Merge branch 'dev_robotaxi-d-app-module_2110_220915_2.11.0' into 'test_robotaxi-d-app-module_2110_220915_2.11.0.1'

Dev robotaxi d app module 2110 220915 2.11.0

See merge request zhjt/AndroidApp/MoGoEagleEye!315
This commit is contained in:
wangmingjun
2022-10-27 09:30:29 +00:00
3 changed files with 23 additions and 37 deletions

View File

@@ -36,15 +36,6 @@ if (!isAndroidTestBuild()) {
apply plugin: 'apm-plugin'
}
if (!isAndroidTestBuild()) {
apply plugin: 'bytex.threadOpt'
thread_opt {
enable !isReleaseBuild
enableInDebug !isReleaseBuild
logLevel "DEBUG"
}
}
if (!isAndroidTestBuild()) {
apply plugin: 'LancetX'
LancetX {
@@ -290,10 +281,6 @@ dependencies {
androidTestImplementation rootProject.ext.dependencies.androidx_espresso_core
androidTestImplementation rootProject.ext.dependencies.localbroadcastmanager
androidTestImplementation rootProject.ext.dependencies.mogo_v2x
if (isAndroidTestBuild()) {
implementation "com.mogo.thread.opt:lib:${THREAD_OPT_VERSION}"
}
}
if (!isAndroidTestBuild()) {

View File

@@ -34,7 +34,6 @@ buildscript {
classpath "com.mogo.cloud:hook:${HOOK_LOG_VERSION}"
classpath "com.mogo.cloud:bizconfig:${BIZCONFIG_VERSION}"
classpath 'com.volcengine:apm_insight_plugin:1.4.1'
classpath "com.mogo.thread.opt:plg:${THREAD_OPT_VERSION}"
classpath 'com.mogo.cloud:systrace:1.0.1'
classpath 'com.google.protobuf:protobuf-gradle-plugin:0.8.18'
classpath 'com.mogo.sticky:service:1.0.8'

View File

@@ -212,29 +212,29 @@ public class MainLauncherActivity extends MainActivity implements IMogoIntentLis
@Override
public boolean onKeyDown(int keyCode, KeyEvent event) {
if (keyCode == KeyEvent.KEYCODE_VOLUME_UP) { //向上长按 开启自动驾驶
long currentTime = System.currentTimeMillis() / (1000);
long oldTime = SharedPrefsMgr.getInstance(getContext()).getLong("old_time_up", 0);
// Log.d("liyz", "time = " + (currentTime - oldTime));
if (currentTime - oldTime > 6) {
SharedPrefsMgr.getInstance(getContext()).putLong("old_time_up", System.currentTimeMillis() / 1000);
// ToastUtils.showShort("长按 ↑↑↑ 开启自动驾驶");
// CallerAutoPilotManager.INSTANCE.setControlAutopilotCarAuto(true);
CallerAutoPilotManager.INSTANCE.startAutoPilot(CallerAutoPilotStatusListenerManager.INSTANCE.getAutoPilotStatusInfo().getAutopilotControlParameters());
}
return true;
} else if (keyCode == KeyEvent.KEYCODE_VOLUME_DOWN) { //下和中间键盘长按,减速为-2
long currentTime = System.currentTimeMillis() / (1000);
long oldTime = SharedPrefsMgr.getInstance(getContext()).getLong("old_time_down", 0);
if (currentTime - oldTime > 6) {
SharedPrefsMgr.getInstance(getContext()).putLong("old_time_down", System.currentTimeMillis() / 1000);
// ToastUtils.showShort("长按 ↓↓↓ 减速 -2 ");
sendAcc(true, -2);
}
return true;
}
// if (keyCode == KeyEvent.KEYCODE_VOLUME_UP) { //向上长按 开启自动驾驶
// long currentTime = System.currentTimeMillis() / (1000);
// long oldTime = SharedPrefsMgr.getInstance(getContext()).getLong("old_time_up", 0);
//// Log.d("liyz", "time = " + (currentTime - oldTime));
// if (currentTime - oldTime > 6) {
// SharedPrefsMgr.getInstance(getContext()).putLong("old_time_up", System.currentTimeMillis() / 1000);
//// ToastUtils.showShort("长按 ↑↑↑ 开启自动驾驶");
//// CallerAutoPilotManager.INSTANCE.setControlAutopilotCarAuto(true);
// CallerAutoPilotManager.INSTANCE.startAutoPilot(CallerAutoPilotStatusListenerManager.INSTANCE.getAutoPilotStatusInfo().getAutopilotControlParameters());
//
// }
//
// return true;
// } else if (keyCode == KeyEvent.KEYCODE_VOLUME_DOWN) { //下和中间键盘长按,减速为-2
// long currentTime = System.currentTimeMillis() / (1000);
// long oldTime = SharedPrefsMgr.getInstance(getContext()).getLong("old_time_down", 0);
// if (currentTime - oldTime > 6) {
// SharedPrefsMgr.getInstance(getContext()).putLong("old_time_down", System.currentTimeMillis() / 1000);
//// ToastUtils.showShort("长按 ↓↓↓ 减速 -2 ");
// sendAcc(true, -2);
// }
// return true;
// }
// Log.e("liyz", "onKeyDown keyCode = " + keyCode + "--action = " + event.getAction() + "---" + event);
return super.onKeyDown(keyCode, event);