0

I have implemented a SDMultiWheel in my Android app. I use the ControlValueChanged event to get the newly selected value, something like this:

Event &var2.ControlValueChanged  //var2 being the wheelcontrol
    msg(&var2)
Endevent

What's strange is that the msg returns, not the selected value, but the old one (value before the selection).

How can I get the new selected value?

Jaime
  • 159
  • 2
  • 10
  • That should work. The string should be the same json as before, but with the "Value" property updated. What version are you testing this on? – matiash Feb 13 '15 at 15:14
  • Yes, i get a Json string, but with the previous value (if I change from 2 to 3 - string will have the value 2). I am using Ev3 U2 (10.3.87166). – Jaime Feb 13 '15 at 18:47
  • http://i.imgur.com/uWk845X.jpg – Jaime Feb 13 '15 at 19:15

1 Answers1

0

Sorry for the confusion. I could not reproduce the problem because this issue is already fixed it our codebase. Both the Wheel and Multiwheel controls were reporting the old value when firing the ControlValueChanged event.

The fix will be released as part of GX Evolution 3 Upgrade 3, there are nightly builds available here if you want to try it.

If necessary, you should be able to backport the fix to U2. The changed files are:

WheelsLib/src/com/artech/controls/wheel/GxMultiWheelPicker.java
WheelsLib/src/com/artech/controls/wheel/GxWheelControl.java
WheelsLib/src/com/artech/controls/wheel/measures/GxMeasuresControl.java
matiash
  • 54,791
  • 16
  • 125
  • 154