┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2018-10-24[KStandardItemListWidget] Pass icon state to overlay painterKai Uwe Broulik
Ensures the overlay is painted in the same icon state, especially the selected one so dark overlays turn white. Differential Revision: https://phabricator.kde.org/D16307
2018-10-10Update hidden state correctlyThomas Surrel
Summary: When renaming a file from '.hidden' to 'not_hidden', the file would still be displayed like a hidden file with a semi-transparent icon and a grey text. BUG: 399599 Reviewers: #dolphin, elvisangelaccio Reviewed By: elvisangelaccio Subscribers: elvisangelaccio, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D16115
2018-10-07[PlacesItemModelTest] More index-related fixesElvis Angelaccio
Again, we cannot assume the Desktop and Downloads places are always around.
2018-10-07[PlacesItemModel] Fix testSystemItems()Elvis Angelaccio
2018-10-07[PlacesItemModelTest] Fix testHideItem()Elvis Angelaccio
2018-10-07[PlacesItemModelTest] Fix testTearDownDevice()Elvis Angelaccio
2018-10-07[PlacesItemModelTest] Fix testDeletePlace()Elvis Angelaccio
If the Desktop or Downloads folder is missing, using 5 as index would be wrong.
2018-10-07[PlacesItemModelTest] Fix testGroups() test caseElvis Angelaccio
The test was also assuming that the Desktop and Downloads folders are always available, which isn't the case.
2018-10-07Follow-up of commit 9760f9607dElvis Angelaccio
Also drop the hardcoded model count all over the place.
2018-10-07[PlacesItemModelTest] Check whether Desktop and Download folders existElvis Angelaccio
KFilePlacesModel creates the Desktop and Downloads bookmarks only if their folder exists. This should hopefully fix the failing test on the CI (actual count = 15, expected count = 17), since the CI runs in docker and probably doesn't have those two folders by default.
2018-10-07Fix disabling of DolphinNewFileMenuElvis Angelaccio
Summary: Commit e133c4557ecc37ed3f7e1b9 doesn't work because the actions in the KNewFileMenu are added only when we show the context menu for the first time. Fixes the failing test cases in D16005. Test Plan: Run `dolphinmainwindowtest` and open the context menu in different places (Home, Root, Trash, `bluetooth:/`, etc.) Reviewers: #dolphin Subscribers: kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D16006
2018-10-07Add test cases for enabled status of DolphinNewFileMenuElvis Angelaccio
Summary: Root and Trash test cases are currently failing because of commit e133c4557ecc37ed3f7e1b9418306aa8cc516865. Reviewers: #dolphin Subscribers: kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D16005
2018-10-06Don't assign twice the same key to the action New TabJaime Torres Amate
Second try: added Qt::CTRL + Qt::Key_T and Qt::CTRL + Qt::SHIFT + Qt::Key_N as QKeySequence::AddTab is only Qt::CTRL + Qt::SHIFT + Qt::Key_N under plasma.
2018-10-03Fix that dragging a file can trigger inline rename.Andreas Krutzler
Summary: Inline renaming is aborted as soon as an item is dragged. Previously, ’m_dragging' was used to determine if an item was being dragged. However, inline renaming is triggered after a certain amount of time, during which time the user may have stopped dragging items. BUG: 398375 FIXED-IN: 18.08.2 Test Plan: When dragging an selected item, inline renaming should never be started, regardless of where you drag it (Places panel, other split-view window, out of the Dolphin window, ...). Reviewers: wbauer, elvisangelaccio, #dolphin, ngraham Reviewed By: wbauer, elvisangelaccio, #dolphin, ngraham Subscribers: kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D15904
2018-09-10Don't assign twice the same key to the action New TabJaime Torres Amate
Summary: QKeySequence::AddTab = Qt::CTRL + Qt::Key_T. Leaving only the first avoids the warning window "There are two actions (New Tab, New Tab) that want to use the same shortcut (Ctrl+T)" BUG: 398324 Test Plan: su - test unset KDE_FULL_SESSION dolphin After: No more the warning window. Reviewers: #dolphin, elvisangelaccio Reviewed By: #dolphin, elvisangelaccio Subscribers: elvisangelaccio, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D15371
2018-09-10Do use QIcon::Selected for non-icon viewKai Uwe Broulik
Fixes a regression introduced by not using the selected state. The views other than icon view actually do have a proper highlighted background. Differential Revision: https://phabricator.kde.org/D15387
2018-09-05[KStandardItemListWidget] Round to icon size before applying scalingKai Uwe Broulik
Otherwise for 22px icons on high dpi we will request either the wrong icons or scale them needlessly. Dolphin requests a pixmap of 22px, this is then multiplied by dpr resulting in 44 which isn't a valid icon size (only 32 or 48 are). Moreover, we will also hit the path where it will scale the pixmap to a proper icon size resulting in blurry icons (and a performance penalty). Differential Revision: https://phabricator.kde.org/D15260
2018-09-04Correctly save behaviourOnLaunchDavid Edmundson
Summary: We only wrote out a checkbox value if the checkbox was checked. Unchecking it would not do anything. BUG: 398022 Test Plan: Read KRun's exepcted values Unchecked config option Reloaded dolphin Checkbox remained off Reviewers: #dolphin, ngraham, elvisangelaccio Reviewed By: #dolphin, ngraham, elvisangelaccio Subscribers: ngraham, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D15147
2018-09-04Don't use QIcon::Selected state for selected iconKai Uwe Broulik
This causes selected monochrome Breeze icons to turn white as this state is meant for when the icon is actually painted ontop of e.g. a blue highlighted area in a menu Since the advanced icon configuration (where you could choose a custom hint color and other effects) has been removed in Plasma 5.13 and more importantly the fact that Dolphin always tints the icon in the highlight color disregarding any custom icon effects settings this is an acceptable change. CHANGELOG: Fixed monochrome icons turning invisible when selected BUG: 398014 FIXED-IN: 18.08.2 Differential Revision: https://phabricator.kde.org/D15255
2018-08-16Pretty-print "creationtime" roleKai Uwe Broulik
It was forgotten and would show up as ISO date string instead of human-readable string. Differential Revision: https://phabricator.kde.org/D14878
2018-08-04Remove custom icon selection for trashShubham Jangra
Summary: CCBUG: 391200 Test Plan: 1. Open Dolphin 2. Edit trash in places item Result: No custom icon option available Reviewers: ngraham, #dolphin, broulik, pino, elvisangelaccio, cfeck Reviewed By: ngraham, #dolphin, elvisangelaccio, cfeck Subscribers: rkflx, cfeck, elvisangelaccio, pino, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D14378
2018-07-30GIT_SILENT made messages (after extraction)l10n daemon script
2018-07-26Compare UDS entry times directly instead of going through KFileItemKai Uwe Broulik
This avoids creating a QDateTime object with all the timezone processing that comes with it since we're only interested in the relative order, not absolute precise date time values. CHANGELOG: Sorting files by date is significantly faster now Differential Revision: https://phabricator.kde.org/D14394
2018-07-19Fixes small memory leak in DolphinContextMenuDavid Hallas
Summary: When DolphinContextMenu::baseFileItem is called a KFileItem is allocated and stored in DolphinContextMenu::m_baseFileItem, which is of type KFileItem*, but the destructor failed to delete this. Test Plan: This leak was found using Address Sanitizer Reviewers: broulik, elvisangelaccio Reviewed By: broulik, elvisangelaccio Subscribers: ngraham, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D14178
2018-07-19[KItemListSelectionToggle] Adjust painting icon for high dpi scalingKai Uwe Broulik
Instead of using KIconLoader which currently doesn't support high dpi scaling, use QIcon::fromTheme which can. Differential Revision: https://phabricator.kde.org/D14222
2018-07-18Fixes memory leak in KItemListViewAccessibleDavid Hallas
Summary: The KItemListViewAccessible class has a list of QAccessibleInterface pointers in a member variable m_cells. The problem is that when new entries are created, the newly allocated pointer is not stored in the list, only a nullptr is store, this renders the cleanup code in the destructor useless. This patch simply stores the pointer in the list, causing the destructor to correctly free the memory. Test Plan: I found this issue using address sanitizer. Simply building Dolphin with -fsanitize=address and opening a window caused the memory leak. Reviewers: #dolphin, jtamate, elvisangelaccio Reviewed By: #dolphin, jtamate, elvisangelaccio Subscribers: elvisangelaccio, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D14168
2018-07-18Removes unused member variablesDavid Hallas
Summary: The InformationPanel::m_pendingPreview and ApplyViewPropsJob::m_currentItem member variables are not used and can therefore be removed. Reviewers: broulik, elvisangelaccio Reviewed By: broulik, elvisangelaccio Subscribers: kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D14180
2018-07-14Modernize View Properties windowNathaniel Graham
Summary: Like D12571, but for the {nav View Properties} Window. Also did a little bit of re-organization. This allows us to use a `QFormLayout` as the top-level layout and simplify the code a lot, including no longer using the now-unnecessary paradigm of putting a layout inside a `QWidget`, and ending the use of `QGridLayout` to make a fake and more complicated form-style layout. Depends on D13749 Test Plan: Window still resizes properly when the Additional Information content is shown or hidden. Global view properties, additional information hidden: {F6035943} Global view properties, additional information shown: {F6035945} Per-folder view properties, additional information hidden: {F6035869} Per-folder view properties, additional information shown: {F6035870} Reviewers: #dolphin, elvisangelaccio, broulik, #vdg Reviewed By: #dolphin, elvisangelaccio Subscribers: abetts, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D13768
2018-07-14Speedup sortJaime Torres
Summary: Uses a reference to the collator instead of copying and reinitializing it again and again. This is the reason for the speedup. Changing the implementation from a Functor class to a Lambda removes some boilerplate code, but is not relevant for performance. This requires a workaround for https://bugreports.qt.io/browse/QTBUG-69361 Just a single comparison to force the clean state of QCollator. Test Plan: Sorting in a directory with 82874 images: [TIME] Sorting: 19883 (before) [TIME] Sorting: 4198 (after) kfileitemmodelbenchmark before: .............. Passed 29.36 sec kfileitemmodelbenchmark after: .............. Passed 20.39 sec Reviewers: #dolphin, #frameworks, markg, elvisangelaccio, bruns Reviewed By: #dolphin, markg, elvisangelaccio Subscribers: elvisangelaccio, apol, bruns, markg, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D13814
2018-07-14Revert to change the commit message.Jaime Torres
Summary: This reverts commit 765cc968c9dfbd4350226b775377506135c0442d. Test Plan: revert-hammer Reviewers: Subscribers:
2018-07-13Speedup sortJaime Torres
Summary: Use a lambda function to use only one QCollator initialized only once. This requires a workaround for https://bugreports.qt.io/browse/QTBUG-69361 Just a single comparison to force the clean state of QCollator. Test Plan: Sorting in a directory with 82874 images: [TIME] Sorting: 19883 (before) [TIME] Sorting: 4198 (after) kfileitemmodelbenchmark before: .............. Passed 29.36 sec kfileitemmodelbenchmark after: .............. Passed 20.39 sec Reviewers: #dolphin, #frameworks, markg, elvisangelaccio, bruns Reviewed By: #dolphin, markg, elvisangelaccio Subscribers: elvisangelaccio, apol, bruns, markg, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D13814
2018-07-11[KFileItemModelRolesUpdater] Fix preview scaling for frameless previewsKai Uwe Broulik
Follow-up to D11319 for e.g. folder previews Differential Revision: https://phabricator.kde.org/D14047
2018-07-11[KStandardItemListWidget] Avoid needless image resizingKai Uwe Broulik
There be rounding errors when scaling pixmaps when keeping aspect ratio Differential Revision: https://phabricator.kde.org/D11319
2018-07-08Mark PHONON_INCLUDES dirs as SYSTEM, so compiler omits them for warningsFriedrich W. H. Kossebau
2018-07-07A complete build does not fix the crashes I'm having.Jaime Torres
I prefer to wait until QQCollator is thread safe or someone discovers why this is happening now and not before. Summary: This reverts commit 63825de82f3adc9376b0f0f27e24e21bccf62e2a. Test Plan: revert-hammer Reviewers: Subscribers:
2018-07-06Speedup sortJaime Torres
Summary: Use a lambda function instead of a class. This way the member QCollator is not copied and initialized several times. Test Plan: Sorting in a directory with 82874 images: [TIME] Sorting: 19883 (before) [TIME] Sorting: 4198 (after) kfileitemmodelbenchmark before: .............. Passed 29.36 sec kfileitemmodelbenchmark after: .............. Passed 20.39 sec Reviewers: #dolphin, #frameworks, markg, elvisangelaccio Reviewed By: #dolphin, markg, elvisangelaccio Subscribers: elvisangelaccio, apol, bruns, markg, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D13814
2018-07-05Modernize Settings windowNathaniel Graham
Summary: This patch modernizes the appearance of Dolphin's configuration window by following the KDE HIG as much as possible and following design cues from Plasma and System Settings. Test Plan: Tested all settings to make sure they still work; they do. Startup page, before: {F5825313} Startup page, after: {F5918574} View page (Icons), before: {F5825319} View page (Icons) after: {F5918575} View page (Compact), before: {F5825321} View page (Compact) after: {F5918700} View page (Detailed), before: {F5825323} View page: (Detailed), after: {F5918701} Navigation page: no change Trash page, before: {F5858748} Trash page, after: {F5866656} (Provided by {D12986}) General page (behavior), before: {F5825316} General page (behavior) after: {F5918572} General page (confirmations), before: {F5866885} General page (confirmations), after: {F5918702} General page (status bar): no change Reviewers: #dolphin, #vdg, broulik, elvisangelaccio Reviewed By: #dolphin, elvisangelaccio Subscribers: fabianr, cfeck, medhefgo, zzag, rkflx, kfm-devel, elvisangelaccio, abetts Tags: #dolphin Differential Revision: https://phabricator.kde.org/D12571
2018-07-04Use more nullptrFriedrich W. H. Kossebau
2018-06-29Remove QT definitions duplicated from KDEFrameworkCompilerSettings or deadFriedrich W. H. Kossebau
2018-06-27Port from KComboBox to QComboBoxNathaniel Graham
Summary: None of Dolphin's current usages of `KComboBox` use any of its additional features beyond `QComboBox`, so let's use `QComboBox` instead. Test Plan: Tested all features that use comboboxes in Dolphin. No visual or functional changes or regressions. Reviewers: #dolphin, elvisangelaccio, broulik Reviewed By: #dolphin, elvisangelaccio Subscribers: broulik, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D13749
2018-06-26Use collapsible box to configure visible rolesElvis Angelaccio
Summary: A modal dialog that opens another modal dialog is bad UX and should be avoided whenever possible. These days we have `KCollapsibleGroupBox` that can be used to show advanced settings without cluttering the default layout. This change removes the `AdditionalInfoDialog` and uses a collapsible groupbox instead. The `Apply` buttons gets enabled whenever a role gets checked or unchecked, consistently with the existing checkboxes. Test Plan: Change visible roles in the view properties dialog. Reviewers: #dolphin, #vdg Reviewed By: #vdg Subscribers: ngraham, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D13569
2018-06-22don't use temporaries when uneededTomaz Canabrava
Summary: Remove unused variable Compiled, Run. Trash still there. Use copy ellision Remove uneeded code Subscribers: kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D13680
2018-06-22Use copy ellisionTomaz Canabrava
2018-06-22Remove unused variableTomaz Canabrava
Compiled, Run. Trash still there.
2018-06-22don't use temporaries when uneededTomaz Canabrava
2018-06-22GIT_SILENT made messages (after extraction)l10n daemon script
2018-06-19Move General settings to the topNathaniel Graham
Summary: KDE apps generally (ha ha) have their {nav General} page at the top of the list, so it's the first thing the user sees when they open the {nav Settings} window, but Dolphin is an exception. It puts the {nav General} page //last!// This patch makes Dolphin consistent with other KDE apps by moving the {nav General} page up to the top. Test Plan: {F5918590} Reviewers: #dolphin, #kde_applications, elvisangelaccio, ltoscano Reviewed By: elvisangelaccio, ltoscano Subscribers: kde-doc-english, ltoscano, elvisangelaccio, kfm-devel Tags: #dolphin, #documentation Differential Revision: https://phabricator.kde.org/D13595
2018-06-19Do not duplicate work of KAboutData::setupCommandLine()Laurent Montel
2018-06-13ViewPropertiesDialog: disable Apply button on startupElvis Angelaccio
We call `markAsDirty(false)` at the end of `loadSettings()` but that's not enough, because `m_isDirty` is initialized to false (as it should be). This means `isDirtyChanged` is not emitted and the button is not disabled. By disabling it explicitly, we make it consistent with the Apply button in the settings dialog (which is also initially disabled).
2018-06-13Merge branch 'Applications/18.04'Elvis Angelaccio