Added dialogs to change home and work locations.
[ptas] / zouba / uicontroller.h
index 392962d..9657b8e 100644 (file)
@@ -1,40 +1,40 @@
 #ifndef UICONTROLLER_H
 #define UICONTROLLER_H
 
-#include "ui_zouba.h"
 #include "routedata.h"
+#include "location.h"
 
 #include <QObject>
 
+class Ui;
+
 class UiController : public QObject
 {
   Q_OBJECT
 
 public:
-  UiController( Ui::MainWindow *ui );
+  UiController( Ui *ui );
   ~UiController();
 
 public Q_SLOTS:
-  void displayRoute( const RouteData &routeData );
+  void displayRoute( const QList<RouteData> &routeData );
 
 Q_SIGNALS:
-  void homeAddressChanged( QString );
-  void workAddressChanged( QString );
-  void directionChanged();
+  void buttonClicked();
+  void destinationChanged( Location *newDestination );
 
 private Q_SLOTS:
-  void setHomeAddress();
-  void setWorkAddress();
-  void toggleRoute();
+  void changeDestination( int id );
+  void setHomeButtonValid();
+  void setWorkButtonValid();
 
 private:
-  Ui::MainWindow *ui;
-  enum Direction {
-    WorkToHome,
-    HomeToWork
-  };
+  void setButtonValid( int id );
 
-  Direction route;
+private:
+  QList<Location*> destination;
+  Ui *ui;
+  int currentDestination;
 };
 #endif // UICONTROLLER_H