AndroidX Demo 调试完成
This commit is contained in:
		
							
								
								
									
										0
									
								
								androidxdemo/app_update_description.txt
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										0
									
								
								androidxdemo/app_update_description.txt
									
									
									
									
									
										Normal file
									
								
							| @@ -1,16 +1,47 @@ | ||||
| apply plugin: 'com.android.application' | ||||
| apply from: '../.winboll/winboll_app_build.gradle' | ||||
| apply from: '../.winboll/winboll_lint_build.gradle' | ||||
|  | ||||
| def genVersionName(def versionName){ | ||||
|     // 检查编译标志位配置 | ||||
|     assert (winbollBuildProps['stageCount'] != null) | ||||
|     assert (winbollBuildProps['baseVersion'] != null) | ||||
|     // 保存基础版本号 | ||||
|     winbollBuildProps.setProperty("baseVersion", "${versionName}"); | ||||
|     //保存编译标志配置 | ||||
|     FileOutputStream fos = new FileOutputStream(winbollBuildPropsFile) | ||||
|     winbollBuildProps.store(fos, "${winbollBuildPropsDesc}"); | ||||
|     fos.close(); | ||||
|      | ||||
|     // 返回编译版本号 | ||||
|     return "${versionName}." + winbollBuildProps['stageCount'] | ||||
| } | ||||
|  | ||||
| android { | ||||
| 	productFlavors { | ||||
| 		beta { | ||||
| 		} | ||||
| 		stage { | ||||
| 		} | ||||
| 	} | ||||
|  | ||||
|     compileSdkVersion 30 | ||||
|     buildToolsVersion "33.0.0" | ||||
|     buildToolsVersion "30.0.3" | ||||
|  | ||||
|     defaultConfig { | ||||
|         applicationId "cc.winboll.studio.androidxdemo" | ||||
|         minSdkVersion 16 | ||||
|         targetSdkVersion 26 | ||||
|         minSdkVersion 26 | ||||
|         targetSdkVersion 29 | ||||
|         versionCode 1 | ||||
|         // versionName 更新后需要手动设置  | ||||
|         // .winboll/winbollBuildProps.properties 文件的 stageCount=0 | ||||
|         // Gradle编译环境下合起来的 versionName 就是 "${versionName}.0" | ||||
|         versionName "1.0" | ||||
|         if(true) { | ||||
|             versionName = genVersionName("${versionName}") | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     buildTypes { | ||||
|         release { | ||||
|             minifyEnabled false | ||||
| @@ -20,7 +51,26 @@ android { | ||||
| } | ||||
|  | ||||
| dependencies { | ||||
|     implementation 'androidx.appcompat:appcompat:1.0.0' | ||||
| 	implementation 'com.google.android.material:material:1.0.0' | ||||
|     implementation fileTree(dir: 'libs', include: ['*.jar']) | ||||
|     api fileTree(dir: 'libs', include: ['*.jar']) | ||||
|      | ||||
|     // SSH | ||||
|     implementation 'com.jcraft:jsch:0.1.55' | ||||
|     // Html 解析 | ||||
|     implementation 'org.jsoup:jsoup:1.13.1' | ||||
|     // 二维码类库 | ||||
|     implementation 'com.google.zxing:core:3.4.1' | ||||
|     implementation 'com.journeyapps:zxing-android-embedded:3.6.0' | ||||
|     // 应用介绍页类库 | ||||
|     implementation 'io.github.medyo:android-about-page:2.0.0' | ||||
|     // 吐司类库 | ||||
|     implementation 'com.github.getActivity:ToastUtils:10.5' | ||||
|     // 网络连接类库 | ||||
|     implementation 'com.squareup.okhttp3:okhttp:4.4.1' | ||||
|     // Android 类库 | ||||
|     implementation 'androidx.appcompat:appcompat:1.1.0' | ||||
|     implementation 'androidx.viewpager:viewpager:1.0.0' | ||||
|     implementation 'androidx.vectordrawable:vectordrawable:1.1.0' | ||||
|     implementation 'androidx.vectordrawable:vectordrawable-animated:1.1.0' | ||||
|     implementation 'androidx.fragment:fragment:1.1.0' | ||||
|     implementation 'com.google.android.material:material:1.4.0' | ||||
| } | ||||
|   | ||||
							
								
								
									
										8
									
								
								androidxdemo/build.properties
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								androidxdemo/build.properties
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | ||||
| #Created by .winboll/winboll_app_build.gradle | ||||
| #Tue Mar 11 18:25:43 GMT 2025 | ||||
| stageCount=0 | ||||
| libraryProject= | ||||
| baseVersion=1.0 | ||||
| publishVersion=1.0.0 | ||||
| buildCount=4 | ||||
| baseBetaVersion=1.0.1 | ||||
							
								
								
									
										12
									
								
								androidxdemo/src/beta/AndroidManifest.xml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								androidxdemo/src/beta/AndroidManifest.xml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,12 @@ | ||||
| <?xml version="1.0" encoding="utf-8"?> | ||||
| <manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||||
|     xmlns:tools="http://schemas.android.com/tools" > | ||||
|  | ||||
|     <application> | ||||
|  | ||||
|         <!-- Put flavor specific code here --> | ||||
|  | ||||
|     </application> | ||||
|  | ||||
| </manifest> | ||||
|  | ||||
							
								
								
									
										6
									
								
								androidxdemo/src/beta/res/values/strings.xml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								androidxdemo/src/beta/res/values/strings.xml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | ||||
| <?xml version="1.0" encoding="utf-8"?> | ||||
| <resources> | ||||
|  | ||||
|     <string name="app_name">AndroidX Demo +</string> | ||||
|  | ||||
| </resources> | ||||
| @@ -10,13 +10,29 @@ | ||||
| 		android:layout_width="match_parent" | ||||
| 		android:layout_height="wrap_content" | ||||
| 		android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"> | ||||
| 		 | ||||
|  | ||||
| 		<androidx.appcompat.widget.Toolbar | ||||
| 			android:id="@+id/toolbar" | ||||
| 			android:layout_width="match_parent" | ||||
| 			android:layout_height="?attr/actionBarSize" | ||||
| 		    app:popupTheme="@style/ThemeOverlay.AppCompat.Light"/> | ||||
| 			app:popupTheme="@style/ThemeOverlay.AppCompat.Light"/> | ||||
|  | ||||
| 	</com.google.android.material.appbar.AppBarLayout> | ||||
|  | ||||
| </LinearLayout> | ||||
| 	<LinearLayout | ||||
| 		android:orientation="vertical" | ||||
| 		android:layout_width="match_parent" | ||||
| 		android:layout_height="0dp" | ||||
| 		android:layout_weight="1.0" | ||||
| 		android:gravity="center_vertical|center_horizontal"> | ||||
|  | ||||
| 		<TextView | ||||
| 			android:layout_width="wrap_content" | ||||
| 			android:layout_height="wrap_content" | ||||
| 			android:text="AndroidX Demo" | ||||
| 			android:textAppearance="?android:attr/textAppearanceLarge"/> | ||||
|  | ||||
| 	</LinearLayout> | ||||
|  | ||||
| </LinearLayout> | ||||
|  | ||||
|   | ||||
| @@ -1,4 +1,4 @@ | ||||
| <resources> | ||||
|     <string name="app_name">AndroidXDemo</string> | ||||
|     <string name="app_name">AndroidX Demo</string> | ||||
|      | ||||
| </resources> | ||||
| </resources> | ||||
|   | ||||
							
								
								
									
										12
									
								
								androidxdemo/src/stage/AndroidManifest.xml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								androidxdemo/src/stage/AndroidManifest.xml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,12 @@ | ||||
| <?xml version="1.0" encoding="utf-8"?> | ||||
| <manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||||
|     xmlns:tools="http://schemas.android.com/tools" > | ||||
|  | ||||
|     <application> | ||||
|  | ||||
|         <!-- Put flavor specific code here --> | ||||
|  | ||||
|     </application> | ||||
|  | ||||
| </manifest> | ||||
|  | ||||
							
								
								
									
										6
									
								
								androidxdemo/src/stage/res/values/strings.xml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								androidxdemo/src/stage/res/values/strings.xml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | ||||
| <?xml version="1.0" encoding="utf-8"?> | ||||
| <resources> | ||||
|  | ||||
|     <!-- Put flavor specific strings here --> | ||||
|  | ||||
| </resources> | ||||
		Reference in New Issue
	
	Block a user
	 ZhanGSKen
					ZhanGSKen