mirror of
https://gitee.com/openharmony/inputmethod_imf
synced 2024-11-23 14:49:59 +00:00
modify code
Signed-off-by: zhaolinglan <zhaolinglan@huawei.com>
This commit is contained in:
parent
7b3847671c
commit
8544d4bd9c
@ -484,8 +484,7 @@ std::shared_ptr<Property> ImeInfoInquirer::GetImeByBundleName(int32_t userId, co
|
||||
}
|
||||
Property prop = { .name = extInfos[0].bundleName,
|
||||
.id = extInfos[0].name,
|
||||
.label =
|
||||
GetStringById(extInfos[0].bundleName, extInfos[0].moduleName, extInfos[0].applicationInfo.labelId, userId),
|
||||
.label = extInfos[0].applicationInfo.label,
|
||||
.labelId = extInfos[0].applicationInfo.labelId,
|
||||
.iconId = extInfos[0].applicationInfo.iconId };
|
||||
return std::make_shared<Property>(prop);
|
||||
|
@ -163,10 +163,10 @@ bool InputTypeManager::ParseFromCustomSystem()
|
||||
}
|
||||
std::vector<InputTypeCfg> configs;
|
||||
if (!GetCfgsFromFile(path, configs)) {
|
||||
IMSA_HILOGE("failed to GetCfgsFromFile");
|
||||
isSuccess = false;
|
||||
continue;
|
||||
}
|
||||
isSuccess = true;
|
||||
std::lock_guard<std::mutex> lock(typesLock_);
|
||||
for (const auto &config : configs) {
|
||||
inputTypes_[config.type] = config.ime;
|
||||
|
@ -70,14 +70,14 @@ void InputMethodPrivateMemberTest::SetUp(void)
|
||||
{
|
||||
IMSA_HILOGI("InputMethodPrivateMemberTest::SetUp");
|
||||
ImeCfgManager::GetInstance().imeConfigs_.clear();
|
||||
ImeInfoInquirer::GetInstance().SetCurrentInfo(nullptr);
|
||||
ImeInfoInquirer::GetInstance().SetCurrentImeInfo(nullptr);
|
||||
}
|
||||
|
||||
void InputMethodPrivateMemberTest::TearDown(void)
|
||||
{
|
||||
IMSA_HILOGI("InputMethodPrivateMemberTest::TearDown");
|
||||
ImeCfgManager::GetInstance().imeConfigs_.clear();
|
||||
ImeInfoInquirer::GetInstance().SetCurrentInfo(nullptr);
|
||||
ImeInfoInquirer::GetInstance().SetCurrentImeInfo(nullptr);
|
||||
}
|
||||
sptr<InputMethodSystemAbility> InputMethodPrivateMemberTest::service_;
|
||||
|
||||
@ -368,7 +368,7 @@ HWTEST_F(InputMethodPrivateMemberTest, SA_SwitchByCombinationKey_001, TestSize.L
|
||||
|
||||
/**
|
||||
* @tc.name: SA_SwitchByCombinationKey_002
|
||||
* @tc.desc: SwitchLanguage()/SwitchMode():GetInfo failed
|
||||
* @tc.desc: SwitchLanguage()/SwitchMode():GetImeInfo failed
|
||||
* @tc.type: FUNC
|
||||
* @tc.require:
|
||||
* @tc.author: chenyu
|
||||
|
Loading…
Reference in New Issue
Block a user