Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-11389] Android: TableViewRow - Longpress on tableViewRow gives a RunTime Error

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2012-10-19T17:21:05.000+0000
Affected Version/sRelease 3.0.0
Fix Version/sRelease 3.0.0, Release 3.1.0, 2012 Sprint 21 API, 2012 Sprint 21
ComponentsAndroid
Labelsapi, module_tableviewrow, qe-and100112, qe-testadded, regression
ReporterTamila Smolich
AssigneeKarl Rowley
Created2012-10-11T18:15:27.000+0000
Updated2012-12-20T17:56:53.000+0000

Description

Description: Longpress on tableViewRow gives a RunTime Error. This is a regression, does not occur on 2.1.3 Steps: 1. Run the following code:
var _window = Titanium.UI.createWindow({backgroundColor:'white'});
		
		var row = Titanium.UI.createTableViewRow({
			height : 'auto'
		});
		var view = Titanium.UI.createView({
			backgroundColor : 'red',
			width : '90%',
			height : '40'
		});
		
		row.add(view);
		row.addEventListener('longpress', TableViewRowLongPress);

		var table = Titanium.UI.createTableView();
		table.appendRow(row);
		_window.add(table);

		function TableViewRowLongPress(evt) {
			alert('*TableViewRow longpress');
		}

		_window.open();
2. Long press on a red view Expected: Should get an alert "*TableViewRow longpress" Actual: RunTime Error

Attachments

FileDateSize
device-2012-10-11-110613.png2012-10-11T18:15:27.000+000065468

Comments

  1. Karl Rowley 2012-10-11

    This works with the fix for [TIMOB-11320]. I'm going to mark this ticket as a duplicate.
  2. Karl Rowley 2012-10-11

    duplicate of [TIMOB-11320]
  3. Tamila Smolich 2012-10-17

    Reopening issue. The RunTime Error still appears after long press on red tableView row. Tested on: Titanium Studio, build: 3.0.0.201210151149 Titanium SDK, builds: 3.0.0.v20121017100120; 3.1.0.v20121017102121 Device: Nexus 7 (4.1.1)
  4. Karl Rowley 2012-10-17

    I'm seeing this failure now: Thread [<9> KrollRuntimeThread] (Suspended (exception ClassCastException)) TableViewProxy.fireEvent(String, Object) line: 143 TableViewRowProxy(KrollProxy).fireEventToParent(String, Object) line: 648 V8Object.nativeFireEvent(long, String, Object) line: not available [native method] V8Object.fireEvent(String, Object) line: 58 TableViewRowProxy(KrollProxy).doFireEvent(String, Object) line: 694 TableViewRowProxy(KrollProxy).handleMessage(Message) line: 918 TableViewRowProxy(TiViewProxy).handleMessage(Message) line: 310 TableViewRowProxy.handleMessage(Message) line: 175 Handler.dispatchMessage(Message) line: 95 Looper.loop() line: 130 KrollRuntime$KrollRuntimeThread.run() line: 112
  5. Karl Rowley 2012-10-18

    Pull request https://github.com/appcelerator/titanium_mobile/pull/3286 It looks as though some recent changes to event handling code caused this regression.
  6. Bill Dawson 2012-10-19

    Master PR merged. Ready for 3_0_X cherry-pick PR.
  7. Karl Rowley 2012-10-19

    Created pull request https://github.com/appcelerator/titanium_mobile/pull/3300 for 3_0_X branch.
  8. Shyam Bhadauria 2012-10-25

    No runtime error is thrown now.Verified with following environment on emulator and galaxy nexus 4.0.4. Titanium SDK: 3.1.0.v20121024131714 Titanium SDK:3.0.0.v20121024144610 Titanium  Studio:3.0.0.201210220122

JSON Source