diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2011-01-07 13:17:06 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2011-01-07 13:17:06 (GMT) |
commit | 3086852122d940f51866fdfab0176d2e4f3ba238 (patch) | |
tree | 490a232d37d8db9230f5a7b5413dece09bcb50a5 | |
parent | 606294044df3cf318bd6bb6f2e73389d84e3a032 (diff) | |
parent | 9fd43b8bc40e3b7657dc7eba2dccff95f0d0077a (diff) | |
download | Qt-3086852122d940f51866fdfab0176d2e4f3ba238.zip Qt-3086852122d940f51866fdfab0176d2e4f3ba238.tar.gz Qt-3086852122d940f51866fdfab0176d2e4f3ba238.tar.bz2 |
Merge branch 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into master-integration
* 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
Assistant: Fix warnings.
Assistant: Don't tabify "Open Pages" dock widget by default.
-rw-r--r-- | tools/assistant/tools/assistant/bookmarkfiltermodel.cpp | 37 | ||||
-rw-r--r-- | tools/assistant/tools/assistant/mainwindow.cpp | 10 |
2 files changed, 21 insertions, 26 deletions
diff --git a/tools/assistant/tools/assistant/bookmarkfiltermodel.cpp b/tools/assistant/tools/assistant/bookmarkfiltermodel.cpp index fe510a5..d60e537 100644 --- a/tools/assistant/tools/assistant/bookmarkfiltermodel.cpp +++ b/tools/assistant/tools/assistant/bookmarkfiltermodel.cpp @@ -54,25 +54,24 @@ void BookmarkFilterModel::setSourceModel(QAbstractItemModel *_sourceModel) { beginResetModel(); - disconnect(sourceModel, SIGNAL(dataChanged(QModelIndex, QModelIndex)), this, - SLOT(changed(QModelIndex, QModelIndex))); - - disconnect(sourceModel, SIGNAL(rowsInserted(QModelIndex, int, int)), - this, SLOT(rowsInserted(QModelIndex, int, int))); - - disconnect(sourceModel, SIGNAL(rowsAboutToBeRemoved(QModelIndex, int, int)), - this, SLOT(rowsAboutToBeRemoved(QModelIndex, int, int))); - disconnect(sourceModel, SIGNAL(rowsRemoved(QModelIndex, int, int)), this, - SLOT(rowsRemoved(QModelIndex, int, int))); - - disconnect(sourceModel, SIGNAL(layoutAboutToBeChanged()), this, - SLOT(layoutAboutToBeChanged())); - disconnect(sourceModel, SIGNAL(layoutChanged()), this, - SLOT(layoutChanged())); - - disconnect(sourceModel, SIGNAL(modelAboutToBeReset()), this, - SLOT(modelAboutToBeReset())); - disconnect(sourceModel, SIGNAL(modelReset()), this, SLOT(modelReset())); + if (sourceModel) { + disconnect(sourceModel, SIGNAL(dataChanged(QModelIndex, QModelIndex)), + this, SLOT(changed(QModelIndex, QModelIndex))); + disconnect(sourceModel, SIGNAL(rowsInserted(QModelIndex, int, int)), + this, SLOT(rowsInserted(QModelIndex, int, int))); + disconnect(sourceModel, + SIGNAL(rowsAboutToBeRemoved(QModelIndex, int, int)), this, + SLOT(rowsAboutToBeRemoved(QModelIndex, int, int))); + disconnect(sourceModel, SIGNAL(rowsRemoved(QModelIndex, int, int)), + this, SLOT(rowsRemoved(QModelIndex, int, int))); + disconnect(sourceModel, SIGNAL(layoutAboutToBeChanged()), this, + SLOT(layoutAboutToBeChanged())); + disconnect(sourceModel, SIGNAL(layoutChanged()), this, + SLOT(layoutChanged())); + disconnect(sourceModel, SIGNAL(modelAboutToBeReset()), this, + SLOT(modelAboutToBeReset())); + disconnect(sourceModel, SIGNAL(modelReset()), this, SLOT(modelReset())); + } QAbstractProxyModel::setSourceModel(sourceModel); sourceModel = qobject_cast<BookmarkModel*> (_sourceModel); diff --git a/tools/assistant/tools/assistant/mainwindow.cpp b/tools/assistant/tools/assistant/mainwindow.cpp index d7d01da..7852104 100644 --- a/tools/assistant/tools/assistant/mainwindow.cpp +++ b/tools/assistant/tools/assistant/mainwindow.cpp @@ -106,7 +106,7 @@ MainWindow::MainWindow(CmdLineParser *cmdLine, QWidget *parent) TRACE_OBJ setToolButtonStyle(Qt::ToolButtonFollowStyle); - setDockOptions(ForceTabbedDocks); // Has no effect; Qt bug? + setDockOptions(dockOptions() | AllowNestedDocks); QString collectionFile; if (usesDefaultCollection()) { @@ -199,6 +199,7 @@ MainWindow::MainWindow(CmdLineParser *cmdLine, QWidget *parent) } QToolBar *toolBar = addToolBar(tr("Bookmark Toolbar")); + toolBar->setObjectName(QLatin1String("Bookmark Toolbar")); bookMarkManager->setBookmarksToolbar(toolBar); // Show the widget here, otherwise the restore geometry and state won't work @@ -218,8 +219,7 @@ MainWindow::MainWindow(CmdLineParser *cmdLine, QWidget *parent) } else { tabifyDockWidget(contentDock, indexDock); tabifyDockWidget(indexDock, bookmarkDock); - tabifyDockWidget(bookmarkDock, openPagesDock); - tabifyDockWidget(openPagesDock, searchDock); + tabifyDockWidget(bookmarkDock, searchDock); contentDock->raise(); const QRect screen = QApplication::desktop()->screenGeometry(); resize(4*screen.width()/5, 4*screen.height()/5); @@ -460,10 +460,6 @@ void MainWindow::setupActions() menu->addAction(globalActions->printAction()); menu->addSeparator(); - m_closeTabAction = menu->addAction(tr("&Close Tab"), m_centralWidget, - SLOT(closeTab())); - m_closeTabAction->setShortcuts(QKeySequence::Close); - QIcon appExitIcon = QIcon::fromTheme("application-exit"); QAction *tmp; #ifdef Q_OS_WIN |