click on check-style button does not make it checked/unchecked [message #22799] |
Wed, 18 February 2009 09:57  |
Eclipse User |
|
|
|
Hi,
I came across this behavior:
I used the click() method (from SWTBotButton) on a SWT.CHECK style Button.
The button did react to it and launched its action as with a real user.
But the problem is that the button kept its state (checked or unchecked),
which lead to bugs in the app.
I found I had to manually ask for a change in the state of the button.
I mean, instead of:
Button myButton = ((Button)bot.widget(myButtonMatcher, 3));
(new SWTBotButton(myButton)).click();
I had to use:
Button myButton = ((Button)bot.widget(myButtonMatcher, 3));
myButton.setSelection(true);
(new SWTBotButton(myButton)).click();
I think this is a bug (or maybe more like a leak), I can add a bugzilla
when I get some more time, I wanted to tell it before (or in case there
was an explaination to that).
I reproduced it on windows, I can't check other OS.
|
|
|
|
Powered by
FUDForum. Page generated in 0.03137 seconds