This is a fix for a bug where in network views (or otherwise slow
systems), pressing `Ctrl+Shift+N` multiple times opens multiple popup
windows and thus causes a crash when any of the popups is interacted
with after closing the topmost one. The problem is not the crash with
popups themselves, but that we're opening multiple popups in the first
place.
In regular views this works fine, since the `nameJob` does not take
long time at all and only one popup opens, immediately blocking the
shortcut.
In network views, the `nameJob` seems to take a while to run, since it
is loading info from network. If user spams `Ctrl+Shift+N` shortcut in
frustration, it starts more `nameJob`s and eventually when those jobs
are done, it opens multiple popups.
This code checks that if we're already running a `namejob`, we're very
likely waiting for the `createDir` popup to appear, so we don't do
anything until there is no more `nameJob` running.
I've tested that it works in both network and regular Dolphin views.
BUG:481401
This is needed or they definitely won't feature us.
The light blue color is chosen because it is vibrant and fits the
association with "Dolphin". The very dark color is chosen to still have
a good contrast with the Dolphin icon even though it is already quite
dark at the top left corner.
For more information see:
https://docs.flathub.org/blog/introducing-app-brand-colors/
This prevents a crash on startup where it tries to delete a null
QShortcut because it didn't check if the QShortcut actually exists in
the QHash.
BUG: 485089
This is a partial revert of
5186f09cab. That commit tried to
simplify code, however this lead to the saving of view properties
being skipped, introducing the linked bug.
The issue is that by the time the slotSortRoleChangedFromHeader()
method is called, the model already changed its sort role.
Therefore the check if the new role is identical to the old sort
role fails and no saving would occur.
With this partial revert the header will continue to change the
sort role itself (which allows a minor optimization of not double
sorting when also changing the sort order at the same time). The
method slotSortRoleChangedFromHeader() is then only responsible
for saving that change in the ViewProperties and telling the
SortBy menu in the user interface that the sorting has changed.
BUG: 480246