Recently, I've written a GUI but it doesn't work properly in Unix.
However, it works fine in windows98(under DOS mode). Does anyone have
similar experience before and know how to solve it?
> Recently, I've written a GUI but it doesn't work properly in Unix.
> However, it works fine in windows98(under DOS mode). Does anyone have
> similar experience before and know how to solve it?
There are so many possibilities for why this might happen it would be
ridiculous to speculate. If you want assistance it would be good if you
could describe what errors you are getting, what code you are using (at
least around the error) and what java version each of these systems are
running.
Cheers,
Adam
Ivor - 10 Sep 2003 05:49 GMT
import java.awt.*;
import javax.swing.UIManager;
import javax.swing.*;
import java.awt.event.*;
class OpenAction extends AbstractAction {
public OpenAction() {
super("Open ...", new ImageIcon("./images/toolbarIcons/open.gif"));
putValue(Action.SHORT_DESCRIPTION, "Open a DBLab File");
putValue(Action.MNEMONIC_KEY, new
Integer(java.awt.event.KeyEvent.VK_O));
putValue(Action.ACCELERATOR_KEY,
KeyStroke.getKeyStroke(KeyEvent.VK_O, Event.CTRL_MASK));
}
public void actionPerformed(ActionEvent event) {
/******** PUT ALL IMPLEMENTATION HERE!!! **************/
System.out.println("Open Works");
}
}
Above is the code that I use for adding Hot key and print out "Open
Works" to standard output.
However, when I run this with the main program in Unix, when I press
"Ctrl o", it did nothing. But when I run it under Dos mode, the hot
key works.
Cheers,
Ivor
> > Recently, I've written a GUI but it doesn't work properly in Unix.
> > However, it works fine in windows98(under DOS mode). Does anyone have
[quoted text clipped - 9 lines]
>
> Adam