During the past few days, major events in the mobile phone industry have continued. The release of the iPhone 4S is accompanied by complaints from countless Internet users, then, the silent death of Steve Jobs also filled people with grief for this
Thanks to the label, you can easily share and reuse the UI components in Android. In Android development, it is easy to create a complex UI structure. As a result, a lot of views are used, and some of them are rarely used. In response to this
1. Definition
Activity is a component that provides a visual interface and can interact with users.2. Overview
Applications are usually composed of multiple loose and mutually bound activities. Generally, when you start an application for the first
1. http uses gzip compression to set the connection timeout and response timeout
Http requests can be divided into cache and non-cache based on business needs. In a network-less environment, some data is still browsed through the cached httpresponse
I. Use html
Method 1. CDATA recommended)
ABC ]]>
Method 2. Escape HTML tags
bold, underline
Reference in the program:
Html.fromHtml(getResources().getString(R.string.myHeadStr));
2. Use Variables
this year is % 1 $ d
I. Socket Introduction
1.The so-called Socket is also known as "Socket", used to describe the IP address and port, is a communication chain handle2.Applications usually send requests to or respond to network requests through sockets3.The Socket has
Moving Objects by preset programs can attract some attention, such as rotating triangles. But what should you do if you want to use OpenGL ES graphics to implement user interaction? The key to enabling touch interaction for your OpenGL ES
I have developed an RSS aggregate Reader using the Windows Phone sdk rtw. I have a lot of experiences and want to write it down and share it with you. It also compares with iOS and Android development to give everyone confidence in the future of WP.
Do not use setImageBitmap, setImageResource, or BitmapFactory. decodeResource to set a large image. After decode is completed, these functions are implemented through the createBitmap on the java layer and consume more memory.
Therefore, use
Use Handler to refresh the interface
Instantiate a Handler object and rewrite the handleMessage method to call invalidate () to refresh the interface. The online program sends the interface to update the message through sendMessage.
// Enable
In a previous article, we mentioned how to implement the push solution in Android. One of the more mature solutions is to use the XMPP protocol. The AndroidPn project is an open-source project that uses the XMPP protocol to push information. Here we
The following is an example of the Code:
Package com. aloong. map;
Import android. app. Activity;
Import android. OS. Bundle;
Import android. OS. Handler;
Import android. webkit. WebSettings;
Import android. webkit. WebView;
Use background thread
The background thread "working thread" can be used to remove the pressure from the main thread, so that you can focus on drawing the UI. In many cases, the use of AsyncTask asynchronous tasks can provide a simple way to execute
Android rapid development framework Afinal has been migrated to github, address: https://github.com/yangfuhai/afina
Afinal currently contains four components:FinalHttp: Used to request http data, direct ajax requests, file uploads, resumable
Currently, smart technology is everywhere, and developers have to design more convenient mobile applications for smartphone users. I am sure that there will be the latest and most special mobile apps in 2013. In fact, there is always a mobile app
First look at a set of simple code
public class SampleActivity extends Activity {
private final Handler mHandler = new Handler() {
@Override
public void handleMessage(Message msg) {
// ...
}
}
}
There are more and more mobile devices, and more than 1.3 million android mobile phones are activated every day. Therefore, our webapps for mobile terminals are also starting to follow up. This article describes the knowledge and experience of
During Android Application Development, the layout code of the control on the screen is usually separated from the logic code of the program. The layout code of the interface is stored in an independent xml file, which is organized in a tree and
Sometimes, our pages may contain some la S. These la s are hidden by default. After a user triggers some operations, the hidden la s are displayed. For example, an Activity is used to display the list of friends. After you click "import" in the Menu,
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