def toggled(self,widget,entry_widget,key): if widget.get_active(): entry_widget.set_sensitive(True) value=metadata.app_key_from_string(key,entry_widget.get_text()) self.item.set_meta_key(key,value) else: entry_widget.set_sensitive(False) try: del self.item.meta[key] except: pass
def meta_changed(self,widget,key): value=metadata.app_key_from_string(key,widget.get_text()) self.item.set_meta_key(key,value,self.collection)