Browse Source

1.创建星火管控app

master
wangwanlei 9 months ago
commit
fa618b71bd
48 changed files with 1258 additions and 0 deletions
  1. 69
    0
      .gitignore
  2. 3
    0
      .idea/.gitignore
  3. 1
    0
      .idea/.name
  4. 123
    0
      .idea/codeStyles/Project.xml
  5. 5
    0
      .idea/codeStyles/codeStyleConfig.xml
  6. 6
    0
      .idea/compiler.xml
  7. 13
    0
      .idea/deploymentTargetDropDown.xml
  8. 13
    0
      .idea/misc.xml
  9. 6
    0
      .idea/vcs.xml
  10. 2
    0
      README.md
  11. 1
    0
      app/.gitignore
  12. 76
    0
      app/build.gradle.kts
  13. 21
    0
      app/proguard-rules.pro
  14. 24
    0
      app/src/androidTest/java/com/xhly/manageapp/ExampleInstrumentedTest.kt
  15. 133
    0
      app/src/main/AndroidManifest.xml
  16. 170
    0
      app/src/main/res/drawable/ic_launcher_background.xml
  17. 30
    0
      app/src/main/res/drawable/ic_launcher_foreground.xml
  18. 6
    0
      app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
  19. 6
    0
      app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml
  20. BIN
      app/src/main/res/mipmap-hdpi/ic_launcher.webp
  21. BIN
      app/src/main/res/mipmap-hdpi/ic_launcher_round.webp
  22. BIN
      app/src/main/res/mipmap-mdpi/ic_launcher.webp
  23. BIN
      app/src/main/res/mipmap-mdpi/ic_launcher_round.webp
  24. BIN
      app/src/main/res/mipmap-xhdpi/ic_launcher.webp
  25. BIN
      app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp
  26. BIN
      app/src/main/res/mipmap-xxhdpi/ic_launcher.webp
  27. BIN
      app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp
  28. BIN
      app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp
  29. BIN
      app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp
  30. 10
    0
      app/src/main/res/values/colors.xml
  31. 19
    0
      app/src/main/res/values/strings.xml
  32. 9
    0
      app/src/main/res/values/themes.xml
  33. 8
    0
      app/src/main/res/xml/accessibility_service_config.xml
  34. 7
    0
      app/src/main/res/xml/file_paths.xml
  35. 4
    0
      app/src/main/res/xml/network_security_config.xml
  36. 17
    0
      app/src/test/java/com/xhly/manageapp/ExampleUnitTest.kt
  37. 8
    0
      build.gradle.kts
  38. 0
    0
      corelib/consumer-rules.pro
  39. 21
    0
      corelib/proguard-rules.pro
  40. 23
    0
      gradle.properties
  41. 98
    0
      gradle/libs.versions.toml
  42. BIN
      gradle/wrapper/gradle-wrapper.jar
  43. 6
    0
      gradle/wrapper/gradle-wrapper.properties
  44. 185
    0
      gradlew
  45. 89
    0
      gradlew.bat
  46. 25
    0
      settings.gradle.kts
  47. 0
    0
      websocket/consumer-rules.pro
  48. 21
    0
      websocket/proguard-rules.pro

+ 69
- 0
.gitignore View File

@@ -0,0 +1,69 @@
1
+# ---> Android
2
+# Built application files
3
+*.apk
4
+*.ap_
5
+*.aab
6
+
7
+# Files for the ART/Dalvik VM
8
+*.dex
9
+
10
+# Java class files
11
+*.class
12
+
13
+# Generated files
14
+bin/
15
+gen/
16
+out/
17
+
18
+# Gradle files
19
+.gradle/
20
+build/
21
+
22
+# Local configuration file (sdk path, etc)
23
+local.properties
24
+
25
+# Proguard folder generated by Eclipse
26
+proguard/
27
+
28
+# Log Files
29
+*.log
30
+
31
+# Android Studio Navigation editor temp files
32
+.navigation/
33
+
34
+# Android Studio captures folder
35
+captures/
36
+
37
+# IntelliJ
38
+*.iml
39
+.idea/workspace.xml
40
+.idea/tasks.xml
41
+.idea/gradle.xml
42
+.idea/assetWizardSettings.xml
43
+.idea/dictionaries
44
+.idea/libraries
45
+.idea/caches
46
+
47
+# Keystore files
48
+# Uncomment the following lines if you do not want to check your keystore files in.
49
+#*.jks
50
+#*.keystore
51
+
52
+# External native build folder generated in Android Studio 2.2 and later
53
+.externalNativeBuild
54
+
55
+# Google Services (e.g. APIs or Firebase)
56
+google-services.json
57
+
58
+# Freeline
59
+freeline.py
60
+freeline/
61
+freeline_project_description.json
62
+
63
+# fastlane
64
+fastlane/report.xml
65
+fastlane/Preview.html
66
+fastlane/screenshots
67
+fastlane/test_output
68
+fastlane/readme.md
69
+

+ 3
- 0
.idea/.gitignore View File

@@ -0,0 +1,3 @@
1
+# Default ignored files
2
+/shelf/
3
+/workspace.xml

+ 1
- 0
.idea/.name View File

@@ -0,0 +1 @@
1
+XhlyManageApp

+ 123
- 0
.idea/codeStyles/Project.xml View File

@@ -0,0 +1,123 @@
1
+<component name="ProjectCodeStyleConfiguration">
2
+  <code_scheme name="Project" version="173">
3
+    <JetCodeStyleSettings>
4
+      <option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
5
+    </JetCodeStyleSettings>
6
+    <codeStyleSettings language="XML">
7
+      <option name="FORCE_REARRANGE_MODE" value="1" />
8
+      <indentOptions>
9
+        <option name="CONTINUATION_INDENT_SIZE" value="4" />
10
+      </indentOptions>
11
+      <arrangement>
12
+        <rules>
13
+          <section>
14
+            <rule>
15
+              <match>
16
+                <AND>
17
+                  <NAME>xmlns:android</NAME>
18
+                  <XML_ATTRIBUTE />
19
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
20
+                </AND>
21
+              </match>
22
+            </rule>
23
+          </section>
24
+          <section>
25
+            <rule>
26
+              <match>
27
+                <AND>
28
+                  <NAME>xmlns:.*</NAME>
29
+                  <XML_ATTRIBUTE />
30
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
31
+                </AND>
32
+              </match>
33
+              <order>BY_NAME</order>
34
+            </rule>
35
+          </section>
36
+          <section>
37
+            <rule>
38
+              <match>
39
+                <AND>
40
+                  <NAME>.*:id</NAME>
41
+                  <XML_ATTRIBUTE />
42
+                  <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
43
+                </AND>
44
+              </match>
45
+            </rule>
46
+          </section>
47
+          <section>
48
+            <rule>
49
+              <match>
50
+                <AND>
51
+                  <NAME>.*:name</NAME>
52
+                  <XML_ATTRIBUTE />
53
+                  <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
54
+                </AND>
55
+              </match>
56
+            </rule>
57
+          </section>
58
+          <section>
59
+            <rule>
60
+              <match>
61
+                <AND>
62
+                  <NAME>name</NAME>
63
+                  <XML_ATTRIBUTE />
64
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
65
+                </AND>
66
+              </match>
67
+            </rule>
68
+          </section>
69
+          <section>
70
+            <rule>
71
+              <match>
72
+                <AND>
73
+                  <NAME>style</NAME>
74
+                  <XML_ATTRIBUTE />
75
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
76
+                </AND>
77
+              </match>
78
+            </rule>
79
+          </section>
80
+          <section>
81
+            <rule>
82
+              <match>
83
+                <AND>
84
+                  <NAME>.*</NAME>
85
+                  <XML_ATTRIBUTE />
86
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
87
+                </AND>
88
+              </match>
89
+              <order>BY_NAME</order>
90
+            </rule>
91
+          </section>
92
+          <section>
93
+            <rule>
94
+              <match>
95
+                <AND>
96
+                  <NAME>.*</NAME>
97
+                  <XML_ATTRIBUTE />
98
+                  <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
99
+                </AND>
100
+              </match>
101
+              <order>ANDROID_ATTRIBUTE_ORDER</order>
102
+            </rule>
103
+          </section>
104
+          <section>
105
+            <rule>
106
+              <match>
107
+                <AND>
108
+                  <NAME>.*</NAME>
109
+                  <XML_ATTRIBUTE />
110
+                  <XML_NAMESPACE>.*</XML_NAMESPACE>
111
+                </AND>
112
+              </match>
113
+              <order>BY_NAME</order>
114
+            </rule>
115
+          </section>
116
+        </rules>
117
+      </arrangement>
118
+    </codeStyleSettings>
119
+    <codeStyleSettings language="kotlin">
120
+      <option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
121
+    </codeStyleSettings>
122
+  </code_scheme>
123
+</component>

