Commit graph

6190 commits

Author SHA1 Message Date
l10n daemon script 030e7857c2 GIT_SILENT made messages (after extraction) 2021-01-01 02:49:09 +01:00
l10n daemon script fc56fb60c1 GIT_SILENT made messages (after extraction) 2020-12-31 08:27:23 +01:00
Piotr Henryk Dabrowski a19469d83d use 'compass' instead of 'bookmarks' icon in Show Places Panel button
'bookmark' icon is already used for Bookmarks Menu
2020-12-30 00:05:49 +01:00
Piotr Henryk Dabrowski 741072272f update KParts' ReadOnlyPart::localFilePath in DolphinPart::openUrl() 2020-12-29 16:06:40 +01:00
l10n daemon script 66ba66b5a0 GIT_SILENT made messages (after extraction) 2020-12-29 02:37:52 +01:00
Duong Do Minh Chau 48af912b83 Add const 2020-12-28 20:18:31 +00:00
Chau Duong 6df591368e Apply Elvis suggestions 2020-12-28 20:18:31 +00:00
Duong Do Minh Chau 238eb86db7 Share actions with main window to avoid duplicating icon name and text 2020-12-28 20:18:31 +00:00
Duong Do Minh Chau 9a0552d51d Remove context menu settings KCM 2020-12-28 20:18:31 +00:00
Duong Do Minh Chau a512176b4b Add options to hide some context menu entries
This commit add options to hide the following context menu entries:
- Add to Places
- Copy Location
- Duplicate Here
- Open in New Tab and Open in New Tabs
- Open in New Window
- Sort By
- View Mode

The Services settings page is renamed to Context Menu

ShowCopyMoveMenu option is moved from GeneralSettings to ContextMenuSettings

BUG: 314594
2020-12-28 20:18:31 +00:00
Eike Hein b339ac1b5f Use a faster way to determine kio-stash isn't installed
Summary:
Dolphin needs to figure out whether or not kio-stash is installed
to set the enabled state of a UI action.

When KProtocolInfo::isKnownProtocol can't find a protocol it gets
worried its protocol cache might be out of date, so it rebuilds it
(doing plenty of disk I/O) and looks again. kio-stash is currently
not yet installed on many systems, so this means most Dolphin
startups out there.

This patch switches to using QDBusConnectionInterface::isServiceRegistered
instead to determine whether the stash notifier daemon is running,
which should be faster than doing disk I/O.

Reviewers: davidedmundson, elvisangelaccio, shortstheory

Subscribers: emmanuelp, alexeymin, ngraham, #dolphin

Differential Revision: https://phabricator.kde.org/D9094
2020-12-28 17:59:14 +01:00
Nate Graham b14f98de19 Make it more obvious that you can connect to servers on remote:/ page
Right now it is not super obvious how you connect to a remote server
in Dolphin when you already know the URL. Users will go to the
"Network" item in the Places panel, but from there it is not totally
clear. The "Add Network Folder" icon in the view opens a complicated
wizard and it's also a bit of an odd UX to have it living in the view as
opposed to being a toolbar button.

Old hands and developers know that the URL navigator is, well, a URL
navigator, and as such, it accepts arbitrary URLs from any view.
However this may not be obvious to other more casual users, for
two reasons:
1. The URL navigator is in breadcrumbs view nearly all of the time and
   by default, so may users may not know that it can accept text at all
2. Even when it's displaying URLs, they are almost always local paths,
   so users may not make the connection that it can accept remote URLs
   rather that just local paths

To improve the discoverability of this feature, this commit makes the
following change:

When the view is displaying the remote:/ ioslave (i.e. the "Networks"
place), the URL navigator is put into URL entry mode and given some
placeholder text that hints at what it can do. It reverts to breadcrumbs
mode when you leave.

BUG: 414670
FIXED-IN: 21.04
2020-12-27 17:38:55 +00:00
Méven Car 88d3f92dff Apply sugestions 2020-12-27 17:18:40 +00:00
Méven Car f6a465c911 Review feedback 2020-12-27 17:18:40 +00:00
Méven Car c1739d5c4d Version Control plugin: allow plugins to return repository root
Currently plugins `fileName()` only return path file extension.

This changes allows plugins to return the absolute file path to their repository root.

