本文整理匯總了Java中org.opensourcephysics.display.GUIUtils.showDrawingAndTableFrames方法的典型用法代碼示例。如果您正苦於以下問題:Java GUIUtils.showDrawingAndTableFrames方法的具體用法?Java GUIUtils.showDrawingAndTableFrames怎麽用?Java GUIUtils.showDrawingAndTableFrames使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.opensourcephysics.display.GUIUtils
的用法示例。
在下文中一共展示了GUIUtils.showDrawingAndTableFrames方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the WRApp user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
LJgasWRApp app = new LJgasWRApp();
LJgasWRAppControl c = new LJgasWRAppControl(app, app.displayFrame, null);
c.getMainFrame().setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.getMainFrame().addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
c.resetSimulation();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例2: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the WRApp user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
MultipleCoinTossWRApp app = new MultipleCoinTossWRApp();
MultipleCoinTossWRAppControl c = new MultipleCoinTossWRAppControl(app, app.histogramFrame, null);
c.getMainFrame().setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.getMainFrame().addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
c.resetSimulation();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例3: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the WRApp user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
LJfluidWRApp app = new LJfluidWRApp();
LJfluidControl c = new LJfluidControl(app, app.displayFrame, null);
c.getMainFrame().setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.getMainFrame().addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
c.resetSimulation();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例4: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the WRApp user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
LJgas2boxWRApp app = new LJgas2boxWRApp();
LJgas2boxWRAppControl c = new LJgas2boxWRAppControl(app, app.displayFrame, null);
c.getMainFrame().setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.getMainFrame().addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
c.resetSimulation();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例5: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the App user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
DemonApp app = new DemonApp();
SimulationControl c = SimulationControl.createApp(app);
c.setDefaultCloseOperation(closeOperation);
c.addButton("zeroAverages", "Zero averages");
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
c.setValue("model", null);
app.customize();
app.initialize();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例6: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the App user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
LJgas2boxApp app = new LJgas2boxApp();
SimulationControl c = SimulationControl.createApp(app);
c.setDefaultCloseOperation(closeOperation);
c.addButton("reverse", "Reverse");
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
c.setValue("model", null);
app.customize();
app.initialize();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例7: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the WRApp user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
FlatWRApp app = new FlatWRApp();
FlatAppControl c = new FlatAppControl(app, app.r2Frame, null);
c.getMainFrame().setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.getMainFrame().addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
c.resetSimulation();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例8: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the App user interface.
*/
public void switchGUI() {
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
MonteCarloEstimationApp app = new MonteCarloEstimationApp();
CalculationControl c = CalculationControl.createApp(app);
c.setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
c.setValue("model", null);
app.customize();
System.gc();
OSPRuntime.disableAllDrawing = false;
c.clearMessages();
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例9: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the WRApp user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
VariableStepLengthWalkWRApp app = new VariableStepLengthWalkWRApp();
VariableStepLengthWalkAppControl c = new VariableStepLengthWalkAppControl(app, app.histogramFrame, null);
c.getMainFrame().setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.getMainFrame().addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
c.resetSimulation();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例10: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the WRApp user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
DemonWRApp app = new DemonWRApp();
DemonWRAppControl c = new DemonWRAppControl(app, app.histogramFrame, null);
c.getMainFrame().setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.getMainFrame().addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
c.resetSimulation();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例11: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the WRApp user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
IsingLG2WRApp app = new IsingLG2WRApp();
IsingLG2Control c = new IsingLG2Control(app, app.displayFrame, null);
c.getMainFrame().setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.getMainFrame().addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
app.initialize();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例12: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the App user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
VariableStepLengthWalkApp app = new VariableStepLengthWalkApp();
SimulationControl c = SimulationControl.createApp(app);
c.setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
c.setValue("model", null);
app.customize();
app.initialize();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例13: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the App user interface.
*/
public void switchGUI() {
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
EinsteinSolidApp app = new EinsteinSolidApp();
CalculationControl c = CalculationControl.createApp(app);
c.setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
app.resetCalculation();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例14: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the App user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
BoxApp app = new BoxApp();
SimulationControl c = SimulationControl.createApp(app);
c.setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
c.setValue("model", null);
app.customize();
app.initialize();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}
示例15: switchGUI
import org.opensourcephysics.display.GUIUtils; //導入方法依賴的package包/類
/**
* Switch to the WRApp user interface.
*/
public void switchGUI() {
stopSimulation();
Runnable runner = new Runnable() {
public synchronized void run() {
OSPRuntime.disableAllDrawing = true;
OSPFrame mainFrame = getMainFrame();
XMLControlElement xml = new XMLControlElement(getOSPApp());
WindowListener[] listeners = mainFrame.getWindowListeners();
int closeOperation = mainFrame.getDefaultCloseOperation();
mainFrame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
mainFrame.setKeepHidden(true);
mainFrame.dispose();
CentralWRApp app = new CentralWRApp();
CentralAppControl c = new CentralAppControl(app, app.frame, null);
c.getMainFrame().setDefaultCloseOperation(closeOperation);
for(int i = 0, n = listeners.length; i<n; i++) {
if(listeners[i].getClass().getName().equals("org.opensourcephysics.tools.Launcher$FrameCloser")) {
c.getMainFrame().addWindowListener(listeners[i]);
}
}
c.loadXML(xml, true);
app.customize();
c.resetSimulation();
System.gc();
OSPRuntime.disableAllDrawing = false;
GUIUtils.showDrawingAndTableFrames();
}
};
Thread t = new Thread(runner);
t.start();
}