FAQ-MT6250,11B1132MP,录音过程中来闹铃,没有铃声

2024-03-08 16:32

本文主要是介绍FAQ-MT6250,11B1132MP,录音过程中来闹铃,没有铃声,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

跟综下来发现control_sound这个函数中
if (behavior == MMI_NOTI_SND_BEHA_NO_PLAY)
{
#ifdef MMI_NOTI_MGR_UT
play_sound = MMI_FALSE;
snd_action = action;
play_sound_id = tone_id;
#endif /* MMI_NOTI_MGR_UT */
return;
}返回了.
修改方法:
关注//add begin和//add end 之间的语句。
static MMI_BOOL
control_notification(
U8 notification_type,
notification_info_struct *noti_info)
{
/*----------------------------------------------------------------*/
/* Local Variables */
/*----------------------------------------------------------------*/
mmi_app_scenario_struct noti_scen, active_scen;
mmi_app_behavior_struct internal_behavior;
mmi_scenario_id active_scen_id;
MMI_BOOL display_scrn = MMI_FALSE;
const mmi_events_notify_struct *notify_event_info = NULL;
mmi_nmgr_behavior_enum attri_action;
mmi_attribute_action_struct action_struct;
MMI_BOOL is_stop_tone = MMI_FALSE;
MMI_BOOL is_stop_vib = MMI_FALSE;
MMI_BOOL is_stop_text_preview = MMI_FALSE;
#ifdef __MMI_NSS_SUPPORT__
U16 notification_setting_value = 0;
#endif
/*----------------------------------------------------------------*/
/* Code Body */
/*----------------------------------------------------------------*/
#ifdef __DM_LAWMO_SUPPORT__ 
if (mmi_dmui_is_phone_lock() && (notification_type ==
MMI_NOTIFY_COMM_POPUP))
{
MMI_TRACE(MMI_FW_TRC_G1_FRM, TRC_MMI_FRM_NMGR_DISBALE_NMGR_BY_DM_LOCK);
return MMI_FALSE;
}
#endif
if (mmi_frm_has_no_scenario_been_started() == MMI_TRUE)
{
return MMI_FALSE;
}
if (g_enable_nmgr == MMI_FALSE)
{
return MMI_FALSE;
}
active_scen_id = mmi_frm_get_active_scenario_id();
get_scenario_info(noti_info->noti_scen_id, &noti_scen);
get_scenario_info(active_scen_id, &active_scen);
compare_scenario_and_get_behavior(active_scen_id, noti_info->noti_scen_id,
&internal_behavior);
if( active_scen.scrn_priority >= MMI_SCEN_SCRN_PRIO_HIGH)
{
is_stop_text_preview = MMI_TRUE;
}
/* Get notify configuration information by user to decide the action of
each attribute. */
notify_event_info = mmi_nmgr_get_event_notify_info(noti_info->notify_type,
active_scen_id);
MMI_ASSERT(NULL != notify_event_info);
attri_action = notify_event_info->behavior;
parse_attri_action(attri_action, &action_struct);
if (notification_type == MMI_NOTIFY_BY_IDLE)
{/* App handle screen work flow, may add extra info, like setting key,
scrn handler */
MMI_ASSERT(noti_info->scrn_func_ptr == NULL && noti_info->arg == NULL);
/* Won't check screen behavior since this kind of screen will be displayed
when goback to idle */
display_scrn = control_idle_screen(noti_info->noti_scen_id, noti_info-
>notify_type, noti_scen.scrn_priority, noti_info->string,
internal_behavior.scrn_behavior);
}
else if (notification_type == MMI_NOTIFY_BY_APP)
{/* App may not display screen for some special case */
display_scrn = control_app_screen(
noti_info->noti_scen_id, 
noti_scen.scrn_priority, 
internal_behavior.scrn_behavior, 
noti_info->scrn_func_ptr, 
noti_info->arg, 
action_struct.scrn_action, 
NULL,
noti_info->notify_type);
}
else if (notification_type == MMI_NOTIFY_COMM_POPUP)
{
display_scrn = control_popup_screen(noti_info->noti_scen_id, noti_info-
>string, noti_info->notify_type, internal_behavior.scrn_behavior,
action_struct.scrn_action);
}
else if (notification_type == MMI_NOTIFY_SUBLCD)
{
}
else if (notification_type == MMI_NOTIFY_PREVIEW)
{
#ifdef __MMI_NCENTER_SUPPORT__
control_preview(noti_info->notify_type, noti_info->notification, NULL,
is_stop_text_preview);
if (noti_info->notification->option & MMI_FRM_NMGR_DISABLE_TONE)
{
is_stop_tone = MMI_TRUE;
}
if (noti_info->notification->option & MMI_FRM_NMGR_DISABLE_VIB)
{
is_stop_vib = MMI_TRUE;
}
#endif
}
else if (notification_type == MMI_NOTIFY_BALLOON)
{
#ifdef __COSMOS_MMI_PACKAGE__
display_scrn = control_balloon(noti_info->notify_type, noti_info-
>balloon_type, noti_info->string, NULL);
#endif
}
else if (notification_type == MMI_NOTIFY_ALERT)
{
/*Show notification by its alert type*/
if (noti_info->alert_info->behavior_mask == ALERT_TYPE_STATUS_BAR)
{/*Show status bar (text preview or balloon)*/
if(noti_info->alert_info->status_bar_para.status_bar_type ==
MMI_FRM_NMGR_ALERT_ST_PREVIEW_TYPE)
{/*text preview*/
#ifdef __MMI_NCENTER_SUPPORT__
mmi_frm_notification_para_struct temp_preview;
temp_preview.text = noti_info->alert_info->status_bar_para.display_string;
temp_preview.option = noti_info->alert_info->alert_option;
control_preview(noti_info->notify_type, &temp_preview, noti_info-
>alert_info, is_stop_text_preview);
#endif
}
if(noti_info->alert_info->status_bar_para.status_bar_type ==
MMI_FRM_NMGR_ALERT_ST_BALLOON_TYPE)
{/*balloon*/
#ifdef __COSMOS_MMI_PACKAGE__
display_scrn = control_balloon(noti_info->notify_type,
MMI_NMGR_BALLOON_TYPE_INFO,
(WCHAR *)noti_info->alert_info->status_bar_para.display_string, noti_info-
>alert_info);
#endif
}
}
if(noti_info->alert_info->behavior_mask == ALERT_TYPE_POPUP)
{ /*Show popup*/
mmi_noti_scrn_func_ptr popup_scrn_entry = nmgr_alert_general_popup;
void *popup_scrn_para = noti_info->alert_info;
display_scrn = control_app_screen(noti_info->noti_scen_id, 
noti_scen.scrn_priority, 
internal_behavior.scrn_behavior, 
popup_scrn_entry, 
popup_scrn_para, 
action_struct.scrn_action,
noti_info->alert_info,
noti_info->notify_type);
}
/*Extract option for sound and vibration usage*/
if ( noti_info->alert_info->alert_option & MMI_FRM_NMGR_DISABLE_TONE)
{
is_stop_tone = MMI_TRUE;
}
if (noti_info->alert_info->alert_option & MMI_FRM_NMGR_DISABLE_VIB)
{
is_stop_vib = MMI_TRUE;
}
/*Extract the sound setting from NSS*/
#ifdef __MMI_NSS_SUPPORT__
mmi_srv_nss_get_setting(noti_info->alert_info->app_id, NSS_SETTING_SOUND,
&notification_setting_value);
if(notification_setting_value == SETTING_OFF)
{
is_stop_tone = MMI_TRUE;
}
#endif
/*According to UE design, we will show status bar icon even the NSS is
none or popup*/
if (noti_info->alert_info->behavior_mask == ALERT_TYPE_POPUP || 
noti_info->alert_info->behavior_mask == ALERT_TYPE_NONE)
{
control_status_icon(noti_info->alert_info->app_id,
noti_info->alert_info->alert_option, 
noti_info->alert_info->status_bar_icon_para.icon_id
);
}
}
else
{
MMI_ASSERT(0);
}
control_sublcd(noti_info->noti_scen_id, internal_behavior.scrn_behavior);
if (!nmgr_is_in_defer_process() && !only_control_scrn)
{/* These three attribute should be invoked immediately! */
//add begin
/* compare scenario again */
active_scen_id = mmi_frm_get_active_scenario_id();
get_scenario_info(noti_info->noti_scen_id, &noti_scen);
get_scenario_info(active_scen_id, &active_scen);
compare_scenario_and_get_behavior(active_scen_id, noti_info->noti_scen_id,
&internal_behavior);
/* Get notify configuration information by user to decide the action of
each attribute. */
notify_event_info = mmi_nmgr_get_event_notify_info(noti_info->notify_type,
active_scen_id);
MMI_ASSERT(NULL != notify_event_info);
attri_action = notify_event_info->behavior;
parse_attri_action(attri_action, &action_struct);
//add end
if (notification_type != MMI_NOTIFY_BALLOON)
{
if (is_stop_tone == MMI_FALSE)
{
mmi_nmgr_sound_play_evt_struct sound_event;
MMI_FRM_INIT_EVENT(&sound_event, SOUND_PLAY_EVT);
sound_event.noti_scen_id = noti_info->noti_scen_id;
sound_event.tone_id = notify_event_info->tone_id;
sound_event.behavior = internal_behavior.snd_behavior;
sound_event.action = action_struct.snd_action;
sound_event.display_scrn = display_scrn;
if(noti_info->alert_info!=NULL)
{
memcpy(&sound_event.snd_info, &noti_info->alert_info->snd_para,
sizeof(mmi_frm_nmgr_alert_snd_struct));
if(sound_event.snd_info.sound_type == MMI_NMGR_SND_FILE_PATH)
{
sound_event.snd_info.sound.file_path =
mmi_frm_alloc_and_copy_string_to_nmgr_buff_internal(
noti_info->alert_info->snd_para.sound.file_path,MMI_MAX_FILE_NAME_LEN);
}
}
MMI_FRM_POST_EVENT(&sound_event, nmgr_control_proc, NULL);
}
if (is_stop_vib == MMI_FALSE)
{
mmi_nmgr_vib_play_evt_struct vib_event;
MMI_FRM_INIT_EVENT(&vib_event, VIB_PLAY_EVT);
vib_event.noti_scen_id = noti_info->noti_scen_id;
vib_event.behavior = internal_behavior.vib_behavior;
vib_event.action = action_struct.vib_action;
MMI_FRM_POST_EVENT(&vib_event, nmgr_control_proc, NULL);
}
}
if (!(notification_type == MMI_NOTIFY_BALLOON && display_scrn ==
MMI_FALSE))
{
mmi_nmgr_bl_ctrl_evt_struct bl_event;
MMI_FRM_INIT_EVENT(&bl_event,BACKLIGHT_CTRL);
bl_event.action = action_struct.bl_action;
bl_event.behavior = internal_behavior.bl_behavior;
MMI_FRM_POST_EVENT(&bl_event, nmgr_control_proc, NULL);
}
}
return display_scrn;
}
以上修改可以打patch MAUI_03207462。http://bbs.16rd.com/thread-476762-1-1.html