CCBUG: 430024
2020-12-27 17:18:40 +00:00
Nate Graham c6cdf4126a Fix typo
GIT_SILENT
2020-12-27 08:25:04 -07:00
l10n daemon script 3c85f4ce3d GIT_SILENT made messages (after extraction) 2020-12-24 02:40:02 +01:00
Méven Car f0d03c7dd7 Details View: display dates as relative Short dates
CCBUG: 340982
2020-12-24 00:11:21 +00:00
Nate Graham 9abe299c77 Merge branch 'release/20.12' 2020-12-23 11:40:09 -07:00
Eduard Manta 303740c68a Fix vertical scroll with horizontal component not being recognized properly
BUG: 430532

a scroll that includes an horizontal component != 0 might still be a vertical scroll
2020-12-23 17:17:19 +01:00
l10n daemon script 7f44b11a5e GIT_SILENT made messages (after extraction) 2020-12-23 02:43:39 +01:00
l10n daemon script ac796744ff GIT_SILENT made messages (after extraction) 2020-12-22 02:41:00 +01:00
Derek Christ 87bb0ca10b Allow non-local startup location
Only local directories were supported to be set as the starting location
of Dolphin. This commit fixes this by using an KIO::StatJob to determine
if the path is actually pointing to a directory or a file regardless if
it is a local or a remote path.

Additionaly a hard-coded exception for urls with the scheme "timeline"
was removed because with the new fix it is now obsolete.

BUG: 428885
2020-12-21 21:28:50 +00:00
l10n daemon script ecd5c7d678 GIT_SILENT made messages (after extraction) 2020-12-21 02:47:25 +01:00
Elvis Angelaccio 125c7aba09 DolphinContextMenu: drop wrong assert
`m_context` can also be `SearchContext` or `TimelineContext`, so this
assert has been wrong since 8b0c12a59c.
2020-12-19 18:25:07 +01:00
Carl Schwan b049f41d7b Improve AppStream description 2020-12-19 16:30:48 +01:00
Nate Graham 59f00343c9 Merge branch 'release/20.12' 2020-12-18 12:22:21 -07:00
Chris Holland ef09315404 Fix crash when device with capacitybar is dragged
BUG: 430441
2020-12-17 19:10:40 -05:00
Ilia Kats acc42f9189 fix display of folder sizes for empty folders
also fixes 1 byte error in size calculation for all folders
2020-12-17 13:04:01 +01:00
Ahmad Samir d74853ef85 Merge branch 'release/20.12' 2020-12-16 23:53:57 +02:00
Ahmad Samir c03b43b4a1 Use setShowOpenOrExecuteDialog(true) with OpenUrlJob
It makes more sense for a file manager to always ask the user:
 - whether to execute binaries
 - whether to open an executable script as text or execute it

The openOrExecute dialog from KIOWidgets has a "don't ask again" checkbox,
and that setting is also accessible from Dolphin's settings dialog.

See the discussion at https://bugs.kde.org/show_bug.cgi?id=429839#c10
2020-12-16 23:51:06 +02:00
Elvis Angelaccio 1b192c67f9 Merge branch 'release/20.12' 2020-12-15 23:28:15 +01:00
Elvis Angelaccio aeea98837d DolphinContextMenu: drop wrong assert
`m_context` can also be `SearchContext` or `TimelineContext`, so this
assert has been wrong since 8b0c12a59c.
2020-12-15 22:56:06 +01:00
Anthony Fieroni c95d7fae79 Fix access url navigator while creating new tab in filename search view
BUG: 429628
BUG: 430434

Signed-off-by: Anthony Fieroni <bvbfan@abv.bg>
2020-12-15 21:44:10 +00:00
David Faure 42cd439af8 Merge remote-tracking branch 'origin/release/20.12' 2020-12-15 18:48:11 +01:00
David Faure da636bf513 Fix KIO warning when URL is empty 2020-12-15 18:45:20 +01:00
Alexander Lohnau 20370b4c9f Do not create instance of GeneralSettings just to access static members 2020-12-11 20:06:51 +01:00
l10n daemon script 784586672d GIT_SILENT made messages (after extraction) 2020-12-10 02:44:34 +01:00
Laurent Montel d2f044b32d operator+/- is disabled for QFlags in qt6 2020-12-09 07:55:44 +01:00
Méven Car ce3c243525 ContextMenu: Allow plugins submenus to react to Shift modifiers
In 9e4642d435 support was added for the
NewFileMenu.
This adds support for the Plugins submenu provided they relay their
parentWidget to their own menus.

