What's the best way to realize a startscreen? - android

Can someone tell me what's the best way to realize a startscreen in android. What I meant is when you open the app than a image appears a few seconds and in the background the app is loading?

Here is another example, which does not utilize a separate activity.

Related

android. One activity to rule them all :)

This is more of a curiosity than anything else but it would be good to get some feedback from everyone on possible problems and solutions etc.
Is it possible to use one "host" activity and use that activity to display 3-4 different activities?
I already use tab host in my app and this doesn't seem to fit my needs in regard to the menu idea, ill explain what I'm trying to do as it may help.
Im trying to find a nice clean solution to playing background music, but this could be applied to other functions as well, but essentially, after the splash screen i would like a "host" activity to load first and in that activity, load up a menu activity, when the use presses a button the menu activity, i would like the next activity to load up still inside the "host" activity.
I'm hoping this would make playing music etc as clean as possible and with as little extra coding as possible.
Is this idea possible? would it be beneficial? what would be the best way to accomplish this?
Like i said this is more of a curiousity than a "gimme code to do it", I can work that out once i know the direction to head in & if its possible, I mainly want this for b/g music at the moment but im sure this could be applied other functions.
Thanks for looking, reading giving your thoughts :)
phil

Android App with Fragments/Actionbar: How to run code when startup is totally finished?

I am writing an android app that uses Fragments and an ActionBar.
Is there a simple way to know when the entire app has finished starting up? Each fragment has it's own layout, and my startup code needs to touch them all. Is there an event I could use to accomplish this?
Thanks!!
onCreateView is called after the view is "all there", so its a good place for code that needs to run late in the game. You could set a flag here or send an event to notify other views that you're ready, but it is per fragment.
However, fragments are kind of based on the idea that they will be created as needed. In a normal app they come and go dynamically so there isnt ever a time when the "whole app is loaded". So, there isnt going to be a single place you can check for whether all fragments are ready unless you make your own. Before doing that you might want to consider other ways to accomplish the task at hand. Your design may not be a good one if you are having to fight against the underlying system.

Android app display on top of another

I'm trying to build an application that would run at the same time as another one, on top of it (hiding only partially the original app), that would display useful information for the user of the main app.
But it seems that 2 activities cannot run at the same time, overlap, etc...
For argument sake, lets say the app would be displaying date & time in a corner of the screen, while playing a specific game.
Anyone got any doc or sample code on how to achieve such a result ?
I'm also interested in how to know which app is currently running in order to decide in my app-on-top to be visible or invisible.
Any help appreciated :)
Thx
Looks like you are in need of Fragments: Fragments
The Android system is designed to be user friendly, and two activities at same time is not, so only one activity is on foreground at once. if you need the other to be running in background make it a Service, if you want to show some data and get back first one use a Dialog, finally if you want both you can either put them in one activity or use Fragments as #Tooroop suggsets.
Its propably too late ... but for others with the same problem:
check out how-to-draw-on-top-of-other-applications
and maybe also this if your app need to be on top on fullscreen apps

Show progress Bar Untill the next activity gets loaded

I am new in android development. I have two activities in first activity there is only a button by which i am calling next activity using intent and in second activity i am doing the actual work i.e. i am getting the values from web using SOAP.
So , My problem is that when i go from 1st activity to the second activity it shows me a BLACK screen until the next activity gets loaded totally since the response fron web is large.
I want to add a progress bar from my 1st activity to second gets loaded totally to avoid this black screen.
Do anyone have any ides about this.
Thanks in advance.....
You have four realistic solutions i would say in my opinion
1- Threads
2- Asyntask
3- Service
4- External lib
If you are doing lot of small downloads classic Theading is the best option maybe with a service to manage it, but not forced.
For one simple download you can use Asynctask alone. It can be enough but you must know several things about this method : AsyncTask can be "Bugged" according to the way you use it.
Service is good you can use it. A download module using service is a good idea to manage the requests.
The best solution for a quick/efficient developement is to use a library that do the work for you. But in your case you are using SOAP... If you where using Json you could make use of Volley which is very good and fast.
Maybe try to use this one which is well known
http://code.google.com/p/ksoap2-android/
with the how to http://code.google.com/p/ksoap2-android/wiki/HowToUse
For the moment when to do the operation you have several solutions
1- In background without blocking the ui, updating the ui View per View
2- Using a loading screen (bad for user experience but sometimes you don't have a choice)
In your case you would have the loading screen between the first activity and the second using a ProgressDialog maybe

An App for Android Tablets

I am very new to android development. I wanna create a app thats like a ticker on android tablet. But when the user clicks on any other application, i still want my ticker to be visible and the other app to resize and occupy rest of the screen only.
Somebody told me that this is not possible. Is it the case ? Anyone know of any similar app ? or somehow plz get me started with this ?
Thanks for your help.
Cheers
It is not a good idea steal screen space from other applications. If your ticker is floating above like modal window, it would probably block some views for the user.
If your app is competing for the screen space, the other app would probably look ugly.
My suggestion is that you rethink your application, and follow the user interface guidelines.
Good luck!
I believe this isn't possible. Even if, it isn't a good idea. If you want something like that consider creating a widget or some kind of notification. That would be the best and a lot of applications use notifications like that.
what you want to do is creating a system type of window,such as PHONE_WINDOW,make your app flowing on the up-layer of other normal window.
You may read this post
http://www.apkbus.com/android-77789-1-1.html

Categories

Resources