diff options
author | Jeremy Stucki <jeremy@myelin.ch> | 2018-11-02 11:51:23 +0100 |
---|---|---|
committer | Sun Zhe <31067185+ZheSun88@users.noreply.github.com> | 2018-11-02 12:51:23 +0200 |
commit | 09207941a982b825dbd429b71c7e89712a3da8f2 (patch) | |
tree | e3e99d9e97d07629608ca3335e854bc7172b7486 /server | |
parent | 4d053a9c1ce1ef0ac63769867c4f89f74a99de26 (diff) | |
download | vaadin-framework-09207941a982b825dbd429b71c7e89712a3da8f2.tar.gz vaadin-framework-09207941a982b825dbd429b71c7e89712a3da8f2.zip |
Make value changes in color picker user originated (#11252)
* Make value changes in color picker user originated
This is not a programmatically initiated event, so it should have the
'userOriginated' property set to 'true'.
- Added test to verify that indeed event is user originated after the change
Diffstat (limited to 'server')
-rw-r--r-- | server/src/main/java/com/vaadin/ui/AbstractColorPicker.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/src/main/java/com/vaadin/ui/AbstractColorPicker.java b/server/src/main/java/com/vaadin/ui/AbstractColorPicker.java index be359cc2ff..cf4c8c8b74 100644 --- a/server/src/main/java/com/vaadin/ui/AbstractColorPicker.java +++ b/server/src/main/java/com/vaadin/ui/AbstractColorPicker.java @@ -464,8 +464,8 @@ public abstract class AbstractColorPicker extends AbstractField<Color> { window.addCloseListener( event -> getState().popupVisible = false); window.addValueChangeListener(event -> { - setValue(event.getValue()); - rpc.changeColor(event.getValue().getCSS()); + window.setValue(color); + setValue(event.getValue(), true); }); window.getHistory().setValue(color); window.setPositionX(positionX); |