Just some small cosmetic chages (spacings and curly brackets)
authorPekka Nissinen <pekka.nissinen@ixonos.com>
Fri, 13 Aug 2010 13:56:01 +0000 (16:56 +0300)
committerPekka Nissinen <pekka.nissinen@ixonos.com>
Fri, 13 Aug 2010 13:56:01 +0000 (16:56 +0300)
src/ui/indicatorbutton.h
src/ui/indicatorbuttonpanel.cpp

index bfd153c..4397aec 100644 (file)
@@ -32,6 +32,7 @@
  * @brief Indicator button class
  *
  * @author Katri Kaikkonen - katri.kaikkonen (at) ixonos.com
+ * @author Kaj Wallin - kaj.wallin (at) ixonos.com
  * @author Sami Rämö - sami.ramo (at) ixonos.com
  */
 class IndicatorButton : public  QToolButton
index 91d777f..55b53a5 100644 (file)
@@ -121,7 +121,7 @@ void IndicatorButtonPanel::mouseMoveEvent(QMouseEvent *event)
 {
     qDebug() << __PRETTY_FUNCTION__;
 
-    if(m_isDraggable) {
+    if (m_isDraggable) {
         if (event->buttons() & Qt::LeftButton) {
             QPoint newLocation = mapToParent(event->pos()) - m_dragPosition;
 
@@ -138,7 +138,7 @@ void IndicatorButtonPanel::mouseMoveEvent(QMouseEvent *event)
             move(newLocation);
         }
     } else {
-        if(!rect().contains(event->pos()))
+        if (!rect().contains(event->pos()))
             m_dragStartTimer->stop();
     }
 }
@@ -301,18 +301,13 @@ void IndicatorButtonPanel::updateValues(qreal direction, qreal distance, bool dr
         m_distanceText.setNum(10);
         m_distanceText.prepend("< ");
         m_distanceText.append(UNIT_METER);
-    }
-    else if (m_distance < MAX_TO_METERS)
-    {
+    } else if (m_distance < MAX_TO_METERS) {
         m_distanceText.setNum(m_distance, 'f', 0);
         m_distanceText.append(UNIT_METER);
-    }
-    else if (m_distance < MAX_TO_KM_WITH_DESIMAL)
-    {
+    } else if (m_distance < MAX_TO_KM_WITH_DESIMAL) {
         m_distanceText.setNum(m_distance / M_TO_KM, 'f', 1);
         m_distanceText.append(UNIT_KILOMETER);
-    }
-    else {
+    } else {
         m_distanceText.setNum(m_distance / M_TO_KM, 'f', 0);
         m_distanceText.append(UNIT_KILOMETER);
     }
@@ -321,4 +316,3 @@ void IndicatorButtonPanel::updateValues(qreal direction, qreal distance, bool dr
 
     update();
 }
-