Le patch yoda 5b838a67 est conserve (il initialise les plafonds sink ET
source, contrairement au code inline amont) mais il est desormais dans
une closure recevant `app: &mut Self` : l appel sur `self` ne compilait
plus.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Menu items expose their icon as a themed `icon-name` or raw PNG `icon-data`. The named-icon branch renders at a fixed `.size(14)`, but the icon-data branch wrapped the pixmap in a bare `Image` with no size constraint, so it rendered at the PNG's native dimensions. Apps may send full-resolution pixmaps, which then render oversized in the menu.
Constrain icon-data to the same 14px box with ContentFit::Contain, matching how KDE (Qt small-icon size) and GNOME (St.Icon popup-menu-icon) render menu item icons.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
cosmic-settings 1.3 replaced its custom NetworkManager backend with nmrs
and removed subscriptions/network-manager, which cosmic-applet-network
still referenced by path. That broke manifest resolution for the whole
workspace, so no applet package could be built at all.
Take upstream's post-migration cosmic-applet-network wholesale (upstream
e318f0d4 "migrate NetworkManager flow to nmrs 3.4" plus the nine network
fixes that followed it). None of our local commits touched this crate's
sources, only its manifest, so the only local adjustments to reapply are
the libcosmic -> cosmic workspace alias and the 1.3.0 version.
This also drops the cosmic-dbus-networkmanager dependency, and with it
the last user of the now-dead cosmic-settings-network-manager and
cosmic-settings-sound patch entries, which are removed from the
workspace manifest.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
max_sink_volume and max_source_volume were only computed in the
TogglePopup handler, so they kept their Default value of 0 until the
popup had been opened once. The scroll-to-adjust handler clamps against
max_sink_volume, which meant every wheel event resolved to
SetSinkVolume(0) until the user had clicked the applet icon: scrolling
up did nothing and scrolling down muted the sink.
Extract refresh_volume_limits() and call it from init() as well as from
TogglePopup, so the popup still picks up amplification config changes
made during the session.
This is the actual cause of "scroll does not adjust volume until the
applet is clicked once" — the wheel events were reaching the widget all
along, which is why a single click made scrolling work on plain hover
from then on.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Move the on_mouse_wheel handler before the cursor.is_over(bounds)
guard. The panel's nested compositor only routes axis events to the
applet surface when the pointer is over it, making the bounds check
redundant for scroll events. This fixes scroll-to-adjust-volume not
working on the audio applet after a fresh login, when the cursor
coordinates sent by the panel may not match the applet's surface-local
coordinate space.
`update_xkb()` was previously never called before the subscription first
returns a config value, so not getting an initial value of `comp_config`
at start before the subscription does not change behavior.
https://github.com/pop-os/cosmic-protocols/pull/28
Continues to use `xkg_config` to get list of layouts, but the group is
now changed by modifying the group while leaving the config unchanged.
And changes to the group are now reflected in the applet.
Track VPN activation and deactivation locally while nmrs operations are
running. This lets the applet show a spinner immediately, refresh state
while NetworkManager settles, and clear pending state on completion or
error.
Also use VPN-specific icons for VPN rows and prefer active or pending VPN
state for the panel icon.
Only mark an nmrs Wi-Fi group as activated when the group itself is
active. Access points inherit device state, so inactive known networks on
a connected Wi-Fi device can otherwise appear activated and get skipped
from the known networks section while also being filtered out of visible
networks.
- Strip the CIDR suffix (/24) from the shown IPv4 address
- Sort visible wireless networks by signal strength again
- Filter out empty-SSID "hidden network" entries from the list
Fixes a bug where we showed `Activated` networks after the current active
one.
Also ipv4/6 addresses were merged so this seperates them and only shows ipv4
for now until we decide the best way to show both, UI/UX wise.
Avec Wayland axis_v120 (scroll haute-résolution sur souris HID modernes),
un cran physique génère 5–8 events ScrollDelta::Pixels (~15–20px chacun).
L'ancien code passait chaque sub-event par .signum() puis -1/+1 à sink_volume,
donc un seul cran physique faisait varier le volume de 5 à 40% — résultat :
scroll up sur l'icône audio panel / dock coupait le son si le volume était
déjà bas.
Fix : thread_local accumulator des deltas Pixels, émission seulement
au passage du seuil de 15px par cran logique. Lines (souris classique
sans axis_v120) reste proportionnel y * WHEEL_STEP. round() au lieu de
truncation finale pour ne pas perdre les fractions de pourcent.
Leyoda 2026 - GPLv3
Replace 3 panicking unwrap() in cosmic-app-list/wayland_handler.rs
(event loop dispatch + 2 conn.flush in screencopy) with logged
errors that break/return None instead.
Wrap cosmic-applets/main.rs entry point in panic::catch_unwind to
catch panics propagating from libcosmic/iced/winit (which we cannot
patch locally without forking) when the COSMIC compositor closes
the Wayland connection at logout. This eliminates the cascade of
~12 SIGABRT coredumps observed at session shutdown.
Panic strategy is unwind (default), catch_unwind is sound here.
Leyoda 2026 – GPLv3
Inter-icon hover changes were snapping because icon_scale_for read the
hovered icon's real rectangle directly. This adds a small animation
layer so the bell center lerps toward the target and the whole effect
fades in/out at the dock's edges.
CosmicAppList gains three fields:
- anim_hover_center: Option<(f32, f32)> — virtual cursor position,
chases the hovered icon's center across ticks.
- anim_hover_intensity: f32 (0..1) — global fade-in/out of the
fisheye. Target 1.0 while a dock icon is hovered, 0.0 otherwise.
- anim_last_tick: Option<Instant> — for dt-based exponential smoothing
(time-constant tau = 60ms, ~99% of target reached in ~120ms).
A new Message::AnimTick(Instant) is emitted at ~60 fps by a
conditional iced::time::every subscription — only active when the
pointer is over a dock icon OR intensity hasn't faded back to ~0 yet,
so the panel stays idle when no one is hovering the dock.
icon_scale_for now reads anim_hover_center instead of rectangles[hovered]
and multiplies the bell's peak by anim_hover_intensity. Behaviour:
- Pointer slides A → B: bell glides continuously, both icons animate.
- Pointer enters dock: icons inflate smoothly over ~120 ms.
- Pointer leaves dock: icons deflate smoothly over ~120 ms.
Fallback paths (first frame, missing rectangles) still respond
instantly so the feature never looks 'stuck' before the animation
kicks in.
Replaces the binary 1.3× hover with a true gaussian bell curve — the
hovered icon still peaks at ~1.35×, but the ±1 neighbours also bulge
noticeably, ±2 a bit, and ±3+ relax to 1.0×. Footprint ~5 icons wide,
matching the macOS Dock fisheye feel.
Implementation in fn icon_scale_for(id):
- Reads the hovered icon's and the current icon's bounds from
self.rectangles (already populated by the existing RectangleTracker
subscription — no new plumbing).
- Distance = |this_center - hovered_center| along the panel's long axis
(horizontal for Top/Bottom anchors, vertical for Left/Right).
- sigma = hovered_extent * 1.4 so the bell's half-width matches one
icon width (neighbors clearly pulled, far icons untouched).
- scale = 1.0 + PEAK * exp(-(d/sigma)²) with PEAK = 0.35.
- Falls back to binary 1.35×/1.0× when rectangle data isn't populated
yet (first render / resize) — visibly responsive even before the
tracker catches up.
No widget signature changes vs v1, just a smarter formula. All five
as_icon call sites already pass the result of icon_scale_for so this
update propagates everywhere.
Still on the TODO list: smooth animation (b). Right now icon→icon
transitions snap instantly; a smoothed_hover_center + tick subscription
would lerp it. Deferred to a follow-up commit.
First pass at the signature macOS Dock effect — the icon under the
pointer grows, adjacent icons stay at base size. Full fisheye (smooth
bell-curve scaling on neighbors) can be a later iteration.
Changes in cosmic-app-list/src/app.rs:
- CosmicAppList gains a hovered_dock_item: Option<DockItemId>
auto-initialized to None via #[derive(Default)].
- New Message::DockItemHover(Option<DockItemId>) handled in update()
by just writing the field; view() then reads it to decide scale.
- DockItem::as_icon gains an icon_scale: f32 parameter. Inside it the
cosmic_icon width/height = (base_icon_size * icon_scale) clamped
to u16; indicator dot and other surrounding layout stay at base
size so only the icon visually bulges.
- New App::icon_scale_for(id) helper: 1.3 if Some(id) == hovered,
1.0 otherwise. Single place to tune the magnification factor.
- The two main dock rows (favorites + filtered_active_list) wrap
their rendered applet_tooltip in widget::mouse_area with
on_enter(DockItemHover(Some(id))) / on_exit(DockItemHover(None))
and call icon_scale_for before rendering.
- The three remaining as_icon call sites (DnD preview, favorites
overflow popup, active overflow popup) pass icon_scale = 1.0 —
hover magnification on those surfaces would look jittery and isn't
needed anyway.
Build: cargo build --release -p cosmic-app-list (≈ 7s). Binary
installed at /usr/local/bin/cosmic-app-list, backup kept as
.pre-magnification.