What is the use of an activity? I still have no idea at all. I am not very clear about it. I found a lot of methods when I read the document. Here I only wrote a simple layout switch, as for how to use the activity in the future, I will learn it
If you need to reprint reference please indicate the source: http://blog.csdn.net/jiahui524
I believe you have encountered such a situation when using many applications, that is, when we click to use this application for the first time, the
Application scenarios:
Android officially pointed out that there are five data storage methods for Android: Shared preferences, network storage, file storage, external storage, and SQLite. However, we know that these storages share data only in a
Android/FFMPEG dynamic module, JNI simple wrapper on production device, we can't use "Executable File ".
We need to build "dynamic, so module" for FFMPEG/ffserver.
This post explain how to build so module and simple JNI interface for FFMPEG.
1)
Recently, I worked overtime day and night, and even forgot my last name. What's more terrible is that I had to pay for a bug! Alas, let's not talk about work first. Back to the technology, we can satisfy ourselves with such spiritual food every day.
1. When a program is accidentally terminated, my program has no errors and I cannot find any errors. I don't know what's going on, but when I copy the code to another project again, it's okay to execute the program again! So far, I still don't
Android starts a subthread, which is an endless loop and cannot print "hello ".
Now, how can I click a button to terminate the subthread?
Stop () does not work. If destroy () has an exception, handler does not seem to be able to solve it because it
Android controls seekbar and ratingbar
1. seekbar is a progress bar. You can drag it to change it;
After dragging:
The original code is as follows:
Layout file:
Java code:
Package Lili. seekbar; import android. app. activity; import android. OS.
Frame Animation, that is, playing images prepared in advance in sequence, is similar to a movie.
The following example shows how to click the button to play the animation and click "stop" to stop the animation!
1 ,:
2. The main. xml file is simple:
First, we will introduce how to draw images!
There are two types of canvas, paint;
Canvas represents the canvas with the specified view attached, and paint represents the paint brush on the canvas;
The key to how to draw a basic set of images in an
:
1. The first is the code of the Main. xml file.
Emphasize: Content in Android: layout_gravity = "center" textview is centered
2. Create a colors. xml file
#330000#550000#770000#990000#bb0000#dd0000#ff0000
3. Source Code layoutchen.
1. The Android platform provides two types of animations: tween animation, that is, animation effects are generated by constantly performing image transformations (translation, scaling, and rotation) on the objects in the scenario; the second type
This method is available in the service. You can bind a notification to start a pre-service, just like Kingsoft Software,Void Android. App. Service. startforeground (int id,
Notification)
Private void setupasforeground (string text, class CLs
Android can be set to adjust the scaling ratio with the window size, but even so, the mobile phone program designer must still know the border of the mobile phone screen to avoid layout deformation caused by scaling.
The resolution information of
Let's take a look
,,
How about it?
Let's analyze how this effect can be achieved?
First of all, we should note that the top several horizontal switchover functions are tabhost.Tabhost
Provides a window view container for tabs. This object
The seventh day of Android
Textview and edittext
Textview:
Android: application of the autolink attribute
Android: layout_width ="Fill_parent"
Android: layout_height ="Wrap_content"
Android: Id ="@ + ID/autotx"
Android: Id ="@ + ID/tvweburl"
*/What do we need to simulate a call program?
1. Draw the android UI
2. The interface is equipped
In our design on the UI, we found that there are two string strings, one text box and one button.
First add two strings to the res-values-strings.xml
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service