/TIENITCodeGener/frmAbout.cs
http://gener.codeplex.com · C# · 196 lines · 160 code · 21 blank · 15 comment · 18 complexity · de59527d745a642b35942bfd06940032 MD5 · raw file
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Text;
- using System.Windows.Forms;
-
- namespace TIENITCodeGener
- {
- public partial class frmAbout : Form
- {
-
- #region "Constructor"
- public frmAbout()
- {
- InitializeComponent();
- ITFACommon.SetFormIcon(this);
- SetLanguage();
- this.Size = new System.Drawing.Size(599, 205);
- }
- #endregion
-
- #region "Form Events"
- private void frmAbout_Load(object sender, EventArgs e)
- {
- try
- {
- SetEditionName();
- }
- catch
- {
- }
- }
-
- private void frmAbout_KeyDown(object sender, KeyEventArgs e)
- {
- if (e.KeyCode == Keys.Escape)
- {
- this.Close();
- }
- }
- #endregion
-
- #region "Common Function"
- private void SetEditionName()
- {
- // EDITION
- // ULT : Ultimate - Full Option
- // PRO_NET : Professional for .NET
- // PRO_JAVA : Professional for Java
- // PRO_WP : Professional for Windows Phone
- // PRO_IOS : Professional for iOS
- // PRO_ANDROID : Professional for Android
- if (TIENITCodeGener.Properties.Settings.Default.Soft_Edition.Equals("ULT"))
- {
- lbl_Edition.Text = "Ultimate";
- }
- else if (TIENITCodeGener.Properties.Settings.Default.Soft_Edition.Equals("PRO_NET"))
- {
- lbl_Edition.Text = "Professional for .NET";
- }
- else if (TIENITCodeGener.Properties.Settings.Default.Soft_Edition.Equals("PRO_JAVA"))
- {
- lbl_Edition.Text = "Professional for Java";
- }
- else if (TIENITCodeGener.Properties.Settings.Default.Soft_Edition.Equals("PRO_WP"))
- {
- lbl_Edition.Text = "Professional for WP";
- }
- else if (TIENITCodeGener.Properties.Settings.Default.Soft_Edition.Equals("PRO_IOS"))
- {
- lbl_Edition.Text = "Professional for iOS";
- }
- else if (TIENITCodeGener.Properties.Settings.Default.Soft_Edition.Equals("PRO_ANDROID"))
- {
- lbl_Edition.Text = "Professional for Android";
- }
- }
-
- private void SetLanguage()
- {
- if (TIENITCodeGener.Properties.Settings.Default.Soft_Language.Equals("EN-US"))
- {
- lbl_Title.Text = "Software Information";
- this.Text = "Software Information";
- toolTip.SetToolTip(pic_Groups, "More information ...");
- }
- else if (TIENITCodeGener.Properties.Settings.Default.Soft_Language.Equals("VI-VN"))
- {
- lbl_Title.Text = "Thông Tin Phần Mềm";
- this.Text = "Thông Tin Phần Mềm";
- toolTip.SetToolTip(pic_Groups, "Thông tin thêm ...");
- }
- }
- #endregion
-
- #region "Link Click"
- private void StartURL(string url)
- {
- System.Diagnostics.Process.Start(url);
- }
-
- private void lbl_FB_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL(lbl_FB.Text);
- }
-
- private void lbl_GooglePlus_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL(lbl_GooglePlus.Text);
- }
-
- private void lbl_Wordpress_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL(lbl_Wordpress.Text);
- }
-
- private void lbl_Twitter_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL(lbl_Twitter.Text);
- }
-
- private void lbl_LinkedIn_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL(lbl_LinkedIn.Text);
- }
-
- private void lbl_YuoTube_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL(lbl_YuoTube.Text);
- }
-
- private void lbl_Flickr_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL(lbl_Flickr.Text);
- }
-
- private void lbl_Gmail_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL("mailto:bktien@gmail.com");
- }
-
- private void lbl_Yahoo_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL("mailto:nguyen_quyet_tien_87hy@yahoo.com");
- }
-
- private void lbl_Skype_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL("skype:tiennq187");
- }
-
- private void lbl_Hotmail_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
- {
- StartURL("mailto:tienit@outlook.com");
- }
- #endregion
-
- #region "Timer"
- private void timer_ABOUT_Tick(object sender, EventArgs e)
- {
- try
- {
- int _seconds = DateTime.Now.Second;
- if (_seconds % 2 == 0)
- {
- picICON.Image = TIENITCodeGener.Properties.Resources.CG_METRO_144;
- }
- else
- {
- picICON.Image = TIENITCodeGener.Properties.Resources.CG_METRO_144_ONE;
- }
- }
- catch
- {
- }
- }
- #endregion
-
- #region "More Information"
- private void pic_Groups_Click(object sender, EventArgs e)
- {
- //if (this.Size.Height == 205)
- //{
- // this.Size = new System.Drawing.Size(599, 684);
- //}
- //else if (this.Size.Height == 684)
- //{
- // this.Size = new System.Drawing.Size(599, 205);
- //}
- }
- #endregion
-
- }
- }