Fix NPE when switching projects
@@ -1563,7 +1563,9 @@ public class Ode implements EntryPoint {
* HideChaff when switching view from block to others
*/
private void hideChaff() {
- if (designToolbar.getCurrentView() == DesignToolbar.View.BLOCKS) {
+ if (designToolbar.getCurrentView() == DesignToolbar.View.BLOCKS
+ // currentFileEditor may be null when switching projects
+ && currentFileEditor != null) {
currentFileEditor.hideChaff();
}
}
