[iOS] Launch image names should be the filenames after all.

Related to http://hipbyte.myjetbrains.com/youtrack/issue/RM-596#comment=74-1742
This commit is contained in:
Eloy Durán
2014-09-13 14:43:39 +02:00
committed by Watson
parent 244b53e894
commit 8d17837e31

View File

@@ -351,8 +351,8 @@ module Motion; module Project;
end
def launch_image_metadata(path)
filename = File.basename(path)
filename_components = File.basename(filename, File.extname(filename)).split(/-|@|~/)
filename = File.basename(path, File.extname(path))
filename_components = filename.split(/-|@|~/)
name = filename_components.shift
scale = (filename_components.find { |c| c =~ /\dx/ } || 1).to_i
orientation = filename_components.find { |c| c =~ /Portrait|PortraitUpsideDown|Landscape|LandscapeLeft|LandscapeRight/ } || 'Portrait'
@@ -382,7 +382,7 @@ module Motion; module Project;
# or not the device is a device such as the iPhone 6 and hardcode
# devices.
"UILaunchImageMinimumOSVersion" => "7.0",
"UILaunchImageName" => name,
"UILaunchImageName" => filename,
"UILaunchImageOrientation" => orientation,
"UILaunchImageSize" => "{#{width}, #{height}}"
}