|
From: <duc...@us...> - 2008-02-13 21:32:01
|
Revision: 749
http://ogoglio.svn.sourceforge.net/ogoglio/?rev=749&view=rev
Author: ducheneaut
Date: 2008-02-13 13:32:05 -0800 (Wed, 13 Feb 2008)
Log Message:
-----------
Minor tweaks to make the out-of-memory alert box less ugly.
Modified Paths:
--------------
maven/trunk/ogoglio-viewer-applet/src/main/java/com/ogoglio/viewer/applet/ViewerApplet.java
Modified: maven/trunk/ogoglio-viewer-applet/src/main/java/com/ogoglio/viewer/applet/ViewerApplet.java
===================================================================
--- maven/trunk/ogoglio-viewer-applet/src/main/java/com/ogoglio/viewer/applet/ViewerApplet.java 2008-02-13 14:20:56 UTC (rev 748)
+++ maven/trunk/ogoglio-viewer-applet/src/main/java/com/ogoglio/viewer/applet/ViewerApplet.java 2008-02-13 21:32:05 UTC (rev 749)
@@ -737,20 +737,23 @@
Button help,cancel;
TextArea text;
String memoryMessage =
- "Our renderer ran out of memory and could not\n"
- + "display all of the objects in the space -\n"
- + "they were replaced by question marks. Click\n"
- + "the Help button below to open a page with \n"
- + "instructions about how to easily solve this\n"
- + "problem in your current operating system.";
+ "\n"
+ + "Our renderer ran out of memory and could not "
+ + "display all of the objects in the space - "
+ + "they were replaced by question marks. Click "
+ + "the Help button below to open a page with "
+ + "instructions about how to easily solve this "
+ + "problem in your current operating system."
+ + "\n";
String helpURL;
public MemoryInfoPanel(Frame frame){
super(frame, "Out Of Memory Error", true);
- setLayout(new FlowLayout());
- text = new TextArea(memoryMessage, 6, 40, TextArea.SCROLLBARS_NONE);
+ setLayout(new BorderLayout());
+ text = new TextArea(memoryMessage, 8, 30, TextArea.SCROLLBARS_NONE);
text.setEditable(false);
- add(text);
+ text.setBackground(Color.LIGHT_GRAY);
+ add(text, BorderLayout.CENTER);
addHelpCancelPanel();
createFrame();
pack();
@@ -761,7 +764,7 @@
Panel p = new Panel();
p.setLayout(new FlowLayout());
createButtons(p);
- add(p);
+ add(p, BorderLayout.SOUTH);
}
private void createButtons(Panel p) {
@@ -774,7 +777,6 @@
private void createFrame() {
Dimension d = theApplet.getSize();
setLocation(d.width/4,d.height/3);
- setPreferredSize(new Dimension(d.width, d.height/3));
}
public void actionPerformed(ActionEvent ae){
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|