Forráskód Böngészése

渠道接入专用工程

kaiweicai 2 éve
szülő
commit
e190cd08a4
100 módosított fájl, 3217 hozzáadás és 2 törlés
  1. 11 2
      .gitignore
  2. 1 0
      YYXXCommSdk/.gitignore
  3. 42 0
      YYXXCommSdk/build.gradle
  4. 0 0
      YYXXCommSdk/consumer-rules.pro
  5. BIN
      YYXXCommSdk/libs/yyxx-comm-base-3.0.306.jar
  6. BIN
      YYXXCommSdk/libs/yyxx-comm-channel-3.0.305.jar
  7. BIN
      YYXXCommSdk/libs/yyxx-comm-core-3.0.305.jar
  8. 21 0
      YYXXCommSdk/proguard-rules.pro
  9. 11 0
      YYXXCommSdk/src/main/AndroidManifest.xml
  10. BIN
      YYXXCommSdk/src/main/jniLibs/arm64-v8a/libdolin-zap.so
  11. BIN
      YYXXCommSdk/src/main/jniLibs/arm64-v8a/libmmkv.so
  12. BIN
      YYXXCommSdk/src/main/jniLibs/arm64-v8a/libyyxxgame.so
  13. BIN
      YYXXCommSdk/src/main/jniLibs/armeabi-v7a/libdolin-zap.so
  14. BIN
      YYXXCommSdk/src/main/jniLibs/armeabi-v7a/libmmkv.so
  15. BIN
      YYXXCommSdk/src/main/jniLibs/armeabi-v7a/libyyxxgame.so
  16. BIN
      YYXXCommSdk/src/main/jniLibs/x86/libdolin-zap.so
  17. BIN
      YYXXCommSdk/src/main/jniLibs/x86/libmmkv.so
  18. BIN
      YYXXCommSdk/src/main/jniLibs/x86/libyyxxgame.so
  19. BIN
      YYXXCommSdk/src/main/jniLibs/x86_64/libdolin-zap.so
  20. BIN
      YYXXCommSdk/src/main/jniLibs/x86_64/libmmkv.so
  21. BIN
      YYXXCommSdk/src/main/jniLibs/x86_64/libyyxxgame.so
  22. 12 0
      YYXXCommSdk/src/main/res/drawable/yyxx_btn_exit_bg.xml
  23. 5 0
      YYXXCommSdk/src/main/res/drawable/yyxx_comm_background.xml
  24. 12 0
      YYXXCommSdk/src/main/res/drawable/yyxx_comm_confirm_button_style.xml
  25. 15 0
      YYXXCommSdk/src/main/res/drawable/yyxx_comm_progress_drawable_white.xml
  26. 8 0
      YYXXCommSdk/src/main/res/drawable/yyxx_dialog_ios_bg.xml
  27. 46 0
      YYXXCommSdk/src/main/res/layout/yyxx_comm_ios_style_dialog.xml
  28. 24 0
      YYXXCommSdk/src/main/res/layout/yyxx_comm_loading_dialog.xml
  29. 36 0
      YYXXCommSdk/src/main/res/layout/yyxx_comm_p_webview.xml
  30. 74 0
      YYXXCommSdk/src/main/res/layout/yyxx_comm_privacy_dialog.xml
  31. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_close.png
  32. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_bg.9.png
  33. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_01.png
  34. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_02.png
  35. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_03.png
  36. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_04.png
  37. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_05.png
  38. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_06.png
  39. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_07.png
  40. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_08.png
  41. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_09.png
  42. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_10.png
  43. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_11.png
  44. BIN
      YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_12.png
  45. 12 0
      YYXXCommSdk/src/main/res/values/yyxx_comm_colors.xml
  46. 15 0
      YYXXCommSdk/src/main/res/values/yyxx_comm_strings.xml
  47. 41 0
      YYXXCommSdk/src/main/res/values/yyxx_comm_styles.xml
  48. 1 0
      app/.gitignore
  49. 68 0
      app/build.gradle
  50. BIN
      app/libs/oaid_sdk_1.0.25.aar
  51. 21 0
      app/proguard-rules.pro
  52. 69 0
      app/src/main/AndroidManifest.xml
  53. 12 0
      app/src/main/java/com/example/yyxx/merge/channel/DemoApplication.java
  54. 429 0
      app/src/main/java/com/example/yyxx/merge/channel/MainActivity.java
  55. 6 0
      app/src/main/java/com/example/yyxx/merge/channel/SplashActivity.java
  56. 34 0
      app/src/main/res/drawable-v24/ic_launcher_foreground.xml
  57. 170 0
      app/src/main/res/drawable/ic_launcher_background.xml
  58. BIN
      app/src/main/res/drawable/yyxx_comm_welcome.png
  59. 175 0
      app/src/main/res/layout/activity_main.xml
  60. 5 0
      app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
  61. BIN
      app/src/main/res/mipmap-hdpi/ic_launcher.png
  62. BIN
      app/src/main/res/mipmap-mdpi/ic_launcher.png
  63. BIN
      app/src/main/res/mipmap-xxhdpi/ic_launcher.png
  64. BIN
      app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
  65. 9 0
      app/src/main/res/values/colors.xml
  66. 6 0
      app/src/main/res/values/strings.xml
  67. 9 0
      app/src/main/res/values/styles.xml
  68. 11 0
      build.gradle
  69. 1 0
      channel/.gitignore
  70. 28 0
      channel/build.gradle
  71. 1 0
      channel/huawei/.gitignore
  72. 49 0
      channel/huawei/build.gradle
  73. 20 0
      channel/huawei/buildJar.gradle
  74. 21 0
      channel/huawei/proguard-rules.pro
  75. 29 0
      channel/huawei/src/main/AndroidManifest.xml
  76. 27 0
      channel/huawei/src/main/assets/agconnect-services.json
  77. 5 0
      channel/huawei/src/main/assets/yyxx_game/yyxx_cfg.properties
  78. 169 0
      channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/ChannelBridge.java
  79. 822 0
      channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/huawei/ChannelBridgeImpl.java
  80. 96 0
      channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/huawei/RealAssertUtils.java
  81. 65 0
      channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/msa/MsaDeviceHandler.java
  82. 19 0
      channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/utils/ParamsUtils.java
  83. 21 0
      channel/proguard-rules.pro
  84. 7 0
      channel/src/main/AndroidManifest.xml
  85. 20 0
      gradle.properties
  86. BIN
      gradle/wrapper/gradle-wrapper.jar
  87. 6 0
      gradle/wrapper/gradle-wrapper.properties
  88. 185 0
      gradlew
  89. 89 0
      gradlew.bat
  90. 1 0
      platform/.gitignore
  91. 30 0
      platform/build.gradle
  92. 0 0
      platform/consumer-rules.pro
  93. 1 0
      platform/hnqj/.gitignore
  94. 33 0
      platform/hnqj/build.gradle
  95. 0 0
      platform/hnqj/consumer-rules.pro
  96. BIN
      platform/hnqj/libs/yyxx-comm-platform-hnqj-3.0.300.jar
  97. 21 0
      platform/hnqj/proguard-rules.pro
  98. 16 0
      platform/hnqj/src/main/AndroidManifest.xml
  99. 11 0
      platform/hnqj/src/main/res/anim/qj_rotate_anim.xml
  100. 13 0
      platform/hnqj/src/main/res/drawable/qj_btn_account_bg.xml

+ 11 - 2
.gitignore

@@ -1,3 +1,13 @@
+# IDEA
+*.iml
+.gradle
+.idea
+/local.properties
+.DS_Store
+
+# ---> dolin zap log framework
+*.zap
+
 # ---> Android
 # Built application files
 *.apk
@@ -30,5 +40,4 @@ proguard/
 .navigation/
 
 # Android Studio captures folder
-captures/
-
+captures/

+ 1 - 0
YYXXCommSdk/.gitignore

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

+ 42 - 0
YYXXCommSdk/build.gradle

@@ -0,0 +1,42 @@
+plugins {
+    id 'com.android.library'
+}
+
+android {
+    compileSdk 31
+
+    defaultConfig {
+        minSdk 21
+        targetSdk 31
+
+         consumerProguardFiles "consumer-rules.pro"
+    }
+
+    buildTypes {
+        release {
+            minifyEnabled false
+            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
+        }
+    }
+    compileOptions {
+        sourceCompatibility JavaVersion.VERSION_1_7
+        targetCompatibility JavaVersion.VERSION_1_7
+    }
+    sourceSets {
+        main {
+            assets {
+                srcDirs 'src/main/assets'
+            }
+        }
+    }
+}
+
+dependencies {
+
+
+    api fileTree(dir: 'libs', include: '*.jar')
+
+
+
+
+}

+ 0 - 0
YYXXCommSdk/consumer-rules.pro


BIN
YYXXCommSdk/libs/yyxx-comm-base-3.0.306.jar


BIN
YYXXCommSdk/libs/yyxx-comm-channel-3.0.305.jar


BIN
YYXXCommSdk/libs/yyxx-comm-core-3.0.305.jar


+ 21 - 0
YYXXCommSdk/proguard-rules.pro

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

+ 11 - 0
YYXXCommSdk/src/main/AndroidManifest.xml

@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.example.yyxx_comm_sdk">
+
+    <application>
+
+
+    </application>
+
+
+</manifest>

BIN
YYXXCommSdk/src/main/jniLibs/arm64-v8a/libdolin-zap.so


BIN
YYXXCommSdk/src/main/jniLibs/arm64-v8a/libmmkv.so


BIN
YYXXCommSdk/src/main/jniLibs/arm64-v8a/libyyxxgame.so


BIN
YYXXCommSdk/src/main/jniLibs/armeabi-v7a/libdolin-zap.so


BIN
YYXXCommSdk/src/main/jniLibs/armeabi-v7a/libmmkv.so


BIN
YYXXCommSdk/src/main/jniLibs/armeabi-v7a/libyyxxgame.so


BIN
YYXXCommSdk/src/main/jniLibs/x86/libdolin-zap.so


BIN
YYXXCommSdk/src/main/jniLibs/x86/libmmkv.so


BIN
YYXXCommSdk/src/main/jniLibs/x86/libyyxxgame.so


BIN
YYXXCommSdk/src/main/jniLibs/x86_64/libdolin-zap.so


BIN
YYXXCommSdk/src/main/jniLibs/x86_64/libmmkv.so


BIN
YYXXCommSdk/src/main/jniLibs/x86_64/libyyxxgame.so


+ 12 - 0
YYXXCommSdk/src/main/res/drawable/yyxx_btn_exit_bg.xml

@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android" >
+
+
+
+    <stroke android:width="1dp" android:color="@color/yyxx_comm_text_cyan"/>
+    <corners
+        android:radius="5dp"
+        />
+
+
+</shape>

+ 5 - 0
YYXXCommSdk/src/main/res/drawable/yyxx_comm_background.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android">
+    <solid android:color="@color/yyxx_comm_white_70" />
+    <corners android:radius="8dp" />
+</shape>

+ 12 - 0
YYXXCommSdk/src/main/res/drawable/yyxx_comm_confirm_button_style.xml

@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android" >
+
+
+
+
+
+        <gradient android:type="linear" android:useLevel="true" android:startColor="@color/yyxx_comm_text_light_blue" android:endColor="@color/yyxx_comm_text_deep_green" android:angle="180" />
+        <corners  android:radius="5dp" />
+
+
+</shape>

+ 15 - 0
YYXXCommSdk/src/main/res/drawable/yyxx_comm_progress_drawable_white.xml

@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<animation-list android:oneshot="false"
+                xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_01" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_02" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_03" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_04" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_05" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_06" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_07" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_08" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_09" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_11" />
+    <item android:duration="83" android:drawable="@mipmap/yyxx_comm_loading_white_12" />
+</animation-list>

+ 8 - 0
YYXXCommSdk/src/main/res/drawable/yyxx_dialog_ios_bg.xml

@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">
+    <solid android:color="@color/yyxx_comm_white"/>
+    <corners android:radius="10dp"/>
+    <stroke
+        android:width="0.1dp"
+        android:color="@color/yyxx_comm_dialog_line"/>
+</shape>

+ 46 - 0
YYXXCommSdk/src/main/res/layout/yyxx_comm_ios_style_dialog.xml

@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:orientation="vertical"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:background="@drawable/yyxx_dialog_ios_bg">
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_margin="20dp"
+        android:gravity="center_horizontal"
+        android:orientation="vertical">
+        <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:textColor="@color/yyxx_comm_black"
+            android:textSize="16sp"
+            android:text="@string/yyxx_comm_title_tip"/>
+
+        <TextView
+            android:id="@+id/content"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
+            android:textColor="@color/yyxx_comm_black"
+            android:textSize="12sp"
+            android:gravity="center"
+            android:text="@string/yyxx_comm_network_error_tip"
+            />
+    </LinearLayout>
+
+    <View
+        android:layout_width="match_parent"
+        android:layout_height="1px"
+        android:background="@color/yyxx_comm_dialog_line"/>
+
+    <TextView
+        android:id="@+id/confirm"
+        android:layout_width="match_parent"
+        android:layout_height="40dp"
+        android:gravity="center"
+        android:layout_gravity="center_horizontal"
+        android:textColor="@color/yyxx_comm_blues"
+        android:textSize="16sp"
+        android:text="@string/yyxx_comm_confirm"/>
+    </LinearLayout>

