Menu Bar is missing in Java 1.5?
Ayse Abacioglu
ayse.abacioglu at gmail.com
Fri Mar 16 19:11:11 MET 2007
hi,
I am seeing the following problem after upgrade to Java 1.5 version.
When trying to create a frame + terminal with MENU bar - a basic menu bar
like
file, edit and etc.... it is not creating the frame with this menu bar.
The menu bar is missing from the terminal.
I have the following code which does this.
frame = (haveMenus ? AWTConvenience.newFrameWithMenuBar() :
new Frame());
terminal = new TerminalWin(frame, props);
RandomSeed seed = new RandomSeed();
terminal.addAsEntropyGenerator(seed);
frame.setLayout(new BorderLayout());
frame.add(terminal.getPanelWithScrollbar(), BorderLayout.CENTER
);
TerminalFrameTitle frameTitle =
new TerminalFrameTitle(frame, getTitle());
frameTitle.attach(terminal);
TerminalMenuHandler tmenus = null;
if(haveMenus) {
try {
tmenus = (TerminalMenuHandler)
Class.forName("
com.mindbright.terminal.TerminalMenuHandlerFull").newInstance();
tmenus.setTitleName(getTitle());
tmenus.addBasicMenus(terminal, frame);
tmenus.setTerminalMenuListener(this);
}
} else {
terminal.setClipboard(GlobalClipboard.getClipboardHandler
());
}
frame.addWindowListener(this);
frame.pack();
frame.show();
The code which was in earlier version of Java was working fine. But there
was a change in the TerminalWin constructor.
Before the constructor was like
terminal = new TerminalWin(frame, new TerminalXTerm(), props);
Does this make a difference ?
Thanks,
Ayse
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mindterm.appgate.com/pipermail/mindterm-users/attachments/20070316/d4b4c3e4/attachment.htm
More information about the Mindterm-users
mailing list