messages.
The following figure shows how to create progressdialog:
ProgressDialogprogressDialog=newProgressDialog(getApplicationContext());
progressDialog.setProgressStyle(ProgressDialog.STYLE_HORIZONTAL);
progressDialog.setIcon(R.drawable.alert_dialog_icon);
progressDialog.setMessage("Loading...");
progressDialog.setCancelable(false);
3. When you are about to display this dialog box, call show () or return progressdialog from the oncreatedialog (INT) callback.
4. You can call
[Android] simple animation for UI switching, android Switching
1. Create an xml file for the displacement Animation
Enable animation in Activity
Use the AnimationUtils class to load animation resource files
Left_to_right.xml
View child=new IndexView(this).getMemberView();child.startAnimation(AnimationUtils.loadAnimation(this, R.anim.left_to_right));
2. Fade-in
object is returned. In this way, the application does not need to execute findviewbyid () to obtain reference for loading views.
Experience Sharing:Viewstub can be used to associate with the specified layout resource file in the XML file, so that the layout resource file can be loaded as needed. When to load data, instead of loading data at startup. This can speed up application startup and save memory resources.
Blog related to optimization series:
[Android UI] android-lockpattern unlocking implementation, androidui
This article is for learning and sharing. If there are similarities, it is a coincidence that there are similarities?
Based on the principles of technology sharing and mutual learning, I would like to share the implementation of an open-source android
Path to Android Development 7-UI component 2
Today, we continue to learn about the UI components, mainly including TextView and EditText.
TextView component introduction:
Subclass:
Button, CheckdTextView, Cheronometer, DigitalClock, EditText
Indirect subclass:
AutoCompleteTextView, CheckBox, CommpoundButton, MultiAutoCompleteTextView
In its xml file, there are ma
Android Interface ProgrammingAndroid Advanced UI Components 2.4.1 Adapter Components the role of the adapterThe adapter acts as a bridge between the adapter control and the view data . the adapter provides access to the data item and is responsible for generating a view of each item in the Data group . commonly used adaptersBaseadapter: Abstract class, with a high degree of flexibility.Arrayadapter: The sim
Android methods for threading update UIWhen an Android program starts running, a process is started separately. By default, all activity or service (service and activity) in this program is only two of the components that Android provides, in addition to content provider and broadcast Receiver) will run in this process.An And
Unit Test and UI test in Android Studio, androidui
This tutorial is translated from codelab for Testing in Google I/O 2015. If you are familiar with scientific Internet access, click here to read: Unit and UI Testing in Android Studio. Limited capability. If any translation error occurs, please correct your criticism.
[Android UI] how to unlock the android-lockpattern
This article is for learning and sharing. If there are similarities, it is a coincidence that there are similarities?
Based on the principles of technology sharing and mutual learning, I would like to share the implementation of an open-source android pattern unlocking
Android for more than 10 years, the adaptation of the Android UI has been the most important issue in the development process, but I've seen a lot of small partners who don't know about the Android adaptation formula. In the near future, we are going to design a set of UI si
Recently in writing an application, want to put the Settings page and application page together, so that users can see their settings in real time to the impact of the UI, so more convenient to set the user's favorite interface. After a while, I found that this effect can be achieved by using the Slidingdrawer control. Which is a drawer. Pull open the drawer, occupy half of the screen, the other half of the screen or display application page. The effe
Android UI design and development tutorial Slide menu bar (iii) Slidingmenu animation effect of the real
Android UI design and development tutorial Slide menu bar (ii) Slidingmenu of Open Source project
Android UI design and dev
recommended colors for Android UI---interface developmentIn the Android development process, always to add some background to the app, the individual think that the use of pure color can achieve elegant visual effect.Add some common color values: Colors.xml1 How to configure colors with Colors.xml filesandroid:background="@color/tan"The lookup is based on the lab
When an android program starts running, a process is started separately. By default, the activity or service (Service and activity are only two types of components provided by Android, and content provider and broadcast receiver) in this program will run in this process.By default, an android program has only one process, but a process can have many threads.Among
Download and learn the source code of the Android UI component instance, which is helpful to your learning. The following is the information in the download package.1. Display GIF animated GIF view on AndroidGifView is a view that does not display gif directly in android. It can only be used by mediaplay to display the problem. It is the same as ImageView and sup
In the forum, we often see people asking how to achieve the drag effect of UC or moji weather. In fact, most implementations refer to the workspace class in launcher. We can see that an open-source project also implements this function.
View flow for Android
Viewflow is an android UI widget providing a horizontally scrollable viewgroup with items populated fromAn
List View plays a major role in the android UI. If listview is not properly written, the program performance will be greatly affected.
Here is an example of a project listview. The key is the implementation of the complex UI of listview.
The final effect is as follows:
package com.test.list;import android.app.ListActivity;import android.content.Context;import
Original address: http://www.cr173.com/html/19165_1.htmlIn the design idea of Android, in order to ensure the user smooth operation experience. Some time-consuming tasks cannot be run in the UI thread, such as accessing the network. So we have to re-open a background thread to run these tasks. However, these tasks often end up needing to access and control the UI
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.