+ 5
- 0
.idea/codeStyles/codeStyleConfig.xml View File

@@ -0,0 +1,5 @@
1
+<component name="ProjectCodeStyleConfiguration">
2
+  <state>
3
+    <option name="USE_PER_PROJECT_SETTINGS" value="true" />
4
+  </state>
5
+</component>

+ 6
- 0
.idea/compiler.xml View File

@@ -0,0 +1,6 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="CompilerConfiguration">
4
+    <bytecodeTargetLevel target="17" />
5
+  </component>
6
+</project>

+ 13
- 0
.idea/deploymentTargetDropDown.xml View File

@@ -0,0 +1,13 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="deploymentTargetDropDown">
4
+    <value>
5
+      <entry key="app">
6
+        <State />
7
+      </entry>
8
+      <entry key="corelib">
9
+        <State />
10
+      </entry>
11
+    </value>
12
+  </component>
13
+</project>

+ 13
- 0
.idea/misc.xml View File

@@ -0,0 +1,13 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="ExternalStorageConfigurationManager" enabled="true" />
4
+  <component name="ProjectRootManager" version="2" languageLevel="JDK_17" default="true" project-jdk-name="jbr-17" project-jdk-type="JavaSDK">
5
+    <output url="file://$PROJECT_DIR$/build/classes" />
6
+  </component>
7
+  <component name="ProjectType">
8
+    <option name="id" value="Android" />
9
+  </component>
10
+  <component name="SuppressKotlinCodeStyleNotification">
11
+    <option name="disableForAll" value="true" />
12
+  </component>
13
+</project>

+ 6
- 0
.idea/vcs.xml View File

@@ -0,0 +1,6 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="VcsDirectoryMappings">
4
+    <mapping directory="$PROJECT_DIR$" vcs="Git" />
5
+  </component>
6
+</project>

+ 2
- 0
README.md View File

@@ -0,0 +1,2 @@
1
+# xh_control_app
2
+

+ 1
- 0
app/.gitignore View File

@@ -0,0 +1 @@
1
+/build

+ 76
- 0
app/build.gradle.kts View File

@@ -0,0 +1,76 @@
1
+@Suppress("DSL_SCOPE_VIOLATION") // TODO: Remove once KTIJ-19369 is fixed
2
+plugins {
3
+    alias(libs.plugins.androidApplication)
4
+    alias(libs.plugins.kotlinAndroid)
5
+}
6
+
7
+android {
8
+    namespace = "com.xhly.manageapp"
9
+    compileSdk = 34
10
+
11
+    defaultConfig {
12
+        applicationId = "com.xhly.manageapp"
13
+        minSdk = 24
14
+        targetSdk = 30
15
+        versionCode = 1
16
+        versionName = "1.0"
17
+
18
+        testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
19
+        vectorDrawables {
20
+            useSupportLibrary = true
21
+        }
22
+    }
23
+    viewBinding{
24
+        enable=true
25
+    }
26
+    buildTypes {
27
+        release {
28
+            isMinifyEnabled = false
29
+            proguardFiles(
30
+                getDefaultProguardFile("proguard-android-optimize.txt"),
31
+                "proguard-rules.pro"
32
+            )
33
+        }
34
+    }
35
+    compileOptions {
36
+        sourceCompatibility = JavaVersion.VERSION_1_8
37
+        targetCompatibility = JavaVersion.VERSION_1_8
38
+    }
39
+    kotlinOptions {
40
+        jvmTarget = "1.8"
41
+    }
42
+    buildFeatures {
43
+        compose = true
44
+    }
45
+    composeOptions {
46
+        kotlinCompilerExtensionVersion = "1.4.3"
47
+    }
48
+    packaging {
49
+        resources {
50
+            excludes += "/META-INF/{AL2.0,LGPL2.1}"
51
+        }
52
+    }
53
+}
54
+
55
+dependencies {
56
+
57
+    implementation(libs.core.ktx)
58
+    implementation(libs.lifecycle.runtime.ktx)
59
+    implementation(libs.activity.compose)
60
+    implementation(platform(libs.compose.bom))
61
+    implementation(libs.ui)
62
+    implementation(libs.ui.graphics)
63
+    implementation(libs.ui.tooling.preview)
64
+    implementation(libs.material3)
65
+    implementation(libs.appcompat)
66
+    implementation(libs.androidx.recyclerview)
67
+    implementation(project(mapOf("path" to ":websocket")))
68
+    implementation(libs.androidx.cardview)
69
+    testImplementation(libs.junit)
70
+    androidTestImplementation(libs.androidx.test.ext.junit)
71
+    androidTestImplementation(libs.espresso.core)
72
+    androidTestImplementation(platform(libs.compose.bom))
73
+    androidTestImplementation(libs.ui.test.junit4)
74
+    debugImplementation(libs.ui.tooling)
75
+    debugImplementation(libs.ui.test.manifest)
76
+}

+ 21
- 0
app/proguard-rules.pro View File

@@ -0,0 +1,21 @@
1
+# Add project specific ProGuard rules here.
2
+# You can control the set of applied configuration files using the
3
+# proguardFiles setting in build.gradle.
4
+#
5
+# For more details, see
6
+#   http://developer.android.com/guide/developing/tools/proguard.html
7
+
8
+# If your project uses WebView with JS, uncomment the following
9
+# and specify the fully qualified class name to the JavaScript interface
10
+# class:
11
+#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12
+#   public *;
13
+#}
14
+
15
+# Uncomment this to preserve the line number information for
16
+# debugging stack traces.
17
+#-keepattributes SourceFile,LineNumberTable
18
+
19
+# If you keep the line number information, uncomment this to
20
+# hide the original source file name.
21
+#-renamesourcefileattribute SourceFile

+ 24
- 0
app/src/androidTest/java/com/xhly/manageapp/ExampleInstrumentedTest.kt View File

