[ALOY-1002] Platform-specific folders within a widget's assets are copied unnecessarily to the Resources folder
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2014-08-13T14:07:11.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Alloy 1.5.0 |
Components | Tooling |
Labels | qe-manualtest |
Reporter | Tim Poulsen |
Assignee | Feon Sua Xin Miao |
Created | 2014-05-01T17:42:49.000+0000 |
Updated | 2014-09-12T03:02:06.000+0000 |
Description
Consider a widget with assets including assets in platform-specific folders.
Test case: app/themes/plusminus/widgets/starrating/assets/ios/star_half.png (a logo) app/themes/plusminus/widgets/starrating/assets/android/star_half.png (blue circle) app/themes/plusminus/widgets/starrating/assets/foo.png (brown circle) app/themes/plusminus/widgets/starrating/assets/star.png (plus) app/themes/plusminus/widgets/starrating/assets/star_off.png (minus) app/widgets/starrating/assets/ios/star.png (red) app/widgets/starrating/assets/android/star.png (green) app/widgets/starrating/assets/star.png (yellow) app/widgets/starrating/assets/star_half.png (half) app/widgets/starrating/assets/star_off.png (off) ------ After compilation, there are some unnecessary files: iphone Resources/iphone/ios/starrating/star.png (red) Resources/iphone/starrating/ios/star_half.png (a logo) Resources/iphone/starrating/android/star_half.png (blue circle) Resources/iphone/starrating/foo.png (brown circle) Resources/iphone/starrating/star.png (red) Resources/iphone/starrating/star_half.png (a logo) Resources/iphone/starrating/star_off.png (minus) — android Resources/android/ios/starrating/star.png (red) Resources/android/starrating/ios/star_half.png (a logo) Resources/android/starrating/android/star_half.png (blue circle) Resources/android/starrating/foo.png (brown circle) Resources/android/starrating/star.png (plus) Resources/android/starrating/star_half.png (half) Resources/android/starrating/star_off.png (minus)
PR : https://github.com/appcelerator/alloy/pull/426 Test app: https://github.com/feons/alloy/tree/ALOY-1002/test/apps/testing/ALOY-1002 Functional Test: The assets in the test app are organized like this: app/themes/plusminus/widgets/starrating/assets/ios/star_half.png (a logo) app/themes/plusminus/widgets/starrating/assets/android/star_half.png (blue circle) app/themes/plusminus/widgets/starrating/assets/foo.png (brown circle) app/themes/plusminus/widgets/starrating/assets/star.png (plus) app/themes/plusminus/widgets/starrating/assets/star_off.png (minus) app/widgets/starrating/assets/ios/star.png (red) app/widgets/starrating/assets/android/star.png (green) app/widgets/starrating/assets/star.png (yellow) app/widgets/starrating/assets/star_half.png (half) app/widgets/starrating/assets/star_off.png ( off ) So, after compilation the Resources folder should have these files and no platform-specific folders: For iphone: Resources/iphone/starrating/star_half.png (a logo) Resources/iphone/starrating/star.png (red) Resources/iphone/starrating/foo.png (brown circle) Resources/iphone/starrating/star_off.png (minus) For android: Resources/android/starrating/star_half.png (blue circle) Resources/android/starrating/star.png (green) Resources/android/starrating/foo.png (brown circle) Resources/android/starrating/star_off.png (minus) For mobileweb: Resources/mobileweb/starrating/star_half.png (half) Resources/mobileweb/starrating/star.png (plus) Resources/mobileweb/starrating/foo.png (brown circle) Resources/mobileweb/starrating/star_off.png (minus) ---- The ordering goes like this from highest to lowest priority: themed widget platform-specific assets widget platform specific assets themed widget non-platform-specific assets widget non-platform-specific assets
PR tested and merged
app/widgets/<widget name>/assets/ios
folder is copied to Resources folder for all platforms, reopening to track implementing the fix.PR: https://github.com/appcelerator/alloy/pull/506 Run this from repo directory, after compilation the Resources folder should not have platform-specific folders:
There should be no image not found error messages when running this:
PR merged
Verified fixed. TiSDK 3.4.0.v20140911135715 Appcelerator Studio 3.4.0.201409111151 CLI 3.4.0-rc2 Alloy 1.5.0-rc Xcode6-beta7 Closing.