From 6564107b8ec7c703456e743ef207f67c539fc871 Mon Sep 17 00:00:00 2001 From: Krisjanis Rijnieks Date: Sun, 18 Sep 2016 15:12:32 +0200 Subject: [PATCH] Clean up BaseJoint --- src/UserInterface/BaseJoint.cpp | 21 --------------------- src/UserInterface/BaseJoint.h | 4 ---- 2 files changed, 25 deletions(-) diff --git a/src/UserInterface/BaseJoint.cpp b/src/UserInterface/BaseJoint.cpp index c5d65cb..4fd890b 100644 --- a/src/UserInterface/BaseJoint.cpp +++ b/src/UserInterface/BaseJoint.cpp @@ -6,30 +6,11 @@ namespace piMapper { BaseJoint::BaseJoint(){ setDefaultColors(); setDefaultProperties(); - registerMouseEvents(); -} - -BaseJoint::~BaseJoint(){ - unregisterMouseEvents(); -} - -void BaseJoint::registerMouseEvents(){ - //ofAddListener(ofEvents().mousePressed, this, &BaseJoint::mousePressed); - //ofAddListener(ofEvents().mouseDragged, this, &BaseJoint::mouseDragged); -} - -void BaseJoint::unregisterMouseEvents(){ - //ofRemoveListener(ofEvents().mousePressed, this, &BaseJoint::mousePressed); - //ofRemoveListener(ofEvents().mouseDragged, this, &BaseJoint::mouseDragged); } void BaseJoint::mousePressed(ofMouseEventArgs & args){ - cout << "BaseJoint::mousePressed()" << endl; - if(hitTest(ofVec2f(args.x, args.y))){ - // selected = true; clickDistance = position - ofVec2f(args.x, args.y); - // startDrag(); } } @@ -38,8 +19,6 @@ void BaseJoint::mouseReleased(int x, int y, int button){ } void BaseJoint::mouseDragged(ofMouseEventArgs & args){ - cout << "BaseJoint::mouseDragged()" << endl; - if(!bDrag){ return; } diff --git a/src/UserInterface/BaseJoint.h b/src/UserInterface/BaseJoint.h index 753c6bc..be75299 100644 --- a/src/UserInterface/BaseJoint.h +++ b/src/UserInterface/BaseJoint.h @@ -9,10 +9,6 @@ class BaseJoint { public: BaseJoint(); - ~BaseJoint(); - - void registerMouseEvents(); - void unregisterMouseEvents(); ofVec2f position; bool enabled;