improved desktop UI
[mardrone] / mardrone / gauges / gauge.cpp
index f555f99..01f4f50 100644 (file)
@@ -10,6 +10,12 @@ Gauge::Gauge(QGraphicsItem *parent) :
     m_textSize=20;
     m_tickMinor=0;
     m_scale=1.0;
+    m_tickLength=10;
+    m_highPosition=0;
+    m_lowPosition=180;
+    m_lineWidth=1;
+    m_backColor=QColor("black");
+    m_needleImage=NULL;
 }
 #if 1
 void Gauge::paint(QPainter *painter,
@@ -26,6 +32,17 @@ void Gauge::setValue(float val_)
     m_value=val_;
     update(boundingRect()); // Value updated, schedule redtaw
 };
+
+void Gauge::propChanged()
+{
+    update(boundingRect()); // Value updated, schedule redtaw
+}
+
+
+bool Gauge::testOption(QString a){
+    return m_options.contains(a);
+
+};
 float Gauge::value()
 {
     return m_value;