{ "id": "104288", "key": "TIMOB-11640", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "14162", "description": "Release 3.1.0", "name": "Release 3.1.0", "archived": true, "released": true, "releaseDate": "2013-04-16" }, { "id": "15275", "description": "2013 Sprint 04 Core", "name": "2013 Sprint 04 Core", "archived": true, "released": true, "releaseDate": "2013-02-25" }, { "id": "14814", "description": "2013 Sprint 04", "name": "2013 Sprint 04", "archived": true, "released": true, "releaseDate": "2013-02-25" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2013-02-25T18:33:26.000+0000", "created": "2012-11-01T21:22:22.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "core", "layout", "module_scrollView", "qe-testadded", "triage" ], "versions": [ { "id": "14137", "description": "Release 2.1.3", "name": "Release 2.1.3", "archived": true, "released": true, "releaseDate": "2012-10-03" } ], "issuelinks": [ { "id": "22524", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "inwardIssue": { "id": "104155", "key": "TIMOB-11610", "fields": { "summary": "iOS:Remote Images inside a vertical ScrollView not scaling properly", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "ayeung", "key": "ayeung", "displayName": "Allen Yeung", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2013-10-03T13:12:48.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" } ], "description": "When trying to add an imageView to a scrollView with a vertical layout, the imageView has a height that is much larger than the image that is displayed. The image is being scaled and displayed but there is a white blank space displayed above,thought the top is set as '10dp'. It works fine when the app is loaded for the first time.\r\n\r\nh4.Steps to reproduce:\r\n1.Load the below app.js\r\n2.Run it on Android Device (4.1)\r\n3.Close and re-open the app by just tapping on the home.\r\n4.After doing it for 4 - 5 times on an average you can see that the height is set to 10dp anymore.\r\n\r\nExpected: There should be no space above the image, no matter how many times we launch the app.\r\n\r\nActual Behavior: There is some empty space above and below the image after folding and re-opening the app couple of times.\r\n\r\nh4.app.js:\r\n{code}\r\nvar detailWindow = Titanium.UI.createWindow({\r\n\tbackgroundColor : '#fff'\r\n});\r\n\r\nvar detailScrollView = Ti.UI.createScrollView({\r\n\tlayout : 'vertical'\r\n});\r\n\r\nvar imageView = Ti.UI.createImageView({\r\n\timage : \"https://s3.amazonaws.com/static.tumblr.com/6t3upxl/Aawm08w0l/khout-kitten-458882.jpeg\",\r\n\ttop : '10dp'\r\n\r\n});\r\n\r\ndetailScrollView.add(imageView);\r\n\r\ndetailWindow.add(detailScrollView);\r\n\r\ndetailWindow.open(); \r\n\r\n\r\n{code}", "attachment": [], "flagged": false, "summary": "Android: Remote Images inside a vertical ScrollView not scaling properly (only seen after closing and reopening the app couple of times)", "creator": { "name": "aakkinepally", "key": "aakkinepally", "displayName": "Amuktha Akkinepally", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "aakkinepally", "key": "aakkinepally", "displayName": "Amuktha Akkinepally", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Android 4.1.1, Ti SDK 2.1.3", "comment": { "comments": [ { "id": "225870", "author": { "name": "aakkinepally", "key": "aakkinepally", "displayName": "Amuktha Akkinepally", "active": true, "timeZone": "America/Los_Angeles" }, "updateAuthor": { "name": "aakkinepally", "key": "aakkinepally", "displayName": "Amuktha Akkinepally", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-11-01T21:22:50.000+0000", "updated": "2012-11-01T21:22:50.000+0000" }, { "id": "237590", "author": { "name": "sunila", "key": "sunila", "displayName": "Sunila", "active": true, "timeZone": "Asia/Kolkata" }, "body": "I spent some time on this but couldn't come up with a solution.\r\nHere is my observation\r\nSince size is not specifiex, the image is first loaded with the original size and when the container(scrollview) do the layout it restrict the size to the scrollview width but the height is set to the originial image height. When the image is drawn, since the width is less, the hieght is also reduced to keep the aspect ratio same and the remaining spaces are see on top and bottom. ", "updateAuthor": { "name": "sunila", "key": "sunila", "displayName": "Sunila", "active": true, "timeZone": "Asia/Kolkata" }, "created": "2013-02-07T02:37:45.000+0000", "updated": "2013-02-07T02:37:45.000+0000" }, { "id": "239298", "author": { "name": "ayeung", "key": "ayeung", "displayName": "Allen Yeung", "active": true, "timeZone": "America/Los_Angeles" }, "body": "https://github.com/appcelerator/titanium_mobile/pull/3897", "updateAuthor": { "name": "ayeung", "key": "ayeung", "displayName": "Allen Yeung", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-02-21T19:20:28.000+0000", "updated": "2013-02-21T19:20:28.000+0000" }, { "id": "241661", "author": { "name": "oromero", "key": "oromero", "displayName": "Olga Romero", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Tested with:\r\nTitanium Studio, build: 3.0.3.201302201202\r\nTitanium SDK, build: 3.1.0.v20130311012453\r\nDevices:\r\nNexus4 4.2(There is space above the image at launch only, the image is scaling properly after closing and reopening the app )\r\nSamsung GalaxyS3 4.0.4 (There is space above the image, no matter how many times we launch the app.)\r\n", "updateAuthor": { "name": "oromero", "key": "oromero", "displayName": "Olga Romero", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-11T21:47:04.000+0000", "updated": "2013-03-11T21:51:18.000+0000" }, { "id": "241719", "author": { "name": "amittal", "key": "amittal", "displayName": "Anshu Mittal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Tested with: \r\nSDK: 3.1.0.v20130312015656\r\nStudio: 3.1.0.201303091040\r\nDevice: Nexus7(v android 4.1)\r\n\r\nWorking as expected", "updateAuthor": { "name": "amittal", "key": "amittal", "displayName": "Anshu Mittal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-12T09:19:47.000+0000", "updated": "2013-03-12T09:19:47.000+0000" } ], "maxResults": 7, "total": 7, "startAt": 0 } } }