~ubuntu-branches/ubuntu/utopic/eclipse-wtp/utopic-proposed

« back to all changes in this revision

Viewing changes to org.eclipse.wst.server.ui/serverui/org/eclipse/wst/server/ui/editor/ServerEditorOverviewPageModifier.java

  • Committer: Package Import Robot
  • Author(s): Jakub Adam
  • Date: 2014-07-10 12:54:39 UTC
  • mfrom: (1.1.5)
  • Revision ID: package-import@ubuntu.com-20140710125439-ixzeiqepu8m3e1z6
Tags: 3.6.0-1
* New upstream release.
* Refreshed d/patches/debian-custom-build.patch.
* Regenerate CSSTokenizer during build.
* Override codeless-jar warning in eclipse-wtp binary package.
* Override false positive source-is-missing lintian error in bundle
  org.eclipse.wst.jsdt.support.ie.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*******************************************************************************
2
 
 * Copyright (c) 2010 IBM Corporation and others.
 
2
 * Copyright (c) 2010, 2014 IBM Corporation and others.
3
3
 * All rights reserved. This program and the accompanying materials
4
4
 * are made available under the terms of the Eclipse Public License v1.0
5
5
 * which accompanies this distribution, and is available at
10
10
 *******************************************************************************/
11
11
package org.eclipse.wst.server.ui.editor;
12
12
 
 
13
import org.eclipse.core.commands.operations.IUndoableOperation;
13
14
import org.eclipse.swt.widgets.Composite;
 
15
import org.eclipse.ui.forms.widgets.FormToolkit;
14
16
import org.eclipse.wst.server.core.IServerWorkingCopy;
15
17
import org.eclipse.wst.server.ui.AbstractUIControl;
 
18
import org.eclipse.wst.server.ui.internal.Trace;
16
19
 
17
20
/**
18
21
 * A modifier class that allows adopter to modify the behaviour of a UI control on the
22
25
 */
23
26
public abstract class ServerEditorOverviewPageModifier extends AbstractUIControl {
24
27
        protected IServerWorkingCopy serverWc = null;
25
 
 
 
28
        private FormToolkit serverEditorFormToolkit = null;
 
29
        private ServerEditorPart serverEditorPart = null;
26
30
        
27
31
        /**
28
32
         * The list of editor sections on the server editors that allow inserting custom GUI.
47
51
        public void setServerWorkingCopy(IServerWorkingCopy curServerWc) {
48
52
                serverWc = curServerWc;
49
53
        }
 
54
        
 
55
        public void setServerEditorPart(ServerEditorPart part) {
 
56
                serverEditorPart = part;
 
57
        }
 
58
 
 
59
        public void setFormToolkit(FormToolkit toolkit) {
 
60
                this.serverEditorFormToolkit = toolkit;
 
61
        }
 
62
 
 
63
        protected FormToolkit getFormToolkit() {
 
64
                return serverEditorFormToolkit;
 
65
        }
 
66
 
 
67
        protected void executeCommand(IUndoableOperation operation) {
 
68
                if (serverEditorPart != null) {
 
69
                        serverEditorPart.execute(operation);
 
70
                } else {
 
71
                        if (Trace.SEVERE) {
 
72
                                Trace.trace(Trace.STRING_SEVERE,
 
73
                                                "Error executing command: No reference to editor part");
 
74
                        }
 
75
                }
 
76
        }
50
77
}
 
 
b'\\ No newline at end of file'