Changeset 3621:b95b4975506c in orange


Ignore:
Timestamp:
04/30/07 17:48:45 (7 years ago)
Author:
janezd <janez.demsar@…>
Branch:
default
Convert:
39d9556cb73337f9a91900b360e4517884e858f6
Message:
  • checks "if self.data" in a few (more) places
File:
1 edited

Legend:

Unmodified
Added
Removed
  • orange/OrangeWidgets/Visualize/OWAttributeStatistics.py

    r3415 r3621  
    6363 
    6464    def resizeEvent(self, event): 
    65         if self.canvas and self.HighlightedAttribute>=0: 
     65        if self.canvas and self.data and self.HighlightedAttribute>=0: 
    6666            # canvas height should be a bit less than the height of the widget frame 
    6767            self.ch = self.height()-20 
     
    8989        self.attributes.clear() 
    9090        if data==None: 
    91             self.dataset = None 
     91            self.dataset = self.dist = None 
    9292            self.canvasview.hide() 
    9393        else: 
     
    122122 
    123123    def displayStat(self, data, ind, dist): 
     124        if not data: 
     125            return 
     126         
    124127        attr = data.domain[ind] 
    125128        attr_name = QCanvasText (attr.name, self) 
Note: See TracChangeset for help on using the changeset viewer.