Changeset 11205:60e3cdc7c041 in orange


Ignore:
Timestamp:
11/27/12 15:32:51 (17 months ago)
Author:
Ales Erjavec <ales.erjavec@…>
Branch:
default
Message:

Removed obsolete unused widget geometry settings (were replaced by savedWidgetGeometry).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Orange/OrangeWidgets/OWBaseWidget.py

    r11134 r11205  
    147147        self.savePosition = savePosition 
    148148        if savePosition: 
    149             self.settingsList = getattr(self, "settingsList", []) + ["widgetWidth", "widgetHeight", "widgetXPosition", "widgetYPosition", "widgetShown", "savedWidgetGeometry"] 
     149            self.settingsList = getattr(self, "settingsList", []) + ["widgetShown", "savedWidgetGeometry"] 
    150150 
    151151        # directories are better defined this way, otherwise .ini files get written in many places 
     
    270270    # call this function if needed in __init__ of the widget 
    271271    def safeProcessEvents(self): 
    272         keys = ["widgetXPosition", "widgetYPosition", "widgetShown", "widgetWidth", "widgetHeight"] 
     272        keys = ["widgetShown"] 
    273273        vals = [(key, getattr(self, key, None)) for key in keys] 
    274274        qApp.processEvents() 
     
    334334        # overwrite the the savedGeometry before then) 
    335335        if self.savePosition and self.isVisible(): 
    336             self.widgetWidth = self.width() 
    337             self.widgetHeight = self.height() 
    338336            self.savedWidgetGeometry = str(self.saveGeometry()) 
    339337 
     
    353351        if self.savePosition: 
    354352            self.widgetShown = 0 
    355             self.widgetXPosition = self.frameGeometry().x() 
    356             self.widgetYPosition = self.frameGeometry().y() 
    357353            self.savedWidgetGeometry = str(self.saveGeometry()) 
    358354        QDialog.hideEvent(self, ev) 
     
    375371    def closeEvent(self, ev): 
    376372        if self.savePosition: 
    377             self.widgetXPosition = self.frameGeometry().x() 
    378             self.widgetYPosition = self.frameGeometry().y() 
    379373            self.savedWidgetGeometry = str(self.saveGeometry()) 
    380374        QDialog.closeEvent(self, ev) 
Note: See TracChangeset for help on using the changeset viewer.