source: src-qt4/PCDM/src/pcdm-gui.h @ 1620346

9.1-release9.2-releasereleng/10.0releng/10.0.1releng/10.0.2releng/10.0.3
Last change on this file since 1620346 was 1620346, checked in by Kris Moore <kris@…>, 17 months ago

Initial import of PC-BSD /current/ SVN repo

  • Property mode set to 100644
File size: 2.0 KB
Line 
1/* PCDM Login Manager:
2*  Written by Ken Moore (ken@pcbsd.org) 2012/2013
3*  Copyright(c) 2013 by the PC-BSD Project
4*  Available under the 3-clause BSD license
5*/
6
7#ifndef PCDMGUI_H
8#define PCDMGUI_H
9
10#include <QtGui/QWidget>
11#include <QMessageBox>
12#include <QFile>
13#include <QGraphicsScene>
14#include <QMainWindow>
15#include <QToolBar>
16#include <QToolButton>
17#include <QMenu>
18#include <QLabel>
19#include <QComboBox>
20#include <QPushButton>
21#include <QLineEdit>
22#include <QGridLayout>
23#include <QSpacerItem>
24#include <QProcessEnvironment>
25
26#include "pcdm-backend.h"
27#include "themeStruct.h"
28#include "fancySwitcher.h"
29#include "dialogKeyboard.h"
30#include "dialogLocale.h"
31#include "loginWidget.h"
32
33#define TMPLANGFILE QString("/tmp/.PCDMLang")
34
35class PCDMgui : public QMainWindow
36{
37    Q_OBJECT
38
39public:
40    PCDMgui();
41    ~PCDMgui();
42    void changeLang(QString code);
43    void progInit();
44
45private slots:
46    void slotStartLogin(QString,QString);
47    void slotLoginSuccess();
48    void slotLoginFailure();
49    void slotUserChanged(QString);
50    void slotUserSelected(QString);
51    void slotRestartComputer();
52    void slotShutdownComputer();
53    void slotClosePCDM();
54    void slotChangeLocale();
55    void slotChangeKeyboardLayout();
56    void slotPushVirtKeyboard();    // Start xvkbd
57    void slotLocaleChanged(QString);
58
59private:
60    //Objects
61    LoginWidget* loginW;
62    widgetKeyboard* wKey;
63    widgetLocale* wLoc;
64    QToolBar* toolbar;
65    QAction *virtkeyboardButton, *localeButton, *keyboardButton;
66    QToolButton *systemButton;
67    QMenu* systemMenu;
68    FancySwitcher* deSwitcher;
69
70    QProcess* vkbd;
71    ThemeStruct* currentTheme;
72
73    QTranslator* m_translator;
74    QString translationDir, lastUser, lastDE;
75   
76    QString hostname;
77    //Functions
78    void createGUIfromTheme();
79    void retranslateUi();
80    void loadTheme();
81    void loadLastUser();
82    void loadLastDE(QString);
83    void saveLastLogin(QString, QString);
84
85signals:
86    void xLoginAttempt(QString, QString, QString, QString);
87
88};
89
90#endif // PCDMGUI_H
Note: See TracBrowser for help on using the repository browser.