Creating a menu like the new YouTube application - android

Any ideas how we can make a menu like the one that Google has implemented in their YouTube app. I've read this, but that solution differs from the behaviour of the YouTube application. Does anyone know a real way to go about this?
I'm talking about this:

I believe that they use a HorizontalScroll in a RelativeLayout.
Image that the menu is always there to the left. You make that first.
Then you place a HorizontalScrollView on top of that and then put your main content in that.
Set your horizontal scrolling properties to only scroll a certain max. Then you wire up your menu button to slide your horizontalscrollview to the max you set and that should be it.
You can always check the source to the People Application in ICS. They do something very similar.

Related

android ui design for an app help needed

One activity in my app looks like below picture. In the below picture ,can any one suggest that best way to implement view,
view in my app
and when i click one of the options(filters in app) available on activity,
the view will be extended like below
view after one of the option selected
For this, i want to use a horizontal linear layout for below options bar,
when one of the options clicked, i wanna use slide up functionality and views show and hide functionalities.
can any one suggest better design for this . thanks.
I think for most apps, all toolbars should stay in the same place throughout the execution of the app. When the toolbar item ("Veg & Non Veg") is clicked, the filter should appear above the toolbar instead of below it. You can still use the slide up function, just have the toolbar layout displayed above (higher z-index) the filter linear layout.
You should also standardize the sizes for the distances/times to each location, personally I think the first one looks better.
Other than that, I think your UI looks pretty good!

Sliding drawer looks like semi circle

Android provides the SlidingDrawer by default looks like below image -
Image http://www.gru.at/android/wp-content/uploads/2010/09/s_open.png
Can we customize this SlidingDrawer looks like semi-circle type with buttons included. For, example take a look at below image -
Anyone done the SlidingDrawer like above one. I've googled it. Didn't get any nice solution for this. Anyone has idea/example blog for this?
So make sure you have Gimp and 9-Patch at the ready for a lot of trial and error...
Then what you wanna do is...
Add suitable layout to hold buttons where the current ImageView Handle is, like Horizontal LinearLayout or RelativeLayout
Cut the id of the current ImageView Handle and add it to this new Layout you just added
add your buttons to the LinearLayout/RelativeLayout (you can test it now, the buttons and the handle should all slide open at the same time)
Now add Button listeners for each of the buttons
Set the SlidingDrawer to android:allowSingleTap = "false" (tit for tat, you cant have the single tap option anymore, just the slide)
Use a ButtonSelector.xml to have different layouts for buttons be pressed or not pressed.
This is the hard part. Edit the drawables for the buttons, and handle so that they will fit together nicely if the screen is huge, small, landscape, portrait. I recommend using 9-Patch in conjunction with Gimp.
Pat yourself on the back because you now have a totally sweet custom sliding drawer.
Make sure you post pictures and state any problems or issues you ran into as I have never fully implemented this, but I did get to step 6 to make sure it was possible.
Last but not least, Good Luck...
Thanks for RelativeLayout and FrameLayout These layouts makes my requirement comportable with what i need. I've done like below steps -
First, i've splitted the full image into three pieces. And, merge these images with FrameLayout And, gave onclickListner to my center of image(Because, it was contain that arrow marks up/down)
And, i've used the Animation for just to open that View as SlidingDrawer
These steps helps me lot.

Android creating a Spotify like slider menu

I am making an app that should implement a slider menu like the one in Spotify (where you slide the triangle in the middle to show the current playing song). The problem is I can't seem to figure out a decent method of doing this. I tried it with a Facebook like menu I found here.
However that just provides me with 2 linear layouts which are placed next to each other and are basically stretched or unstretched when expanding the menu. This gives some layout issues when expanding/collapsing (all items are placed below each other in the linearlayout when expanding and are quietly moved into the right place when collapsing the menu again).
In Spotify on the other hand it seems as if the layouts are on top of each other when the menu is expanded. This seems like a much cleaner way. However I have no idea on how to tackle this and Google doesn't really provide a lot of answers. Physically sliding the menu up isn't necessary, just getting the layouts on top of each other with some sliding animation on clicking the menu button.
Sorry for the long post, it seemed necessary to specify the question.
You dont need to re-invent a view or do anything fancy to get this functionality. Its called SlidingDrawer and is already available in the framework. Read this and this or watch this video.

Scrollable menu bar with left/right arrows

I am looking to create a navigation or menu bar similar to the functionality of the one at the top of the Fox News app. I started to code this myself using a Gallery but I'm not sure how to hide the left and right arrows when they are not needed. I was also wandering if you would have to use images for the menu items or if you could just use TextView or buttons so I could change the text without having to modify an image. I have seen this type of navigation on several apps and I tried all types of searches trying to find code examples but I must not be using the correct name for this type of scrollable menu because I couldn't find anything. If anyone has an example or provide a link to an article I would greatly appreciate it.
Look into HorizontalScrollView. It is a Layout that will handle the smooth scrolling and is likely to be much less of a hassle to work with than Gallery for this operation (I just added one for a similar reason).
To handle the left/right, look into setOnTouchListener. I'm not sure if you can get the current scroll position without making a new child class of HorizontalScrollView to access protected methods. There may be other ways, however - I didn't need to add buttons so I didn't investigate.

How to make an app similar to Pulse News Reader for Android

http://androidapt.wordpress.com/2010/11/19/pulse-news-reader-an-android-app-that-kicks-rss/
Gallery inside ListView it's clear, but:
What is the technology that allows you to show a ScrollView under opening ListView?
How to make gallery and top bar move down by touching screen inside opened Scrollview?
I don't need the direct code, just show me where to lurk for this info.
I though that it uses SlideDrawer, but it reacts only on touches, then i think it is something similar to SlidingPanel
It is a gallery with left margin adjusted.
Accept Mark's answer as right way to made it.
That is not a Gallery widget, AFAICT. My guess is a LinearLayout in a HorizontalScrollView. I am impressed that it works -- I wonder how much headache was involved. In terms of your questions, I have no idea what you are talking about and how they relate to the video
Yes Mark, We have reengineered the pulse app, It is the gallery with its left margin adjusted.
and the center locking on gallery item click is also overridden.

Categories

Resources