CONTEXT MENU: restore clean project
authorHyeoongseok Heo <harry.heo@samsung.com>
Fri, 19 Aug 2016 10:45:07 +0000 (19:45 +0900)
committerSangho Park <sangho.p@samsung.com>
Sat, 20 Aug 2016 02:28:06 +0000 (11:28 +0900)
- Restored 'Clean Project' context menu

Change-Id: I3103435801892c5de1ac5b4abb15a0210bdb8fde
Signed-off-by: Hyeoongseok Heo <harry.heo@samsung.com>
core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/navigator/CNavigatorBuildActionGroup.java

index 82d0449..4094fa4 100644 (file)
@@ -9,10 +9,6 @@
  *     IBM Corporation - initial API and implementation
  *     Anton Leherbauer (Wind River Systems) - adaptations for Common Navigator
  *******************************************************************************/
-/* 2016-08-08 Hyeongseok Heo <harry.heo@samsung.com>
- * Modifications by S-Core Co., Ltd.
- * 1. Modified context menu - hide Clean Project menu
- */
 package org.eclipse.cdt.internal.ui.navigator;
 
 import java.util.Iterator;
@@ -122,8 +118,6 @@ public class CNavigatorBuildActionGroup extends AbstractCNavigatorActionGroup {
                }
 
                if (!selection.isEmpty() && isProjectSelection && hasBuilder) {
-                       /* Tizen */
-                       /*
                        fCleanAction.selectionChanged(selection);
                        if (fCleanAction.isEnabled()) {
                                IContributionItem oldBuild = menu.find(BuildAction.ID_BUILD);
@@ -140,22 +134,6 @@ public class CNavigatorBuildActionGroup extends AbstractCNavigatorActionGroup {
                                        menu.insertAfter(ICommonMenuConstants.GROUP_BUILD, fBuildAction);
                                }
                        }
-                       */
-                       fCleanAction.selectionChanged(selection);
-                       if (fCleanAction.isEnabled()) {
-                               IContributionItem oldBuild = menu.find(BuildAction.ID_BUILD);
-                               if (oldBuild != null) {
-                                       // Replace ResourceMgmtActionProvier's build action with our own
-                                       if (oldBuild instanceof ActionContributionItem &&
-                                                       ((ActionContributionItem)oldBuild).getAction() instanceof BuildAction) {
-                                               menu.remove(oldBuild);
-                                               menu.insertAfter(ICommonMenuConstants.GROUP_BUILD, fBuildAction);
-                                       }
-                               } else {
-                                       menu.insertAfter(ICommonMenuConstants.GROUP_BUILD, fBuildAction);
-                               }
-                       }
-                       /* ===== */
                }
                menu.appendToGroup(ICommonMenuConstants.GROUP_BUILD, new Separator(BUILD_GROUP_MARKER));
                menu.appendToGroup(BUILD_GROUP_MARKER, new GroupMarker(BUILD_GROUP_MARKER_END));