Go straight to the topic !!!
Steps for developing an application based on Baidu map on an Android device:
1. Download the android SDK:
Http://dev.baidu.com/wiki/imap/index.php? Title = Android % E5 % B9 % B3 % E5 % 8f % B0/% E7 % 9B % B8
Android provides a class: android.net. connectivitymanager can detect the network status
The initialization object is instantiated as follows:Context. getsystemservice (context. connectivity_service).
For example, check whether the Network is
Specifying the interface.
This example uses aidl, so the first step is to add an InterfaceDefinitionFile:
Frameworks/base/CORE/Java/Android/OS/ieneaservice. aidl
Package Android. OS;
Interface ieneaservice {
/**
* {@ Hide}
*/
Void
Viewflipper is a simple implementation provided by Android, multiple view switching controls, and animation effects can be added.
First, let's take a look at how viewflipper is described in the document.
Simple viewanimator that will animate
The webview control provided in Android allows developers to embed their own applications into the web browsing function, but some problems may occur in actual development. This will be introduced later,
:
Let's first look at an instance:
public
In multi-activity development, activity jumps between applications or reusable activities with other applications. You may want to jump to an existing activity instance instead of generating a large number of duplicate activities.
This requires
1. Install ndk here: http://developer.android.com/sdk/ndk/index.html download ndk. Unzip it.
To install the ndk, follow these steps:
From the table at the top of this page, select the ndk package that is appropriate for your development computer
1. Add read/write permissions
XHTML code
Android: Name = "android. Permission. read_contacts"/>
Android: Name = "android. Permission. write_contacts"/>
Contact information URI:
Content: // com. Android. Contacts/contacts
Contact number
I. Cause Analysis
Because a large number of programs are installed in the memory, the simulator runs slowly.
2. Solutions
Solution 1:
1. Uninstall unnecessary programs (follow the uninstall method in the mobile phone)
Solution 2:
1. When starting
Webview can be reused on the android interface. First, write a simple webview implementation.It is very simple and directly added to the default ADT project. Added a webview to access my blog homepage.First, remember to add the Internet access
This article is 51cto bhubhu original. For reprinted, please mark the original author and source to show respect!
Author: bhubhu
Original article: http://taodym.blog.51cto.com/3032223/11121601. Download and install Android ndk
My application's ndk
I will explain in detail about Java yesterday.JNI-related exception handling and thread security issues are mainly caused by insufficient memory outofmemoryerror and array out-of-bounds exceptions in JNI.Arrayindexoutofboundsexception, array
The reflection mechanism needs to be used to reflect itelephony.Private void dial (string number ){Class C = telephonymanager. Class;Method getitelephonymethod = NULL;Try {Getitelephonymethod = C. getdeclaredmethod ("getitelephony ",(Class []) null
First of all, in the development environment, Google recommends that you use ubuntu10.0.4 and preferably 64-bit. Since it is for work and study, follow the official requirements as much as possible.
Python 2.5 -- 2.7 ubuntu10.0.4 has been installed
Android: scaletype controls how images are resized/moved to match the size of imageview.
Imageview. scaletype/Android: the differences between scaletype values:
Center/centerCentered by the original size of the image. When the length/width of the
To use the root permission in an Android Application, the device that runs the program must have the root permission.
public static boolean runRootCommand(String command) { Process process = null; DataOutputStream os = null; try { process =
Ndk overview ndk Full name: Native Development Kit.
1. ndk is a collection of tools.
* Ndk provides a series of tools to help developers quickly develop C (or C ++) dynamic libraries and automatically package so and Java applications into APK. These
[Chinese is converted]1. onintercepttouchevent () is used to process events (similar to preprocessing, but it can also not be processed) and change the event transmission direction, that is, to determine whether to allow the touch event to continue
During Android application development, there are only two types, one is simple local application operations on the C/S mobile phone, and the other is through the network, local app operations on mobile phones are relatively simple, but interactions
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