Add copying and licence information
[evehomescreen] / src / evesettingsdialog.h
1 // Copyright (C) 2010 Jaakko Kyro <jkyro@korjaussarja.net>
2 // This file is licenced under GPL, see COPYING
3 // for full licence information
4 #ifndef EVESETTINGSDIALOG_H
5 #define EVESETTINGSDIALOG_H
6
7 #include <QDialog>
8 #include "evemodel.h"
9 #include <QtMaemo5>
10 #include <QtGui>
11 #include <QSharedPointer>
12
13 class QNetworkReply;
14 class EveCharacter;
15 namespace Ui {
16     class EveSettingsDialog;
17 }
18
19 class EveSettingsDialog : public QDialog {
20     Q_OBJECT
21 public:
22     EveSettingsDialog(QWidget *parent = 0);
23
24     EveCharacter *selectedCharacter();
25     QSharedPointer<EveModel> model() { return m_model; }
26     void setModel(QSharedPointer<EveModel> &model);
27 protected:
28     void changeEvent(QEvent *e);
29 public slots:
30     void tryLoadCharacters();
31     void charactersLoaded();
32     void characterSelected();
33 private:
34     QSharedPointer<EveModel> m_model;
35     QNetworkReply *m_reply;
36     EveCharacter *m_selection;
37     QLineEdit *userIdEdit;
38     QLineEdit *apiKeyEdit;
39     QMaemo5ValueButton *characterPicker;
40     QMaemo5ListPickSelector *characterSelector;
41     QStandardItemModel *characterModel;
42     QVBoxLayout *m_layout;
43
44 };
45
46 #endif // EVESETTINGSDIALOG_H