|
|
5b2f0d |
From ccf5b18a16216bbc807d8eb1f425aa632fc76e1b Mon Sep 17 00:00:00 2001
|
|
|
5b2f0d |
From: "Jasper St. Pierre" <jstpierre@mecheye.net>
|
|
|
5b2f0d |
Date: Thu, 12 Dec 2013 13:46:10 -0500
|
|
|
5b2f0d |
Subject: [PATCH 1/2] ItemEditor: Fix validity check
|
|
|
5b2f0d |
|
|
|
5b2f0d |
---
|
|
|
5b2f0d |
Alacarte/ItemEditor.py | 4 ++--
|
|
|
5b2f0d |
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
5b2f0d |
|
|
|
5b2f0d |
diff --git a/Alacarte/ItemEditor.py b/Alacarte/ItemEditor.py
|
|
|
5b2f0d |
index 64d713f..c6b9fba 100644
|
|
|
5b2f0d |
--- a/Alacarte/ItemEditor.py
|
|
|
5b2f0d |
+++ b/Alacarte/ItemEditor.py
|
|
|
5b2f0d |
@@ -182,7 +182,7 @@ class LauncherEditor(ItemEditor):
|
|
|
5b2f0d |
def resync_validity(self, *args):
|
|
|
5b2f0d |
name_text = self.builder.get_object('name-entry').get_text()
|
|
|
5b2f0d |
exec_text = self.builder.get_object('exec-entry').get_text()
|
|
|
5b2f0d |
- valid = (name_text is not None and exec_text is not None)
|
|
|
5b2f0d |
+ valid = (name_text != "" and exec_text != "")
|
|
|
5b2f0d |
self.builder.get_object('ok').set_sensitive(valid)
|
|
|
5b2f0d |
|
|
|
5b2f0d |
def load(self):
|
|
|
5b2f0d |
@@ -223,7 +223,7 @@ class DirectoryEditor(ItemEditor):
|
|
|
5b2f0d |
|
|
|
5b2f0d |
def resync_validity(self, *args):
|
|
|
5b2f0d |
name_text = self.builder.get_object('name-entry').get_text()
|
|
|
5b2f0d |
- valid = (name_text is not None)
|
|
|
5b2f0d |
+ valid = (name_text != "")
|
|
|
5b2f0d |
self.builder.get_object('ok').set_sensitive(valid)
|
|
|
5b2f0d |
|
|
|
5b2f0d |
def load(self):
|
|
|
5b2f0d |
--
|
|
|
5b2f0d |
1.9.0
|
|
|
5b2f0d |
|