cloud storage client
git clone https://git.lucas.co/cce-cloud.git
fix: a single click on any launcher row activates it
Apps/Path popups gated pointer activation on `selected == prev_selected`:
click once to move the highlight, click the SAME row again to launch. A
single click on an unselected app therefore only re-highlighted, which reads
as the click doing nothing — and is invisible as a bug because Enter always
worked. Dmenu and switcher mode already activated on any click.
The gate is gone: the fuzzel on_event only reports presses it resolved to a
really-drawn row (scrollbar grabs and clipped-sliver presses are filtered
before and inside it), so the click IS the choice, exactly as Enter is.
Verified in a shadow session: a single click on an unselected row spawned the
app 0.21s later as a live daemon child, and killing it left no zombie —
re-exercising the reap fix from the previous commit on the way through.
src/main.rs | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/src/main.rs b/src/main.rs
index 4c6c9c1..e2062bf 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -1919,7 +1919,6 @@ impl PointerHandler for AppState {
st.upload_vertices();
self.redraw = true;
} else {
- let prev_selected = st.fuzzel.selected;
let changed = {
let ev = cce_ui::widget::Event::MouseButton {
button: cce_ui::widget::MouseButton::Left,
@@ -1934,7 +1933,15 @@ impl PointerHandler for AppState {
st.ui_context.propagate_event(&ev, root)
};
if changed {
- if st.fuzzel.selected == prev_selected || st.switcher_mode || st.mode == LauncherMode::Dmenu {
+ // Any row press activates. This used to gate on
+ // `selected == prev_selected` outside Dmenu/switcher
+ // mode — click-to-select, click-AGAIN-to-launch — so a
+ // single click on an unselected app only moved the
+ // highlight, which reads as the click doing nothing.
+ // The fuzzel on_event already resolved the press to a
+ // really-drawn row (scrollbar and clipped-sliver
+ // presses never get here), so the click IS the choice.
+ {
if let Some(item) = st.fuzzel.filtered_items.get(st.fuzzel.selected) {
println!("{}", item);
self.selected_item = Some(item.clone());