@@ -63,7 +63,7 @@ public class AppBundlerTask extends Task {
6363 private String name = null ;
6464 private String displayName = null ;
6565 private String identifier = null ;
66- private File icon = null ;
66+ private File iconFile = null ;
6767 private String executableName = EXECUTABLE_NAME ;
6868
6969 private String shortVersion = null ; //"1.0";
@@ -121,7 +121,7 @@ public void setIdentifier(String identifier) {
121121
122122
123123 public void setIcon (File icon ) {
124- this .icon = icon ;
124+ this .iconFile = icon ;
125125 }
126126
127127
@@ -332,12 +332,12 @@ public void execute() throws BuildException {
332332 throw new IllegalStateException ("Identifier is required." );
333333 }
334334
335- if (icon != null ) {
336- if (!icon .exists ()) {
335+ if (iconFile != null ) {
336+ if (!iconFile .exists ()) {
337337 throw new IllegalStateException ("Icon does not exist." );
338338 }
339339
340- if (icon .isDirectory ()) {
340+ if (iconFile .isDirectory ()) {
341341 throw new IllegalStateException ("Invalid icon." );
342342 }
343343 }
@@ -552,11 +552,11 @@ private void copyLibraryPathEntries(File macOSDirectory) throws IOException {
552552
553553
554554 private void copyIcon (File resourcesDirectory ) throws IOException {
555- if (icon == null ) {
555+ if (iconFile == null ) {
556556 copy (getClass ().getResource (DEFAULT_ICON_NAME ),
557557 new File (resourcesDirectory , DEFAULT_ICON_NAME ));
558558 } else {
559- copy (icon , new File (resourcesDirectory , icon .getName ()));
559+ copy (iconFile , new File (resourcesDirectory , iconFile .getName ()));
560560 }
561561 }
562562
@@ -584,7 +584,7 @@ private void writeInfoPlist(File file) throws IOException {
584584 // Write bundle properties
585585 plist .writeProperty ("CFBundleDevelopmentRegion" , "English" );
586586 plist .writeProperty ("CFBundleExecutable" , executableName );
587- plist .writeProperty ("CFBundleIconFile" , (icon == null ) ? DEFAULT_ICON_NAME : icon .getName ());
587+ plist .writeProperty ("CFBundleIconFile" , (iconFile == null ) ? DEFAULT_ICON_NAME : iconFile .getName ());
588588 plist .writeProperty ("CFBundleIdentifier" , identifier );
589589 plist .writeProperty ("CFBundleDisplayName" , displayName );
590590 plist .writeProperty ("CFBundleInfoDictionaryVersion" , "6.0" );
0 commit comments