这篇关于FAQ-MT6250,11B1132MP,录音过程中来闹铃,没有铃声的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/787692

相关文章

Java中对象的创建和销毁过程详析

《Java中对象的创建和销毁过程详析》:本文主要介绍Java中对象的创建和销毁过程,对象的创建过程包括类加载检查、内存分配、初始化零值内存、设置对象头和执行init方法,对象的销毁过程由垃圾回收机... 目录前言对象的创建过程1. 类加载检查2China编程. 分配内存3. 初始化零值4. 设置对象头5. 执行

SpringBoot整合easy-es的详细过程

《SpringBoot整合easy-es的详细过程》本文介绍了EasyES,一个基于Elasticsearch的ORM框架,旨在简化开发流程并提高效率,EasyES支持SpringBoot框架,并提供... 目录一、easy-es简介二、实现基于Spring Boot框架的应用程序代码1.添加相关依赖2.添

SpringBoot中整合RabbitMQ(测试+部署上线最新完整)的过程

《SpringBoot中整合RabbitMQ(测试+部署上线最新完整)的过程》本文详细介绍了如何在虚拟机和宝塔面板中安装RabbitMQ,并使用Java代码实现消息的发送和接收,通过异步通讯,可以优化... 目录一、RabbitMQ安装二、启动RabbitMQ三、javascript编写Java代码1、引入

