Hi, Janak!

Thanks a lot for response!
But I've enabled "Look and Feel" to Windows mode. And in this case I
expect the same behavior as it is done for the Windows - always both
enter and space keys click the same button. The main behavior difference
is that "default" message box button in windows is focused by default.

Using the Windows "Look and Feel" mode I have "ok" button pressed by
both enter and space keys and initial value has no effect and no meaning
in this case. I believe this is wrong exactly for "windows" behavior
case, how I can select the "cancel" button by default in this case else?

 
~~~~~~~~~~~~~~~~~~~~~~
Vitaliy Tkachenko
Senior Software Engineer
Mirasoft
 
E-mail: [EMAIL PROTECTED]
Work phone: +380 44 4929960
Cellular phone: +380 66 7406009
ICQ: 40299155
Skype: virtualvat
 

-----Original Message-----
From: 
Sent: Wednesday, February 07, 2007 6:57 PM
To: Vitaliy Tkachenko
Cc: Vitaliy Tkachenko; [email protected]
Subject: RE: [ULC-developer] Bug found: ULCAlert.setInitialValue doesn't
work

Hi Vitaliy,

This is not a Bug. The behaviour is consistent with JOptionPane of
Swing.

setInitialValue("Cancel") will make the Cancel button the default
button.

The default command button is the button that the application activates
when
users press Enter (or Return). JFC gives the default command button a
heavier border than other command buttons. The default button does not
need
to have keyboard focus when users press Enter.

So if you press Enter key, Cancel button will be clicked even though the
focus is on the Ok button.

Thanks and regards,

Janak


>-----Original Message-----
>From: [EMAIL PROTECTED]
>[mailto:[EMAIL PROTECTED] Behalf Of Vitaliy
>Tkachenko
>Sent: Wednesday, February 07, 2007 3:00 PM
>To: [EMAIL PROTECTED]
>Cc: [EMAIL PROTECTED] Com; Janak Mulani
>Subject: [ULC-developer] Bug found: ULCAlert.setInitialValue doesn't
>work
>
>
>Hi, ladies and gentlemen!
>
>       Component:              ULCBase, core
>
>       Version:                6.1.1
>
>       Bug description:
>====================
>ULCAlert dialog = new ULCAlert((ULCRootPane)null, "Test title", "Test
>message", null);
>dialog.setFirstButtonLabel("Ok");
>dialog.setSecondButtonLabel("Cancel");
>dialog.setInitialValue("Cancel");
>dialog.show();
>====================
>This code results in the "Ok" button focused by default.
>
>       Environment:
>Windows XP
>
>
>~~~~~~~~~~~~~~~~~~~~~~
>Vitaliy Tkachenko
>Senior Software Engineer
>Mirasoft
>
>E-mail: [EMAIL PROTECTED]
>Work phone: +380 44 4929960
>Cellular phone: +380 66 7406009
>ICQ: 40299155
>Skype: virtualvat
>
>
>-----Original Message-----
>From: Janak Mulani [mailto:[EMAIL PROTECTED]
>Sent: Wednesday, February 07, 2007 3:02 PM
>To: Vitaliy Tkachenko
>Cc: [EMAIL PROTECTED] Com
>Subject: Your issues
>
>Hi Vitaly,
>
>Please post your issues on the developer list. We can create JIRA
issues
>after proper analysis because some of the issues may be non issues or
>duplicates.
>
>Thanks and regards,
>
>Janak
>
>_______________________________________________
>ULC-developer mailing list
>[email protected]
>http://lists.canoo.com/mailman/listinfo/ulc-developer

_______________________________________________
ULC-developer mailing list
[email protected]
http://lists.canoo.com/mailman/listinfo/ulc-developer

Reply via email to