1. 修复比亚迪分享框弹不出来的问题;
2. 增加比亚迪Full Screen
This commit is contained in:
@@ -4,9 +4,14 @@ import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
|
||||
import android.view.MotionEvent;
|
||||
import android.view.Window;
|
||||
import android.view.WindowManager;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.utils.SoftKeyBoardJobber;
|
||||
|
||||
/**
|
||||
@@ -23,6 +28,10 @@ public abstract class MvpActivity< V extends IView, P extends Presenter< V > >
|
||||
@Override
|
||||
protected void onCreate( @Nullable Bundle savedInstanceState ) {
|
||||
super.onCreate( savedInstanceState );
|
||||
if (DebugConfig.getCarMachineType() == DebugConfig.CAR_MACHINE_TYPE_BYD) {
|
||||
requestWindowFeature(Window.FEATURE_NO_TITLE);
|
||||
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN);
|
||||
}
|
||||
setContentView( getLayoutId() );
|
||||
initViews();
|
||||
mPresenter = createPresenter();
|
||||
|
||||
@@ -6,7 +6,11 @@ import android.widget.FrameLayout;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.module.main.MainActivity;
|
||||
import com.mogo.service.IMogoServiceApis;
|
||||
import com.mogo.service.MogoServicePaths;
|
||||
|
||||
/**
|
||||
* 针对独立应用形式,做单独定制
|
||||
@@ -19,6 +23,12 @@ public class MainIndependentActivity extends MainActivity {
|
||||
super.onCreate( savedInstanceState );
|
||||
// 独立app需要在onCreate里面增加处理scheme的情况
|
||||
mPresenter.handleSchemeIntent( getIntent() );
|
||||
|
||||
if (DebugConfig.getCarMachineType() == DebugConfig.CAR_MACHINE_TYPE_BYD) {
|
||||
IMogoServiceApis apis =
|
||||
(IMogoServiceApis) ARouter.getInstance().build(MogoServicePaths.PATH_SERVICE_APIS).navigation(this);
|
||||
apis.getShareManager().resetContext(this);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -20,7 +20,7 @@ public class BaseFloatDialog extends Dialog {
|
||||
|
||||
public BaseFloatDialog(@NonNull Context context, int themeResId) {
|
||||
super(context, themeResId);
|
||||
addFlag();
|
||||
// addFlag();
|
||||
}
|
||||
|
||||
private void addFlag() {
|
||||
|
||||
@@ -115,6 +115,11 @@ public class ShareControl implements IMogoShareManager, IMogoIntentListener, IMo
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void resetContext(Context context) {
|
||||
mContext = context;
|
||||
}
|
||||
|
||||
private void realShowDialog() {
|
||||
if (mShareDialog == null) {
|
||||
mShareDialog = new LaucherShareDialog(mContext);
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
package com.mogo.service.share;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
import com.mogo.service.module.IMogoModuleProvider;
|
||||
|
||||
/**
|
||||
@@ -16,4 +18,10 @@ public interface IMogoShareManager extends IMogoModuleProvider {
|
||||
* 隐藏分享框
|
||||
*/
|
||||
void dismissShareDialog();
|
||||
|
||||
/**
|
||||
* 重置一下上下文,普通dialog需要activity的上下文
|
||||
* @param context 待重置的上下文
|
||||
*/
|
||||
void resetContext(Context context);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user