diff options
author | Matti Tahvonen <matti.tahvonen@itmill.com> | 2010-10-26 14:12:43 +0000 |
---|---|---|
committer | Matti Tahvonen <matti.tahvonen@itmill.com> | 2010-10-26 14:12:43 +0000 |
commit | a98ecb2b8d2949eec1b32a66eb8e1f5cddb5910d (patch) | |
tree | 79e82136cd61eb03490e3752c8e7869a6b4cd20b /src | |
parent | b8a8f1a387ee32b74953c054bc695349ba105849 (diff) | |
download | vaadin-framework-a98ecb2b8d2949eec1b32a66eb8e1f5cddb5910d.tar.gz vaadin-framework-a98ecb2b8d2949eec1b32a66eb8e1f5cddb5910d.zip |
fixes #5888, AC now checks against Focusable instead of FocusWidget when updating paintables tab index
svn changeset:15722/svn branch:6.5
Diffstat (limited to 'src')
-rwxr-xr-x | src/com/vaadin/terminal/gwt/client/ApplicationConnection.java | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java b/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java index fd0a9ea8aa..10536d83d5 100755 --- a/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java +++ b/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java @@ -30,6 +30,7 @@ import com.google.gwt.user.client.History; import com.google.gwt.user.client.Timer; import com.google.gwt.user.client.Window; import com.google.gwt.user.client.ui.FocusWidget; +import com.google.gwt.user.client.ui.Focusable; import com.google.gwt.user.client.ui.HasWidgets; import com.google.gwt.user.client.ui.Widget; import com.vaadin.terminal.gwt.client.RenderInformation.FloatSize; @@ -1619,12 +1620,16 @@ public class ApplicationConnection { } boolean enabled = !uidl.getBooleanAttribute("disabled"); + if (uidl.hasAttribute("tabindex") && component instanceof Focusable) { + ((Focusable) component).setTabIndex(uidl + .getIntAttribute("tabindex")); + } + /* + * Disabled state may affect (override) tabindex so the order must be + * first setting tabindex, then enabled state. + */ if (component instanceof FocusWidget) { FocusWidget fw = (FocusWidget) component; - if (uidl.hasAttribute("tabindex")) { - fw.setTabIndex(uidl.getIntAttribute("tabindex")); - } - // Disabled state may affect tabindex fw.setEnabled(enabled); } |