Diffstat (limited to 'core/settings/security/multiauthconfig.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/settings/security/multiauthconfig.h | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/core/settings/security/multiauthconfig.h b/core/settings/security/multiauthconfig.h index 5287083..e64795c 100644 --- a/core/settings/security/multiauthconfig.h +++ b/core/settings/security/multiauthconfig.h | |||
@@ -54,59 +54,64 @@ | |||
54 | #include <qtextstream.h> | 54 | #include <qtextstream.h> |
55 | 55 | ||
56 | /* UI */ | 56 | /* UI */ |
57 | #include "syncbase.h" | 57 | #include "syncbase.h" |
58 | #include "loginbase.h" | 58 | #include "loginbase.h" |
59 | 59 | ||
60 | class MultiauthConfig; | ||
61 | class MultiauthGeneralConfig; | ||
60 | 62 | ||
61 | /// the "misc" configuration tab, about general Opie Multiauth settings | 63 | /// the "misc" configuration tab, about general Opie Multiauth settings |
62 | class MultiauthGeneralConfig : public QWidget | 64 | class MultiauthGeneralConfig : public QWidget |
63 | { | 65 | { |
64 | Q_OBJECT | 66 | Q_OBJECT |
65 | public: | 67 | public: |
66 | MultiauthGeneralConfig(QWidget * parent, const char * name); | 68 | MultiauthGeneralConfig(MultiauthConfig * parentConfig, QWidget * parent, const char * name); |
67 | ~MultiauthGeneralConfig(); | 69 | ~MultiauthGeneralConfig(); |
68 | protected: | 70 | protected: |
69 | QCheckBox *onStart, *onResume, *noProtectConfig, *explanScreens, *allowBypass; | 71 | QCheckBox *m_onStart, *m_onResume, *m_noProtectConfig, *m_explanScreens; |
70 | QSpinBox *nbSuccessMin; | 72 | QSpinBox *m_nbSuccessMin; |
71 | private: | 73 | private: |
72 | friend class MultiauthConfig; | 74 | friend class MultiauthConfig; |
75 | /// pointer to the MultiauthConfig that called us | ||
76 | MultiauthConfig *m_parentConfig; | ||
77 | QPushButton *m_tryButton; | ||
73 | private slots: | 78 | private slots: |
74 | void checkBypass(); | 79 | void tryAuth(); |
75 | void checkScreens(); | ||
76 | }; | 80 | }; |
77 | 81 | ||
78 | /// the whole configuration dialog | 82 | /// the whole configuration dialog |
79 | class MultiauthConfig : public QDialog | 83 | class MultiauthConfig : public QDialog |
80 | { | 84 | { |
81 | Q_OBJECT | 85 | Q_OBJECT |
82 | 86 | ||
83 | public: | 87 | public: |
84 | static QString appName() { return QString::fromLatin1("security"); } | 88 | static QString appName() { return QString::fromLatin1("security"); } |
85 | MultiauthConfig(QWidget *parent, const char* name, WFlags fl); | 89 | MultiauthConfig(QWidget *parent, const char* name, WFlags fl); |
86 | virtual ~MultiauthConfig(); | 90 | virtual ~MultiauthConfig(); |
87 | void writeConfig(); | ||
88 | QList<Opie::Security::MultiauthConfigWidget> configWidgetList; | 91 | QList<Opie::Security::MultiauthConfigWidget> configWidgetList; |
89 | 92 | ||
90 | protected slots: | 93 | protected slots: |
91 | void accept(); | 94 | void accept(); |
92 | void done(int r); | 95 | void done(int r); |
93 | void pluginsChanged(); | 96 | void pluginsChanged(); |
94 | void moveSelectedUp(); | 97 | void moveSelectedUp(); |
95 | void moveSelectedDown(); | 98 | void moveSelectedDown(); |
99 | void writeConfigs(); | ||
96 | 100 | ||
97 | private slots: | 101 | private slots: |
98 | // Login and Sync stuff | 102 | // Login and Sync stuff |
99 | void setSyncNet(const QString&); | 103 | void setSyncNet(const QString&); |
100 | void changeLoginName(int); | 104 | void changeLoginName(int); |
101 | void toggleAutoLogin(bool); | 105 | void toggleAutoLogin(bool); |
102 | void restoreDefaults(); | 106 | void restoreDefaults(); |
103 | void insertDefaultRanges(); | 107 | void insertDefaultRanges(); |
104 | void deleteListEntry(); | 108 | void deleteListEntry(); |
105 | 109 | ||
106 | private: | 110 | private: |
111 | friend class MultiauthGeneralConfig; | ||
107 | /// the widget holding all the tabs (or pages) | 112 | /// the widget holding all the tabs (or pages) |
108 | Opie::Ui::OTabWidget *m_mainTW; | 113 | Opie::Ui::OTabWidget *m_mainTW; |
109 | /// list of authentication plugins in the "Plugins" page | 114 | /// list of authentication plugins in the "Plugins" page |
110 | QListView *m_pluginListView; | 115 | QListView *m_pluginListView; |
111 | QStringList m_allPlugins, m_excludePlugins; | 116 | QStringList m_allPlugins, m_excludePlugins; |
112 | QMap<QString,QCheckListItem*> m_plugins; | 117 | QMap<QString,QCheckListItem*> m_plugins; |
@@ -121,12 +126,13 @@ private: | |||
121 | 126 | ||
122 | int m_nbSuccessReq; | 127 | int m_nbSuccessReq; |
123 | bool m_plugins_changed; | 128 | bool m_plugins_changed; |
124 | bool m_pluginsInstalled; | 129 | bool m_pluginsInstalled; |
125 | 130 | ||
126 | void readConfig(); | 131 | void readConfig(); |
132 | void writeConfig(); | ||
127 | void loadPlugins(); | 133 | void loadPlugins(); |
128 | 134 | ||
129 | // Login and Sync stuff | 135 | // Login and Sync stuff |
130 | void loadUsers(); | 136 | void loadUsers(); |
131 | bool telnetAvailable() const; | 137 | bool telnetAvailable() const; |
132 | bool sshAvailable() const; | 138 | bool sshAvailable() const; |