Improved XFCE/MATE detection
This commit is contained in:
parent
2449e217e8
commit
854de8452c
@ -217,6 +217,11 @@ class MainWindow( object ):
|
|||||||
de = os.environ["DESKTOP_SESSION"]
|
de = os.environ["DESKTOP_SESSION"]
|
||||||
if de in ["gnome", "gnome-shell", "mate", "kde", "xfce"]:
|
if de in ["gnome", "gnome-shell", "mate", "kde", "xfce"]:
|
||||||
self.de = de
|
self.de = de
|
||||||
|
else:
|
||||||
|
if os.path.exists("/usr/bin/caja"):
|
||||||
|
self.de = "mate"
|
||||||
|
elif os.path.exists("/usr/bin/thunar"):
|
||||||
|
self.de = "xfce"
|
||||||
except Exception, detail:
|
except Exception, detail:
|
||||||
print detail
|
print detail
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user