diff options
author | Artur Signell <artur.signell@itmill.com> | 2011-02-07 13:53:51 +0000 |
---|---|---|
committer | Artur Signell <artur.signell@itmill.com> | 2011-02-07 13:53:51 +0000 |
commit | 0230adada02cf432af6277342d2bca015efbe599 (patch) | |
tree | 96ee54470681e6335968833ce851b1f4f1ea234d /src/com/vaadin/terminal | |
parent | 09d5540fe2c2919b4e5baad39f14d05ee6ee2fd1 (diff) | |
download | vaadin-framework-0230adada02cf432af6277342d2bca015efbe599.tar.gz vaadin-framework-0230adada02cf432af6277342d2bca015efbe599.zip |
#6319 Delesecting one preselected item in multiselect ListSelect
svn changeset:17188/svn branch:6.5
Diffstat (limited to 'src/com/vaadin/terminal')
-rw-r--r-- | src/com/vaadin/terminal/gwt/client/ui/VListSelect.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/com/vaadin/terminal/gwt/client/ui/VListSelect.java b/src/com/vaadin/terminal/gwt/client/ui/VListSelect.java index e19079039d..46211bafe5 100644 --- a/src/com/vaadin/terminal/gwt/client/ui/VListSelect.java +++ b/src/com/vaadin/terminal/gwt/client/ui/VListSelect.java @@ -51,7 +51,9 @@ public class VListSelect extends VOptionGroupBase { select.addItem(optionUidl.getStringAttribute("caption"), optionUidl.getStringAttribute("key")); if (optionUidl.hasAttribute("selected")) { - select.setItemSelected(select.getItemCount() - 1, true); + int itemIndex = select.getItemCount() - 1; + select.setItemSelected(itemIndex, true); + lastSelectedIndex = itemIndex; } } if (getRows() > 0) { |