上节说到如何添加输入法到注册表,但发现重启,断电开发板输入法打不开,但存在注册表,只是相关文件丢失
于是照着开发板注册表修改工程里的注册表文件,并将相应文件添加到工程。具体如下:
1,修改platform.bib
IF BSP_NOBACKLIGHT !
backlight.cpl $(_FLATRELEASEDIR)acklight.cpl NK U
ENDIF ; BSP_NOBACKLIGHT !
WnpyCE.dll $(_FLATRELEASEDIR)WnpyCE.dll NK U
findIndex.idx $(_FLATRELEASEDIR)findIndex.idx NK U
; ShiQiang WnpyCab.unload $(_FLATRELEASEDIR)ShiQiang WnpyCab.unload NK U
Total_MB.idx $(_FLATRELEASEDIR)Total_MB.idx NK U
Total_MB.txt $(_FLATRELEASEDIR)Total_MB.txt NK U
WnpyCab.DAT $(_FLATRELEASEDIR)WnpyCab.DAT NK U
WnpyCab.DLL $(_FLATRELEASEDIR)WnpyCab.DLL NK U
ShiQiangWnpyCab.DAT $(_FLATRELEASEDIR)AppMgrShiQiangWnpyCab.DAT NK U
ShiQiangWnpyCab.DLL $(_FLATRELEASEDIR)AppMgrShiQiangWnpyCab.DLL NK U
Wnpy.ARMV4.CAB $(_FLATRELEASEDIR)Wnpy.ARMV4.CAB NK U
; WnpyCE.dll $(_FLATRELEASEDIR)WnpyCE.dll NK U
IF BSP_NOOES !
必须在backlight.cpl $(_FLATRELEASEDIR)acklight.cpl NK U
代码后面添加否则添加不进nk
2,修改platform.reg
[HKEY_LOCAL_MACHINESOFTWAREAppsShiQiang WnpyCab]
"IsvFile"="
\Windows\AppMgr\ShiQiangWnpyCab.DLL"
"CmdFile"="
\Windows\AppMgr\ShiQiangWnpyCab.DAT"
"CabFile"="Wnpy.ARMV4.CAB"
"InstallDir"="
\Program Files\WnpyCab"
"InstlDir"="
\Program Files\WnpyCab"
"Instl"=dword:1
"InstlDirCnt"=dword:1
[HKEY_LOCAL_MACHINESOFTWAREWnpyCE]
"Curfollow"=dword:1
"DisableDefaultIME"=dword:1
"Original IME File"="_myime.dll"
"4ChOnly"=dword:1
"4ChShop"=dword:1
这个目前添加但是没用,所以就有了将cab还要重新安装这一步。
3,将安装的cab解压的文件添加到file目录下
重新编译,这里有个技巧,将file修改的都复制到release下make image就行
烧写nk,安装cab,成功后拔掉电源线重新启动,发现掉电输入法运行正常。
4,这里有个大问题就是添加了注册表但烧写nk没有我们的输入法,必须再安装一遍。如果有访客知道请告知,不胜感谢。