author | zecke <zecke> | 2004-07-09 21:36:37 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-07-09 21:36:37 (UTC) |
commit | 944adb8bf2741a16cf627d19e08f51c08920ad89 (patch) (unidiff) | |
tree | 5f9edc9784e0268a00fe68ec74d7151900c5183a /core/opie-login/loginwindowimpl.cpp | |
parent | c5d3262afd775bce81b99c5dc06e74c4686cee2a (diff) | |
download | opie-944adb8bf2741a16cf627d19e08f51c08920ad89.zip opie-944adb8bf2741a16cf627d19e08f51c08920ad89.tar.gz opie-944adb8bf2741a16cf627d19e08f51c08920ad89.tar.bz2 |
Add setting a root password if none is set to opie-login
If you directly start Opie-Taskbar or use AutoLogin
you will not be presented by a set root password gui
Diffstat (limited to 'core/opie-login/loginwindowimpl.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/opie-login/loginwindowimpl.cpp | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/core/opie-login/loginwindowimpl.cpp b/core/opie-login/loginwindowimpl.cpp index 32f98f3..73c2cbe 100644 --- a/core/opie-login/loginwindowimpl.cpp +++ b/core/opie-login/loginwindowimpl.cpp | |||
@@ -47,6 +47,7 @@ | |||
47 | #include <stdio.h> | 47 | #include <stdio.h> |
48 | #include <stdlib.h> | 48 | #include <stdlib.h> |
49 | 49 | ||
50 | #include "passworddialogimpl.h" | ||
50 | #include "loginwindowimpl.h" | 51 | #include "loginwindowimpl.h" |
51 | #include "loginapplication.h" | 52 | #include "loginapplication.h" |
52 | #include "inputmethods.h" | 53 | #include "inputmethods.h" |
@@ -90,7 +91,7 @@ LoginWindowImpl::LoginWindowImpl ( ) : LoginWindow ( 0, "LOGIN-WINDOW", WStyle_C | |||
90 | TextLabel2-> setBackgroundPixmap ( bgpix); | 91 | TextLabel2-> setBackgroundPixmap ( bgpix); |
91 | } | 92 | } |
92 | 93 | ||
93 | m_caption-> setText ( tr("<center>Welcome to OPIE %1</center><center>& %2 %3</center>"). arg(QPE_VERSION). arg ( ODevice::inst ( )-> systemString ( )). arg ( ODevice::inst ( )-> systemVersionString ( ))); | 94 | //m_caption-> setText ( tr("<center>Welcome to OPIE %1</center><center>& %2 %3</center>"). arg(QPE_VERSION). arg ( ODevice::inst ( )-> systemString ( )). arg ( ODevice::inst ( )-> systemVersionString ( ))); |
94 | 95 | ||
95 | Config cfg ( "opie-login" ); | 96 | Config cfg ( "opie-login" ); |
96 | cfg. setGroup ( "General" ); | 97 | cfg. setGroup ( "General" ); |
@@ -100,6 +101,11 @@ LoginWindowImpl::LoginWindowImpl ( ) : LoginWindow ( 0, "LOGIN-WINDOW", WStyle_C | |||
100 | m_user-> setEditText ( last ); | 101 | m_user-> setEditText ( last ); |
101 | 102 | ||
102 | calcMaxWindowRect ( ); | 103 | calcMaxWindowRect ( ); |
104 | |||
105 | if ( PasswordDialogImpl::needDialog() ) | ||
106 | QTimer::singleShot(10, this, SLOT(showPasswordDialog()) ); | ||
107 | |||
108 | |||
103 | } | 109 | } |
104 | 110 | ||
105 | LoginWindowImpl::~LoginWindowImpl ( ) | 111 | LoginWindowImpl::~LoginWindowImpl ( ) |
@@ -248,3 +254,9 @@ void LoginWindowImpl::login ( ) | |||
248 | m_password-> clear ( ); | 254 | m_password-> clear ( ); |
249 | } | 255 | } |
250 | } | 256 | } |
257 | |||
258 | void LoginWindowImpl::showPasswordDialog() { | ||
259 | PasswordDialogImpl dia( this ); | ||
260 | dia.showMaximized(); | ||
261 | dia.exec(); | ||
262 | } | ||