@@ -0,0 +1,24 @@
1
+package com.xhly.manageapp
2
+
3
+import androidx.test.platform.app.InstrumentationRegistry
4
+import androidx.test.ext.junit.runners.AndroidJUnit4
5
+
6
+import org.junit.Test
7
+import org.junit.runner.RunWith
8
+
9
+import org.junit.Assert.*
10
+
11
+/**
12
+ * Instrumented test, which will execute on an Android device.
13
+ *
14
+ * See [testing documentation](http://d.android.com/tools/testing).
15
+ */
16
+@RunWith(AndroidJUnit4::class)
17
+class ExampleInstrumentedTest {
18
+    @Test
19
+    fun useAppContext() {
20
+        // Context of the app under test.
21
+        val appContext = InstrumentationRegistry.getInstrumentation().targetContext
22
+        assertEquals("com.xhly.manageapp", appContext.packageName)
23
+    }
24
+}

+ 133
- 0
app/src/main/AndroidManifest.xml View File

@@ -0,0 +1,133 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
3
+    xmlns:tools="http://schemas.android.com/tools">
4
+
5
+    <uses-permission android:name="android.permission.INTERNET" />
6
+    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
7
+    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
8
+    <uses-permission
9
+        android:name="android.permission.QUERY_ALL_PACKAGES"
10
+        tools:ignore="QueryAllPackagesPermission" />
11
+    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
12
+    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
13
+    <uses-permission android:name="android.permission.PACKAGE_USAGE_STATS" />
14
+
15
+    <uses-feature android:name="android.hardware.usb.host" />
16
+    <uses-permission android:name="android.permission.USB_PERMISSION" />
17
+    <!--重启包-->
18
+    <uses-permission android:name="android.permission.RESTART_PACKAGES" />
19
+    <!--接收启动完成-->
20
+    <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
21
+    <uses-permission android:name="android.permission.BLUETOOTH" />
22
+    <uses-permission android:name="android.permission.BLUETOOTH_ADMIN" />
23
+    <uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" />
24
+
25
+    <application
26
+        android:name=".ManageApplication"
27
+        android:allowBackup="true"
28
+        android:dataExtractionRules="@xml/data_extraction_rules"
29
+        android:fullBackupContent="@xml/backup_rules"
30
+        android:icon="@mipmap/ic_launcher"
31
+        android:label="@string/app_name"
32
+        android:roundIcon="@mipmap/ic_launcher_round"
33
+        android:networkSecurityConfig="@xml/network_security_config"
34
+        android:supportsRtl="true"
35
+        android:theme="@style/MyStyle"
36
+        tools:targetApi="31">
37
+        <meta-data
38
+            android:name="design_width_in_dp"
39
+            android:value="853" />
40
+        <meta-data
41
+            android:name="design_height_in_dp"
42
+            android:value="667" /> <!-- 全局内容提供者 -->
43
+        <activity
44
+            android:name=".ui.MainActivity"
45
+            android:exported="true"
46
+            android:launchMode="singleTask"
47
+            android:screenOrientation="landscape">
48
+            <intent-filter>
49
+                <category android:name="android.intent.category.HOME" />
50
+                <category android:name="android.intent.category.DEFAULT" />
51
+
52
+                <action android:name="android.intent.action.MAIN" />
53
+                <category android:name="android.intent.category.LAUNCHER" />
54
+            </intent-filter>
55
+        </activity>
56
+        <activity
57
+            android:name="com.xhly.manageapp.ui.ManageActivity"
58
+            android:screenOrientation="landscape" />
59
+        <activity
60
+            android:name=".ui.login.activity.LoginActivity"
61
+            android:launchMode="singleTask"
62
+            android:screenOrientation="landscape"
63
+            android:windowSoftInputMode="adjustResize"
64
+            />
65
+
66
+        <receiver
67
+            android:name=".broadcastreceiver.XhlyBroadCastReceiver"
68
+            android:enabled="true"
69
+            android:exported="true">
70
+            <intent-filter>
71
+               <!-- <action android:name="com.linspirer.edu.loginapkfinish" /-->
72
+                <action android:name="test" />
73
+            </intent-filter>
74
+        </receiver>
75
+        <receiver
76
+            android:name=".broadcastreceiver.USBReceiver"
77
+            android:enabled="true"
78
+            android:exported="true">
79
+            <intent-filter android:priority="1000">
80
+                <action android:name="android.hardware.usb.action.USB_STATE" />
81
+            </intent-filter>
82
+        </receiver>
83
+        <receiver
84
+            android:name=".broadcastreceiver.BLEStateReceiver"
85
+            android:enabled="true"
86
+            android:exported="true">
87
+            <intent-filter android:priority="1000">
88
+                <action android:name="android.bluetooth.adapter.action.STATE_CHANGED" />
89
+                <action android:name="android.bluetooth.BluetoothAdapter.STATE_OFF" />
90
+                <action android:name="android.bluetooth.BluetoothAdapter.STATE_ON" />
91
+            </intent-filter>
92
+        </receiver>
93
+        <!--     &lt;!&ndash;覆盖安装清理数据广播——————————————————————————————————————————————————————————&ndash;&gt;
94
+             <receiver
95
+                 android:name=".broadcastreceiver.AppInstallReceiver"
96
+                 android:enabled="true"
97
+                 android:exported="true">
98
+                 <intent-filter android:priority="1000">
99
+                     &lt;!&ndash; 一个新应用包已经安装在设备上,数据包括包名(监听所在的app,新安装时,不能接收到这个广播) &ndash;&gt;
100
+                     <action android:name="android.intent.action.PACKAGE_ADDED" />
101
+                     &lt;!&ndash; 一个新版本的应用安装到设备,替换之前已经存在的版本  替换时会先收到卸载的再收到替换的, 替换自身也能收到&ndash;&gt;
102
+                     <action android:name="android.intent.action.PACKAGE_REPLACED" />
103
+                     &lt;!&ndash; 一个已存在的应用程序包已经从设备上移除,包括包名(卸载监听所在的app,则无法接收到) &ndash;&gt;
104
+                     <action android:name="android.intent.action.PACKAGE_REMOVED" />
105
+                     <data android:scheme="package" />
106
+                 </intent-filter>
107
+             </receiver>-->
108
+
109
+        <service
110
+            android:name=".service.TestService"
111
+            android:exported="true"
112
+            android:permission="android.permission.BIND_ACCESSIBILITY_SERVICE">
113
+            <intent-filter>
114
+                <action android:name="android.accessibilityservice.AccessibilityService" />
115
+            </intent-filter>
116
+            <meta-data
117
+                android:name="android.accessibilityservice"
118
+                android:resource="@xml/accessibility_service_config" />
119
+        </service>
120
+
121
+        <provider
122
+            android:name="androidx.core.content.FileProvider"
123
+            android:authorities="com.xhly.manageapp.fileprovider"
124
+            android:exported="false"
125
+            android:grantUriPermissions="true">
126
+            <!-- 元数据 -->
127
+            <meta-data
128
+                android:name="android.support.FILE_PROVIDER_PATHS"
129
+                android:resource="@xml/file_paths" />
130
+        </provider>
131
+    </application>
132
+
133
+</manifest>

+ 170
- 0
app/src/main/res/drawable/ic_launcher_background.xml View File