JavaScript中的reduce方法执行过程、使用场景及进阶用法

《JavaScript中的reduce方法执行过程、使用场景及进阶用法》:本文主要介绍JavaScript中的reduce方法执行过程、使用场景及进阶用法的相关资料,reduce是JavaScri... 目录1. 什么是reduce2. reduce语法2.1 语法2.2 参数说明3. reduce执行过程

redis群集简单部署过程

《redis群集简单部署过程》文章介绍了Redis,一个高性能的键值存储系统,其支持多种数据结构和命令,它还讨论了Redis的服务器端架构、数据存储和获取、协议和命令、高可用性方案、缓存机制以及监控和... 目录Redis介绍1. 基本概念2. 服务器端3. 存储和获取数据4. 协议和命令5. 高可用性6.

PLsql Oracle 下载安装图文过程详解

《PLsqlOracle下载安装图文过程详解》PL/SQLDeveloper是一款用于开发Oracle数据库的集成开发环境,可以通过官网下载安装配置,并通过配置tnsnames.ora文件及环境变... 目录一、PL/SQL Developer 简介二、PL/SQL Developer 安装及配置详解1.下

在Java中使用ModelMapper简化Shapefile属性转JavaBean实战过程

《在Java中使用ModelMapper简化Shapefile属性转JavaBean实战过程》本文介绍了在Java中使用ModelMapper库简化Shapefile属性转JavaBean的过程,对比... 目录前言一、原始的处理办法1、使用Set方法来转换2、使用构造方法转换二、基于ModelMapper

springboot启动流程过程

《springboot启动流程过程》SpringBoot简化了Spring框架的使用,通过创建`SpringApplication`对象,判断应用类型并设置初始化器和监听器,在`run`方法中,读取配... 目录springboot启动流程springboot程序启动入口1.创建SpringApplicat

本地搭建DeepSeek-R1、WebUI的完整过程及访问

《本地搭建DeepSeek-R1、WebUI的完整过程及访问》:本文主要介绍本地搭建DeepSeek-R1、WebUI的完整过程及访问的相关资料,DeepSeek-R1是一个开源的人工智能平台,主... 目录背景       搭建准备基础概念搭建过程访问对话测试总结背景       最近几年,人工智能技术

Linux部署jar包过程

《Linux部署jar包过程》文章介绍了在Linux系统上部署Java(jar)包时需要注意的几个关键点,包括统一JDK版本、添加打包插件、修改数据库密码以及正确执行jar包的方法... 目录linux部署jar包1.统一jdk版本2.打包插件依赖3.修改密码4.执行jar包总结Linux部署jar包部署