Commit graph

827 commits

Author SHA1 Message Date
Cheong Lau
cfc7ee69b7
Merge branch 'pop-os:master' into item-display-name 2025-11-12 01:57:18 +00:00
Cheong Lau
cd6187433d fixup! chore: more pedantic clippy suggestions
This fixes an accidental change that converted images to `rgb8` instead
of `rgba8`, which silently broke thumbnail rendering.

fixes: 5f729829d7
2025-11-08 14:45:38 +10:00
Cheong Lau
5aa8a8ff76
Merge branch 'pop-os:master' into item-display-name 2025-11-05 22:49:34 +00:00
Vukašin Vojinović
2ba08c4928 chore: update dependencies
This adapts to the changed context drawer actions API.
Also simplifies the actions code.
2025-11-05 15:26:02 -07:00
Cheong Lau
9f680251ab
Merge branch 'master' into item-display-name 2025-10-29 04:46:23 +00:00
Cheong Lau
bd1fa1f0a9 perf: general minor performance optimisations
Notably there is some code cleanup with the zooming functionality, I've
created a new module to reduce code duplication.
2025-10-29 08:16:50 +10:00
Cheong Lau
5f729829d7 chore: more pedantic clippy suggestions 2025-10-29 08:10:19 +10:00
Cheong Lau
2eaad6088a perf: optimise tab::folder_name
This was done by separating out the function to get the display name
into its own function, then running just that.
2025-10-28 17:13:22 +10:00
Cheong Lau
c0736400e4
Merge branch 'pop-os:master' into rustc-hash 2025-10-28 03:12:10 +00:00
Jeremy Soller
419516863c
Merge pull request #1311 from pop-os/joshmegnauth-dialog-escape
dialog escape
2025-10-23 09:34:13 -06:00
Cheong Lau
78f2ed2bdd
Merge branch 'master' into rustc-hash 2025-10-23 11:24:01 +00:00
Ashley Wulber
a2f81cdcf0 refactor: capture Escape in subscription
If the event status of a key event is captured by a widget, the libcosmic tab subscription will ignore it, but we can manually capture it in cosmic-files for its dialogs and handle it ourselves. Alternatively, the subscription could capture events regardless of status, and include it as an argument to on_escape.
2025-10-22 15:04:49 -04:00
Josh Megnauth
1a465ffd7a Close dialog on esc if text input is focused
Closes: pop-os/cosmic-edit#350

Escape unfocusses the main text input widget instead of closing the
dialog. The user has to hit escape twice to close the window. It's not a
big deal, but it's also unexpected and unergonomic.
2025-10-22 14:51:22 -04:00
Ashley Wulber
d9b35a4612 chore: update libcosmic 2025-10-22 14:21:46 -04:00
Ashley Wulber
90d705dd52 chore: update libcosmic and use custom IDs
fixes #1087
2025-10-22 14:10:15 -04:00
Ashley Wulber
ee550266c6 chore: focus empty trash and mount error buttons 2025-10-22 14:10:15 -04:00
Ashley Wulber
e6da0a8ae5 chore: focus replace & favorite path dialog buttons 2025-10-22 14:10:15 -04:00
Ashley Wulber
ce207a54b3 chore: set executable and launch dialog confirm button 2025-10-22 14:10:15 -04:00
Ashley Wulber
7be73d584d chore: focus open with dialog confirm button 2025-10-22 14:10:15 -04:00
Ashley Wulber
6615e0a2b7 fix: focus button for permanently delete dialog 2025-10-22 14:10:15 -04:00
Gwen Lg
423d5d1054 enable ovelap variable on features 2025-10-21 01:02:28 +02:00
Jeremy Soller
0b9cf4397f
Merge pull request #1303 from pop-os/fix-applet-keypress
fix: check surface_ids for keypress
2025-10-20 14:19:16 -06:00
Ashley Wulber
24b28a3703
fix: check surface_ids for keypress 2025-10-20 16:17:19 -04:00
Jeremy Soller
704ff6ad4f
Unhighlight all items when config changes, fixes #1139 2025-10-20 14:16:03 -06:00
Jeremy Soller
e2c446b73a
Fix shift click sorting when items sorted by name, fixes #1135 2025-10-20 14:03:45 -06:00
Cheong Lau
43a9fca4ec perf: use rustc-hash for HashMap and HashSet
Since we already depend on `rustc-hash` transiently, this doesn't add
any more dependencies. As long as DOS attacks aren't a concern (which I
don't think they are?), this should be free performance.

