[alacarte] MainWindow: Use the new LauncherEditor for new files
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [alacarte] MainWindow: Use the new LauncherEditor for new files
- Date: Fri, 11 Jan 2013 06:39:49 +0000 (UTC)
commit c850f46beb1d60812e2163118951b8d285868c3e
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Fri Jan 11 00:43:42 2013 -0500
MainWindow: Use the new LauncherEditor for new files
Alacarte/MainWindow.py | 12 +++---------
1 files changed, 3 insertions(+), 9 deletions(-)
---
diff --git a/Alacarte/MainWindow.py b/Alacarte/MainWindow.py
index 31a69ce..c3dc42b 100644
--- a/Alacarte/MainWindow.py
+++ b/Alacarte/MainWindow.py
@@ -235,13 +235,6 @@ class MainWindow(object):
#this is a little timeout callback to insert new items after
#gnome-desktop-item-edit has finished running
- def waitForNewItemProcess(self, process, parent_id, file_path):
- if process.poll() is not None:
- if os.path.isfile(file_path):
- self.editor.insertExternalItem(os.path.split(file_path)[1], parent_id)
- return False
- return True
-
def waitForNewMenuProcess(self, process, parent_id, file_path):
if process.poll() is not None:
if os.path.isfile(file_path):
@@ -272,8 +265,9 @@ class MainWindow(object):
else:
parent = menus[iter][2]
file_path = os.path.join(util.getUserItemPath(), util.getUniqueFileId('alacarte-made', '.desktop'))
- process = subprocess.Popen(['gnome-desktop-item-edit', file_path], env=os.environ)
- GObject.timeout_add(100, self.waitForNewItemProcess, process, parent.get_menu_id(), file_path)
+
+ editor = LauncherEditor(file_path)
+ editor.run()
def on_new_separator_button_clicked(self, button):
item_tree = self.tree.get_object('item_tree')
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]