|
@@ -1,4 +1,4 @@
|
|
|
-#include "findresultwin.h"
|
|
|
+#include "findresultwin.h"
|
|
|
#include "findwin.h"
|
|
|
#include "common.h"
|
|
|
#include "styleset.h"
|
|
@@ -208,12 +208,12 @@ void FindResultWin::slot_selectAll()
|
|
|
//遍历下面的子节点
|
|
|
int i = 0;
|
|
|
QModelIndex childMi;
|
|
|
- childMi = sectionItem.child(i, 0);
|
|
|
+ childMi = sectionItem.model()->index(i, 0, sectionItem);
|
|
|
while (childMi.isValid())
|
|
|
{
|
|
|
++i;
|
|
|
ui.resultTreeView->selectionModel()->select(childMi, QItemSelectionModel::Select);
|
|
|
- childMi = sectionItem.child(i, 0);
|
|
|
+ childMi = sectionItem.model()->index(i, 0, sectionItem);
|
|
|
}
|
|
|
return i+1;
|
|
|
};
|
|
@@ -226,12 +226,12 @@ void FindResultWin::slot_selectAll()
|
|
|
//遍历根节点下面每一个section
|
|
|
{
|
|
|
int i = 0;
|
|
|
- QModelIndex section = rootItem.child(i, 0);
|
|
|
+ QModelIndex section = rootItem.model()->index(i, 0, rootItem);
|
|
|
while (section.isValid() && !section.data(ResultItemEditor).isNull())
|
|
|
{
|
|
|
++i;
|
|
|
selectCount += selectSection(section);
|
|
|
- section = firstRootItem.child(i, 0);
|
|
|
+ section = firstRootItem.model()->index(i, 0, firstRootItem);
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -255,12 +255,12 @@ void FindResultWin::slot_selectSection()
|
|
|
//遍历下面的子节点
|
|
|
int i = 0;
|
|
|
QModelIndex childMi;
|
|
|
- childMi = sectionItem.child(i, 0);
|
|
|
+ childMi = sectionItem.model()->index(i, 0, sectionItem);
|
|
|
while (childMi.isValid())
|
|
|
{
|
|
|
++i;
|
|
|
ui.resultTreeView->selectionModel()->select(childMi, QItemSelectionModel::Select);
|
|
|
- childMi = sectionItem.child(i, 0);
|
|
|
+ childMi = sectionItem.model()->index(i, 0, sectionItem);
|
|
|
}
|
|
|
return i+1;
|
|
|
};
|