Blob Blame History Raw
From ccf5b18a16216bbc807d8eb1f425aa632fc76e1b Mon Sep 17 00:00:00 2001
From: "Jasper St. Pierre" <jstpierre@mecheye.net>
Date: Thu, 12 Dec 2013 13:46:10 -0500
Subject: [PATCH 1/2] ItemEditor: Fix validity check

---
 Alacarte/ItemEditor.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Alacarte/ItemEditor.py b/Alacarte/ItemEditor.py
index 64d713f..c6b9fba 100644
--- a/Alacarte/ItemEditor.py
+++ b/Alacarte/ItemEditor.py
@@ -182,7 +182,7 @@ class LauncherEditor(ItemEditor):
     def resync_validity(self, *args):
         name_text = self.builder.get_object('name-entry').get_text()
         exec_text = self.builder.get_object('exec-entry').get_text()
-        valid = (name_text is not None and exec_text is not None)
+        valid = (name_text != "" and exec_text != "")
         self.builder.get_object('ok').set_sensitive(valid)
 
     def load(self):
@@ -223,7 +223,7 @@ class DirectoryEditor(ItemEditor):
 
     def resync_validity(self, *args):
         name_text = self.builder.get_object('name-entry').get_text()
-        valid = (name_text is not None)
+        valid = (name_text != "")
         self.builder.get_object('ok').set_sensitive(valid)
 
     def load(self):
-- 
1.9.0