aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTor Norbye <tnorbye@google.com>2011-06-02 11:33:51 -0700
committerTor Norbye <tnorbye@google.com>2011-06-02 11:33:51 -0700
commit4867ce096c648149c49089fb7230adc499ebd39a (patch)
treef7d00a7cd69cfee9bec07a4aebeedb154a703ee6
parentdeb260db08cc7e31d26fe543146b264fae714db8 (diff)
downloadsdk-4867ce096c648149c49089fb7230adc499ebd39a.zip
sdk-4867ce096c648149c49089fb7230adc499ebd39a.tar.gz
sdk-4867ce096c648149c49089fb7230adc499ebd39a.tar.bz2
Fix invalid caching of project callback
Change-Id: If7c0ee87e5263767e607cf226838e65667a5106c
-rw-r--r--eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/GraphicalEditorPart.java9
1 files changed, 4 insertions, 5 deletions
diff --git a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/GraphicalEditorPart.java b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/GraphicalEditorPart.java
index 88624bc..41017a0 100644
--- a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/GraphicalEditorPart.java
+++ b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/GraphicalEditorPart.java
@@ -1425,11 +1425,10 @@ public class GraphicalEditorPart extends EditorPart
}
}
- // also remove the ProjectCallback as it caches custom views which must be reloaded
- // with the classloader of the new LayoutLib.
- if (mProjectCallback != null && mProjectCallback.isUsed()) {
- mProjectCallback = null;
- }
+ // Also remove the ProjectCallback as it caches custom views which must be reloaded
+ // with the classloader of the new LayoutLib. We also have to clear it out
+ // because it stores a reference to the layout library which could have changed.
+ mProjectCallback = null;
// FIXME: get rid of the current LayoutScene if any.
}