+ 24 - 0
YYXXCommSdk/src/main/res/layout/yyxx_comm_loading_dialog.xml

@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+              android:layout_width="wrap_content"
+              android:layout_height="wrap_content"
+              android:background="@mipmap/yyxx_comm_loading_bg"
+              android:gravity="center"
+              android:orientation="vertical"
+              android:padding="16.0dip" >
+
+    <ProgressBar
+            android:layout_width="30.0dip"
+            android:layout_height="30.0dip"
+            android:indeterminateDrawable="@drawable/yyxx_comm_progress_drawable_white" />
+
+    <TextView
+            android:id="@+id/id_tv_loadingmsg"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_gravity="center_vertical"
+            android:layout_marginTop="8.0dip"
+            android:textColor="#fff"
+            android:textSize="16.0dip" />
+
+</LinearLayout>

+ 36 - 0
YYXXCommSdk/src/main/res/layout/yyxx_comm_p_webview.xml

@@ -0,0 +1,36 @@
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="360dp"
+    android:layout_height="320dp"
+    android:gravity="center"
+     android:orientation="vertical"
+    android:id="@+id/ll_p_wb"
+    >
+        <RelativeLayout
+            android:layout_width="match_parent"
+            android:layout_height="20dp"
+            android:layout_weight="1.0"
+            android:orientation="horizontal">
+
+            <WebView
+                android:id="@+id/wb_with_xd"
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"
+                android:scrollbars="none" />
+
+            <ImageView
+                android:id="@+id/iv_reback_close"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="10dp"
+                android:layout_marginRight="10dp"
+                android:padding="10dp"
+                android:src="@mipmap/yyxx_comm_close"
+                android:layout_alignParentRight="true"
+
+                />
+
+        </RelativeLayout>
+
+
+    </LinearLayout>
+

+ 74 - 0
YYXXCommSdk/src/main/res/layout/yyxx_comm_privacy_dialog.xml

@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="360dp"
+    android:layout_height="280dp"
+    android:background="@color/yyxx_comm_white"
+    android:orientation="vertical"
+    android:id="@+id/ll_private_policy"
+    >
+
+
+<RelativeLayout
+    android:layout_width="match_parent"
+    android:layout_height="0dp"
+    android:layout_weight="7"
+    android:layout_marginTop="10dp"
+    android:layout_marginLeft="2dp"
+    android:layout_marginRight="2dp"
+    >
+
+    <WebView
+        android:id="@+id/wb_user_info"
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:layout_gravity="center"
+        android:background="@color/yyxx_comm_transparent" />
+</RelativeLayout>
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="0dp"
+        android:layout_weight="3"
+        android:orientation="horizontal"
+        >
+        <View
+            android:layout_width="0dp"
+            android:layout_height="match_parent"
+            android:layout_weight="1"
+            />
+        <Button
+
+            android:id="@+id/btn_disagree"
+            android:layout_width="0dp"
+            android:layout_height="30dp"
+            android:layout_weight="2"
+            android:layout_gravity="center"
+            android:text="@string/yyxx_comm_disagreement"
+            android:textColor="@color/yyxx_comm_text_cyan"
+            android:background="@drawable/yyxx_btn_exit_bg"/>
+        <View
+            android:layout_width="0dp"
+            android:layout_height="match_parent"
+            android:layout_weight="1"
+            />
+        <View
+            android:layout_width="0dp"
+            android:layout_height="match_parent"
+            android:layout_weight="1"
+            />
+
+        <Button
+            android:id="@+id/btn_agree"
+            android:layout_width="0dp"
+            android:layout_height="30dp"
+            android:layout_weight="2"
+            android:layout_gravity="center"
+            android:background="@drawable/yyxx_comm_confirm_button_style"
+            android:textColor="@color/yyxx_comm_white"
+            android:text="@string/yyxx_comm_agreement"/>
+        <View
+            android:layout_width="0dp"
+            android:layout_height="match_parent"
+            android:layout_weight="1"
+            />
+    </LinearLayout>
+</LinearLayout>

BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_close.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_bg.9.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_01.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_02.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_03.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_04.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_05.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_06.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_07.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_08.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_09.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_10.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_11.png


BIN
YYXXCommSdk/src/main/res/mipmap-hdpi/yyxx_comm_loading_white_12.png


+ 12 - 0
YYXXCommSdk/src/main/res/values/yyxx_comm_colors.xml

@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+    <color name="yyxx_comm_transparent">#00000000</color>
+    <color name="yyxx_comm_text_cyan">#12B2A6</color>
+    <color name="yyxx_comm_white">#FFFFFF</color>
+    <color name="yyxx_comm_white_70">#B3FFFFFF</color>
+    <color name="yyxx_comm_text_deep_green">#87DB3E</color>
+    <color name="yyxx_comm_text_light_blue">#198AC3</color>
+    <color name="yyxx_comm_black">#000000</color>
+    <color name="yyxx_comm_blues">#2abfff</color>
+    <color name="yyxx_comm_dialog_line">#999999</color>
+</resources>

+ 15 - 0
YYXXCommSdk/src/main/res/values/yyxx_comm_strings.xml

@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+
+
+    <string name="yyxx_comm_disagreement">不同意</string>
+    <string name="yyxx_comm_agreement">同意</string>
+    <string name="yyxx_comm_title_tip">温馨提示</string>
+    <string name="yyxx_comm_confirm">确定</string>
+    <string name="yyxx_comm_network_error_tip">网络出错,请检查网络</string>
+    <string name="yyxx_comm_params_error_tip">参数异常,请检查AndroidManifest.xml中的YYXX_COMM_GAME_CODE值</string>
+    <string name="yyxx_comm_initing">正在初始化...</string>
+    <string name="yyxx_comm_init_success">初始化成功</string>
+    <string name="yyxx_comm_init_fail">初始化失败</string>
+    <string name="yyxx_comm_ctime_format_error">角色创建时间格式错误,需10位数精度为秒</string>
+</resources>

+ 41 - 0
YYXXCommSdk/src/main/res/values/yyxx_comm_styles.xml

@@ -0,0 +1,41 @@
+<resources>
+
+
+
+
+
+
+
+
+
+
+    <style name="yyxx_comm_base_dialog" parent="@android:style/Theme.Dialog">
+    <item name="android:windowFrame">@null</item>
+    <!-- 边框 -->
+    <item name="android:windowIsFloating">true</item>
+    <!-- 是否浮现在activity之上 -->
+    <item name="android:windowIsTranslucent">false</item>
+    <!-- 半透明 -->
+    <item name="android:windowNoTitle">true</item>
+    <!-- 无标题 -->
+    <item name="android:windowBackground">@color/yyxx_comm_transparent</item>
+    <!-- 背景透明 -->
+    <item name="android:backgroundDimEnabled">false</item>
+    <item name="android:windowCloseOnTouchOutside">false</item>
+    <item name="android:windowFullscreen">true</item>
+
+    <!-- 模糊 -->
+    </style>
+
+
+    <style name="yyxx_comm_loading_dialog" parent="@android:style/Theme.Dialog">
+        <item name="android:windowFrame">@null</item>
+        <item name="android:windowIsFloating">true</item>
+        <item name="android:windowIsTranslucent">true</item>
+        <item name="android:windowNoTitle">true</item>
+        <item name="android:background">@null</item>
+        <item name="android:windowBackground">@null</item>
+        <item name="android:backgroundDimEnabled">false</item>
+    </style>
+
+</resources>

+ 1 - 0
app/.gitignore

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

+ 68 - 0
app/build.gradle

@@ -0,0 +1,68 @@
+plugins {
+    id 'com.android.application'
+}
+
+android {
+    compileSdk 31
+
+    defaultConfig {
+        applicationId "com.yyxx.qyj2.huawei"
+        minSdk 21
+        targetSdk 26
+        versionCode 1
+        versionName "1.0"
+
+     }
+
+
+    buildTypes {
+        debug {
+            minifyEnabled false
+             proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
+        }
+        release {
+            minifyEnabled false
+            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
+        }
+
+
+    }
+
+
+    // 签名
+    signingConfigs {
+        debug {
+
+            storeFile file('/Users/kaiweicai/Documents/Android/keystore/yyrh.jks')
+//            storeFile file('/Users/change/Desktop/SVNProject/Android/android_project/keystore/yyrh.jks')
+            storePassword 'yyrh123456'
+            keyAlias 'yyrh'
+            keyPassword 'yyrh123456'
+        }
+        release {
+
+            storeFile file('/Users/kaiweicai/Documents/Android/keystore/yyrh.jks')
+//            storeFile file('/Users/change/Desktop/SVNProject/Android/android_project/keystore/yyrh.jks')
+            storePassword 'yyrh123456'
+            keyAlias 'yyrh'
+            keyPassword 'yyrh123456'
+        }
+    }
+
+    lintOptions {
+        abortOnError false
+    }
+
+    compileOptions {
+        sourceCompatibility JavaVersion.VERSION_1_8
+        targetCompatibility JavaVersion.VERSION_1_8
+    }
+}
+
+dependencies {
+
+     implementation project(':YYXXCommSdk')
+
+    implementation project(':channel:huawei')
+
+}

BIN
app/libs/oaid_sdk_1.0.25.aar


+ 21 - 0
app/proguard-rules.pro

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

+ 69 - 0
app/src/main/AndroidManifest.xml

@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.example.yyxx.merge.channel">
+
+    <application
+        android:name=".DemoApplication"
+        android:allowBackup="true"
+        android:icon="@mipmap/ic_launcher"
+        android:label="@string/app_name"
+        android:roundIcon="@mipmap/ic_launcher"
+        android:supportsRtl="true">
+        <activity
+            android:name="com.example.yyxx.merge.channel.SplashActivity"
+            android:exported="true">
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN" />
+                <category android:name="android.intent.category.LAUNCHER" />
+            </intent-filter>
+        </activity>
+
+        <activity
+            android:name="com.example.yyxx.merge.channel.MainActivity"
+            android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation"
+            android:exported="true"
+            android:launchMode="singleTask"
+            android:screenOrientation="sensorLandscape" >
+            <intent-filter>
+                <action android:name="${applicationId}" />
+                <action android:name="android.intent.action.VIEW" />
+                <category android:name="android.intent.category.DEFAULT" />
+            </intent-filter>
+        </activity>
+
+
+
+
+        <activity android:name="cn.yyxx.support.permission.PermissionKitActivity"
+            android:configChanges="orientation|keyboardHidden|screenSize"
+            android:screenOrientation="behind"
+            android:theme="@android:style/Theme.Translucent.NoTitleBar.Fullscreen"
+            />
+
+
+        <meta-data
+            android:name="YYXX_COMM_GAME_CODE"
+            android:value="100001" />
+    </application>
+
+
+    <!-- 网络权限 -->
+    <uses-permission android:name="android.permission.INTERNET" />
+    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
+    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
+    <uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
+    <uses-permission android:name="android.permission.CHANGE_WIFI_STATE" />
+    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
+    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
+    <uses-permission android:name="android.permission.READ_PHONE_STATE" />
+    <uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
+
+
+
+
+
+    <uses-permission android:name="com.asus.msa.SupplementaryDID.ACCESS" />
+
+    <uses-permission android:name="freemme.permission.msa" />
+
+</manifest>

+ 12 - 0
app/src/main/java/com/example/yyxx/merge/channel/DemoApplication.java

@@ -0,0 +1,12 @@
+package com.example.yyxx.merge.channel;
+
+import android.content.Context;
+
+
+
+import cn.yyxx.commsdk.base.YYXXApplication;
+
+
+public class DemoApplication extends YYXXApplication {
+
+}

+ 429 - 0
app/src/main/java/com/example/yyxx/merge/channel/MainActivity.java

