diff options
Diffstat (limited to 'tools')
-rw-r--r-- | tools/assistant/tools/assistant/centralwidget.cpp | 3 | ||||
-rw-r--r-- | tools/assistant/tools/assistant/mainwindow.cpp | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/tools/assistant/tools/assistant/centralwidget.cpp b/tools/assistant/tools/assistant/centralwidget.cpp index 52d48d5..95e458c 100644 --- a/tools/assistant/tools/assistant/centralwidget.cpp +++ b/tools/assistant/tools/assistant/centralwidget.cpp @@ -780,6 +780,9 @@ void CentralWidget::showTabBarContextMenu(const QPoint &point) menu.addSeparator(); QAction *newBookmark = menu.addAction(tr("Add Bookmark for this Page...")); + const QString &url = viewer->source().toString(); + if (url.isEmpty() || url == QLatin1String("about:blank")) + newBookmark->setEnabled(false); QAction *pickedAction = menu.exec(tabBar->mapToGlobal(point)); if (pickedAction == newPage) diff --git a/tools/assistant/tools/assistant/mainwindow.cpp b/tools/assistant/tools/assistant/mainwindow.cpp index 582eef3..ba22590 100644 --- a/tools/assistant/tools/assistant/mainwindow.cpp +++ b/tools/assistant/tools/assistant/mainwindow.cpp @@ -748,7 +748,7 @@ void MainWindow::copyAvailable(bool yes) void MainWindow::addNewBookmark(const QString &title, const QString &url) { - if (url.isEmpty()) + if (url.isEmpty() || url == QLatin1String("about:blank")) return; m_bookmarkManager->showBookmarkDialog(this, title, url); |