Show
Ignore:
Timestamp:
11/19/09 12:30:22 (4 years ago)
Author:
robert
Message:

Form Roland Smeenk, "Attached is a small change to the osgWidget::EventInterface? so it matches the NotifyWidget? and NullWidget? interface (added const). Due to this mismatch these widgets never received events.

I also changed the osgwidgetbox example so the ColorWidget? is receiving events again."

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/examples/osgwidgetbox/osgwidgetbox.cpp

    r9370 r10779  
    1919    ColorWidget(): 
    2020    osgWidget::Widget("", 256.0f, 256.0f) { 
     21        setEventMask(osgWidget::EVENT_ALL); 
    2122    } 
    2223 
    23     bool mouseEnter(double, double, osgWidget::WindowManager*) { 
     24    bool mouseEnter(double, double, const osgWidget::WindowManager*) { 
    2425        addColor(-osgWidget::Color(0.4f, 0.4f, 0.4f, 0.0f)); 
    2526         
     
    2930    } 
    3031 
    31     bool mouseLeave(double, double, osgWidget::WindowManager*) { 
     32    bool mouseLeave(double, double, const osgWidget::WindowManager*) { 
    3233        addColor(osgWidget::Color(0.4f, 0.4f, 0.4f, 0.0f)); 
    3334         
     
    3738    } 
    3839 
    39     bool mouseOver(double x, double y, osgWidget::WindowManager*) { 
     40    bool mouseOver(double x, double y, const osgWidget::WindowManager*) { 
    4041        osgWidget::Color c = getImageColorAtPointerXY(x, y); 
    4142