Disable scroll view action


Last Updated:

  1. Kishore

    Kishore Guest This Topic's Starter

    In my application i've a line for increasing the width of a widget(by dragging the line to right/left) and i've the scroll view enabled in the same activity.
    I need to disable the scroll view action when the user touches the line and when user releases, it should be enabled.
    The scroll view should be in visible state but the action of the scroll view should be disabled.
    Please help me in solving this problem.
    I've tried with these but none of them is working.
    scroll.setEnabled(false);
    scroll.setFocusable(false);
    scroll.setHorizontalScrollBarEnabled(false);
    scroll.setVerticalScrollBarEnabled(false);

    Thanks in advance.
     

    Advertisement
  2. MikeMcG

    MikeMcG Well-Known Member

    Joined:
    Jan 16, 2010
    Messages:
    114
    Likes Received:
    3
    I win.
     
  3. OfTheDamned

    OfTheDamned The Friendly Undead VIP Member

    Joined:
    Oct 29, 2009
    Messages:
    9,691
    Likes Received:
    8,364
    I think this could be the best forum game EVER!
     
  4. Frisco

    Frisco =Luceat Lux Vestra= VIP Member

    Joined:
    Jan 19, 2010
    Messages:
    22,479
    Likes Received:
    9,223
    scroll.setEnabled(false);
    scroll.setFocusable(true);
    scroll.setHorizontalScrollBarEnabled(maybe);
    scroll.setVerticalScrollBarEnabled(wtf?);
     
  5. eyebeam

    eyebeam Well-Known Member

    Joined:
    Nov 6, 2009
    Messages:
    5,418
    Likes Received:
    3,091
    The Bourne Identity Crisis

    (Say! This is fun.)
     
  6. ElasticNinja

    ElasticNinja Well-Known Member

    Joined:
    Aug 29, 2010
    Messages:
    4,488
    Likes Received:
    472
    haha this is great
    stickyyyyyyy!!!!!!!!!!11111!!!!!
     
  7. eyebeam

    eyebeam Well-Known Member

    Joined:
    Nov 6, 2009
    Messages:
    5,418
    Likes Received:
    3,091
    Banned for requesting an unnecessary sticky. Loser! :p
     
  8. Frisco

    Frisco =Luceat Lux Vestra= VIP Member

    Joined:
    Jan 19, 2010
    Messages:
    22,479
    Likes Received:
    9,223
    scroll.setEnabled(falafel);
    scroll.setFocusable(glue);
    scroll.setHorizontalScrollBarEnabled(anchoviepaste);
    scroll.setVerticalScrollBarEnabled(snailmail);
     
  9. ElasticNinja

    ElasticNinja Well-Known Member

    Joined:
    Aug 29, 2010
    Messages:
    4,488
    Likes Received:
    472
    scroll.setHorizontalScrollBarDisabled(true);

    Was it THAT hard?
    WiiN
     

Share This Page

Loading...