ScrollHandler: Handle the scroll of scroll views

1.Introduction

ScrollHandler extension can be used to handle the scroll and properties of scroll views.

Latest Version: 1.3
Released: August 14,2020
Last Updated: July 6,2021

2.Blocks

3.Documentation

Events

  • On HTouch Down
    Event indicating a touch down on hsa.

    100%75%50%
  • On HTouch Up
    Event indicating a touch up on hsa.
    100%75%50%
  • On VScroll
    Event raised when a scroll happens in vsa.
    100%75%50%
    scrollY ~ int
  • On VTouch Down
    Event indicating a touch down on vsa.
    100%75%50%
  • On VTouch Up
    Event indicating a touch up on vsa.

Methods

  • CanHSAScrollHorizontally
    Returns whether HSA can scroll in left(-1) and right(1)
    direction: int
    Returns : boolean
  • CanVSAScrollVertically
    Returns whether VSA can scroll in up(-1) and down(1)
    direction: int
    Returns : boolean
  • HArrow Scroll
    Handle scrolling in response to a left or right arrow click.
    image
    direction ~ int
    Left = 17
    Right = 66
    Top = 33
    Bottom = 130
 
 
  • HFling
    Fling the hsa with given velocity.Positive numbers mean that the finger/cursor is moving right the screen, which means we want to scroll towards the left.
    image
    velocityX ~ int
  • HFull Scroll
    Handles scrolling in response to a “home/end” shortcut press. This method will scroll the view to the left or right and give the focus to the leftmost/rightmost component in the new visible area. If no component is a good candidate for focus, this scrollview reclaims the focus.
    image
    direction ~ int
  • HGet ScrollX
    Returns current scrollX position of hsa.0 if no view is registered.
    image
    Returns : int
  • HMax Scroll
    Returns max scroll position of hsa.0 if no view is registered.
    image
    Returns : int
  • HPage Scroll
    Handles scrolling in response to a ‘page up/down’ shortcut press. This method will scroll the view by one page up or down and give the focus to the topleft/right component in the new visible area. If no component is a good candidate for focus, this scrollview reclaims the focus.
    image
    direction ~ int
  • Register HSA
    Registers given horizonatal scroll arrangement for method execution
    image
    hsa ~ Horizontal Scroll Arrangement
  • Register VSA
    Registers given vertical scroll arrangement for method execution
    image
    vsa ~ Vertical Scroll Arrangement
  • Scroll By
    Scrolls to the given position by pixels.pX and pY are pixel value of scroll position.If hScrollView value is true then method will be executed for hsa.
    image
    pX ~ int
    pY ~ int
    hScrollView ~ boolean
  • Scroll To
    Set the scrolled position of your view.sX and yX are the scroll position of view.If hScrollView value is true then method will be executed for hsa.
    image
    sX ~ int
    sY ~ int
    hScrollView ~ boolean
  • Smooth Scroll By
    Smoothly scrolls by the given pixel position of view.If any speed is set then it will use that speed for scrolling.
    image
    pX ~ int
    pY ~ int
    hScrollView ~ boolean
  • Smooth Scroll To
    Smoothly scrolls to given position.If any speed is set then it will use that speed for scrolling.
    image
    pX ~ int
    pY ~ int
    hScrollView ~ boolean
  • ToggleScrolling

Toggles scrolling of specific scroll view

enable ~ boolean

