diff --git a/data/gnome-shell/pamac-updates@manjaro.org/extension.js b/data/gnome-shell/pamac-updates@manjaro.org/extension.js index 52c4cc28795cde8eec3bb6aa20462060c9cc0721..ab70553b90e7e46895dd2292fe7b6b7c6819b951 100644 --- a/data/gnome-shell/pamac-updates@manjaro.org/extension.js +++ b/data/gnome-shell/pamac-updates@manjaro.org/extension.js @@ -76,12 +76,18 @@ const PamacUpdateIndicator = new Lang.Class({ _updateList: [], _config: null, _pacman_lock: null, + _icon_theme: null, _init: function() { this.parent(0.0, "PamacUpdateIndicator"); - Gtk.IconTheme.get_default().append_search_path(Me.dir.get_child('icons').get_path()); + // Set icon theme + let that = this; + this._icon_theme = Gtk.IconTheme.get_default(); + this._icon_theme.connect('changed', function () { + that._icon_theme = Gtk.IconTheme.get_default(); + }); - this.updateIcon = new St.Icon({icon_name: "pamac-tray-no-update", style_class: 'system-status-icon'}); + this.updateIcon = new St.Icon({icon_name: "pamac-tray-no-update", icon_size: 20, style_class: 'system-status-icon'}); let box = new St.BoxLayout({ vertical: false, style_class: 'panel-status-menu-box' }); this.label = new St.Label({ text: '', diff --git a/data/icons/hicolor/16x16/status/package-available-locked.svg b/data/icons/hicolor/16x16/status/package-available-locked.svg new file mode 100644 index 0000000000000000000000000000000000000000..4d4e19197adf0ce12ca35f75c8444e6851c62c8e --- /dev/null +++ b/data/icons/hicolor/16x16/status/package-available-locked.svg @@ -0,0 +1,69 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + version="1.1" + viewBox="0 0 16 16" + id="svg8" + sodipodi:docname="package-available-locked.svg" + inkscape:version="0.92.2 2405546, 2018-03-11"> + <metadata + id="metadata14"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <defs + id="defs12" /> + <sodipodi:namedview + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1" + objecttolerance="10" + gridtolerance="10" + guidetolerance="10" + inkscape:pageopacity="0" + inkscape:pageshadow="2" + inkscape:window-width="792" + inkscape:window-height="480" + id="namedview10" + showgrid="false" + inkscape:zoom="14.75" + inkscape:cx="7.0564046" + inkscape:cy="8" + inkscape:window-x="403" + inkscape:window-y="85" + inkscape:window-maximized="0" + inkscape:current-layer="g6" /> + <g + transform="translate(0,-1036.3622)" + id="g6"> + <rect + style="fill:#e4e4e4;fill-opacity:1" + width="16" + height="16" + x="-1052.36" + y="-16" + rx=".8" + ry=".8" + transform="matrix(0,-1,-1,0,0,0)" + id="rect2" /> + <path + style="fill:#ffffff" + d="m 5,1041.3622 0,1.9998 -0.5000001,0 c -0.277,0 -0.5,0.223 -0.5,0.5 l 0,5 c 0,0.277 0.223,0.5 0.5,0.5 l 7.0000001,0 c 0.277,0 0.5,-0.223 0.5,-0.5 l 0,-5 c 0,-0.277 -0.223,-0.5 -0.5,-0.5 l -0.5,0 0,-1.9998 c 0,-2 -1,-2 -2,-2 l -2,0 c -1,0 -2,0 -2,2 z m 4,0 0,2 -2,0 0,-2 z" + id="path4" /> + </g> +</svg> diff --git a/data/icons/hicolor/16x16/status/package-available.svg b/data/icons/hicolor/16x16/status/package-available.svg new file mode 100644 index 0000000000000000000000000000000000000000..242dc3e12f5d53d114d68725b0130f69332716f8 --- /dev/null +++ b/data/icons/hicolor/16x16/status/package-available.svg @@ -0,0 +1,60 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + version="1.1" + viewBox="0 0 16 16" + id="svg6" + sodipodi:docname="package-available.svg" + inkscape:version="0.92.2 2405546, 2018-03-11"> + <metadata + id="metadata12"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + </cc:Work> + </rdf:RDF> + </metadata> + <defs + id="defs10" /> + <sodipodi:namedview + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1" + objecttolerance="10" + gridtolerance="10" + guidetolerance="10" + inkscape:pageopacity="0" + inkscape:pageshadow="2" + inkscape:window-width="792" + inkscape:window-height="480" + id="namedview8" + showgrid="false" + inkscape:zoom="14.75" + inkscape:cx="8" + inkscape:cy="8" + inkscape:window-x="0" + inkscape:window-y="0" + inkscape:window-maximized="0" + inkscape:current-layer="svg6" /> + <rect + style="fill:#e4e4e4" + width="16" + height="16" + x="-16" + y="-16" + rx=".8" + ry=".8" + transform="matrix(0,-1,-1,0,0,0)" + id="rect2" /> +</svg> diff --git a/data/icons/hicolor/16x16/status/package-install.svg b/data/icons/hicolor/16x16/status/package-install.svg new file mode 100644 index 0000000000000000000000000000000000000000..89cbdd74e9b7107c20a3bf2a20c5f20dd8002d0e --- /dev/null +++ b/data/icons/hicolor/16x16/status/package-install.svg @@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + version="1.1" + viewBox="0 0 16 16" + id="svg8" + sodipodi:docname="package-install.svg" + inkscape:version="0.92.2 2405546, 2018-03-11"> + <metadata + id="metadata14"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + </cc:Work> + </rdf:RDF> + </metadata> + <defs + id="defs12" /> + <sodipodi:namedview + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1" + objecttolerance="10" + gridtolerance="10" + guidetolerance="10" + inkscape:pageopacity="0" + inkscape:pageshadow="2" + inkscape:window-width="778" + inkscape:window-height="480" + id="namedview10" + showgrid="false" + inkscape:zoom="14.75" + inkscape:cx="8" + inkscape:cy="8" + inkscape:window-x="527" + inkscape:window-y="67" + inkscape:window-maximized="0" + inkscape:current-layer="g6" /> + <g + transform="translate(0,-1036.3622)" + id="g6"> + <rect + style="fill:#e4e4e4;fill-opacity:1" + width="16" + height="16" + x="-1052.36" + y="-16" + rx=".8" + ry=".8" + transform="matrix(0,-1,-1,0,0,0)" + id="rect2" /> + <path + style="fill:#8fb629;fill-opacity:1" + d="m 12.900392,1039.8778 -5.6582045,5.6563 -2.828125,-2.8281 L 3,1044.12 l 2.828125,2.8281 1.4140625,1.4141 1.4140625,-1.4141 5.658203,-5.6562 -1.414061,-1.4141 z" + id="path4" /> + </g> +</svg> diff --git a/data/icons/hicolor/16x16/status/package-installed-locked.svg b/data/icons/hicolor/16x16/status/package-installed-locked.svg new file mode 100644 index 0000000000000000000000000000000000000000..37b47b01721fb7986337e975e507fcd5c23863f2 --- /dev/null +++ b/data/icons/hicolor/16x16/status/package-installed-locked.svg @@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + version="1.1" + viewBox="0 0 16 16" + id="svg8" + sodipodi:docname="package-installed-locked.svg" + inkscape:version="0.92.2 2405546, 2018-03-11"> + <metadata + id="metadata14"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + </cc:Work> + </rdf:RDF> + </metadata> + <defs + id="defs12" /> + <sodipodi:namedview + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1" + objecttolerance="10" + gridtolerance="10" + guidetolerance="10" + inkscape:pageopacity="0" + inkscape:pageshadow="2" + inkscape:window-width="792" + inkscape:window-height="480" + id="namedview10" + showgrid="false" + inkscape:zoom="14.75" + inkscape:cx="8.1048439" + inkscape:cy="8" + inkscape:window-x="0" + inkscape:window-y="0" + inkscape:window-maximized="0" + inkscape:current-layer="g6" /> + <g + transform="translate(0,-1036.3622)" + id="g6"> + <rect + style="fill:#8fb633;fill-opacity:1" + width="16" + height="16" + x="-1052.36" + y="-16" + rx=".8" + ry=".8" + transform="matrix(0,-1,-1,0,0,0)" + id="rect2" /> + <path + style="fill:#ffffff" + d="m 5,1041.3622 0,1.9998 -0.5000001,0 c -0.277,0 -0.5,0.223 -0.5,0.5 l 0,5 c 0,0.277 0.223,0.5 0.5,0.5 l 7.0000001,0 c 0.277,0 0.5,-0.223 0.5,-0.5 l 0,-5 c 0,-0.277 -0.223,-0.5 -0.5,-0.5 l -0.5,0 0,-1.9998 c 0,-2 -1,-2 -2,-2 l -2,0 c -1,0 -2,0 -2,2 z m 4,0 0,2 -2,0 0,-2 z" + id="path4" /> + </g> +</svg> diff --git a/data/icons/hicolor/16x16/status/package-installed-updated.svg b/data/icons/hicolor/16x16/status/package-installed-updated.svg new file mode 100644 index 0000000000000000000000000000000000000000..a7b40412670b77c122e01e28e2189ca63f5eb9ef --- /dev/null +++ b/data/icons/hicolor/16x16/status/package-installed-updated.svg @@ -0,0 +1,65 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + version="1.1" + viewBox="0 0 16 16" + id="svg8" + sodipodi:docname="package-installed-updated.svg" + inkscape:version="0.92.2 2405546, 2018-03-11"> + <metadata + id="metadata14"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <defs + id="defs12" /> + <sodipodi:namedview + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1" + objecttolerance="10" + gridtolerance="10" + guidetolerance="10" + inkscape:pageopacity="0" + inkscape:pageshadow="2" + inkscape:window-width="640" + inkscape:window-height="480" + id="namedview10" + showgrid="false" + inkscape:zoom="14.75" + inkscape:cx="8" + inkscape:cy="8" + inkscape:window-x="0" + inkscape:window-y="0" + inkscape:window-maximized="0" + inkscape:current-layer="g6" /> + <g + transform="translate(0,-1036.3622)" + id="g6"> + <rect + style="fill:#8fb633" + width="16" + height="16" + x="-1052.36" + y="-16" + rx=".8" + ry=".8" + transform="matrix(0,-1,-1,0,0,0)" + id="rect2" /> + </g> +</svg> diff --git a/resources/package-reinstall.svg b/data/icons/hicolor/16x16/status/package-reinstall.svg similarity index 100% rename from resources/package-reinstall.svg rename to data/icons/hicolor/16x16/status/package-reinstall.svg diff --git a/resources/package-remove.svg b/data/icons/hicolor/16x16/status/package-remove.svg similarity index 100% rename from resources/package-remove.svg rename to data/icons/hicolor/16x16/status/package-remove.svg diff --git a/data/icons/hicolor/16x16/status/package-upgrade.svg b/data/icons/hicolor/16x16/status/package-upgrade.svg new file mode 100644 index 0000000000000000000000000000000000000000..c8297fdc389262e95e2cdbfe7c81ebf12ac9a3de --- /dev/null +++ b/data/icons/hicolor/16x16/status/package-upgrade.svg @@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + version="1.1" + viewBox="0 0 16 16" + id="svg8" + sodipodi:docname="package-upgrade.svg" + inkscape:version="0.92.2 2405546, 2018-03-11"> + <metadata + id="metadata14"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + </cc:Work> + </rdf:RDF> + </metadata> + <defs + id="defs12" /> + <sodipodi:namedview + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1" + objecttolerance="10" + gridtolerance="10" + guidetolerance="10" + inkscape:pageopacity="0" + inkscape:pageshadow="2" + inkscape:window-width="792" + inkscape:window-height="480" + id="namedview10" + showgrid="false" + inkscape:zoom="14.75" + inkscape:cx="8" + inkscape:cy="8" + inkscape:window-x="0" + inkscape:window-y="0" + inkscape:window-maximized="0" + inkscape:current-layer="g6" /> + <g + transform="translate(0,-1036.3622)" + id="g6"> + <rect + style="fill:#8fb633;fill-opacity:1" + width="16" + height="16" + x="-1052.36" + y="-16" + rx=".8" + ry=".8" + transform="matrix(0,-1,-1,0,0,0)" + id="rect2" /> + <path + style="fill:#ffffff;fill-rule:evenodd" + d="m 7,1049.3622 0,-6 -2,0 3,-4 3,4 -2,0 0,6 z" + id="path4" /> + </g> +</svg> diff --git a/data/icons/hicolor/24x24/status/pamac-tray-update.svg b/data/icons/hicolor/24x24/status/pamac-tray-update.svg index fae59f7aa5112d4b882d4b4e9e9d0f4668a4c324..c530a631fea24089ee94d13ceb55857a35a0f437 100644 --- a/data/icons/hicolor/24x24/status/pamac-tray-update.svg +++ b/data/icons/hicolor/24x24/status/pamac-tray-update.svg @@ -1,11 +1,63 @@ -<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" version="1.1"> - <defs> - <style id="current-color-scheme" type="text/css"> +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="24" + height="24" + version="1.1" + id="svg11" + sodipodi:docname="pamac-tray-update.svg" + inkscape:version="0.92.2 2405546, 2018-03-11"> + <metadata + id="metadata15"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + </cc:Work> + </rdf:RDF> + </metadata> + <sodipodi:namedview + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1" + objecttolerance="10" + gridtolerance="10" + guidetolerance="10" + inkscape:pageopacity="0" + inkscape:pageshadow="2" + inkscape:window-width="792" + inkscape:window-height="480" + id="namedview13" + showgrid="false" + inkscape:zoom="9.8333333" + inkscape:cx="12" + inkscape:cy="12" + inkscape:window-x="0" + inkscape:window-y="0" + inkscape:window-maximized="0" + inkscape:current-layer="g9" /> + <defs + id="defs3"> + <style + id="current-color-scheme" + type="text/css"> .ColorScheme-Text { color:#d3dae3; } .ColorScheme-Highlight { color:#5294e2; } </style> - </defs> - <g> - <path style="fill:currentColor;fill-rule:evenodd" class="ColorScheme-Text" d="m 10,10 3,0 0,5 1,0 0,2 -4,0 0,-2 1,0 0,-3 -1,0 0,-2 z m 1,-3 2,0 0,2 -2,0 0,-2 z M 12,4 C 9.8519,5.9698 6.2346,7.7049 5,8 5,13.333 7.625,19.111 12,20 16.375,19.111 19,13.333 19,8 17.765,7.7049 14.148,5.9698 12,4 Z"/> - <circle style="fill:currentColor" class="ColorScheme-Highlight" cx="19" cy="19" r="2"/> - </g> + </defs> + <g + id="g9"> + <path + style="fill:#dc0000;fill-rule:evenodd;fill-opacity:1" + class="ColorScheme-Text" + d="m 10,10 3,0 0,5 1,0 0,2 -4,0 0,-2 1,0 0,-3 -1,0 0,-2 z m 1,-3 2,0 0,2 -2,0 0,-2 z M 12,4 C 9.8519,5.9698 6.2346,7.7049 5,8 5,13.333 7.625,19.111 12,20 16.375,19.111 19,13.333 19,8 17.765,7.7049 14.148,5.9698 12,4 Z" + id="path5" /> + </g> </svg> diff --git a/resources/package-available-locked.svg b/resources/package-available-locked.svg deleted file mode 100644 index 2d248963f77b5c5511c220686432f84b5caa4aef..0000000000000000000000000000000000000000 --- a/resources/package-available-locked.svg +++ /dev/null @@ -1,4 +0,0 @@ -<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" version="1"> - <path style="fill:#b9b9b9" d="m8 1c-2.216 0-4 1.784-4 4v2h2v-2c0-1.108 0.892-2 2-2s2 0.892 2 2v2h2v-2c0-2.216-1.784-4-4-4z"/> - <rect style="fill:#9b9b9b" width="9" height="12" x="-16" y="-14" rx="1" ry="1" transform="matrix(0,-1,-1,0,0,0)"/> -</svg> diff --git a/resources/package-available.svg b/resources/package-available.svg deleted file mode 100644 index 0f4ee8d09555ede676720ab11d63e2ed41c47ded..0000000000000000000000000000000000000000 --- a/resources/package-available.svg +++ /dev/null @@ -1,4 +0,0 @@ -<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" version="1.1" viewBox="0 0 16 16"> - <rect style="fill:#e4e4e4" width="16" height="16" x="-16" y="-16" rx=".8" ry=".8" transform="matrix(0,-1,-1,0,0,0)"/> - <path style="opacity:0.5;fill:#ac6f11" d="M 6.5976562 0 C 6.2666588 0 6 0.34239436 6 0.76757812 L 6 6 L 0.76757812 6 C 0.34239436 6 1.9001242e-17 6.2666588 0 6.5976562 L 0 9.4023438 C 0 9.7333412 0.34239436 10 0.76757812 10 L 6 10 L 6 15.232422 C 6 15.657606 6.2666588 16 6.5976562 16 L 9.4023438 16 C 9.7333412 16 10 15.657606 10 15.232422 L 10 10 L 15.232422 10 C 15.657606 10 16 9.7333412 16 9.4023438 L 16 6.5976562 C 16 6.2666588 15.657606 6 15.232422 6 L 10 6 L 10 0.76757812 C 10 0.34239436 9.7333412 1.9001242e-17 9.4023438 0 L 6.5976562 0 z"/> -</svg> diff --git a/resources/package-generic.svg b/resources/package-generic.svg deleted file mode 100644 index d46db37977ef45df0bdaa79cfbbd57251e406c94..0000000000000000000000000000000000000000 --- a/resources/package-generic.svg +++ /dev/null @@ -1,12 +0,0 @@ -<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" version="1"> - <rect style="opacity:0.2" width="56" height="56" x="-61" y="-60" rx="3" ry="3" transform="matrix(0,-1,-1,0,0,0)"/> - <rect style="fill:#8bc34a" width="56" height="56" x="-60" y="-60" rx="3" ry="3" transform="matrix(0,-1,-1,0,0,0)"/> - <path style="opacity:0.2" d="m 32,25 c -2.210666,0 -4,1.8 -4,4 v 8 c 0,2.2 1.79,4 4,4 2.21,0 4,-1.8 4,-4 v -8 c 0,-2.2 -1.789334,-4 -4,-4 z m 0,2 c 1.104,0 2,0.8 2,2 0,0.999998 -0.896,2 -2,2 -1.104,0 -2,-1.000002 -2,-2 0,-1.2 0.896,-2 2,-2 z m 0,6 c 1.10457,0 2,0.89543 2,2 v 2 c 0,1.10457 -0.89543,2 -2,2 -1.10457,0 -2,-0.89543 -2,-2 v -2 c 0,-1.10457 0.89543,-2 2,-2 z"/> - <path style="opacity:0.2;fill:#ffffff" d="M 7 4 C 5.338 4 4 5.338 4 7 L 4 8 C 4 6.338 5.338 5 7 5 L 57 5 C 58.662 5 60 6.338 60 8 L 60 7 C 60 5.338 58.662 4 57 4 L 7 4 z"/> - <path style="opacity:0.2" d="m 30,4 v 20 c 0,1.1 0.895,2 2,2 1.105,0 2,-0.9 2,-2 V 4 Z"/> - <path style="opacity:0.2" d="m 32,4 v 1 h 1 V 4 Z m 0,1 h -1 v 1 h 1 z m 0,1 v 1 h 1 V 6 Z m 0,1 h -1 v 1 h 1 z m 0,1 v 1 h 1 V 8 Z m 0,1 h -1 v 1 h 1 z m 0,1 v 1 h 1 v -1 z m 0,1 h -1 v 1 h 1 z m 0,1 v 1 h 1 v -1 z m 0,1 h -1 v 1 h 1 z m 0,1 v 1 h 1 v -1 z m 0,1 h -1 v 1 h 1 z m 0,1 v 1 h 1 v -1 z m 0,1 h -1 z"/> - <path style="fill:#dddddd" d="m 31,4 v 1 h 1 V 4 Z m 0,2 v 1 h 1 V 6 Z m 0,2 v 1 h 1 V 8 Z m 0,2 v 1 h 1 v -1 z m 0,2 v 1 h 1 v -1 z m 0,2 v 1 h 1 v -1 z m 0,2 v 1 h 1 v -1 z"/> - <path style="opacity:0.2" d="m 31,18 h 1 c 0.04125,-0.367529 0,-1 0,-1 h -1 z m 1,0 v 1 h 1 v -1 z m 0,1 h -1 v 1 h 1 z m 0,1 v 1 h 1 v -1 z m 0,1 h -1 v 1 h 1 z m 0,1 v 1 h 1 v -1 z m 0,1 h -1 v 1 h 1 z m 0,1 v 1 h 1 v -1 z m 0,1 h -1 c -0.1561,1.390912 1,1.390912 1,0 z"/> - <path style="fill:#dddddd" d="m 31,18 v 1 h 1 v -1 z m 0,2 v 1 h 1 v -1 z m 0,2 v 1 h 1 v -1 z m 0,2 v 1 h 1 v -1 z"/> - <path style="fill:#ffffff" d="m 32,24 c -2.210666,0 -4,1.8 -4,4 v 8 c 0,2.2 1.79,4 4,4 2.21,0 4,-1.8 4,-4 v -8 c 0,-2.2 -1.789334,-4 -4,-4 z m 0,2 c 1.104,0 2,0.8 2,2 0,0.999998 -0.896,2 -2,2 -1.104,0 -2,-1.000002 -2,-2 0,-1.2 0.896,-2 2,-2 z m 0,6 c 1.10457,0 2,0.89543 2,2 v 2 c 0,1.10457 -0.89543,2 -2,2 -1.10457,0 -2,-0.89543 -2,-2 v -2 c 0,-1.10457 0.89543,-2 2,-2 z"/> -</svg> diff --git a/resources/package-install.svg b/resources/package-install.svg deleted file mode 100644 index 3dfffecba1102f0ea5b28d00a24a58ef87dda6e0..0000000000000000000000000000000000000000 --- a/resources/package-install.svg +++ /dev/null @@ -1,6 +0,0 @@ -<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" version="1.1" viewBox="0 0 16 16"> - <g transform="translate(0,-1036.3622)"> - <rect style="fill:#8fb633" width="16" height="16" x="-1052.36" y="-16" rx=".8" ry=".8" transform="matrix(0,-1,-1,0,0,0)"/> - <path style="fill:#ffffff" d="m 12.900392,1039.8778 -5.6582045,5.6563 -2.828125,-2.8281 L 3,1044.12 l 2.828125,2.8281 1.4140625,1.4141 1.4140625,-1.4141 5.658203,-5.6562 -1.414061,-1.4141 z"/> - </g> -</svg> diff --git a/resources/package-installed-locked.svg b/resources/package-installed-locked.svg deleted file mode 100644 index bf70944ed1aa9d98be492cdcdc619dae50ce3799..0000000000000000000000000000000000000000 --- a/resources/package-installed-locked.svg +++ /dev/null @@ -1,6 +0,0 @@ -<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" version="1.1" viewBox="0 0 16 16"> - <g transform="translate(0,-1036.3622)"> - <rect style="fill:#3f83d6" width="16" height="16" x="-1052.36" y="-16" rx=".8" ry=".8" transform="matrix(0,-1,-1,0,0,0)"/> - <path style="fill:#ffffff" d="m 5,1041.3622 0,1.9998 -0.5000001,0 c -0.277,0 -0.5,0.223 -0.5,0.5 l 0,5 c 0,0.277 0.223,0.5 0.5,0.5 l 7.0000001,0 c 0.277,0 0.5,-0.223 0.5,-0.5 l 0,-5 c 0,-0.277 -0.223,-0.5 -0.5,-0.5 l -0.5,0 0,-1.9998 c 0,-2 -1,-2 -2,-2 l -2,0 c -1,0 -2,0 -2,2 z m 4,0 0,2 -2,0 0,-2 z"/> - </g> -</svg> diff --git a/resources/package-installed-updated.svg b/resources/package-installed-updated.svg deleted file mode 100644 index d79705f89dbde0e2d6ef252f4c2129dcb7144e7d..0000000000000000000000000000000000000000 --- a/resources/package-installed-updated.svg +++ /dev/null @@ -1,6 +0,0 @@ -<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" version="1.1" viewBox="0 0 16 16"> - <g transform="translate(0,-1036.3622)"> - <rect style="fill:#3f83d6" width="16" height="16" x="-1052.36" y="-16" rx=".8" ry=".8" transform="matrix(0,-1,-1,0,0,0)"/> - <path style="fill:#ffffff" d="m 12.900392,1039.8778 -5.6582045,5.6563 -2.828125,-2.8281 L 3,1044.12 l 2.828125,2.8281 1.4140625,1.4141 1.4140625,-1.4141 5.658203,-5.6562 -1.414061,-1.4141 z"/> - </g> -</svg> diff --git a/resources/package-upgrade.svg b/resources/package-upgrade.svg deleted file mode 100644 index 83c7fdd1b5de62017d9679bb9916ba31f01a2a30..0000000000000000000000000000000000000000 --- a/resources/package-upgrade.svg +++ /dev/null @@ -1,6 +0,0 @@ -<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" version="1.1" viewBox="0 0 16 16"> - <g transform="translate(0,-1036.3622)"> - <rect style="fill:#835296" width="16" height="16" x="-1052.36" y="-16" rx=".8" ry=".8" transform="matrix(0,-1,-1,0,0,0)"/> - <path style="fill:#ffffff;fill-rule:evenodd" d="m 7,1049.3622 0,-6 -2,0 3,-4 3,4 -2,0 0,6 z"/> - </g> -</svg> diff --git a/resources/pamac.manager.gresource.xml b/resources/pamac.manager.gresource.xml index e148bc1b0d850aa9f6d0b3b51f75914b0fc314a1..deb798debc423f904d86f57e9e8de664c4cf231c 100644 --- a/resources/pamac.manager.gresource.xml +++ b/resources/pamac.manager.gresource.xml @@ -3,15 +3,6 @@ <gresource prefix="/org/manjaro/pamac/manager"> <file preprocess="xml-stripblanks">manager_window.ui</file> <file preprocess="xml-stripblanks">history_dialog.ui</file> - <file preprocess="to-pixdata">package-available.svg</file> - <file preprocess="to-pixdata">package-available-locked.svg</file> - <file preprocess="to-pixdata">package-install.svg</file> - <file preprocess="to-pixdata">package-installed-locked.svg</file> - <file preprocess="to-pixdata">package-installed-updated.svg</file> - <file preprocess="to-pixdata">package-reinstall.svg</file> - <file preprocess="to-pixdata">package-remove.svg</file> - <file preprocess="to-pixdata">package-upgrade.svg</file> - <file preprocess="to-pixdata">package-generic.svg</file> </gresource> <gresource prefix="/org/manjaro/pamac/preferences"> <file preprocess="xml-stripblanks">preferences_dialog.ui</file> diff --git a/src/manager_window.vala b/src/manager_window.vala index f3e345e0f88aa1f2435ff0bc51c3540d8250f23b..383257ed774d008879ba4757fc1f2255f5030673 100644 --- a/src/manager_window.vala +++ b/src/manager_window.vala @@ -37,6 +37,7 @@ namespace Pamac { [GtkTemplate (ui = "/org/manjaro/pamac/manager/manager_window.ui")] class ManagerWindow : Gtk.ApplicationWindow { // icons + Gtk.IconTheme icon_theme; Gdk.Pixbuf? installed_icon; Gdk.Pixbuf? uninstalled_icon; Gdk.Pixbuf? to_install_icon; @@ -275,6 +276,8 @@ namespace Pamac { if (filters_stack.visible_child_name == "updates") { if (unlikely (temporary_ignorepkgs.contains (pkgname))) { pixbuf = uninstalled_icon; + } else if (unlikely (transaction.transaction_summary.contains (pkgname))) { + pixbuf = installed_locked_icon; } else { pixbuf = to_upgrade_icon; } @@ -323,6 +326,8 @@ namespace Pamac { if (filters_stack.visible_child_name == "updates") { if (unlikely (temporary_ignorepkgs.contains (pkgname))) { pixbuf = uninstalled_icon; + } else if (unlikely (transaction.transaction_summary.contains (pkgname))) { + pixbuf = installed_locked_icon; } else { pixbuf = to_upgrade_icon; } @@ -349,19 +354,10 @@ namespace Pamac { }); aur_state_renderer.activated.connect (on_aur_state_icon_activated); - try { - installed_icon = new Gdk.Pixbuf.from_resource ("/org/manjaro/pamac/manager/package-installed-updated.svg"); - uninstalled_icon = new Gdk.Pixbuf.from_resource ("/org/manjaro/pamac/manager/package-available.svg"); - to_install_icon = new Gdk.Pixbuf.from_resource ("/org/manjaro/pamac/manager/package-install.svg"); - to_reinstall_icon = new Gdk.Pixbuf.from_resource ("/org/manjaro/pamac/manager/package-reinstall.svg"); - to_remove_icon = new Gdk.Pixbuf.from_resource ("/org/manjaro/pamac/manager/package-remove.svg"); - to_upgrade_icon = new Gdk.Pixbuf.from_resource ("/org/manjaro/pamac/manager/package-upgrade.svg"); - installed_locked_icon = new Gdk.Pixbuf.from_resource ("/org/manjaro/pamac/manager/package-installed-locked.svg"); - available_locked_icon = new Gdk.Pixbuf.from_resource ("/org/manjaro/pamac/manager/package-available-locked.svg"); - package_icon = new Gdk.Pixbuf.from_resource ("/org/manjaro/pamac/manager/package-generic.svg"); - } catch (GLib.Error e) { - stderr.printf ("%s\n", e.message); - } + // icons + icon_theme = Gtk.IconTheme.get_default (); + icon_theme.changed.connect (update_icons); + update_icons (); // database database.get_updates_progress.connect (on_get_updates_progress); @@ -430,6 +426,23 @@ namespace Pamac { } } + void update_icons () { + icon_theme = Gtk.IconTheme.get_default (); + try { + installed_icon = icon_theme.load_icon ("package-installed-updated", 16, 0); + uninstalled_icon = icon_theme.load_icon ("package-available", 16, 0); + to_install_icon = icon_theme.load_icon ("package-install", 16, 0); + to_reinstall_icon = icon_theme.load_icon ("package-reinstall", 16, 0); + to_remove_icon = icon_theme.load_icon ("package-remove", 16, 0); + to_upgrade_icon = icon_theme.load_icon ("package-upgrade", 16, 0); + installed_locked_icon = icon_theme.load_icon ("package-installed-locked", 16, 0); + available_locked_icon = icon_theme.load_icon ("package-available-locked", 16, 0); + package_icon = icon_theme.load_icon ("package-x-generic", 64, 0); + } catch (GLib.Error e) { + stderr.printf ("%s\n", e.message); + } + } + [GtkCallback] bool on_ManagerWindow_delete_event () { if (transaction_running || sysupgrade_running || generate_mirrors_list) { diff --git a/src/tray.vala b/src/tray.vala index c7913a0fff1d23a25204ded05b0e52060b58adaf..2c867a384ffe0d633ad5b41dc1bc7aa0024327d8 100644 --- a/src/tray.vala +++ b/src/tray.vala @@ -45,6 +45,7 @@ namespace Pamac { GLib.File lockfile; FileMonitor monitor; uint updates_nb; + Gtk.IconTheme icon_theme; public TrayIcon () { application_id = "org.manjaro.pamac.tray"; @@ -265,6 +266,15 @@ namespace Pamac { } } + void on_icon_theme_changed () { + icon_theme = Gtk.IconTheme.get_default (); + if (updates_nb > 0) { + set_icon (update_icon_name); + } else { + set_icon (noupdate_icon_name); + } + } + public override void startup () { // i18n Intl.textdomain ("pamac"); @@ -281,6 +291,8 @@ namespace Pamac { extern_lock = false; refresh_timeout_id = 0; + icon_theme = Gtk.IconTheme.get_default (); + icon_theme.changed.connect (on_icon_theme_changed); init_status_icon (); set_icon (noupdate_icon_name); set_tooltip (noupdate_info);