Android Google Keep Style Reording of Views - android

I have an app where I programmatically add several views to a linear layout. I would like to allow the user to reorder these views but I am having a hard time figuring out how to do that. I would like to emulate the functionality that google keep uses to reorder items in its checklists. If someone could please point me at a working example that would be awesome.
Thanks,
Nathan

Related

Android Layout for Google Maps - Choose starting point Screen

Please have a look at this screenshot from Google Maps for Android. What layout is Google using for this particular screen?
Using multiple ListView controls here would be an overkill in terms of performance (or so I think). Also, because one can scroll on this screen, I don't think Google is using ListView controls here as ListView controls don't work along with ScrollView controls. Is Google using multiple instances of the all new CardView control on top of a ScrollView control here?
Can someone help with the best possible layout (from a performance perspective) for rendering this particular screen? I need to make sure my app supports lower end Android handsets so rendering performance is the number one priority but nothing like achieving it with clean, simple & reusable code + layouts (if possible in this scenario).
Thanks in advance!

How to position controls in Android?

I am trying to create the UI but I'm having a lot of difficulty just placing controls where I want them to appear on the main screen. For example I want to add a few ImageButtons but they just seem to snap to one corner and I can't seem to add more than one.
Do I need to use a layout or something? Can't I just drag and drop and move the controls around where I want?
I suggest you start by reading a few of the developer tools out there. http://developer.android.com/guide/topics/ui/declaring-layout.html This guide will help you get your feet wet with how to properly layout a screen in Android. There are also a bunch of other great guides on there to help with other aspects of the UI. Even though you use C# in Xamarin Studio, the UI portion is native Android so the guides should still be relevant.
try to use relative layout , its kind of easy for visual studio developer and others too.
details here : http://developer.android.com/guide/topics/ui/layout/relative.html

General android layout questions

I should begin by saying that I'm brand new to android development, although I have a good understanding of the fundamentals of java. That being said, I usually learn best by doing, so I'm writing an app for a campus magazine I work for and trying to learn through the process of making it.
At the top of the screen is a bar with two spinners labeled "issues" and "sections," which allow the user to filter the articles shown to only those in the respective issue / section. The rest of the screen is taken up by what I will describe as a vertically-oriented gallery, which shows the headline for each story underneath an image associated with it. The user can then "flip" through the stories in the magazine by scrolling through the "gallery." Selecting one of the stories will open the full story up in ViewPager.
I have two main questions at this point:
1) Initially, I planned to place the "issues" and "sections" spinners in the ActionBar. However, as I understand it, ActionBars are not displayed to users using Android 2.x. Given that these elements are critical to navigating the app, and that a majority of android users are still using 2.x, this seems unacceptable. As a result, I'm using an ActionBar-less theme and essentially drawing my own action bar via a linear layout on top of my main activity. Am I correct in my understanding that ActionBars do not display on Android 2.x devices? If so, am I correct in including my "tool bar" as a part of the main activity, or is there a better way to implement it? (Perhaps as a fragment? I don't really understand how those fit in yet...).
2) I am aware that the gallery widget is deprecated, so obviously I'm not going to use it. What alternative widgets would best achieve the same visual goal of having the user "flip" through the stories in the magazine by scrolling through the widget? Is there a way to animate a ListView to achieve this goal?
Again, any help - particularly which helps me to understand the wider issues involved here - will be greatly appreciated.
Thanks in advance.
You can use ActionBarSherlock - it is compatible down to Android v 1.6.
ViewPager might help you

Horizontal Paging/Swipe views

I have a quiz app which loads questions into a textview, answers in radiobuttons which is wrapped in a scrollview. Currently I'm using next and previous buttons which work but I'd rather use swiping to control that. How do I implement this so that I can get animations of the page being dragged kind of like the tabs in the google play music app.
I've googled around and seen viewpager used a lot, but I don't know if that's right for what I want to do. I've also considered using viewflipper but again I don't know if that's right. And I wouldn't know how to use either of those in an animated drag fashion.
There's the possibility of hundreds of questions one after another which might be a factor.
Thank you!
How do I implement this so that I can get animations of the page being dragged kind of like the tabs in the google play music app.
Use a ViewPager.
There's the possibility of hundreds of questions one after another which might be a factor.
Rewrite your app to not ask the user "hundreds of questions one after another", then. Having a single quiz that long would be annoying in any medium, IMHO.
From a coding standpoint, depending upon what else is going on in your app, memory might become an issue using ViewPager, ViewFlipper, or pretty much anything other than a single set of radio buttons whose captions you change as the user moves from question to question.

android swipe to delete list row

so i've done some searching but haven't found a good answer. anyone who's familiar with android 4.0 knows the fancy swipe to remove running apps. i'm trying to implement this into a dynamic list.
when i say dynamic, it's a list being built with a base adapter and holder's.
i'm wondering if anyone has a good example of how to implement this swipe feature into a dynamic list. i want it to have the fancy animation and everything of the list collapsing back together after an element is removed. but, for now, i'm looking for a good starting point on how to properly implement this.
any and all help is always appreciated. thanks all!
SwipeListView is an excellent ListView extension that does this. A demo application is also available on Google Play here: https://play.google.com/store/apps/details?id=com.fortysevendeg.android.swipelistview

Categories

Resources