goldfish_defconfig
$ Make-J2 // The current machine is dual-core, so that code compilation is faster.
Compile the last two lines of information:
Objcopy ARCH/ARM/boot/zimageKernel: ARCH/ARM/boot/zimage is ready
6. Start the simulator with the kernel we just compiled (this will not affect the original simulator)
$ Emulator-AVD avd15-kernel ~ /Kernel_common/ARCH/ARM/boot/zimage
If the simulator can be up, it means it is successful.
Open another termina
response action can be written as follows if you want to swipe left on the first page.Private Onpagechangelistener Pagechangelistener = new Onpagechangelistener () {@Overridepublic void onpageselected (int arg0) {//Todo auto-generated method stub} @Overridepublic void onpagescrolled (int arg0, float arg1, int arg2) {//Todo Auto-gene Rated Method Stub//log.d ("Testactivity", arg0+ "," +arg1+ "," +arg2 "); curpage = arg0;} @Overridepublic void onpagescrollstatechanged (int arg0) {//TODO auto-gen
Android: Introduction to asynchronous task asyncTask and download image of asynchronous task (with progress bar)
Why use an asynchronous task?
In android, the ui can be updated only in the main thread, while other threads cannot directly perform operations on the ui.
Android itself is a multi-threaded operating system.
/*New private static final int my_permissions_request_call_camera = 1;//request code, self-defined//new Android6.0 permission check @Override protected void OnStart () {Super.onstart (); if (Build.VERSION.SDK_INT >= build.version_codes. M) {if (Contextcompat.checkselfpermission (this, Manifest.permission.CAMERA)! = Packagemanager.permission_grant ED) {//If there is no authorization, request authorization Activitycompat.requestpermissions (this, new String[]{manifest.permissi On.
First, download adbwirelessAddress: http://sj.zol.com.cn/detail/41/40834.shtmlRoot privileges are required for installation.Transport adbwireless. The interface is simple, just a big button. Click the button to turn it green, indicating that it is running. You can start the connection on the PC side.Each machine will be different, the above picture is: ADB connect 192.168.1.106:5555Second, wireless connection mobile phoneUnder the Win7 Start menu, sel
32-bit systems as a personal experience.
2. Memory and CPUBecause some friends install Ubuntu on the virtual machine, so the memory allocation may be easy to small, recommended as large as possible, I 1G memory, the compilation of errors, reset 2G memory is no problem.CPU is too weak, the process of compiling is also easy to kill, I appeared once, restart after OK. So the CPU level should pay attention to.
3.java of choiceWhether it is the official Androi
This article describes the Android imitation Zaker with hand-driven development of special effects. Share to everyone for your reference, specific as follows:
Recently in the store to download the Zaker, leisure time to take a look at the news! Found that every time you open the software into the main interface, there is an interface, you need to slide it up to a certain distance to enter the main interfac
This article introduces the sdcard storage picture Download simple operation, share to everyone for your reference, the specific contents are as follows
Step--After adding network permissions to the configuration manifest
1, Res/layout interface layout
2, there are 2 classes of one Operation SDcard File tool Class (Fileutil) another mainactivity class
Fileutil class
Operation SDcard's File tool class public class Fileutil {priv
A recent study of multi-threaded download, wrote a demo. It may help others to sort it out.Multi-threaded download generally open two to three threads. It's a waste of time to assume that too many threads will waste time on thread switching. Too many threads is not a good thing.The principle of the words to see my also a blog post, in fact, the code is ported to the And
Learning android together (6)
The menu includes the OptionMenu, the context menu, and the SubMenu ).
To create a SubMenu:
1. Override the onCreateOptionMenu (Menu menu) method of the Activity. In this method, add a Menu through the Menu object method.
2. In response to the click event in the menu, override the onOptionItemSelected (MenuItem mi) method of the Activity.
The Code is as follows:
Public class
) {super.handlemessage (msg); Bundle bundle = new bundle (); bundle = Msg.getdata (); Bitmap Mybitmap = bundle.getparcelable ("Bitmap"); Inserttoedittext (Mybitmap);} };Where Mybitmap is the handwritten word obtained, saved in bitmap, Inserttoedittext (Mybitmap); is to add the picture in EditText, as follows:Et_handwrite = (lineedittext) Findviewbyid (r.id.et_handwrite); Insert hand writing into EditText private void Inserttoedittext (Bitmap mbitmap) { int imgwidth = Mbitmap.getwid
each thread, ending position for (int threadId = 1; ThreadId For the output of the stream can encapsulate a streamtools method, can be applied in the main program, the code is as follows:Package Www.csdn.net.utils;import Java.io.bytearrayoutputstream;import Java.io.ioexception;import Java.io.inputstream;public class Streamtools {public static string Streamtostr (InputStream is) {String value = null;try {B Ytearrayoutputstream BAOs = new Bytearrayoutputstream ();//define the length of the read i
vertical control, three labels layout_height are wrap_content, when three labels by the height of the occupied space. The remaining space is allocated at layout_weight scale, because label 1 and label 3 do not have the Layoutweight property set. Defaults to 0, so the rest of the space is allocated to the label 2,???????????????????? Keep in mind that this time the TextView? android:layout_height= "Wrap_content"???????????? ?????????????????? 3.2? Whe
Csdn posts
1. The source code of android can be downloaded synchronously. How can I obtain the source code of Android Linux? Linux website? What version should I get?
Http://topic.csdn.net/u/20110328/16/ab03326f-9309-428e-b52c-0c122cedb5c9.html
2. When downloading the android source code, why does the following error always occur when the curl command is execut
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.