File simple-ccsm-explicitly-disable-compiz.patch of Package simple-ccsm

Only in simple-ccsm-0.7.8: setup.py~
---
 simple-ccsm.in |   16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)

Index: simple-ccsm-0.7.8/simple-ccsm.in
===================================================================
--- simple-ccsm-0.7.8.orig/simple-ccsm.in
+++ simple-ccsm-0.7.8/simple-ccsm.in
@@ -1278,6 +1278,12 @@ class MainWin:
             # Create a file that indicates wether compiz is enabled or not
             path = os.path.expanduser("~/.config/compiz/enable-compiz")
             open(path, "w+").close() # touch replacement
+
+            path = os.path.expanduser("~/.config/compiz/disable-compiz")
+            try:
+                os.remove(path)
+            except (IOError, OSError):
+                pass
         else:
             fallbackWM = ""
             if GnomeSession in os.environ and os.environ[GnomeSession]:
@@ -1294,11 +1300,19 @@ class MainWin:
             cmd = "kwriteconfig --file ksmserverrc --group General --key windowManager kwin".split(" ")
             subprocess.Popen(cmd)
 
+            # Create a file that indicates compiz is explicitly disabled, so should not
+            # be started
+            path = os.path.expanduser("~/.config/compiz/disable-compiz")
+            open(path, "w+").close() # touch replacement
+
             # Remove old config
             files = ("~/.config/compiz/enable-compiz", "~/.config/compiz/compiz-manager")
             for file in files:
                 path = os.path.expanduser(file)
-                os.remove(path)
+                try:
+                    os.remove(path)
+                except (IOError, OSError):
+                    pass
 
         self.Notebook.set_sensitive(enabled)
         self.ProfileChooser.set_sensitive(enabled)

openSUSE Build Service is sponsored by