SDK:
- fix NiftyGUI reshape.. still problems git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@8101 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
This commit is contained in:
parent
578c92affc
commit
e2a822fc48
@ -34,8 +34,6 @@ package com.jme3.gde.gui.multiview;
|
|||||||
|
|
||||||
import com.jme3.asset.AssetManager;
|
import com.jme3.asset.AssetManager;
|
||||||
import com.jme3.audio.AudioRenderer;
|
import com.jme3.audio.AudioRenderer;
|
||||||
import com.jme3.gde.core.scene.SceneApplication;
|
|
||||||
import com.jme3.niftygui.InputSystemJme;
|
|
||||||
import com.jme3.niftygui.RenderDeviceJme;
|
import com.jme3.niftygui.RenderDeviceJme;
|
||||||
import com.jme3.niftygui.SoundDeviceJme;
|
import com.jme3.niftygui.SoundDeviceJme;
|
||||||
import com.jme3.post.SceneProcessor;
|
import com.jme3.post.SceneProcessor;
|
||||||
@ -55,8 +53,6 @@ public class NiftyJmeDisplay extends com.jme3.niftygui.NiftyJmeDisplay implement
|
|||||||
AudioRenderer audioRenderer,
|
AudioRenderer audioRenderer,
|
||||||
ViewPort vp){
|
ViewPort vp){
|
||||||
this.assetManager = assetManager;
|
this.assetManager = assetManager;
|
||||||
//FIXME: needed, else npe
|
|
||||||
this.inputSys = new InputSystemJme(SceneApplication.getApplication().getInputManager());
|
|
||||||
|
|
||||||
w = vp.getCamera().getWidth();
|
w = vp.getCamera().getWidth();
|
||||||
h = vp.getCamera().getHeight();
|
h = vp.getCamera().getHeight();
|
||||||
@ -109,7 +105,7 @@ public class NiftyJmeDisplay extends com.jme3.niftygui.NiftyJmeDisplay implement
|
|||||||
public void reshape(ViewPort vp, int w, int h) {
|
public void reshape(ViewPort vp, int w, int h) {
|
||||||
this.w = w;
|
this.w = w;
|
||||||
this.h = h;
|
this.h = h;
|
||||||
super.reshape(vp,w,h);
|
nifty.resolutionChanged();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -4,7 +4,6 @@
|
|||||||
*/
|
*/
|
||||||
package com.jme3.gde.gui.multiview;
|
package com.jme3.gde.gui.multiview;
|
||||||
|
|
||||||
import com.jme3.asset.AssetManager;
|
|
||||||
import com.jme3.audio.AudioRenderer;
|
import com.jme3.audio.AudioRenderer;
|
||||||
import com.jme3.gde.core.assets.ProjectAssetManager;
|
import com.jme3.gde.core.assets.ProjectAssetManager;
|
||||||
import com.jme3.gde.core.scene.OffScenePanel;
|
import com.jme3.gde.core.scene.OffScenePanel;
|
||||||
@ -32,11 +31,15 @@ import javax.swing.JToolBar;
|
|||||||
import org.netbeans.modules.xml.multiview.Error;
|
import org.netbeans.modules.xml.multiview.Error;
|
||||||
import org.netbeans.modules.xml.multiview.ui.PanelView;
|
import org.netbeans.modules.xml.multiview.ui.PanelView;
|
||||||
import org.netbeans.modules.xml.multiview.ui.ToolBarDesignEditor;
|
import org.netbeans.modules.xml.multiview.ui.ToolBarDesignEditor;
|
||||||
|
import org.openide.DialogDisplayer;
|
||||||
|
import org.openide.NotifyDescriptor;
|
||||||
|
import org.openide.NotifyDescriptor.Message;
|
||||||
import org.openide.nodes.Node;
|
import org.openide.nodes.Node;
|
||||||
import org.openide.util.Exceptions;
|
import org.openide.util.Exceptions;
|
||||||
import org.openide.xml.XMLUtil;
|
import org.openide.xml.XMLUtil;
|
||||||
import org.w3c.dom.Document;
|
import org.w3c.dom.Document;
|
||||||
import org.xml.sax.InputSource;
|
import org.xml.sax.InputSource;
|
||||||
|
import uk.co.mandolane.midi.e;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
@ -124,7 +127,12 @@ public class NiftyPreviewPanel extends PanelView {
|
|||||||
setRoot(rootContext);
|
setRoot(rootContext);
|
||||||
comp.setRootContext(rootContext);
|
comp.setRootContext(rootContext);
|
||||||
} catch (Exception ex) {
|
} catch (Exception ex) {
|
||||||
|
Message msg = new NotifyDescriptor.Message(
|
||||||
|
"Error parsing File:" + ex,
|
||||||
|
NotifyDescriptor.ERROR_MESSAGE);
|
||||||
|
DialogDisplayer.getDefault().notifyLater(msg);
|
||||||
Exceptions.printStackTrace(ex);
|
Exceptions.printStackTrace(ex);
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
SceneApplication.getApplication().enqueue(new Callable<Object>() {
|
SceneApplication.getApplication().enqueue(new Callable<Object>() {
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user