From 3f08b8847e2255b837f177820ed38c08fc98ee50 Mon Sep 17 00:00:00 2001 From: Harry van Haaren Date: Thu, 5 Dec 2013 20:45:56 +0000 Subject: [PATCH] -Refactoring ~GOptions() --- src/goptions.cxx | 14 ++++++++++++-- src/goptions.hxx | 6 +----- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/src/goptions.cxx b/src/goptions.cxx index f432ef1..9d4efc9 100644 --- a/src/goptions.cxx +++ b/src/goptions.cxx @@ -380,7 +380,6 @@ void ControllerUI::addBinding( Binding* b ) void ControllerUI::addBindings( GenericMIDI* c ) { - // FIXME: add binding to Avtk::Binding here std::vector bindingVector= c->getMidiToAction(); for(unsigned int i = 0; i < bindingVector.size(); i++ ) @@ -391,7 +390,18 @@ void ControllerUI::addBindings( GenericMIDI* c ) ControllerUI::~ControllerUI() { - // FIXME CRITICAL! free UI component memory here + + // free all binding resources here: + + + delete authorLabel; + delete linkLabel; + + delete targetLabel; + delete targetLabelStat; + delete bindEnable; + delete removeController; + delete writeControllerBtn; } OptionsWindow::OptionsWindow() diff --git a/src/goptions.hxx b/src/goptions.hxx index cd8e815..87c8e29 100644 --- a/src/goptions.hxx +++ b/src/goptions.hxx @@ -68,14 +68,10 @@ class ControllerUI Fl_Box* targetLabel; Fl_Box* targetLabelStat; - Avtk::Bindings* bindings; + //Avtk::Bindings* bindings; Avtk::LightButton* bindEnable; Avtk::Button* removeController; Avtk::Button* writeControllerBtn; - - - // Controller - Avtk::Button* ctlrButton; }; class OptionsWindow