BUG: 425997
2020-12-07 22:13:29 +00:00
Alexander Lohnau a4a7b5e8af servicemenuinstaller: Remove file if it already exists
This is the case when you update an entry.
2020-12-07 22:10:37 +00:00
Friedrich W. H. Kossebau ac97d98866 dolphinpart: fix broken part icon name 2020-12-07 22:09:58 +00:00
Friedrich W. H. Kossebau 9826d81034 dolphinpart: port to new KPluginMetaData-based KParts API 2020-12-07 22:09:58 +00:00
Friedrich W. H. Kossebau 07b7f76f7c dolphinpart: add JSON metadata to plugin, install into kf5/parts subdir 2020-12-07 22:09:58 +00:00
l10n daemon script 476fe42624 GIT_SILENT made messages (after extraction) 2020-12-06 08:14:05 +01:00
l10n daemon script 3c6f1e6881 GIT_SILENT made messages (after extraction) 2020-12-06 02:38:12 +01:00
Elvis Angelaccio 2274db954a Merge branch 'release/20.12' 2020-12-05 19:24:56 +01:00
Elvis Angelaccio c453393d35 Fix PlacesItemModelTest, 2nd try
This partly reverts 15a5189b11

The KDE CI does not have KDE_FULL_SESSION set, which means that KIO
doesn't add the recentlyused:// urls to the model, but defaults to the
old timeline:// urls instead.

In both cases KIO adds 2 places, so it is safe to always assume that the
expected model count is 14.
2020-12-05 19:15:51 +01:00
Elvis Angelaccio bc3e77d2ef Drop obsolete KF5 version check
We depend on 5.77 now.
2020-12-05 18:39:45 +01:00
Elvis Angelaccio c4a1903dd1 Add missing const 2020-12-05 16:58:04 +01:00
Ahmad Samir 1d64b9bb10 DolphinView: set the parent of layout in the ctor
This silences a runtime warning:
QLayout: Attempting to add QLayout "" to DolphinView "", which already
has a layout

Remove redudant setLayout() calls, passing a parent widget to the
Q*BoxLayout ctor sets that layout as the top-level layout for that widget.
2020-12-03 19:50:04 +00:00
Christoph Feck 9b8ac3ef3f GIT_SILENT Update Appstream for new release 2020-12-02 23:01:21 +01:00
Christoph Feck 16ec949f35 GIT_SILENT Update Appstream for new release
(cherry picked from commit 9b8ac3ef3f)
2020-12-02 23:01:21 +01:00
Méven Car 60b9eaa4c1 Toolbar: move and rename filter to edit menu above Search
This is to expose more filter.
Also rename "Show Filter Bar" to simply "Filter", keep "Show Filter Bar" as tooltip

Adds a toggle filter bar action.
2020-12-02 07:07:41 +00:00
Nate Graham ce11325115 Merge branch 'release/20.12' 2020-11-30 17:08:46 -07:00
Méven Car c2a7bde383 Re-allow to paste files via context menu
BUG: 429762
2020-11-30 22:18:48 +01:00
Alexander Lohnau dbf0f645d2 Utilize KFileItemActions::addActionsTo method from KIO 2020-11-29 14:34:07 +00:00
Nicolas Fella 94c1fe6299 Remove unused includes 2020-11-29 15:03:27 +01:00
Carson Black ad9c955835 [kitemlistview]: Animate rubberband fading out 2020-11-28 21:11:44 +00:00
Nate Graham 78c7429a35 Add placeholder text for empty views
Throughout our QML-based software, we now display placeholder text for
empty views so that the user knows that the view is actually empty, and
it's not that the software is just broken.

This commit introduces the same thing for Dolphin's main view.

BUG: 429248
BUG: 426354
FIXED-IN: 21.04
2020-11-28 19:06:28 +00:00
Friedrich W. H. Kossebau ac862c8e2d ui.rc files: consistenly use <gui> instead of deprecated <kpartgui> 2020-11-28 10:28:53 +01:00
Nate Graham 31528188c1 Merge branch 'release/20.12' 2020-11-24 13:53:33 -07:00
Nate Graham bcdb1957af Allow the openURLJob to run executables
Otherwise, excecutable files like AppImages won't be allowed to launch
even if they are correctly marked as executable.

