Lines 7-16
Link Here
|
7 |
* |
7 |
* |
8 |
* Contributors: |
8 |
* Contributors: |
9 |
* IBM Corporation - initial API and implementation |
9 |
* IBM Corporation - initial API and implementation |
|
|
10 |
* Ferenc Hechler, ferenc_hechler@users.sourceforge.net - 83258 [jar exporter] Deploy java application as executable jar |
10 |
*******************************************************************************/ |
11 |
*******************************************************************************/ |
11 |
package org.eclipse.jdt.internal.ui.jarpackager; |
12 |
package org.eclipse.jdt.internal.ui.jarpackager; |
12 |
|
13 |
|
13 |
import java.io.File; |
|
|
14 |
import java.lang.reflect.InvocationTargetException; |
14 |
import java.lang.reflect.InvocationTargetException; |
15 |
import java.util.HashSet; |
15 |
import java.util.HashSet; |
16 |
import java.util.Iterator; |
16 |
import java.util.Iterator; |
Lines 20-26
Link Here
|
20 |
import org.eclipse.core.runtime.IPath; |
20 |
import org.eclipse.core.runtime.IPath; |
21 |
import org.eclipse.core.runtime.IProgressMonitor; |
21 |
import org.eclipse.core.runtime.IProgressMonitor; |
22 |
import org.eclipse.core.runtime.IStatus; |
22 |
import org.eclipse.core.runtime.IStatus; |
23 |
import org.eclipse.core.runtime.Path; |
|
|
24 |
|
23 |
|
25 |
import org.eclipse.core.resources.IFile; |
24 |
import org.eclipse.core.resources.IFile; |
26 |
import org.eclipse.core.resources.IFolder; |
25 |
import org.eclipse.core.resources.IFolder; |
Lines 36-45
Link Here
|
36 |
import org.eclipse.swt.layout.GridData; |
35 |
import org.eclipse.swt.layout.GridData; |
37 |
import org.eclipse.swt.layout.GridLayout; |
36 |
import org.eclipse.swt.layout.GridLayout; |
38 |
import org.eclipse.swt.widgets.Button; |
37 |
import org.eclipse.swt.widgets.Button; |
39 |
import org.eclipse.swt.widgets.Combo; |
|
|
40 |
import org.eclipse.swt.widgets.Composite; |
38 |
import org.eclipse.swt.widgets.Composite; |
41 |
import org.eclipse.swt.widgets.Event; |
|
|
42 |
import org.eclipse.swt.widgets.FileDialog; |
43 |
import org.eclipse.swt.widgets.Label; |
39 |
import org.eclipse.swt.widgets.Label; |
44 |
import org.eclipse.swt.widgets.Link; |
40 |
import org.eclipse.swt.widgets.Link; |
45 |
import org.eclipse.swt.widgets.TreeItem; |
41 |
import org.eclipse.swt.widgets.TreeItem; |
Lines 56-62
Link Here
|
56 |
import org.eclipse.jface.wizard.IWizardPage; |
52 |
import org.eclipse.jface.wizard.IWizardPage; |
57 |
|
53 |
|
58 |
import org.eclipse.ui.PlatformUI; |
54 |
import org.eclipse.ui.PlatformUI; |
59 |
import org.eclipse.ui.dialogs.WizardExportResourcesPage; |
|
|
60 |
|
55 |
|
61 |
import org.eclipse.ltk.core.refactoring.RefactoringCore; |
56 |
import org.eclipse.ltk.core.refactoring.RefactoringCore; |
62 |
import org.eclipse.ltk.core.refactoring.history.IRefactoringHistoryService; |
57 |
import org.eclipse.ltk.core.refactoring.history.IRefactoringHistoryService; |
Lines 82-94
Link Here
|
82 |
import org.eclipse.jdt.internal.ui.IJavaHelpContextIds; |
77 |
import org.eclipse.jdt.internal.ui.IJavaHelpContextIds; |
83 |
import org.eclipse.jdt.internal.ui.filters.EmptyInnerPackageFilter; |
78 |
import org.eclipse.jdt.internal.ui.filters.EmptyInnerPackageFilter; |
84 |
import org.eclipse.jdt.internal.ui.util.ExceptionHandler; |
79 |
import org.eclipse.jdt.internal.ui.util.ExceptionHandler; |
85 |
import org.eclipse.jdt.internal.ui.util.SWTUtil; |
|
|
86 |
import org.eclipse.jdt.internal.ui.viewsupport.LibraryFilter; |
80 |
import org.eclipse.jdt.internal.ui.viewsupport.LibraryFilter; |
87 |
|
81 |
|
88 |
/** |
82 |
/** |
89 |
* Page 1 of the JAR Package wizard |
83 |
* Page 1 of the JAR Package wizard |
90 |
*/ |
84 |
*/ |
91 |
class JarPackageWizardPage extends WizardExportResourcesPage implements IJarPackageWizardPage { |
85 |
class JarPackageWizardPage extends AbstractJarDestinationWizardPage { |
92 |
|
86 |
|
93 |
private JarPackageData fJarPackage; |
87 |
private JarPackageData fJarPackage; |
94 |
private IStructuredSelection fInitialSelection; |
88 |
private IStructuredSelection fInitialSelection; |
Lines 101-109
Link Here
|
101 |
private Button fExportRefactoringsCheckbox; |
95 |
private Button fExportRefactoringsCheckbox; |
102 |
private Link fRefactoringLink; |
96 |
private Link fRefactoringLink; |
103 |
|
97 |
|
104 |
private Combo fDestinationNamesCombo; |
|
|
105 |
private Button fDestinationBrowseButton; |
106 |
|
107 |
private Button fCompressCheckbox; |
98 |
private Button fCompressCheckbox; |
108 |
private Button fOverwriteCheckbox; |
99 |
private Button fOverwriteCheckbox; |
109 |
private Button fIncludeDirectoryEntriesCheckbox; |
100 |
private Button fIncludeDirectoryEntriesCheckbox; |
Lines 116-123
Link Here
|
116 |
private static final String STORE_EXPORT_OUTPUT_FOLDERS= PAGE_NAME + ".EXPORT_OUTPUT_FOLDER"; //$NON-NLS-1$ |
107 |
private static final String STORE_EXPORT_OUTPUT_FOLDERS= PAGE_NAME + ".EXPORT_OUTPUT_FOLDER"; //$NON-NLS-1$ |
117 |
private static final String STORE_EXPORT_JAVA_FILES= PAGE_NAME + ".EXPORT_JAVA_FILES"; //$NON-NLS-1$ |
108 |
private static final String STORE_EXPORT_JAVA_FILES= PAGE_NAME + ".EXPORT_JAVA_FILES"; //$NON-NLS-1$ |
118 |
|
109 |
|
119 |
private static final String STORE_DESTINATION_NAMES= PAGE_NAME + ".DESTINATION_NAMES_ID"; //$NON-NLS-1$ |
|
|
120 |
|
121 |
private static final String STORE_REFACTORINGS= PAGE_NAME + ".REFACTORINGS"; //$NON-NLS-1$ |
110 |
private static final String STORE_REFACTORINGS= PAGE_NAME + ".REFACTORINGS"; //$NON-NLS-1$ |
122 |
private static final String STORE_COMPRESS= PAGE_NAME + ".COMPRESS"; //$NON-NLS-1$ |
111 |
private static final String STORE_COMPRESS= PAGE_NAME + ".COMPRESS"; //$NON-NLS-1$ |
123 |
private final static String STORE_OVERWRITE= PAGE_NAME + ".OVERWRITE"; //$NON-NLS-1$ |
112 |
private final static String STORE_OVERWRITE= PAGE_NAME + ".OVERWRITE"; //$NON-NLS-1$ |
Lines 129-137
Link Here
|
129 |
|
118 |
|
130 |
/** |
119 |
/** |
131 |
* Create an instance of this class |
120 |
* Create an instance of this class |
|
|
121 |
* |
122 |
* @param jarPackage an object containing all required information to make an export |
123 |
* @param selection the initial selection |
132 |
*/ |
124 |
*/ |
133 |
public JarPackageWizardPage(JarPackageData jarPackage, IStructuredSelection selection) { |
125 |
public JarPackageWizardPage(JarPackageData jarPackage, IStructuredSelection selection) { |
134 |
super(PAGE_NAME, selection); |
126 |
super(PAGE_NAME, selection, jarPackage); |
135 |
setTitle(JarPackagerMessages.JarPackageWizardPage_title); |
127 |
setTitle(JarPackagerMessages.JarPackageWizardPage_title); |
136 |
setDescription(JarPackagerMessages.JarPackageWizardPage_description); |
128 |
setDescription(JarPackagerMessages.JarPackageWizardPage_description); |
137 |
fJarPackage= jarPackage; |
129 |
fJarPackage= jarPackage; |
Lines 207-245
Link Here
|
207 |
} |
199 |
} |
208 |
|
200 |
|
209 |
/** |
201 |
/** |
210 |
* Answer the contents of the destination specification widget. If this |
|
|
211 |
* value does not have the required suffix then add it first. |
212 |
* |
213 |
* @return java.lang.String |
214 |
*/ |
215 |
protected String getDestinationValue() { |
216 |
String destinationText= fDestinationNamesCombo.getText().trim(); |
217 |
if (destinationText.indexOf('.') < 0) |
218 |
destinationText += getOutputSuffix(); |
219 |
return destinationText; |
220 |
} |
221 |
|
222 |
/** |
223 |
* Answer the string to display in self as the destination type |
224 |
* |
225 |
* @return java.lang.String |
226 |
*/ |
227 |
protected String getDestinationLabel() { |
228 |
return JarPackagerMessages.JarPackageWizardPage_destination_label; |
229 |
} |
230 |
|
231 |
/** |
232 |
* Answer the suffix that files exported from this wizard must have. |
233 |
* If this suffix is a file extension (which is typically the case) |
234 |
* then it must include the leading period character. |
235 |
* |
236 |
* @return java.lang.String |
237 |
*/ |
238 |
protected String getOutputSuffix() { |
239 |
return "." + JarPackagerUtil.JAR_EXTENSION; //$NON-NLS-1$ |
240 |
} |
241 |
|
242 |
/** |
243 |
* Returns an iterator over this page's collection of currently-specified |
202 |
* Returns an iterator over this page's collection of currently-specified |
244 |
* elements to be exported. This is the primary element selection facility |
203 |
* elements to be exported. This is the primary element selection facility |
245 |
* accessor for subclasses. |
204 |
* accessor for subclasses. |
Lines 257-271
Link Here
|
257 |
* <code>internalSaveWidgetValues</code>. |
216 |
* <code>internalSaveWidgetValues</code>. |
258 |
*/ |
217 |
*/ |
259 |
public final void saveWidgetValues() { |
218 |
public final void saveWidgetValues() { |
|
|
219 |
super.saveWidgetValues(); |
260 |
// update directory names history |
220 |
// update directory names history |
261 |
IDialogSettings settings= getDialogSettings(); |
221 |
IDialogSettings settings= getDialogSettings(); |
262 |
if (settings != null) { |
222 |
if (settings != null) { |
263 |
String[] directoryNames= settings.getArray(STORE_DESTINATION_NAMES); |
|
|
264 |
if (directoryNames == null) |
265 |
directoryNames= new String[0]; |
266 |
directoryNames= addToHistory(directoryNames, getDestinationValue()); |
267 |
settings.put(STORE_DESTINATION_NAMES, directoryNames); |
268 |
|
269 |
settings.put(STORE_EXPORT_CLASS_FILES, fJarPackage.areClassFilesExported()); |
223 |
settings.put(STORE_EXPORT_CLASS_FILES, fJarPackage.areClassFilesExported()); |
270 |
settings.put(STORE_EXPORT_OUTPUT_FOLDERS, fJarPackage.areOutputFoldersExported()); |
224 |
settings.put(STORE_EXPORT_OUTPUT_FOLDERS, fJarPackage.areOutputFoldersExported()); |
271 |
settings.put(STORE_EXPORT_JAVA_FILES, fJarPackage.areJavaFilesExported()); |
225 |
settings.put(STORE_EXPORT_JAVA_FILES, fJarPackage.areJavaFilesExported()); |
Lines 298-318
Link Here
|
298 |
fExportOutputFoldersCheckbox.setSelection(fJarPackage.areOutputFoldersExported()); |
252 |
fExportOutputFoldersCheckbox.setSelection(fJarPackage.areOutputFoldersExported()); |
299 |
fExportJavaFilesCheckbox.setSelection(fJarPackage.areJavaFilesExported()); |
253 |
fExportJavaFilesCheckbox.setSelection(fJarPackage.areJavaFilesExported()); |
300 |
|
254 |
|
301 |
// destination |
255 |
super.restoreWidgetValues(); |
302 |
if (fJarPackage.getJarLocation().isEmpty()) |
|
|
303 |
fDestinationNamesCombo.setText(""); //$NON-NLS-1$ |
304 |
else |
305 |
fDestinationNamesCombo.setText(fJarPackage.getJarLocation().toOSString()); |
306 |
IDialogSettings settings= getDialogSettings(); |
307 |
if (settings != null) { |
308 |
String[] directoryNames= settings.getArray(STORE_DESTINATION_NAMES); |
309 |
if (directoryNames == null) |
310 |
return; // ie.- no settings stored |
311 |
if (! fDestinationNamesCombo.getText().equals(directoryNames[0])) |
312 |
fDestinationNamesCombo.add(fDestinationNamesCombo.getText()); |
313 |
for (int i= 0; i < directoryNames.length; i++) |
314 |
fDestinationNamesCombo.add(directoryNames[i]); |
315 |
} |
316 |
|
256 |
|
317 |
// options |
257 |
// options |
318 |
if (fExportRefactoringsCheckbox != null) |
258 |
if (fExportRefactoringsCheckbox != null) |
Lines 326-331
Link Here
|
326 |
* Initializes the JAR package from last used wizard page values. |
266 |
* Initializes the JAR package from last used wizard page values. |
327 |
*/ |
267 |
*/ |
328 |
protected void initializeJarPackage() { |
268 |
protected void initializeJarPackage() { |
|
|
269 |
super.initializeJarPackage(); |
270 |
|
329 |
IDialogSettings settings= getDialogSettings(); |
271 |
IDialogSettings settings= getDialogSettings(); |
330 |
if (settings != null) { |
272 |
if (settings != null) { |
331 |
// source |
273 |
// source |
Lines 339-350
Link Here
|
339 |
fJarPackage.setCompress(settings.getBoolean(STORE_COMPRESS)); |
281 |
fJarPackage.setCompress(settings.getBoolean(STORE_COMPRESS)); |
340 |
fJarPackage.setIncludeDirectoryEntries(settings.getBoolean(STORE_INCLUDE_DIRECTORY_ENTRIES)); |
282 |
fJarPackage.setIncludeDirectoryEntries(settings.getBoolean(STORE_INCLUDE_DIRECTORY_ENTRIES)); |
341 |
fJarPackage.setOverwrite(settings.getBoolean(STORE_OVERWRITE)); |
283 |
fJarPackage.setOverwrite(settings.getBoolean(STORE_OVERWRITE)); |
342 |
|
|
|
343 |
// destination |
344 |
String[] directoryNames= settings.getArray(STORE_DESTINATION_NAMES); |
345 |
if (directoryNames == null) |
346 |
return; // ie.- no settings stored |
347 |
fJarPackage.setJarLocation(Path.fromOSString(directoryNames[0])); |
348 |
} |
284 |
} |
349 |
} |
285 |
} |
350 |
|
286 |
|
Lines 365-380
Link Here
|
365 |
fJarPackage.setExportJavaFiles(fExportJavaFilesCheckbox.getSelection()); |
301 |
fJarPackage.setExportJavaFiles(fExportJavaFilesCheckbox.getSelection()); |
366 |
fJarPackage.setElements(getSelectedElements()); |
302 |
fJarPackage.setElements(getSelectedElements()); |
367 |
|
303 |
|
368 |
// destination |
304 |
super.updateModel(); |
369 |
String comboText= fDestinationNamesCombo.getText(); |
|
|
370 |
IPath path= Path.fromOSString(comboText); |
371 |
|
372 |
if (path.segmentCount() > 0 && ensureTargetFileIsValid(path.toFile()) && path.getFileExtension() == null) |
373 |
// append .jar |
374 |
path= path.addFileExtension(JarPackagerUtil.JAR_EXTENSION); |
375 |
|
376 |
fJarPackage.setJarLocation(path); |
377 |
|
378 |
// options |
305 |
// options |
379 |
if (fExportRefactoringsCheckbox != null) |
306 |
if (fExportRefactoringsCheckbox != null) |
380 |
fJarPackage.setRefactoringAware(fExportRefactoringsCheckbox.getSelection()); |
307 |
fJarPackage.setRefactoringAware(fExportRefactoringsCheckbox.getSelection()); |
Lines 386-470
Link Here
|
386 |
} |
313 |
} |
387 |
|
314 |
|
388 |
/** |
315 |
/** |
389 |
* Returns a boolean indicating whether the passed File handle is |
|
|
390 |
* is valid and available for use. |
391 |
* |
392 |
* @return boolean |
393 |
*/ |
394 |
protected boolean ensureTargetFileIsValid(File targetFile) { |
395 |
if (targetFile.exists() && targetFile.isDirectory() && fDestinationNamesCombo.getText().length() > 0) { |
396 |
setErrorMessage(JarPackagerMessages.JarPackageWizardPage_error_exportDestinationMustNotBeDirectory); |
397 |
fDestinationNamesCombo.setFocus(); |
398 |
return false; |
399 |
} |
400 |
if (targetFile.exists()) { |
401 |
if (!targetFile.canWrite()) { |
402 |
setErrorMessage(JarPackagerMessages.JarPackageWizardPage_error_jarFileExistsAndNotWritable); |
403 |
fDestinationNamesCombo.setFocus(); |
404 |
return false; |
405 |
} |
406 |
} |
407 |
return true; |
408 |
} |
409 |
|
410 |
/* |
411 |
* Overrides method from WizardExportPage |
412 |
*/ |
413 |
protected void createDestinationGroup(Composite parent) { |
414 |
|
415 |
initializeDialogUnits(parent); |
416 |
|
417 |
// destination specification group |
418 |
Composite destinationSelectionGroup= new Composite(parent, SWT.NONE); |
419 |
GridLayout layout= new GridLayout(); |
420 |
layout.numColumns= 3; |
421 |
destinationSelectionGroup.setLayout(layout); |
422 |
destinationSelectionGroup.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL | GridData.VERTICAL_ALIGN_FILL)); |
423 |
|
424 |
new Label(destinationSelectionGroup, SWT.NONE).setText(getDestinationLabel()); |
425 |
|
426 |
// destination name entry field |
427 |
fDestinationNamesCombo= new Combo(destinationSelectionGroup, SWT.SINGLE | SWT.BORDER); |
428 |
fDestinationNamesCombo.addListener(SWT.Modify, this); |
429 |
fDestinationNamesCombo.addListener(SWT.Selection, this); |
430 |
GridData data= new GridData(GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL); |
431 |
data.widthHint= SIZING_TEXT_FIELD_WIDTH; |
432 |
fDestinationNamesCombo.setLayoutData(data); |
433 |
|
434 |
// destination browse button |
435 |
fDestinationBrowseButton= new Button(destinationSelectionGroup, SWT.PUSH); |
436 |
fDestinationBrowseButton.setText(JarPackagerMessages.JarPackageWizardPage_browseButton_text); |
437 |
fDestinationBrowseButton.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL)); |
438 |
SWTUtil.setButtonDimensionHint(fDestinationBrowseButton); |
439 |
fDestinationBrowseButton.addSelectionListener(new SelectionAdapter() { |
440 |
public void widgetSelected(SelectionEvent e) { |
441 |
handleDestinationBrowseButtonPressed(); |
442 |
} |
443 |
}); |
444 |
} |
445 |
|
446 |
/** |
447 |
* Open an appropriate destination browser so that the user can specify a source |
448 |
* to import from |
449 |
*/ |
450 |
protected void handleDestinationBrowseButtonPressed() { |
451 |
FileDialog dialog= new FileDialog(getContainer().getShell(), SWT.SAVE); |
452 |
dialog.setFilterExtensions(new String[] {"*.jar", "*.zip"}); //$NON-NLS-1$ //$NON-NLS-2$ |
453 |
|
454 |
String currentSourceString= getDestinationValue(); |
455 |
int lastSeparatorIndex= currentSourceString.lastIndexOf(File.separator); |
456 |
if (lastSeparatorIndex != -1) { |
457 |
dialog.setFilterPath(currentSourceString.substring(0, lastSeparatorIndex)); |
458 |
dialog.setFileName(currentSourceString.substring(lastSeparatorIndex + 1, currentSourceString.length())); |
459 |
} |
460 |
else |
461 |
dialog.setFileName(currentSourceString); |
462 |
String selectedFileName= dialog.open(); |
463 |
if (selectedFileName != null) |
464 |
fDestinationNamesCombo.setText(selectedFileName); |
465 |
} |
466 |
|
467 |
/** |
468 |
* Returns the resource for the specified path. |
316 |
* Returns the resource for the specified path. |
469 |
* |
317 |
* |
470 |
* @param path the path for which the resource should be returned |
318 |
* @param path the path for which the resource should be returned |
Lines 655-675
Link Here
|
655 |
setErrorMessage(null); |
503 |
setErrorMessage(null); |
656 |
return complete; |
504 |
return complete; |
657 |
} |
505 |
} |
658 |
|
|
|
659 |
/* |
660 |
* Implements method from Listener |
661 |
*/ |
662 |
public void handleEvent(Event e) { |
663 |
if (getControl() == null) |
664 |
return; |
665 |
update(); |
666 |
} |
667 |
|
668 |
protected void update() { |
669 |
updateModel(); |
670 |
updateWidgetEnablements(); |
671 |
updatePageCompletion(); |
672 |
} |
673 |
|
506 |
|
674 |
protected void updatePageCompletion() { |
507 |
protected void updatePageCompletion() { |
675 |
boolean pageComplete= isPageComplete(); |
508 |
boolean pageComplete= isPageComplete(); |
Lines 691-741
Link Here
|
691 |
/* |
524 |
/* |
692 |
* Overrides method from WizardDataTransferPage |
525 |
* Overrides method from WizardDataTransferPage |
693 |
*/ |
526 |
*/ |
694 |
protected boolean validateDestinationGroup() { |
|
|
695 |
if (fDestinationNamesCombo.getText().length() == 0) { |
696 |
// Clear error |
697 |
if (getErrorMessage() != null) |
698 |
setErrorMessage(null); |
699 |
if (getMessage() != null) |
700 |
setMessage(null); |
701 |
return false; |
702 |
} |
703 |
if (fJarPackage.getAbsoluteJarLocation().toString().endsWith("/")) { //$NON-NLS-1$ |
704 |
setErrorMessage(JarPackagerMessages.JarPackageWizardPage_error_exportDestinationMustNotBeDirectory); |
705 |
fDestinationNamesCombo.setFocus(); |
706 |
return false; |
707 |
} |
708 |
// Check if the Jar is put into the workspace and conflicts with the containers |
709 |
// exported. If the workspace isn't on the local files system we are fine since |
710 |
// the Jar is always created in the local file system |
711 |
IPath workspaceLocation= ResourcesPlugin.getWorkspace().getRoot().getLocation(); |
712 |
if (workspaceLocation != null && workspaceLocation.isPrefixOf(fJarPackage.getAbsoluteJarLocation())) { |
713 |
int segments= workspaceLocation.matchingFirstSegments(fJarPackage.getAbsoluteJarLocation()); |
714 |
IPath path= fJarPackage.getAbsoluteJarLocation().removeFirstSegments(segments); |
715 |
IResource resource= ResourcesPlugin.getWorkspace().getRoot().findMember(path); |
716 |
if (resource != null && resource.getType() == IResource.FILE) { |
717 |
// test if included |
718 |
if (JarPackagerUtil.contains(JarPackagerUtil.asResources(fJarPackage.getElements()), (IFile)resource)) { |
719 |
setErrorMessage(JarPackagerMessages.JarPackageWizardPage_error_cantExportJARIntoItself); |
720 |
return false; |
721 |
} |
722 |
} |
723 |
} |
724 |
// Inform user about relative directory |
725 |
String currentMessage= getMessage(); |
726 |
if (!(new File(fDestinationNamesCombo.getText()).isAbsolute())) { |
727 |
if (currentMessage == null) |
728 |
setMessage(JarPackagerMessages.JarPackageWizardPage_info_relativeExportDestination, IMessageProvider.INFORMATION); |
729 |
} else { |
730 |
if (currentMessage != null) |
731 |
setMessage(null); |
732 |
} |
733 |
return ensureTargetFileIsValid(fJarPackage.getAbsoluteJarLocation().toFile()); |
734 |
} |
735 |
|
736 |
/* |
737 |
* Overrides method from WizardDataTransferPage |
738 |
*/ |
739 |
protected boolean validateOptionsGroup() { |
527 |
protected boolean validateOptionsGroup() { |
740 |
return true; |
528 |
return true; |
741 |
} |
529 |
} |
Lines 799-811
Link Here
|
799 |
return null; |
587 |
return null; |
800 |
} |
588 |
} |
801 |
|
589 |
|
802 |
/** |
|
|
803 |
* Set the current input focus to self's destination entry field |
804 |
*/ |
805 |
protected void giveFocusToDestination() { |
806 |
fDestinationNamesCombo.setFocus(); |
807 |
} |
808 |
|
809 |
/* |
590 |
/* |
810 |
* Overrides method from WizardExportResourcePage |
591 |
* Overrides method from WizardExportResourcePage |
811 |
*/ |
592 |
*/ |
Lines 849-861
Link Here
|
849 |
} |
630 |
} |
850 |
|
631 |
|
851 |
/* |
632 |
/* |
852 |
* Implements method from IJarPackageWizardPage. |
|
|
853 |
*/ |
854 |
public void finish() { |
855 |
saveWidgetValues(); |
856 |
} |
857 |
|
858 |
/* |
859 |
* Method declared on IWizardPage. |
633 |
* Method declared on IWizardPage. |
860 |
*/ |
634 |
*/ |
861 |
public void setPreviousPage(IWizardPage page) { |
635 |
public void setPreviousPage(IWizardPage page) { |