blob: 6f46d97c70a0406985fd4cb2738e3878f72d902d [file] [log] [blame]
Edric Milaret627500d2015-03-27 16:41:40 -04001/***************************************************************************
Edric Milaret4bba46d2015-04-29 16:33:38 -04002 * Copyright (C) 2015 by Savoir-Faire Linux *
Edric Milaret627500d2015-03-27 16:41:40 -04003 * Author: Edric Ladent Milaret <edric.ladent-milaret@savoirfairelinux.com>*
4 * *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 3 of the License, or *
8 * (at your option) any later version. *
9 * *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
14 * *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program. If not, see <http://www.gnu.org/licenses/>. *
17 **************************************************************************/
18
19#ifndef MAINWINDOW_H
20#define MAINWINDOW_H
21
22#include <QMainWindow>
23#include <QMouseEvent>
24#include <QSystemTrayIcon>
25
26#include "navstack.h"
27
28
29namespace Ui {
30class MainWindow;
31}
32
33class MainWindow : public QMainWindow
34{
35 Q_OBJECT
36
37public:
38 explicit MainWindow(QWidget *parent = 0);
39 ~MainWindow();
40
41private slots:
42 void trayActivated(QSystemTrayIcon::ActivationReason reason);
Edric Milaret3a23e492015-04-29 14:23:48 -040043 void onIncomingCall(Call *call);
Edric Milaret627500d2015-03-27 16:41:40 -040044
45private:
46 Ui::MainWindow *ui;
47 NavStack* navStack_;
48 QPoint oldPos_;
49 QSystemTrayIcon sysIcon_;
50
51protected:
52 void mousePressEvent(QMouseEvent *evt);
53 void mouseMoveEvent(QMouseEvent *evt);
54};
55
56#endif // MAINWINDOW_H