@@ -0,0 +1,429 @@
+package com.example.yyxx.merge.channel;
+
+
+import android.app.Activity;
+
+
+import android.app.AlertDialog;
+import android.content.DialogInterface;
+import android.content.Intent;
+
+
+import android.content.res.Configuration;
+
+
+
+
+
+import android.os.Bundle;
+
+
+import android.util.Log;
+import android.view.View;
+import android.view.Window;
+import android.view.WindowManager;
+import android.widget.Button;
+import android.widget.EditText;
+import android.widget.ScrollView;
+
+import android.widget.Toast;
+
+
+import org.json.JSONException;
+import org.json.JSONObject;
+
+
+
+import java.util.HashMap;
+
+
+
+import cn.yyxx.commsdk.base.YYXXCommSdk;
+import cn.yyxx.commsdk.base.constants.Constants;
+import cn.yyxx.commsdk.base.entity.ResultInfo;
+import cn.yyxx.commsdk.base.entity.SdkChargeInfo;
+import cn.yyxx.commsdk.base.entity.SdkRoleInfo;
+import cn.yyxx.commsdk.base.internal.ICallback;
+import cn.yyxx.commsdk.base.utils.Logger;
+import cn.yyxx.support.hawkeye.ToastUtils;
+
+
+public class MainActivity extends Activity implements View.OnClickListener {
+
+    private EditText et_hasgold;
+    private EditText et_money;
+    private EditText et_partyid;
+    private EditText et_partyname;
+    private EditText et_reincarnationrCount;
+    private EditText et_rolectime;
+    private EditText et_roleid;
+    private EditText et_rolelevel;
+    private EditText et_rolename;
+    private EditText et_rolepower;
+    private EditText et_rolesex;
+    private EditText et_serveid;
+    private EditText et_servername;
+    private EditText et_viplevel;
+    private EditText et_charge;
+    private boolean isDebug = true;
+    private Button logOut;
+    private Button login_btn;
+    private Button pay_btn;
+    private Button permission;
+
+    private Button upload_btn;
+    private Button upload_btn1;
+    private Button upload_btn2;
+    private Button userCenter;
+
+
+    @Override
+    protected void onCreate(final Bundle savedInstanceState) {
+        super.onCreate(savedInstanceState);
+
+         requestWindowFeature(Window.FEATURE_NO_TITLE);
+        //隐藏顶部状态栏
+        getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
+
+        setContentView(R.layout.activity_main);
+
+        ScrollView ll = findViewById(R.id.scl_1);
+
+        this.login_btn = (Button) findViewById(R.id.login_btn);
+        this.upload_btn = (Button) findViewById(R.id.upload_btn);
+        this.upload_btn1 = (Button) findViewById(R.id.upload_btn1);
+        this.upload_btn2 = (Button) findViewById(R.id.upload_btn2);
+        this.pay_btn = (Button) findViewById(R.id.pay_btn);
+        this.logOut = (Button) findViewById(R.id.logout_btn);
+        this.userCenter = (Button) findViewById(R.id.user_btn);
+        this.permission = (Button) findViewById(R.id.permission);
+        this.et_roleid = (EditText) findViewById(R.id.et_roleid);
+        this.et_rolename = (EditText) findViewById(R.id.et_rolename);
+        this.et_rolelevel = (EditText) findViewById(R.id.et_rolelevel);
+        this.et_rolesex = (EditText) findViewById(R.id.et_rolesex);
+        this.et_serveid = (EditText) findViewById(R.id.et_serveid);
+        this.et_servername = (EditText) findViewById(R.id.et_servername);
+        this.et_hasgold = (EditText) findViewById(R.id.et_hasgold);
+        this.et_viplevel = (EditText) findViewById(R.id.et_viplevel);
+        this.et_partyname = (EditText) findViewById(R.id.et_partyname);
+        this.et_partyid = (EditText) findViewById(R.id.et_partyid);
+        this.et_rolectime = (EditText) findViewById(R.id.et_rolectime);
+        this.et_rolepower = (EditText) findViewById(R.id.et_rolepower);
+        this.et_reincarnationrCount = (EditText) findViewById(R.id.et_reincarnationrCount);
+        this.et_money = (EditText) findViewById(R.id.et_money);
+        this.et_charge = findViewById(R.id.et_charge);
+        this.upload_btn.setOnClickListener(this);
+        this.upload_btn1.setOnClickListener(this);
+        this.upload_btn2.setOnClickListener(this);
+        this.pay_btn.setOnClickListener(this);
+        this.logOut.setOnClickListener(this);
+        this.userCenter.setOnClickListener(this);
+        this.permission.setOnClickListener(this);
+        this.login_btn.setOnClickListener(this);
+
+
+
+        this.permission.setOnClickListener(this);
+
+
+
+
+        YYXXCommSdk.getInstance().initialize(this, new ICallback() {
+            @Override
+            public void onResult(int i, String s) {
+                ToastUtils.toastInfo(MainActivity.this,s);
+            }
+        });
+
+
+
+
+
+    }
+
+
+    @Override
+    public void onClick(View view) {
+        int id = view.getId();
+        if (id == R.id.pay_btn) {
+            HashMap hashMap = new HashMap();
+            String obj = this.et_money.getText().toString();
+            if (judgeStrNull(obj)) {
+                ToastUtils.toastInfo(MainActivity.this,"输入金额不能为空");
+                return;
+            }
+
+            SdkChargeInfo chargeInfo = new SdkChargeInfo();
+
+
+
+
+            StringBuilder stringBuilder = new StringBuilder();
+            stringBuilder.append(System.currentTimeMillis());
+            stringBuilder.append("");
+
+            chargeInfo.setGame_no(stringBuilder.toString());
+
+
+            chargeInfo.setExt("111");
+
+
+            chargeInfo.setCount("10");
+
+            chargeInfo.setHasGold("120");
+            chargeInfo.setOrder_desc("购买10元宝");
+            chargeInfo.setProduct_name("10元宝");
+            chargeInfo.setParty_name("霸天");
+            chargeInfo.setParty_id("192828333955");
+            chargeInfo.setPay_money(obj);
+            chargeInfo.setRadio("10");
+            chargeInfo.setReincarnationCount("0");
+            chargeInfo.setProduct_name("元宝");
+            chargeInfo.setRole_id("10086");
+            chargeInfo.setRole_name("可爱小呆瓜");
+            chargeInfo.setServer_id("100");
+            chargeInfo.setServer_name("惊天1服");
+            chargeInfo.setVip_level("10");
+            chargeInfo.setProduct_id("com.yyxx.yb6");
+            chargeInfo.setOrder_name("购买10元宝");
+            chargeInfo.setRole_level("299");
+            chargeInfo.setRoleCreateTime(System.currentTimeMillis() / 1000 +"");
+
+            YYXXCommSdk.getInstance().charge(this, chargeInfo, new ICallback() {
+                @Override
+                public void onResult(int i, String s) {
+
+                }
+            });
+
+
+        } else if (id != R.id.permission) {
+            switch (id) {
+                case R.id.login_btn:
+                    YYXXCommSdk.getInstance().login(this, new ICallback() {
+                        @Override
+                        public void onResult(int i, String s) {
+                            if (i == ResultInfo.CODE_SUCCESS){
+                                ToastUtils.toastInfo(MainActivity.this,s);
+                            }else{
+                                ToastUtils.toastInfo(MainActivity.this,s);
+                            }
+
+                        }
+                    });
+                    break;
+                case R.id.logout_btn /*2131034178*/:
+
+
+                    break;
+                default:
+                    SdkRoleInfo roleInfo;
+                    StringBuilder stringBuilder2;
+                    switch (id) {
+                        case R.id.upload_btn /*2131034222*/:
+                            roleInfo = new SdkRoleInfo();
+                            roleInfo.setRoleId(this.et_roleid.getText().toString());
+                            roleInfo.setRoleName(this.et_rolename.getText().toString());
+                            roleInfo.setRoleLevel(this.et_rolelevel.getText().toString());
+                            roleInfo.setGender(this.et_rolesex.getText().toString());
+                            roleInfo.setServerId(this.et_serveid.getText().toString());
+                            roleInfo.setServerName(this.et_servername.getText().toString());
+                            roleInfo.setHasGold(this.et_hasgold.getText().toString());
+                            roleInfo.setVipLevel(this.et_viplevel.getText().toString());
+                            roleInfo.setRolePower("7653471597");
+
+                            roleInfo.setPartyId(this.et_partyid.getText().toString());
+                            roleInfo.setPartyName(this.et_partyname.getText().toString());
+                            roleInfo.setRoleCreateTime(this.et_rolectime.getText().toString());
+                            roleInfo.setPartyId(this.et_partyid.getText().toString());
+                            roleInfo.setReincarnationCount(this.et_reincarnationrCount.getText().toString());
+                            roleInfo.setCharge(et_charge.getText().toString());
+                            YYXXCommSdk.getInstance().uploadRoleInfo(this, Constants.UPLOAD_TYPE_CREATE_ROLE,roleInfo);
+                            break;
+                        case R.id.upload_btn1 /*2131034223*/:
+                            roleInfo = new SdkRoleInfo();
+                            roleInfo.setRoleId(this.et_roleid.getText().toString());
+                            roleInfo.setRoleName(this.et_rolename.getText().toString());
+                            roleInfo.setRoleLevel(this.et_rolelevel.getText().toString());
+                            roleInfo.setGender(this.et_rolesex.getText().toString());
+                            roleInfo.setServerId(this.et_serveid.getText().toString());
+                            roleInfo.setServerName(this.et_servername.getText().toString());
+                            roleInfo.setHasGold(this.et_hasgold.getText().toString());
+                            roleInfo.setVipLevel(this.et_viplevel.getText().toString());
+                            roleInfo.setRolePower("7653471597");
+
+                            roleInfo.setPartyId(this.et_partyid.getText().toString());
+                            roleInfo.setPartyName(this.et_partyname.getText().toString());
+                            roleInfo.setRoleCreateTime(this.et_rolectime.getText().toString());
+                            roleInfo.setPartyId(this.et_partyid.getText().toString());
+                            roleInfo.setReincarnationCount(this.et_reincarnationrCount.getText().toString());
+                            roleInfo.setCharge(et_charge.getText().toString());
+
+                            YYXXCommSdk.getInstance().uploadRoleInfo(this, Constants.UPLOAD_TYPE_ENTER_GAME,roleInfo);
+
+
+                            break;
+                        case R.id.upload_btn2 /*2131034224*/:
+                            roleInfo = new SdkRoleInfo();
+                            roleInfo.setRoleId(this.et_roleid.getText().toString());
+                            roleInfo.setRoleName(this.et_rolename.getText().toString());
+                            roleInfo.setRoleLevel(this.et_rolelevel.getText().toString());
+                            roleInfo.setGender(this.et_rolesex.getText().toString());
+                            roleInfo.setServerId(this.et_serveid.getText().toString());
+                            roleInfo.setServerName(this.et_servername.getText().toString());
+                            roleInfo.setHasGold(this.et_hasgold.getText().toString());
+                            roleInfo.setVipLevel(this.et_viplevel.getText().toString());
+                            roleInfo.setRolePower(this.et_rolepower.getText().toString());
+                            roleInfo.setPartyId(this.et_partyid.getText().toString());
+                            roleInfo.setPartyName(this.et_partyname.getText().toString());
+                            roleInfo.setRoleCreateTime(this.et_rolectime.getText().toString());
+                            roleInfo.setPartyId(this.et_partyid.getText().toString());
+                            roleInfo.setReincarnationCount(this.et_reincarnationrCount.getText().toString());
+                            roleInfo.setCharge(et_charge.getText().toString());
+                            YYXXCommSdk.getInstance().uploadRoleInfo(this, Constants.UPLOAD_TYPE_LEVEL_UPGRADE,roleInfo);
+                        case R.id.user_btn /*2131034225*/:
+                            JSONObject json = new JSONObject();
+                            try {
+                                json.put("AE", "xio");
+                                json.put("AE5", "future");
+                            } catch (JSONException e) {
+                                e.printStackTrace();
+                            }
+
+
+                            YYXXCommSdk.getInstance().reportGameEvent("Car", json);
+                            break;
+                    }
+                    break;
+            }
+        } else {
+            Toast.makeText(this, String.format("%010d", new Object[]{Long.valueOf(System.currentTimeMillis() / 1000)}), Toast.LENGTH_LONG).show();
+        }
+
+    }
+
+
+
+    @Override
+    protected void onStart() {
+        // TODO Auto-generated method stub
+        YYXXCommSdk.getInstance().onStart(MainActivity.this);
+
+        super.onStart();
+    }
+
+    @Override
+    protected void onStop() {
+        // TODO Auto-generated method stub
+        YYXXCommSdk.getInstance().onStop(MainActivity.this);
+        super.onStop();
+    }
+
+    @Override
+    protected void onResume() {
+        // TODO Auto-generated method stub
+        super.onResume();
+        YYXXCommSdk.getInstance().onResume(MainActivity.this);
+    }
+
+    @Override
+    protected void onDestroy() {
+        // TODO Auto-generated method stub
+        YYXXCommSdk.getInstance().onDestroy(MainActivity.this);
+        super.onDestroy();
+//        System.exit(0);
+    }
+
+    @Override
+    protected void onPause() {
+        // TODO Auto-generated method stub
+        super.onPause();
+        YYXXCommSdk.getInstance().onPause(MainActivity.this);
+    }
+
+    @Override
+    protected void onRestart() {
+        super.onRestart();
+        YYXXCommSdk.getInstance().onRestart(MainActivity.this);
+    }
+
+
+    @Override
+    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
+        // TODO Auto-generated method stub
+        super.onActivityResult(requestCode, resultCode, data);
+        YYXXCommSdk.getInstance().onActivityResult(this, requestCode, resultCode, data);
+
+    }
+
+
+    @Override
+    public void onBackPressed() {
+        YYXXCommSdk.getInstance().openExitView(this, new ICallback() {
+            @Override
+            public void onResult(int i, String s) {
+                if (i == ResultInfo.CODE_SUCCESS){
+                    if (YYXXCommSdk.getInstance().hasExitView(MainActivity.this)){
+                        System.exit(0);
+                    }else {
+                        new AlertDialog.Builder(MainActivity.this)
+                                .setMessage("是否关闭游戏?")
+                                .setTitle("温馨提示")
+                                .setPositiveButton("确定", new DialogInterface.OnClickListener() {
+                                    @Override
+                                    public void onClick(DialogInterface dialogInterface, int i) {
+                                        System.exit(0);
+                                    }
+                                })
+                                .setNegativeButton("取消",null)
+                                .create()
+                                .show();
+                    }
+                }
+            }
+        });
+
+    }
+
+
+
+    @Override
+    public void onConfigurationChanged(Configuration newConfig) {
+        // TODO Auto-generated method stub
+        super.onConfigurationChanged(newConfig);
+        YYXXCommSdk.getInstance().onConfigurationChanged(this,newConfig);
+    }
+
+    @Override
+
+
+    public void onWindowFocusChanged(boolean hasFocus) {
+        super.onWindowFocusChanged(hasFocus);
+        YYXXCommSdk.getInstance().onWindowFocusChanged(this, hasFocus);
+    }
+
+    @Override
+    protected void onNewIntent(Intent intent) {
+        super.onNewIntent(intent);
+        YYXXCommSdk.getInstance().onNewIntent(this, intent);
+    }
+
+    @Override
+    public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults) {
+        super.onRequestPermissionsResult(requestCode, permissions, grantResults);
+        YYXXCommSdk.getInstance().onRequestPermissionsResult(requestCode, permissions, grantResults);
+
+    }
+
+
+
+    public static boolean judgeStrNull(String str) {
+        return str == null || str.equals("");
+    }
+
+    @Override
+    protected void onSaveInstanceState(Bundle outState) {
+        super.onSaveInstanceState(outState);
+    }
+
+}

+ 6 - 0
app/src/main/java/com/example/yyxx/merge/channel/SplashActivity.java

@@ -0,0 +1,6 @@
+package com.example.yyxx.merge.channel;
+
+import cn.yyxx.commsdk.base.YYXXWelcomeActivity;
+
+public class SplashActivity extends YYXXWelcomeActivity {
+}

+ 34 - 0
app/src/main/res/drawable-v24/ic_launcher_foreground.xml

@@ -0,0 +1,34 @@
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:aapt="http://schemas.android.com/aapt"
+    android:width="108dp"
+    android:height="108dp"
+    android:viewportWidth="108"
+    android:viewportHeight="108">
+    <path
+        android:fillType="evenOdd"
+        android:pathData="M32,64C32,64 38.39,52.99 44.13,50.95C51.37,48.37 70.14,49.57 70.14,49.57L108.26,87.69L108,109.01L75.97,107.97L32,64Z"
+        android:strokeWidth="1"
+        android:strokeColor="#00000000">
+        <aapt:attr name="android:fillColor">
+            <gradient
+                android:endX="78.5885"
+                android:endY="90.9159"
+                android:startX="48.7653"
+                android:startY="61.0927"
+                android:type="linear">
+                <item
+                    android:color="#44000000"
+                    android:offset="0.0" />
+                <item
+                    android:color="#00000000"
+                    android:offset="1.0" />
+            </gradient>
+        </aapt:attr>
+    </path>
+    <path
+        android:fillColor="#FFFFFF"
+        android:fillType="nonZero"
+        android:pathData="M66.94,46.02L66.94,46.02C72.44,50.07 76,56.61 76,64L32,64C32,56.61 35.56,50.11 40.98,46.06L36.18,41.19C35.45,40.45 35.45,39.3 36.18,38.56C36.91,37.81 38.05,37.81 38.78,38.56L44.25,44.05C47.18,42.57 50.48,41.71 54,41.71C57.48,41.71 60.78,42.57 63.68,44.05L69.11,38.56C69.84,37.81 70.98,37.81 71.71,38.56C72.44,39.3 72.44,40.45 71.71,41.19L66.94,46.02ZM62.94,56.92C64.08,56.92 65,56.01 65,54.88C65,53.76 64.08,52.85 62.94,52.85C61.8,52.85 60.88,53.76 60.88,54.88C60.88,56.01 61.8,56.92 62.94,56.92ZM45.06,56.92C46.2,56.92 47.13,56.01 47.13,54.88C47.13,53.76 46.2,52.85 45.06,52.85C43.92,52.85 43,53.76 43,54.88C43,56.01 43.92,56.92 45.06,56.92Z"
+        android:strokeWidth="1"
+        android:strokeColor="#00000000" />
+</vector>

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

@@ -0,0 +1,170 @@
+<?xml version="1.0" encoding="utf-8"?>
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+    android:width="108dp"
+    android:height="108dp"
+    android:viewportWidth="108"
+    android:viewportHeight="108">
+    <path
+        android:fillColor="#008577"
+        android:pathData="M0,0h108v108h-108z" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M9,0L9,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M19,0L19,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M29,0L29,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M39,0L39,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M49,0L49,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M59,0L59,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M69,0L69,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M79,0L79,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M89,0L89,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M99,0L99,108"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,9L108,9"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,19L108,19"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,29L108,29"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,39L108,39"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,49L108,49"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,59L108,59"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,69L108,69"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,79L108,79"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,89L108,89"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M0,99L108,99"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M19,29L89,29"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M19,39L89,39"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M19,49L89,49"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M19,59L89,59"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M19,69L89,69"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M19,79L89,79"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M29,19L29,89"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M39,19L39,89"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M49,19L49,89"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M59,19L59,89"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M69,19L69,89"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+    <path
+        android:fillColor="#00000000"
+        android:pathData="M79,19L79,89"
+        android:strokeWidth="0.8"
+        android:strokeColor="#33FFFFFF" />
+</vector>

BIN
app/src/main/res/drawable/yyxx_comm_welcome.png


+ 175 - 0
app/src/main/res/layout/activity_main.xml

@@ -0,0 +1,175 @@
+<?xml version="1.0" encoding="utf-8"?>
+<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:id="@+id/scl_1"
+
+    >
+
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+
+    android:orientation="vertical">
+
+        <Button
+            android:id="@+id/login_btn"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:text="登陆"/>
+
+        <EditText
+            android:id="@+id/et_roleid"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入角色ID"
+            android:text="120000"
+                />
+        <EditText
+            android:id="@+id/et_rolename"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入角色名称"
+            android:text="角德玛"
+            />
+        <EditText
+            android:id="@+id/et_rolelevel"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入角色等级"
+            android:text="110"
+            />
+        <EditText
+            android:id="@+id/et_rolesex"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入角色性别"
+            android:text="男"
+            />
+        <EditText
+            android:id="@+id/et_serveid"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入服务器id"
+            android:text="1"
+            />
+        <EditText
+            android:id="@+id/et_servername"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入服务器名称"
+            android:text="1服"
+        />
+        <EditText
+            android:id="@+id/et_hasgold"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入剩余元宝"
+            android:text="100"
+            />
+        <EditText
+            android:id="@+id/et_viplevel"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入vip等级"
+            android:text="5"
+            />
+        <EditText
+            android:id="@+id/et_partyname"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入帮派名称"
+            android:text="青帮"
+            />
+        <EditText
+            android:id="@+id/et_rolepower"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入战斗力"
+            android:text="100000"
+            />
+        <EditText
+            android:id="@+id/et_partyid"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入帮派id"
+            android:text="1200"
+            />
+        <EditText
+            android:id="@+id/et_rolectime"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入角色创建时间"
+            android:text="1604044240"
+            />
+        <EditText
+            android:id="@+id/et_reincarnationrCount"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入转生次数"
+            android:text="2"
+            />
+
+        <EditText
+            android:id="@+id/et_charge"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入累充金额"
+            android:text="10"
+            />
+
+        <Button
+            android:id="@+id/upload_btn"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
+            android:text="上传角色信息(创建角色)"/>
+        <Button
+            android:id="@+id/upload_btn1"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
+            android:text="上传角色信息(进入游戏)"/>
+        <Button
+            android:id="@+id/upload_btn2"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
+            android:text="上传角色信息(角色升级)"/>
+
+        <EditText
+            android:id="@+id/et_money"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:hint="请输入支付金额"
+            />
+        <Button
+            android:id="@+id/pay_btn"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
+            android:text="支付"/>
+        <Button
+            android:id="@+id/user_btn"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
+            android:text="实名认证"/>
+
+        <Button
+            android:id="@+id/logout_btn"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
+            android:text="LogOut"/>
+        <Button
+            android:id="@+id/permission"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
+            android:text="request_permission"/>
+
+
+
+    </LinearLayout>
+</ScrollView>

+ 5 - 0
app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml

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

BIN
app/src/main/res/mipmap-hdpi/ic_launcher.png


BIN
app/src/main/res/mipmap-mdpi/ic_launcher.png


BIN
app/src/main/res/mipmap-xxhdpi/ic_launcher.png


BIN
app/src/main/res/mipmap-xxxhdpi/ic_launcher.png


+ 9 - 0
app/src/main/res/values/colors.xml

@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+    <color name="colorPrimary">#008577</color>
+    <color name="colorPrimaryDark">#00574B</color>
+    <color name="colorAccent">#D81B60</color>
+
+
+
+</resources>

+ 6 - 0
app/src/main/res/values/strings.xml

@@ -0,0 +1,6 @@
+<resources>
+
+    <string name="app_name">YYXXMergeChannelSdk</string>
+
+
+</resources>

+ 9 - 0
app/src/main/res/values/styles.xml

@@ -0,0 +1,9 @@
+<resources>
+
+    <!-- Base application theme. -->
+    <style name="AppTheme" parent="android:Theme.Light">
+        <!-- Customize your theme here. -->
+
+    </style>
+
+</resources>

+ 11 - 0
build.gradle

@@ -0,0 +1,11 @@
+// Top-level build file where you can add configuration options common to all sub-projects/modules.
+plugins {
+    id 'com.android.application' version '7.1.1' apply false
+    id 'com.android.library' version '7.1.1' apply false
+}
+
+
+
+task clean(type: Delete) {
+    delete rootProject.buildDir
+}

+ 1 - 0
channel/.gitignore

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

+ 28 - 0
channel/build.gradle

@@ -0,0 +1,28 @@
+plugins {
+    id 'com.android.application'
+}
+
+android {
+    compileSdk 31
+
+    defaultConfig {
+        applicationId "com.merge.yyxx.channel"
+        minSdk 21
+        targetSdk 26
+        versionCode 1
+        versionName "1.0"
+
+     }
+
+    buildTypes {
+        release {
+            minifyEnabled false
+            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
+        }
+    }
+    compileOptions {
+        sourceCompatibility JavaVersion.VERSION_1_8
+        targetCompatibility JavaVersion.VERSION_1_8
+    }
+}
+

+ 1 - 0
channel/huawei/.gitignore

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

+ 49 - 0
channel/huawei/build.gradle

@@ -0,0 +1,49 @@
+apply plugin: 'com.android.library'
+android {
+    compileSdkVersion 28
+
+
+
+    defaultConfig {
+        minSdkVersion 21
+        targetSdkVersion 26
+        versionCode 1
+        versionName "1.0"
+
+    }
+    buildTypes {
+        release {
+            minifyEnabled false
+            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
+        }
+    }
+
+    buildFeatures {
+        buildConfig = false
+    }
+
+    lintOptions {
+        abortOnError false
+    }
+
+}
+
+dependencies {
+
+    api fileTree(dir: 'libs', include: ['*.jar'])
+
+    api 'com.huawei.hms:base:6.3.0.301'
+    api 'com.huawei.hms:hwid:6.4.0.300'
+    api 'com.huawei.hms:iap:6.3.0.300'
+    api 'com.huawei.hms:game:6.2.0.301'
+    api 'com.huawei.hms:hianalytics:6.4.1.302'
+
+
+    api 'com.huawei.hms:ads-identifier:3.4.39.302'
+    api 'com.huawei.hms:ads-installreferrer:3.4.39.302'
+
+
+    implementation project(':YYXXCommSdk')
+}
+apply from: 'buildJar.gradle'
+

+ 20 - 0
channel/huawei/buildJar.gradle

@@ -0,0 +1,20 @@
+def SDK_BASENAME = "huawei"
+def sdkDestinationPath = "build/jar/"
+def zipFile = file('build/intermediates/aar_main_jar/release/classes.jar')
+
+static def buildTime() {
+    return new Date().format("yyyyMMddHHmm", TimeZone.getDefault())
+}
+
+task deleteBaseBuild(type: Delete) {
+    delete sdkDestinationPath
+}
+
+task makeJar(type: Jar) {
+    from zipTree(zipFile)
+    baseName(SDK_BASENAME)
+    destinationDir(file(sdkDestinationPath))
+
+}
+
+makeJar.dependsOn(deleteBaseBuild, build)

