Commit b29b9ac6 by 刘鹏

Merge branch 'feat/lp/lp_v4.3.95' into 'd/v4.3.95'

feat: 1. opensl去掉,采用系统音频采集。2.倒计时增加1分钟,保证通话不被提前终止。3.登录页授权按钮加入动效

See merge request app_android_lib/YDL-Component!135
parents 43649f62 ffa3295a
......@@ -21,8 +21,8 @@ import java.util.List;
public final class DemoGlobalConfig implements IConfigModule {
String APP_DOMAIN = "https://api.github.com/";
// public static String appEnv = YDLConstants.ENV_AUTO_TEST;
// public static String appEnv = YDLConstants.ENV_NEW_TEST;//配置未上传到maven库
// public static String appEnv = YDLConstants.ENV_TEST;
// public static String appEnv = YDLConstants.ENV_NEW_TEST;//配置未上传到maven库
public static String appEnv = YDLConstants.ENV_PROD;
@Override
public void injectAppLifecycle(@NotNull Context context, @NotNull List<IAppLifecycles> lifecycles) {
......
......@@ -75,7 +75,7 @@ dependencies {
kapt "com.alibaba:arouter-compiler:$arouter_compiler"
api "com.alibaba:arouter-api:$arouter_api"
implementation "com.ydl:ydl-av:1.4.2"
implementation "com.ydl:ydl-av:1.4.4"
implementation 'com.volcengine:apm_insight:1.4.6.cn'
if (rootProject.ext.dev_mode){
......
......@@ -1259,7 +1259,7 @@ class AudioHomeActivity :
totalDisposable =
Observable.interval(0, 1, TimeUnit.SECONDS)
.subscribeOn(Schedulers.computation())
.take(remainTime!!.toLong() + 1)
.take(remainTime!!.toLong() + 60)
.observeOn(AndroidSchedulers.mainThread())
.subscribe({
localRemainTime =
......
package com.yidianling.user.ui.login
import android.Manifest
import android.annotation.SuppressLint
import android.content.Context
import android.content.Intent
import android.graphics.Color
import android.net.Uri
import android.os.Handler
import android.provider.Settings
import androidx.core.content.ContextCompat
import android.text.*
import android.text.method.LinkMovementMethod
import android.text.style.AbsoluteSizeSpan
import android.text.style.ClickableSpan
import android.view.View
import android.view.animation.AnimationUtils
import androidx.core.content.ContextCompat
import com.alibaba.android.arouter.facade.annotation.Route
import com.fm.openinstall.OpenInstall
import com.meituan.android.walle.WalleChannelReader
import com.mobile.auth.gatewayauth.PhoneNumberAuthHelper
import com.mobile.auth.gatewayauth.ResultCode
import com.mobile.auth.gatewayauth.model.TokenRet
import com.tbruyelle.rxpermissions2.RxPermissions
import com.umeng.socialize.UMShareAPI
import com.umeng.socialize.UMShareConfig
import com.umeng.socialize.bean.SHARE_MEDIA
......@@ -60,6 +56,8 @@ import io.reactivex.android.schedulers.AndroidSchedulers
import io.reactivex.schedulers.Schedulers
import kotlinx.android.synthetic.main.user_activity_register_and_login_bottom.*
import kotlinx.android.synthetic.main.user_activity_register_and_login_new.*
import kotlinx.android.synthetic.main.user_activity_register_and_login_new.img_reg_back
import kotlinx.android.synthetic.main.user_activity_register_and_login_new.view_lin
/**
* @author jiucheng
......@@ -151,32 +149,6 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
StatusBarUtils.Companion.setWindowStatusBarColor(this, R.color.white)
StatusBarUtils.Companion.setStatusBarLightMode(this, true)
}
/*取消READ_PHONE_STATE权限申请,已经在启动页弹过一次
* */
@SuppressLint("CheckResult")
private fun requestPermission() {
val rxPermissions = RxPermissions(this)
rxPermissions.requestEach(Manifest.permission.READ_PHONE_STATE)
.subscribe { permission ->
when {
permission.granted -> {
}
permission.shouldShowRequestPermissionRationale -> {
// 用户拒绝了该权限,没有选中『不再询问』(Never ask again),那么下次再次启动时。还会提示请求权限的对话框
}
else -> {
// 用户拒绝了该权限,而且选中『不再询问』
/*ToastUtil.toastLong(this, "App正常工作需要使用设备信息权限,请开启")
val intent = Intent(Settings.ACTION_APPLICATION_DETAILS_SETTINGS)
val uri = Uri.fromParts("package", packageName, null)
intent.data = uri
startActivity(intent)
finish()*/
}
}
}
}
/**
* 注册流程成功之后,进行百度埋点
*/
......@@ -198,8 +170,6 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
private fun initAuthHelper() {
// requestPermission()
OneKeyLoginHelp.checkEnvAvailable(PhoneNumberAuthHelper.SERVICE_TYPE_AUTH)
OneKeyLoginHelp.setVerifyTokenResultListener(object :
OneKeyLoginHelp.VerifyTokenResultListener {
......@@ -402,6 +372,8 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
//微信登录
login_wechat.setOnClickListener {
if (iv_select_protocol.visibility == View.VISIBLE && !isAgreeProtocol) {
val shake = AnimationUtils.loadAnimation(this, R.anim.user_shake_input)//加载动画资源文件 
check_protocol.startAnimation(shake)
ToastUtil.toastShort("请您先同意壹点灵《用户使用协议》、《隐私保护政策》,才能登录使用")
return@setOnClickListener
}
......@@ -410,6 +382,8 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
//QQ 登录
login_qq.setOnClickListener {
if (iv_select_protocol.visibility == View.VISIBLE && !isAgreeProtocol) {
val shake = AnimationUtils.loadAnimation(this, R.anim.user_shake_input)//加载动画资源文件 
check_protocol.startAnimation(shake)
ToastUtil.toastShort("请您先同意壹点灵《用户使用协议》、《隐私保护政策》,才能登录使用")
return@setOnClickListener
}
......@@ -427,6 +401,8 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
//下一步
ll_next.setOnClickListener {
if (iv_select_protocol.visibility == View.VISIBLE && !isAgreeProtocol) {
val shake = AnimationUtils.loadAnimation(this, R.anim.user_shake_input)//加载动画资源文件 
check_protocol.startAnimation(shake)
ToastUtil.toastShort("请您先同意壹点灵《用户使用协议》、《隐私保护政策》,才能登录使用")
return@setOnClickListener
}
......
<?xml version="1.0" encoding="utf-8"?>
<translate xmlns:android="http://schemas.android.com/apk/res/android"
android:duration="400"
android:duration="300"
android:fromXDelta="0"
android:interpolator="@anim/user_cycle_input"
android:toXDelta="20" />
......
......@@ -172,6 +172,7 @@
/>
<LinearLayout
android:id="@+id/check_protocol"
android:layout_marginTop="8dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment