Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-6711] iOS: Disappearing events in views/elements nested in ScrollViews

GitHub Issuen/a
TypeBug
PriorityLow
StatusResolved
ResolutionFixed
Resolution Date2019-11-01T21:28:39.000+0000
Affected Version/sRelease 1.7.5, Release 1.8.0.1
Fix Version/sSprint 2012-02, Release 1.8.1, Release 7.5.0
ComponentsiOS
Labelsmodule_scrollview, parity, qe-testadded
ReporterMauro Parra-Miranda
AssigneeUnknown
Created2011-12-15T15:55:58.000+0000
Updated2019-12-02T23:06:27.000+0000

Description

PROBLEM DESCRIPTION

If you have a view inside a scrollview with the property "vertical", you will lose the events in the nested views/elements.

STEPS TO REPRODUCE

1. Create a new mobile project 2. Paste the code below into app.js 3. Singletap on the label or the scroll.

ACTUAL RESULTS

The singletap event is not fired.

EXPECTED RESULTS

Singletap event should be fired.

CODE

var win = Ti.UI.createWindow({
    backgroundColor:'white',
    borderColor:    'black',
    borderWidth:    1,
    width:      '100%',
    height:     '100%',
    navBarHidden:   true
});
var scrollView = Ti.UI.createScrollView({
    layout:     'vertical',
    height:     '100%',
    contentWidth:   'auto',
    contentHeight:  'auto',
    showVerticalScrollIndicator: true,
    touchEnabled:   true
});
var textLabel = Ti.UI.createLabel({
    color:      'black',
    text:       "Tab here to fire the singletap event!",
    textAlign:  'left',
    left:       6,
    right:      6,
    top:        6,
    height:     'auto',
    touchEnabled:   false
});
scrollView.add(textLabel);
win.addEventListener('singletap', function(){
    Ti.API.info('singletap event fired!');
});
win.add(scrollView);
win.open();

Comments

  1. Blain Hamon 2012-01-09

    Adding event listeners has pointed out that we have far from parity with event sequence and triggering between Android and iOS. A cursory examination is at: https://wiki.appcelerator.org/display/pe/User+click-touch+event+handling
  2. Blain Hamon 2012-01-20

    Pull pending means it's still in progress.
  3. Wilson Luu 2012-01-23

    Closing bug. Verified fix on: SDK build: 1.9.0.v20120121223134 Titanium Studio, build: 1.0.8.201201210622 Xcode: 4.2 OS: Mac OS X Lion (10.7.2) Device: iPhone 4S Verizon (5.0.1)
  4. Eric Merriman 2017-09-08

    Occurs with SDK 6.0.0 -> 6.2.0.v20170908103920
  5. Alan Hutton 2019-11-01

    Cannot reproduce. Axway Appcelerator Studio, build: 5.1.4.201909061933  macOS : 10.15 Node.js Version : 8.9.1 npm Version : 5.5.1 Appcelerator CLI : 7.1.1 Titanium CLI CLI Version : 5.2.1 node-appc Version : 0.2.49 Titanium SDKs : 8.2.1.GA

JSON Source