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 Android
GifView 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 supports gif image usage: 1-set gif view. jar to add your project. 2-configure the basic attributes of GIF View in xml. gif View inherits from the View class, which is a UI control like Button and ImageView.
For example:
<Com. ant. liao. GifView android: id = "@ + id/gif2"
Android: layout_height = "wrap_content" android: layout_width = "wrap_content"
Android: paddingTop = "4px" android: paddingLeft = "14px" android: enabled = "false"/>
3-configure common attributes in the Code:
// Get the GifView handle from xml
Gf1 = (GifView) findViewById(R.id.gif 1 );
// Set the GIF Image Source
Gf1.setGifImage(R.drawable.gif 1 );
// Add listener
Gf1.setOnClickListener (this );
// Set the display size, stretch, or compress
Gf1.setShowDimension (300,300 );
// Set the loading mode: First load and then display, while loading, only display the first frame and then display
Gf1.setGifImageType (GifImageType. COVER );
The Jar package of GifView has four classes:
GifAction. java observer class to monitor whether the GIF is loaded successfully
Three members in GifFrame. java: current image, latency, And next Frame link.
GifDecoder. java decoding Thread class
GifView. java main class, including common methods, such as the GifView constructor, image source setting, latency, and painting.
2. Calendar. v0.5.0
Is a calendar display component of the Android platform.
3. CWAC EndlessAdapter
It is a widget on Android that can load list data without limit.
4. Android Horizontal ListView
It is a horizontal sliding ListView component on Android.
5. Android ViewBadger
View layout.
6. sliding and refreshing ListView Android PullToRefresh
Provides an Android app with the ability to slide down to refresh the list, with two target files.
7. pakerfeldt-android-viewflow
Is the effect library for view switching on the Android platform. ViewFlow is equivalent to a ViewGroup that provides horizontal scrolling for Android UI parts and binds entries using the Adapter.
8. RibbonMenu
Is a navigation menu component on Android. For the three target files, the menu items are directly defined in XML, and text and Icons can be added.
9. Android UI toolkit android-ui-utils
Is a toolkit used to help design and develop the Android user interface, including three separate tools: Android Asset Studio User Interface prototype mold, Android design preview, android App developers who often need to repeat the Design of the program layout should fall in love with this lightweight Java program: Andorid Design Preview tool. After connecting through USB, you can simply select the layout range of the program on your computer to display the image result directly on the mobile phone device.
10. Android ui development class library GreenDroid
Is an Android ui development class library that makes your Android development easier and faster.
11. Android sliding menu SlidingMenu
Is a component that implements slide menus like Facebook and Path 2.0 on Android.
12. AsyncImageView
It is an open-source component on Android that asynchronously retrieves images from the network and browses them. It can be automatically cached locally. This project is part of GreenDroid.
13. Simulate the Path button animation effect PathButton
I wrote a simple Demo similar to the Button animation effect in the lower-left corner of the Path application homepage. Due to poor mathematics, coordinates are always different from ideal, but the animation effect is roughly achieved. If someone can calculate the coordinates correctly, then I can modify my demo to make an animation effect similar to Path! I hope you can make some improvements and share them with us!
14. Android Intent Development Kit OpenIntents
The OpenIntents project uses "Intents" and Android provides an excellent foundation for connection software and dynamic replacement components. Google defines a batch of intents (for example, call, select a contact on the contact list, open the browser, and provide a prompt when the battery is changed, etc. However, any program can define additional intents and content-providers as needed. We can easily think of independently developed programs (such as in this competition), and very few may work together with newly defined intents and interfaces.
The goal of this project is to collect ideas that may be useful in multiple projects (and may have been implemented by other independent programmers ), define a batch of intents and interfaces with reasonable and good scalability, provide basic but stable and effective implementation, and can be applied by other Android programs, especially other programmers participating in the competition. OpenIntents will also participate in this competition. We provide a small sample program to demonstrate the usage and features of OpenIntents.
Because we focus on the commonly used intents, Google may also provide their own standard intents (such as about calendar...) in the near future ...) At that time, we will provide transparent interfaces to directly call Google's implementation methods, and your existing programs can directly use Google's new features without changing anything. In addition, because your program supports intents at the initial stage of design, when Google intents comes out, you can easily directly use their intents. It is also possible that Google may borrow some intents developed by OpenIntents. In any case, if your program uses OpenIntents to provide mutual support with other OpenIntents programs, you will get additional value to enhance the user experience.
OpenIntents is published using "Apache License 2", which is the same as Android license. This offers the same benefits to commercial and non-commercial third-party developers.
15. android-query
Is a lightweight Development Kit for implementing asynchronous tasks and UI elements on Android, which makes Android Application Development easier, easier, and more interesting.
16. Android-Universal-Image-Loader
Multi-thread asynchronous loading is supported for Asynchronous Network image loading.
17. Development Framework of Android mobilelite
It provides a lightweight development framework for Android application development, allowing developers to quickly develop android application interfaces based on HTML, CSS, and JAVASCRIPT. It can also use javaselite to call android background services.
18. Android waterfall stream instance android_waterfall
Implemented waterfall stream layout similar to the legend android and mogujie.com android.
19. JakeWharton-ActionBarSherlock www.2cto.com
It is an extension of the Android compatibility library. I don't know why the Android compatibility Development Kit does not contain ActionBar. so there is ActionBarSherlock. the usage is similar to that of the compatible development kit. it is designed to use the design mode of the Android operation bar of all versions through an API.
20. JakeWharton-Android-ViewPagerIndicator
Interface switching effect.