diff --git a/retroshare-gui/src/gui/msgs/MessagesDialog.cpp b/retroshare-gui/src/gui/msgs/MessagesDialog.cpp index 78d81ef20..de91df5ff 100644 --- a/retroshare-gui/src/gui/msgs/MessagesDialog.cpp +++ b/retroshare-gui/src/gui/msgs/MessagesDialog.cpp @@ -95,6 +95,7 @@ #define ROW_SENTBOX 3 #define ROW_TRASHBOX 4 +// #define DEBUG_MESSAGES_DIALOG 1 class MessageSortFilterProxyModel: public QSortFilterProxyModel { @@ -365,15 +366,18 @@ void MessagesDialog::preModelUpdate() if (m.isValid()) { mTmpSavedCurrentId = m.sibling(m.row(), RsMessageModel::COLUMN_THREAD_MSGID).data(RsMessageModel::MsgIdRole).toString(); } - +#ifdef DEBUG_MESSAGES_DIALOG std::cerr << "Pre-change: saving selection for " << mTmpSavedSelectedIds.size() << " indexes" << std::endl; +#endif } void MessagesDialog::postModelUpdate() { // restore selection +#ifdef DEBUG_MESSAGES_DIALOG std::cerr << "Post-change: restoring selection for " << mTmpSavedSelectedIds.size() << " indexes" << std::endl; +#endif QItemSelection sel; foreach(const QString& s,mTmpSavedSelectedIds) diff --git a/retroshare-gui/src/gui/settings/AppearancePage.cpp b/retroshare-gui/src/gui/settings/AppearancePage.cpp index 2fb86e5a2..dcfb0350e 100755 --- a/retroshare-gui/src/gui/settings/AppearancePage.cpp +++ b/retroshare-gui/src/gui/settings/AppearancePage.cpp @@ -75,7 +75,8 @@ AppearancePage::AppearancePage(QWidget * parent, Qt::WindowFlags flags) ui.cmboLanguage->addItem(FilesDefs::getIconFromQtResourcePath(":/images/flags/" + code + ".png"), LanguageSupport::languageName(code), code); } foreach (QString style, QStyleFactory::keys()) { - ui.cmboStyle->addItem(style, style.toLower()); + if(style.toLower() != "gtk2" || (getenv("QT_QPA_PLATFORMTHEME")!=nullptr && !strcmp(getenv("QT_QPA_PLATFORMTHEME"),"gtk2"))) // make sure that if style is gtk2, the system has the correct environment variable set. + ui.cmboStyle->addItem(style, style.toLower()); } QMap styleSheets; @@ -266,9 +267,9 @@ void AppearancePage::load() index = ui.mainPageButtonType_CB->findData(Settings->getPageButtonLoc()); if (index != 0) { - ui.cmboTollButtonsStyle->hide(); - }else { - ui.cmboTollButtonsStyle->show(); + ui.cmboTollButtonsStyle->show(); + }else { + ui.cmboTollButtonsStyle->hide(); } whileBlocking(ui.mainPageButtonType_CB)->setCurrentIndex(!Settings->getPageButtonLoc());