@@ -0,0 +1,170 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
3
+    android:width="108dp"
4
+    android:height="108dp"
5
+    android:viewportWidth="108"
6
+    android:viewportHeight="108">
7
+    <path
8
+        android:fillColor="#3DDC84"
9
+        android:pathData="M0,0h108v108h-108z" />
10
+    <path
11
+        android:fillColor="#00000000"
12
+        android:pathData="M9,0L9,108"
13
+        android:strokeWidth="0.8"
14
+        android:strokeColor="#33FFFFFF" />
15
+    <path
16
+        android:fillColor="#00000000"
17
+        android:pathData="M19,0L19,108"
18
+        android:strokeWidth="0.8"
19
+        android:strokeColor="#33FFFFFF" />
20
+    <path
21
+        android:fillColor="#00000000"
22
+        android:pathData="M29,0L29,108"
23
+        android:strokeWidth="0.8"
24
+        android:strokeColor="#33FFFFFF" />
25
+    <path
26
+        android:fillColor="#00000000"
27
+        android:pathData="M39,0L39,108"
28
+        android:strokeWidth="0.8"
29
+        android:strokeColor="#33FFFFFF" />
30
+    <path
31
+        android:fillColor="#00000000"
32
+        android:pathData="M49,0L49,108"
33
+        android:strokeWidth="0.8"
34
+        android:strokeColor="#33FFFFFF" />
35
+    <path
36
+        android:fillColor="#00000000"
37
+        android:pathData="M59,0L59,108"
38
+        android:strokeWidth="0.8"
39
+        android:strokeColor="#33FFFFFF" />
40
+    <path
41
+        android:fillColor="#00000000"
42
+        android:pathData="M69,0L69,108"
43
+        android:strokeWidth="0.8"
44
+        android:strokeColor="#33FFFFFF" />
45
+    <path
46
+        android:fillColor="#00000000"
47
+        android:pathData="M79,0L79,108"
48
+        android:strokeWidth="0.8"
49
+        android:strokeColor="#33FFFFFF" />
50
+    <path
51
+        android:fillColor="#00000000"
52
+        android:pathData="M89,0L89,108"
53
+        android:strokeWidth="0.8"
54
+        android:strokeColor="#33FFFFFF" />
55
+    <path
56
+        android:fillColor="#00000000"
57
+        android:pathData="M99,0L99,108"
58
+        android:strokeWidth="0.8"
59
+        android:strokeColor="#33FFFFFF" />
60
+    <path
61
+        android:fillColor="#00000000"
62
+        android:pathData="M0,9L108,9"
63
+        android:strokeWidth="0.8"
64
+        android:strokeColor="#33FFFFFF" />
65
+    <path
66
+        android:fillColor="#00000000"
67
+        android:pathData="M0,19L108,19"
68
+        android:strokeWidth="0.8"
69
+        android:strokeColor="#33FFFFFF" />
70
+    <path
71
+        android:fillColor="#00000000"
72
+        android:pathData="M0,29L108,29"
73
+        android:strokeWidth="0.8"
74
+        android:strokeColor="#33FFFFFF" />
75
+    <path
76
+        android:fillColor="#00000000"
77
+        android:pathData="M0,39L108,39"
78
+        android:strokeWidth="0.8"
79
+        android:strokeColor="#33FFFFFF" />
80
+    <path
81
+        android:fillColor="#00000000"
82
+        android:pathData="M0,49L108,49"
83
+        android:strokeWidth="0.8"
84
+        android:strokeColor="#33FFFFFF" />
85
+    <path
86
+        android:fillColor="#00000000"
87
+        android:pathData="M0,59L108,59"
88
+        android:strokeWidth="0.8"
89
+        android:strokeColor="#33FFFFFF" />
90
+    <path
91
+        android:fillColor="#00000000"
92
+        android:pathData="M0,69L108,69"
93
+        android:strokeWidth="0.8"
94
+        android:strokeColor="#33FFFFFF" />
95
+    <path
96
+        android:fillColor="#00000000"
97
+        android:pathData="M0,79L108,79"
98
+        android:strokeWidth="0.8"
99
+        android:strokeColor="#33FFFFFF" />
100
+    <path
101
+        android:fillColor="#00000000"
102
+        android:pathData="M0,89L108,89"
103
+        android:strokeWidth="0.8"
104
+        android:strokeColor="#33FFFFFF" />
105
+    <path
106
+        android:fillColor="#00000000"
107
+        android:pathData="M0,99L108,99"
108
+        android:strokeWidth="0.8"
109
+        android:strokeColor="#33FFFFFF" />
110
+    <path
111
+        android:fillColor="#00000000"
112
+        android:pathData="M19,29L89,29"
113
+        android:strokeWidth="0.8"
114
+        android:strokeColor="#33FFFFFF" />
115
+    <path
116
+        android:fillColor="#00000000"
117
+        android:pathData="M19,39L89,39"
118
+        android:strokeWidth="0.8"
119
+        android:strokeColor="#33FFFFFF" />
120
+    <path
121
+        android:fillColor="#00000000"
122
+        android:pathData="M19,49L89,49"
123
+        android:strokeWidth="0.8"
124
+        android:strokeColor="#33FFFFFF" />
125
+    <path
126
+        android:fillColor="#00000000"
127
+        android:pathData="M19,59L89,59"
128
+        android:strokeWidth="0.8"
129
+        android:strokeColor="#33FFFFFF" />
130
+    <path
131
+        android:fillColor="#00000000"
132
+        android:pathData="M19,69L89,69"
133
+        android:strokeWidth="0.8"
134
+        android:strokeColor="#33FFFFFF" />
135
+    <path
136
+        android:fillColor="#00000000"
137
+        android:pathData="M19,79L89,79"
138
+        android:strokeWidth="0.8"
139
+        android:strokeColor="#33FFFFFF" />
140
+    <path
141
+        android:fillColor="#00000000"
142
+        android:pathData="M29,19L29,89"
143
+        android:strokeWidth="0.8"
144
+        android:strokeColor="#33FFFFFF" />
145
+    <path
146
+        android:fillColor="#00000000"
147
+        android:pathData="M39,19L39,89"
148
+        android:strokeWidth="0.8"
149
+        android:strokeColor="#33FFFFFF" />
150
+    <path
151
+        android:fillColor="#00000000"
152
+        android:pathData="M49,19L49,89"
153
+        android:strokeWidth="0.8"
154
+        android:strokeColor="#33FFFFFF" />
155
+    <path
156
+        android:fillColor="#00000000"
157
+        android:pathData="M59,19L59,89"
158
+        android:strokeWidth="0.8"
159
+        android:strokeColor="#33FFFFFF" />
160
+    <path
161
+        android:fillColor="#00000000"
162
+        android:pathData="M69,19L69,89"
163
+        android:strokeWidth="0.8"
164
+        android:strokeColor="#33FFFFFF" />
165
+    <path
166
+        android:fillColor="#00000000"
167
+        android:pathData="M79,19L79,89"
168
+        android:strokeWidth="0.8"
169
+        android:strokeColor="#33FFFFFF" />
170
+</vector>

+ 30
- 0
app/src/main/res/drawable/ic_launcher_foreground.xml View File

