KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > pde > internal > ui > editor > cheatsheet > simple > SimpleCSInputContextManager


1 /*******************************************************************************
2  * Copyright (c) 2006 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11
12 package org.eclipse.pde.internal.ui.editor.cheatsheet.simple;
13
14 import org.eclipse.pde.core.IBaseModel;
15 import org.eclipse.pde.internal.ui.editor.PDEFormEditor;
16 import org.eclipse.pde.internal.ui.editor.context.InputContext;
17 import org.eclipse.pde.internal.ui.editor.context.InputContextManager;
18
19 /**
20  * SimpleCSInputContextManager
21  *
22  */

23 public class SimpleCSInputContextManager extends InputContextManager {
24
25     /**
26      * @param editor
27      */

28     public SimpleCSInputContextManager(PDEFormEditor editor) {
29         super(editor);
30     }
31
32     /* (non-Javadoc)
33      * @see org.eclipse.pde.internal.ui.editor.context.InputContextManager#getAggregateModel()
34      */

35     public IBaseModel getAggregateModel() {
36         InputContext context = findContext(SimpleCSInputContext.CONTEXT_ID);
37         return (context != null) ? context.getModel() : null;
38     }
39
40 }
41
Popular Tags