Hello community,

here is the log from the commit of package cinnamon for openSUSE:Leap:15.2 
checked in at 2020-05-13 03:49:52
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Leap:15.2/cinnamon (Old)
 and      /work/SRC/openSUSE:Leap:15.2/.cinnamon.new.2738 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "cinnamon"

Wed May 13 03:49:52 2020 rev:20 rq:797206 version:4.4.8

Changes:
--------
--- /work/SRC/openSUSE:Leap:15.2/cinnamon/cinnamon.changes      2020-02-21 
23:52:46.976975594 +0100
+++ /work/SRC/openSUSE:Leap:15.2/.cinnamon.new.2738/cinnamon.changes    
2020-05-13 03:49:53.523955321 +0200
@@ -1,0 +2,33 @@
+Wed Apr 22 04:44:06 UTC 2020 - Marguerite Su <[email protected]>
+
+- update cinnamon-settings-native.patch, use more yast2 modules
+
+-------------------------------------------------------------------
+Thu Apr 16 04:30:19 UTC 2020 - Marguerite Su <[email protected]>
+
+- the cinnamon-settings' calendar module requires python3-pytz
+
+-------------------------------------------------------------------
+Thu Apr  2 05:05:02 UTC 2020 - Marguerite Su <[email protected]>
+
+- fix an error in cinnamon-settings-4.4.8-tinycss2.patch,
+  now "cinnamon-settings -> themes" can start (boo#1166981)
+- add cinnamon-4.4.8-python3-platform.linux_distribution.patch
+  * python3.7 deprecates "platform.linux_distribution", use
+    "distro.linux_distribution" instead
+
+-------------------------------------------------------------------
+Thu Apr  2 04:36:48 UTC 2020 - Marguerite Su <[email protected]>
+
+- add cinnamon-4.4.8-python3-is-with-literal.patch
+  * fix 'using "is" with a literal warning
+
+-------------------------------------------------------------------
+Mon Mar 16 15:31:14 UTC 2020 - Marguerite Su <[email protected]>
+
+- update version 4.4.8
+  * details see github commits
+- refreshed patch cinnamon-settings-4.4.8-tinycss2.patch
+  * dropped cinnamon-settings-4.2.3-tinycss2.patch
+
+-------------------------------------------------------------------

Old:
----
  cinnamon-4.2.3.tar.gz
  cinnamon-settings-4.2.3-tinycss2.patch

New:
----
  cinnamon-4.4.8-python3-is-with-literal.patch
  cinnamon-4.4.8-python3-platform.linux_distribution.patch
  cinnamon-4.4.8.tar.gz
  cinnamon-settings-4.4.8-tinycss2.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ cinnamon.spec ++++++
--- /var/tmp/diff_new_pack.BtQizv/_old  2020-05-13 03:49:54.031956386 +0200
+++ /var/tmp/diff_new_pack.BtQizv/_new  2020-05-13 03:49:54.035956395 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package cinnamon
 #
-# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2020 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -18,7 +18,7 @@
 
 %define _version 4.0.0
 Name:           cinnamon
-Version:        4.2.3
+Version:        4.4.8
 Release:        0
 Summary:        GNU/Linux Desktop featuring a traditional layout
 License:        GPL-2.0-or-later AND LGPL-2.1-only
@@ -41,8 +41,12 @@
 Patch7:         %{name}-fallback-icewm.patch
 # PATCH-FIX-OPENSUSE cinnamon-fix-typelib-false-positive.patch 
[email protected] -- remove false typelib(Webkit) dependency
 Patch8:         %{name}-fix-typelib-false-positive.patch
-# PATCH-FIx-UPSTREAM cinnamon-settings-4.2.3-tinycss2.patch
-Patch9:         %{name}-settings-4.2.3-tinycss2.patch
+# PATCH-FIX-UPSTREAM cinnamon-settings-4.4.8-tinycss2.patch 
[email protected] - port deprecated tinycss to tinycss2
+Patch9:         %{name}-settings-4.4.8-tinycss2.patch
+# PATCH-FIX-UPSTREAM cinnamon-4.4.8-python3-is-with-literal.patch
+Patch10:        %{name}-4.4.8-python3-is-with-literal.patch
+# PATCH-FIX-UPSTREAM cinnamon-4.4.8-python3-platform.linux_distribution.patch
+Patch11:        %{name}-4.4.8-python3-platform.linux_distribution.patch
 BuildRequires:  autoconf
 BuildRequires:  autoconf-archive
 BuildRequires:  automake
@@ -92,12 +96,16 @@
 Requires:       polkit-gnome
 Requires:       python3-Pillow
 Requires:       python3-cairo
+Requires:       python3-distro
 Requires:       python3-gobject
 Requires:       python3-gobject-Gdk
 Requires:       python3-gobject-cairo
 Requires:       python3-pexpect
 Requires:       python3-pyinotify
 Requires:       python3-python-pam
+# cinnamon-settings calendar module
+Requires:       python3-pytz
+# cinnamon-settings theme module
 Requires:       python3-tinycss2
 Requires:       v4l-tools
 Requires:       wget
@@ -189,6 +197,8 @@
 %patch7 -p1
 %patch8 -p1
 %patch9 -p1
+%patch10 -p1
+%patch11 -p1
 cp -a %{SOURCE1} .
 
 for file in files%{_datadir}/%{name}/%{name}-settings/bin/*.py 
files%{_datadir}/%{name}/%{name}-looking-glass/*.py \

++++++ cinnamon-4.4.8-python3-is-with-literal.patch ++++++
Index: 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-desktop-editor/cinnamon-desktop-editor.py
===================================================================
--- 
cinnamon-4.4.8.orig/files/usr/share/cinnamon/cinnamon-desktop-editor/cinnamon-desktop-editor.py
+++ 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-desktop-editor/cinnamon-desktop-editor.py
@@ -194,7 +194,7 @@ class LauncherEditor(ItemEditor):
     def resync_validity(self, *args):
         name_text = self.builder.get_object('name-entry').get_text().strip()
         exec_text = self.builder.get_object('exec-entry').get_text().strip()
-        name_valid = name_text is not ""
+        name_valid = name_text != ""
         exec_valid = self.validate_exec_line(exec_text)
         self.sync_widgets(name_valid, exec_valid)
 
@@ -236,7 +236,7 @@ class DirectoryEditor(ItemEditor):
 
     def resync_validity(self, *args):
         name_text = self.builder.get_object('name-entry').get_text().strip()
-        valid = (name_text is not "")
+        valid = (name_text != "")
         self.builder.get_object('ok').set_sensitive(valid)
 
     def load(self):
@@ -281,7 +281,7 @@ class CinnamonLauncherEditor(ItemEditor)
     def resync_validity(self, *args):
         name_text = self.builder.get_object('name-entry').get_text().strip()
         exec_text = self.builder.get_object('exec-entry').get_text().strip()
-        name_valid = name_text is not ""
+        name_valid = name_text != ""
         exec_valid = self.validate_exec_line(exec_text)
         self.sync_widgets(name_valid, exec_valid)
 
Index: 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/bin/ChooserButtonWidgets.py
===================================================================
--- 
cinnamon-4.4.8.orig/files/usr/share/cinnamon/cinnamon-settings/bin/ChooserButtonWidgets.py
+++ 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/bin/ChooserButtonWidgets.py
@@ -339,13 +339,13 @@ class TimeChooserButton(Gtk.Button):
     def __init__(self, follow_current=False, time=None, 
show_seconds='default'):
         super(TimeChooserButton, self).__init__()
 
-        if show_seconds is 'default':
+        if show_seconds == 'default':
             self.show_seconds_override_default = False
         else:
             self.show_seconds_override_default = True
-            if show_seconds is 'true':
+            if show_seconds == 'true':
                 self.show_seconds = True
-            elif show_seconds is 'false':
+            elif show_seconds == 'false':
                 self.show_seconds = False
             else:
                 raise ValueError('Invalid argument: show_seconds must be 
default, true, or false')
Index: 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/bin/JsonSettingsWidgets.py
===================================================================
--- 
cinnamon-4.4.8.orig/files/usr/share/cinnamon/cinnamon-settings/bin/JsonSettingsWidgets.py
+++ 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/bin/JsonSettingsWidgets.py
@@ -239,7 +239,7 @@ class JSONSettingsRevealer(Gtk.Revealer)
                 break
 
         if self.key is None:
-            if key[:1] is '!':
+            if key[:1] == '!':
                 self.invert = True
                 self.key = key[1:]
             else:
Index: 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/modules/cs_keyboard.py
===================================================================
--- 
cinnamon-4.4.8.orig/files/usr/share/cinnamon/cinnamon-settings/modules/cs_keyboard.py
+++ 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/modules/cs_keyboard.py
@@ -419,7 +419,7 @@ class Module:
             categories, iter = tree.get_selection().get_selected()
             if iter:
                 category = categories[iter][2]
-                if category.int_name is not "custom":
+                if category.int_name != "custom":
                     for keybinding in category.keybindings:
                         self.kb_store.append((keybinding.label, keybinding))
                 else:
@@ -428,7 +428,7 @@ class Module:
 
     def loadCustoms(self):
         for category in self.main_store:
-            if category.int_name is "custom":
+            if category.int_name == "custom":
                 category.clear()
 
         parent = Gio.Settings.new(CUSTOM_KEYS_PARENT_SCHEMA)
@@ -443,7 +443,7 @@ class Module:
                                          schema.get_strv("binding"))
             self.kb_store.append((custom_kb.label, custom_kb))
             for category in self.main_store:
-                if category.int_name is "custom":
+                if category.int_name == "custom":
                     category.add(custom_kb)
 
     def onKeyBindingChanged(self, tree):
@@ -453,7 +453,7 @@ class Module:
             if iter:
                 keybinding = keybindings[iter][1]
                 for entry in keybinding.entries:
-                    if entry is not "_invalid_":
+                    if entry != "_invalid_":
                         self.entry_store.append((entry,))
                 self.remove_custom_button.set_property('sensitive', 
isinstance(keybinding, CustomKeyBinding))
 
@@ -536,7 +536,7 @@ class Module:
         new_schema.set_strv("binding", ())
         i = 0
         for cat in self.cat_store:
-            if cat[2].int_name is "custom":
+            if cat[2].int_name == "custom":
                 self.cat_tree.set_cursor(str(i), self.cat_tree.get_column(0), 
False)
             i += 1
         i = 0
@@ -574,7 +574,7 @@ class Module:
 
         i = 0
         for cat in self.cat_store:
-            if cat[2].int_name is "custom":
+            if cat[2].int_name == "custom":
                 self.cat_tree.set_cursor(str(i), self.cat_tree.get_column(0), 
False)
             i += 1
 
@@ -600,7 +600,7 @@ class Module:
 
                 i = 0
                 for cat in self.cat_store:
-                    if cat[2].int_name is "custom":
+                    if cat[2].int_name == "custom":
                         self.cat_tree.set_cursor(str(i), 
self.cat_tree.get_column(0), False)
                     i += 1
                 i = 0
@@ -691,7 +691,7 @@ class KeyBinding():
     def writeSettings(self):
         array = []
         for entry in self.entries:
-            if entry is not "":
+            if entry != "":
                 array.append(entry)
         self.settings.set_strv(self.key, array)
 
@@ -731,7 +731,7 @@ class CustomKeyBinding():
 
         array = []
         for entry in self.entries:
-            if entry is not "":
+            if entry != "":
                 array.append(entry)
         settings.set_strv("binding", array)
 
@@ -777,6 +777,6 @@ class AddCustomDialog(Gtk.Dialog):
         self.command_entry.set_text(path)
 
     def onEntriesChanged(self, widget):
-        ok_enabled = self.name_entry.get_text().strip() is not "" and 
self.command_entry.get_text().strip() is not ""
+        ok_enabled = self.name_entry.get_text().strip() != "" and 
self.command_entry.get_text().strip() != ""
         self.set_response_sensitive(Gtk.ResponseType.OK, ok_enabled)
-        
\ No newline at end of file
+        
Index: 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-slideshow/cinnamon-slideshow.py
===================================================================
--- 
cinnamon-4.4.8.orig/files/usr/share/cinnamon/cinnamon-slideshow/cinnamon-slideshow.py
+++ 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-slideshow/cinnamon-slideshow.py
@@ -118,7 +118,7 @@ class CinnamonSlideshow(dbus.service.Obj
         def on_next_file_complete(obj, res, user_data=all_files):
             files = obj.next_files_finish(res)
             file_list = all_files
-            if len(files) is not 0:
+            if len(files) != 0:
                 file_list = file_list.extend(files)
                 enumerator.next_files_async(100, GLib.PRIORITY_LOW, None, 
on_next_file_complete, None)
             else:
++++++ cinnamon-4.4.8-python3-platform.linux_distribution.patch ++++++
Index: 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/modules/cs_info.py
===================================================================
--- 
cinnamon-4.4.8.orig/files/usr/share/cinnamon/cinnamon-settings/modules/cs_info.py
+++ cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/modules/cs_info.py
@@ -6,6 +6,7 @@ import shlex
 import os
 import re
 import threading
+import distro
 
 from SettingsWidgets import SidePage
 from xapp.GSettingsWidgets import *
@@ -105,7 +106,7 @@ def createSystemInfos():
         title = ' '.join(contents[:2]) or "Manjaro Linux"
         infos.append((_("Operating System"), title))
     else:
-        s = '%s (%s)' % (' '.join(platform.linux_distribution()), arch)
+        s = '%s (%s)' % (' '.join(distro.linux_distribution()), arch)
         # Normalize spacing in distribution name
         s = re.sub('\s{2,}', ' ', s)
         infos.append((_("Operating System"), s))
++++++ cinnamon-4.2.3.tar.gz -> cinnamon-4.4.8.tar.gz ++++++
++++ 37361 lines of diff (skipped)

++++++ cinnamon-settings-4.2.3-tinycss2.patch -> 
cinnamon-settings-4.4.8-tinycss2.patch ++++++
--- 
/work/SRC/openSUSE:Leap:15.2/cinnamon/cinnamon-settings-4.2.3-tinycss2.patch    
    2020-02-21 23:52:46.736975118 +0100
+++ 
/work/SRC/openSUSE:Leap:15.2/.cinnamon.new.2738/cinnamon-settings-4.4.8-tinycss2.patch
      2020-05-13 03:49:53.347954952 +0200
@@ -1,7 +1,30 @@
-Index: 
cinnamon-4.2.3/files/usr/share/cinnamon/cinnamon-settings/bin/CinnamonGtkSettings.py
-===================================================================
---- 
cinnamon-4.2.3.orig/files/usr/share/cinnamon/cinnamon-settings/bin/CinnamonGtkSettings.py
-+++ 
cinnamon-4.2.3/files/usr/share/cinnamon/cinnamon-settings/bin/CinnamonGtkSettings.py
+From 009317e7c324a39f9ca97d731af08645359aa5bc Mon Sep 17 00:00:00 2001
+From: marguerite <[email protected]>
+Date: Tue, 17 Mar 2020 10:53:26 +0800
+Subject: [PATCH] port tinycss to tinycss2
+
+---
+ debian/control                                |   2 +-
+ .../bin/CinnamonGtkSettings.py                | 144 +++++++++++++-----
+ 2 files changed, 103 insertions(+), 43 deletions(-)
+
+diff --git a/debian/control b/debian/control
+index 638885ff94..454fcf1958 100644
+--- a/debian/control
++++ b/debian/control
+@@ -96,7 +96,7 @@ Depends:
+  python3-pil,
+  python3-pyinotify,
+  python3-setproctitle,
+- python3-tinycss,
++ python3-tinycss2,
+  python3-tz,
+  streamer,
+  wget,
+diff --git 
a/files/usr/share/cinnamon/cinnamon-settings/bin/CinnamonGtkSettings.py 
b/files/usr/share/cinnamon/cinnamon-settings/bin/CinnamonGtkSettings.py
+index 5b2a66418c..555cad6841 100644
+--- a/files/usr/share/cinnamon/cinnamon-settings/bin/CinnamonGtkSettings.py
++++ b/files/usr/share/cinnamon/cinnamon-settings/bin/CinnamonGtkSettings.py
 @@ -3,8 +3,7 @@
  import os.path
  import signal
@@ -12,29 +35,45 @@
  
  import gi
  gi.require_version("Gtk", "3.0")
-@@ -87,13 +86,37 @@ class GtkCssEditor:
-         self._path = os.path.join(GLib.get_user_config_dir(),
+@@ -91,11 +90,10 @@ def __init__(self, selector):
                                    "gtk-3.0",
                                    "gtk.css")
--
+ 
 -        self.parser = tinycss.make_parser()
+         self.selector = selector
+ 
+         self.rule_separator = "/***** %s - cinnamon-settings-generated - do 
not edit *****/" % self.selector
+-        self.my_ruleset = None
 +        rules = []
  
-         try:
--            self.stylesheet = self.parser.parse_stylesheet_file(self._path)
-+            stylesheet = tinycss2.parse_stylesheet_bytes(open(self._path, 
'rb').read())
-+            for rs in stylesheet[0]:
-+                if type(rs) == tinycss2.ast.ParseError:
+         file = Gio.File.new_for_path(self._path)
+ 
+@@ -103,11 +101,16 @@ def __init__(self, selector):
+             success, content_bytes, tag = file.load_contents(None)
+ 
+             self._contents = content_bytes.decode()
+-            self.stylesheet = self.parser.parse_stylesheet(self._contents)
++            stylesheet = tinycss2.parse_stylesheet(self._contents)
++            for rs in stylesheet:
++                if isinstance(rs, tinycss2.ast.ParseError):
 +                    continue
 +                rules.append(rs)
 +            self.stylesheet = rules
-         except FileNotFoundError:
--            self.stylesheet = tinycss.css21.Stylesheet(rules=[], errors=[], 
encoding="utf-8")
-+            self.stylesheet = rules
-+
+         except GLib.Error as e:
+             if e.code == Gio.IOErrorEnum.NOT_FOUND:
+                 self._contents = ""
+-                self.stylesheet = tinycss.css21.Stylesheet(rules=[], 
errors=[], encoding="utf-8")
++                self.stylesheet = rules
+             else:
+                 raise PermissionError("Could not load 
~/.config/gtk-3.0/gtk.css file, check permissions")
+ 
+@@ -142,30 +145,56 @@ def sanitize_contents(self):
+ 
+         self._contents = "\n".join(out_lines)
+ 
 +    def _serialize_selector(self, rule):
 +        at_css = ""
-+        if type(rule) == tinycss2.ast.AtRule:
++        if isinstance(rule, tinycss2.ast.AtRule):
 +            at_css += "@" + rule.at_keyword
 +        at_css += self._serialize_prelude(rule.prelude)
 +        return at_css
@@ -42,28 +81,31 @@
 +    def _serialize_prelude(self, prelude):
 +        at_css = ""
 +        for cv in prelude:
-+            if type(cv) == tinycss2.ast.WhitespaceToken:
++            if isinstance(cv, tinycss2.ast.WhitespaceToken):
 +                at_css += " "
-+            elif type(cv) == tinycss2.ast.HashToken:
++            elif isinstance(cv, tinycss2.ast.HashToken):
 +                at_css += "#" + cv.value
-+            elif type(cv) == tinycss2.ast.FunctionBlock:
++            elif isinstance(cv, tinycss2.ast.FunctionBlock):
 +                next
 +            else:
 +                at_css += cv.value
 +        return at_css.strip()
- 
++
      def get_ruleset(self, selector_css):
          """
-@@ -101,21 +124,30 @@ class GtkCssEditor:
+         Gets the current ruleset for selector_css,
          If it isn't currently defined, returns an empty
          one.
          """
 -        for rs in self.stylesheet.rules:
--            if rs.selector.as_css() == selector_css:
--                return rs
+-            try:
+-                if rs.selector.as_css() == selector_css:
+-                    return rs
+-            except AttributeError:
+-                continue
 +        idx = 0
 +        for rs in self.stylesheet:
-+            if type(rs) == tinycss2.ast.AtRule or type(rs) == 
tinycss2.ast.QualifiedRule:
++            if isinstance(rs, (tinycss2.ast.AtRule, 
tinycss2.ast.QualifiedRule)):
 +                if self._serialize_selector(rs) == selector_css:
 +                    return rs, idx
 +            idx += 1
@@ -88,13 +130,13 @@
 -                return declaration.value[0].value
 +                decl_value = None
 +                for component_value in declaration.value:
-+                    if type(component_value) == tinycss2.ast.DimensionToken:
++                    if isinstance(component_value, 
tinycss2.ast.DimensionToken):
 +                        decl_value = component_value.value
 +                return decl_value
  
          return None
  
-@@ -124,41 +156,67 @@ class GtkCssEditor:
+@@ -174,32 +203,68 @@ def set_declaration(self, selector, decl_name, 
value_as_str):
          # get modified, they become invalid (or I'm doing something wrong)
          self.remove_declaration(selector, decl_name)
  
@@ -104,17 +146,23 @@
 -
 -        # Make a new declaration, add it to the ruleset
 -        new_decl = tinycss.css21.Declaration(decl_name, value_token, None, 
None, None)
+-
+-        rs.declarations.append(new_decl)
+-
+-        self.my_ruleset = rs
 +        rs, idx = self.get_ruleset(selector)
 +        # rs.content[0].value: the value of the WhitespaceToken is the actual 
indent
 +        prefix = "\n\t"
-+        if len(rs.content) > 0:
++        if rs.content:
 +            prefix = rs.content[0].value
 +
-+        component_values = tinycss2.parse_component_value_list(prefix + 
decl_name + ": " + value_as_str + ";")
++        component_values = tinycss2.parse_component_value_list(prefix + 
decl_name +
++                                                               ": " + 
value_as_str + ";")
 +        for component_value in component_values:
 +            self.stylesheet[idx].content.append(component_value)
 +
-+    def _remove_declaration_from_content(self, declaration, content):
++    @staticmethod
++    def _remove_declaration_from_content(declaration, content):
 +        idx = 0
 +        ident_idx = 0
 +        found_ident = False
@@ -122,25 +170,29 @@
 +        new_content = []
 +        for component_value in content:
 +            idx += 1
-+            if len(content) != idx and type(content[idx]) == 
tinycss2.ast.IdentToken and content[idx].value == declaration.name and 
type(component_value) == tinycss2.ast.WhitespaceToken:
++            if len(content) != idx and isinstance(content[idx], 
tinycss2.ast.IdentToken) and \
++               content[idx].value == declaration.name and \
++               isinstance(component_value, tinycss2.ast.WhitespaceToken):
 +                continue
-+            if type(component_value) == tinycss2.ast.IdentToken and 
component_value.value == declaration.name:
++            if isinstance(component_value, tinycss2.ast.IdentToken) and \
++               component_value.value == declaration.name:
 +                found_ident = True
 +                continue
 +            if found_ident:
-+                if type(component_value) == tinycss2.ast.LiteralToken:
-+                    if ident_idx == 0 or done == True:
++                if isinstance(component_value, tinycss2.ast.LiteralToken):
++                    if ident_idx == 0 or done:
 +                        done = False
 +                        continue
-+                if len(declaration.value) - 1 == ident_idx and 
component_value == declaration.value[ident_idx]:
++                if len(declaration.value) - 1 == ident_idx and \
++                   component_value == declaration.value[ident_idx]:
 +                    done = True
 +                    continue
-+                if component_value == declaration.value[ident_idx] and 
content[idx] == declaration.value[ident_idx + 1]:
++                if component_value == declaration.value[ident_idx] and \
++                   content[idx] == declaration.value[ident_idx + 1]:
 +                    ident_idx += 1
 +                    continue
 +            new_content.append(component_value)
- 
--        rs.declarations.append(new_decl)
++
 +        return new_content
  
      def remove_declaration(self, selector, decl_name):
@@ -150,9 +202,10 @@
          if not rs:
              return
  
--        for declaration in rs.declarations:
+-        self.my_ruleset = None
 +        declarations = tinycss2.parse_declaration_list(rs.content, True, True)
-+
+ 
+-        for declaration in rs.declarations:
 +        for declaration in declarations:
              if decl_name == declaration.name:
 -                rs.declarations.remove(declaration)
@@ -160,7 +213,7 @@
  
 -                if len(rs.declarations) == 0:
 -                    self.stylesheet.rules.remove(rs)
-+                if len(new_content) == 0:
++                if not new_content:
 +                    self.stylesheet.remove(rs)
 +                    break
  
@@ -168,18 +221,25 @@
                  break
  
      def save_stylesheet(self):
-         out = ""
+@@ -213,18 +278,13 @@ def save_stylesheet(self):
+ 
+             out += line + "\n"
+ 
+-        if self.my_ruleset:
++        if self.stylesheet:
+             if line != "":
+                 out += "\n"
+ 
+             out += self.rule_separator + "\n"
 -
--        for rs in self.stylesheet.rules:
--            out += rs.selector.as_css() + " {\n"
+-            out += self.my_ruleset.selector.as_css() + " {\n"
 -
--            for decl in rs.declarations:
+-            for decl in self.my_ruleset.declarations:
 -                out += "    " + decl.name + ": " + decl.value.as_css() + ";\n"
 -
 -            out += "}\n"
--
-+        for rs in self.stylesheet:
-+            out += rs.serialize()
-         with open(self._path, "w+") as f:
-             f.write(out)
++            for rs in self.stylesheet:
++                out += rs.serialize()
+ 
+         self._contents = out
  

++++++ cinnamon-settings-native.patch ++++++
--- /var/tmp/diff_new_pack.BtQizv/_old  2020-05-13 03:49:54.443957250 +0200
+++ /var/tmp/diff_new_pack.BtQizv/_new  2020-05-13 03:49:54.443957250 +0200
@@ -1,10 +1,35 @@
---- a/files/usr/share/cinnamon/cinnamon-settings/cinnamon-settings.py
-+++ b/files/usr/share/cinnamon/cinnamon-settings/cinnamon-settings.py
-@@ -87,6 +87,7 @@ STANDALONE_MODULES = [
-     [_("Software Sources"),              "pkexec mintsources",                
  "cs-sources",         "admin",          _("ppa, repository, package, source, 
download")],
-     [_("Package Management"),            "dnfdragora",                        
  "cs-sources",         "admin",          _("update, install, repository, 
package, source, download")],
-     [_("Package Management"),            "yumex-dnf",                         
  "cs-sources",         "admin",          _("update, install, repository, 
package, source, download")],
-+    [_("YaST"),                          "xdg-su -c /sbin/yast2",             
  "yast",               "admin",          _("system, admin, yast2, settings")],
+Index: 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/cinnamon-settings.py
+===================================================================
+--- 
cinnamon-4.4.8.orig/files/usr/share/cinnamon/cinnamon-settings/cinnamon-settings.py
++++ 
cinnamon-4.4.8/files/usr/share/cinnamon/cinnamon-settings/cinnamon-settings.py
+@@ -76,22 +76,19 @@ CONTROL_CENTER_MODULES = [
+ 
+ STANDALONE_MODULES = [
+     #         Label                          Executable                       
   Icon                Category        Keywords for filter
+-    [_("Printers"),                      "system-config-printer",             
  "cs-printer",         "hardware",       _("printers, laser, inkjet")],
+-    [_("Firewall"),                      "gufw",                              
  "cs-firewall",        "admin",          _("firewall, block, filter, 
programs")],
+-    [_("Firewall"),                      "firewall-config",                   
  "cs-firewall",        "admin",          _("firewall, block, filter, 
programs")],
+-    [_("Languages"),                     "mintlocale",                        
  "cs-language",        "prefs",          _("language, install, foreign")],
+-    [_("Input Method"),                  "mintlocale-im",                     
  "cs-input-method",    "prefs",          _("language, install, foreign, input, 
method, chinese, korean, japanese, typing")],
++    [_("Printers"),                      "xdg-su -c '/sbin/yast2 printer'",   
            "cs-printer",         "hardware",       _("printers, laser, 
inkjet")],
++    [_("Firewall"),                      "xdg-su -c '/sbin/yast2 firewall'",  
                   "cs-firewall",        "admin",          _("firewall, block, 
filter, programs")],
++    [_("Languages"),                     "xdg-su -c '/sbin/yast2 language'",  
                        "cs-language",        "prefs",          _("language, 
install, foreign")],
+     [_("Login Window"),                  "pkexec lightdm-settings",           
  "cs-login",           "admin",          _("login, lightdm, mdm, gdm, manager, 
user, password, startup, switch")],
+     [_("Login Window"),                  
"lightdm-gtk-greeter-settings-pkexec", "cs-login",           "admin",          
_("login, lightdm, manager, settings, editor")],
+-    [_("Driver Manager"),                "pkexec driver-manager",             
  "cs-drivers",         "admin",          _("video, driver, wifi, card, 
hardware, proprietary, nvidia, radeon, nouveau, fglrx")],
++    [_("Driver Manager"),                "xdg-su -c '/sbin/yast2 hwinfo'",    
           "cs-drivers",         "admin",          _("video, driver, wifi, 
card, hardware, proprietary, nvidia, radeon, nouveau, fglrx")],
+     [_("Nvidia Settings"),               "nvidia-settings",                   
  "cs-drivers",         "admin",          _("video, driver, proprietary, 
nvidia, settings")],
+-    [_("Software Sources"),              "pkexec mintsources",                
  "cs-sources",         "admin",          _("ppa, repository, package, source, 
download")],
+-    [_("Package Management"),            "dnfdragora",                        
  "cs-sources",         "admin",          _("update, install, repository, 
package, source, download")],
+-    [_("Package Management"),            "yumex-dnf",                         
  "cs-sources",         "admin",          _("update, install, repository, 
package, source, download")],
++    [_("Software Sources"),              "xdg-su -c '/sbin/yast2 
repositories'",                  "cs-sources",         "admin",          
_("ppa, repository, package, source, download")],
++    [_("Package Management"),            "xdg-su -c '/sbin/yast2 sw_single'", 
                          "cs-sources",         "admin",          _("update, 
install, repository, package, source, download")],
      [_("Users and Groups"),              "cinnamon-settings-users",           
  "cs-user-accounts",   "admin",          _("user, users, account, accounts, 
group, groups, password")],
      [_("Bluetooth"),                     "blueberry",                         
  "cs-bluetooth",       "hardware",       _("bluetooth, dongle, transfer, 
mobile")],
-     [_("Manage Services and Units"),     "systemd-manager-pkexec",            
  "cs-sources",         "admin",          _("systemd, units, services, 
systemctl, init")]
+-    [_("Manage Services and Units"),     "systemd-manager-pkexec",            
  "cs-sources",         "admin",          _("systemd, units, services, 
systemctl, init")],
+-    [_("Disks"),                         "gnome-disks",                       
  "gnome-disks",        "hardware",       _("disks, manage, hardware, 
management, hard, hdd, pendrive, format, erase, test, create, iso, ISO, disk, 
image")]
++    [_("Manage Services and Units"),     "xdg-su -c '/sbin/yast2 
services-manager'",              "cs-sources",         "admin",          
_("systemd, units, services, systemctl, init")],
++    [_("Disks"),                         "xdg-su -c '/sbin/yast2 
partitioner'",                         "gnome-disks",        "hardware",       
_("disks, manage, hardware, management, hard, hdd, pendrive, format, erase, 
test, create, iso, ISO, disk, image")]
+ ]
+ 
+ TABS = {


Reply via email to