From: Alexander Volkov Date: Thu, 18 Sep 2014 14:31:40 +0000 (+0400) Subject: Assistant: Make "Bookmarks Menu" the default bookmarks folder X-Git-Tag: v5.4.0~13 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=dff9a4c9e5b5a616c920a693d9c4cca5c49c2d77;p=platform%2Fupstream%2Fqttools.git Assistant: Make "Bookmarks Menu" the default bookmarks folder Assistant doesn't show the bookmarks toolbar by default so it's more reasonable to preselect the "Bookmarks Menu" folder when a user adds a bookmark. Change-Id: If1b92c1decb280e96e5c58a56d6948eec6e44813 Reviewed-by: Karsten Heimrich Reviewed-by: Christian Kandeler --- diff --git a/src/assistant/assistant/bookmarkdialog.cpp b/src/assistant/assistant/bookmarkdialog.cpp index ac7fd44..14132d1 100644 --- a/src/assistant/assistant/bookmarkdialog.cpp +++ b/src/assistant/assistant/bookmarkdialog.cpp @@ -84,8 +84,7 @@ BookmarkDialog::BookmarkDialog(BookmarkModel *sourceModel, const QString &title, connect(ui.treeView->selectionModel(), SIGNAL(currentChanged(QModelIndex, QModelIndex)), this, SLOT(currentIndexChanged(QModelIndex))); - ui.bookmarkFolders->setCurrentIndex(0); - ui.treeView->setCurrentIndex(ui.treeView->indexAt(QPoint(2, 2))); + ui.bookmarkFolders->setCurrentIndex(ui.bookmarkFolders->count() > 1 ? 1 : 0); const HelpEngineWrapper &helpEngine = HelpEngineWrapper::instance(); if (helpEngine.usesAppFont())