|
Lines 1-5
Link Here
|
| 1 |
/******************************************************************************* |
1 |
/******************************************************************************* |
| 2 |
* Copyright (c) 2008, 2009 Code 9 Corporation and others. |
2 |
* Copyright (c) 2008, 2011 Code 9 Corporation and others. |
| 3 |
* All rights reserved. This program and the accompanying materials |
3 |
* All rights reserved. This program and the accompanying materials |
| 4 |
* are made available under the terms of the Eclipse Public License v1.0 |
4 |
* are made available under the terms of the Eclipse Public License v1.0 |
| 5 |
* which accompanies this distribution, and is available at |
5 |
* which accompanies this distribution, and is available at |
|
Lines 14-28
Link Here
|
| 14 |
*******************************************************************************/ |
14 |
*******************************************************************************/ |
| 15 |
package org.eclipse.pde.internal.ds.ui.editor.sections; |
15 |
package org.eclipse.pde.internal.ds.ui.editor.sections; |
| 16 |
|
16 |
|
| 17 |
import org.eclipse.core.resources.IProject; |
|
|
| 18 |
import org.eclipse.core.runtime.CoreException; |
| 19 |
import org.eclipse.jdt.core.IJavaElement; |
| 20 |
import org.eclipse.jdt.core.IJavaProject; |
| 21 |
import org.eclipse.jdt.core.JavaCore; |
| 22 |
import org.eclipse.jdt.ui.IJavaElementSearchConstants; |
| 23 |
import org.eclipse.jdt.ui.JavaUI; |
| 24 |
import org.eclipse.jface.window.Window; |
| 25 |
import org.eclipse.jface.wizard.WizardDialog; |
| 26 |
import org.eclipse.pde.core.IModelChangedEvent; |
17 |
import org.eclipse.pde.core.IModelChangedEvent; |
| 27 |
import org.eclipse.pde.internal.ds.core.IDSComponent; |
18 |
import org.eclipse.pde.internal.ds.core.IDSComponent; |
| 28 |
import org.eclipse.pde.internal.ds.core.IDSImplementation; |
19 |
import org.eclipse.pde.internal.ds.core.IDSImplementation; |
|
Lines 37-53
Link Here
|
| 37 |
import org.eclipse.pde.internal.ui.editor.PDEFormPage; |
28 |
import org.eclipse.pde.internal.ui.editor.PDEFormPage; |
| 38 |
import org.eclipse.pde.internal.ui.editor.PDESection; |
29 |
import org.eclipse.pde.internal.ui.editor.PDESection; |
| 39 |
import org.eclipse.pde.internal.ui.util.PDEJavaHelperUI; |
30 |
import org.eclipse.pde.internal.ui.util.PDEJavaHelperUI; |
|
|
31 |
|
| 40 |
import org.eclipse.swt.SWT; |
32 |
import org.eclipse.swt.SWT; |
| 41 |
import org.eclipse.swt.layout.GridData; |
33 |
import org.eclipse.swt.layout.GridData; |
| 42 |
import org.eclipse.swt.layout.GridLayout; |
34 |
import org.eclipse.swt.layout.GridLayout; |
| 43 |
import org.eclipse.swt.widgets.Composite; |
35 |
import org.eclipse.swt.widgets.Composite; |
| 44 |
import org.eclipse.swt.widgets.Display; |
36 |
import org.eclipse.swt.widgets.Display; |
|
|
37 |
|
| 38 |
import org.eclipse.core.runtime.CoreException; |
| 39 |
|
| 40 |
import org.eclipse.core.resources.IProject; |
| 41 |
|
| 42 |
import org.eclipse.jface.window.Window; |
| 43 |
import org.eclipse.jface.wizard.WizardDialog; |
| 44 |
|
| 45 |
import org.eclipse.ui.IActionBars; |
45 |
import org.eclipse.ui.IActionBars; |
| 46 |
import org.eclipse.ui.PartInitException; |
46 |
import org.eclipse.ui.PartInitException; |
| 47 |
import org.eclipse.ui.forms.events.HyperlinkEvent; |
47 |
import org.eclipse.ui.forms.events.HyperlinkEvent; |
| 48 |
import org.eclipse.ui.forms.widgets.FormToolkit; |
48 |
import org.eclipse.ui.forms.widgets.FormToolkit; |
| 49 |
import org.eclipse.ui.forms.widgets.Section; |
49 |
import org.eclipse.ui.forms.widgets.Section; |
| 50 |
|
50 |
|
|
|
51 |
import org.eclipse.jdt.core.IJavaElement; |
| 52 |
import org.eclipse.jdt.core.IJavaProject; |
| 53 |
import org.eclipse.jdt.core.JavaCore; |
| 54 |
|
| 55 |
import org.eclipse.jdt.ui.IJavaElementSearchConstants; |
| 56 |
import org.eclipse.jdt.ui.JavaUI; |
| 57 |
|
| 51 |
public class DSComponentSection extends PDESection { |
58 |
public class DSComponentSection extends PDESection { |
| 52 |
|
59 |
|
| 53 |
private IDSComponent fComponent; |
60 |
private IDSComponent fComponent; |
|
Lines 143-155
Link Here
|
| 143 |
} |
150 |
} |
| 144 |
|
151 |
|
| 145 |
if (fNameEntry != null) { |
152 |
if (fNameEntry != null) { |
| 146 |
Display.getDefault().syncExec(new Runnable() { |
153 |
Display display= fNameEntry.getText().getDisplay(); |
| 147 |
public void run() { |
154 |
if (display.getThread() == Thread.currentThread()) |
| 148 |
updateUIFields(); |
155 |
updateUIFields(); |
| 149 |
} |
156 |
else |
| 150 |
}); |
157 |
display.asyncExec(new Runnable() { |
|
|
158 |
public void run() { |
| 159 |
if (!fNameEntry.getText().isDisposed()) |
| 160 |
updateUIFields(); |
| 161 |
} |
| 162 |
}); |
| 151 |
} |
163 |
} |
| 152 |
|
|
|
| 153 |
} |
164 |
} |
| 154 |
|
165 |
|
| 155 |
public void updateUIFields() { |
166 |
public void updateUIFields() { |