Help get this topic noticed by sharing it on Twitter, Facebook, or email.

My workaround for sliding open a drawer, then closing it after hitting a button in the drawer, and repeat...

Using variables I have figured out no way to open a drawer the normal way, and then close it when choosing a command. I want this because find it easy to slide open, but difficult and redundant to slide shut after I use a command. Using variables, the only way is to fix the drawer and open/close it with buttons. I don't have room for a drawer open/close buttons, and I had no luck trying to use swipe to set the variable to open either.

My method has one main limitation, you must disable swiping between pages in the panel you want to do this with.

Create your drawer and page, and duplicate both into a 2nd panel. (This is needed because going to another panel is required to reset an unpinned drawer to closed.)

Then set all the commands in your panel1 drawer to point to the page in panel2. And vise versa. Set the drawers in both to initially closed, unpinned. Works like a charm. (You only need to duplicate the specific page and drawer, you can leave any other pages in panel1 alone, assuming they are accessed by buttons and not by swiping.)

Now when I select Living Room TV, I get the TV remote, and I can slide open the drawer for channels. I select a channel, and the drawer appears to automatically close. (It's in fact going to the other panel, but it looks the part)

I can then slide open the drawer again, hit a channel, repeat.
1 person likes
this idea
+1
Reply
  • Why not simply use a variable for the drawer width and set that variable appropriately.

    I use that to open a drawer to different widths and it works perfectly. The redraw is as fast as you'd ever need.

    Not sure why that wouldn't work for what you're trying to do and avoids the need for any duplication of pages etc.
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • Sure but then how do you re-open your drawer? You can't swipe it open because the variable was set to 0% when you last hit a button to "close" it.

    You'd need a button to change that variable back to 80% or whatever get it open again. I don't want or have room for such a button.

    Also If I change my mind and don't want to pick a channel, I can swipe the drawer shut as well. To do this with variables this would require another button.

    Correct me if I'm wrong.
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • Good point.

    We need 2 additional commands:-

    - Open drawer

    - Close drawer

    Then you could do it.

    For different reasons we also need to be able to assign drawers by variable, so you could programmatically change which drawer should be used on a page. I have proposed this elsewhere, but thought I'd mention it again to try and get the message home to the iRule team. :-)
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • I have found that swiping does not work that well for me. Touching the screen just in the right spot has been a pain. I also don't like seeing the little tab. So I have gone to using buttons to open and close drawer.
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • It seems to have to do with how crowded the screen is. If there's no empty space near the drawer line it's hard to close. Irule thinks you're hitting some other button, or both, and gets confused. Opening works great though, even with a protective case on my phone.
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • Drawer operation does leave much to be desired. Opening is usually OK, but sometimes it can misinterpret the swipe and simply slides to the next page instead. Closing can be more problematic if as you say there isn't much space to place your finger on to swipe it closed and if you're not very careful you end up pushing a button at the same time, or instead.

    But there can also be other more fundamental issues with the operation. Sometimes I simply cannot open a drawer. However much I swipe from the side of the screen, the drawer simply will NOT open and it simply slides to the next page instead (if there is one). Closing can similarly be a problem. It's as if the entire drawer open/close detection has been disabled. I have to keep trying to open and close and going to different pages entirely, maybe a different panel and then suddenly it works again and continues to function correctly for days. But it WILL happen again.

    It's a bit like when gestures briefly stop working that I mentioned elsewhere. It's as if for a while iRule has 'forgotten' how drawers and gestures should work and then after a few minutes it suddenly remembers again. I don't know if these problems are related, but it is VERY annoying when it happens.
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • Right after using a drawer, it's easy to grab again, but yeah, it seems like it almost becomes background to other objects at times. Like in a windows program when an object loses it focus.


    But let's get on track, this drawer work around is working perfectly for me even on my slow phone. You should build a test page and give it a try. There's always a way. Heck, I'm even faking feedback driven button states. I don't think irule does that either
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • This reply was removed on 2014-05-06.
    see the change log
  • Tim (Official Rep) May 13, 2014 15:10
    If you use variables to Open & Close the drawer. What works best is to make either a button with an image or blank button along the entire edge of the screen where you would like your drawer to be. You can make your own custom looking drawer handles too. Then when they press the button it opens the drawer, and on the drawer is the close button that will close the drawer.
    What I have done in systems is to automatically close the drawer after a given time. For example on my activity selection drawer I have a macro that opens the drawer delays for 3 seconds and then closes the drawer. If I have not made an activity selection in 3 seconds I simply press the button again.

    Hope this info helps.

    Thanks,
    Tim
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • hi guys just leave you drawer unpined and at 0% and use a variable to open it on drawer select button, set you variable to say 100%, on that make any button a variable return button but you will also be able to close the drawer by sliding it closed.

    give it a go it works fine,

    barry
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • An unpinned closed drawer set to 0% or 100% is still closed.

    I'll check anyways but that idea sounds like a waste of time, maybe it works on the first try because the page loads with drawer initially open to 0%, but I don't see any way a button is going to open a drawer once it is swiped closed.
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • I use a variable for opening my favorites drawer that is unpinned. It's set to 0% and the Fav button slides it to 25% or so. Any selection of a channel sets the DirecTV channel and resets the drawer to 0%. I've even tested and swiping still works, I thought that would be disabled but I'm able to do it.
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • Ok I just made a test panel to check what three of you said.

    Swiping open does NOT work after you've used a button to close the drawer (setting width variable to zero).

    Try it on yours. Swiping does nothing one the drawer width variable is zero. Obviously, how could it?
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • Alright, tested it last night and I could not duplicate what I'd seen before, or thought I'd seen. At any rate, I open the drawer with a button that says Favs and close it when I hit a button. I like the delay action to close it after 3-5 sec if I don't hit anything.
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • There is a bug that if you open a drawer with a variable on iOS then you have to close the drawer with a variable. I have seen this before.

    Another option is to use Gestures to set the variable percentage. The only issue with this is that you could only open one drawer with a gesture.

    Scott
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned

  • This is on Android. I had no luck using gestures to set the variable, but that'd give you options also if it wasn't for the bug you mentioned.

    Anyhow, back to my post #1. It appears to be the only way on android and iOS to have a drawer that is fully functional with buttons and swiping. The trick is that by going to a different panel, the drawer resets to its initial position.

    A lot of people complained about limitations of drawers, so this is a solution. I posted it as a tip, not a Q&A.
  • (some HTML allowed)
    How does this make you feel?
    Add Image
    I'm

    e.g. sad, anxious, confused, frustrated happy, confident, thankful, excited kidding, amused, unsure, silly indifferent, undecided, unconcerned