{ "id": "92399", "key": "TIMOB-9280", "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": "14164", "description": "Release 3.0.2", "name": "Release 3.0.2", "archived": true, "released": true, "releaseDate": "2013-02-19" } ], "resolution": { "id": "5", "description": "All attempts at reproducing this issue failed, or not enough information was available to reproduce the issue. Reading the code produces no clues as to why this behavior would occur. If more information appears later, please reopen the issue.", "name": "Cannot Reproduce" }, "resolutiondate": "2013-03-19T07:02:35.000+0000", "created": "2012-05-25T12:01:31.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "api" ], "versions": [ { "id": "13271", "description": "Release 2.1.0", "name": "Release 2.1.0", "archived": false, "released": true, "releaseDate": "2012-06-29" } ], "issuelinks": [], "assignee": { "name": "jithinv@exalture.com", "key": "jithinv@exalture.com", "displayName": "jithinpv", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-03-21T21:24:57.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": "h4. Problem Description\r\nWhen customer uses scrollview to show several textfields, the textfields at the bottom won't be seen when clicked, since they hide under the softkeyboard. \r\n\r\nh4. Actual Results\r\nThe textfield in the scrollview is hidden under the keyboard.\r\n\r\nh4. Expected Results\r\nThe textfield scrolling properly, so you can see the textfield on top of the keyboard.\r\n\r\nh4. TestCase\r\n1. Create mobile project.\r\n2. Paste this app.js:\r\n{code}\r\nvar win = Ti.UI.createWindow({\r\n title:'pippo',\r\n backgroundColor:'white',\r\n windowSoftInputMode:Ti.UI.Android.SOFT_INPUT_ADJUST_PAN,\r\n layout:'vertical',\r\n fullscreen:'false',\r\n});\r\nwin.orientationModes = [Titanium.UI.PORTRAIT, Titanium.UI.UPSIDE_PORTRAIT, Titanium.UI.LANDSCAPE_LEFT, Titanium.UI.LANDSCAPE_RIGHT];\r\n\r\n\r\nvar curTop = 0;\r\n \r\n \r\nfunction createRows(i) {\r\n var row = Titanium.UI.createView({\r\n width:'100%',\r\n height : Ti.UI.SIZE,\r\n left:0,\r\n bottom:0,\r\n backgroundColor : 'white',\r\n borderColor:'#bbb',\r\n borderWidth:1\r\n });\r\n var inputTextField = Titanium.UI.createTextField({\r\n color : '#ff7c00',\r\n top:10,\r\n height : 50,\r\n textAlign : 'right',\r\n width : '25%',\r\n hintText : '',\r\n left : '65%',\r\n right : '8%',\r\n borderStyle : Titanium.UI.INPUT_BORDERSTYLE_ROUNDED,\r\n keyboardType : Titanium.UI.KEYBOARD_NUMBERS_PUNCTUATION,\r\n returnKeyType : Titanium.UI.RETURNKEY_DONE,\r\n font : {\r\n fontSize : 20,\r\n fontColor : '#ff7c00',\r\n fontWeight : 'bold',\r\n fontFamily : 'Helvetica Neue'\r\n }\t\r\n });\r\n /* inputTextField.addEventListener('focus', function(e) {\r\n Ti.API.info(\"Parent's height: \"+ inputTextField.getParent().getHeight());\r\n Ti.API.info(\"Parent's top: \"+ inputTextField.getParent().top);\r\n Ti.API.info(\"Size of the view: \"+ inputTextField.getParent().size.height+\" \"+inputTextField.getParent().size.width+\" \"+inputTextField.getParent().size.x+\" \"+inputTextField.getParent().size.y);\r\n Ti.API.info(\"Size of the scrollview: \"+scrollView.contentHeight);\r\n scrollView.scrollTo(0,(inputTextField.getParent().top-(Ti.Platform.displayCaps.platformHeight/4)));\r\n }); */ \r\n inputTextField.addEventListener('return', function() {\r\n alert('return');\r\n inputTextField.blur();\r\n });\r\n \r\n row.add(inputTextField);\r\n return row;\r\n}\r\n \r\n \r\nvar scrollView = Ti.UI.createScrollView({\r\n top:0,\r\n bottom:0,\r\n layout:'vertical',\r\n contentWidth:Ti.UI.SIZE,\r\n contentHeight:Ti.UI.SIZE\r\n})\r\n\r\nfor( i = 0; i <= 20; i++) {\r\n var row = createRows(i);\r\n scrollView.add(row);\r\n curTop += 70;\r\n};\r\n\r\nif (i==20) {\r\n\tvar viewFiller = Ti.UI.createView({\r\n\t\topacity:30, \r\n\t\theight:59,\r\n\t\tbottom:10\r\n\t})\r\n\tscrollView.add(viewFiller);\r\n}\r\n\r\nwin.add(scrollView);\r\n \r\nwin.open();\r\n{code}\r\n3. Run it in a device (See extra info to see where is not working).\r\n4. Click on the bottom textfield.\r\n5. See that you can type, but you can't see what you typing\r\n\r\nh4. Extra info\r\nWe tested this case, and it's working in some cases, in others don't:\r\n\r\nWorking fine: \r\nAndroid emulator - Works fine.\r\nAcer Iconia A500 - OS 3.2 - Working Fine\r\nMotorola Droid 1, running 2.2.3 - Working fine\r\nMotorola Droid 3 with Android 2.3.4 - Working fine.\r\n\r\nFailing: \r\nhtc sprint slider device - PG06100, OS ver 2.2 - Does not work fine\r\nsamsung galaxy Nexus - OS ver 4.0.2 - Does not work fine\r\nMotorola MB860 - OS ver 2.3.4 - Does not work fine\r\nhtc spring non slider device PC36100 - OS ver 2.2 - Does not work fine\r\n\r\n", "attachment": [], "flagged": false, "summary": "Android: Scrollview+Textfields is not working properly (The textfield/view hides behind the keyboard, instead of scroll to be on top of the keyboard).", "creator": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "subtasks": [], "reporter": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "environment": "Titanium SDK version: 2.1.0v20120524 \r\nJavascript Engine: V8 \r\nPlatform & version: Android 2.3.x, Android 3.2, Android 4.x \r\nDevice Details: Android emulator, HTC Sprint PG06100, Motorola MB860, HTC Sprint PC36100, Samsung Galaxy Nexus\r\nHost Operating System: OS X 10.7.3\r\nTitanium Studio version: 2.0", "comment": { "comments": [ { "id": "242863", "author": { "name": "jithinv@exalture.com", "key": "jithinv@exalture.com", "displayName": "jithinpv", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Issue does not reproduces \r\n\r\nTested with\r\n\r\nTitanium Studio, build: 3.0.1.201212181159\r\nTitanium SDK version: 3.1.0 (03/11/13 15:43 0c88429)\r\nTitanium SDK version: 3.0.2 (02/07/13 16:46 a4def81)\r\nDevice: Samsung galaxy s duos Android version: 4.0.4\r\n\r\njithinpv\r\n", "updateAuthor": { "name": "jithinv@exalture.com", "key": "jithinv@exalture.com", "displayName": "jithinpv", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-19T07:02:35.000+0000", "updated": "2013-03-19T07:02:35.000+0000" }, { "id": "414438", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as the issue cannot be reproduced.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-03-21T21:24:57.000+0000", "updated": "2017-03-21T21:24:57.000+0000" } ], "maxResults": 3, "total": 3, "startAt": 0 } } }