ThePuiu Active Member Licensed User Longtime User Sep 20, 2019 #1 I saw in a commercial application (Glovo) a menu (in fact it is just a button) that I like very much and I would like to replicate it. The button is actually an area at the bottom of the screen where you can perform a slide operation. After the drawn area reaches a certain size (1/3 of the screen height) it becomes another page. To better explain I attached 2 images: one in which the menu is in the normal state and the other during the wipe operation. Can anyone help me with an idea how I could do this? Attachments 1.JPG 16.7 KB · Views: 551 2.JPG 16.7 KB · Views: 568
I saw in a commercial application (Glovo) a menu (in fact it is just a button) that I like very much and I would like to replicate it. The button is actually an area at the bottom of the screen where you can perform a slide operation. After the drawn area reaches a certain size (1/3 of the screen height) it becomes another page. To better explain I attached 2 images: one in which the menu is in the normal state and the other during the wipe operation. Can anyone help me with an idea how I could do this?
Brandsum Well-Known Member Licensed User Sep 20, 2019 #2 Create a panel with an image view at the top then place another panel below the imageview inside the first panel. Now set the background color of first panel to transparent and child panel to white. Set an image like the example arc to the imageview Set child panel height to 100%y and main panel height to 100%y + imageview height. Set main panel top to 100%y - imageview height Write a touch event sub of the main panel and write your code to detect action down and action move on action move set the panel top as you drag upward. and check if the top is 1/3 of the screen set top of the main panel to 0%y - imageview height On touch up if the top is less than 1/3 of the screen set main panel height back to 100%y - imageview height Upvote 0
Create a panel with an image view at the top then place another panel below the imageview inside the first panel. Now set the background color of first panel to transparent and child panel to white. Set an image like the example arc to the imageview Set child panel height to 100%y and main panel height to 100%y + imageview height. Set main panel top to 100%y - imageview height Write a touch event sub of the main panel and write your code to detect action down and action move on action move set the panel top as you drag upward. and check if the top is 1/3 of the screen set top of the main panel to 0%y - imageview height On touch up if the top is less than 1/3 of the screen set main panel height back to 100%y - imageview height
ThePuiu Active Member Licensed User Longtime User Sep 20, 2019 #3 ty Brandsum, I'll give a try! Upvote 0
asales Expert Licensed User Longtime User Sep 21, 2019 #4 I tried to make this some time ago, without success: https://www.b4x.com/android/forum/t...s-effect-open-and-close-panel-manually.98609/ If you get success to made this, please share the code. Upvote 0
I tried to make this some time ago, without success: https://www.b4x.com/android/forum/t...s-effect-open-and-close-panel-manually.98609/ If you get success to made this, please share the code.
Erel B4X founder Staff member Licensed User Longtime User Sep 22, 2019 #5 Check B4XDrawer code. Shouldn't be too complicated to modify it to slide from the bottom. Upvote 0
asales Expert Licensed User Longtime User Sep 27, 2019 #6 Here: https://www.b4x.com/android/forum/threads/class-slidingsidebar.21533/ Upvote 0