Merge branch 'liana/simplified_debugger'
authorEkaterina Tuzova <Ekaterina.Tuzova@jetbrains.com>
Mon, 24 Aug 2015 08:33:01 +0000 (11:33 +0300)
committerEkaterina Tuzova <Ekaterina.Tuzova@jetbrains.com>
Mon, 24 Aug 2015 08:33:01 +0000 (11:33 +0300)
Conflicts:
python/edu/src/META-INF/PyCharmEduPlugin.xml
python/edu/src/com/jetbrains/python/edu/PyCharmEduInitialConfigurator.java

1  2 
python/edu/src/META-INF/PyCharmEduPlugin.xml
python/edu/src/com/jetbrains/python/edu/PyCharmEduInitialConfigurator.java
python/educational/course-creator/src/com/jetbrains/edu/coursecreator/actions/CCRunTestsAction.java

index b2ee67e705e097d1aaadb3ede4fe92181e683c68,b1dfd7039a3ddfbf28d42740a7550e8127a200bd..65eb9ca1bed03a92b922961a71fc512723de1ee9
  
    <extensions defaultExtensionNs="com.intellij">
        <codeInsight.lineMarkerProvider language="Python" implementationClass="com.jetbrains.python.edu.PyExecuteFileLineMarkerProvider"/>
+       <programRunner implementation="com.jetbrains.python.edu.debugger.PyEduDebugRunner"/>
+       <executor implementation="com.jetbrains.python.edu.debugger.PyEduDebugExecutor" order="first,after run"/>
+       <consoleInputFilterProvider implementation="com.jetbrains.python.edu.debugger.PyEduConsoleInputFilterProvider"/>
    </extensions>
    <extensions defaultExtensionNs="Edu">
 -    <executeFile implementation="com.jetbrains.python.edu.PyDebugCurrentFile"/>
 +    <executeFile implementation="com.jetbrains.python.edu.PyEduAddParametersAction"/>
    </extensions>
  
--  <actions>
-     <group id="PyRunMenu">
-       <action id="runCurrentFile" class="com.jetbrains.python.edu.PyRunCurrentFileAction"/>
-       <add-to-group group-id="RunMenu" anchor="first"/>
 -    <group overrides="true" class="com.intellij.openapi.actionSystem.EmptyActionGroup" id="ToolsMenu"/>
 -
 -    <group overrides="true" class="com.intellij.openapi.actionSystem.EmptyActionGroup" id="PrintExportGroup"/>
 -    <group overrides="true" id="FileMainSettingsGroup">
 -      <reference id="ShowSettings"/>
 -      <separator/>
 -      <reference id="ExportImportGroup"/>
--    </group>
 -
 -    <group overrides="true" class="com.intellij.openapi.actionSystem.EmptyActionGroup" id="EditBookmarksGroup"/>
 -    <group overrides="true" class="com.intellij.openapi.actionSystem.EmptyActionGroup" id="AddToFavorites"/>
 -    <group overrides="true" class="com.intellij.openapi.actionSystem.EmptyActionGroup" id="AddAllToFavorites"/>
 -    <action overrides="true" class="com.intellij.openapi.actionSystem.EmptyAction" id="AddToFavoritesPopup"/>
 -
 -    <action overrides="true" class="com.intellij.openapi.actionSystem.EmptyAction" id="NewHtmlFile"/>
--
--
--  </actions>
  </idea-plugin>
index 18197fe169d7ef0b6a446ba21ea6d4d30cb5b810,73d9e9b8142bf106fd1e72f120b0cf4f25ea44e4..d8c78bb1dedaee5f1c5f648f597a08cee9b29a93
@@@ -19,21 -19,21 +19,27 @@@ import com.google.common.collect.Sets
  import com.intellij.codeInsight.CodeInsightSettings;
  import com.intellij.codeInsight.intention.IntentionActionBean;
  import com.intellij.codeInsight.intention.IntentionManager;
+ import com.intellij.execution.Executor;
+ import com.intellij.execution.ExecutorRegistryImpl;
+ import com.intellij.execution.executors.DefaultDebugExecutor;
  import com.intellij.ide.AppLifecycleListener;
  import com.intellij.ide.GeneralSettings;
 -import com.intellij.ide.RecentProjectsManager;
  import com.intellij.ide.SelectInTarget;
 +import com.intellij.ide.projectView.impl.AbstractProjectViewPane;
 +import com.intellij.ide.scopeView.ScopeViewPane;
  import com.intellij.ide.ui.UISettings;
 +import com.intellij.ide.ui.customization.ActionUrl;
 +import com.intellij.ide.ui.customization.CustomActionsSchema;
 +import com.intellij.ide.ui.customization.CustomizationUtil;
  import com.intellij.ide.util.PropertiesComponent;
  import com.intellij.ide.util.TipAndTrickBean;
  import com.intellij.notification.EventLog;
+ import com.intellij.openapi.actionSystem.ActionManager;
+ import com.intellij.openapi.actionSystem.AnAction;
+ import com.intellij.openapi.actionSystem.DefaultActionGroup;
  import com.intellij.openapi.application.ApplicationManager;
 +import com.intellij.openapi.editor.colors.EditorColorsManager;
 +import com.intellij.openapi.editor.colors.EditorColorsScheme;
  import com.intellij.openapi.editor.ex.EditorSettingsExternalizable;
  import com.intellij.openapi.extensions.Extensions;
  import com.intellij.openapi.extensions.ExtensionsArea;
@@@ -313,19 -216,12 +319,23 @@@ public class PyCharmEduInitialConfigura
    }
  
    private static void patchProjectAreaExtensions(@NotNull final Project project) {
+     Executor debugExecutor = DefaultDebugExecutor.getDebugExecutorInstance();
+     unregisterAction(debugExecutor.getId(), ExecutorRegistryImpl.RUNNERS_GROUP);
+     unregisterAction(debugExecutor.getContextActionId(), ExecutorRegistryImpl.RUN_CONTEXT_GROUP);
++
 +    ExtensionsArea projectArea = Extensions.getArea(project);
 +
      for (SelectInTarget target : Extensions.getExtensions(SelectInTarget.EP_NAME, project)) {
 -      if (ToolWindowId.FAVORITES_VIEW.equals(target.getToolWindowId())) {
 -        Extensions.getArea(project).getExtensionPoint(SelectInTarget.EP_NAME).unregisterExtension(target);
 +      if (ToolWindowId.FAVORITES_VIEW.equals(target.getToolWindowId()) ||
 +          ToolWindowId.STRUCTURE_VIEW.equals(target.getToolWindowId())) {
 +        projectArea.getExtensionPoint(SelectInTarget.EP_NAME).unregisterExtension(target);
 +      }
 +    }
 +
 +    for (AbstractProjectViewPane pane : Extensions.getExtensions(AbstractProjectViewPane.EP_NAME, project)) {
 +      if (pane.getId().equals(ScopeViewPane.ID)) {
 +        Disposer.dispose(pane);
 +        projectArea.getExtensionPoint(AbstractProjectViewPane.EP_NAME).unregisterExtension(pane);
        }
      }
    }