diff options
| author | Luca Beltrame <[email protected]> | 2012-09-21 10:55:08 +0200 |
|---|---|---|
| committer | Luca Beltrame <[email protected]> | 2012-09-21 10:55:08 +0200 |
| commit | f1b822d926316d739ec10d8b05917b6b0c2d92b5 (patch) | |
| tree | 20e52bfd70694a34f86fa650d3797be67bda8f67 /src/panels | |
| parent | 399c4b22ea9947047c7d2777d7f361df6b5e9636 (diff) | |
| parent | c8243401470156d9ee76e2015a23741570d3dba1 (diff) | |
Merge branch 'KDE/4.9'
Conflicts:
konq-plugins/dirfilter/dirfilterplugin.cpp
konq-plugins/dirfilter/dirfilterplugin.h
Diffstat (limited to 'src/panels')
| -rw-r--r-- | src/panels/folders/folderspanel.cpp | 2 | ||||
| -rw-r--r-- | src/panels/places/placesitemmodel.cpp | 24 | ||||
| -rw-r--r-- | src/panels/terminal/terminalpanel.cpp | 1 |
3 files changed, 20 insertions, 7 deletions
diff --git a/src/panels/folders/folderspanel.cpp b/src/panels/folders/folderspanel.cpp index 0760200b6..13093fff6 100644 --- a/src/panels/folders/folderspanel.cpp +++ b/src/panels/folders/folderspanel.cpp @@ -140,6 +140,8 @@ void FoldersPanel::showEvent(QShowEvent* event) m_controller = new KItemListController(m_model, view, this); m_controller->setSelectionBehavior(KItemListController::SingleSelection); + m_controller->setAutoActivationBehavior(KItemListController::ExpansionOnly); + m_controller->setMouseDoubleClickAction(KItemListController::ActivateAndExpandItem); m_controller->setAutoActivationDelay(750); m_controller->setSingleClickActivation(true); diff --git a/src/panels/places/placesitemmodel.cpp b/src/panels/places/placesitemmodel.cpp index 5eb1c35ea..4770c6b10 100644 --- a/src/panels/places/placesitemmodel.cpp +++ b/src/panels/places/placesitemmodel.cpp @@ -659,11 +659,22 @@ void PlacesItemModel::updateBookmarks() } if (!found) { - PlacesItem* item = new PlacesItem(newBookmark); - if (item->isHidden() && !m_hiddenItemsShown) { - m_bookmarkedItems.append(item); - } else { - appendItemToGroup(item); + const QString udi = newBookmark.metaDataItem("UDI"); + + /* + * See Bug 304878 + * Only add a new places item, if the item text is not empty + * and if the device is available. Fixes the strange behaviour - + * add a places item without text in the Places section - when you + * remove a device (e.g. a usb stick) without unmounting. + */ + if (udi.isEmpty() || Solid::Device(udi).isValid()) { + PlacesItem* item = new PlacesItem(newBookmark); + if (item->isHidden() && !m_hiddenItemsShown) { + m_bookmarkedItems.append(item); + } else { + appendItemToGroup(item); + } } } } @@ -885,8 +896,7 @@ void PlacesItemModel::createSystemBookmarks() Q_ASSERT(m_systemBookmarks.isEmpty()); Q_ASSERT(m_systemBookmarksIndexes.isEmpty()); - const QString timeLineIcon = "package_utility_time"; // TODO: Ask the Oxygen team to create - // a custom icon for the timeline-protocol + const QString timeLineIcon = "chronometer"; // Note: The context of the I18N_NOOP2 must be "KFile System Bookmarks". The real // i18nc call is done after reading the bookmark. The reason why the i18nc call is not diff --git a/src/panels/terminal/terminalpanel.cpp b/src/panels/terminal/terminalpanel.cpp index 889c07e45..f6d3a5981 100644 --- a/src/panels/terminal/terminalpanel.cpp +++ b/src/panels/terminal/terminalpanel.cpp @@ -159,6 +159,7 @@ void TerminalPanel::sendCdToTerminal(const QString& dir) } m_terminal->sendInput(" cd " + KShell::quoteArg(dir) + '\n'); + m_konsolePartCurrentDirectory = dir; if (m_clearTerminal) { m_terminal->sendInput(" clear\n"); |