+ 21 - 0
channel/huawei/proguard-rules.pro

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

+ 29 - 0
channel/huawei/src/main/AndroidManifest.xml

@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.merge.yyxx.huawei">
+
+
+    <application>
+
+
+
+        <meta-data
+            android:name="com.huawei.hms.client.channel.androidMarket"
+            android:value="false"
+            />
+    </application>
+
+
+    <uses-permission android:name="android.permission.INTERNET" />
+    <uses-permission android:name="android.permission.READ_PHONE_STATE" />
+    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
+    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
+    <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
+
+    <uses-permission android:name="android.permission.BLUETOOTH_ADMIN"/>
+    <uses-permission android:name="android.permission.BLUETOOTH"/>
+
+    <uses-permission
+        android:name="com.huawei.appmarket.service.commondata.permission.GET_COMMON_DATA" />
+
+</manifest>

+ 27 - 0
channel/huawei/src/main/assets/agconnect-services.json

@@ -0,0 +1,27 @@
+{
+	"agcgw":{
+		"backurl":"connect-drcn.dbankcloud.cn",
+		"url":"connect-drcn.hispace.hicloud.com"
+	},
+	"client":{
+		"cp_id":"890086200300022659",
+		"product_id":"9105385871708146003",
+		"client_id":"207609245833626624",
+		"client_secret":"6F94EAF0B2DC9381D923F4430274AA1E09DC02283B2CFB5C42AB6A1A67C6C277",
+		"app_id":"101215129",
+		"package_name":"com.yyxx.qyj2.huawei",
+		"api_key":"CV6QVxagVDKVisaDUdxsPfJ0syCSveoIFbZD2LVgAktXDr34ERfYRx1rNgV20PkOXTM9nperi09/WcMNdg4ZTlW01AGP"
+	},
+	"service":{
+		"analytics":{
+			"collector_url":"datacollector-drcn.dt.hicloud.com,datacollector-drcn.dt.dbankcloud.cn",
+			"resource_id":"p1",
+			"channel_id":""
+		},
+		"ml":{
+			"mlservice_url":"ml-api-drcn.ai.dbankcloud.com,ml-api-drcn.ai.dbankcloud.cn"
+		}
+	},
+	"region":"CN",
+	"configuration_version":"1.0"
+}

+ 5 - 0
channel/huawei/src/main/assets/yyxx_game/yyxx_cfg.properties

@@ -0,0 +1,5 @@
+YYXX_GCP_CODE=Y010402
+YYXX_ONLINE_ENV=http://testsdkapi.yyxxgame.com
+YYXX_PLATFORM=HUAWEI
+#channel params
+

+ 169 - 0
channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/ChannelBridge.java

@@ -0,0 +1,169 @@
+package cn.yyxx.commsdk.impl.merge.channel;
+
+import android.app.Activity;
+import android.app.Application;
+import android.content.Context;
+import android.content.Intent;
+import android.content.res.Configuration;
+import android.os.Bundle;
+
+import org.json.JSONObject;
+
+import cn.yyxx.commsdk.base.entity.SdkOrderInfo;
+import cn.yyxx.commsdk.base.entity.SdkRoleInfo;
+import cn.yyxx.commsdk.base.entity.bean.InitBean;
+import cn.yyxx.commsdk.base.internal.ICallback;
+import cn.yyxx.commsdk.base.internal.IMsaDeviceCallback;
+import cn.yyxx.commsdk.base.internal.feature.IApplication;
+import cn.yyxx.commsdk.base.internal.feature.IFeature;
+import cn.yyxx.commsdk.base.internal.feature.ILifeCycle;
+import cn.yyxx.commsdk.base.internal.feature.IOrder;
+import cn.yyxx.commsdk.impl.merge.channel.huawei.ChannelBridgeImpl;
+
+public class ChannelBridge implements IFeature, ILifeCycle, IApplication, IOrder {
+
+    private ChannelBridgeImpl impl = null;
+
+    public ChannelBridge(Context context) {
+        if (null == impl) {
+            impl = new ChannelBridgeImpl(context);
+        }
+    }
+
+
+
+
+    @Override
+    public void attachBaseContext(Application application, Context context) {
+        impl.attachBaseContext(application,context);
+    }
+
+    @Override
+    public void initApplication(Application application) {
+        impl.initApplication(application);
+
+    }
+
+    @Override
+    public void initialize(Activity activity, ICallback callback) {
+        impl.initialize(activity,callback);
+    }
+
+    @Override
+    public void initializeSuccess(Activity activity, int loginStatus) {
+        impl.initializeSuccess(activity,loginStatus);
+    }
+
+    @Override
+    public void setLogoutListener(Activity activity, ICallback callback) {
+        impl.setLogoutListener(activity,callback);
+    }
+
+    @Override
+    public void login(final Activity activity, InitBean initBean, final ICallback callback) {
+        impl.login(activity,initBean,callback);
+    }
+
+    @Override
+    public void logout() {
+        impl.logout();
+    }
+
+
+
+    @Override
+    public boolean hasExitView(Activity activity) {
+        return impl.hasExitView(activity);
+    }
+
+    @Override
+    public void openExitView(Activity activity,ICallback callback) {
+        impl.openExitView(activity,callback);
+    }
+
+    @Override
+    public void uploadRoleInfo(Activity activity, String type, SdkRoleInfo roleInfo) {
+        impl.uploadRoleInfo(activity,type,roleInfo);
+    }
+
+    @Override
+    public void reportGameEvent(String event, JSONObject message) {
+        impl.reportGameEvent(event,message);
+    }
+
+    @Override
+    public void initMsaDeviceIds(Context context, IMsaDeviceCallback iMsaDeviceCallback) {
+        impl.initMsaDeviceIds(context,iMsaDeviceCallback);
+    }
+
+    @Override
+    public String getChannelOcfg(Activity activity) {
+        return impl.getChannelOcfg(activity);
+    }
+
+
+    @Override
+    public void onStart(Activity activity) {
+        impl.onStart(activity);
+    }
+
+    @Override
+    public void onResume(Activity activity) {
+        impl.onResume(activity);
+    }
+
+    @Override
+    public void onRestart(Activity activity) {
+        impl.onRestart(activity);
+    }
+
+    @Override
+    public void onPause(Activity activity) {
+        impl.onPause(activity);
+    }
+
+    @Override
+    public void onStop(Activity activity) {
+        impl.onStop(activity);
+    }
+
+    @Override
+    public void onActivityResult(Activity activity, int requestCode, int resultCode, Intent data) {
+        impl.onActivityResult(activity,requestCode,resultCode,data);
+    }
+
+    @Override
+    public void onNewIntent(Activity activity, Intent intent) {
+        impl.onNewIntent(activity,intent);
+    }
+
+    @Override
+    public void onConfigurationChanged(Activity activity, Configuration newconfig) {
+        impl.onConfigurationChanged(activity,newconfig);
+    }
+
+    @Override
+    public void onWindowFocusChanged(Activity activity, boolean hasFocus) {
+        impl.onWindowFocusChanged(activity,hasFocus);
+    }
+
+    @Override
+    public void onDestroy(Activity activity) {
+        impl.onDestroy(activity);
+
+    }
+
+    @Override
+    public void onCreate(Activity activity, Bundle savedInstanceState) {
+        impl.onCreate(activity,savedInstanceState);
+    }
+
+
+    public void startPay(Activity activity, SdkOrderInfo sdkOrderInfo,ICallback callback) {
+        impl.startPay(activity,sdkOrderInfo,callback);
+    }
+
+    public String getChannelOrderExt() {
+        return  impl.getChannelOrderExt();
+    }
+}

+ 822 - 0
channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/huawei/ChannelBridgeImpl.java

