Brief introduction
Android offers three menu types, options menu,context menu,sub menu, respectively.
The Options menu is displayed by pressing the home key, and the context menu needs to be displayed on the view after 2s. Both menus have submenus
In Java, if you want to use a global variable, you typically define a variable of the public static type. But this approach does not conform to the Android framework, and Android uses the application context.
Application is a base class, and the
Content Provider is one of the components of an Android application, and as the only way to share data between applications, the main function of content Provider is to store and retrieve data and provide access to other applications as an excuse
Sharing data using ContentProvider (content provider)
ContentProvider's role in Android is to share data externally, which means that you can share data from the application to other applications via ContentProvider, and other applications can be
"0" The basic design concept of Android is to encourage the reduction of coupling between components, so Android provides intent (intent), intent provides a common messaging system that allows you to pass intent between your application and other
As far as the Android platform is concerned, the URI is mainly divided into three parts: scheme, authority and path. Among them authority is divided into host and port. The format is as follows:
Scheme://host:port/path
As a practical example:
Context literal, which is in the Android.content.Context of the framework package, in fact the class is long, similar to the handle handle in Win32, many methods need to pass The context can identify the caller's instance, for example, the first
The study of Android loading images asynchronously from the network is summarized as follows:
(1) Since the Android UI update supports a single threading principle, fetching data from the network and updating it to the interface may first be
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
In the display and rendering of fonts, Libgdx's author (Mario Zechner, American) provides us with a very useful tool
--hiero, let's take a look at how it is used.
First, the use of Hiero tools
1. Download Address of Hiero tool
2, after the
This article is an example of how Android implements font flicker animation. Share to everyone for your reference. Specifically as follows:
This is based on the thread and timer to achieve the Android font flashing animation effect.
?
public
An example of this article describes how the Android programming implementation detects the current power state. Share to everyone for your reference, specific as follows:
Detected now in power state:
Intentfilter mintentfilter = new Intentfilter (
Article Description: Android Application interface design.
Compared with IOS, the Android interface has a variety of uncoordinated interfaces, and the application interface itself lacks a uniform specification. While Android's openness
After Android3.0, Google created the fragment, so the original tabhost has not been recommended, now generally recommended to use Fragmenttabhost.
Google considered compatibility issues, so fragmenttabhost was not added to the official SDK, but it
The process name is passed in the Manifest.xml "
public void OnCreate () {
String processname = Getprocessname (this, android.os.Process.myPid ());
if (Processname.endwidth ("Replace with the desired process name")) {
initxxx ();
}
}
public
Fastjson is a JSON-processing toolkit for Alibaba Open source, including "serialization" and "deserialization" in two parts.
Tests show that Fastjson has a very fast performance beyond any other Java Json parser. Includes self-proclaimed fastest
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. Illustration
Android is based on Linux and is different from what we normally think of Windows. Its file structure is similar to Linux, so its root directory is/, and then underneath is:
1. MNT: mount point directory, sdcard in the modified
First, Simpleadapter
Simpleadapter is a simple adapter that maps static data to a defined view in an XML file. You can specify a list of data support such as the ArrayList composition map. Each entry in the ArrayList corresponds to a row in the
An error occurred when Android Studio loaded the OPENCV library: "Cause failed to find target android-14"
Modify the Build.gradle file in the app folder. Change the sdkversion to use the SDK, such as 19.
Apply plugin: ' Android-library '
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