Changeset 11826:957e603d5ed0 in orange


Ignore:
Timestamp:
01/06/14 17:59:19 (3 months ago)
Author:
Ales Erjavec <ales.erjavec@…>
Branch:
default
Message:

Ignore mouse press events not started on the plot canvas.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Orange/OrangeWidgets/OWGraph.py

    r9671 r11826  
    539539        QwtPlot.mousePressEvent(self, e) 
    540540        canvasPos = self.canvas().mapFrom(self, e.pos()) 
     541 
     542        if not self.canvas().contentsRect().contains(canvasPos): 
     543            # Press on the legend or axis widget. 
     544            return 
     545 
    541546        xFloat = self.invTransform(QwtPlot.xBottom, canvasPos.x()) 
    542547        yFloat = self.invTransform(QwtPlot.yLeft, canvasPos.y()) 
Note: See TracChangeset for help on using the changeset viewer.