Bugzilla – Attachment 255 Details for
Bug 499
Simple AWT and JOGL application hangs on startup
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
Log In
[x]
|
Forgot Password
Login:
[x]
Sample Code
SimpleScene.java (text/x-java), 1007 bytes, created by
Mike Pleasance
on 2011-05-11 02:04:48 CEST
(
hide
)
Description:
Sample Code
Filename:
MIME Type:
Creator:
Mike Pleasance
Created:
2011-05-11 02:04:48 CEST
Size:
1007 bytes
patch
obsolete
>import java.awt.Frame; >import java.awt.event.WindowAdapter; >import java.awt.event.WindowEvent; >import javax.media.opengl.*; >import javax.media.opengl.awt.GLCanvas; > >public class SimpleScene { > > public static Frame frame = null; > > public static void main(String[] args) { > > GLProfile.initSingleton(false); > GLProfile glp = GLProfile.getDefault(); > GLCapabilities caps = new GLCapabilities(glp); > GLCanvas canvas = new GLCanvas(caps); > > frame = new Frame("AWT Window Test"); > frame.setSize(300, 300); > frame.add(canvas); > frame.setVisible(true); > > // by default, an AWT Frame doesn't do anything when you click > // the close button; this bit of code will terminate the program when > // the window is asked to close > frame.addWindowListener(new WindowAdapter() { > public void windowClosing(WindowEvent e) { > frame.dispose(); > System.exit(0); > } > }); > } >} > >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 499
:
254
| 255 |
263
|
264