summaryrefslogtreecommitdiffstats
path: root/client/src/com/vaadin/client/ui/VOptionGroup.java
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/com/vaadin/client/ui/VOptionGroup.java')
-rw-r--r--client/src/com/vaadin/client/ui/VOptionGroup.java13
1 files changed, 11 insertions, 2 deletions
diff --git a/client/src/com/vaadin/client/ui/VOptionGroup.java b/client/src/com/vaadin/client/ui/VOptionGroup.java
index eed5549e39..a4c8b6733c 100644
--- a/client/src/com/vaadin/client/ui/VOptionGroup.java
+++ b/client/src/com/vaadin/client/ui/VOptionGroup.java
@@ -41,6 +41,7 @@ import com.google.gwt.user.client.ui.Panel;
import com.google.gwt.user.client.ui.RadioButton;
import com.google.gwt.user.client.ui.Widget;
import com.vaadin.client.ApplicationConnection;
+import com.vaadin.client.BrowserInfo;
import com.vaadin.client.UIDL;
import com.vaadin.client.Util;
import com.vaadin.shared.EventId;
@@ -161,8 +162,16 @@ public class VOptionGroup extends VOptionGroupBase implements FocusHandler,
public void onClick(ClickEvent event) {
super.onClick(event);
if (event.getSource() instanceof CheckBox) {
- final boolean selected = ((CheckBox) event.getSource()).getValue();
- final String key = optionsToKeys.get(event.getSource());
+ CheckBox source = (CheckBox) event.getSource();
+
+ if (BrowserInfo.get().isWebkit()) {
+ // Webkit does not focus non-text input elements on click
+ // (#11854)
+ source.setFocus(true);
+ }
+
+ final boolean selected = source.getValue();
+ final String key = optionsToKeys.get(source);
if (!isMultiselect()) {
selectedKeys.clear();
}