@@ -0,0 +1,30 @@
1
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
2
+    xmlns:aapt="http://schemas.android.com/aapt"
3
+    android:width="108dp"
4
+    android:height="108dp"
5
+    android:viewportWidth="108"
6
+    android:viewportHeight="108">
7
+    <path android:pathData="M31,63.928c0,0 6.4,-11 12.1,-13.1c7.2,-2.6 26,-1.4 26,-1.4l38.1,38.1L107,108.928l-32,-1L31,63.928z">
8
+        <aapt:attr name="android:fillColor">
9
+            <gradient
10
+                android:endX="85.84757"
11
+                android:endY="92.4963"
12
+                android:startX="42.9492"
13
+                android:startY="49.59793"
14
+                android:type="linear">
15
+                <item
16
+                    android:color="#44000000"
17
+                    android:offset="0.0" />
18
+                <item
19
+                    android:color="#00000000"
20
+                    android:offset="1.0" />
21
+            </gradient>
22
+        </aapt:attr>
23
+    </path>
24
+    <path
25
+        android:fillColor="#FFFFFF"
26
+        android:fillType="nonZero"
27
+        android:pathData="M65.3,45.828l3.8,-6.6c0.2,-0.4 0.1,-0.9 -0.3,-1.1c-0.4,-0.2 -0.9,-0.1 -1.1,0.3l-3.9,6.7c-6.3,-2.8 -13.4,-2.8 -19.7,0l-3.9,-6.7c-0.2,-0.4 -0.7,-0.5 -1.1,-0.3C38.8,38.328 38.7,38.828 38.9,39.228l3.8,6.6C36.2,49.428 31.7,56.028 31,63.928h46C76.3,56.028 71.8,49.428 65.3,45.828zM43.4,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2c-0.3,-0.7 -0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C45.3,56.528 44.5,57.328 43.4,57.328L43.4,57.328zM64.6,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2s-0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C66.5,56.528 65.6,57.328 64.6,57.328L64.6,57.328z"
28
+        android:strokeWidth="1"
29
+        android:strokeColor="#00000000" />
30
+</vector>

+ 6
- 0
app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml View File

@@ -0,0 +1,6 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
3
+    <background android:drawable="@drawable/ic_launcher_background" />
4
+    <foreground android:drawable="@drawable/ic_launcher_foreground" />
5
+    <monochrome android:drawable="@drawable/ic_launcher_foreground" />
6
+</adaptive-icon>

+ 6
- 0
app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml View File

@@ -0,0 +1,6 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
3
+    <background android:drawable="@drawable/ic_launcher_background" />
4
+    <foreground android:drawable="@drawable/ic_launcher_foreground" />
5
+    <monochrome android:drawable="@drawable/ic_launcher_foreground" />
6
+</adaptive-icon>

BIN
app/src/main/res/mipmap-hdpi/ic_launcher.webp View File


BIN
app/src/main/res/mipmap-hdpi/ic_launcher_round.webp View File


BIN
app/src/main/res/mipmap-mdpi/ic_launcher.webp View File


BIN
app/src/main/res/mipmap-mdpi/ic_launcher_round.webp View File


BIN
app/src/main/res/mipmap-xhdpi/ic_launcher.webp View File


BIN
app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp View File


BIN
app/src/main/res/mipmap-xxhdpi/ic_launcher.webp View File


BIN
app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp View File


BIN
app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp View File


BIN
app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp View File


+ 10
- 0
app/src/main/res/values/colors.xml View File

@@ -0,0 +1,10 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<resources>
3
+    <color name="purple_200">#FFBB86FC</color>
4
+    <color name="purple_500">#FF6200EE</color>
5
+    <color name="purple_700">#FF3700B3</color>
6
+    <color name="teal_200">#FF03DAC5</color>
7
+    <color name="teal_700">#FF018786</color>
8
+    <color name="black">#FF000000</color>
9
+    <color name="white">#FFFFFFFF</color>
10
+</resources>

+ 19
- 0
app/src/main/res/values/strings.xml View File

@@ -0,0 +1,19 @@
1
+<resources>
2
+    <string name="app_name">XhlyManageApp</string>
3
+    <string name="stoptips">已被禁用,无法操作</string>
4
+    <string name="inputaccount">请输入账号</string>
5
+    <string name="inputcode">请输入密码</string>
6
+    <string name="inputregioncode">请输入区域码</string>
7
+    <string name="login">立即登录</string>
8
+    <string name="regioncode">区域码</string>
9
+    <string name="cancel">取消</string>
10
+    <string name="enter">确定</string>
11
+    <string name="psw_style">abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789</string>
12
+    <string name="loginnow">立即登录</string>
13
+    <string name="accountnoempty">账号不能为空</string>
14
+    <string name="codenoempty">密码不能为空</string>
15
+    <string name="exit">退出</string>
16
+    <string name="close">关闭</string>
17
+    <string name="clear">清除缓存</string>
18
+    <string name="speed">一键加速</string>
19
+</resources>

+ 9
- 0
app/src/main/res/values/themes.xml View File

@@ -0,0 +1,9 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<resources>
3
+
4
+    <style name="Theme.XhlyManageApp" parent="android:Theme.Material.Light.NoActionBar" />
5
+    <style name="MyStyle" parent="Theme.AppCompat.NoActionBar">
6
+      <item name="android:overScrollMode">never</item>
7
+      <item name="android:windowBackground">@color/white</item>
8
+    </style>
9
+</resources>

+ 8
- 0
app/src/main/res/xml/accessibility_service_config.xml View File

@@ -0,0 +1,8 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<accessibility-service xmlns:android="http://schemas.android.com/apk/res/android"
3
+    android:accessibilityEventTypes="typeAllMask"
4
+    android:accessibilityFeedbackType="feedbackSpoken"
5
+    android:accessibilityFlags="flagDefault"
6
+    android:canRetrieveWindowContent="true"
7
+    android:description="@string/app_name"
8
+    android:notificationTimeout="100" /><!--   android:settingsActivity="com.example.android.accessibility.ServiceSettingsActivity"-->

+ 7
- 0
app/src/main/res/xml/file_paths.xml View File

@@ -0,0 +1,7 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<resources>
3
+    <paths>
4
+        <external-path path="Android/data/com.example.iu/" name="files_root" />
5
+        <external-path path="." name="external_storage_root" />
6
+    </paths>
7
+</resources>

+ 4
- 0
app/src/main/res/xml/network_security_config.xml View File

@@ -0,0 +1,4 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<network-security-config >
3
+    <base-config cleartextTrafficPermitted="true" />
4
+</network-security-config>

+ 17
- 0
app/src/test/java/com/xhly/manageapp/ExampleUnitTest.kt View File

@@ -0,0 +1,17 @@
1
+package com.xhly.manageapp
2
+
3
+import org.junit.Test
4
+
5
+import org.junit.Assert.*
6
+
7
+/**
8
+ * Example local unit test, which will execute on the development machine (host).
9
+ *
10
+ * See [testing documentation](http://d.android.com/tools/testing).
11
+ */
12
+class ExampleUnitTest {
13
+    @Test
14
+    fun addition_isCorrect() {
15
+        assertEquals(4, 2 + 2)
16
+    }
17
+}

+ 8
- 0
build.gradle.kts View File

@@ -0,0 +1,8 @@
1
+// Top-level build file where you can add configuration options common to all sub-projects/modules.
2
+@Suppress("DSL_SCOPE_VIOLATION") // TODO: Remove once KTIJ-19369 is fixed
3
+plugins {
4
+    alias(libs.plugins.androidApplication) apply false
5
+    alias(libs.plugins.kotlinAndroid) apply false
6
+    alias(libs.plugins.androidLibrary) apply false
7
+}
8
+true // Needed to make the Suppress annotation work for the plugins block

