During debugging of Android applications, the android simulator screen is often found.
Most people may use hvga debugging.ProgramThe simulator works normally when the resolution is small.
However, the current mobile phone screen is 800*480.
I made some changes based on the Code on the Internet, and kept records for learning.
As follows:
The main code is as follows:
Package COM. andyidea. tabdemo; import android. app. tabactivity; import android. content. intent; import android. OS.
Sometimes we want to add new resources in the standard framework. What should we do?
The solution is to try it.
Through the eclipse contact, we can think of whether it is simply to put the string in each folder of Res. Let's try it out first,
Download programs designed on Android 2.3 run on Android 4.0 and report to Android. OS. networkonmainthreadexception exception. Originally in 4.0, the access network cannot be performed in the main program. There are two solutions, one being added
From: http://liangruijun.blog.51cto.com/3061169/805484
Enjoy 20 android game source codes. Hope you will like them!Http://www.apkbus.com/android-21834-1-1.htmlAndroid crazy soccer game source codeHttp://www.apkbus.com/android-20986-1-1.htmlAndroid
AndroidThe code is downloaded from gingerbread 2.3.1. Make directly and an error message is displayed:
You are attempting to build on a 32-bit system.Only 64-bit build environments are supported beyond froyo/2.2
Search for
This demo is the first Android-based development.
The main functions include reading the contact name and number, displaying the lisetview, obtaining listview data, concurrent text messages, or dialing.
Package com. Android. Hello;
Import Android.
When we need to implement a touch event, we usually think of the ontouchevent method, which can get the coordinates of the touch point, and the component also has this function, use this function, you can move, scale, and change the background image
Recently, a drawer-like function needs to be implemented in the project, and the component of the drawer content can implement the slide function. This function is implemented here:
First, design the layout Code. The Code is as follows:
The main content of this chapter is to search for the local video on the mobile phone and add it to the listview list. Each table item contains the thumbnail of the video, the video playback time, and the video title, in searching for a local video (
Reprinted please indicate the source!
Link: http://blog.csdn.net/zgyulongfei/article/details/7750707
When I was lazy, I used Java to write a simple server. It is good for everyone to understand the principle.
The server has two ports open, one UDP
Public class mainactivity extends activity {// declare the control // path and number of threads private edittext et_url, et_num; // progress bar public static progressbar pb_thread; // display progress operation private textview TV _pb; // The
Recently, a Vertical Slide rod was added to the project. It was originally intended to rewrite the seekbar. Although it was finally achieved, it was not adaptive, so in order to adapt to different devices, the following describes how to use
Previously, the project needed to convert songs, but it was slow to implement through java. Recently, I had time to view MP3 decoding on the Internet and find libmad, which could implement mp3 decoding, so compile it into a database to test the
After reading coverflow on iOS, I felt that the effect was really good. I wanted to implement a program on Android. This program references this core code on the Internet, of course, I have added some other things. If you don't talk nonsense, check
·
·
Today, we will categorize how to call common functions:
Display webpage:Uri uri = URI. parse ("http://www.google.com ");Intent it = new intent (intent. action_view, Uri );Startactivity (it );Display map:Uri uri = URI. parse ("Geo: 38.899533,-77.0
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