In my (admittedly naive) testing, this really improved CPU usage in some
cases, which is pretty nice to get for free.
2025-10-19 08:46:12 +10:00
Cheong Lau
f16981020b fix: avoid background process when last tab closed
The current behaviour leaves the process running in the background.
Instead, send a `Message::WindowClose` which properly closes the window.
2025-10-16 13:03:07 +10:00
Jeremy Soller
2e103dd4eb
Update dependencies and format 2025-10-14 11:18:23 -06:00
Jeremy Soller
4312179a4d
Allow type to enter path to select files in dialog 2025-10-14 11:16:37 -06:00
Jeremy Soller
9e8fb60b70
Implement type to search in dialog, fixes #965 2025-10-14 10:57:36 -06:00
Jeremy Soller
17b99cd9a6
Merge pull request #1280 from Cheong-Lau/replace-arc
perf: use `Rc<RefCell>` for `ArcElementWrapper`
2025-10-12 20:26:48 -06:00
Cheong Lau
f78d4a4b4f perf: use Rc<RefCell> for ArcElementWrapper
Since `Element` isn't `Sync` and `ArcElementWrapper` doesn't need to be
sent across threads, the overhead from using `Arc<Mutex>` isn't really
needed. Using an `Rc<RefCell>` has the same effect, but is faster and
isn't thread-safe.
2025-10-13 10:13:01 +10:00
Cheong Lau
0093562e46 fix: avoid leaving zombie processes on unix
In `spawn_detached()`, the spawned process isn't waited on, which makes
zombie processes. This is fixed by calling `wait()` on the `Child`.

While this isn't done in the original function taken from the `open`
crate, it is done in `Alacritty`'s implementation, which is what the
author of `open` based the function on anyway.
2025-10-12 17:04:54 +10:00
Jeremy Soller
5a326b6ff1
Merge pull request #1270 from jasonrhansen/location-context-menu-fix
Fix location context menu
2025-10-10 08:34:34 -06:00
Jason Rodney Hansen
7362e8924c When navbar context menu is opened, close all others 2025-10-09 19:59:27 -06:00
Jason Rodney Hansen
d9d5a6fe3d Fix location context menu 2025-10-09 19:17:55 -06:00
Ashley Wulber
20ea5a2a5c
fix(desktop applet): overlaps 2025-10-09 17:19:18 -04:00
Jeremy Soller
7d5fb79f02
Handle single click to open on release, fixes #1212 2025-10-09 13:52:41 -06:00
Jeremy Soller
f9f27765c7
Always set maximum scrollable height for open with dialog, fixes #1229 2025-10-09 13:41:39 -06:00
Jeremy Soller
52d0586a1b
Merge pull request #1248 from therealmate/image
fix: use the dimension of the image instead of the thumbnail's dimension
2025-10-09 13:24:35 -06:00
therealmate
c7ee1c9ae1 fix: update modifier state for all windows, not just the main window
Fixes https://github.com/pop-os/cosmic-files/issues/1152
2025-10-05 23:44:23 +02:00
Vukašin Vojinović
d788fe2421 perf(zip): don't call sync_all() on every file
Calling it on every file massively slows down extraction of zip archives containing a lot of files.
Yields a ~60x time reduction for extracting a zipped folder containing 10,000 empty txt files.

From what I can find, Ark also doesn't seem to do this, and instead relies on the OS to handle it.
2025-10-05 23:42:30 +02:00
therealmate
23dd824746
fix: use the dimension of the image instead of the thumbnail's dimension
Fixes https://github.com/pop-os/cosmic-files/issues/1244
2025-10-05 22:50:56 +02:00
Vukašin Vojinović
909577b364 chore: clippy 2025-10-03 14:36:00 -04:00
Vukašin Vojinović
4a4d5c0a9e chore: update dependencies
Also removes the license crate patch.
2025-10-03 14:36:00 -04:00
Jeremy Soller
942a7f47d3
Ensure task to remove desktop dialogs is run, fixes #1185 2025-09-16 14:13:04 -06:00
Vukašin Vojinović
901bf3f564 chore: update to icu 2.0.0 2025-09-15 15:20:33 -06:00
Vukašin Vojinović
11b6a0713f chore: link desktop appearance to desktop page 2025-09-13 10:51:14 -06:00
Vukašin Vojinović
131cf7e8cd chore: make dbus-config optional
Also fixes some lints.
2025-09-13 10:51:14 -06:00
Vukašin Vojinović
f0cce9a81f fix(desktop): header bar styling
This effectively reverts commit 19c2cefd8a.
The changes don't seem to be necessary anymore. and this ensures the header bar matches the theme.
2025-09-11 08:15:26 -06:00