]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/dolphinmainwindow.cpp
Sync docs with interface
[dolphin.git] / src / dolphinmainwindow.cpp
index ec42d33f71adc50ad699ce7300b8e24c4f91cb00..afca88198e6fb84f5cc6bb653152914c28ee0d35 100644 (file)
@@ -359,7 +359,7 @@ void DolphinMainWindow::addToPlaces()
     QString name;
 
     // If nothing is selected, act on the current dir
-    if (m_activeViewContainer->view()->selectedItems().count() == 0) {
+    if (m_activeViewContainer->view()->selectedItems().isEmpty()) {
         url = m_activeViewContainer->url();
         name = m_activeViewContainer->placesText();
     } else {
@@ -1696,8 +1696,9 @@ void DolphinMainWindow::setupDockWidgets()
         "</interface> to display it again.</para>") + panelWhatsThis);
 
     // Add actions into the "Panels" menu
-    KActionMenu* panelsMenu = new KActionMenu(i18nc("@action:inmenu View", "Panels"), this);
+    KActionMenu* panelsMenu = new KActionMenu(i18nc("@action:inmenu View", "Show Panels"), this);
     actionCollection()->addAction(QStringLiteral("panels"), panelsMenu);
+    panelsMenu->setIcon(QIcon::fromTheme(QStringLiteral("view-sidetree")));
     panelsMenu->setDelayed(false);
     const KActionCollection* ac = actionCollection();
     panelsMenu->addAction(ac->action(QStringLiteral("show_places_panel")));
@@ -2160,10 +2161,6 @@ void DolphinMainWindow::UndoUiInterface::jobError(KIO::Job* job)
 
 bool DolphinMainWindow::isUrlOpen(const QString& url)
 {
-    if (m_tabWidget->getIndexByUrl(QUrl::fromUserInput((url))).first >= 0) {
-        return true;
-    } else {
-        return false;
-    }
+    return m_tabWidget->isUrlOpen(QUrl::fromUserInput((url)));
 }