Handling for spinner on orientation change - android - android-spinner

I have spinner in my activity. When spinner is clicked, drop-down is shown.
Now, Change orientation. That drop-down is not maintained.
Is there any way to shown drop-down again on orientation change?
Thanks in advance.

Your question is a bit unclear to me.
Please try adding this to your <activity> in your android manifest:
android:configChanges="orientation|screenSize|keyboardHidden"
See this for details
(Some might say this is not the right way to do it, but you can use this until you find a better solution)

Related

In Android Studio How To Remove Guidelines?

I'm learning Android Studio, so I clicked a few buttons to add vertical and horizontal guidelines, but how to roll back ? In the following image you can see how they look, but I can't figure out how to not show the guidelines ?
I figured it out, select it, make sure it turns blue, then hit "Delete" key to get rid of it.
Select the guidelines or just go into the COMPONENT TREE window below the Palettes and delete the guidelines you want.

Android - Set Default Spinner Themes

I'm new to Android development.
I'm using drag and drop to pull down a default spinner onto my layout.
However, the default is not the one I see everyone using with the triangle on the bottom right.
An example of what I see is:
http://www.mkyong.com/wp-content/uploads/2011/11/android-spinner-demo1.png
Whereas what I'm looking to achieve is this:
http://i.stack.imgur.com/X82Ld.png
Is it a styling issue?
Apologies for ripping off other people's images, I don't have enough rep for uploading my own images.
Thanks so much!
I've Solved my issue by setting the Theme of the application/activity to Holo.Light. Hope this helps other people in the process.

xamarin.ios (monotouch) How to have a help UIImageView appear ABOVE the current view

I am hoping someone can help with this issue that I am having using xamarin.ios. I am trying to present a UIImageView on top of the current view once a button is touched. To illustrate what I mean, see the two screenshots from an app that does exactly what I want. The first shows the 'i' button next to Printers label on the navigationbar, that when touched the second screen as shown in the second screenshot appears.
Any help much appreciated.
I think what you want is a "popover".
Xamarin has a recipe for popovers on: http://docs.xamarin.com/recipes/ios/standard_controls/popovers/display_a_loading_message

C# ListView Image/Icon margin/padding

Is it possible to reproduce what is on the picture below in ListView, padding/margin icon to the right.
http://img801.imageshack.us/img801/4043/listview.png
My first question here, so I couldnt post the picture here.
Basically I need to move the ListView icon more right, I am reproducing file/directory browser, so the fails that are in a directory need to be below them and slighty right like in the picture, I have everything else figured out.
You should be using a TreeView control:
http://msdn.microsoft.com/en-us/library/1dtsdfkx.aspx
But if you insist on hacking a ListView to render this way, you'll simply have to take over drawing each row yourself. You can do so using the OwnerDraw property, though be warned that there's a lot of corner cases here so you should do a lot of reading to see what people have had to deal with when implementing this:
http://msdn.microsoft.com/en-us/library/system.windows.forms.listview.ownerdraw.aspx

android - UI like sliding down notification bar

I want to develop a panel with animation same as notification panel. I mean to say the notification panel is a cool control where you grab and slide down the notification bar and see all the notifications.
Actually, I am having 2 UI , 1st should be shown with Button at top, when user click on that button, the 2nd UI with listview items should be slide down same as notification panel and again when user click or drag the 2nd UI at the top side, then 2nd UI should be become invisible. I hope i made clear my question.
From Christian's answer, I am trying to use a sliding drawer that will display a
list of options. I need this to expand over the current ListView on the page.
So if anybody know how to implement such layout or UI with sliding down animation then please share it.
Please suggest how to build with such control or layout? any ideas or suggestions
Thanx
Have you tried the SlidingDrawer widget?
Paresh I found a solution in this post about sliding drawers.
android misc widgets has it implemented , though it still has some flaws but it will definitely prove helpful.
Though in the same SO post CommonsWare has quoted :
...
You similarly cannot make a
SlidingDrawer that descends from the
top.
Good Luck.
You can use SlidingTray from: http://aniqroid.sileria.com to make this happen
http://aniqroid.sileria.com/doc/api/com/sileria/android/view/SlidingTray.html
Alternatively you can also use a custom PopupWindow class which is part of Android API.

Resources