Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 335840
Collapse All | Expand All

(-)Eclipse UI/org/eclipse/ui/internal/WorkbenchPlugin.java (-6 / +11 lines)
Lines 303-309 Link Here
303
// RAP [rh] PerspectiveRegistry has session scope    
303
// RAP [rh] PerspectiveRegistry has session scope    
304
//    private PerspectiveRegistry perspRegistry;
304
//    private PerspectiveRegistry perspRegistry;
305
305
306
    private ActionSetRegistry actionSetRegistry;
306
// RAP [if] ActionSetRegistry has session scope 
307
//    private ActionSetRegistry actionSetRegistry;
307
308
308
    private SharedImages sharedImages;
309
    private SharedImages sharedImages;
309
310
Lines 376-382 Link Here
376
//            perspRegistry = null;
377
//            perspRegistry = null;
377
//        }
378
//        }
378
        
379
        
379
        actionSetRegistry = null;
380
// RAP [if] actionSetRegistry field is unused, ActionsetRegistry has session scope 
381
//        actionSetRegistry = null;
380
        sharedImages = null;
382
        sharedImages = null;
381
383
382
        productInfo = null;
384
        productInfo = null;
Lines 579-588 Link Here
579
     * @return the workbench action set registry
581
     * @return the workbench action set registry
580
     */
582
     */
581
    public ActionSetRegistry getActionSetRegistry() {
583
    public ActionSetRegistry getActionSetRegistry() {
582
        if (actionSetRegistry == null) {
584
        // RAP [if]
583
            actionSetRegistry = new ActionSetRegistry();
585
//        if (actionSetRegistry == null) {
584
        }
586
//            actionSetRegistry = new ActionSetRegistry();
585
        return actionSetRegistry;
587
//        }
588
//        return actionSetRegistry;
589
        return ActionSetRegistry.getInstance();
590
        // RAPEND: [if]
586
    }
591
    }
587
592
588
    /**
593
    /**
(-)Eclipse UI/org/eclipse/ui/internal/registry/ActionSetRegistry.java (-1 / +15 lines)
Lines 24-29 Link Here
24
import org.eclipse.core.runtime.dynamichelpers.ExtensionTracker;
24
import org.eclipse.core.runtime.dynamichelpers.ExtensionTracker;
25
import org.eclipse.core.runtime.dynamichelpers.IExtensionChangeHandler;
25
import org.eclipse.core.runtime.dynamichelpers.IExtensionChangeHandler;
26
import org.eclipse.core.runtime.dynamichelpers.IExtensionTracker;
26
import org.eclipse.core.runtime.dynamichelpers.IExtensionTracker;
27
import org.eclipse.rwt.SessionSingletonBase;
27
import org.eclipse.ui.PlatformUI;
28
import org.eclipse.ui.PlatformUI;
28
import org.eclipse.ui.contexts.IContextService;
29
import org.eclipse.ui.contexts.IContextService;
29
import org.eclipse.ui.internal.WorkbenchPlugin;
30
import org.eclipse.ui.internal.WorkbenchPlugin;
Lines 61-67 Link Here
61
    /**
62
    /**
62
     * Creates the action set registry.
63
     * Creates the action set registry.
63
     */
64
     */
64
    public ActionSetRegistry() {
65
	// RAP [if]: see getInstance
66
//    public ActionSetRegistry() {
67
	private ActionSetRegistry() {
68
    // RAPEND: [if] 
65
    	contextService = (IContextService) PlatformUI
69
    	contextService = (IContextService) PlatformUI
66
				.getWorkbench().getService(IContextService.class);
70
				.getWorkbench().getService(IContextService.class);
67
		PlatformUI.getWorkbench().getExtensionTracker().registerHandler(
71
		PlatformUI.getWorkbench().getExtensionTracker().registerHandler(
Lines 72-77 Link Here
72
                                getActionSetPartAssociationExtensionPoint() }));
76
                                getActionSetPartAssociationExtensionPoint() }));
73
        readFromRegistry();
77
        readFromRegistry();
74
    }
78
    }
79
	
80
	// RAP [if]: 
81
    /**
82
     * Returns a session scoped ActionSetRegistry
83
     * @return
84
     */
85
    public static ActionSetRegistry getInstance() {
86
        return ( ActionSetRegistry )SessionSingletonBase.getInstance( ActionSetRegistry.class );  
87
    }
88
    // RAPEND: [if]
75
89
76
    /**
90
    /**
77
     * Return the action set part association extension point.
91
     * Return the action set part association extension point.

Return to bug 335840