return;
QListWidget * lw = static_cast<QListWidget *>(bulletpaneSW->widget(font));
- lw->setItemSelected(lw->item(character), select);
+ lw->item(character)->setSelected(select);
}
// restore selected branch
if (bname == sel_branch) {
branchesTW->setCurrentItem(newItem);
- branchesTW->setItemSelected(newItem, true);
+ newItem->setSelected(true);
}
}
unknownPB->setEnabled(!unknown_branches_.isEmpty());
// restore selected index
if (iname == sel_index) {
indicesTW->setCurrentItem(newItem);
- indicesTW->setItemSelected(newItem, true);
+ newItem->setSelected(true);
}
}
indicesTW->resizeColumnToContents(0);
// show all hidden items
QTreeWidgetItemIterator it(shortcutsTW, QTreeWidgetItemIterator::Hidden);
for (; *it; ++it)
- shortcutsTW->setItemHidden(*it, isAlwaysHidden(**it));
+ (*it)->setHidden(isAlwaysHidden(**it));
// close all categories
for (int i = 0; i < shortcutsTW->topLevelItemCount(); ++i)
shortcutsTW->collapseItem(shortcutsTW->topLevelItem(i));
// show matched items
for (int i = 0; i < matched.size(); ++i)
if (!isAlwaysHidden(*matched[i])) {
- shortcutsTW->setItemHidden(matched[i], false);
- shortcutsTW->setItemExpanded(matched[i]->parent(), true);
+ matched[i]->setHidden(false);
+ matched[i]->parent()->setExpanded(true);
}
}
if (item) {
user_bind_.bind(&k, func);
shortcutsTW->sortItems(0, Qt::AscendingOrder);
- shortcutsTW->setItemExpanded(item->parent(), true);
+ item->parent()->setExpanded(true);
shortcutsTW->setCurrentItem(item);
shortcutsTW->scrollToItem(item);
} else {
while (*it) {
if ((*it)->text(0) == textToFind) {
refsTW->setCurrentItem(*it);
- refsTW->setItemSelected(*it, true);
+ (*it)->setSelected(true);
//Make sure selected item is visible
refsTW->scrollToItem(*it);
last_reference_ = textToFind;