From 36a201f22f66989bf7a78ce8afce1ee64aaa0a22 Mon Sep 17 00:00:00 2001 From: Artur Signell Date: Wed, 6 Mar 2013 14:55:15 +0200 Subject: Fixed focus and tab index handling for UI (#11129) Change-Id: I80377792ade11946337e2900a7ea84209ae1d060 --- server/src/com/vaadin/ui/UI.java | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'server/src/com/vaadin/ui') diff --git a/server/src/com/vaadin/ui/UI.java b/server/src/com/vaadin/ui/UI.java index d12c8d89c9..796d1f08ea 100644 --- a/server/src/com/vaadin/ui/UI.java +++ b/server/src/com/vaadin/ui/UI.java @@ -78,7 +78,7 @@ import com.vaadin.util.CurrentInstance; * @since 7.0 */ public abstract class UI extends AbstractSingleComponentContainer implements - Action.Container, Action.Notifier, LegacyComponent { + Action.Container, Action.Notifier, LegacyComponent, Focusable { /** * The application to which this UI belongs @@ -183,6 +183,11 @@ public abstract class UI extends AbstractSingleComponentContainer implements return (UIState) super.getState(); } + @Override + protected UIState getState(boolean markAsDirty) { + return (UIState) super.getState(markAsDirty); + } + @Override public Class getStateType() { // This is a workaround for a problem with creating the correct state @@ -1039,4 +1044,14 @@ public abstract class UI extends AbstractSingleComponentContainer implements } super.setContent(content); } + + @Override + public void setTabIndex(int tabIndex) { + getState().tabIndex = tabIndex; + } + + @Override + public int getTabIndex() { + return getState(false).tabIndex; + } } -- cgit v1.2.3