aboutsummaryrefslogtreecommitdiff
path: root/source/WindowsFormsApplication1/Apps/About.cs
diff options
context:
space:
mode:
authorMichael VanOverbeek <[email protected]>2016-07-22 08:00:32 -0700
committerGitHub <[email protected]>2016-07-22 08:00:32 -0700
commite4951c025d842484ade89b86f66d4140ff240d03 (patch)
tree9839226f202f7da734aa549fd18427747548731e /source/WindowsFormsApplication1/Apps/About.cs
parentb9911efba3bc070c4a4995a8cf89163ef1685af6 (diff)
parenta1f8770e879259b4b71589c842e5eeb26a59f2fb (diff)
downloadshiftos-c-_theultimatehacker-e4951c025d842484ade89b86f66d4140ff240d03.tar.gz
shiftos-c-_theultimatehacker-e4951c025d842484ade89b86f66d4140ff240d03.tar.bz2
shiftos-c-_theultimatehacker-e4951c025d842484ade89b86f66d4140ff240d03.zip
Merge pull request #9 from carverh/master
Added A LOT
Diffstat (limited to 'source/WindowsFormsApplication1/Apps/About.cs')
-rw-r--r--source/WindowsFormsApplication1/Apps/About.cs115
1 files changed, 115 insertions, 0 deletions
diff --git a/source/WindowsFormsApplication1/Apps/About.cs b/source/WindowsFormsApplication1/Apps/About.cs
new file mode 100644
index 0000000..995b696
--- /dev/null
+++ b/source/WindowsFormsApplication1/Apps/About.cs
@@ -0,0 +1,115 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Drawing;
+using System.Linq;
+using System.Reflection;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+
+namespace ShiftOS.Apps
+{
+ partial class About : Form
+ {
+ public About()
+ {
+ InitializeComponent();
+ this.Text = String.Format("About {0}", AssemblyTitle);
+ this.labelProductName.Text = AssemblyProduct;
+ this.labelVersion.Text = String.Format("Version {0}", AssemblyVersion);
+ this.labelCopyright.Text = AssemblyCopyright;
+ this.labelCompanyName.Text = AssemblyCompany;
+ this.textBoxDescription.Text = AssemblyDescription;
+ }
+
+ #region Assembly Attribute Accessors
+
+ public string AssemblyTitle
+ {
+ get
+ {
+ object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyTitleAttribute), false);
+ if (attributes.Length > 0)
+ {
+ AssemblyTitleAttribute titleAttribute = (AssemblyTitleAttribute)attributes[0];
+ if (titleAttribute.Title != "")
+ {
+ return titleAttribute.Title;
+ }
+ }
+ return System.IO.Path.GetFileNameWithoutExtension(Assembly.GetExecutingAssembly().CodeBase);
+ }
+ }
+
+ public string AssemblyVersion
+ {
+ get
+ {
+ return Assembly.GetExecutingAssembly().GetName().Version.ToString();
+ }
+ }
+
+ public string AssemblyDescription
+ {
+ get
+ {
+ object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyDescriptionAttribute), false);
+ if (attributes.Length == 0)
+ {
+ return "";
+ }
+ return ((AssemblyDescriptionAttribute)attributes[0]).Description;
+ }
+ }
+
+ public string AssemblyProduct
+ {
+ get
+ {
+ object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyProductAttribute), false);
+ if (attributes.Length == 0)
+ {
+ return "";
+ }
+ return ((AssemblyProductAttribute)attributes[0]).Product;
+ }
+ }
+
+ public string AssemblyCopyright
+ {
+ get
+ {
+ object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyCopyrightAttribute), false);
+ if (attributes.Length == 0)
+ {
+ return "";
+ }
+ return ((AssemblyCopyrightAttribute)attributes[0]).Copyright;
+ }
+ }
+
+ public string AssemblyCompany
+ {
+ get
+ {
+ object[] attributes = Assembly.GetExecutingAssembly().GetCustomAttributes(typeof(AssemblyCompanyAttribute), false);
+ if (attributes.Length == 0)
+ {
+ return "";
+ }
+ return ((AssemblyCompanyAttribute)attributes[0]).Company;
+ }
+ }
+ #endregion
+
+ private void logoPictureBox_Click(object sender, EventArgs e)
+ {
+
+ }
+
+ private void textBoxDescription_TextChanged(object sender, EventArgs e)
+ {
+
+ }
+ }
+}