@@ -0,0 +1,822 @@
+package cn.yyxx.commsdk.impl.merge.channel.huawei;
+
+import android.app.Activity;
+import android.app.Application;
+import android.content.ContentResolver;
+import android.content.Context;
+import android.content.Intent;
+import android.content.IntentSender;
+import android.content.res.Configuration;
+import android.database.Cursor;
+import android.net.Uri;
+import android.os.Bundle;
+import android.text.TextUtils;
+
+import com.huawei.agconnect.config.AGConnectServicesConfig;
+import com.huawei.agconnect.config.LazyInputStream;
+import com.huawei.hmf.tasks.OnFailureListener;
+import com.huawei.hmf.tasks.OnSuccessListener;
+import com.huawei.hmf.tasks.Task;
+import com.huawei.hms.common.ApiException;
+import com.huawei.hms.iap.Iap;
+import com.huawei.hms.iap.IapApiException;
+import com.huawei.hms.iap.entity.ConsumeOwnedPurchaseReq;
+import com.huawei.hms.iap.entity.ConsumeOwnedPurchaseResult;
+import com.huawei.hms.iap.entity.InAppPurchaseData;
+import com.huawei.hms.iap.entity.IsEnvReadyResult;
+import com.huawei.hms.iap.entity.OrderStatusCode;
+import com.huawei.hms.iap.entity.OwnedPurchasesReq;
+import com.huawei.hms.iap.entity.OwnedPurchasesResult;
+import com.huawei.hms.iap.entity.ProductInfoReq;
+import com.huawei.hms.iap.entity.ProductInfoResult;
+import com.huawei.hms.iap.entity.PurchaseIntentReq;
+import com.huawei.hms.iap.entity.PurchaseIntentResult;
+import com.huawei.hms.jos.AntiAddictionCallback;
+import com.huawei.hms.jos.AppParams;
+import com.huawei.hms.jos.AppUpdateClient;
+import com.huawei.hms.jos.JosApps;
+import com.huawei.hms.jos.JosAppsClient;
+import com.huawei.hms.jos.games.AppPlayerInfo;
+import com.huawei.hms.jos.games.Games;
+import com.huawei.hms.jos.games.PlayersClient;
+import com.huawei.hms.jos.games.player.Player;
+import com.huawei.hms.support.account.AccountAuthManager;
+import com.huawei.hms.support.account.request.AccountAuthParams;
+import com.huawei.hms.support.account.request.AccountAuthParamsHelper;
+import com.huawei.hms.support.account.service.AccountAuthService;
+import com.huawei.hms.support.api.client.Status;
+import com.huawei.hms.support.hwid.HuaweiIdAuthManager;
+import com.huawei.hms.support.hwid.result.AuthHuaweiId;
+import com.huawei.updatesdk.service.appmgr.bean.ApkUpgradeInfo;
+import com.huawei.updatesdk.service.otaupdate.CheckUpdateCallBack;
+
+import org.json.JSONException;
+import org.json.JSONObject;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.List;
+
+import cn.yyxx.commsdk.base.constants.Constants;
+import cn.yyxx.commsdk.base.entity.ResultInfo;
+import cn.yyxx.commsdk.base.entity.SdkOrderInfo;
+import cn.yyxx.commsdk.base.entity.SdkRoleInfo;
+import cn.yyxx.commsdk.base.entity.bean.InitBean;
+import cn.yyxx.commsdk.base.internal.ICallback;
+import cn.yyxx.commsdk.base.internal.IMsaDeviceCallback;
+import cn.yyxx.commsdk.base.internal.feature.IApplication;
+import cn.yyxx.commsdk.base.internal.feature.IFeature;
+import cn.yyxx.commsdk.base.internal.feature.ILifeCycle;
+import cn.yyxx.commsdk.base.internal.feature.IOrder;
+import cn.yyxx.commsdk.base.utils.Logger;
+import cn.yyxx.commsdk.impl.merge.LoginViewModel;
+import cn.yyxx.commsdk.impl.merge.channel.msa.MsaDeviceHandler;
+import cn.yyxx.commsdk.impl.merge.channel.utils.ParamsUtils;
+
+/**
+ * @author #Suyghur.
+ * Created on 2021/12/25
+ */
+public class ChannelBridgeImpl implements IFeature, ILifeCycle, IApplication, IOrder {
+
+
+
+    LoginViewModel loginViewModel;
+
+    private String trackId;
+
+    public final static  String  TAG = "HuaWeiSDK";
+
+    public final static  String  AD_TAG = "huawei_pkg_data";
+
+    private boolean hasInit = false;
+
+
+    String notifyUrl = "";
+
+
+    private static final int INDEX_REFERRER = 0;
+
+    private static final int INDEX_ENTER_AG_TIME = 1;
+    private static final int INDEX_START_DOWNLOAD_TIME = 2;
+    private static final int INDEX_TRACKID = 4;
+    private static final String PROVIDER_URI = "content://com.huawei.appmarket.commondata/item/5";
+
+
+
+
+    private AccountAuthParams mAuthParam;
+    private AccountAuthService mAuthManager;
+
+    private String playerId;
+
+
+
+    //login
+    public static final int REQUEST_SIGN_IN_LOGIN = 1002;
+
+    //login
+    public static final int REQUEST_IAP = 6666;
+
+    private Activity activity;
+
+    public ChannelBridgeImpl(Context context){
+
+    }
+
+    @Override
+    public void attachBaseContext(Application application, Context context) {
+        /**
+        AGConnectOptionsBuilder agConnectOptionsBuilder = new AGConnectOptionsBuilder();
+        try {
+            agConnectOptionsBuilder.setRoutePolicy(AGCRoutePolicy.CHINA)
+                    .setInputStream(context.getAssets().open("agconnect-services.json"));
+
+            AGConnectInstance.initialize(application, agConnectOptionsBuilder);
+
+        } catch (IOException e) {
+            e.printStackTrace();
+        }
+
+        // 初始化AGC框架
+**/
+
+        AGConnectServicesConfig config = AGConnectServicesConfig.fromContext(context);
+        config.overlayWith(new LazyInputStream(context) {
+            public InputStream get(Context context) {
+                try {
+                    return context.getAssets().open("agconnect-services.json");
+                } catch (IOException e) {
+                    return null;
+                }
+            }
+        });
+
+    }
+
+    @Override
+    public void initApplication(Application application) {
+
+
+
+
+
+    }
+
+    @Override
+    public void initialize(Activity activity, ICallback callback) {
+        init(activity);
+        checkUpdate(activity);
+        trackId = getTrackId(activity);
+
+        if (judgeStrNull(trackId)){
+            Logger.i(TAG,"is null");
+        }else{
+            Logger.i(TAG,trackId);
+        }
+
+        hasInit = true;
+    }
+
+    public void init(Activity ac) {
+
+        JosAppsClient appsClient = JosApps.getJosAppsClient(ac);
+        AppParams appParams = new AppParams();
+        appParams.setAuthScope(AccountAuthParams.DEFAULT_AUTH_REQUEST_PARAM_GAME);
+        appParams.setAntiAddictionCallback(new AntiAddictionCallback() {
+            @Override
+            public void onExit() {
+                System.exit(0);
+            }
+        });
+        appsClient.init(appParams);
+        activity = ac;
+
+    }
+    public void checkUpdate(final Activity ac) {
+        AppUpdateClient client = JosApps.getAppUpdateClient(ac);
+        client.checkAppUpdate(ac, new CheckUpdateCallBack() {
+            @Override
+            public void onUpdateInfo(Intent intent) {
+
+                if (intent != null) {
+                    Serializable info = intent.getSerializableExtra("updatesdk_update_info");
+                    if (info instanceof ApkUpgradeInfo) {
+
+                        ApkUpgradeInfo apkUpgradeInfo = (ApkUpgradeInfo) info;
+
+                    }
+                }
+            }
+
+            @Override
+            public void onMarketInstallInfo(Intent intent) {
+
+            }
+
+            @Override
+            public void onMarketStoreError(int i) {
+
+            }
+
+            @Override
+            public void onUpdateStoreError(int i) {
+
+            }
+        });
+    }
+
+    /**
+     * 获取 trackid
+
+     * @return json 格式字符串
+     */
+    private String getTrackId(Activity activity) {
+        String pkgName = getPackageName(activity);
+        String trackId = null;
+        Cursor cursor = null;
+        Uri uri = Uri.parse(PROVIDER_URI);
+        ContentResolver contentResolver = activity.getContentResolver();
+        String packageName[] = new String[] { pkgName };
+        try {
+            cursor = contentResolver.query(uri, null, null, packageName, null);
+
+            if (cursor != null) {
+                cursor.moveToFirst();
+                Logger.i(TAG, "packageName=" + pkgName);
+                if (cursor.getColumnCount() > INDEX_TRACKID) {
+                    // 10.5.0.300 及之后版本
+                    Logger.i(TAG, "version is Version greater than 10.5.0.300");
+                    Logger.i(TAG, "referrer=" + cursor.getString(INDEX_REFERRER));
+                    Logger.i(TAG, "enter appgallery time=" +
+                            cursor.getString(INDEX_ENTER_AG_TIME));
+                    Logger.i(TAG, "donwload time=" +
+                            cursor.getString(INDEX_START_DOWNLOAD_TIME));
+                    Logger.i(TAG, "track id=" + cursor.getString(INDEX_TRACKID));
+                    trackId = cursor.getString(INDEX_TRACKID);
+                } else if (cursor.getColumnCount() > INDEX_START_DOWNLOAD_TIME){
+                    // 兼容旧版本
+                    Logger.i(TAG, "version is Version less than 10.5.0.300");
+                    trackId = cursor.getString(INDEX_REFERRER);
+                    Logger.i(TAG, "referrer=" + cursor.getString(INDEX_REFERRER));
+                    Logger.i(TAG, "enter appgallery time=" +
+                            cursor.getString(INDEX_ENTER_AG_TIME));
+                    Logger.i(TAG, "donwload time=" +
+                            cursor.getString(INDEX_START_DOWNLOAD_TIME));
+                    return trackId;
+                } else {
+                    // 不支持归因信息
+                    Logger.e(TAG, "appgallery not support");
+                }
+            }
+        }finally {
+            if (cursor != null) {
+                cursor.close();
+            }
+
+        }
+        // 如果 trackid 是 json 格式,打印具体内容
+        if (!TextUtils.isEmpty(trackId)) {
+            try {
+                JSONObject attributionMap = new JSONObject(trackId);
+
+                Logger.i(TAG, "json channel id=" + attributionMap.getString("channel"));
+                Logger.i(TAG, "json callback=" + attributionMap.get("callback"));
+                Logger.i(TAG, "json taskid=" + attributionMap.get("taskid"));
+
+            } catch (JSONException e) {
+                e.printStackTrace();
+            }
+            Logger.i(TAG, "trackId is json  :" + trackId);
+        }
+
+        return trackId;
+    }
+
+    @Override
+    public void initializeSuccess(Activity activity, int loginStatus) {
+
+    }
+
+    @Override
+    public void setLogoutListener(Activity activity, ICallback callback) {
+
+    }
+
+    @Override
+    public void login(final Activity activity, InitBean initBean, ICallback callback) {
+
+        loginViewModel  = new LoginViewModel(callback);
+
+        signIn(activity);
+
+    }
+
+    private void signIn(Activity activity) {
+        mAuthParam = new AccountAuthParamsHelper(AccountAuthParams.DEFAULT_AUTH_REQUEST_PARAM)
+                .setIdToken()
+                .setAccessToken()
+                .createParams();
+        mAuthManager = AccountAuthManager.getService(activity, mAuthParam);
+        activity.startActivityForResult(mAuthManager.getSignInIntent(),REQUEST_SIGN_IN_LOGIN);
+
+
+    }
+
+
+
+    @Override
+    public void logout() {
+        signOut();
+    }
+    /**
+     * Codelab Code
+     * sign Out by signOut
+     */
+    private void signOut() {
+        Task<Void> signOutTask = mAuthManager.signOut();
+        signOutTask.addOnSuccessListener(new OnSuccessListener<Void>() {
+            @Override
+            public void onSuccess(Void aVoid) {
+                Logger.i(TAG, "signOut Success");
+            }
+        }).addOnFailureListener(new OnFailureListener() {
+            @Override
+            public void onFailure(Exception e) {
+                Logger.i(TAG, "signOut fail");
+            }
+        });
+    }
+
+    @Override
+    public boolean hasExitView(Activity activity) {
+        return false;
+    }
+
+    @Override
+    public void openExitView(Activity activity, ICallback iCallback) {
+        iCallback.onResult(ResultInfo.CODE_SUCCESS,"EXIT GAME.");
+    }
+
+    @Override
+    public void uploadRoleInfo(Activity activity, String type, SdkRoleInfo roleInfo) {
+
+
+        if (type == Constants.UPLOAD_TYPE_ENTER_GAME){
+            savePlayerInfo(activity,roleInfo.getServerName(),roleInfo.getRoleLevel(),roleInfo.getRoleName(),roleInfo.getPartyName());
+        }
+    }
+
+    public void savePlayerInfo(Activity ac, String serverName,String roleLevel,String roleName,String partyName) {
+        if (TextUtils.isEmpty(playerId)) {
+
+            return;
+        }
+        PlayersClient client = Games.getPlayersClient(ac);
+        AppPlayerInfo appPlayerInfo = new AppPlayerInfo();
+        appPlayerInfo.area = serverName;
+        appPlayerInfo.rank = roleLevel;
+        appPlayerInfo.role = roleName;
+        appPlayerInfo.sociaty = partyName;
+        appPlayerInfo.playerId = playerId;
+        Task<Void> task = client.savePlayerInfo(appPlayerInfo);
+        task.addOnSuccessListener(new OnSuccessListener<Void>() {
+            @Override
+            public void onSuccess(Void v) {
+
+            }
+        }).addOnFailureListener(new OnFailureListener() {
+            @Override
+            public void onFailure(Exception e) {
+                if (e instanceof ApiException) {
+                    String result = "rtnCode:" + ((ApiException) e).getStatusCode();
+
+                }
+            }
+        });
+    }
+
+    @Override
+    public void reportGameEvent(String event, JSONObject message) {
+
+    }
+
+    @Override
+    public void initMsaDeviceIds(Context context, IMsaDeviceCallback iMsaDeviceCallback) {
+        MsaDeviceHandler.initMsaDeviceIds(context,iMsaDeviceCallback);
+    }
+
+    @Override
+    public String getChannelOcfg(Activity activity) {
+
+        String huawei_pkg_data = RealAssertUtils.getSharedPreferences(activity,AD_TAG,AD_TAG);
+
+        Logger.i(AD_TAG + " : ", huawei_pkg_data);
+
+        if (judgeStrNull(huawei_pkg_data)){
+
+            Logger.i(AD_TAG + " : ","is null, frist open the game.");
+
+            String gcp_code = ParamsUtils.getCfgParam(activity,"YYXX_GCP_CODE");
+            if (judgeStrNull(gcp_code)){
+                return null;
+            }else{
+
+                String sp_code  = RealAssertUtils.GetApplicationMetaData(activity,"YYXX_COMM_SP_CODE");
+                JSONObject json = new JSONObject();
+                try {
+                    json.put("gcp_code",gcp_code);
+                    if (!judgeStrNull(sp_code)){
+                        json.put("sp_code",sp_code);
+                    }
+
+                } catch (JSONException e) {
+                    e.printStackTrace();
+                }
+                RealAssertUtils.saveSharedPreferences(activity,AD_TAG,AD_TAG,json.toString());
+                return json.toString();
+            }
+        }else{
+            return huawei_pkg_data;
+        }
+
+
+    }
+
+
+    @Override
+    public void onStart(Activity activity) {
+
+    }
+
+    @Override
+    public void onResume(Activity activity) {
+        showFloatWindowNewWay(activity);
+    }
+
+    @Override
+    public void onRestart(Activity activity) {
+
+    }
+
+    @Override
+    public void onPause(Activity activity) {
+        hideFloatWindowNewWay(activity);
+    }
+
+    @Override
+    public void onStop(Activity activity) {
+
+    }
+
+    @Override
+    public void onActivityResult(Activity activity, int requestCode, int resultCode, Intent data) {
+        if (requestCode == REQUEST_SIGN_IN_LOGIN) {
+            //login success
+            //get user message by parseAuthResultFromIntent
+            Task<AuthHuaweiId> authHuaweiIdTask = HuaweiIdAuthManager.parseAuthResultFromIntent(data);
+            if (authHuaweiIdTask.isSuccessful()) {
+                currentPlayerInfo(activity);
+
+            } else {
+                Logger.i(TAG, "signIn failed: " + ((ApiException) authHuaweiIdTask.getException()).getStatusCode());
+            }
+        }
+    }
+
+
+    private void currentPlayerInfo(final Activity ac) {
+
+        PlayersClient client = Games.getPlayersClient(ac);
+        Task<Player> task = client.getCurrentPlayer();
+        task.addOnSuccessListener(new OnSuccessListener<Player>() {
+            @Override
+            public void onSuccess(Player player) {
+                String ts = player.getSignTs();
+                playerId = player.getPlayerId();
+                String playerLevel = player.getLevel() + "";
+                String playerSSign = player.getPlayerSign();
+
+
+                JSONObject json = new JSONObject();
+                try {
+                    json.put("ts",ts);
+                    json.put("playerId",playerId);
+                    json.put("playerLevel",playerLevel);
+                    json.put("playerSSign",playerSSign);
+
+
+                    if (!judgeStrNull(trackId)){
+                        json.put("ntrackId",trackId);
+                    }
+
+                } catch (JSONException e) {
+                    e.printStackTrace();
+                }
+
+
+                if (playerId != null && playerLevel != null &&playerLevel != null && playerSSign != null){
+                    loginViewModel.verifyChannelInfo(ac,json.toString());
+                }
+
+
+
+
+            }
+        }).addOnFailureListener(new OnFailureListener() {
+            @Override
+            public void onFailure(Exception e) {
+                // 获取玩家信息失败
+                if (e instanceof ApiException) {
+                    if (((ApiException) e).getStatusCode() == 7018){
+                        init(ac);
+                    }
+
+                }
+            }
+        });
+    }
+
+
+    @Override
+    public void onNewIntent(Activity activity, Intent intent) {
+
+    }
+
+    @Override
+    public void onConfigurationChanged(Activity activity, Configuration newconfig) {
+
+    }
+
+    @Override
+    public void onWindowFocusChanged(Activity activity, boolean hasFocus) {
+
+    }
+
+    @Override
+    public void onDestroy(Activity activity) {
+
+    }
+
+    @Override
+    public void onCreate(Activity activity, Bundle savedInstanceState) {
+
+    }
+
+    @Override
+    public void startPay(Activity activity, SdkOrderInfo sdkOrderInfo, final ICallback callback) {
+
+
+
+        String order_id = sdkOrderInfo.getOrder_id();
+
+
+        String trdext = sdkOrderInfo.getOrder_ext();
+        String productId = "";
+
+
+
+
+        try {
+            JSONObject json = new JSONObject(trdext);
+            notifyUrl = json.getString("notifyUrl");
+            productId = json.getString("productId");
+        } catch (JSONException e) {
+            e.printStackTrace();
+        }
+
+        final PurchaseIntentReq request = new PurchaseIntentReq();
+
+        request.setDeveloperPayload(order_id);
+        request.setPriceType(0);
+        request.setProductId(productId);
+
+
+
+        Task<IsEnvReadyResult> task = Iap.getIapClient(activity).isEnvReady();
+        task.addOnSuccessListener(new OnSuccessListener<IsEnvReadyResult>() {
+            @Override
+            public void onSuccess(IsEnvReadyResult result) {
+                // 获取接口请求的结果
+
+                obtainOwnedPurchases(activity,request);
+
+            }
+        }).addOnFailureListener(new OnFailureListener() {
+            @Override
+            public void onFailure(Exception e) {
+                if (e instanceof IapApiException) {
+                    IapApiException apiException = (IapApiException) e;
+                    // Status不支持序列化操作
+                    Status status = apiException.getStatus();
+                    String error =  status.getErrorString();
+                    if (status.getStatusCode() == OrderStatusCode.ORDER_HWID_NOT_LOGIN) {
+                        // 未登录帐号
+                        if (status.hasResolution()) {
+                            try {
+                                // 6666是您自定义的常量
+                                // 启动IAP返回的登录页面
+                                status.startResolutionForResult(activity, REQUEST_IAP);
+
+                            } catch (IntentSender.SendIntentException exp) {
+                            }
+                        }
+                    } else if (status.getStatusCode() == OrderStatusCode.ORDER_ACCOUNT_AREA_NOT_SUPPORTED) {
+
+                    }
+                } else {
+                    // 其他外部错误
+
+                }
+            }
+        });
+
+        }
+
+
+    void obtainOwnedPurchases(Activity activity, final PurchaseIntentReq purchaseIntentReq){
+
+        OwnedPurchasesReq req = new OwnedPurchasesReq();
+        req.setPriceType(0);
+        Task<OwnedPurchasesResult> task = Iap.getIapClient(activity).obtainOwnedPurchases(req);
+        task.addOnSuccessListener(new OnSuccessListener<OwnedPurchasesResult>() {
+            @Override
+            public void onSuccess(OwnedPurchasesResult result) {
+                // Obtain the execution result.
+                if (!result.getInAppPurchaseDataList().isEmpty()) {
+
+                    for (int i = 0; i < result.getInAppPurchaseDataList().size(); i++) {
+                        String inAppPurchaseData = result.getInAppPurchaseDataList().get(i);
+                        String InAppSignature = result.getInAppSignature().get(i);
+                        onPaySuccessNotify(activity,inAppPurchaseData,InAppSignature,notifyUrl);
+                    }
+                }else{
+                    obtainProductInfo(activity,purchaseIntentReq);
+                }
+            }
+        }).addOnFailureListener(new OnFailureListener() {
+            @Override
+            public void onFailure(Exception e) {
+                if (e instanceof IapApiException) {
+                    IapApiException apiException = (IapApiException)e;
+                    Status status = apiException.getStatus();
+                    int returnCode = apiException.getStatusCode();
+                } else {
+                    // Other external errors
+                }
+            }
+        });
+    }
+
+
+    void obtainProductInfo(final Activity activity, final PurchaseIntentReq req){
+        ProductInfoReq productInfoReq = new ProductInfoReq();
+        productInfoReq.setPriceType(0);
+        List<String> productList = new ArrayList<>();
+        productList.add(req.getProductId());
+        productInfoReq.setProductIds(productList);
+        Iap.getIapClient(activity).obtainProductInfo(productInfoReq).addOnSuccessListener(new OnSuccessListener<ProductInfoResult>() {
+            @Override
+            public void onSuccess(ProductInfoResult productInfoResult) {
+                createPurchaseIntent(req,activity);
+            }
+        }).addOnFailureListener(new OnFailureListener() {
+            @Override
+            public void onFailure(Exception e) {
+                Logger.i(TAG, "查询商品异常");
+
+            }
+        });
+    }
+
+
+    private void createPurchaseIntent(PurchaseIntentReq req, final Activity activity){
+
+// 调用createPurchaseIntent接口创建托管商品订单
+        Task<PurchaseIntentResult> task = Iap.getIapClient(activity).createPurchaseIntent(req);
+        task.addOnSuccessListener(new OnSuccessListener<PurchaseIntentResult>() {
+            @Override
+            public void onSuccess(PurchaseIntentResult result) {
+                // 获取创建订单的结果
+                Status status = result.getStatus();
+                if (status.hasResolution()) {
+                    try {
+                        // 6666是您自定义的常量
+                        // 启动IAP返回的收银台页面
+                        status.startResolutionForResult(activity, REQUEST_IAP);
+                    } catch (IntentSender.SendIntentException exp) {
+                    }
+                }
+            }
+        }).addOnFailureListener(new OnFailureListener() {
+            @Override
+            public void onFailure(Exception e) {
+                if (e instanceof IapApiException) {
+
+                    IapApiException apiException = (IapApiException) e;
+
+                } else {
+                    // 其他外部错误
+                }
+            }
+        });
+    }
+
+    private void onPaySuccessNotify(Activity activity,String inAppPurchaseData,String inAppPurchaseDataSignature,String notifyUrl){
+
+        if (judgeStrNull(inAppPurchaseData)){
+
+            return;
+        }
+        JSONObject json  = new JSONObject();
+        try {
+            json.put("hwData",inAppPurchaseData);
+            json.put("hwSign",inAppPurchaseDataSignature);
+
+        } catch (JSONException e) {
+            e.printStackTrace();
+        }
+
+        loginViewModel.requestChannelExtInfo(activity,notifyUrl, json, new ICallback() {
+            @Override
+            public void onResult(int code, String result) {
+                if (code == ResultInfo.CODE_SUCCESS){
+
+                        InAppPurchaseData inAppPurchaseDataBean = null;
+                        try {
+                            inAppPurchaseDataBean = new InAppPurchaseData(inAppPurchaseData);
+                        } catch (JSONException e) {
+                            e.printStackTrace();
+                        }
+                        String token = inAppPurchaseDataBean.getPurchaseToken();
+                        consumeOwnedPurchase(activity,token);
+
+                    }
+
+            }
+        });
+
+
+    }
+
+
+    public void consumeOwnedPurchase(Activity activity,String purchaseToken){
+        // Constructs a ConsumeOwnedPurchaseReq object.
+
+        ConsumeOwnedPurchaseReq req = new ConsumeOwnedPurchaseReq();
+        req.setPurchaseToken(purchaseToken);
+// to call the consumeOwnedPurchase API.
+// To get the Activity instance that calls this API.
+
+        Task<ConsumeOwnedPurchaseResult> task = Iap.getIapClient(activity).consumeOwnedPurchase(req);
+        task.addOnSuccessListener(new OnSuccessListener<ConsumeOwnedPurchaseResult>() {
+            @Override
+            public void onSuccess(ConsumeOwnedPurchaseResult result) {
+                // Obtain the result
+                Logger.i("消耗成功");
+            }
+        }).addOnFailureListener(new OnFailureListener() {
+            @Override
+            public void onFailure(Exception e) {
+                if (e instanceof IapApiException) {
+                    IapApiException apiException = (IapApiException)e;
+                    Status status = apiException.getStatus();
+                    int returnCode = apiException.getStatusCode();
+                    Logger.i("消耗失败:"+status);
+                } else {
+                    // Other external errors
+                }
+            }
+        });
+    }
+
+
+    @Override
+    public String getChannelOrderExt() {
+        return null;
+    }
+
+    private boolean judgeStrNull(String str) {
+        return (str == null || str.equals(""));
+    }
+
+
+    public static String getPackageName(Activity ac) {
+
+        String pkgName = ac.getPackageName();
+        return pkgName;
+    }
+
+
+    private void hideFloatWindowNewWay(Activity activity) {
+        Games.getBuoyClient(activity).hideFloatWindow();
+    }
+    private void showFloatWindowNewWay(Activity ac) {
+        if (!hasInit) {
+            init(ac);
+        }
+        Games.getBuoyClient(ac).showFloatWindow();
+    }
+}

