Commit d69b7023 刘韬

排除旧代码

1 个父辈 eb8e4d23
......@@ -16,7 +16,7 @@
<UpgradeBackupLocation>
</UpgradeBackupLocation>
<IsWebBootstrapper>true</IsWebBootstrapper>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<TargetFrameworkProfile>
</TargetFrameworkProfile>
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir>
......@@ -295,12 +295,6 @@
<Compile Include="FrmSplash.designer.cs">
<DependentUpon>FrmSplash.cs</DependentUpon>
</Compile>
<Compile Include="FrmTestManage.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmTestManage.designer.cs">
<DependentUpon>FrmTestManage.cs</DependentUpon>
</Compile>
<Compile Include="FrmTestResult.cs">
<SubType>Form</SubType>
</Compile>
......@@ -349,10 +343,6 @@
<EmbeddedResource Include="FrmStandard.resx">
<DependentUpon>FrmStandard.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmTestManage.resx">
<DependentUpon>FrmTestManage.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="FrmTestResult.resx">
<SubType>Designer</SubType>
<DependentUpon>FrmTestResult.cs</DependentUpon>
......@@ -420,9 +410,6 @@
<SubType>Designer</SubType>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
<EmbeddedResource Include="testZedGraph.resx">
<DependentUpon>testZedGraph.cs</DependentUpon>
</EmbeddedResource>
<None Include="msyh.ttc">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
......@@ -454,12 +441,6 @@
<Compile Include="TabPanel.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="testZedGraph.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="testZedGraph.Designer.cs">
<DependentUpon>testZedGraph.cs</DependentUpon>
</Compile>
<Compile Include="WebConfig.cs" />
<Compile Include="XMLEncrypt.cs" />
</ItemGroup>
......@@ -491,10 +472,6 @@
<Project>{7DC9A638-7BE8-4CF7-AC2E-57C77F1BF9BC}</Project>
<Name>OutlookStyleNavigateBar</Name>
</ProjectReference>
<ProjectReference Include="..\Shixin.MyCMMI.BizFacade\BizFacade.csproj">
<Project>{88402163-A455-4C86-8F1E-DAA8C3EEF56E}</Project>
<Name>BizFacade</Name>
</ProjectReference>
<ProjectReference Include="..\TabStripControlLibrary\TabStripControlLibrary.csproj">
<Project>{F63A0939-5ADD-4931-8066-6901B5FBEF67}</Project>
<Name>TabStripControlLibrary</Name>
......
......@@ -161,8 +161,10 @@ namespace App
{
//遍历所有控件 国际化并修改字体
string AppPath = Application.StartupPath;
PrivateFontCollection font = new PrivateFontCollection();
font.AddFontFile(AppPath + @"\msyh.ttc");//字体的路径及名字
//PrivateFontCollection font = new PrivateFontCollection();
//font.AddFontFile(AppPath + @"\msyh.ttc");//字体的路径及名字
//Font font = new Font("微软雅黑", 10);
var fontname = "微软雅黑";
if (control.GetType().BaseType.Name == "Form" || control.GetType().BaseType.Name == "FrmBase")//判断控件是否为Form类型
{
formName = control.Name;
......@@ -173,7 +175,7 @@ namespace App
else
{
control.Text = getMsg(control.Name);//根据传入控件名字返回该控件TEXT
control.Font = new Font(font.Families[0].Name, control.Font.Size);
control.Font = new Font(fontname, control.Font.Size);
}
}
#region 对所有控件做循环,并判断,符合条件的控件能够将名字返回为该控件特定区域的TEXT
......@@ -191,12 +193,12 @@ namespace App
case "TextBox":
//根据传入的控件名字返回该控件在制定语言区域的TEXT属性
control.Controls[i].Text = getMsg(formName + control.Controls[i].Name);
control.Controls[i].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
control.Controls[i].Font = new Font(fontname, control.Controls[i].Font.Size);
break;
case "RibbonButton":
//根据传入的控件名字返回该控件在制定语言区域的TEXT属性
control.Controls[i].Text = getMsg(formName + control.Controls[i].Name);
control.Controls[i].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
control.Controls[i].Font = new Font(fontname, control.Controls[i].Font.Size);
break;
case "Panel":
SetFormLanguage(control.Controls[i]);
......@@ -206,7 +208,7 @@ namespace App
break;
case "TabPanel":
((RibbonStyle.TabPanel)control.Controls[i]).Caption = getMsg(formName + control.Controls[i].Name);
((RibbonStyle.TabPanel)control.Controls[i]).Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
((RibbonStyle.TabPanel)control.Controls[i]).Font = new Font(fontname, control.Controls[i].Font.Size);
SetFormLanguage(control.Controls[i]);
break;
case "TabStrip":
......@@ -214,7 +216,7 @@ namespace App
for (int j = 0; j < ts.Items.Count; j++)
{
ts.Items[j].Text = getMsg(formName + ((RibbonStyle.Tab)ts.Items[j]).Name);
ts.Items[j].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
ts.Items[j].Font = new Font(fontname, control.Controls[i].Font.Size);
SetFormLanguage(control.Controls[i]);//返回该页所拥有控件,并设置其语言
}
break;
......@@ -226,7 +228,7 @@ namespace App
break;
case "GroupBox":
control.Controls[i].Text = getMsg(formName + control.Controls[i].Name);
control.Controls[i].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
control.Controls[i].Font = new Font(fontname, control.Controls[i].Font.Size);
SetFormLanguage(control.Controls[i]);
break;
case "TabControl":
......@@ -234,14 +236,14 @@ namespace App
for (int j = 0; j < tbc.TabCount; j++)
{
tbc.TabPages[j].Text = getMsg(formName + tbc.TabPages[j].Name);
tbc.TabPages[j].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
tbc.TabPages[j].Font = new Font(fontname, control.Controls[i].Font.Size);
SetFormLanguage(tbc.TabPages[j]);//返回该页所拥有控件,并设置其语言
}
break;
case "DataGridView":
DataGridView dgv = (DataGridView)control.Controls[i];
dgv.Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
dgv.Font = new Font(fontname, control.Controls[i].Font.Size);
for (int j = 0; j < dgv.ColumnCount; j++)
{
dgv.Columns[j].HeaderText = getMsg(formName + dgv.Columns[j].Name);
......@@ -253,19 +255,19 @@ namespace App
for (int k = 0; k < ms.Items.Count; k++)
{
ms.Items[k].Text = getMsg(formName + ms.Items[k].Name);
ms.Items[k].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
ms.Items[k].Font = new Font(fontname, control.Controls[i].Font.Size);
menu = (ToolStripMenuItem)ms.Items[k];
for (int l = 0; l < menu.DropDownItems.Count; l++)
{
menu.DropDownItems[l].Text = getMsg(formName + menu.DropDownItems[l].Name);
menu.DropDownItems[l].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
menu.DropDownItems[l].Font = new Font(fontname, control.Controls[i].Font.Size);
}
}
break;
case "ComboBox":
ComboBox cb = (ComboBox)control.Controls[i];
cb.Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
cb.Font = new Font(fontname, control.Controls[i].Font.Size);
//for (int o = 0; o < cb.Items.Count; o++)
//{
if (cb.Items.Count > 0 || cb.DataSource != null)
......@@ -290,7 +292,7 @@ namespace App
for (int x = 0; x < ss.Items.Count; x++)
{
ss.Items[x].Text = getMsg(formName + ss.Items[x].Name);
ss.Items[x].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
ss.Items[x].Font = new Font(fontname, control.Controls[i].Font.Size);
}
break;
case "ToolStrip":
......@@ -299,7 +301,7 @@ namespace App
{
ts1.Items[w].Text = getMsg(formName + ts1.Items[w].Name);
ts1.Items[w].ToolTipText = getMsg(formName + ts1.Items[w].Name + "Tip");
ts1.Items[w].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
ts1.Items[w].Font = new Font(fontname, control.Controls[i].Font.Size);
}
break;
......@@ -312,7 +314,7 @@ namespace App
// break;
case "ListView":
ListView lv = (ListView)control.Controls[i];
lv.Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
lv.Font = new Font(fontname, control.Controls[i].Font.Size);
for (int v = 0; v < lv.Columns.Count; v++)
{
lv.Columns[v].Text = getMsg(formName + lv.Columns[v].Name);
......@@ -324,7 +326,7 @@ namespace App
for (int v = 0; v < cms.Items.Count; v++)
{
cms.Items[v].Text = getMsg(formName + cms.Items[v].Name);
cms.Items[v].Font = new Font(font.Families[0].Name, control.Controls[i].Font.Size);
cms.Items[v].Font = new Font(fontname, control.Controls[i].Font.Size);
}
break;
default:
......
此文件类型无法预览
......@@ -148,7 +148,7 @@ namespace App
private void PauseTest()
{
if (newForm is FrmTestManage)
if (newForm is FrmTestManage2)
{
//if (((FrmTestManage)newForm).IsRealStart)
//{
......
......@@ -16,7 +16,6 @@ namespace App
public partial class MetroTestResult : FrmBase
{
FrmTestResult newForm;
FrmTestManage newForm2;
private LoginManager _loginManager;
private string FileName;
public bool isOpen = true;//判断该窗口是否打开状态
......
......@@ -4,7 +4,6 @@ using System.Windows.Forms;
using System.Diagnostics;
using System.IO;
using Comm;
using BizFacade;
using System.Runtime.InteropServices;
using log4net;
using System.Reflection;
......
......@@ -727,7 +727,7 @@ namespace App.Properties {
///
/// ... ado.net/XML headers &amp; schema ...
/// &lt;resheader name=&quot;resmimetype&quot;&gt;text/microsoft-resx&lt;/resheader&gt;
/// &lt;resheader name=&quot;version&quot;&gt;2. [字符串的其余部分被截断]&quot;; 的本地化字符串。
/// &lt;resheader n [字符串的其余部分被截断]&quot;; 的本地化字符串。
/// </summary>
internal static string LResource_zh_CN {
get {
......
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<configSections>
<sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<section name="BizFacade.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
<section name="MyCMMIConfiguration" type="Comm.Configuration, Comm" />
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />
<section name="BizFacade.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false"/>
<section name="MyCMMIConfiguration" type="Comm.Configuration, Comm"/>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net"/>
</sectionGroup>
</configSections>
<applicationSettings>
......@@ -17,41 +17,41 @@
</setting>
</BizFacade.Properties.Settings>
<MyCMMIConfiguration>
<add key="MyCMMI.MyCMMI.LicencePath" value="D:\Contamination Explorer.lic" />
<add key="MyCMMI.MyCMMI.LicencePath" value="D:\Contamination Explorer.lic"/>
</MyCMMIConfiguration>
<log4net>
<appender name="RollingLogFileAppender" type="log4net.Appender.RollingFileAppender">
<file value="logs\\logFile.log" />
<file value="logs\\logFile.log"/>
<!--file可以指定具体的路径 eg : d:\\test.log。不指定的话log被生成在项目的bin/Debug 或者 bin/Release目录下 (web的项目 默认生成在根目录下)-->
<appendToFile value="true" />
<rollingStyle value="Date" />
<datePattern value="yyyy-MM-dd" />
<bufferSize value="0" />
<appendToFile value="true"/>
<rollingStyle value="Date"/>
<datePattern value="yyyy-MM-dd"/>
<bufferSize value="0"/>
<layout type="log4net.Layout.PatternLayout">
<!--指定log的格式-->
<conversionPattern value="[%date] [%t] %-5p %C(%L) - %m%n" />
<conversionPattern value="[%date] [%t] %-5p %C(%L) - %m%n"/>
<!-- <conversionPattern value="【%d{yyyy/MM/dd HH:mm:ss.fff}】[%t] %-5p %C - %m%n" />-->
</layout>
</appender>
<root>
<level value="Debug" />
<level value="Debug"/>
<!--文件形式记录日志-->
<appender-ref ref="RollingLogFileAppender" />
<appender-ref ref="RollingLogFileAppender"/>
</root>
</log4net>
</applicationSettings>
<startup useLegacyV2RuntimeActivationPolicy="true"><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0" /></startup>
<startup useLegacyV2RuntimeActivationPolicy="true"><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1"/></startup>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="office" publicKeyToken="71e9bce111e9429c" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0" />
<assemblyIdentity name="office" publicKeyToken="71e9bce111e9429c" culture="neutral"/>
<bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.Vbe.Interop" publicKeyToken="71e9bce111e9429c" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0" />
<assemblyIdentity name="Microsoft.Vbe.Interop" publicKeyToken="71e9bce111e9429c" culture="neutral"/>
<bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0"/>
</dependentAssembly>
</assemblyBinding>
</runtime>
......
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="MetroFramework-1.3.0.0" version="1.3.0.0" targetFramework="net40" />
<package id="System.ValueTuple" version="4.5.0" targetFramework="net40" />
<package id="System.ValueTuple" version="4.5.0" targetFramework="net40" requireReinstallation="true" />
<package id="ZedGraph" version="5.1.7" targetFramework="net40" />
</packages>
\ No newline at end of file
......@@ -45,17 +45,10 @@
<ItemGroup>
<Compile Include="Enums.cs" />
<Compile Include="Licence.cs" />
<Compile Include="MyCMMIConfiguration.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Utility.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Shixin.SysFramework\SysFramework.csproj">
<Project>{70F73B3C-62BB-4338-A0C6-370528D8FABE}</Project>
<Name>SysFramework</Name>
</ProjectReference>
</ItemGroup>
<ItemGroup>
<Content Include="DiskSerialNo.dll" />
</ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
......
......@@ -198,51 +198,6 @@
<SubType>Designer</SubType>
<DependentUpon>ZedGraphControl.ContextMenu.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.en-US.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.de.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.es.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.fr.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.hu.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.it.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.ja-JP.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.pt.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.ru.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.sk.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.sv.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.tr.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.tw.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="ZedGraph\ZedGraphLocale.zh-tw.resx">
<SubType>Designer</SubType>
</EmbeddedResource>
</ItemGroup>
<ItemGroup>
<None Include="zedgraphkey.snk" />
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!