Skip to content

Commit

Permalink
Fix initial widget focus in credential dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn committed Jul 11, 2016
1 parent 729fc49 commit 73bf82f
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/gui/qgscredentialdialog.cpp
Expand Up @@ -43,6 +43,7 @@ QgsCredentialDialog::QgsCredentialDialog( QWidget *parent, const Qt::WindowFlags
Qt::BlockingQueuedConnection );
mOkButton = buttonBox->button( QDialogButtonBox::Ok );
leMasterPass->setPlaceholderText( tr( "Required" ) );
leUsername->setFocus();
}

QgsCredentialDialog::~QgsCredentialDialog()
Expand Down Expand Up @@ -119,6 +120,7 @@ void QgsCredentialDialog::requestCredentialsMasterPassword( QString * password,
{
QgsDebugMsg( "Entering." );
stackedWidget->setCurrentIndex( 1 );
leMasterPass->setFocus();

QString titletxt( stored ? tr( "Enter CURRENT master authentication password" ) : tr( "Set NEW master authentication password" ) );
lblPasswordTitle->setText( titletxt );
Expand Down
8 changes: 8 additions & 0 deletions src/ui/qgscredentialdialog.ui
Expand Up @@ -220,6 +220,14 @@ font-style: italic;
</item>
</layout>
</widget>
<tabstops>
<tabstop>leUsername</tabstop>
<tabstop>lePassword</tabstop>
<tabstop>leMasterPass</tabstop>
<tabstop>leMasterPassVerify</tabstop>
<tabstop>chkMasterPassShow</tabstop>
<tabstop>chkbxEraseAuthDb</tabstop>
</tabstops>
<resources/>
<connections>
<connection>
Expand Down

0 comments on commit 73bf82f

Please sign in to comment.