-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix #52 Creation of Menu solving Ant export should be a separate export #66
Fix #52 Creation of Menu solving Ant export should be a separate export #66
Conversation
When I select the new option in the export dialog, I get: |
Ok the problem was on my side, the new java files were not compiled somehow. This works basically :) Some points:
Also please have a look at your coding style. There was some incorrect indentation and some excessive blank lines. You might consider using Eclipse's source format feature. |
https://github.com/shobhanmandal/loeclipse into loeclipse_branch_4 # Conflicts: # core/plugin.properties # java/source/org/libreoffice/ide/eclipse/java/export/JavaExportPart.java
* @param pAntScriptPage | ||
* Helps in retrieving the project selected in this part. | ||
*/ | ||
public static void setAntScriptExportPage(AntScriptExportWizardPage pAntScriptPage) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please no references to the ant stuff from here. If you need a shared method, add it to some helper class or something.
@@ -0,0 +1 @@ | |||
/UnoPackageExportPage.java |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, this file got created and pushed, would remove it
@@ -145,7 +145,7 @@ private void loadData() { | |||
i++; | |||
} | |||
|
|||
if(selected) { | |||
if (selected) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this whole file still needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, this file forms the first page of the Export -> 'LibreOffice Package', the Ant Script gets build from the 'ManifestExportPage' which is the second page in the export. Nothing related to Ant Script building was form the first page, so has to be kept intact, second page 'ManifestExportPage' though had a number of changes.
core/plugin.properties
Outdated
@@ -14,6 +14,7 @@ wizards.service = UNO service | |||
wizards.interface = UNO interface | |||
wizards.export = LibreOffice package | |||
|
|||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please no whitespace / new line changes in existing files.
@@ -78,4 +78,5 @@ public void setPage(ManifestExportPage pPage) { | |||
protected ManifestExportPage getPage() { | |||
return mPage; | |||
} | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
…anges and .gitignore file removed
setControl(body); | ||
|
||
createProjectSelection(); | ||
sContentSelector = new PackageContentSelector(body, SWT.NONE); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we don't need the PackageContentSelector on this wizard. It's not used in the ant export.
} | ||
} | ||
|
||
File tmpDir = new File(directory + "/build.xml"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please chose a better name than tmpDir, maybe antFile?
if (mController.getSaveAntScript()) { | ||
|
||
String directory = mAntScriptPage.getPath(); | ||
File tmpDir = new File(directory + "/build.xml"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please chose a better name than tmpDir, maybe antFile?
*/ | ||
public class AntScriptExportWizard extends Wizard implements IExportWizard { | ||
|
||
private static final String DIALOG_SETTINGS_KEY = "oxt.export"; //$NON-NLS-1$ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please chose a different key here. this one is used for the package export.
@@ -118,7 +116,7 @@ public ManifestExportPage(String pPageName, IUnoidlProject pProject) { | |||
*/ | |||
public void setProject(IUnoidlProject pProject) { | |||
mProject = pProject; | |||
reloadLanguagePart(); | |||
// reloadLanguagePart(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this still needed? If not please remove.
@@ -66,9 +63,20 @@ | |||
private Button mSaveScripts; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This button seems unused?
public class AntScriptExportWizardPage extends WizardPage { | ||
|
||
private IUnoidlProject sSelectedProject; | ||
private LanguageExportPart sLangPart; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hm this LanguageExportPart was designed to add some language specific options to the package export wizard.
It seems a bit weird that we have a LangaugeExportPart on a java specific AntScriptWizardPage.
Maybe you can rename it so it matches better what it's actually used for now? Also I don't know if we still need to derive from the LanguageExportPart, or we just make it an own class?
Maybe also just include the relevant stuff directly here without this extra class?
Not sure what is best, but this looks cumbersome at least.
…d renaming certain variables
A new Wizard Menu under LibreOffice is now shown which allows you to create the ANT file build.xml in one go rather than going for Package Export followed by the ANT file generation.