+ 0
- 0
corelib/consumer-rules.pro View File


+ 21
- 0
corelib/proguard-rules.pro View File

@@ -0,0 +1,21 @@
1
+# Add project specific ProGuard rules here.
2
+# You can control the set of applied configuration files using the
3
+# proguardFiles setting in build.gradle.
4
+#
5
+# For more details, see
6
+#   http://developer.android.com/guide/developing/tools/proguard.html
7
+
8
+# If your project uses WebView with JS, uncomment the following
9
+# and specify the fully qualified class name to the JavaScript interface
10
+# class:
11
+#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12
+#   public *;
13
+#}
14
+
15
+# Uncomment this to preserve the line number information for
16
+# debugging stack traces.
17
+#-keepattributes SourceFile,LineNumberTable
18
+
19
+# If you keep the line number information, uncomment this to
20
+# hide the original source file name.
21
+#-renamesourcefileattribute SourceFile

+ 23
- 0
gradle.properties View File

@@ -0,0 +1,23 @@
1
+# Project-wide Gradle settings.
2
+# IDE (e.g. Android Studio) users:
3
+# Gradle settings configured through the IDE *will override*
4
+# any settings specified in this file.
5
+# For more details on how to configure your build environment visit
6
+# http://www.gradle.org/docs/current/userguide/build_environment.html
7
+# Specifies the JVM arguments used for the daemon process.
8
+# The setting is particularly useful for tweaking memory settings.
9
+org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
10
+# When configured, Gradle will run in incubating parallel mode.
11
+# This option should only be used with decoupled projects. More details, visit
12
+# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
13
+# org.gradle.parallel=true
14
+# AndroidX package structure to make it clearer which packages are bundled with the
15
+# Android operating system, and which are packaged with your app's APK
16
+# https://developer.android.com/topic/libraries/support-library/androidx-rn
17
+android.useAndroidX=true
18
+# Kotlin code style for this project: "official" or "obsolete":
19
+kotlin.code.style=official
20
+# Enables namespacing of each library's R class so that its R class includes only the
21
+# resources declared in the library itself and none from the library's dependencies,
22
+# thereby reducing the size of the R class for that library
23
+android.nonTransitiveRClass=true

+ 98
- 0
gradle/libs.versions.toml View File

@@ -0,0 +1,98 @@
1
+[versions]
2
+agp = "8.2.0-alpha06"
3
+androidautosize = "v1.2.1"
4
+com-jakewharton-retrofit-retrofit2-kotlin-coroutines-adapter2 = "0.9.2"
5
+com-squareup-okhttp3-logging-interceptor2 = "4.9.3"
6
+com-squareup-retrofit2-converter-scalars2 = "2.9.0"
7
+com-squareup-retrofit2-converter-gson2 = "2.9.0"
8
+com-squareup-retrofit2-adapter-rxjava22 = "2.5.0"
9
+com-squareup-retrofit2-retrofit2 = "2.9.0"
10
+constraintlayoutversion = "2.2.0-alpha13"
11
+dialogxversion = "0.0.48"
12
+eventbus = "3.3.1"
13
+kotlin = "1.8.10"
14
+core-ktx = "1.12.0"
15
+junit = "4.13.2"
16
+androidx-test-ext-junit = "1.1.5"
17
+espresso-core = "3.5.1"
18
+activity-compose = "1.8.1"
19
+compose-bom = "2023.03.00"
20
+appcompat = "1.6.1"
21
+
22
+lifecycle-viewmodel-ktx = "2.7.0"
23
+androidx-lifecycle-livedata-ktx = "2.7.0"
24
+lifecycle-runtime-ktx = "2.7.0"
25
+material = "1.11.0"
26
+org-jetbrains-kotlinx-kotlinx-coroutines-android2 = "1.8.0"
27
+org-jetbrains-kotlinx-kotlinx-coroutines-core2 = "1.8.0"
28
+multidex = "2.0.1"
29
+recyclerview = "1.3.2"
30
+refresh-layout-kernel = "2.0.6"
31
+rxpermissions = "0.10.2"
32
+rxjava = "2.2.8"
33
+rxandroid = "2.1.1"
34
+gittoaster = "12.3"
35
+adapterhelper = "3.0.4"
36
+cardview = "1.0.0"
37
+
38
+[libraries]
39
+
40
+
41
+androidx-constraintlayout = { module = "androidx.constraintlayout:constraintlayout", version.ref = "constraintlayoutversion" }
42
+androidx-lifecycle-viewmodel-ktx = { module = "androidx.lifecycle:lifecycle-viewmodel-ktx", version.ref = "lifecycle-viewmodel-ktx" }
43
+com-jakewharton-retrofit-retrofit2-kotlin-coroutines-adapter2 = { module = "com.jakewharton.retrofit:retrofit2-kotlin-coroutines-adapter", version.ref = "com-jakewharton-retrofit-retrofit2-kotlin-coroutines-adapter2" }
44
+com-squareup-okhttp3-logging-interceptor = { module = "com.squareup.okhttp3:logging-interceptor", version.ref = "com-squareup-okhttp3-logging-interceptor2" }
45
+com-squareup-retrofit2-converter-scalars = { module = "com.squareup.retrofit2:converter-scalars", version.ref = "com-squareup-retrofit2-converter-scalars2" }
46
+com-squareup-retrofit2-converter-gson = { module = "com.squareup.retrofit2:converter-gson", version.ref = "com-squareup-retrofit2-converter-gson2" }
47
+com-squareup-retrofit2-adapter-rxjava2 = { module = "com.squareup.retrofit2:adapter-rxjava2", version.ref = "com-squareup-retrofit2-adapter-rxjava22" }
48
+com-squareup-retrofit2-retrofit = { module = "com.squareup.retrofit2:retrofit", version.ref = "com-squareup-retrofit2-retrofit2" }
49
+androidx-multidex = { module = "androidx.multidex:multidex", version.ref = "multidex" }
50
+dialogx = { module = "com.github.kongzue.DialogX:DialogX", version.ref = "dialogxversion" }
51
+junit = { group = "junit", name = "junit", version.ref = "junit" }
52
+androidx-test-ext-junit = { group = "androidx.test.ext", name = "junit", version.ref = "androidx-test-ext-junit" }
53
+espresso-core = { group = "androidx.test.espresso", name = "espresso-core", version.ref = "espresso-core" }
54
+lifecycle-livedata-ktx = { module = "androidx.lifecycle:lifecycle-livedata-ktx", version.ref = "androidx-lifecycle-livedata-ktx" }
55
+lifecycle-runtime-ktx = { group = "androidx.lifecycle", name = "lifecycle-runtime-ktx", version.ref = "lifecycle-runtime-ktx" }
56
+activity-compose = { group = "androidx.activity", name = "activity-compose", version.ref = "activity-compose" }
57
+compose-bom = { group = "androidx.compose", name = "compose-bom", version.ref = "compose-bom" }
58
+org-jetbrains-kotlinx-kotlinx-coroutines-android2 = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-android", version.ref = "org-jetbrains-kotlinx-kotlinx-coroutines-android2" }
59
+org-jetbrains-kotlinx-kotlinx-coroutines-core2 = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-core", version.ref = "org-jetbrains-kotlinx-kotlinx-coroutines-core2" }
60
+ui = { group = "androidx.compose.ui", name = "ui" }
61
+ui-graphics = { group = "androidx.compose.ui", name = "ui-graphics" }
62
+ui-tooling = { group = "androidx.compose.ui", name = "ui-tooling" }
63
+ui-tooling-preview = { group = "androidx.compose.ui", name = "ui-tooling-preview" }
64
+ui-test-manifest = { group = "androidx.compose.ui", name = "ui-test-manifest" }
65
+ui-test-junit4 = { group = "androidx.compose.ui", name = "ui-test-junit4" }
66
+material3 = { group = "androidx.compose.material3", name = "material3" }
67
+appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "appcompat" }
68
+material = { group = "com.google.android.material", name = "material", version.ref = "material" }
69
+androidx-recyclerview = { group = "androidx.recyclerview", name = "recyclerview", version.ref = "recyclerview" }
70
+
71
+rxpermissions = { module = "com.github.tbruyelle:rxpermissions", version.ref = "rxpermissions" }
72
+rxjava = { module = "io.reactivex.rxjava2:rxjava", version.ref = "rxjava" }
73
+rxandroid = { module = "io.reactivex.rxjava2:rxandroid", version.ref = "rxandroid" }
74
+gittoaster = { module = "com.github.getActivity:Toaster", version.ref = "gittoaster" }
75
+
76
+
77
+baseadapterhelper = { module = "com.github.CymChad:BaseRecyclerViewAdapterHelper", version.ref = "adapterhelper" }
78
+core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "core-ktx" }
79
+eventbus = { module = "org.greenrobot:eventbus", version.ref = "eventbus" }
80
+
81
+smartrefresh-footer-classics = { module = "io.github.scwang90:refresh-footer-classics", version.ref = "refresh-layout-kernel" }
82
+smartrefresh-footer-ball = { module = "io.github.scwang90:refresh-footer-ball", version.ref = "refresh-layout-kernel" }
83
+smartrefresh-header-two-level = { module = "io.github.scwang90:refresh-header-two-level", version.ref = "refresh-layout-kernel" }
84
+smartrefresh-header-material = { module = "io.github.scwang90:refresh-header-material", version.ref = "refresh-layout-kernel" }
85
+smartrefresh-header-falsify = { module = "io.github.scwang90:refresh-header-falsify", version.ref = "refresh-layout-kernel" }
86
+smartrefresh-header-radar = { module = "io.github.scwang90:refresh-header-radar", version.ref = "refresh-layout-kernel" }
87
+smartrefresh-header-classics = { module = "io.github.scwang90:refresh-header-classics", version.ref = "refresh-layout-kernel" }
88
+smartrefresh-layout-kernel = { module = "io.github.scwang90:refresh-layout-kernel", version.ref = "refresh-layout-kernel" }
89
+androidx-cardview = { group = "androidx.cardview", name = "cardview", version.ref = "cardview" }
90
+
91
+jessyanandroidautosize = { module = "com.github.JessYanCoding:AndroidAutoSize", version.ref = "androidautosize" }
92
+
93
+[plugins]
94
+androidApplication = { id = "com.android.application", version.ref = "agp" }
95
+kotlinAndroid = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
96
+androidLibrary = { id = "com.android.library", version.ref = "agp" }
97
+[bundles]
98
+

