The codebase to run the *spark d-fuser controller www.sparkav.co.uk/dvimixer

Dependencies:   SPK-TVOne DMX DmxArtNet NetServicesMin OSC PinDetect mRotaryEncoder iniparser mbed spk_oled_ssd1305 filter

Revision:
5:f8b285ca41ba
Parent:
0:87aab40d5806
Child:
8:d46cc49f0f37
--- a/spk_utils.h	Mon Apr 23 09:30:50 2012 +0000
+++ b/spk_utils.h	Thu Jul 19 10:46:53 2012 +0000
@@ -67,8 +67,10 @@
     
     std::string title;
     
-    void operator = (int newIndex) {
+    // not carried into subclass... whats the c++ way of doing this?
+    SPKMenu& operator = (const int &newIndex) {
         selected = newIndex;
+        return *this;
     }
     
     void operator ++ () {
@@ -143,7 +145,13 @@
     int32_t selectedPayload2() {
         return payload2[selected.index()];
     }
-        
+    
+    SPKMenuPayload& operator = (const int &newIndex) {
+        selected = newIndex;
+        return *this;
+    }
+    
+               
 private:
     vector<int32_t> payload1;
     vector<int32_t> payload2;