From 21a8ed6f269cced8dbed199f24efd50a212444a3 Mon Sep 17 00:00:00 2001 From: Artur Signell Date: Wed, 14 Mar 2012 15:04:55 +0200 Subject: [PATCH] Made TabSheet compatible with older TestBench scripts --- src/com/vaadin/terminal/gwt/client/ComponentLocator.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/com/vaadin/terminal/gwt/client/ComponentLocator.java b/src/com/vaadin/terminal/gwt/client/ComponentLocator.java index ae9f077912..f6aaf3edd3 100644 --- a/src/com/vaadin/terminal/gwt/client/ComponentLocator.java +++ b/src/com/vaadin/terminal/gwt/client/ComponentLocator.java @@ -14,6 +14,7 @@ import com.google.gwt.user.client.ui.Widget; import com.vaadin.terminal.gwt.client.ui.SubPartAware; import com.vaadin.terminal.gwt.client.ui.VGridLayout; import com.vaadin.terminal.gwt.client.ui.VMeasuringOrderedLayout; +import com.vaadin.terminal.gwt.client.ui.VTabsheetPanel; import com.vaadin.terminal.gwt.client.ui.VView; import com.vaadin.terminal.gwt.client.ui.VWindow; @@ -465,6 +466,12 @@ public class ComponentLocator { continue; } + if (w instanceof VTabsheetPanel && !"0".equals(indexString)) { + // TabSheetPanel now only contains 1 connector => the index + // is always 0 which indicates the widget in the active tab + indexString = "0"; + } + /* * The new grid and ordered layotus do not contain * ChildComponentContainer widgets. This is instead simulated by -- 2.39.5