|
@@ -690,48 +690,40 @@ class CallingbedActivity :BaseActivity<CallingbedActivityPresenter, CallingbedMa
|
|
|
//当前是白天并且原来不是白天
|
|
|
if (Constant.day_state != 0 || forceSet) {
|
|
|
//设置白天亮度
|
|
|
- ScreenManagerUtil().setScreenBrightness(
|
|
|
- this,
|
|
|
- Math.ceil(2.54 * SettingConfig.getExtensionDaytimeBrightness(this)).toInt()
|
|
|
- )
|
|
|
+ ScreenManagerUtil().setScreenBrightness(this, Math.ceil(2.54 * SettingConfig.getExtensionDaytimeBrightness(this)).toInt())
|
|
|
//设置白天系统音量和响铃音
|
|
|
- VoiceManagerUtil.setSystemVoice(
|
|
|
- this,
|
|
|
- SettingConfig.getExtensionDaytimeSystemVolume(this)
|
|
|
- )
|
|
|
- VoiceManagerUtil.setMusicVoice(
|
|
|
- this,
|
|
|
- SettingConfig.getExtensionDaytimeSystemVolume(this)
|
|
|
- )
|
|
|
+ VoiceManagerUtil.setSystemVoice(this, SettingConfig.getExtensionDaytimeSystemVolume(this))
|
|
|
+ VoiceManagerUtil.setMusicVoice(this, SettingConfig.getExtensionDaytimeSystemVolume(this))
|
|
|
view_title_layout_iv_day_night.setImageResource(R.mipmap.ic_daylight)
|
|
|
|
|
|
if (hasNurseValue) {
|
|
|
SerialPortHelper.setNurseLedLight2(SettingConfig.getExtensionDaytimeLEDBrightness(activity), configList)
|
|
|
}
|
|
|
+
|
|
|
+ //白天灭掉紧急按钮灯
|
|
|
+ AppTool.Time.delay(2000) {
|
|
|
+ SerialPortHelper.setSosLight("0")
|
|
|
+ }
|
|
|
}
|
|
|
Constant.day_state = 0
|
|
|
} else {
|
|
|
//当前是夜晚并且原来不是夜晚
|
|
|
if (Constant.day_state != 1 || forceSet) {
|
|
|
//设置晚上亮度
|
|
|
- ScreenManagerUtil().setScreenBrightness(
|
|
|
- this,
|
|
|
- Math.ceil(2.54 * SettingConfig.getExtensionNightBrightness(this)).toInt()
|
|
|
- )
|
|
|
+ ScreenManagerUtil().setScreenBrightness(this, Math.ceil(2.54 * SettingConfig.getExtensionNightBrightness(this)).toInt())
|
|
|
//设置晚上系统音量和响铃音
|
|
|
- VoiceManagerUtil.setSystemVoice(
|
|
|
- this,
|
|
|
- SettingConfig.getExtensionNightSystemVolume(this)
|
|
|
- )
|
|
|
- VoiceManagerUtil.setMusicVoice(
|
|
|
- this,
|
|
|
- SettingConfig.getExtensionNightSystemVolume(this)
|
|
|
- )
|
|
|
+ VoiceManagerUtil.setSystemVoice(this, SettingConfig.getExtensionNightSystemVolume(this))
|
|
|
+ VoiceManagerUtil.setMusicVoice(this, SettingConfig.getExtensionNightSystemVolume(this))
|
|
|
view_title_layout_iv_day_night.setImageResource(R.mipmap.ic_night)
|
|
|
|
|
|
if (hasNurseValue) {
|
|
|
SerialPortHelper.setNurseLedLight2(SettingConfig.getExtensionNightLEDBrightness(activity), configList)
|
|
|
}
|
|
|
+
|
|
|
+ //晚上打开紧急按钮灯
|
|
|
+ AppTool.Time.delay(2000) {
|
|
|
+ SerialPortHelper.setSosLight("1")
|
|
|
+ }
|
|
|
}
|
|
|
Constant.day_state = 1
|
|
|
}
|