Android : UI Design Suggestions For Display And Switching Between Multiple Layouts

Jun 26, 2010

I'm trying to create an app that offers the user 3 different kinds of layouts. The only common portion for all 3 would be the TextView (located at the top) that would display information specific to the currently displayed layout and 3 buttons to select the required layouts.

Is there some way we can create this UI in XML to keep only one constant part(the upper TextView) and dynamically display any one of the 3 layouts below it?
Would it be better to create separate XML's for each of the layouts (each including the upper TextView in them)?
OR would doing this via code be better?

Fast switching between the 3 layouts is important. TIA

[EDIT 1]
Actually they are 3 different layouts, with several "child" layouts and views within each of them. Could a ViewFlipper be used for switching between these? I was thinking that a ViewFlipper was only for switching between View elements?

I do have them in individual XML's right now but am looking for some way to load and unload them fast. Not sure how to do the hiding thing, will try reading up on that. [/EDIT 1]

Android : UI design suggestions for Display and Switching between Multiple Layouts


Android :: Multiple Activites That Share 75% Of Layout - Layouts Within Layouts?

Sep 6, 2010

I'm creating a game where there's a screen that, for the most part, is shared by four different activites - but a key portion of the screen will be completely different, depending upon which activity is active. Basically, on the left will be an image of the player and along the bottom there will be a row of buttons (let's say for Armour, Weapons, Magic, Skills). This leaves the top-right portion, which will need to dynamically change to represent the button pressed. (So, one moment the top-right portion is the armour selection activity, and the next it's the weapon selection activity, and so on.)

Is this possible? Can I have a layout within a layout and dynamically point the nested layout at a (nested) layout.xml of my choosing? Or, am I looking at just duplicating most of the layout four times (for the four different activities?) Or, am I going to be looking at linking the four activities to a (the top-right) view component, and then having to dynamically construct all of *that* view's child views based on the currently active activity? Well, that's about as much sense as I can make this question make.

View 4 Replies View Related

Android :: Should App's With Multiple Layouts Have Multiple Activities To Handle Each

Jul 1, 2010

I'm planning to develop and app that presents the users with several different screens (of different information).
Was wondering what would be the best way to implement this?

Is it better to have separate XML layouts and an activity to display and allow the user to interact with each screen of data?

OR would handling all of these in the same activity be more efficient (and dynamically load / unload each layout)?

View 2 Replies View Related

Android :: Changing Screens - Switching Between Layouts

Jun 1, 2010

I am trying to create an app for android 1.5 which would be organized around 4-5 'screen's that will be changing in a given order.

So I start ma app with the first screen, which it's background and a button. When I click on the button a new screen appears with a different background and different options which lead to next screens. Sth. that is usually seen in games. The problem is that I need to pass a lot of data between those 'screens' like and array with recorded sound. My idea was to create a separate xml layout file for each screen and change the context in the activity class so ie:

CODE:............

A simple test app for 3 screens works this way but my I don't really like this approach and it seems to be inappropriate.

Is this the correct way of organizing such an app in android or should I take another approach - if I should, please give a more detailed advice on how to do this.

View 5 Replies View Related

Android : Using Multiple Layouts For Different Screens

Dec 3, 2009

I am getting my feet wet developing software for the Android. My test app will have multiple screens (each having their own layout file). The main screen will direct the user to view the other screens based on user input. I kinda see this as layers of cake. Bottom layer being main; then you add and remove layers as the user makes UI inputs. The crazy trouble is how to view a second layer. I have created a second class which has its own onCreate method, which has its on setContentView(R.layout.secondlayer).

This class extends Activity much like my primary class does. I have a click event on a button within the main layout. This button will instantiate the new second layer class which I have done. And that is where my story endsI don't know what to do from this point. This is surely a newbie question If someone has an example that would be extremely helpful teach me to fish and I will be on my way.

View 6 Replies View Related

Android :: Multiple Screen Sizes - Layouts

Dec 16, 2009

I have created layout-large and testing against android 2.0.1 WVGA. however, its picking layout-normal. Can anybody suggest me what I am doing wrong. Even though, I have 3 layouts ( layout-normal, layout-large, layout- small), Its always picking layout-normal. why its so.

I added properties to manifest file

CODE:.............

View 2 Replies View Related

Android :: Use Motion Events With Multiple Layouts