hscrollView ~ boolean

  • Unregister HSA
    Unregisters previously registered hsa.After using extension will stop listening for that hsa.
    image
  • Unregister VSA
    Unregisters previously registered vsa.After using extension will stop listening for that vsa.
    image
  • VArrow Scroll
    Handle scrolling in response to an up or down arrow click.
    image
    direction ~ int
  • VFling
    Fling the vsa with given velocity.Positive numbers mean that the finger/cursor is moving down the screen, which means we want to scroll towards the top.
    image
    velocityY ~ int
  • VFull Scroll
    Handles scrolling in response to a ‘home/end’ shortcut press. This method will scroll the view to the top or bottom and give the focus to the topmost/bottommost component in the new visible area. If no component is a good candidate for focus, this scrollview reclaims the focus.
    image
    direction ~ int
  • VGet ScrollY
    Returns current scrollY position of vsa.0 if no view is registered.
    image
    Returns : int
  • VMax Scroll
    Returns max scroll position of vsa.0 if no view is registered.
    image
    Returns : int
  • VPage Scroll
    Handles scrolling in response to a ‘page up/down’ shortcut press. This method will scroll the view by one page up or down and give the focus to the topmost/bottommost component in the new visible area. If no component is a good candidate for focus, this scrollview reclaims the focus.
    image
    direction ~ int
  • Properties
  • HSet Edge Effect Color
    Sets the edge effect color for both left and right edge effects of hsa.
    image
    Accpets int
  • Left Edge Effect Color
    Get/Set left edge effect color of hsa.
    image
    image
    Accepts int
    Returns : int
  • Right Edge Effect Color
    Get/Set the right edge effect color of hsa.
    image
    image
    Accepts int
    Returns : int
  • HSmooth Scroll Speed
    Sets smooth scrolling speed for hsa.Setting it 0 will reset the speed.
    image
    Accepts int
  • VSet Edge Effect Color
    Sets the edge effect color for both top and bottom edge effects of vsa.
    image
    Accepts int
  • Top Edge Effect Color
    Get/Set the top edge effect color of vsa.
    image
  • Bottom Edge Effect Color
    Sets the bottom edge effect color.
    image
    Accepts int
  • VSmooth Scroll Speed
    Sets smooth scrolling speed for vsa.Setting it 0 will reset the speed.
    image

4.Downloads

4.Downloads

Bug Fixes

  • Fixed bug in `VMaxScroll` method

New blocks

Changes

  • Methods will work only when respective scroll view is registered

Bug Fixes

  • Minor bug fixes

New Blocks


 

Subscribe
Notify of
45 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Techno Vedang
1 year ago

Nice Extension vknow360

Soham Shah
1 year ago

Really helpful extension, expecting a background task extension from you

Smaug
1 year ago

Great

Salman Dev
1 year ago

I Really Like this Extension, Thank you vknow360

nivu_techy
1 year ago

super

saisab
1 year ago

best

Aj developer
1 year ago

is this open source sunny ?

Reply to  Aj developer
1 year ago

Why would you steal others works, if it’s not opensource.
Then it’s unethical to get it’s source.

Ankit
1 year ago

Max scroll gives always 0 value

Ankit
Reply to  vknow360
1 year ago

No check this. you have to use scrollView but you are using hscrollView also in MaxScrool of vsa .

Untitled.png
Ankit
Reply to  vknow360
1 year ago

You can call it reverse engineering not decompiling which sounds better

Ankit
Reply to  vknow360
1 year ago

I have fixed myself please update and make it bug free for others.

Untitled.png
1 year ago

I’ve reloaded the website several times and they don’t load the examples in the guide if you could fix it please!

Error de Crga IMG.png
Reply to  Franklin Ortiz
1 year ago

Check if the image you are saving exists or if the server is loading 

Error de Carga IMG 2.png
Reply to  vknow360
11 months ago

Joo
Okay, Thanks

Last edited 11 months ago by Franklin Ortiz
Suman Jha
1 year ago

Hello bro vmax scroll not working please fix

Suman Jha
Reply to  vknow360
1 year ago

Thankyou bro i downloaded again and it works but max scroll value is 345 more than actual value

Suman Jha
Reply to  vknow360
11 months ago

Yes but please test again when you reach bottom also max value is 345 more

Suman Jha
Reply to  vknow360
11 months ago

But collintree’s give same value when scroll to bottom ,
But in this scrolling bottom postion of vsa not equals to max position

Ekansh Pandit
10 months ago

really nice and cool extension vknow360❤

AveNooN
9 months ago

Hello,
Thank you for the extension, it does a really good work. Could u add an option to disable scroll ability for an user?

AveNooN
Reply to  vknow360
8 months ago

It was very fast. Thank you very much!

AveNooN
8 months ago

Are the download links up to date? It’s only possible to download ver 1.1.

AveNooN
Reply to  vknow360
8 months ago

Thank you! It’s a great loss for kodular community that u left. Your extensions are powerful.

alex8
7 months ago

Hi, Touch Down and Touch UP not work
Example paste Notifer.

From ColinTree work this..

alex8
Reply to  vknow360
7 months ago

on email send

alex8
Reply to  vknow360
7 months ago

Please Fix, TouchDown

alex8
Reply to  vknow360
7 months ago

scrolling is enabled) only in 10% touched work

blocks - 2021-03-18T111322.095.png