Browse Source

删除无用so,并且升级依赖库的版本,将极光推送依赖模式改为远程依赖

hy 3 years ago
parent
commit
4c85721583

+ 23 - 14
app/build.gradle

@ -37,11 +37,12 @@ android {
37 37
        multiDexEnabled true
38 38
39 39
        ndk {
40
//            abiFilters "armeabi", "arm64-v8a"
40 41
            abiFilters "armeabi"
41 42
        }
42 43
        flavorDimensions "default"
43 44
        vectorDrawables.useSupportLibrary = true
44
45
        manifestPlaceholders = rootProject.ext.manifestPlaceholders
45 46
//        jackOptions {
46 47
//            enabled true
47 48
//        }
@ -173,24 +174,29 @@ MobSDK {
173 174
dependencies {
174 175
    implementation fileTree(include: ['*.jar'], dir: 'libs')
175 176
    implementation(name: 'alipaySdk-15.6.8-20191021122514', ext: 'aar')
177
    //https://github.com/hongyangAndroid/AndroidAutoLayout
176 178
    implementation project(':autolayout')
179
    //下拉刷新库 View  https://github.com/chrisbanes/Android-PullToRefresh
177 180
    implementation project(':library')
181
    //二维码 扫描
178 182
    implementation project(':zxing')
183
    //https://github.com/huxq17/XRefreshView 下拉上拉刷新
179 184
    implementation project(':XRefreshView')
180 185
    //    implementation project(':videolibrary:picture_library')
181 186
    //    compile 'com.google.zxing:core:+'
182 187
    //    compile 'com.google.zxing:android-core:+'
183 188
    implementation 'com.blankj:utilcode:1.9.8'
184
    implementation 'androidx.multidex:multidex:2.0.0'
189
    implementation 'androidx.multidex:multidex:2.0.1'
185 190
    implementation 'com.umeng.analytics:analytics:latest.integration'
186
    implementation 'com.google.code.gson:gson:2.2.4'
191
    implementation 'com.google.code.gson:gson:2.8.6'
187 192
    //    compile 'com.squareup.okhttp:okhttp:3.14.0'
188 193
    implementation 'com.squareup.okhttp:okhttp:2.0.0'
189 194
    implementation 'com.zhy:okhttputils:2.4.1'
190 195
    implementation 'androidx.legacy:legacy-support-v4:1.0.0'
191
    implementation 'com.google.firebase:firebase-appindexing:10.0.0'
192
    implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
196
    implementation 'com.google.firebase:firebase-appindexing:20.0.0'
197
    implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
193 198
    implementation 'com.zhy:flowlayout-lib:1.0.3'
199
    //类似与Event bus
194 200
    implementation 'com.squareup:otto:+'
195 201
    implementation 'org.greenrobot:greendao:3.2.0'
196 202
    implementation 'org.greenrobot:greendao-generator:3.2.0'
@ -199,16 +205,16 @@ dependencies {
199 205
    implementation 'me.codeboy.android:align-text-view:2.3.0'
200 206
    implementation 'me.itangqi.waveloadingview:library:0.3.5'
201 207
    implementation 'com.yinglan.scrolllayout:scrolllayout:1.0.0'
202
    implementation 'androidx.appcompat:appcompat:1.0.0'
203
    implementation 'com.google.android.material:material:1.0.0'
208
    implementation 'androidx.appcompat:appcompat:1.3.1'
209
    implementation 'com.google.android.material:material:1.4.0'
204 210
    //    compile 'com.nineoldandroids:library:2.4.0'
205 211
    //    compile 'com.github.bumptech.glide:glide:4.1.1'
206
    implementation 'com.github.bumptech.glide:glide:4.11.0'
212
    implementation 'com.github.bumptech.glide:glide:4.12.0'
207 213
    // 停更过期库,用zhihu/Matisse
208 214
//    implementation 'me.iwf.photopicker:PhotoPicker:0.9.12@aar'
209 215
    // 为了兼容Android10 使用beta版本
210 216
    implementation 'com.zhihu.android:matisse:0.5.3-beta3'
211
    implementation 'top.zibin:Luban:1.1.2'
217
    implementation 'top.zibin:Luban:1.1.8'
212 218
    implementation 'com.ms-square:expandableTextView:0.1.4'
213 219
    implementation 'io.reactivex.rxjava2:rxjava:2.0.5'
214 220
    implementation 'io.reactivex.rxjava2:rxandroid:2.0.1'
@ -217,7 +223,7 @@ dependencies {
217 223
    implementation 'pub.devrel:easypermissions:3.0.0'
218 224
    implementation 'com.github.PhilJay:MPAndroidChart:v3.0.3'
219 225
    implementation 'com.github.promeg:tinypinyin:1.0.0'
220
    implementation 'org.greenrobot:eventbus:3.0.0'
226
    implementation 'org.greenrobot:eventbus:3.2.0'
221 227
    implementation 'com.qmuiteam:qmui:1.2.0'
222 228
    implementation 'org.zackratos:ultimatebar:1.1.1'
223 229
    implementation 'com.upyun:upyun-android-sdk:2.1.0'
@ -225,7 +231,9 @@ dependencies {
225 231
    //    implementation 'com.github.castorflex.verticalviewpager:library:19.0.1'
226 232
    // sqlite异常结局
227 233
    implementation 'net.zetetic:android-database-sqlcipher:3.5.7@aar'
228
    implementation 'com.shuyu:GSYVideoPlayer:5.0.2'
234
    implementation 'com.github.CarGuo.GSYVideoPlayer:gsyVideoPlayer-java:v8.1.5-jitpack'
235
    implementation 'com.github.CarGuo.GSYVideoPlayer:gsyVideoPlayer-armv7a:v8.1.5-jitpack'
236
    implementation 'com.github.CarGuo.GSYVideoPlayer:gsyVideoPlayer-armv64:v8.1.5-jitpack'
229 237
    implementation 'com.wang.avi:library:2.1.3'
230 238
    implementation 'com.afollestad.material-dialogs:core:0.9.6.0'
231 239
    implementation 'com.afollestad.material-dialogs:commons:0.9.6.0'
@ -233,8 +241,8 @@ dependencies {
233 241
    //    implementation 'com.github.Aspsine:IRecyclerView:0.0.7'
234 242
    implementation 'com.github.LuckSiege.PictureSelector:picture_library:v2.5.6'
235 243
//    implementation files('libs/bugly_crash_release_3.2.2.jar')
236
    implementation "androidx.camera:camera-camera2:1.0.0-beta03"
237
    implementation "androidx.camera:camera-core:1.0.0-beta03"
244
    implementation "androidx.camera:camera-camera2:1.1.0-alpha07"
245
    implementation "androidx.camera:camera-core:1.1.0-alpha07"
238 246
//    implementation 'com.github.chrisbanes:PhotoView:2.3.0'
239 247
240 248
    // 使用微信分享、登录、收藏、支付等功能需要的库以及文件
@ -242,7 +250,8 @@ dependencies {
242 250
//    implementation 'com.squareup.picasso:picasso:2.71828'
243 251
    // https://github.com/khoyron/Actionsheet-android
244 252
    implementation 'com.github.khoyron:Actionsheet-android:4'
245
253
    implementation 'cn.jiguang.sdk:jpush:4.0.6'
254
    implementation 'cn.jiguang.sdk:jcore:2.8.2'
246 255
247 256
248 257
}

BIN
app/libs/jcore-android-2.5.5.jar


BIN
app/libs/jpush-android-3.8.6.jar


+ 16 - 110
app/src/main/AndroidManifest.xml

@ -12,16 +12,16 @@
12 12
         ACCESS_COARSE_LOCATION instead.
13 13
    -->
14 14
15
    <permission
16
        android:name="${applicationId}.permission.JPUSH_MESSAGE"
17
        android:protectionLevel="signature" />
15
<!--    <permission-->
16
<!--        android:name="${applicationId}.permission.JPUSH_MESSAGE"-->
17
<!--        android:protectionLevel="signature" />-->
18 18
19 19
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" /> <!-- 往SDCard写入数据权限 -->
20 20
21 21
    <uses-feature android:name="android.hardware.camera" />
22 22
    <uses-feature android:name="android.hardware.camera.autofocus" />
23 23
24
    <uses-permission android:name="${applicationId}.permission.JPUSH_MESSAGE" />
24
<!--    <uses-permission android:name="${applicationId}.permission.JPUSH_MESSAGE" />-->
25 25
    <uses-permission android:name="android.permission.GET_ACCOUNTS" />
26 26
    <uses-permission android:name="android.permission.USE_CREDENTIALS" />
27 27
    <uses-permission android:name="android.permission.MANAGE_ACCOUNTS" />
@ -804,121 +804,33 @@
804 804
            android:launchMode="singleTask"
805 805
            android:screenOrientation="portrait" />
806 806
807
        <!-- Rich push 核心功能 since 2.0.6-->
807
        <!-- 若您的业务中有使用极光富媒体功能,或者极光早上好功能,需要把此 Activity 的 exported 修改成 true 覆盖 mavenCentral 上的组件。 -->
808 808
        <activity
809 809
            android:name="cn.jpush.android.ui.PopWinActivity"
810
            android:exported="false"
811
            android:theme="@style/MyDialogStyle"></activity>
812
813
        <!-- Required SDK核心功能-->
814
        <activity
815
            android:name="cn.jpush.android.ui.PushActivity"
816
            android:configChanges="orientation|keyboardHidden"
817
            android:exported="false"
818
            android:theme="@android:style/Theme.NoTitleBar">
810
            android:exported="true"
811
            tools:node="replace"
812
            android:theme="@style/MyDialogStyle">
819 813
            <intent-filter>
820
                <action android:name="cn.jpush.android.ui.PushActivity" />
821
822 814
                <category android:name="android.intent.category.DEFAULT" />
815
                <action android:name="cn.jpush.android.ui.PopWinActivity" />
823 816
                <category android:name="${applicationId}" />
824 817
            </intent-filter>
825 818
        </activity>
826 819
827
        <!-- Required SDK 核心功能-->
828
        <!-- 可配置android:process参数将PushService放在其他进程中 -->
829
        <service
830
            android:name="cn.jpush.android.service.PushService"
831
            android:process=":pushcore">
832
            <intent-filter>
833
                <action android:name="cn.jpush.android.intent.REGISTER" />
834
                <action android:name="cn.jpush.android.intent.REPORT" />
835
                <action android:name="cn.jpush.android.intent.PushService" />
836
                <action android:name="cn.jpush.android.intent.PUSH_TIME" />
837
            </intent-filter>
838
        </service>
839
840
        <!-- since 3.0.9 Required SDK 核心功能-->
841
        <provider
842
            android:name="cn.jpush.android.service.DataProvider"
843
            android:authorities="${applicationId}.DataProvider"
844
            android:exported="false"
845
            android:process=":pushcore" />
846
847
        <!-- since 1.8.0 option 可选项。用于同一设备中不同应用的JPush服务相互拉起的功能。 -->
848
        <!-- 若不启用该功能可删除该组件,或把 enabled 设置成 false ;App 不会被其他 App 拉起,但会拉起其他的 App。 -->
849
        <service
850
            android:name="cn.jpush.android.service.DaemonService"
851
            android:enabled="true"
852
            android:exported="true">
853
            <intent-filter>
854
                <action android:name="cn.jpush.android.intent.DaemonService" />
855
                <category android:name="${applicationId}" />
856
            </intent-filter>
857
        </service>
858
859
        <!-- 可选,如果使用静态Activity方式拉起,该组件必须声明 -->
820
        <!-- 若您的业务中有使用极光富媒体功能,或者极光早上好功能,需要把此 Activity 的 exported 修改成 true 覆盖 mavenCentral 上的组件。 -->
860 821
        <activity
861
            android:name="cn.jpush.android.service.DActivity"
862
            android:enabled="true"
822
            android:name="cn.jpush.android.ui.PushActivity"
823
            android:configChanges="orientation|keyboardHidden"
863 824
            android:exported="true"
864
            android:taskAffinity="jpush.custom"
865
            android:theme="@android:style/Theme.Translucent.NoTitleBar">
866
            <intent-filter>
867
                <action android:name="cn.jpush.android.intent.DActivity" />
868
                <category android:name="${applicationId}" />
869
            </intent-filter>
870
        </activity>
871
872
        <!--since 3.3.0 Required SDK核心功能-->
873
        <activity
874
            android:name="cn.jpush.android.service.JNotifyActivity"
875
            android:exported="false"
876
            android:taskAffinity="jpush.custom"
877
            android:theme="@android:style/Theme.Translucent.NoTitleBar">
825
            tools:node="replace"
826
            android:theme="@android:style/Theme.NoTitleBar">
878 827
            <intent-filter>
879
                <action android:name="cn.jpush.android.intent.JNotifyActivity" />
828
                <action android:name="cn.jpush.android.ui.PushActivity" />
829
                <category android:name="android.intent.category.DEFAULT" />
880 830
                <category android:name="${applicationId}" />
881 831
            </intent-filter>
882 832
        </activity>
883 833
884
        <!-- since 3.1.0 Required SDK 核心功能-->
885
        <provider
886
            android:name="cn.jpush.android.service.DownloadProvider"
887
            android:authorities="${applicationId}.DownloadProvider"
888
            android:exported="true" />
889
890
        <!-- Required SDK核心功能-->
891
        <receiver
892
            android:name="cn.jpush.android.service.PushReceiver"
893
            android:enabled="true">
894
            <intent-filter android:priority="1000">
895
                <action android:name="cn.jpush.android.intent.NOTIFICATION_RECEIVED_PROXY" />   <!--Required  显示通知栏 -->
896
                <category android:name="${applicationId}" />
897
            </intent-filter>
898
            <intent-filter>
899
                <action android:name="android.intent.action.USER_PRESENT" />
900
                <action android:name="android.net.conn.CONNECTIVITY_CHANGE" />
901
            </intent-filter>
902
            <!-- Optional -->
903
            <intent-filter>
904
                <action android:name="android.intent.action.PACKAGE_ADDED" />
905
                <action android:name="android.intent.action.PACKAGE_REMOVED" />
906
907
                <data android:scheme="package" />
908
            </intent-filter>
909
        </receiver>
910
911
        <!-- Required SDK核心功能-->
912
        <receiver
913
            android:name="cn.jpush.android.service.AlarmReceiver"
914
            android:exported="false" />
915
916
        <!-- 3.5.0新增,用于定时展示功能 -->
917
        <receiver
918
            android:name="cn.jpush.android.service.SchedulerReceiver"
919
            android:exported="false" />
920
921
922 834
        <meta-data
923 835
            android:name="com.amap.api.v2.apikey"
924 836
            android:value="fabcfbf869745789b151d0c88e9b4807" />
@ -940,12 +852,6 @@
940 852
        <meta-data
941 853
            android:name="com.google.android.gms.version"
942 854
            android:value="@integer/google_play_services_version" />
943
        <meta-data
944
            android:name="JPUSH_CHANNEL"
945
            android:value="developer-default" />
946
        <meta-data
947
            android:name="JPUSH_APPKEY"
948
            android:value="19fde8a6fe56b6918522bfa3" />
949 855
950 856
        <provider
951 857
            android:name="androidx.core.content.FileProvider"

+ 5 - 0
app/src/main/java/com/electric/chargingpile/activity/ChatContentListActivity.java

@ -922,6 +922,11 @@ public class ChatContentListActivity extends AppCompatActivity {
922 922
                }
923 923
924 924
                @Override
925
                public void onComplete(String url, Object... objects) {
926
927
                }
928
929
                @Override
925 930
                public void onClickStartError(String s, Object... objects) {
926 931
                    playIcon.setVisibility(View.VISIBLE);
927 932
                    ToastUtil.showToast(getContext(), s, Toast.LENGTH_SHORT);

+ 3 - 1
app/src/main/java/com/electric/chargingpile/application/MainApplication.java

@ -40,6 +40,7 @@ import java.util.Map;
40 40

41 41
import cn.jpush.android.api.JPushInterface;
42 42

43

43 44
public class MainApplication extends MultiDexApplication {
44 45
    public static MainApplication instances;
45 46
    private DaoMaster.DevOpenHelper mHelper;
@ -184,8 +185,9 @@ public class MainApplication extends MultiDexApplication {
184 185

185 186
    public void initJPush() {
186 187
        //极光
187
        JPushInterface.setDebugMode(false);
188
        JPushInterface.setDebugMode(BuildConfig.DEBUG);
188 189
        JPushInterface.init(this);
190
        Log.e("TAG", "initJPush: "+ JPushInterface.getRegistrationID(this) );
189 191
    }
190 192

191 193
    public static MainApplication getInstance() {

+ 8 - 0
app/src/main/java/com/electric/chargingpile/video/VideoPlayer.java

@ -2,6 +2,7 @@ package com.electric.chargingpile.video;
2 2
3 3
import android.content.Context;
4 4
import android.util.AttributeSet;
5
import android.view.MotionEvent;
5 6
6 7
import com.electric.chargingpile.R;
7 8
import com.shuyu.gsyvideoplayer.video.StandardGSYVideoPlayer;
@ -38,10 +39,17 @@ public class VideoPlayer extends StandardGSYVideoPlayer {
38 39
    }
39 40
40 41
    @Override
42
    protected void touchDoubleUp(MotionEvent e) {
43
//        super.touchDoubleUp(e);
44
    }
45
46
/*
47
    @Override
41 48
    protected void touchDoubleUp() {
42 49
        // super.touchDoubleUp();
43 50
        // 不需要双击暂停
44 51
    }
52
*/
45 53
46 54
    @Override
47 55
    protected void changeUiToPreparingShow() {

BIN
app/src/main/jniLibs/armeabi-v7a/libijkffmpeg.so


BIN
app/src/main/jniLibs/armeabi-v7a/libijkplayer.so


BIN
app/src/main/jniLibs/armeabi-v7a/libijksdl.so


BIN
app/src/main/jniLibs/armeabi/libZBarDecoder.so


BIN
app/src/main/jniLibs/armeabi/libiconv.so


BIN
app/src/main/jniLibs/armeabi/libijkffmpeg.so


BIN
app/src/main/jniLibs/armeabi/libijkplayer.so


BIN
app/src/main/jniLibs/armeabi/libijksdl.so


BIN
app/src/main/jniLibs/armeabi/libjcore255.so


BIN
app/src/main/jniLibs/armeabi/libndkbitmap.so


BIN
app/src/main/jniLibs/armeabi/librtmp-jni.so


BIN
app/src/main/jniLibs/armeabi/libtpnsWatchdog.so


BIN
app/src/main/jniLibs/armeabi/libzbarjni.so


+ 15 - 5
build.gradle

@ -8,8 +8,9 @@ buildscript {
8 8
//        appKey = 'mnhwhy8jP7Fq2G6b' // 注册时分配的App Key
9 9
//    }
10 10
    repositories {
11
        jcenter()
12
        google()
11
        maven {url 'https://maven.aliyun.com/repository/google/'}
12
        maven {url 'https://maven.aliyun.com/repository/public/'}
13
        maven {url 'https://maven.aliyun.com/repository/gradle-plugin/'}
13 14
    }
14 15
15 16
    dependencies {
@ -25,9 +26,18 @@ allprojects {
25 26
        flatDir {
26 27
            dirs 'libs'
27 28
        }
28
        jcenter()
29
        google()
30
        maven { url "https://jitpack.io" }
29
        maven {url 'https://maven.aliyun.com/repository/google/'}
30
        maven {url 'https://maven.aliyun.com/repository/public/'}
31
        maven {url 'https://maven.aliyun.com/repository/gradle-plugin/'}
32
        maven { url "https://www.jitpack.io" }
33
        maven { url 'https://repo1.maven.org/maven2/' }
31 34
    }
32 35
}
36
ext{
37
    manifestPlaceholders= [
38
            JPUSH_PKGNAME : "com.electric.chargingpile",
39
            JPUSH_APPKEY  : "19fde8a6fe56b6918522bfa3", //JPush 上注册的包名对应的 Appkey.
40
            JPUSH_CHANNEL : "developer-default", //暂时填写默认值即可.
41
    ]
33 42
43
}