Aug 22, 2009

I'm beginning in android development, and I've stumbled upon a problem. My application has different layouts stored in xml files, and I use motion events such as onFling or onSingleTapup. These motion events seem to apply whatever layout i'm in. My problem is simply identifying which layout i'm currently using so I can define the appropriate action. I guess what i'm trying to do is a bit like this:

@Override public boolean onSingleTapUp(MotionEvent e) { if(using main layout) { //do this } else if (using settings layout) { // do that } return false;

}

View 4 Replies View Related

Android : ListViews With Multiple Item Layouts

Aug 5, 2010

I have a ListView on my ListActivity and I'd like the rows of the ListView to be 1 of 3 different layouts. The first item in my list is always going to use layout A, the second item in my list is always going to use layout B, and all subsequent items are going to use layout C.

Here is my getView function: Code...

R.id.label1 and R.id.label2 are TextViews on R.layout.layout_A. However, txtLabel1 and txtLabel2 are null after trying to set them. Why?

I stepped through this code in the debugger and it inflated the correct layout (R.layout.layout_A) and fell into the correct case below to set the R.id.label1 and R.id.label2 text. Also, if there is a better way to do this, please let me know.

View 1 Replies View Related

Android : Using Multiple Layouts With Include Tag / Create A Title Bar

Oct 19, 2010

I'm trying to create a title bar that is the same throughout my application and have been creating layouts like this for each of my activities:

main.xml:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent" android:layout_height="fill_parent">
<include layout="@layout/title_bar_layout" android:id="@+id/title_bar_layout" />
<include layout="@layout/main_body" android:id="@+id/main_body" />
</LinearLayout>

main_body.xml:

<?xml version="1.0" encoding="utf-8"?>
<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/main_table" android:layout_width="fill_parent"
android:layout_height="fill_parent" android:stretchColumns="1"
android:orientation="vertical">
</TableLayout> Code...

View 1 Replies View Related

Android :: How To Design Layouts In Android

Feb 5, 2010

I dont have idea of layouts,where to refer? basic of layout desigining,and how to make the form scrollable ,such things etc

View 1 Replies View Related

Android : Add Couple Of Command Buttons For Creating Multiple Layouts

Mar 25, 2009

I am new to android and trying to create a customized list. Every item in the list has TextView and one Ratingbar. I now want add a couple of command buttons at the end of the list (like BACK, HOME, , NEXT). When I add these extra views to the layout xml file then they get added along with every item in the list. I think there should be another layout defined for the buttons to be displayed separate from the list. Anyone has an idea on how to do this?

View 2 Replies View Related

Android : Sharing Common View Layouts And Resources Across Multiple Applications

Jun 2, 2009

I am working on developing several individual android applications. We had created common UI Layout View XMLs, classes and resources. I would like to share these common layout xml, classes and resources across all of my android applications. I dont want to duplicate them in my applications. Is there any easy way to do this?

View 5 Replies View Related

General :: Multiple Home Screen Layouts?

Mar 28, 2013

Can you have Multiple Home screen Layouts? Like Like swapping themes but layouts. I designed a bunch of custom wallpapers with corresponding Custom widgets. I'd love a way to just swap between different ones with out having to re-set up all the widgets.

View 2 Replies View Related

Android :: App Design For Multiple Data Connections

Oct 18, 2010

I am working on developing an application that requires me to establish multiple client-server based connections. Connection can be of two types where the Android device can be a server or a client. I can have up to 6 - 8 connections. Once the connections are set-up they need to be running in the background and are not typically affected by UI actions.Since each connection can be blocking, I am wondering what is a good away to design this app. Should I have two services for handling the server and client connections? Each service could have a "connection manager" that can spawn new threads when necessary. Or does creating two services even help? I presume spawning new processed would not be good as they will be expensive. Is this correct? I would appreciate any suggestions. Also, if this use case is not typical please let me know if you need more information to make any recommendation.

View 2 Replies View Related

Android :: Make ScrollView With A RelativeLayout With Multiple Child Layouts Fill The Screen

Aug 20, 2010

I have a layout that has just a ScrollView visible. It has a relative layout as its child. This layout has several other layouts (mainly text views) as its children. When the text is not big enough, the scroll view does not expand itself to fit the whole screen. Instead, it shows a gap at the bottom where the background shows. I tried setting fillViewPort=true on the ScrollView, but that just made the first child layout (RL1) to fill the screen.

CODE:....................

View 1 Replies View Related

Android : Multiple Handlers Design In An Activity Failed

May 14, 2010

This question is related to an existing question I asked. I though I'll ask a new question instead of replying back to the other question. Cannot "comment" on my previous question because of a word limit. Marc wrote - I've more than one Handlers in an Activity." Why? If you do not want a complicated handleMessage() method, then use post() (on Handler or View) to break the logic up into individual Runnable. Multiple Handlers makes me nervous. I'm new to Android. Is having multiple handlers in a single activity a bad design ?

I'm new to Android.My question is - is having multiple handlers in a single activity a bad design ? Here is the sketch of my current implementation. I've a mapActivity that creates a data thread (a UDP socket that listens for data).

My first handler is responsible for sending data from the data thread to the activity. On the map I've a bunch of "dynamic" markers that are refreshed frequently. Some of these markers are video markers i.e., if the user clicks a video marker, I add a ViewView that extends a android.opengl.GLSurfaceView to my map activity and display video on this new vide.

I use my second handler to send information about the marker that the user tapped on ItemizedOverlay onTap(int index) method.The user can close the video view by tapping on the video view. I use my third handler for this. I would appreciate if people can tell me what's wrong with this approach and suggest better ways to implement this.

View 2 Replies View Related

Android :: Supporting Multiple Screens / Most Optical Way To Design Application?

Jun 9, 2010

I have read the topic about supporting multiple screen size as well as different DPI. I am wondering which of the following way is better in supporting multiple screens:

1. Have different layout for different screen size (stretch the images)
2. Have different set of graphics for different screen (use the same layout)
3. Have different set of graphics and different set of layout for each of the screen

Which way is the easiest? And which way is the most optical way to design? Or is there another better way?

View 2 Replies View Related

Android :: Activity Bind To Service - Multiple Thread Design

May 28, 2010

A new question about android and services. Currently I'm developing a App that should send images to a server. It should also be possible to send more images parallel. I made a service that creates for every image a new image. The activity can bind to that service and gather information about the progress. I want to show the current status for every image in a notification (and when the user clicks a notification, an activity with the progress for that image should be shown). But I get several problems with that approach. There are errors with binding, the notification pending event starts the activity completely new, so I lose information about currently sending images and so on. How I could design in a appropriate way.

View 1 Replies View Related

Android : Switching Between Multiple Views In A ViewFlipper

Jul 19, 2010

I have an application using ListView inside Tabs, and I'd like to switch to a separate View(data collection widget) on clicking an item in the List.I'm adding each List's row's children to a ViewFlipper and the items are added at runtime so there is no definite number of views. As such, i would want to navigate/switch to a particular View in the ViewFlipper.Any pointers?

View 3 Replies View Related

Android :: Multiple Activities Or Switching Views Manually

Jan 15, 2010

I have developed some apps for Android, and this questions stays always:

How should I structure my UI? Should I launch activity after activity and leave the phone to make the "back" button, or should I choose more optimized, but more complex to implement, way with switching manually Views and then manually doing the "Back" button functionality?

View 4 Replies View Related

General :: Note 2 SGH-I317M With JB 4.1.2 - Switching Between Multiple APNs

Jun 15, 2013

I need to use a separate APN for work which only allows access to internal servers and no access to the internet. I'm wondering if it's possible to for certain apps to use the work APN and everything else goes through the internet APN.

If the above is not possible are their any decent widgets that I can use for switching between APNs?

My phone is a Note 2 SGH-I317M with JB4.1.2.

View 2 Replies View Related

General :: MK812 - Enable Multiple Users Switching?

Apr 4, 2013

I bought this nice minicomputer - MK812 Mini PC Dual-Core Android Camera Mic BT 4.2.1 and I relied on the fact that since there is Android 4.2 installed, I can use switching users, but unfortunately this function is disabled. I need to get it to work.

Of course, I googled. This is what I've already tried: URL....The problem is that this command pm get-max-users returns Unknown command get-max-users. Furthermore, when I enter SetProp fw.max_users 8, it has no effect, even after a reboot. The command pm usernameyouwanthere create-user is also without effect. URL....

App - 4.2 Multiple users feature enabler..This app can't be installed by Google Play (apparently MK812 is not a compatible device). Since I couldn't get APK anywhere to download, I downloaded the source code and compiled it and generated APK. Unfortunately, can't be installed either.I studied the source code and found out that even if i was able to get it installed, it wouldn't have worked anyway, because this app runs similar commands (as those above) instead of the user.

URL....This could be a solution even for Android 4.0 and 4.1. It works, but switching takes too long, because it requires a reboot and this switching is not integrated into the system.

View 3 Replies View Related

Android :: Display Multiple Activities In A Single Activity

Jun 12, 2010

I want to know if we can display multiple activities in a single activity using ActivityGroup.Can anyone please help me out with this?

View 1 Replies View Related

General :: PC Output Display To Multiple Android Tablets?

Jan 25, 2012

All I can find is video output to 1 secondary monitor. I need to know if I can (using iDisplay or whatever) output from a pc to 8-12 android tablets in extended desktop. So the tablets would make 1 big monitor. Operating system on pc side can be linux or windows 7/xp.

[URL]

View 7 Replies View Related

Android :: Google Maps Search - Display Multiple Results?

Mar 2, 2010

I had been showing off the droids capabilities to a co-worker when he asked "how far away is the nearest place to get a haircut from the hotel". At this time we were still at the airport, so I couldn't just say "map of nearest haircut". So I got the map to display the embassy suites, but then couldn't get it to ALSO display places to get a haircut. It was one or the other. I worked on it for about an hour but couldn't figure this one out. Is there a way to display multiple results?

View 9 Replies View Related

Android : Multiple Listviews In Single Activity But Display At One Time

Apr 5, 2010

I want to have multiple listviews in single activity. But only one listview should be displayed at one time. The listviews will be loaded dynamically. So, how can I fill all the four listviews at the same time and display only one.

If anyone knows the solution then please share it over here. I hope to get a quick response.

View 1 Replies View Related

Android :: Create Multiple Threads To Achieve Ftp Download And Display In Imageview?

Jun 30, 2010

The following code executes a function that retrieves a file via ftp and then displays it in an imageview. Since I'm using the main thread the UI locks up, somebody tells me I can use asynctask to make this work but I can't figure it out :<

Is anybody familiar with this that could offer me some guidance? code...

View 1 Replies View Related

Android :: Display Multiple Images From Remote Source In Gallery - Zoomable - Pannable

Jun 1, 2010

I want do display some images that I load from a remote source in a gallery. The gallery should let the user do the following things:

-zoom the image (preferably also by pinch-zoom) -pan the image -switch between the different images

Of course most built-in gallery applications can do all of that. So my first idea was to use an ACTION_VIEW intent in order to delegate the task to some gallery application. This however won't work for me since you can only pass the URI of the image you want to display but not the actual bitmap data itself. I can't just pass the URL of the remote image because I need to manage the loading and caching of the data myself. A way around this would be to write the data to a local file and then pass the URI of that file (and deleting the file again afterward). Besides this being less than elegant it won't even do the trick because with an intent like this you can only pass one image at a time.

The built-in Facebook application on the Nexus One actually does exactly what I have in mind for displaying photo albums. It looks like a custom gallery activity they built into their application. Does anyone know whether there are templates available for something like this somewhere that one could reuse? Building something like this from scratch by myself seems too time consuming.

View 2 Replies View Related

Android :: GUI Design - Mockup Design Tool For Android Application

Nov 23, 2010

I am going to develop an Android Application but before developing it i needs to have MockUp for the Android Application,so is there any way to design MockUp/GUI Design tool for the Android Application?

I know about DroidDraw tool , but i think it is not the exact way to prepare Mockup for the android application.

I have already referred this SO Question , but overthere i just found all the tools for the I-Phone only. So please feel free to share with me if you have/found any !

View 3 Replies View Related

Motorola Droid X :: Change Display Name With Multiple Links?

Oct 12, 2010

I searched for this, but it came up with nothing. How do you change the display name in contacts with multiple links? I have one contact that has a phone link, twitter link, facebook link, and gmail link, and the display name is the twitter name. I dont like this, and I cant change it. I tried linking the phone contact name last, and it still reverts to Twitter. Where are the permissions at to say which account should bear the contact name in my phonebook? So annoying that I cant find it.

View 13 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved