Author: scabanovich
Date: 2007-09-18 06:09:23 -0400 (Tue, 18 Sep 2007)
New Revision: 3678
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ObjectMultiPageEditor.java
Log:
JBIDE-905
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ObjectMultiPageEditor.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ObjectMultiPageEditor.java 2007-09-18
10:00:32 UTC (rev 3677)
+++
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/editor/ObjectMultiPageEditor.java 2007-09-18
10:09:23 UTC (rev 3678)
@@ -158,6 +158,7 @@
}
private void loadSelectedTabForStorage() {
+ if(object == null) return;
String path = object.getPath();
QualifiedName qn = new QualifiedName("", "Selected_tab_" + path);
IProject p = EclipseResourceUtil.getProject(object);
@@ -188,10 +189,11 @@
}
private void saveSelectedTabForStorage() {
+ if(object == null) return;
+ IProject p = EclipseResourceUtil.getProject(object);
+ if(p == null || !p.isOpen()) return;
String path = object.getPath();
QualifiedName qn = new QualifiedName("", "Selected_tab_" + path);
- IProject p = EclipseResourceUtil.getProject(object);
- if(p == null || !p.isOpen()) return;
try {
p.setPersistentProperty(qn, "" + selectedPageIndex);
} catch (CoreException e) {