πŸš€ go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.api
Article #820

simulating mouseclicks on MenuBar class

#820
From: David Komanek
Date: Thu, 29 Aug 2002 14:04
18 lines
1428 bytes
Please, is there a way to generate events to simulate mouseclicks on
the MenuBar component of the frame ? I assigned the MenuBar by calling

menuBarMain = new java.awt.MenuBar();
menuMainGeneral = new java.awt.Menu("General");
menuMainTools = new java.awt.Menu("Tools");
....
setMenuBar(menuBarMain);

and need to learn how to open the Menu "General" or Menu "Tools"
without real clicking with the mouse, for example upon a keyboard
shortcut. I am able to capture the keyboard clicks with specific
KeyAdapter, but donοΏ½t know how to generate the event MenuBar could
react to.

Thanks in advance,

  David
Technical Details
Message-ID: <e54ab944.0208290604.96dff79@posting.google.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!postnews1.google.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 1089d0,f16c32ace7da0dcf,start
X-Google-Attributes: gid1089d0,public
X-Google-ArrivalTime: 2002-08-29 07:04:27 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!postnews1.google.com!not-for-mail
From: komanek@natur.cuni.cz (David Komanek)
Newsgroups: borland.public.jbuilder.java.api
Subject: simulating mouseclicks on MenuBar class
Date: 29 Aug 2002 07:04:27 -0700
Organization: http://groups.google.com/
Lines: 18
Message-ID: <e54ab944.0208290604.96dff79@posting.google.com>
NNTP-Posting-Host: 195.113.56.250
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
X-Trace: posting.google.com 1030629867 1127 127.0.0.1 (29 Aug 2002 14:04:27 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: 29 Aug 2002 14:04:27 GMT