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

Android: Add scrollstart/scrollend to ScrollView

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Medium
    • Resolution: Unresolved
    • Affects Version/s: Release 8.1.0
    • Fix Version/s: None
    • Component/s: None

      Description

      Addding scrollstart and scrollend events to ScrollView.

      Example:

      var win = Ti.UI.createWindow({backgroundColor: '#fff'});
      var view1 = Ti.UI.createView({width:20,height:1520,backgroundColor:"#f00",top:0,borderWidth:1,borderColor:"#000"});
      var scrollView = Ti.UI.createScrollView({height:Ti.UI.FILL,width:Ti.UI.FILL});
      var ldi = Ti.Platform.displayCaps.logicalDensityFactor;
      scrollView.addEventListener("scrollend",function(e){
      	console.log("scrollend");
      })
      scrollView.addEventListener("scrollstart",function(e){
      	console.log("scrollstart");
      })
      win.add(scrollView);
      scrollView.add(view1);
       
      win.open();
      
      

      it is based on: https://stackoverflow.com/a/24883303/5193915
      and will use a Runnable with 100ms to check if the scroll event is called or not.

      Possible PR: https://github.com/m1ga/titanium_mobile/commit/8f133bb49f66e2780338fae6125e945d13648eb3

      It needs iOS parity and it is up for discussion if that approach is usable or if it will create some performance problems

        Attachments

          Activity

            People

            • Assignee:
              shossain Shak Hossain (Inactive)
              Reporter:
              michael Michael Gangolf
            • Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Backbone Issue Sync

                • Backbone Issue Sync is enabled for your project, but we do not have any synchronization info for this issue.

                  Git Integration