Removed special case from widget set that used to support VButton changing into VCheckBox Corrected teststags/7.0.0.alpha1
@@ -6,8 +6,6 @@ package com.vaadin.terminal.gwt.client; | |||
import com.google.gwt.core.client.GWT; | |||
import com.google.gwt.user.client.ui.Widget; | |||
import com.vaadin.terminal.gwt.client.ui.VButton; | |||
import com.vaadin.terminal.gwt.client.ui.VCheckBox; | |||
import com.vaadin.terminal.gwt.client.ui.VFilterSelect; | |||
import com.vaadin.terminal.gwt.client.ui.VListSelect; | |||
import com.vaadin.terminal.gwt.client.ui.VPasswordField; | |||
@@ -79,9 +77,7 @@ public class WidgetSet { | |||
// add our historical quirks | |||
if (widgetClass == VButton.class && uidl.hasAttribute("type")) { | |||
return VCheckBox.class; | |||
} else if (widgetClass == VView.class && uidl.hasAttribute("sub")) { | |||
if (widgetClass == VView.class && uidl.hasAttribute("sub")) { | |||
return VWindow.class; | |||
} else if (widgetClass == VFilterSelect.class) { | |||
if (uidl.hasAttribute("type")) { | |||
@@ -143,9 +139,7 @@ public class WidgetSet { | |||
* is in multiselect mode, causing the clientside implementation to | |||
* *actually* be VListSelect, when the annotation says VFilterSelect | |||
*/ | |||
if (fullyqualifiedName.equals("com.vaadin.ui.Button")) { | |||
loadImplementation(VCheckBox.class); | |||
} else if (fullyqualifiedName.equals("com.vaadin.ui.Select")) { | |||
if (fullyqualifiedName.equals("com.vaadin.ui.Select")) { | |||
loadImplementation(VListSelect.class); | |||
} else if (fullyqualifiedName.equals("com.vaadin.ui.TextField")) { | |||
loadImplementation(VTextArea.class); |
@@ -9,6 +9,7 @@ import java.io.Serializable; | |||
import java.lang.reflect.Method; | |||
import java.util.Map; | |||
import com.vaadin.event.Action; | |||
import com.vaadin.event.FieldEvents; | |||
import com.vaadin.event.FieldEvents.BlurEvent; | |||
import com.vaadin.event.FieldEvents.BlurListener; | |||
@@ -37,7 +38,8 @@ import com.vaadin.ui.Component.Focusable; | |||
@SuppressWarnings("serial") | |||
@ClientWidget(value = VButton.class, loadStyle = LoadStyle.EAGER) | |||
public class Button extends AbstractComponent implements | |||
FieldEvents.BlurNotifier, FieldEvents.FocusNotifier, Focusable { | |||
FieldEvents.BlurNotifier, FieldEvents.FocusNotifier, Focusable, | |||
Action.ShortcutNotifier { | |||
/* Private members */ | |||
@@ -5,16 +5,17 @@ import com.vaadin.data.Property.ReadOnlyStatusChangeListener; | |||
import com.vaadin.data.Property.ValueChangeEvent; | |||
import com.vaadin.data.Property.ValueChangeListener; | |||
import com.vaadin.tests.server.component.AbstractListenerMethodsTest; | |||
import com.vaadin.ui.Button; | |||
import com.vaadin.ui.CheckBox; | |||
public class TestAbstractFieldListeners extends AbstractListenerMethodsTest { | |||
public void testReadOnlyStatusChangeListenerAddGetRemove() throws Exception { | |||
testListenerAddGetRemove(Button.class, ReadOnlyStatusChangeEvent.class, | |||
testListenerAddGetRemove(CheckBox.class, | |||
ReadOnlyStatusChangeEvent.class, | |||
ReadOnlyStatusChangeListener.class); | |||
} | |||
public void testValueChangeListenerAddGetRemove() throws Exception { | |||
testListenerAddGetRemove(Button.class, ValueChangeEvent.class, | |||
testListenerAddGetRemove(CheckBox.class, ValueChangeEvent.class, | |||
ValueChangeListener.class); | |||
} | |||
} |
@@ -16,7 +16,7 @@ | |||
<td>/run/com.vaadin.tests.components.button.Buttons2?restartApplication</td> | |||
<td></td> | |||
</tr> | |||
<!--value change listener--> | |||
<!--click listener--> | |||
<tr> | |||
<td>mouseClick</td> | |||
<td>vaadin=runcomvaadintestscomponentsbuttonButtons2::PID_Smenu#item0</td> | |||
@@ -29,7 +29,7 @@ | |||
</tr> | |||
<tr> | |||
<td>mouseClick</td> | |||
<td>vaadin=runcomvaadintestscomponentsbuttonButtons2::Root/VOverlay[1]/VMenuBar[0]#item4</td> | |||
<td>vaadin=runcomvaadintestscomponentsbuttonButtons2::Root/VOverlay[1]/VMenuBar[0]#item2</td> | |||
<td>35,8</td> | |||
</tr> | |||
<!--disable on click--> | |||
@@ -45,7 +45,7 @@ | |||
</tr> | |||
<tr> | |||
<td>mouseClick</td> | |||
<td>vaadin=runcomvaadintestscomponentsbuttonButtons2::Root/VOverlay[1]/VMenuBar[0]#item1</td> | |||
<td>vaadin=runcomvaadintestscomponentsbuttonButtons2::Root/VOverlay[1]/VMenuBar[0]#item0</td> | |||
<td>22,4</td> | |||
</tr> | |||
<tr> | |||
@@ -133,7 +133,7 @@ | |||
</tr> | |||
<tr> | |||
<td>mouseClick</td> | |||
<td>vaadin=runcomvaadintestscomponentsbuttonButtons2::Root/VOverlay[1]/VMenuBar[0]#item1</td> | |||
<td>vaadin=runcomvaadintestscomponentsbuttonButtons2::Root/VOverlay[1]/VMenuBar[0]#item0</td> | |||
<td>36,3</td> | |||
</tr> | |||
<tr> | |||
@@ -151,7 +151,6 @@ | |||
<td>vaadin=runcomvaadintestscomponentsbuttonButtons2::PID_StestComponent</td> | |||
<td>v-disabled</td> | |||
</tr> | |||
</tbody></table> | |||
</body> | |||
</html> |
@@ -16,7 +16,7 @@ | |||
<td>/run/com.vaadin.tests.components.nativebutton.NativeButtonTest?restartApplication</td> | |||
<td></td> | |||
</tr> | |||
<!--value change listener--> | |||
<!-- click listener--> | |||
<tr> | |||
<td>mouseClick</td> | |||
<td>vaadin=runcomvaadintestscomponentsnativebuttonNativeButtonTest::PID_Smenu#item0</td> | |||
@@ -29,7 +29,7 @@ | |||
</tr> | |||
<tr> | |||
<td>mouseClick</td> | |||
<td>vaadin=runcomvaadintestscomponentsnativebuttonNativeButtonTest::Root/VOverlay[1]/VMenuBar[0]#item4</td> | |||
<td>vaadin=runcomvaadintestscomponentsnativebuttonNativeButtonTest::Root/VOverlay[1]/VMenuBar[0]#item2</td> | |||
<td>35,8</td> | |||
</tr> | |||
<!--disable on click--> | |||
@@ -45,7 +45,7 @@ | |||
</tr> | |||
<tr> | |||
<td>mouseClick</td> | |||
<td>vaadin=runcomvaadintestscomponentsnativebuttonNativeButtonTest::Root/VOverlay[1]/VMenuBar[0]#item1</td> | |||
<td>vaadin=runcomvaadintestscomponentsnativebuttonNativeButtonTest::Root/VOverlay[1]/VMenuBar[0]#item0</td> | |||
<td>22,4</td> | |||
</tr> | |||
<tr> | |||
@@ -133,7 +133,7 @@ | |||
</tr> | |||
<tr> | |||
<td>mouseClick</td> | |||
<td>vaadin=runcomvaadintestscomponentsnativebuttonNativeButtonTest::Root/VOverlay[1]/VMenuBar[0]#item1</td> | |||
<td>vaadin=runcomvaadintestscomponentsnativebuttonNativeButtonTest::Root/VOverlay[1]/VMenuBar[0]#item0</td> | |||
<td>36,3</td> | |||
</tr> | |||
<tr> |
@@ -55,7 +55,6 @@ public class Ticket2151 extends Application { | |||
ok = true; | |||
} catch (Exception e1) { | |||
e1.printStackTrace(); | |||
return; | |||
} | |||
if (ok) { |