Ignore:
Timestamp:
03/02/11 18:25:27 (3 years ago)
Author:
ales_erjavec <ales.erjavec@…>
Branch:
default
Convert:
bdb2d3a1a862ba58e2e6e111c3c3db74fa2b0abb
Message:
  • update the loadedSettingsDict after loadDocument
  • changed the default dontAskBeforeClose value to False
File:
1 edited

Legend:

Unmodified
Added
Removed
  • orange/OrangeCanvas/orngDoc.py

    r7716 r7721  
    6262    # ask the user if he is sure 
    6363    def closeEvent(self,ce): 
    64         newSettings = self.loadedSettingsDict and self.loadedSettingsDict != dict([(widget.caption, widget.instance.saveSettingsStr()) for widget in self.widgets]) 
     64        newSettings = self.isSchemaChanged() 
    6565 
    6666        self.synchronizeContexts() 
     
    454454    # save the file 
    455455    def save(self, filename = None): 
    456         print "Saving to", filename 
    457456        if filename == None: 
    458457            filename = os.path.join(self.schemaPath, self.schemaName) 
     
    582581        if self.widgets: 
    583582            self.signalManager.processNewSignals(self.widgets[0].instance) 
     583             
     584        # Store the loaded settings dict again  
     585        self.loadedSettingsDict = dict((widget.caption, widget.instance.saveSettingsStr()) for widget in self.widgets) 
     586        self.canvasDlg.setWindowModified(False) 
    584587 
    585588        # do we want to restore last position and size of the widget 
Note: See TracChangeset for help on using the changeset viewer.