rigelhope / omnidroid

Automatically exported from code.google.com/p/omnidroid
Apache License 2.0
0 stars 0 forks source link

Attribute gets inserted even if user chooses none #150

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create a new rule.
2. Press add action.
3. Select Omnidroid > Display Alert > Add attributes.
4. Press the back button.

What is the expected output? What do you see instead?
An attribute tag will be inserted even though no attribute was chosen.

Original issue reported on code.google.com by renc...@gmail.com on 29 Jul 2010 at 6:01

GoogleCodeExporter commented 8 years ago
Code review:
http://codereview.appspot.com/1910042

Caused by:
When the list of attributes activity loads, the first item is already selected 
by default.

Fix detail:
Set the selected index to an invalid index on load.

Test Cases:
1. Try to open the list of attributes activity
  1.1 Do not select anything and press back. The attribute should not be inserted.
  1.2 Select an attribute. The attribute should be inserted.
  1.3 Do 1.2 then 1.1. No new attribute tag should not be inserted.

Original comment by renc...@gmail.com on 29 Jul 2010 at 6:10

GoogleCodeExporter commented 8 years ago
Checked-in @ r837.

Original comment by renc...@gmail.com on 29 Jul 2010 at 8:36