diff options
Diffstat (limited to 'le_new/src')
| -rw-r--r-- | le_new/src/ofApp.cpp | 7 | ||||
| -rw-r--r-- | le_new/src/ofApp.h | 3 |
2 files changed, 9 insertions, 1 deletions
diff --git a/le_new/src/ofApp.cpp b/le_new/src/ofApp.cpp index f12380e..d9488ec 100644 --- a/le_new/src/ofApp.cpp +++ b/le_new/src/ofApp.cpp @@ -74,7 +74,7 @@ void previewWindow::setup(){ setWindowShape(600,800); setWindowPosition(260, 0); setWindowTitle("PREVIEW"); - ofRegisterMouseEvents(this); + ofAddListener(onMouseMoved, this, &previewWindow::mousemoved); } void previewWindow::setParent(ofApp *p){ parent=p; @@ -87,6 +87,11 @@ void previewWindow::draw(){ rb->draw(0,0,getWidth(),getHeight()); //why crash? } +void previewWindow::mousemoved(ofMouseEventArgs &arg){ + + printf("moved\n"); + +} //-------------------------------------------------------------- outputWindow::~outputWindow(){ diff --git a/le_new/src/ofApp.h b/le_new/src/ofApp.h index 99cfbdf..8a33b96 100644 --- a/le_new/src/ofApp.h +++ b/le_new/src/ofApp.h @@ -1,6 +1,7 @@ #pragma once #include "ofMain.h" +#include "ofEvents.h" #include "ofxXmlSettings.h" #include "ofxFensterManager.h" @@ -126,6 +127,8 @@ public: void setup(); void setBuffer(ofFbo *buffer); void draw(); + void mousemoved(ofMouseEventArgs &arg); + }; class outputWindow: public ofxFenster{ |
