部分选项特殊处理

This commit is contained in:
mo1027728827@qq.com 2022-06-28 17:28:51 +08:00
parent 17454877a8
commit a9f1e5a8dc
5 changed files with 50 additions and 41 deletions

View File

@ -20,13 +20,13 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType> <ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries> <UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset> <PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet> <CharacterSet>Unicode</CharacterSet>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType> <ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries> <UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset> <PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization> <WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet> <CharacterSet>Unicode</CharacterSet>
</PropertyGroup> </PropertyGroup>

View File

@ -20,7 +20,7 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType> <ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries> <UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v120</PlatformToolset> <PlatformToolset>v142</PlatformToolset>
<CharacterSet>Unicode</CharacterSet> <CharacterSet>Unicode</CharacterSet>
<UseOfMfc>Dynamic</UseOfMfc> <UseOfMfc>Dynamic</UseOfMfc>
</PropertyGroup> </PropertyGroup>

View File

@ -6267,11 +6267,20 @@ void* ChgjsonDlg::create_json(int item, std::vector<DEFH>* def_h)
jsn->set_value(L"name", coding::a2u(SANE_STD_OPT_NAME_CUSTOM_AREA_RIGHT).c_str()); jsn->set_value(L"name", coding::a2u(SANE_STD_OPT_NAME_CUSTOM_AREA_RIGHT).c_str());
else if (hg_items_[item].title == L"\u626B\u63CF\u533A\u57DF\u4E0B\u4FA7\uFF08mm\uFF09") else if (hg_items_[item].title == L"\u626B\u63CF\u533A\u57DF\u4E0B\u4FA7\uFF08mm\uFF09")
jsn->set_value(L"name", coding::a2u(SANE_STD_OPT_NAME_CUSTOM_AREA_BOTTOM).c_str()); jsn->set_value(L"name", coding::a2u(SANE_STD_OPT_NAME_CUSTOM_AREA_BOTTOM).c_str());
else if (hg_items_[item].title == L"ÑÕɫģʽ")
jsn->set_value(L"name", coding::a2u(SANE_STD_OPT_NAME_COLOR_MODE).c_str());
else if (hg_items_[item].title == L"Ö½Õųߴç")
jsn->set_value(L"name", coding::a2u(SANE_STD_OPT_NAME_PAPER).c_str());
else if (hg_items_[item].title == L"ɨÃèÒ³Ãæ")
jsn->set_value(L"name", coding::a2u(SANE_STD_OPT_NAME_PAGE_TYPE).c_str());
else if (hg_items_[item].title == L"³¬Éù²¨¼ì²â")
jsn->set_value(L"name", coding::a2u(SANE_STD_OPT_NAME_ULTRASONIC_CHECK).c_str());
else else
{ {
swprintf_s(buf, _countof(buf) - 1, L"cfg-%d", hg_items_[item].index); swprintf_s(buf, _countof(buf) - 1, L"cfg-%d", hg_items_[item].index);
jsn->set_value(L"name", buf); jsn->set_value(L"name", buf);
} }
jsn->set_value(L"title", hg_items_[item].title.c_str()); jsn->set_value(L"title", hg_items_[item].title.c_str());
if (def_h) if (def_h)
ChgjsonDlg::to_define_header(*def_h, hg_items_[item].title.c_str()); ChgjsonDlg::to_define_header(*def_h, hg_items_[item].title.c_str());

Binary file not shown.

Binary file not shown.