Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDani Megert2012-03-19 13:33:25 +0000
committerDani Megert2012-03-19 13:33:25 +0000
commit2a5e3be158604107fa824aad8223a074af34852b (patch)
tree6601a60c9149e55bac717087ad55ab5801e0d67d
parent34c656445e49e127c5c4a4e8153b782a5731d1ce (diff)
downloadeclipse.platform.text-2a5e3be158604107fa824aad8223a074af34852b.tar.gz
eclipse.platform.text-2a5e3be158604107fa824aad8223a074af34852b.tar.xz
eclipse.platform.text-2a5e3be158604107fa824aad8223a074af34852b.zip
Fixed bug 374082: [implementation] AbstractTextEditor does not restorev20120319-1333
state when in a MultiPageEditorPart
-rw-r--r--org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor/AbstractTextEditor.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor/AbstractTextEditor.java b/org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor/AbstractTextEditor.java
index 1403f60cf78..8b18f0a95a9 100644
--- a/org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor/AbstractTextEditor.java
+++ b/org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor/AbstractTextEditor.java
@@ -965,7 +965,7 @@ public abstract class AbstractTextEditor extends EditorPart implements ITextEdit
*/
public void partOpened(IWorkbenchPart part) {
// Restore the saved state if any
- if (part == AbstractTextEditor.this && fMementoToRestore != null && containsSavedState(fMementoToRestore)) {
+ if ((part == AbstractTextEditor.this || part.getAdapter(AbstractTextEditor.class) == AbstractTextEditor.this) && fMementoToRestore != null && containsSavedState(fMementoToRestore)) {
doRestoreState(fMementoToRestore);
fMementoToRestore= null;
}

Back to the top