Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-25979

Android: Changing index break events on TableViewRow

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: Release 7.1.0
    • Fix Version/s: Release 7.5.0
    • Component/s: Android
    • Environment:

      MacOS
      SDK: 7.1.0
      Genymotion Emulator

    • Story Points:
      3
    • Sprint:
      2016 Sprint 17 SDK

      Description

      When we populate TableView with TableViewRows and then change their order with updateRow method it will prevent firing events on the TableViewRow with lowest index. This includes click and touchstart events.

      Code to reproduce:

      var window = Ti.UI.createWindow();
      window.open();
       
       
      var container = Ti.UI.createView({	
      	backgroundColor: '#333'
      });
       
      	var tableView = Ti.UI.createTableView({
      		backgroundColor: 'white'
      	});
      	
      	var row1 = Ti.UI.createTableViewRow({
      		height: 50,
      		backgroundColor: 'red',
      		className: 'scheduled'
      	});
      	
      	var row2 = Ti.UI.createTableViewRow({
      		height: 50,
      		backgroundColor: 'green',
      		className: 'scheduled'
      	});
      	
      	
      	var row3 = Ti.UI.createTableViewRow({
      		height: 50,
      		backgroundColor: 'yellow',
      		className: 'scheduled'
      	});
      	
      	
      	
      	tableView.appendRow(row1);
      	tableView.appendRow(row2);
      	tableView.appendRow(row3);
      	
      	tableView.updateRow(0, row3); //this row will stop to react on events
      	tableView.updateRow(1, row2);
      	tableView.updateRow(2, row1);
      	
      	container.add(tableView);
       
       
      window.add(container);
      	
      tableView.addEventListener('click', function() {alert('clickFromTableView');});
      container.addEventListener('click', function() {alert('clickFromContainer');});
      

        Attachments

          Activity

            People

            • Assignee:
              ybanev Yordan Banev
              Reporter:
              CREATIVE KAIZEN CREATIVE KAIZEN
              Reviewer:
              Gary Mathews
              Tester:
              Samir Mohammed
            • Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Backbone Issue Sync

                • Titanium SDK/CLI <> Titanium Mobile
                  Synced with:
                  TIMOB-6313
                  Sync status:
                  ERROR
                  Last received:
                  Last sent:

                  Git Source Code