BIN
gradle/wrapper/gradle-wrapper.jar View File


+ 6
- 0
gradle/wrapper/gradle-wrapper.properties View File

@@ -0,0 +1,6 @@
1
+#Mon Mar 11 14:46:06 GMT+08:00 2024
2
+distributionBase=GRADLE_USER_HOME
3
+distributionPath=wrapper/dists
4
+distributionUrl=https\://services.gradle.org/distributions/gradle-8.1-bin.zip
5
+zipStoreBase=GRADLE_USER_HOME
6
+zipStorePath=wrapper/dists

+ 185
- 0
gradlew View File

@@ -0,0 +1,185 @@
1
+#!/usr/bin/env sh
2
+
3
+#
4
+# Copyright 2015 the original author or authors.
5
+#
6
+# Licensed under the Apache License, Version 2.0 (the "License");
7
+# you may not use this file except in compliance with the License.
8
+# You may obtain a copy of the License at
9
+#
10
+#      https://www.apache.org/licenses/LICENSE-2.0
11
+#
12
+# Unless required by applicable law or agreed to in writing, software
13
+# distributed under the License is distributed on an "AS IS" BASIS,
14
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+# See the License for the specific language governing permissions and
16
+# limitations under the License.
17
+#
18
+
19
+##############################################################################
20
+##
21
+##  Gradle start up script for UN*X
22
+##
23
+##############################################################################
24
+
25
+# Attempt to set APP_HOME
26
+# Resolve links: $0 may be a link
27
+PRG="$0"
28
+# Need this for relative symlinks.
29
+while [ -h "$PRG" ] ; do
30
+    ls=`ls -ld "$PRG"`
31
+    link=`expr "$ls" : '.*-> \(.*\)$'`
32
+    if expr "$link" : '/.*' > /dev/null; then
33
+        PRG="$link"
34
+    else
35
+        PRG=`dirname "$PRG"`"/$link"
36
+    fi
37
+done
38
+SAVED="`pwd`"
39
+cd "`dirname \"$PRG\"`/" >/dev/null
40
+APP_HOME="`pwd -P`"
41
+cd "$SAVED" >/dev/null
42
+
43
+APP_NAME="Gradle"
44
+APP_BASE_NAME=`basename "$0"`
45
+
46
+# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
47
+DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
48
+
49
+# Use the maximum available, or set MAX_FD != -1 to use that value.
50
+MAX_FD="maximum"
51
+
52
+warn () {
53
+    echo "$*"
54
+}
55
+
56
+die () {
57
+    echo
58
+    echo "$*"
59
+    echo
60
+    exit 1
61
+}
62
+
63
+# OS specific support (must be 'true' or 'false').
64
+cygwin=false
65
+msys=false
66
+darwin=false
67
+nonstop=false
68
+case "`uname`" in
69
+  CYGWIN* )
70
+    cygwin=true
71
+    ;;
72
+  Darwin* )
73
+    darwin=true
74
+    ;;
75
+  MINGW* )
76
+    msys=true
77
+    ;;
78
+  NONSTOP* )
79
+    nonstop=true
80
+    ;;
81
+esac
82
+
83
+CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
84
+
85
+
86
+# Determine the Java command to use to start the JVM.
87
+if [ -n "$JAVA_HOME" ] ; then
88
+    if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
89
+        # IBM's JDK on AIX uses strange locations for the executables
90
+        JAVACMD="$JAVA_HOME/jre/sh/java"
91
+    else
92
+        JAVACMD="$JAVA_HOME/bin/java"
93
+    fi
94
+    if [ ! -x "$JAVACMD" ] ; then
95
+        die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
96
+
97
+Please set the JAVA_HOME variable in your environment to match the
98
+location of your Java installation."
99
+    fi
100
+else
101
+    JAVACMD="java"
102
+    which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
103
+
104
+Please set the JAVA_HOME variable in your environment to match the
105
+location of your Java installation."
106
+fi
107
+
108
+# Increase the maximum file descriptors if we can.
109
+if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
110
+    MAX_FD_LIMIT=`ulimit -H -n`
111
+    if [ $? -eq 0 ] ; then
112
+        if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
113
+            MAX_FD="$MAX_FD_LIMIT"
114
+        fi
115
+        ulimit -n $MAX_FD
116
+        if [ $? -ne 0 ] ; then
117
+            warn "Could not set maximum file descriptor limit: $MAX_FD"
118
+        fi
119
+    else
120
+        warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
121
+    fi
122
+fi
123
+
124
+# For Darwin, add options to specify how the application appears in the dock
125
+if $darwin; then
126
+    GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
127
+fi
128
+
129
+# For Cygwin or MSYS, switch paths to Windows format before running java
130
+if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
131
+    APP_HOME=`cygpath --path --mixed "$APP_HOME"`
132
+    CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
133
+
134
+    JAVACMD=`cygpath --unix "$JAVACMD"`
135
+
136
+    # We build the pattern for arguments to be converted via cygpath
137
+    ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
138
+    SEP=""
139
+    for dir in $ROOTDIRSRAW ; do
140
+        ROOTDIRS="$ROOTDIRS$SEP$dir"
141
+        SEP="|"
142
+    done
143
+    OURCYGPATTERN="(^($ROOTDIRS))"
144
+    # Add a user-defined pattern to the cygpath arguments
145
+    if [ "$GRADLE_CYGPATTERN" != "" ] ; then
146
+        OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
147
+    fi
148
+    # Now convert the arguments - kludge to limit ourselves to /bin/sh
149
+    i=0
150
+    for arg in "$@" ; do
151
+        CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
152
+        CHECK2=`echo "$arg"|egrep -c "^-"`                                 ### Determine if an option
153
+
154
+        if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then                    ### Added a condition
155
+            eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
156
+        else
157
+            eval `echo args$i`="\"$arg\""
158
+        fi
159
+        i=`expr $i + 1`
160
+    done
161
+    case $i in
162
+        0) set -- ;;
163
+        1) set -- "$args0" ;;
164
+        2) set -- "$args0" "$args1" ;;
165
+        3) set -- "$args0" "$args1" "$args2" ;;
166
+        4) set -- "$args0" "$args1" "$args2" "$args3" ;;
167
+        5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
168
+        6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
169
+        7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
170
+        8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
171
+        9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
172
+    esac
173
+fi
174
+
175
+# Escape application args
176
+save () {
177
+    for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
178
+    echo " "
179
+}
180
+APP_ARGS=`save "$@"`
181
+
182
+# Collect all arguments for the java command, following the shell quoting and substitution rules
183
+eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
184
+
185
+exec "$JAVACMD" "$@"

