Results 1 to 2 of 2
Thread: Strange behaviour in swing
- 05-22-2008, 01:21 PM #1Member
- Join Date
- Nov 2007
- Rep Power
Strange behaviour in swing
Today i noticed two strange behaviour in swing.
Case 1: Normally for every key events we used to get one keyPress and one keyRelease events.But this is not of the case with PrintScreen key. I tested this behaviour on the JNLP file used in java tutorial at this link itself.
Question: Why only PrintScreen has this kind of event associated with it?
Case 2: One more thing is that whenever we create a JMenu component on the JFrame we are able to access this menu by Left-Clicking on the JMenu component but accidentally i made a right click on the JMenu and that too populates the JMenu.
Question: How can i restrict Right-Clicking on the JMenu Component?
Image for your reference
1.JNLP file under my PC
Can anybody help????:eek::eek::eek:
Last edited by cbalu; 05-22-2008 at 01:22 PM. Reason: Added link
- 05-23-2008, 09:23 PM #2
- By squad in forum Advanced JavaReplies: 0Last Post: 03-21-2008, 11:55 AM
- By kantze in forum New To JavaReplies: 2Last Post: 03-19-2008, 02:44 PM
- By ppayal in forum EclipseReplies: 0Last Post: 11-25-2007, 07:19 PM
- By adoorsarath in forum Advanced JavaReplies: 3Last Post: 08-10-2007, 05:02 PM
- By elizabeth in forum New To JavaReplies: 1Last Post: 07-30-2007, 07:02 PM