BUG: 429603
FIXED-IN: 20.12
2020-11-24 13:47:48 -07:00
Derek Christ 9e4642d435 Fix delete action switching via 'Shift' when sub-context-menu is open
Switching the 'Move to Trash' action to 'Delete' using the shift key
does not work when the mouse hovers a submenu. This fix resolves the
issue by using an event filter instead of the key event functions.

BUG: 425997
2020-11-23 22:07:31 +00:00
Alexander Lohnau c3b238bbe9 Move repetitive contextmenu related logic in one place
This makes a bit easier to handle the stuff.
Also we don't need the `addVersionControlPluginActions` utility method
and we can put it in the new utility method instead.
2020-11-23 21:58:36 +00:00
Felix Ernst b62095950a Merge branch 'release/20.12' 2020-11-23 13:38:22 +01:00
Méven Car 2cd1c07cad Places panel: highlight place only when it is displayed
BUG: 156678
FIXED-IN: 20.12
2020-11-23 00:02:59 +00:00
Elvis Angelaccio d5a4835f01 PlacesItemModelTest: consider also Pictures/Music/Videos folders
See a371e23b2b667bc85c311d04549f3d7348d00af5 in kio.
2020-11-23 00:40:53 +01:00
Elvis Angelaccio a218b2ce51 PlacesItemModelTest: use helper method to increase indexes
Instead of duplicating the logic all over the place.
2020-11-23 00:36:50 +01:00
Mufeed Ali 4f8c8955b9
Rename 'Url Navigator' to 'Location Bar' 2020-11-22 18:06:37 +05:30
Alexander Lohnau 3b74e4a3ab Remove unneeded version check 2020-11-22 08:42:18 +01:00
Alexander Lohnau 48fec6c9ec Add 'Open Terminal Here' action from dolphin to menu 2020-11-21 20:22:16 +00:00
Felix Ernst 760700819c Select last visited folder when going up/back
This commit fixes a regression introduced by
ad5d3367c7. A lot of connections were
changed there and at least one of them was wrong. The connections can
be separated into GUI connections and internal ones. This commit makes
it so the GUI stuff is connected to m_urlNavigatorConnected and
everything else to m_urlNavigator.

BUG: 429097
2020-11-21 18:24:24 +00:00
l10n daemon script 6171e08eaf GIT_SILENT made messages (after extraction) 2020-11-21 08:23:19 +01:00
Nate Graham f46e630dda Merge branch 'release/20.12' 2020-11-20 11:32:49 -07:00
Méven Car b3c37507dc Re-allow icons that are not theme icon
Particularly concerned are .desktop files.

See also:
15baa93640

BUG: 429113
2020-11-19 21:48:15 +00:00
Felix Ernst 50ca5af7e0 Allow having the UrlNavigators below the tab bar
This commit restores the possibility to have the UrlNavigators below
the tab bar. This will happen automatically whenever the UrlNavigator
is removed from the toolbar.

It is also now again possible to have the toolbar on the side. This
option is disabled while the toolbar contains the UrlNavigators.

This commit makes no changes to the new default which is having the
UrlNavigators in the toolbar but makes sure that upgrading users won't
be affected.
2020-11-19 21:22:27 +00:00
Alexander Lohnau 154843406d Different icon to launch Konsole terminal 2020-11-18 18:59:04 +00:00
Nate Graham b76cc3f6fa Separate Delete/Move To Trash menu items in context menu
Right now these actions are in a visual group with "Rename" and "Add to
Places" which is silly as those actions have no logical connection
whatsoever to deletion.

This commits moves those items into the section above, putting them in a
more logical place and leaving the Delete/Move To Trash item in its own
section.

