File desktop-icon-gnome-41.patch of Package gnome-shell-extension-desktop-icons.36963
Index: desktop-icons-20.10.0/fileItem.js
===================================================================
--- desktop-icons-20.10.0.orig/fileItem.js
+++ desktop-icons-20.10.0/fileItem.js
@@ -446,7 +446,7 @@ var FileItem = GObject.registerClass({
if (icon != null) {
let theme = new Gtk.IconTheme();
theme.set_custom_theme(St.Settings.get().gtk_icon_theme);
- if (theme.lookup_by_gicon(icon, null, Gtk.IconLookupFlags.GENERIC_FALLBACK) == null)
+ if (theme.lookup_by_gicon(icon, null, Gtk.IconLookupFlags.FORCE_REGULAR) == null)
icon = Gio.ThemedIcon.new_with_default_fallbacks('text-x-generic');
} else {
if (GLib.path_is_absolute(iconName)) {
Index: desktop-icons-20.10.0/metadata.json
===================================================================
--- desktop-icons-20.10.0.orig/metadata.json
+++ desktop-icons-20.10.0/metadata.json
@@ -2,6 +2,6 @@
"name": "Desktop Icons",
"description": "Add icons to the desktop",
"uuid": "desktop-icons@csoriano",
- "shell-version": ["3.38.0"],
+ "shell-version": ["3.38.0", "41"],
"url": "https://gitlab.gnome.org/World/ShellExtensions/desktop-icons"
}
Index: desktop-icons-20.10.0/prefs.js
===================================================================
--- desktop-icons-20.10.0.orig/prefs.js
+++ desktop-icons-20.10.0/prefs.js
@@ -98,13 +98,19 @@ function get_schema(schema) {
function buildPrefsWidget() {
initTranslations();
- let frame = new Gtk.Box({ orientation: Gtk.Orientation.VERTICAL, border_width: 10, spacing: 10 });
+ let frame = new Gtk.Box({
+ orientation: Gtk.Orientation.VERTICAL,
+ spacing: 10,
+ margin_top: 10,
+ margin_bottom: 10,
+ margin_start: 10,
+ margin_end: 10,
+ });
- frame.add(buildSelector('icon-size', _("Size for the desktop icons"), { 'small': _("Small"), 'standard': _("Standard"), 'large': _("Large") }));
- frame.add(buildSwitcher('show-home', _("Show the personal folder in the desktop")));
- frame.add(buildSwitcher('show-trash', _("Show the trash icon in the desktop")));
- frame.add(buildSwitcher('show-mount', _("Show mounted drives in the desktop")));
- frame.show_all();
+ frame.append(buildSelector('icon-size', _("Size for the desktop icons"), { 'small': _("Small"), 'standard': _("Standard"), 'large': _("Large") }));
+ frame.append(buildSwitcher('show-home', _("Show the personal folder in the desktop")));
+ frame.append(buildSwitcher('show-trash', _("Show the trash icon in the desktop")));
+ frame.append(buildSwitcher('show-mount', _("Show mounted drives in the desktop")));
return frame;
}
@@ -113,8 +119,8 @@ function buildSwitcher(key, labelText) {
let label = new Gtk.Label({ label: labelText, xalign: 0 });
let switcher = new Gtk.Switch({ active: settings.get_boolean(key) });
settings.bind(key, switcher, 'active', 3);
- hbox.pack_start(label, true, true, 0);
- hbox.add(switcher);
+ hbox.prepend(label);
+ hbox.append(switcher);
return hbox;
}
@@ -138,8 +144,8 @@ function buildSelector(key, labelText, e
combo.add_attribute (rendererText, 'text', 0);
combo.set_id_column(1);
settings.bind(key, combo, 'active-id', 3);
- hbox.pack_start(label, true, true, 0);
- hbox.add(combo);
+ hbox.prepend(label);
+ hbox.append(combo);
return hbox;
}