[28945] in CVS-changelog-for-Kerberos-V5

home help back first fref pref prev next nref lref last post

krb5 commit: Put focus on password field when principal is set

daemon@ATHENA.MIT.EDU (Benjamin Kaduk)
Wed Jun 24 17:11:40 2015

Date: Wed, 24 Jun 2015 17:11:32 -0400
From: Benjamin Kaduk <kaduk@mit.edu>
Message-Id: <201506242111.t5OLBW9d007221@drugstore.mit.edu>
To: cvs-krb5@mit.edu
Reply-To: krbdev@mit.edu
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: cvs-krb5-bounces@mit.edu

https://github.com/krb5/krb5/commit/50b3bba748084c99a339bd526ad47ecfccc09472
commit 50b3bba748084c99a339bd526ad47ecfccc09472
Author: Ben Kaduk <kaduk@mit.edu>
Date:   Mon Jun 22 19:11:28 2015 -0400

    Put focus on password field when principal is set
    
    In the Leash "Get Ticket" window, under some user-customized
    configurations, the principal field can be pre-populated.  In this case,
    it makes sense for the default focus to be on the password field,
    since most users will only be using a single principal and should
    go directly to typing their password.
    
    The focus was already set to the password field in the case when
    the principal was not modifiable (such as when the "Get Ticket" dialog
    was opened by an application requesting a specific ticket).
    
    ticket: 8032
    tags: pullup
    target_version: 1.13.3

 src/windows/leashdll/lsh_pwd.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/windows/leashdll/lsh_pwd.c b/src/windows/leashdll/lsh_pwd.c
index 3c965b4..ac85625 100644
--- a/src/windows/leashdll/lsh_pwd.c
+++ b/src/windows/leashdll/lsh_pwd.c
@@ -1506,7 +1506,7 @@ AuthenticateProc(
         SetActiveWindow(hDialog);
         SetForegroundWindow(hDialog);
         /* put focus on password if princ is read-only */
-        hFocusCtrl = bReadOnlyPrinc ?
+        hFocusCtrl = (bReadOnlyPrinc || principal[0] != '\0') ?
             GetDlgItem(hDialog, IDC_EDIT_PASSWORD) : hEditCtrl;
         if (((HWND)wParam) != hFocusCtrl) {
             SetFocus(hFocusCtrl);
_______________________________________________
cvs-krb5 mailing list
cvs-krb5@mit.edu
https://mailman.mit.edu/mailman/listinfo/cvs-krb5

home help back first fref pref prev next nref lref last post