# HG changeset patch
# User Yuki KODAMA <[email protected]>
# Date 1244866546 -32400
# Node ID d6591ec1ab9018e30e7881e559f84b6515b207e4
# Parent 7784b868358604ceccec2cfd66313fb2d7092913
shelve: disable 'Shelve' button if no changes
diff --git a/hggtk/thgshelve.py b/hggtk/thgshelve.py
--- a/hggtk/thgshelve.py
+++ b/hggtk/thgshelve.py
@@ -112,6 +112,7 @@
def reload_status(self):
if not self.ready: return False
success = GStatus.reload_status(self)
+ self.activate_shelve_buttons(True)
return success
### End of overridable methods ###
@@ -121,7 +122,7 @@
def activate_shelve_buttons(self, status):
if status:
- self.shelve_btn.set_sensitive(True)
+ self.shelve_btn.set_sensitive(len(self.filemodel) > 0)
self.unshelve_btn.set_sensitive(self.has_shelve_file())
else:
self.shelve_btn.set_sensitive(False)
------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Tortoisehg-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tortoisehg-develop