First, get the current mobile phone number * * Get current cell phone number/public String Getlocalnumber () {Telephonymanager Tmanager = (Telephonymanager) . Getsystemservice (Telephony_service); String number = Tmanager.getline1number (); ;
First boot after program installation:
Launch page--> feature introduction page--> system Home
Start later:
Start Page--> System home
So it's OK to judge on the launch page.
Can get a file to save a state, recommended with Sharedpreferences.
1.
From the SDK can be learned that it is the expansion of the ProgressBar, it is more than the progress bar a function is a drag, so that users can control the progress bar, such as playing movies, users can drag Seekbar for fast forward and fast
First step: First add the following code to the Androidmanifest.xml:
;/application>
The package specified above targetpackage is the same as the applied package. is the name of the package where the test class resides;
Step Two:
If you exit the currently running activity, you can use either this.finish () or System.exit (0).
If you exit the entire program, the following actions:
Mode one:
Intent intent=new Intent (intent.action_main);
Intent.addcategory (intent.
Online on this aspect of the article also a lot, the basic idea is thread + cache to solve. Some optimizations are presented below:
1, the use of thread pool
2, Memory cache + file cache
3, the memory cache in many of the internet is to use
Now give the second step analysis
Let's take a look at the process of sending a broadcast
The implementation of the Sendbroadcast function in the context is in Contextimpl, and the following six functions are associated with sending a broadcast
Guide: How do we start the first boot as an example to illustrate the receiving order of static broadcast receivers receiving unordered broadcasts
(Note that the text is only a statement of results, so called the result of the article, and then
Google unveiled its February version of Android, where Android 5.0 has grown to 3.3%.
According to last month's data, Android's 5.0 per cent share is 1.6%, and now it has grown to 3.3%, which can be doubled. Still, it's not much, but it's a lot
In the previous learning process has also seen, because it has not been working, also useless to, has been ignoring the past, in the group of a discussion, decided to take a good look at this, and finally find out, online a lot of introduction point
Before that, wrote a few about in Android to achieve the effect of sliding, after all, sliding effect in the development of Andriod also used more frequently, interested friends please check my previous article, no longer detailed here.
Today, the
The previous world in an application calls the system to send the text message intent, but the receiver's number has been worn, the code is as follows:
The code is as followsUri Smstouri = Uri.parse ("smsto:123456");Intent sendintent = new Intent
First download the latest version of the Android SDK. However, the latest version of the SDK has clearly stated that the Android SDK archive now contains the tools. It no longer comes populated with a specific Android platform or Google add-on.
Today I wrote a simple memory note applet, but found that my own code did not work when I judged that the data added was not empty.
String titlestr = AddTitle () ()
String contentstr = Addcontent () ()
if (titlestr = null && contentstr =
I. Use of bundle
When we start the activity, service, and receiver of another process in a process, we can attach the information we need to transmit to the remote process and send it through intent in bundle.
The data we transmit must be able to
I also wrote a few custom progress control, then, today, I add a control, the principle of similar to the previous, look at the effect:
This is an arc based on the progress control, mainly includes two arcs, a circle, a text.
When we click on
Introduced
Build Android's development environment and write a simple sample program
Build Android development environment under Windows
Directory structure description of Android project
Write a simple Hello world program
First, build the
Used EditText know, EditText has a feature, when the inside long press, will appear a ContextMenu, provides the choice of text, copy, cut and other functions. Sometimes, we will think, if do not appear this contextmenu, directly on the view of the
Activityunittestcase are often used to test individual activity. Before starting the activity being tested, you can inject a fake context or application to run the tested activity in an isolated environment in the mock contexts. Typically used for
An activity in an Android application is a basic module with a screen display that supports user interaction, similar to the MIDlet in Java me, and the form in Windows applications. For example, it can be a dial-up, sending a mail UI. Each activity
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