+ 89
- 0
gradlew.bat View File

@@ -0,0 +1,89 @@
1
+@rem
2
+@rem Copyright 2015 the original author or authors.
3
+@rem
4
+@rem Licensed under the Apache License, Version 2.0 (the "License");
5
+@rem you may not use this file except in compliance with the License.
6
+@rem You may obtain a copy of the License at
7
+@rem
8
+@rem      https://www.apache.org/licenses/LICENSE-2.0
9
+@rem
10
+@rem Unless required by applicable law or agreed to in writing, software
11
+@rem distributed under the License is distributed on an "AS IS" BASIS,
12
+@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+@rem See the License for the specific language governing permissions and
14
+@rem limitations under the License.
15
+@rem
16
+
17
+@if "%DEBUG%" == "" @echo off
18
+@rem ##########################################################################
19
+@rem
20
+@rem  Gradle startup script for Windows
21
+@rem
22
+@rem ##########################################################################
23
+
24
+@rem Set local scope for the variables with windows NT shell
25
+if "%OS%"=="Windows_NT" setlocal
26
+
27
+set DIRNAME=%~dp0
28
+if "%DIRNAME%" == "" set DIRNAME=.
29
+set APP_BASE_NAME=%~n0
30
+set APP_HOME=%DIRNAME%
31
+
32
+@rem Resolve any "." and ".." in APP_HOME to make it shorter.
33
+for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
34
+
35
+@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
36
+set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
37
+
38
+@rem Find java.exe
39
+if defined JAVA_HOME goto findJavaFromJavaHome
40
+
41
+set JAVA_EXE=java.exe
42
+%JAVA_EXE% -version >NUL 2>&1
43
+if "%ERRORLEVEL%" == "0" goto execute
44
+
45
+echo.
46
+echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
47
+echo.
48
+echo Please set the JAVA_HOME variable in your environment to match the
49
+echo location of your Java installation.
50
+
51
+goto fail
52
+
53
+:findJavaFromJavaHome
54
+set JAVA_HOME=%JAVA_HOME:"=%
55
+set JAVA_EXE=%JAVA_HOME%/bin/java.exe
56
+
57
+if exist "%JAVA_EXE%" goto execute
58
+
59
+echo.
60
+echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
61
+echo.
62
+echo Please set the JAVA_HOME variable in your environment to match the
63
+echo location of your Java installation.
64
+
65
+goto fail
66
+
67
+:execute
68
+@rem Setup the command line
69
+
70
+set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
71
+
72
+
73
+@rem Execute Gradle
74
+"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
75
+
76
+:end
77
+@rem End local scope for the variables with windows NT shell
78
+if "%ERRORLEVEL%"=="0" goto mainEnd
79
+
80
+:fail
81
+rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
82
+rem the _cmd.exe /c_ return code!
83
+if  not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
84
+exit /b 1
85
+
86
+:mainEnd
87
+if "%OS%"=="Windows_NT" endlocal
88
+
89
+:omega

+ 25
- 0
settings.gradle.kts View File

@@ -0,0 +1,25 @@
1
+pluginManagement {
2
+    repositories {
3
+        maven (url="https://maven.aliyun.com/repository/google")
4
+        maven (url="https://maven.aliyun.com/repository/public")//jcenter public 阿里最新地址
5
+        google()
6
+        mavenCentral()
7
+        gradlePluginPortal()
8
+        maven(url="https://jitpack.io")
9
+    }
10
+}
11
+dependencyResolutionManagement {
12
+    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
13
+    repositories {
14
+        maven (url="https://maven.aliyun.com/repository/google")
15
+        maven (url="https://maven.aliyun.com/repository/public")//jcenter public 阿里最新地址
16
+        google()
17
+        mavenCentral()
18
+        maven(url="https://jitpack.io")
19
+    }
20
+}
21
+
22
+rootProject.name = "XhlyManageApp"
23
+include(":app")
24
+include(":corelib")
25
+include(":websocket")

+ 0
- 0
websocket/consumer-rules.pro View File


+ 21
- 0
websocket/proguard-rules.pro View File

@@ -0,0 +1,21 @@
1
+# Add project specific ProGuard rules here.
2
+# You can control the set of applied configuration files using the
3
+# proguardFiles setting in build.gradle.
4
+#
5
+# For more details, see
6
+#   http://developer.android.com/guide/developing/tools/proguard.html
7
+
8
+# If your project uses WebView with JS, uncomment the following
9
+# and specify the fully qualified class name to the JavaScript interface
10
+# class:
11
+#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12
+#   public *;
13
+#}
14
+
15
+# Uncomment this to preserve the line number information for
16
+# debugging stack traces.
17
+#-keepattributes SourceFile,LineNumberTable
18
+
19
+# If you keep the line number information, uncomment this to
20
+# hide the original source file name.
21
+#-renamesourcefileattribute SourceFile

Loading…
Cancel
Save