Recent studiesLanucher , Read the source code, and foundSlidingDrawer This class is also called the "drawer" class. It is easy to use, includingHandle , AndContent .
Handle When you click it,Content Either drawer or close drawer. The specific steps
In Android, there are several ways to store data, including file, file-type database, and network data. Android comes with an SQLite database, embedded developers are certainly not unfamiliar with this cross-platform local file database. In Android,
I started to read sundy's tutorial today. I made some notes about Log and summarized some things according to the SDK on the official website. In fact, it is equivalent to a simple translation. Let's get down to the truth ~
/*************************
When we load a list, such as the GridView, we usually use Thread, Timer, or AsyncTask to avoid blocking the UI, all these operations are performed by opening another thread in the background to find data for us. The specific data obtained requires
1. query the devices currently connected (physical and virtual)
Shell code
Adb devices
Generally, a device with emulator is a virtual device.
2. Map the device port to the PC port
Shell code
Adb-s forward tcp: 8080 tcp: 8080
If only one virtual
Common usage: callback method interface, dynamic binding to upward transformation, constant interface.
Callback method interface:
Java code
Public interface ICallback {
Public void func ();
}
Public class Caller {
ICallback callback;
Public
Android applications are also message-driven. In principle, the message loop mechanism should also be provided. In fact, Google refers to the Message Loop Mechanism of Windows and implements the message Loop Mechanism in Android.Android uses logoff
Trouble writing output: Too writable methods: 65634; max is 65536. By package :( Too many interfaces, broken through. Interface separation required)26 android145 android. accessibilityservice700 android. accounts436 android. animation8 android.
In the last two things, we have encountered the need to listen to user gesture input and take some time to record these basic implementations. In this regard, many of the materials mentioned here are just simple gesture listening. for example, slide,
I will not mention the commonly used SQList writing method. Here, I mainly add a writing method when the database is updated and columns need to be added:
For example, in the user table, add a gender column. The default value is 1, which is male
The Activity itself provides a progress bar that can be controlled and displayed on the Titlebar. In this example, a horizontal progress bar is used. In this example, a Spinning wheel is displayed on the Titlebar.
First, you need to set the
RadioGroup is used to manage a set of Radio buttons. RadioButton is a single-choice Button. Only one RadioButton in the same group can be selected. In the preceding example, the Android ApiDemos sample is parsed (107): Views-> Controls-> 1. Light
This example introduces the basic usage of ScrollView. ScrollView allows you to scroll the screen to display content greater than the screen. ScrollView is a subclass of FrameLayout. Therefore, only one sublayout is displayed in ScrollView,
[Html]Layout file. The outer layer uses RelativeLayout to use the last image and android: keepScreenOn = "true"[Html]Android: layout_width = "fill_parent"Android: layout_height = "fill_parent"> Android: layout_width = "match_parent"Android:
In android, data type conversion does not seem to support a great deal of data types. Backup functions and tool functions are useful.
I. type conversion
1. Convert byte to int (int can be converted to long double float)
[Java]Public static int
With TimePicker, you can select events of the day, including the 24-hour and AM/PM formats. The following example shows how to use TimePicker.
1. Create a project: BasicViews4.
2. Code in main. xml.
[Html]Android: layout_width =
Many usage of PopupWindow are described on the Internet, so I will not explain it too much. I just want to explain the possible problems and solutions:
1. The listview in PopupWindow has no responseThis is mainly because show is written before
This example describes how to use an empty cell in TableLayout. One is to skip the cell, and the other is to use an invisible View to occupy a cell:
Android: layout_width = "match_parent"Android: layout_height = "match_parent">
Android: text = "@
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