[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdelibs/khtml/html
From:       Germain Garand <germain () ebooksfrance ! com>
Date:       2005-03-29 1:56:29
Message-ID: 20050329015629.55B14630 () office ! kde ! org
[Download RAW message or body]

CVS commit by ggarand: 

focus form fields on the way when filling wallet information, and *before*
setting the value. Otherwise onfocus handlers might clear the last field.

BUG: 100530


  M +1 -4      html_formimpl.cpp   1.430


--- kdelibs/khtml/html/html_formimpl.cpp  #1.429:1.430
@@ -444,5 +444,4 @@ void HTMLFormElementImpl::walletOpened(K
         return; // failed, abort
 
-    HTMLInputElementImpl *last = 0L;
     for (QPtrListIterator<HTMLGenericFormElementImpl> it(formElements); it.current(); ++it) {
         if (it.current()->id() == ID_INPUT) {
@@ -452,11 +451,9 @@ void HTMLFormElementImpl::walletOpened(K
                     !current->readOnly() &&
                     map.contains(current->name().string())) {
+                getDocument()->setFocusNode(current);
                 current->setValue(map[current->name().string()]);
-                last = current;
             }
         }
     }
-
-    getDocument()->setFocusNode(last);
 }
 


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic