From ac7ef665a1eb583a9548edfdd065b8eff8696b30 Mon Sep 17 00:00:00 2001 From: Sam Hewitt Date: Wed, 15 Nov 2023 11:32:27 -0330 Subject: [PATCH] Use dedicated assets for ctrlAltTab Part-of: --- data/gnome-shell-icons.gresource.xml | 10 +- .../actions/shell-focus-app-grid-symbolic.svg | 4 + .../actions/shell-focus-dash-symbolic-rtl.svg | 7 + .../actions/shell-focus-dash-symbolic.svg | 7 + .../shell-focus-desktop-symbolic-rtl.svg | 9 + .../actions/shell-focus-desktop-symbolic.svg | 9 + .../actions/shell-focus-search-symbolic.svg | 4 + .../shell-focus-top-bar-symbolic-rtl.svg | 7 + .../actions/shell-focus-top-bar-symbolic.svg | 7 + .../actions/shell-focus-windows-symbolic.svg | 4 + data/org.gnome.Shell-symbolic.Source.svg | 272 ++++++++++++++---- js/ui/ctrlAltTab.js | 4 +- js/ui/dash.js | 2 +- js/ui/overviewControls.js | 4 +- js/ui/panel.js | 2 +- js/ui/searchController.js | 2 +- 16 files changed, 294 insertions(+), 60 deletions(-) create mode 100644 data/icons/scalable/actions/shell-focus-app-grid-symbolic.svg create mode 100644 data/icons/scalable/actions/shell-focus-dash-symbolic-rtl.svg create mode 100644 data/icons/scalable/actions/shell-focus-dash-symbolic.svg create mode 100644 data/icons/scalable/actions/shell-focus-desktop-symbolic-rtl.svg create mode 100644 data/icons/scalable/actions/shell-focus-desktop-symbolic.svg create mode 100644 data/icons/scalable/actions/shell-focus-search-symbolic.svg create mode 100644 data/icons/scalable/actions/shell-focus-top-bar-symbolic-rtl.svg create mode 100644 data/icons/scalable/actions/shell-focus-top-bar-symbolic.svg create mode 100644 data/icons/scalable/actions/shell-focus-windows-symbolic.svg diff --git a/data/gnome-shell-icons.gresource.xml b/data/gnome-shell-icons.gresource.xml index 272f43ceb..680cffced 100644 --- a/data/gnome-shell-icons.gresource.xml +++ b/data/gnome-shell-icons.gresource.xml @@ -21,6 +21,15 @@ scalable/actions/screenshot-ui-show-pointer-symbolic.svg scalable/actions/screenshot-ui-window-symbolic.svg scalable/actions/screenshot-recorded-symbolic.svg + scalable/actions/shell-focus-app-grid-symbolic.svg + scalable/actions/shell-focus-dash-symbolic.svg + scalable/actions/shell-focus-dash-symbolic-rtl.svg + scalable/actions/shell-focus-desktop-symbolic.svg + scalable/actions/shell-focus-desktop-symbolic-rtl.svg + scalable/actions/shell-focus-search-symbolic.svg + scalable/actions/shell-focus-top-bar-symbolic.svg + scalable/actions/shell-focus-top-bar-symbolic-rtl.svg + scalable/actions/shell-focus-windows-symbolic.svg scalable/status/background-app-ghost-symbolic.svg scalable/status/keyboard-brightness-high-symbolic.svg scalable/status/keyboard-brightness-medium-symbolic.svg @@ -37,4 +46,3 @@ scalable/status/screen-privacy-symbolic.svg - diff --git a/data/icons/scalable/actions/shell-focus-app-grid-symbolic.svg b/data/icons/scalable/actions/shell-focus-app-grid-symbolic.svg new file mode 100644 index 000000000..c0fbc6cce --- /dev/null +++ b/data/icons/scalable/actions/shell-focus-app-grid-symbolic.svg @@ -0,0 +1,4 @@ + + + + diff --git a/data/icons/scalable/actions/shell-focus-dash-symbolic-rtl.svg b/data/icons/scalable/actions/shell-focus-dash-symbolic-rtl.svg new file mode 100644 index 000000000..fcc795505 --- /dev/null +++ b/data/icons/scalable/actions/shell-focus-dash-symbolic-rtl.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/data/icons/scalable/actions/shell-focus-dash-symbolic.svg b/data/icons/scalable/actions/shell-focus-dash-symbolic.svg new file mode 100644 index 000000000..9fc75e971 --- /dev/null +++ b/data/icons/scalable/actions/shell-focus-dash-symbolic.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/data/icons/scalable/actions/shell-focus-desktop-symbolic-rtl.svg b/data/icons/scalable/actions/shell-focus-desktop-symbolic-rtl.svg new file mode 100644 index 000000000..b5008d99e --- /dev/null +++ b/data/icons/scalable/actions/shell-focus-desktop-symbolic-rtl.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/data/icons/scalable/actions/shell-focus-desktop-symbolic.svg b/data/icons/scalable/actions/shell-focus-desktop-symbolic.svg new file mode 100644 index 000000000..add7fbaef --- /dev/null +++ b/data/icons/scalable/actions/shell-focus-desktop-symbolic.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/data/icons/scalable/actions/shell-focus-search-symbolic.svg b/data/icons/scalable/actions/shell-focus-search-symbolic.svg new file mode 100644 index 000000000..c680c205c --- /dev/null +++ b/data/icons/scalable/actions/shell-focus-search-symbolic.svg @@ -0,0 +1,4 @@ + + + + diff --git a/data/icons/scalable/actions/shell-focus-top-bar-symbolic-rtl.svg b/data/icons/scalable/actions/shell-focus-top-bar-symbolic-rtl.svg new file mode 100644 index 000000000..3d3097ff3 --- /dev/null +++ b/data/icons/scalable/actions/shell-focus-top-bar-symbolic-rtl.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/data/icons/scalable/actions/shell-focus-top-bar-symbolic.svg b/data/icons/scalable/actions/shell-focus-top-bar-symbolic.svg new file mode 100644 index 000000000..7e7772413 --- /dev/null +++ b/data/icons/scalable/actions/shell-focus-top-bar-symbolic.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/data/icons/scalable/actions/shell-focus-windows-symbolic.svg b/data/icons/scalable/actions/shell-focus-windows-symbolic.svg new file mode 100644 index 000000000..fadcaf426 --- /dev/null +++ b/data/icons/scalable/actions/shell-focus-windows-symbolic.svg @@ -0,0 +1,4 @@ + + + + diff --git a/data/org.gnome.Shell-symbolic.Source.svg b/data/org.gnome.Shell-symbolic.Source.svg index 21bcfd8e5..0f02fdc0e 100644 --- a/data/org.gnome.Shell-symbolic.Source.svg +++ b/data/org.gnome.Shell-symbolic.Source.svg @@ -7,7 +7,7 @@ viewBox="0 0 64 64" id="svg2" version="1.1" - inkscape:version="1.2.2 (b0a8486541, 2022-12-01)" + inkscape:version="1.3 (0e150ed6c4, 2023-07-21)" sodipodi:docname="org.gnome.Shell-symbolic.Source.svg" xml:space="preserve" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" @@ -22,16 +22,16 @@ inkscape:pageopacity="1" inkscape:pageshadow="2" inkscape:zoom="1" - inkscape:cx="51.5" - inkscape:cy="258" + inkscape:cx="224.5" + inkscape:cy="258.5" inkscape:document-units="px" inkscape:current-layer="layer2" showgrid="false" units="px" - inkscape:window-width="1920" - inkscape:window-height="1011" + inkscape:window-width="2560" + inkscape:window-height="1531" inkscape:window-x="0" - inkscape:window-y="32" + inkscape:window-y="0" inkscape:window-maximized="1" inkscape:snap-bbox="true" inkscape:bbox-paths="true" @@ -55,7 +55,13 @@ color="#5e57ff" opacity="0.1254902" empcolor="#5e57ff" - empopacity="0.25098039" />keyboard-hide<path id="path955" style="fill:#241f31;fill-opacity:1" - d="m 187,470 v 6.00391 c 0.006,0.996 -1,0.99609 -1,0.99609 h -11.58594 l 1.29297,-1.29297 a 1,1 0 0 0 0,-1.41406 A 1,1 0 0 0 175,474 a 1,1 0 0 0 -0.70703,0.29297 l -3,3 a 1.0001,1.0001 0 0 0 0,1.41406 l 3,3 a 1,1 0 0 0 1.41406,0 1,1 0 0 0 0,-1.41406 L 174.41602,479 H 186 c 3.006,0 3,-3 3,-3 v -6 z" /></g></g><g + d="m 187,470 v 6.00391 c 0.006,0.996 -1,0.99609 -1,0.99609 h -11.58594 l 1.29297,-1.29297 a 1,1 0 0 0 0,-1.41406 A 1,1 0 0 0 175,474 a 1,1 0 0 0 -0.70703,0.29297 l -3,3 a 1.0001,1.0001 0 0 0 0,1.41406 l 3,3 a 1,1 0 0 0 1.41406,0 1,1 0 0 0 0,-1.41406 L 174.41602,479 H 186 c 3.006,0 3,-3 3,-3 v -6 z" /></g><g + id="g14" + transform="translate(-64,-6.3362101e-5)" + inkscape:label="on-screen keyboard keys"><title + id="title14">keyboard-hideactionscarousel-arrow-next<title id="title39373">pointer-secondary-click<title id="title39371">pointer-primary-click<title id="title39369">pointer-drag<title id="title39367">pointer-double-clickscreenshot-ui-areascreenshot-ui-displayscreenshot-ui-windowscreenshot-ui-windowshell-focus-windows<title id="title42423">screenshot-ui-show-pointerpreview-closepreview-closepreview-closecarousel-arrow-previous + style="fill:#241f31;fill-opacity:1" />shell-focus-dashshell-focus-app-gridshell-focus-searchshell-focus-top-barshell-focus-desktopshell-focus-dash-rtlshell-focus-top-bar-rtlshell-focus-desktop-rtl diff --git a/js/ui/ctrlAltTab.js b/js/ui/ctrlAltTab.js index 16becf19f..a802501b2 100644 --- a/js/ui/ctrlAltTab.js +++ b/js/ui/ctrlAltTab.js @@ -23,7 +23,7 @@ export class CtrlAltTabManager { this._items = []; this.addGroup(global.window_group, _('Windows'), - 'focus-windows-symbolic', { + 'shell-focus-windows-symbolic', { sortGroup: SortGroup.TOP, focusCallback: this._focusWindows.bind(this), }); @@ -95,7 +95,7 @@ export class CtrlAltTabManager { let icon = null; let iconName = null; if (windows[i].get_window_type() === Meta.WindowType.DESKTOP) { - iconName = 'video-display-symbolic'; + iconName = 'shell-focus-desktop-symbolic'; } else { let app = windowTracker.get_window_app(windows[i]); if (app) { diff --git a/js/ui/dash.js b/js/ui/dash.js index 3cdc0b5af..dac2a99a7 100644 --- a/js/ui/dash.js +++ b/js/ui/dash.js @@ -407,7 +407,7 @@ export const Dash = GObject.registerClass({ // Translators: this is the name of the dock/favorites area on // the bottom of the overview - Main.ctrlAltTabManager.addGroup(this, _('Dash'), 'user-bookmarks-symbolic'); + Main.ctrlAltTabManager.addGroup(this, _('Dash'), 'shell-focus-dash-symbolic'); } _onItemDragBegin() { diff --git a/js/ui/overviewControls.js b/js/ui/overviewControls.js index 29471ee6f..4eb6c92e6 100644 --- a/js/ui/overviewControls.js +++ b/js/ui/overviewControls.js @@ -398,7 +398,7 @@ class ControlsManager extends St.Widget { Main.ctrlAltTabManager.addGroup( this.appDisplay, _('Apps'), - 'view-app-grid-symbolic', { + 'shell-focus-app-grid-symbolic', { proxy: this, focusCallback: () => { this.dash.showAppsButton.checked = true; @@ -410,7 +410,7 @@ class ControlsManager extends St.Widget { Main.ctrlAltTabManager.addGroup( this._workspacesDisplay, _('Windows'), - 'focus-windows-symbolic', { + 'shell-focus-windows-symbolic', { proxy: this, focusCallback: () => { this.dash.showAppsButton.checked = false; diff --git a/js/ui/panel.js b/js/ui/panel.js index a15290771..9f4313b54 100644 --- a/js/ui/panel.js +++ b/js/ui/panel.js @@ -679,7 +679,7 @@ class Panel extends St.Widget { Main.layoutManager.panelBox.add_child(this); Main.ctrlAltTabManager.addGroup(this, - _('Top Bar'), 'focus-top-bar-symbolic', + _('Top Bar'), 'shell-focus-top-bar-symbolic', {sortGroup: CtrlAltTab.SortGroup.TOP}); Main.sessionMode.connect('updated', this._updatePanel.bind(this)); diff --git a/js/ui/searchController.js b/js/ui/searchController.js index 53a8cb863..532a6d3ed 100644 --- a/js/ui/searchController.js +++ b/js/ui/searchController.js @@ -86,7 +86,7 @@ export const SearchController = GObject.registerClass({ this._searchResults = new Search.SearchResultsView(); this.add_child(this._searchResults); - Main.ctrlAltTabManager.addGroup(this._entry, _('Search'), 'edit-find-symbolic'); + Main.ctrlAltTabManager.addGroup(this._entry, _('Search'), 'shell-focus-search-symbolic'); // Since the entry isn't inside the results container we install this // dummy widget as the last results container child so that we can