Hi i have a app contain 3 page. and i want to set one page as background like android home screen. I search in google and i found this and this
tutorial's but i couldn't use it for my target can anyone show me another better example thanks.
i mean How can i create app like android home screen which have one picture for 5 pages background (in my phone).
at last i found my answer and that was so simpler that i think.
that was not a live wallpaper that was simple trick using scroolview for background of main layout and listen to onPageScrollStateChanged.
that's it.
Related
I am thinking about creating a text-based game (similar to gamebooks) for android device. In this moment only theoretically. Do you have some advice please, which way to go?
You probably know how gamebooks works, but the gamebook I want, will be very easy, should work like this:
User has shown some image, text and 3 options (questions), he decides which option to click, then a new page is showing (according to the clicked option) with another image, text and another 3 options. Then again, the user clicks one option, another page opens, etc.
My question is not how to do it programmatically, but how to start with this in Android Studio, what system to use for such game on android or which way to go.
Because I think it has no sense to create intents after each click, as there might be hundreds of clickable options.
I have already created such game on my website with php/html/js, but I want to create it also offline for android.
Intents implies one activity per page - unmaintainable.
You should work with a database and load based on user interaction. So you'll need to learn about Databases and Asynchronicity (working in the background while updating the UI so the user knows)
This is my first Android app, and first java app in general so the more detailed the answers/examples the better.
I've got three buttons in my app. I'd like these same three buttons to be accessible on the lock screen. They're not media controls, but actual buttons that when pressed fire up or interact with a running thread.
Any suggestions? Links to examples? Thanks.
Follow Google's documentation
https://developer.android.com/guide/topics/appwidgets/index.html
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
I am posting this question because I never worked on this and I am not aware which component is used to implement such functionality.
See this screen-shot. This is an sample image. It is not my work, this is taken from Google Images:
Now on application startup I am reading Android sd card and updating my database. In the meantime, I am using ProgressDialog like this
Now what I want is to show 5 image slides. Not Image slide I want a single colour backgroung and the text should have to be change every two seconds on the same backgroung with five small circles I downside.
Now I am not able to get what is it. A image slide show or other native component. I asked in chat rooms they asked me to post here.
If it can happen without image it will be better because there is a lot of complexities with different device sizes.
How can I implement this?
Try with android smartimageview or with Viewflow
I need a way to show off concept designs of an android application on an android phone to simulate that it is running. Basically just being able to tap to advance to the next photo/screen would be sufficient with a tap ANYWHERE on the screen. Any tools you know that would be helpful?
Eclipse with Android toolkit.
Write a small program. wont take up much time.
[update]
No coding is required. Create an android project Using Eclipse android project, you can visually create UI prototype (i.e. drag and drop .. no coding). Use main.xml after developing each screen run the project in emulator, you can take screenshot of the same (either using eclipse DDMS plugin's snapshot capability or using Alt+Print screen in windows or something similar in other OS). Use this screenshot in a powerpoint presetation . Repeat the same process for a second screen (overwrite the same main.xml so that you dont have to write code). take screenshot again. Add the required animations in powerpoint.
Is there any other option that does not involve any code?
The easiest way I can think of is:
1. Take screen shots(wireframes, screen prototypes) for every screen flow you wish to demonstrate.
2. add them in proper sequence(regulated by sequence number) to your sdcard.
3. Open Picture gallery and use swipe gesture to transition and cycle between screen, walk through all the screen flows.
Do it photoshop, create images, add it to an activity. Create a layout that fills the parent, add it as a background. Then implement a ontouch method to finish the activity and load the next. Quite simple.