File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
lib/motion/project/template/ios Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -388,6 +388,17 @@ def launch_image_metadata(path)
388388 }
389389 end
390390
391+ def icon_file_names
392+ images = resources_dirs . map do |dir |
393+ Dir . glob ( File . join ( dir , 'Icon*.png' ) ) . map do |file |
394+ f = File . basename ( file , File . extname ( file ) )
395+ i = f . rindex ( '@' )
396+ i ? f [ 0 ...i ] : f
397+ end
398+ end . flatten . compact
399+ images . uniq unless images . empty?
400+ end
401+
391402 # From iOS 7 and up we try to infer the launch images by looking for png
392403 # files that start with 'Default'.
393404 #
@@ -403,6 +414,7 @@ def launch_images
403414 end
404415
405416 def merged_info_plist ( platform )
417+ self . icons = icon_file_names if icons . empty?
406418 ios = {
407419 'MinimumOSVersion' => deployment_target ,
408420 'CFBundleResourceSpecification' => 'ResourceRules.plist' ,
You can’t perform that action at this time.
0 commit comments