BUG: 429256
FIXED-IN: 21.04
2020-11-17 22:21:19 +00:00
Elvis Angelaccio b03607b20b Add missing kconfig_version.h include
This should have been part of edced8460b.
2020-11-17 22:54:22 +01:00
Nate Graham e636bae43e Correct indentation and whitespace in prior commit 2020-11-17 09:40:05 -07:00
Domenico Panella edced8460b Allow folder creation on desktop via F10 shortcut 2020-11-17 16:18:54 +00:00
Nate Graham a3c0a822ca Merge branch 'release/20.12' 2020-11-16 10:26:04 -07:00
Méven Car f2d2f325b6 PlacesPanel: tooltip, use toLocalFile instead of path
To avoid Windows compatiblity issues.
2020-11-16 06:59:59 +01:00
Elvis Angelaccio 8fd0d685a6 Merge branch 'release/20.12' 2020-11-15 22:46:34 +01:00
Felix Ernst 8999580e2a Increment kpartgui version
The defaults changed in 37327c9b0a but
I forgot to also bump the kpartgui version so this commit rectifies
that.
2020-11-15 15:21:44 +01:00
Méven Car 5c99790c94 Context Menu: Only add paste action to folders
Either the viewport, or the selected folder is used as destination.
The paste action is only added when enabled.
2020-11-14 20:28:01 +01:00
l10n daemon script 2bfe601272 GIT_SILENT made messages (after extraction) 2020-11-14 02:37:30 +01:00
Felix Ernst 4f645f1b29 Fix navigator alignment for right-to-left localizations 2020-11-13 11:29:54 +01:00
Alexander Lohnau 1208f86696 Fix qrc icon
Apparently the icon was not null, because the mimetype was known.
But there was no icon associated with it and we got an
icon which is not null, but has a null pixmap.
2020-11-12 17:16:50 +01:00
Alexander Lohnau 208d733ae3 Set empty value for packagekit transaction flags
Otherwise the value would be Trusted Only, which will
forbid installing local packages
2020-11-12 17:15:01 +01:00
Méven Car 6b1524e4ff Places panel: show a tooltip after 500 ms
BUG: 426455
FIXED-IN: 20.12
2020-11-10 08:04:15 +00:00
Felix Ernst 63f4981fe0 Adress the third round of Angelaccio's review comments
Additionally remove some redundant code concerning UrlNavigator visuals.
2020-11-09 23:49:07 +01:00
Felix Ernst 2d4d2ce9a1 Adress most of the second round of Angelaccio's review comments
This commit applies most suggestions which were made on the MR.
Most notably the DolphinUrlNavigator class is split up which leads to
the creation of a DolphinUrlNavigatorsController class.

Additionally some minor coding style and const correctness changes are
included.

The error value of cached integers is changed from -1 to INT_MIN
because situations could come up in which -1 would be a valid value.
2020-11-09 23:49:07 +01:00
Felix Ernst 4202383137 Apply Méven Car's suggestions 2020-11-09 23:49:07 +01:00
Felix Ernst a418d6229e Fix a crash and extract unrelated changes
The secondary UrlNavigator is now created when and only when:
- split view mode is activated for the active tab
OR
- switching to a tab that has split view already enabled.
This fixes a crash that occurs when the setting to always start in
split view mode is enabled.

An animation for activating split view is also removed from this and
moved into a separate MR. Another unrelated name change left over from
a previous commit (viewContainers() -> activeViewContainers()) is
dropped.
2020-11-09 23:49:07 +01:00
Felix Ernst 37327c9b0a Make UrlNavigators in the toolbar the only option
The UrlNavigators will be automatically added to the toolbar. The Sort By
action is removed from the default toolbar to make space.

Remove all options to have UrlNavigators outside the toolbar and remove
those code paths.

Make it so the new NavigatorsWidgetAction contains two UrlNavigators when
in split view mode. Spacing was also added to align these UrlNavigators
with the ViewContainers when enough space is available.

Force the toolbar to be either at the top or bottom of the window.

Set a sane sizeHint for DolphinUrlNavigator. It would be better to do this
in KUrlNavigator in the future.

This commit also contains a changes which should be moved to a separate
merge requests before this gets merged:
- Add an expansion animation when split view is enabled by the user
2020-11-09 23:49:07 +01:00
Felix Ernst 6151a7aec0 Add the UrlNavigator to the toolbar automatically if needed
This commit adds the DolphinUrlNavigatorWidgetAction::addToToolbarAndSave()
method which changes the users toolbar configuration to contain an
Url Navigator. This way the user doesn't need to do anything manually.

Aside from that a bunch of minor fixes like renaming and reordering
2020-11-09 23:49:07 +01:00
Felix Ernst b6fc58c3c3 Adress the first round of Angelaccio's review comments
- Split the viewContainers(bool includeInActive) into two methods
    without parameters
- Prevent users from accidently hiding all Url Navigators by
    preventing the dangerous action and then displaying a helpful
    message instead
Unrelated to review comments: Remove a useless line of code
2020-11-09 23:49:07 +01:00
Felix Ernst 00abc6d280 trailing whitespaces 2020-11-09 23:49:07 +01:00