KIO::PasswordDialog Class Reference
A dialog for requesting a login and a password from the end user. More...
#include <passdlg.h>
Inheritance diagram for KIO::PasswordDialog:

Public Methods | |
PasswordDialog (const QString &prompt, const QString &user, bool enableKeep=false, bool modal=true, QWidget *parent=0, const char *name=0) | |
Create a password dialog. | |
~PasswordDialog () | |
Destructor. | |
void | setPrompt (const QString &prompt) |
Sets the prompt to show to the user. | |
void | addCommentLine (const QString &label, const QString comment) |
Adds a comment line to the dialog. | |
QString | password () const |
Returns the password entered by the user. | |
QString | username () const |
Returns the username entered by the user. | |
bool | keepPassword () const |
Determines whether supplied authorization should persist even after the application has been closed. | |
void | setUserReadOnly (bool readOnly) |
Sets the username field read-only and sets the focus to the password field. | |
void | setEnableUserField (bool enable, bool=false) |
void | setPassword (const QString &password) |
Presets the password
| |
Static Public Methods | |
int | getNameAndPassword (QString &user, QString &pass, bool *keep, const QString &prompt=QString::null, bool readOnly=false, const QString &caption=QString::null, const QString &comment=QString::null, const QString &label=QString::null) |
A convienence static method for obtaining authorization information from the end user. | |
Protected Methods | |
virtual void | virtual_hook (int id, void *data) |
Detailed Description
A dialog for requesting a login and a password from the end user.KIO-Slave authors are encouraged to use SlaveBase::openPassDlg instead of directly instantiating this dialog.
Definition at line 35 of file passdlg.h.
Constructor & Destructor Documentation
|
Create a password dialog.
Definition at line 49 of file passdlg.cpp. Referenced by getNameAndPassword(). |
|
Destructor.
Definition at line 57 of file passdlg.cpp. |
Member Function Documentation
|
Sets the prompt to show to the user.
Definition at line 206 of file passdlg.cpp. |
|
Adds a comment line to the dialog. This function allows you to add one additional comment line to this widget. Calling this fucntion after a comment has already been added will not have any effect.
Definition at line 180 of file passdlg.cpp. References KStdAccel::label(), KDialogBase::mainWidget(), and QLabel::setAlignment(). |
|
Returns the password entered by the user.
Definition at line 170 of file passdlg.cpp. |
|
Returns the username entered by the user.
Definition at line 165 of file passdlg.cpp. |
|
Determines whether supplied authorization should persist even after the application has been closed.
Definition at line 175 of file passdlg.cpp. |
|
Sets the username field read-only and sets the focus to the password field.
Definition at line 218 of file passdlg.cpp. Referenced by setEnableUserField(). |
|
Definition at line 103 of file passdlg.h. References setUserReadOnly(). |
|
Presets the password
Definition at line 213 of file passdlg.cpp. |
|
A convienence static method for obtaining authorization information from the end user.
Definition at line 225 of file passdlg.cpp. References QString::isEmpty(), KStdAccel::label(), and PasswordDialog(). |
The documentation for this class was generated from the following files: