Commit 275d4dee authored by Andrey Filippov's avatar Andrey Filippov

Do not try to restore non-HDL project state if the selected file in the editor...

Do not try to restore non-HDL project state if the selected file in the editor is from non-HDL project
parent b3e15b29
...@@ -1270,17 +1270,16 @@ public class DesignFlowView extends ViewPart implements ISelectionListener { ...@@ -1270,17 +1270,16 @@ public class DesignFlowView extends ViewPart implements ISelectionListener {
toggleLinkedTools.setChecked(!SelectedResourceManager.getDefault().isToolsLinked()); toggleLinkedTools.setChecked(!SelectedResourceManager.getDefault().isToolsLinked());
// Initialize VEditor database build // Initialize VEditor database build
IResource HDLFile=SelectedResourceManager.getDefault().getChosenVerilogFile(); IResource HDLFile=SelectedResourceManager.getDefault().getChosenVerilogFile();
// restore properties from the project, overwrite global ones
IProject project;
if (selectedResource == null) {
project = SelectedResourceManager.getDefault().getSelectedProject();
} else {
project = HDLFile.getProject();
}
// restoreCurrentState(selectedResource.getProject()); // null OK
restoreCurrentState(project); // null OK
if ((HDLFile!=null) && HDLFile.exists()){ if ((HDLFile!=null) && HDLFile.exists()){
// restore properties from the project, overwrite global ones
IProject project;
if (selectedResource == null) {
project = SelectedResourceManager.getDefault().getSelectedProject();
} else {
project = HDLFile.getProject();
}
restoreCurrentState(project); // null OK
toolSequence.setUnfinishedBoot(memento,true); toolSequence.setUnfinishedBoot(memento,true);
if (VerilogPlugin.getPreferenceBoolean(PreferenceStrings.DEBUG_OTHER)) if (VerilogPlugin.getPreferenceBoolean(PreferenceStrings.DEBUG_OTHER))
System.out.println("Initiating DB rebuild HDLFile="+HDLFile); System.out.println("Initiating DB rebuild HDLFile="+HDLFile);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment