source: lumina/lumina-desktop/SystemWindow.h @ 9d0ec76

enter/10releng/10.0.3releng/10.1releng/10.1.1releng/10.1.2
Last change on this file since 9d0ec76 was 9d0ec76, checked in by Ken Moore <ken@…>, 12 months ago

Update lumina-desktop to use the new abilities in LuminaOS instead of the GLobals.h file. Now all the OS-specific stuff is contained in a single location.

  • Property mode set to 100644
File size: 948 bytes
Line 
1#ifndef _LUMINA_DESKTOP_SYSTEM_WINDOW_H
2#define _LUMINA_DESKTOP_SYSTEM_WINDOW_H
3
4#include <QDialog>
5#include <QCoreApplication>
6#include <QDesktopWidget>
7#include <QList>
8
9#include "ui_SystemWindow.h"
10#include "Globals.h"
11
12#include <LuminaXDG.h>
13#include <LuminaX11.h>
14#include <LuminaOS.h>
15
16
17
18namespace Ui{
19        class SystemWindow;
20};
21
22class SystemWindow : public QDialog{
23        Q_OBJECT
24public:
25        SystemWindow();
26        ~SystemWindow();
27
28private:
29        Ui::SystemWindow *ui;
30
31        void closeAllWindows(){
32          QList<WId> WL = LX11::WindowList();
33          for(int i=0; i<WL.length(); i++){
34            LX11::CloseWindow(WL[i]);
35          }
36        }
37       
38private slots:
39        void sysLogout(){
40          closeAllWindows();
41          QCoreApplication::exit(0);
42        }
43       
44        void sysRestart(){
45          closeAllWindows();
46          LOS::systemRestart();
47          QCoreApplication::exit(0);           
48        }
49       
50        void sysShutdown(){
51          closeAllWindows();
52          LOS::systemShutdown();
53          QCoreApplication::exit(0);
54        }
55       
56        void sysCancel(){
57          this->close();
58        }
59};
60
61#endif
Note: See TracBrowser for help on using the repository browser.