A few days ago because of the train, took a few days and energy past, today finally tested (subject two, or supplementary test ...) Well.. No matter how much it is. Today starts my Android learning journey again!!
Notebook:
Documents under the Platform-tools catalogue:
Adb.exe:android Debug Bridge (Android Bridges)
Devices list all connection equipment
Kill-server kill ADB
Start-server Kai adb
Dx.bat: Package Generate Dex File
Tools Catalog Documents:
Emulator.exe: Analog Device
Item Documents:
. Setting Save configuration information (Eclipse)
Assets assets (storage files, will be packaged into the APK.) Example: Pictures, library ...
Document after bin editing
Gen (Generated Java file) (auto-generated files catalogue)
Buildconfig.java Fit Information
R.java a reference to the storage resource ID
Android x.x.x (x.x.x version)
Android.jar (SDK) Well, the "folder Bag" I said earlier is a jar package ... Finally understand .
Project.Properties editing version
Target=android-x (version x)
Libs supported jar, will be added to Android depend under the catalogue
Android-support-v4.jar (Supplemental API)
RES Resource Catalogue
Drawable-xxxx (hdpi,ldpi,mdpi,xhdpi,xxhdpi ...) The store application will automatically generate ID to the R.java file.
Layout
Activity_main.xml (view in MVC)
<Relativelayoutxmlns:android= "Http://schemas.android.com/apk/res/android"Xmlns:tools= "Http://schemas.android.com/tools"Android:layout_width= "Match_parent"Android:layout_height= "Match_parent"Tools:context=". Mainactivity " ><TextViewAndroid:layout_width= "Wrap_content"Android:layout_height= "Wrap_content"Android:layout_centerhorizontal= "true"android:layout_centervertical= "true"Android:text= "@string/hello_world" /></Relativelayout>
View Code
Relativelayout (relative to the Bureau)
xmlns (named space)
Layout_width,layout_height (width of control) match_parent (padding)
Wrap_content (Package Contents)
Centerhorizontal (Horizontal center)
Centervertical (Vertical center)
@ (on behalf of Res,res and will be translated into R.java) string (internal) in the Res/values*/strings.xml has the definition of the strings
Androidmainfest.xml (The program's configuration information ={"Activate the program", "Application Name", "Package Name", "Version number", "...") in the application's checklist file.
<?XML version= "1.0" encode= "Utf-8"?><Manifestxmlns:android= "Http://schemas.android.com/apk/res/android" Package= "Com.itheima.helloworld"Android:versioncode= "1"Android:versionname= "1.0" ><USES-SDKandroid:minsdkversion= "8"android:targetsdkversion= "+" /><ApplicationAndroid:allowbackup= "true"Android:icon= "@drawable/ic_launcher"Android:label= "@strings/app_name"Android:theme= "@style/apptheme" ><ActivityAndroid:name= "Com.itheima.helloworld.MainActivity"Android:label= "@string/app_name" ><Intent-filter><ActionAndroid:name= "Android.intent.action.MAIN" /><categoryAndroid:name= "Android.intent.category.LAUNCHER" /></Intent-filter></Activity></Application></Manifest>
View Code
Package= "Com.itheima.helloworld" (Hand machine relies on package name recognition)
Android:versioncode= "1", Android:versionname= "1.0" (version)
Android:minsdkversion= "8" (System requires minimum version) android:targetsdkversion= "17" (System highest version?)
android:icon= "@drawable/ic_launcher" (icon)
Android:label= "@string/app_name" (Application name)
Android:theme= "@style/apptheme" (Application-like)
<activity> Application Interface
(Generate graphics on desktop ...) <intent-filter> Extra configuration <action android:name= "Android.intent.action.MAIN"/><category android:name= " Android.intent.category.LAUNCHER "/>
This is my own Baidu down .
First case: There is main, no launcher, no icon in the program list reason: Android.intent.category.LAUNCHER Decide whether the application appears in the program list Second case: No main, launcher, no icon in the program list Reason: Android.intent.action.MAIN determines the activity that the application starts first, if there is no main, then does not know which activity to start, therefore will not have the icon to appear quoted
Let's do it today. A lot of key words do not understand AH. A little bit of difficulty
Android Learning Journey! (2)