Skip to content

App icon categories with drag-and-drop grouping#2579

Open
db0x wants to merge 36 commits intomicheleg:masterfrom
db0x:master
Open

App icon categories with drag-and-drop grouping#2579
db0x wants to merge 36 commits intomicheleg:masterfrom
db0x:master

Conversation

@db0x
Copy link
Copy Markdown

@db0x db0x commented Apr 23, 2026

feat: App icon categories with drag-and-drop grouping

Adds a lightweight category system to the dock — no settings required.

What it does

  • Create a category by dragging one app icon onto another; the two collapse into a single category icon
  • Reorder apps within a category via drag-and-drop
  • Dissolve a category automatically when all but one app is removed from it
  • Categories are purely runtime — no configuration UI, no schema changes

Also included

  • Fix timing issue for apps with non-standard WM_CLASS (e.g. emulators): a window-created listener with a short delay supplements app-state-changed to ensure reliable app detection

Note

This feature was developed with the assistance of AI (Claude by Anthropic). While functional, the implementation likely needs review and refinement in several areas — feedback and improvements are very welcome.

db0x and others added 30 commits March 29, 2026 11:32
- show() before ensure_style()/_reposition() so get_preferred_size() returns correct values
- position-aware _reposition() for all 4 dock sides (bottom/top/left/right)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Rename all identifiers, GSettings keys, and UI widget IDs from the
custom-icon/CustomApp namespace to category-icon/CategoryIcon to better
reflect the feature's purpose (filtering apps by desktop category).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Replace the single category icon (5 individual GSettings keys) with a
JSON array key 'category-icons', where each entry holds name, label,
category and position. DockManager now manages a _categoryIcons[]
array, updating or recreating instances on config changes.

The preferences UI (Launchers tab) gets a fully dynamic list: each icon
shows an inline label, icon-name entry and category dropdown, plus a
remove button. An "Add Category Icon" button appends a new entry.
External GSettings changes (e.g. from the dock itself) also update the
list, with a _writingFromUI guard to prevent rebuild loops on UI edits.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@alooflishan-sys
Copy link
Copy Markdown

Skipping drag target: Error: GSettings key user-categories not found in schema org.gnome.shell.extensions.dash-to-dock

                                           Stack trace:
                                             _checkKey@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:857:23
                                             createCheckedMethod/<@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:807:30
                                             _writeUserCategories@file:///home/vela/.local/share/gnome-shell/extensions/dash-to-dock@micxgx.gmail.com/docking.js:1850:24
                                             createUserCategory@file:///home/vela/.local/share/gnome-shell/extensions/dash-to-dock@micxgx.gmail.com/docking.js:1864:14
                                             acceptDrop@file:///home/vela/.local/share/gnome-shell/extensions/dash-to-dock@micxgx.gmail.com/dash.js:585:29
                                             _dragActorDropped@resource:///org/gnome/shell/ui/dnd.js:422:49
                                             _onEvent@resource:///org/gnome/shell/ui/dnd.js:582:18
                                             _getEventHandlerActor/<@resource:///org/gnome/shell/ui/dnd.js:48:37
                                             @resource:///org/gnome/shell/ui/init.js:20:20

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants