Added the ability to edit the PID number using the number pad.
[profile/ivi/hfdialer.git] / src / qmlmainwindow.h
1 /*
2  * dialer - Declarative Dialer UX Main Window.
3  * Copyright (c) 2011, Tom Swindell.
4  *
5  * This program is licensed under the terms and conditions of the
6  * Apache License, version 2.0.  The full text of the Apache License is at
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  */
10
11 #ifndef QMLMAINWINDOW_H
12 #define QMLMAINWINDOW_H
13
14 #include <QDeclarativeView>
15 #include <QDeclarativeComponent>
16 #include "qmldialer.h"
17 #include "callitem.h"
18
19 class QMLMainWindowPrivate;
20
21 class QMLMainWindow : public QDeclarativeView 
22 {
23     Q_OBJECT
24
25 public:
26     static   QMLMainWindow* instance();
27     static   QMLMainWindow* instanceP(QWidget* parent);
28             ~QMLMainWindow();
29
30 public Q_SLOTS:
31     void hide();
32     void tryToShow();
33     
34     void setAdapter(QMLDialer *adapter); //TODO: Refactor out
35
36 protected Q_SLOTS:
37     void setupUi();
38
39     void onGeometryChanged();
40
41 protected:
42     virtual void closeEvent(QCloseEvent *event);
43
44 private:
45     explicit QMLMainWindow(QWidget *parent = 0);
46     QMLMainWindowPrivate *d;
47     QDeclarativeView qv;
48     Q_DISABLE_COPY(QMLMainWindow)
49 };
50
51 #endif // QMLMAINWINDOW_H