Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-4689] iOS:globalPoint property is undefined in a tableview click event

GitHub Issuen/a
TypeBug
PriorityLow
StatusClosed
ResolutionDuplicate
Resolution Date2011-08-01T12:33:40.000+0000
Affected Version/sRelease 1.7.0
Fix Version/sSprint 2011-31
ComponentsiOS
Labelsn/a
ReporterAnirudh Nagesh
AssigneeBlain Hamon
Created2011-07-14T18:12:20.000+0000
Updated2017-03-03T22:30:04.000+0000

Description

The globalpoint property in a click event on a tableview is undefined. It does not return the screen co-ordinates. Step1: Copy the below code in app.js
Titanium.UI.setBackgroundColor('white');

var win = Titanium.UI.createWindow();
var data = [{title:"Row 1"},{title:"Row 2"}];
var table = Titanium.UI.createTableView({data:data,backgroundColor:'#336699'});

table.addEventListener('click',function(e)

{
	Ti.API.info('globalpoint dictionary is...' +e.globalPoint);
	Ti.API.info('X co-ordinate is'+e.x);
	Ti.API.info('Y co-ordinate is'+e.y);
}

);
win.add(table);
win.open();
Step2: The globalPoint property is undefined Workaround: to obtain the screen co-ordinates using e.x and e.y

Associated helpdesk ticket:

http://support-admin.appcelerator.com/display/APP-152774

Comments

  1. Blain Hamon 2011-08-01

    TIMOB-4475 already caused globalpoint to be added to tableview. Verified that we're getting x and y locations in the sample code.
  2. Lee Morris 2017-03-03

    Closing as duplicate.

JSON Source