+ 96 - 0
channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/huawei/RealAssertUtils.java

@@ -0,0 +1,96 @@
+package cn.yyxx.commsdk.impl.merge.channel.huawei;
+
+import android.app.Activity;
+import android.content.Context;
+import android.content.SharedPreferences;
+import android.content.pm.ApplicationInfo;
+import android.content.pm.PackageManager;
+
+import java.io.BufferedReader;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+
+public class RealAssertUtils {
+    public static String getParamCnfValuebyKey(Context context,
+                                               String filename, String key) {
+        try {
+            return readAssertFileWithKey(context, filename, key);
+        } catch (IOException e) {
+            // TODO Auto-generated catch block
+            e.printStackTrace();
+        }
+        return "";
+    }
+
+    public static String readAssertFileWithKey(Context context,
+                                               String file_name, String key) throws IOException {
+        String web_str = "";
+
+        InputStream input_stream = context.getAssets().open(file_name);
+
+        InputStreamReader inputStreamReader = new InputStreamReader(
+                input_stream);
+
+        BufferedReader reader = new BufferedReader(inputStreamReader);
+
+        String tempString = null;
+
+        while ((tempString = reader.readLine()) != null) {
+
+            if (tempString.contains(key)) {
+
+                web_str = tempString.substring(tempString.indexOf("=") + 1,
+                        tempString.length());
+                break;
+            }
+        }
+        reader.close();
+
+        return web_str;
+    }
+
+    public static String GetApplicationMetaData(Context context, String metaName) {
+        Object metaData = "";
+
+        if (null == metaName || metaName.isEmpty()) {
+
+            return "";
+        }
+        try {
+            ApplicationInfo info = context.getPackageManager()
+                    .getApplicationInfo(context.getPackageName(),
+                            PackageManager.GET_META_DATA);
+            metaData = info.metaData.get(metaName);
+            // 是否有引用
+            if (null != metaData && metaData.toString().contains("ref=")) {
+                String newMetaName = metaData.toString().split("=")[1];
+                metaData = GetApplicationMetaData(context, newMetaName);
+            }
+        } catch (PackageManager.NameNotFoundException e) {
+
+        }
+        if (null == metaData) {
+            metaData = "";
+        }
+        return metaData.toString();
+    }
+
+    public static String getSharedPreferences(Context context,String head,String key){
+        SharedPreferences sp = context.getSharedPreferences(head, Activity.MODE_PRIVATE);
+        return  sp.getString(key, "") ;
+    }
+
+
+    public static void saveSharedPreferences( Context context,String head, String key, String value) {
+        SharedPreferences sp = context
+                .getSharedPreferences(head,
+                        Activity.MODE_PRIVATE);
+        // 实例化SharedPreferences.Editor对象(第二步)
+        SharedPreferences.Editor editor = sp.edit();
+        // 用putString的方法保存数据
+        editor.putString(key, value);
+        // 提交当前数据
+        editor.commit();
+    }
+}

+ 65 - 0
channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/msa/MsaDeviceHandler.java

