From c029e9ac6c21aca41f9053f8e9ec3aa78a407c6f Mon Sep 17 00:00:00 2001 From: Icius Date: Sat, 23 Jan 2010 01:16:49 -0500 Subject: [PATCH] changed the os.system command to os.spawnlp. When using os.system, the context menu stays visible while the gnome-desktop-item-edit program is running. Looked a bit strange. This change is at the cost of the cleanup routine to delete idential .desktop files in the users directory. --- usr/lib/linuxmint/mintMenu/plugins/applications.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/usr/lib/linuxmint/mintMenu/plugins/applications.py b/usr/lib/linuxmint/mintMenu/plugins/applications.py index 8499ef0..b44c72a 100755 --- a/usr/lib/linuxmint/mintMenu/plugins/applications.py +++ b/usr/lib/linuxmint/mintMenu/plugins/applications.py @@ -748,14 +748,7 @@ class pluginclass( object ): data = open(widget.desktopFile).read() open(file_path, 'w').write(data) - os.system('gnome-desktop-item-edit ' + file_path) - - if file_path != widget.desktopFile: - if filecmp.cmp(widget.desktopFile, file_path): - try: - os.remove(file_path) - except os.error: - pass + pid = os.spawnlp(os.P_NOWAIT, "/usr/bin/gnome-desktop-item-edit", "gnome-desktop-item-edit", file_path) self.mintMenuWin.hide()