home *** CD-ROM | disk | FTP | other *** search
- package netscape.applet;
-
- import java.io.BufferedOutputStream;
- import java.io.InputStream;
- import java.io.PrintStream;
-
- class Console {
- ConsoleFrame frame = new ConsoleFrame(this);
-
- Console() {
- InputStream in = new ConsoleInputStream(this);
- PrintStream out = new PrintStream(new BufferedOutputStream(new ConsoleOutputStream(this), 128), true);
- setSystemIO(in, out, out);
- }
-
- private static native void setSystemIO(InputStream var0, PrintStream var1, PrintStream var2);
-
- void reset() {
- this.frame.reset();
- }
-
- void show() {
- if (!this.frame.isVisible()) {
- this.frame.show();
- MozillaAppletContext.setConsoleState(1);
- }
-
- }
-
- void hide() {
- if (this.frame.isVisible()) {
- this.frame.hide();
- MozillaAppletContext.setConsoleState(0);
- }
-
- }
- }
-