From c1467477983557edf34cb4773581782be76df34f Mon Sep 17 00:00:00 2001 From: minl1 Date: Mon, 10 Apr 2017 14:20:42 +0800 Subject: [PATCH] CP-21662:replace the icon for new vm template(asianux and turbo linux) in Xencenter --- XenAdmin/Images.cs | 2 + XenAdmin/Images/asianux_16x.png | Bin 0 -> 3524 bytes XenAdmin/Images/turbo_16x.png | Bin 0 -> 540 bytes XenAdmin/Properties/Resources.Designer.cs | 23 ++++++++++ XenAdmin/Properties/Resources.resx | 6 +++ XenAdmin/Properties/Resources.zh-CN.resx | 6 +++ XenAdmin/Wizards/NewVMWizard/Page_Template.cs | 8 ++++ XenAdmin/XenAdmin.csproj | 2 + XenModel/Icons.cs | 2 + XenModel/Messages.Designer.cs | 20 +++++++++ XenModel/Messages.resx | 6 +++ XenModel/Messages.zh-CN.resx | 6 +++ XenModel/XenAPI-Extensions/VM.cs | 40 +++++++++++------- XenModel/XenSearch/Common.cs | 4 ++ 14 files changed, 109 insertions(+), 16 deletions(-) create mode 100644 XenAdmin/Images/asianux_16x.png create mode 100644 XenAdmin/Images/turbo_16x.png diff --git a/XenAdmin/Images.cs b/XenAdmin/Images.cs index 494fc092c..d452bfca8 100644 --- a/XenAdmin/Images.cs +++ b/XenAdmin/Images.cs @@ -132,6 +132,8 @@ namespace XenAdmin ImageList16.Images.Add("ubuntu_16x.png", Properties.Resources.ubuntu_16x); ImageList16.Images.Add("scilinux_16x.png", Properties.Resources.scilinux_16x); ImageList16.Images.Add("neokylin_16x.png", Properties.Resources.neokylin_16x); + ImageList16.Images.Add("asianux_16x.png", Properties.Resources.asianux_16x); + ImageList16.Images.Add("turbo_16x.png", Properties.Resources.turbo_16x); ImageList16.Images.Add("windows_h32bit_16.png", Properties.Resources.windows_h32bit_16); ImageList16.Images.Add("coreos-globe-icon.png", Properties.Resources.coreos_globe_icon); diff --git a/XenAdmin/Images/asianux_16x.png b/XenAdmin/Images/asianux_16x.png new file mode 100644 index 0000000000000000000000000000000000000000..de0c5c5b8c9a2f59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EXaa*`=|u(R%sNGl*T1_|xx1H%z=v8;f0_%^Ij_ovxoVWab=Hl@?m(vpNfq zjk~Y9Xc;%y`3xHH_i3sV9e1oq0`>-FZL{@sdJLPz66tFDK6|> z!udUUB;zU6q)IG0O--o}Gp*7)Fiz>IhvKs~v{b@!U;#P@)2LG_ibH4rMuo3GrZ9w{ zy4b_sBAIXBBkU_)%(?0?c0I+>%g@-ldg%fn8qpY=Nb;zDGcVr%L|J5GO-Lf(wOO!y z#UWg4MlN@e`u6tvdTX%KXYuWpODYw&HFwQ z$prCO1lgYE@#}62U^Ve(%NQpr*Kq6JTO6XkfZr>&Ogv5pi5VSnqXhl3b)A!ORjBNg zZzyDYSf6)Ll%K=xM;~xYb`I@WMJV9L<8}}Z`It2fN>?iU5%3839J@-wtPTfA&1hNa zJfM3hiB05n1kTvUA7XJdlAi7YpLB=&c~h+e6l+$od@Ll z{bbS_HB}`vz39f}auLk+;S~AIkxjJsMme^79XQ;yed@P_9*=Bg3vi>p21)h_Covwj z4e=vpa{cij|9??=`FR@ME_1(ql;hW)GOgKAmIOIlS7`wp6%`eYCr=#3BYU{>q>I$7 z#K&PB6)yu3lfkHXCUpiTRHDf=y~8oCoH`)fmeJbUx-bjb+Dq0KaJjjQZzCDR-z&N; yw#6(+MuwamgB8nNT&gQ$TXDg>NW^cBGyDQtKR0GaeKLpu0000004R=004l4008;_004mK004C`008P>0026d000+nm#LZ500009 za7bBm000ie000ie0hKEb8vp~_GxwfLg~MSEjlc`4nK-!OuzJqzUOx*FdH7m|;1Lm;v;rIj&&d;;mUtdNl+ zD^RJ`@C@pKCIu3o92QUGLPm;6kj-Wh2m}yhS**J>K)yt53LL(Cp)VK(y%8au6@}du zL;{9k;Pd&g;Ps-z)Qx$&7ATN2CN;J;27adzpp?Sy3X)%-X&P$s@obLu069`kB /// Looks up a localized resource of type System.Drawing.Bitmap. /// + + internal static System.Drawing.Bitmap asianux_16x { + get { + object obj = ResourceManager.GetObject("asianux_16x", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + + internal static System.Drawing.Bitmap turbo_16x { + get { + object obj = ResourceManager.GetObject("turbo_16x", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap notif_alerts_16 { get { object obj = ResourceManager.GetObject("notif_alerts_16", resourceCulture); diff --git a/XenAdmin/Properties/Resources.resx b/XenAdmin/Properties/Resources.resx index f1c373182..34fae77ff 100644 --- a/XenAdmin/Properties/Resources.resx +++ b/XenAdmin/Properties/Resources.resx @@ -1093,4 +1093,10 @@ ..\Images\neokylin_16x.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Images\asianux_16x.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Images\turbo_16x.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + \ No newline at end of file diff --git a/XenAdmin/Properties/Resources.zh-CN.resx b/XenAdmin/Properties/Resources.zh-CN.resx index d041e539f..a996c4102 100644 --- a/XenAdmin/Properties/Resources.zh-CN.resx +++ b/XenAdmin/Properties/Resources.zh-CN.resx @@ -1093,4 +1093,10 @@ ..\Images\neokylin_16x.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + ..\Images\asianux_16x.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + + + ..\Images\turbo_16x.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + \ No newline at end of file diff --git a/XenAdmin/Wizards/NewVMWizard/Page_Template.cs b/XenAdmin/Wizards/NewVMWizard/Page_Template.cs index 583f6a3c1..7e6361b10 100644 --- a/XenAdmin/Wizards/NewVMWizard/Page_Template.cs +++ b/XenAdmin/Wizards/NewVMWizard/Page_Template.cs @@ -319,6 +319,10 @@ namespace XenAdmin.Wizards.NewVMWizard return Messages.NEW_VM_WIZARD_TEMPLATEPAGE_UBUNTU; case VM.VmTemplateType.NeoKylin: return Messages.NEW_VM_WIZARD_TEMPLATEPAGE_NEOKYLIN; + case VM.VmTemplateType.Asianux: + return Messages.NEW_VM_WIZARD_TEMPLATEPAGE_ASIANUX; + case VM.VmTemplateType.Turbo: + return Messages.NEW_VM_WIZARD_TEMPLATEPAGE_TURBO; case VM.VmTemplateType.Citrix: return Messages.NEWVMWIZARD_TEMPLATEPAGE_CITRIX; case VM.VmTemplateType.Solaris: @@ -358,6 +362,10 @@ namespace XenAdmin.Wizards.NewVMWizard return Resources.ubuntu_16x; case VM.VmTemplateType.NeoKylin: return Resources.neokylin_16x; + case VM.VmTemplateType.Asianux: + return Resources.asianux_16x; + case VM.VmTemplateType.Turbo: + return Resources.turbo_16x; case VM.VmTemplateType.Citrix: return Resources.Logo; case VM.VmTemplateType.Solaris: diff --git a/XenAdmin/XenAdmin.csproj b/XenAdmin/XenAdmin.csproj index 8581b0a24..f8e3a52a7 100644 --- a/XenAdmin/XenAdmin.csproj +++ b/XenAdmin/XenAdmin.csproj @@ -4385,6 +4385,8 @@ + + diff --git a/XenModel/Icons.cs b/XenModel/Icons.cs index 4acaee98c..910346f6f 100644 --- a/XenModel/Icons.cs +++ b/XenModel/Icons.cs @@ -108,6 +108,8 @@ namespace XenAdmin Ubuntu, SciLinux, NeoKylin, + Asianux, + Turbo, Windows, CoreOS, diff --git a/XenModel/Messages.Designer.cs b/XenModel/Messages.Designer.cs index 9e80b8f70..6ae79782f 100755 --- a/XenModel/Messages.Designer.cs +++ b/XenModel/Messages.Designer.cs @@ -23515,6 +23515,26 @@ namespace XenAdmin { return ResourceManager.GetString("NEW_VM_WIZARD_TEMPLATEPAGE_NEOKYLIN", resourceCulture); } } + + /// + /// Looks up a localized string similar to Asianux. + /// + + public static string NEW_VM_WIZARD_TEMPLATEPAGE_ASIANUX { + get { + return ResourceManager.GetString("NEW_VM_WIZARD_TEMPLATEPAGE_ASIANUX", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to Turbo. + /// + + public static string NEW_VM_WIZARD_TEMPLATEPAGE_TURBO { + get { + return ResourceManager.GetString("NEW_VM_WIZARD_TEMPLATEPAGE_TURBO", resourceCulture); + } + } /// /// Looks up a localized string similar to Ubuntu. diff --git a/XenModel/Messages.resx b/XenModel/Messages.resx index ae305d500..c35774647 100755 --- a/XenModel/Messages.resx +++ b/XenModel/Messages.resx @@ -8823,6 +8823,12 @@ It is strongly recommended that you Cancel and apply the latest version of the p NeoKylin + + Asianux + + + Turbo + Ubuntu diff --git a/XenModel/Messages.zh-CN.resx b/XenModel/Messages.zh-CN.resx index d8fc29652..156454674 100755 --- a/XenModel/Messages.zh-CN.resx +++ b/XenModel/Messages.zh-CN.resx @@ -8850,6 +8850,12 @@ VM 克隆使用文件管理器的快照和克隆功能来实现高性能,并 NeoKylin + + Asianux + + + Turbo + Ubuntu diff --git a/XenModel/XenAPI-Extensions/VM.cs b/XenModel/XenAPI-Extensions/VM.cs index b178a959f..88c79ce9e 100644 --- a/XenModel/XenAPI-Extensions/VM.cs +++ b/XenModel/XenAPI-Extensions/VM.cs @@ -1006,7 +1006,7 @@ namespace XenAPI /// Sort in the following order: /// 1) User Templates /// 2) Windows VMs - /// 3) Other VMs (e.g. Linux) + /// 3) Other VMs (e.g. Linux . Names in alphabetical order) /// 4) Citrix VMs (e.g. XenApp templates) /// 5) Misc VMs /// 6) Regular snapshots @@ -1019,21 +1019,23 @@ namespace XenAPI Custom = 1, Windows = 2, LegacyWindows = 3, - Centos = 4, - CoreOS = 5, - Debian = 6, - NeoKylin = 7, - Oracle = 8, - RedHat = 9, - SciLinux = 10, - Suse = 11, - Ubuntu = 12, - Citrix = 13, - Solaris = 14, - Misc = 15, - Snapshot = 16, - SnapshotFromVmpp = 17, - Count = 18 //bump this if values are added + Asianux = 4, + Centos = 5, + CoreOS = 6, + Debian = 7, + NeoKylin = 8, + Oracle = 9, + RedHat = 10, + SciLinux = 11, + Suse = 12, + Turbo = 13, + Ubuntu = 14, + Citrix = 15, + Solaris = 16, + Misc = 17, + Snapshot = 18, + SnapshotFromVmpp = 19, + Count = 20 //bump this if values are added } public VmTemplateType TemplateType @@ -1087,6 +1089,12 @@ namespace XenAPI if (os.Contains("kylin")) return VmTemplateType.NeoKylin; + if (os.Contains("asianux")) + return VmTemplateType.Asianux; + + if (os.Contains("turbo")) + return VmTemplateType.Turbo; + if (os.Contains("solaris")) return VmTemplateType.Solaris; diff --git a/XenModel/XenSearch/Common.cs b/XenModel/XenSearch/Common.cs index 6ce517a03..8720e1874 100644 --- a/XenModel/XenSearch/Common.cs +++ b/XenModel/XenSearch/Common.cs @@ -1255,6 +1255,10 @@ namespace XenAdmin.XenSearch return Icons.SciLinux; if (os.Contains("kylin")) return Icons.NeoKylin; + if (os.Contains("asianux")) + return Icons.Asianux; + if (os.Contains("turbo")) + return Icons.Turbo; if (os.Contains("windows")) return Icons.Windows; if (os.Contains("coreos"))