@@ -0,0 +1,65 @@
+package cn.yyxx.commsdk.impl.merge.channel.msa;
+
+import android.content.Context;
+import android.util.Log;
+
+import com.huawei.hms.ads.identifier.AdvertisingIdClient;
+
+import java.io.IOException;
+import java.util.HashMap;
+import java.util.Map;
+
+import cn.yyxx.commsdk.base.internal.IMsaDeviceCallback;
+
+
+/**
+ * @author #Suyghur.
+ * Created on 2021/04/23
+ */
+public class MsaDeviceHandler {
+
+    private static final String VERSION = "1.0.25";
+
+    public static String oaid = "";
+    public static String vaid = "";
+    public static String aaid = "";
+
+    public static void initMsaDeviceIds(Context context, final IMsaDeviceCallback callback)  {
+        new Thread(){
+            @Override
+            public void run() {
+                AdvertisingIdClient.Info info = null;
+                try {
+                    info = AdvertisingIdClient.getAdvertisingIdInfo(context);
+                } catch (IOException e) {
+                    e.printStackTrace();
+                }
+                if (null != info) {
+                    if (info.isLimitAdTrackingEnabled()){
+                        callback.onIdsRead(-1, "获取oaid失败", null);
+                        Log.i("oaid","获取oaid失败");
+                    }else {
+                        oaid = info.getId();
+
+                        Map<String, String> ids = new HashMap<>();
+
+                        ids.put("oaid", oaid);
+                        ids.put("vaid", "");
+                        ids.put("aaid", "");
+
+                        callback.onIdsRead(0, "获取MsaIds成功", ids);
+
+                        Log.i("oaid","获取oaid成功,返回结果:" +oaid);
+                    }
+                }else{
+                    Log.i("oaid","不支持获取oaid");
+                    callback.onIdsRead(-1, "不支持获取oaid", null);
+
+                }
+
+            }
+        }.start();
+
+
+    }
+}

+ 19 - 0
channel/huawei/src/main/java/cn/yyxx/commsdk/impl/merge/channel/utils/ParamsUtils.java

@@ -0,0 +1,19 @@
+package cn.yyxx.commsdk.impl.merge.channel.utils;
+
+import android.content.Context;
+
+import cn.yyxx.support.PropertiesUtils;
+
+public class ParamsUtils {
+    private static String  CONFIG_FILE  =  "yyxx_cfg.properties";
+
+
+
+
+
+    private static String ASSETS_PATH = "yyxx_game";
+
+    public static String getCfgParam(Context context,String key){
+        return PropertiesUtils.getValue4Properties(context,CONFIG_FILE,ASSETS_PATH, key);
+    }
+}

+ 21 - 0
channel/proguard-rules.pro

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

+ 7 - 0
channel/src/main/AndroidManifest.xml

@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.merge.yyxx.channel">
+
+
+
+</manifest>

+ 20 - 0
gradle.properties

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

BIN
gradle/wrapper/gradle-wrapper.jar


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

@@ -0,0 +1,6 @@
+#Tue Apr 19 10:53:16 CST 2022
+distributionBase=GRADLE_USER_HOME
+distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip
+distributionPath=wrapper/dists
+zipStorePath=wrapper/dists
+zipStoreBase=GRADLE_USER_HOME

+ 185 - 0
gradlew

@@ -0,0 +1,185 @@
+#!/usr/bin/env sh
+
+#
+# Copyright 2015 the original author or authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#      https://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+##############################################################################
+##
+##  Gradle start up script for UN*X
+##
+##############################################################################
+
+# Attempt to set APP_HOME
+# Resolve links: $0 may be a link
+PRG="$0"
+# Need this for relative symlinks.
+while [ -h "$PRG" ] ; do
+    ls=`ls -ld "$PRG"`
+    link=`expr "$ls" : '.*-> \(.*\)$'`
+    if expr "$link" : '/.*' > /dev/null; then
+        PRG="$link"
+    else
+        PRG=`dirname "$PRG"`"/$link"
+    fi
+done
+SAVED="`pwd`"
+cd "`dirname \"$PRG\"`/" >/dev/null
+APP_HOME="`pwd -P`"
+cd "$SAVED" >/dev/null
+
+APP_NAME="Gradle"
+APP_BASE_NAME=`basename "$0"`
+
+# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
+
+# Use the maximum available, or set MAX_FD != -1 to use that value.
+MAX_FD="maximum"
+
+warn () {
+    echo "$*"
+}
+
+die () {
+    echo
+    echo "$*"
+    echo
+    exit 1
+}
+
+# OS specific support (must be 'true' or 'false').
+cygwin=false
+msys=false
+darwin=false
+nonstop=false
+case "`uname`" in
+  CYGWIN* )
+    cygwin=true
+    ;;
+  Darwin* )
+    darwin=true
+    ;;
+  MINGW* )
+    msys=true
+    ;;
+  NONSTOP* )
+    nonstop=true
+    ;;
+esac
+
+CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
+
+
+# Determine the Java command to use to start the JVM.
+if [ -n "$JAVA_HOME" ] ; then
+    if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
+        # IBM's JDK on AIX uses strange locations for the executables
+        JAVACMD="$JAVA_HOME/jre/sh/java"
+    else
+        JAVACMD="$JAVA_HOME/bin/java"
+    fi
+    if [ ! -x "$JAVACMD" ] ; then
+        die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
+
+Please set the JAVA_HOME variable in your environment to match the
+location of your Java installation."
+    fi
+else
+    JAVACMD="java"
+    which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
+
+Please set the JAVA_HOME variable in your environment to match the
+location of your Java installation."
+fi
+
+# Increase the maximum file descriptors if we can.
+if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
+    MAX_FD_LIMIT=`ulimit -H -n`
+    if [ $? -eq 0 ] ; then
+        if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
+            MAX_FD="$MAX_FD_LIMIT"
+        fi
+        ulimit -n $MAX_FD
+        if [ $? -ne 0 ] ; then
+            warn "Could not set maximum file descriptor limit: $MAX_FD"
+        fi
+    else
+        warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
+    fi
+fi
+
+# For Darwin, add options to specify how the application appears in the dock
+if $darwin; then
+    GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
+fi
+
+# For Cygwin or MSYS, switch paths to Windows format before running java
+if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
+    APP_HOME=`cygpath --path --mixed "$APP_HOME"`
+    CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
+
+    JAVACMD=`cygpath --unix "$JAVACMD"`
+
+    # We build the pattern for arguments to be converted via cygpath
+    ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
+    SEP=""
+    for dir in $ROOTDIRSRAW ; do
+        ROOTDIRS="$ROOTDIRS$SEP$dir"
+        SEP="|"
+    done
+    OURCYGPATTERN="(^($ROOTDIRS))"
+    # Add a user-defined pattern to the cygpath arguments
+    if [ "$GRADLE_CYGPATTERN" != "" ] ; then
+        OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
+    fi
+    # Now convert the arguments - kludge to limit ourselves to /bin/sh
+    i=0
+    for arg in "$@" ; do
+        CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
+        CHECK2=`echo "$arg"|egrep -c "^-"`                                 ### Determine if an option
+
+        if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then                    ### Added a condition
+            eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
+        else
+            eval `echo args$i`="\"$arg\""
+        fi
+        i=`expr $i + 1`
+    done
+    case $i in
+        0) set -- ;;
+        1) set -- "$args0" ;;
+        2) set -- "$args0" "$args1" ;;
+        3) set -- "$args0" "$args1" "$args2" ;;
+        4) set -- "$args0" "$args1" "$args2" "$args3" ;;
+        5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
+        6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
+        7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
+        8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
+        9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
+    esac
+fi
+
+# Escape application args
+save () {
+    for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
+    echo " "
+}
+APP_ARGS=`save "$@"`
+
+# Collect all arguments for the java command, following the shell quoting and substitution rules
+eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
+
+exec "$JAVACMD" "$@"

+ 89 - 0
gradlew.bat

@@ -0,0 +1,89 @@
+@rem
+@rem Copyright 2015 the original author or authors.
+@rem
+@rem Licensed under the Apache License, Version 2.0 (the "License");
+@rem you may not use this file except in compliance with the License.
+@rem You may obtain a copy of the License at
+@rem
+@rem      https://www.apache.org/licenses/LICENSE-2.0
+@rem
+@rem Unless required by applicable law or agreed to in writing, software
+@rem distributed under the License is distributed on an "AS IS" BASIS,
+@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+@rem See the License for the specific language governing permissions and
+@rem limitations under the License.
+@rem
+
+@if "%DEBUG%" == "" @echo off
+@rem ##########################################################################
+@rem
+@rem  Gradle startup script for Windows
+@rem
+@rem ##########################################################################
+
+@rem Set local scope for the variables with windows NT shell
+if "%OS%"=="Windows_NT" setlocal
+
+set DIRNAME=%~dp0
+if "%DIRNAME%" == "" set DIRNAME=.
+set APP_BASE_NAME=%~n0
+set APP_HOME=%DIRNAME%
+
+@rem Resolve any "." and ".." in APP_HOME to make it shorter.
+for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
+
+@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
+
+@rem Find java.exe
+if defined JAVA_HOME goto findJavaFromJavaHome
+
+set JAVA_EXE=java.exe
+%JAVA_EXE% -version >NUL 2>&1
+if "%ERRORLEVEL%" == "0" goto execute
+
+echo.
+echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
+echo.
+echo Please set the JAVA_HOME variable in your environment to match the
+echo location of your Java installation.
+
+goto fail
+
+:findJavaFromJavaHome
+set JAVA_HOME=%JAVA_HOME:"=%
+set JAVA_EXE=%JAVA_HOME%/bin/java.exe
+
+if exist "%JAVA_EXE%" goto execute
+
+echo.
+echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
+echo.
+echo Please set the JAVA_HOME variable in your environment to match the
+echo location of your Java installation.
+
+goto fail
+
+:execute
+@rem Setup the command line
+
+set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
+
+
+@rem Execute Gradle
+"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
+
+:end
+@rem End local scope for the variables with windows NT shell
+if "%ERRORLEVEL%"=="0" goto mainEnd
+
+:fail
+rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
+rem the _cmd.exe /c_ return code!
+if  not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
+exit /b 1
+
+:mainEnd
+if "%OS%"=="Windows_NT" endlocal
+
+:omega

+ 1 - 0
platform/.gitignore

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

+ 30 - 0
platform/build.gradle

@@ -0,0 +1,30 @@
+plugins {
+    id 'com.android.library'
+}
+
+android {
+    compileSdk 31
+
+    defaultConfig {
+        minSdk 21
+        targetSdk 31
+
+        consumerProguardFiles "consumer-rules.pro"
+    }
+
+    buildTypes {
+        release {
+            minifyEnabled false
+            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
+        }
+    }
+    compileOptions {
+        sourceCompatibility JavaVersion.VERSION_1_7
+        targetCompatibility JavaVersion.VERSION_1_7
+    }
+}
+
+dependencies {
+    implementation fileTree(dir: 'libs', include: '*.jar')
+
+}

+ 0 - 0
platform/consumer-rules.pro


+ 1 - 0
platform/hnqj/.gitignore

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

+ 33 - 0
platform/hnqj/build.gradle

@@ -0,0 +1,33 @@
+plugins {
+    id 'com.android.library'
+}
+
+android {
+    compileSdk 31
+
+    defaultConfig {
+        minSdk 21
+        targetSdk 31
+
+
+        consumerProguardFiles "consumer-rules.pro"
+    }
+
+    buildTypes {
+        release {
+            minifyEnabled false
+            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
+        }
+    }
+    compileOptions {
+        sourceCompatibility JavaVersion.VERSION_1_7
+        targetCompatibility JavaVersion.VERSION_1_7
+    }
+}
+
+dependencies {
+
+    implementation fileTree(dir: 'libs', include: '*.jar')
+
+
+}

+ 0 - 0
platform/hnqj/consumer-rules.pro


BIN
platform/hnqj/libs/yyxx-comm-platform-hnqj-3.0.300.jar


+ 21 - 0
platform/hnqj/proguard-rules.pro

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

+ 16 - 0
platform/hnqj/src/main/AndroidManifest.xml

@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.merge.yyxx.hnqj">
+
+    <application>
+
+        <activity
+            android:name="cn.yyxx.commsdk.impl.merge.platform.hnqj.HNQJLoginActivity"
+            android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation"
+            android:imeOptions="flagNoFullscreen|flagNoExtractUi"
+            android:launchMode="singleTask"
+            android:theme="@android:style/Theme.Translucent.NoTitleBar.Fullscreen"
+            android:windowSoftInputMode="adjustResize|stateHidden|stateVisible" />
+    </application>
+
+</manifest>

+ 11 - 0
platform/hnqj/src/main/res/anim/qj_rotate_anim.xml

@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<set xmlns:android="http://schemas.android.com/apk/res/android">
+    <rotate
+        android:duration="1000"
+        android:fromDegrees="0"
+        android:pivotX="50%"
+        android:pivotY="50%"
+        android:repeatCount="infinite"
+        android:interpolator="@android:anim/linear_interpolator"
+        android:toDegrees="360" />
+</set>

+ 13 - 0
platform/hnqj/src/main/res/drawable/qj_btn_account_bg.xml

@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape xmlns:android="http://schemas.android.com/apk/res/android" >
+
+
+
+    <stroke android:width="1dp" android:color="@color/qj_text_orange_color"/>
+    <corners
+        android:radius="30dp"
+
+        />
+
+
+</shape>

Nem az összes módosított fájl került megjelenítésre, mert túl sok fájl változott