01: /*******************************************************************************
02: * Copyright (c) 2004, 2006 IBM Corporation and others.
03: * All rights reserved. This program and the accompanying materials
04: * are made available under the terms of the Eclipse Public License v1.0
05: * which accompanies this distribution, and is available at
06: * http://www.eclipse.org/legal/epl-v10.html
07: *
08: * Contributors:
09: * IBM Corporation - initial API and implementation
10: *******************************************************************************/package org.eclipse.ui.internal.presentations;
11:
12: import org.eclipse.swt.widgets.Composite;
13: import org.eclipse.ui.presentations.IStackPresentationSite;
14: import org.eclipse.ui.presentations.StackPresentation;
15: import org.eclipse.ui.presentations.WorkbenchPresentationFactory;
16:
17: /**
18: * A presentation factory using native widgets.
19: * <p>
20: * EXPERIMENTAL
21: * </p>
22: *
23: * @since 3.0
24: */
25: public class NativePresentationFactory extends
26: WorkbenchPresentationFactory {
27:
28: /*
29: * (non-Javadoc)
30: *
31: * @see org.eclipse.ui.presentations.AbstractPresentationFactory
32: */
33: public StackPresentation createEditorPresentation(Composite parent,
34: IStackPresentationSite site) {
35: return new NativeStackPresentation(parent, site);
36: }
37:
38: /*
39: * (non-Javadoc)
40: *
41: * @see org.eclipse.ui.presentations.AbstractPresentationFactory
42: */
43: public StackPresentation createViewPresentation(Composite parent,
44: IStackPresentationSite site) {
45: return new NativeStackPresentation(parent, site);
46: }
47:
48: /*
49: * (non-Javadoc)
50: *
51: * @see org.eclipse.ui.presentations.AbstractPresentationFactory
52: */
53: public StackPresentation createStandaloneViewPresentation(
54: Composite parent, IStackPresentationSite site,
55: boolean showTitle) {
56: // TODO honour showTitle
57: return new NativeStackPresentation(parent, site);
58: }
59:
60: }
|