您的位置:首页 > 其它

symbian_s60_9.2_localization

2010-03-05 15:22 155 查看
symbian s60 系列 9.2 platform无需单独做本地化,直接abld build 生成。

资源文件统一编译生成在/epoc32/data/z/resource/目录下,

编译的可执行二进制文件放在相应平台的release/***/urel或者udeb目录下

多语言支持的本地化文件统一生成系统统一放在%epocroot%/data/z/resource/目录下可供emulator or armv*使用。

关于资源文件配置在bld.inf中:

PRJ_EXPORTS

//.iby files is used for create image, we should put the .iby to system relative root
../rom/gspreferrednetworkplugin.iby /epoc32/rom/include/customer/app/gspreferrednetworkplugin.iby
../rom/gspreferrednetworkpluginresources.iby /epoc32/rom/include/customer/app/gspreferrednetworkpluginresources.iby
../rom/gspreferrednetworkpluginloc.iby /epoc32/rom/include/customer/app/gspreferrednetworkpluginloc.iby

//*.loc *_01.loc *_31.loc *_159.loc is copied to APP_LAYER_LOC_EXPORT_PATH ( macor defines %epocroot%/epoc32/include/platform/app/loc)

../loc/gspreferrednetworkplugin.loc APP_LAYER_LOC_EXPORT_PATH( ../gspreferrednetworkplugin.loc )

// content of ../loc/gspreferrednetworkplugin.loc
#if LANGUAGE_sc
#include <sc/gspreferrednetworkplugin.loc>
#elif LANGUAGE_00
#include <00/gspreferrednetworkplugin_00.loc>
#elif LANGUAGE_01
#include <01/gspreferrednetworkplugin_01.loc>
#elif LANGUAGE_02
#include <02/gspreferrednetworkplugin_02.loc>
#elif LANGUAGE_03
#include <03/gspreferrednetworkplugin_03.loc>
#elif LANGUAGE_04
#include <04/gspreferrednetworkplugin_04.loc>
#elif LANGUAGE_05
#include <05/gspreferrednetworkplugin_05.loc>
#elif LANGUAGE_06
#include <06/gspreferrednetworkplugin_06.loc>
#elif LANGUAGE_07
#include <07/gspreferrednetworkplugin_07.loc>
#elif LANGUAGE_08
#include <08/gspreferrednetworkplugin_08.loc>
#elif LANGUAGE_09
#include <09/gspreferrednetworkplugin_09.loc>
#elif LANGUAGE_10
#include <10/gspreferrednetworkplugin_10.loc>
#elif LANGUAGE_102
#include <102/gspreferrednetworkplugin_102.loc>
#elif LANGUAGE_103
#include <103/gspreferrednetworkplugin_103.loc>
#elif LANGUAGE_129
#include <129/gspreferrednetworkplugin_129.loc>
#elif LANGUAGE_13
#include <13/gspreferrednetworkplugin_13.loc>
#elif LANGUAGE_14
#include <14/gspreferrednetworkplugin_14.loc>
#elif LANGUAGE_15
#include <15/gspreferrednetworkplugin_15.loc>
#elif LANGUAGE_157
#include <157/gspreferrednetworkplugin_157.loc>
#elif LANGUAGE_158
#include <158/gspreferrednetworkplugin_158.loc>
#elif LANGUAGE_159
#include <159/gspreferrednetworkplugin_159.loc>
#elif LANGUAGE_16
#endif

../loc/sc/gspreferrednetworkplugin.loc APP_LAYER_LOC_EXPORT_PATH( gspreferrednetworkplugin.loc )

//content of ../loc/sc/gspreferednerworkplugin.loc
#define qtn_uplmn_softkey_options "Options"
#define qtn_uplmn_softkey_edit "Edit"
#define qtn_uplmn_softkey_done "Done"
#define qtn_uplmn_menu_delete "Delete"
#define qtn_uplmn_menu_help "Help"
#define qtn_uplmn_menu_exit "Exit"
#define qtn_uplmn_note_ok "Ok"
#define qtn_uplmn_note_cancel "Cancel"

../loc/01/gspreferrednetworkplugin_01.loc APP_LAYER_LOC_EXPORT_PATH( ../01/gspreferrednetworkplugin_01.loc ) //same as above

../loc/159/gspreferrednetworkplugin_159.loc APP_LAYER_LOC_EXPORT_PATH( ../159/gspreferrednetworkplugin_159.loc ) //same as above

../loc/31/gspreferrednetworkplugin_31.loc APP_LAYER_LOC_EXPORT_PATH( ../31/gspreferrednetworkplugin_31.loc ) //定义中文字符串

#define qtn_uplmn_menu_delete "删除"
#define qtn_uplmn_menu_help "帮助"
#define qtn_uplmn_menu_exit "退出"
#define qtn_uplmn_note_ok "确认"
#define qtn_uplmn_note_cancel "取消"


资源文件的配置在:*.mmp 中资源编写节选:

#include <data_caging_paths.hrh> //this is needed for RESOURCE_FILES_DIR
#include <platform_paths.hrh>

SOURCEPATH ../data

//ECOM resource definition
START RESOURCE 2002B33E.rss //this is search in ../data
TARGET gspreferrednetworkplugin.rsc //生成目标文件名
TARGETPATH ECOM_RESOURCE_DIR // macro define %epocroot%/epoc32/data/z/resource/plugins/
END // ECOM resource definition

START RESOURCE gspreferrednetworkpluginrsc.rss //this is search in ../data
HEADER
TARGETPATH RESOURCE_FILES_DIR // macro define %epocroot%/epoc32/data/z/resource/
LANG sc 01 31 159 //this means the target files include four files named of

//gspreferrednetworkpluginrsc.r01 gspreferrednetworkpluginrsc.r31

//gspreferrednetworkpluginrsc.r159 gspreferrednetworkpluginrsc.rsc
END //resources

注意生成资源文件的名字:

chitian.loc(宏定义文件)

/sc/chitian.loc (默认语言英文资源文件)

/01/chitian_01.loc --->>> chitianrsc.r01

/159/chitian_159.loc--->>> chitianrsc.r159

/31/chitian_31.loc --->>> chitianrsc.r31
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: