diff --git a/Outlook2013TodoAddIn/Constants.cs b/Outlook2013TodoAddIn/Constants.cs index 6c164f3..a140076 100644 --- a/Outlook2013TodoAddIn/Constants.cs +++ b/Outlook2013TodoAddIn/Constants.cs @@ -37,6 +37,11 @@ namespace Outlook2013TodoAddIn /// public const string FollowUp = "Follow up"; + /// + /// URL to paypal donation site, in case someone want's to buy me a beer ;-) + /// + public const string DonateUrl = "https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=ZXYEC3PM6K7TQ&lc=US&item_name=Outlook2103AddInBuyBeer¤cy_code=USD&bn=PP%2dDonationsBF%3amybutton%2epng%3aNonHosted"; + #endregion "Variables" } } \ No newline at end of file diff --git a/Outlook2013TodoAddIn/Forms/FormConfiguration.Designer.cs b/Outlook2013TodoAddIn/Forms/FormConfiguration.Designer.cs index b18faff..474a01c 100644 --- a/Outlook2013TodoAddIn/Forms/FormConfiguration.Designer.cs +++ b/Outlook2013TodoAddIn/Forms/FormConfiguration.Designer.cs @@ -28,6 +28,7 @@ /// private void InitializeComponent() { + this.components = new System.ComponentModel.Container(); this.chkMailAlerts = new System.Windows.Forms.CheckBox(); this.lblRangeDays = new System.Windows.Forms.Label(); this.numRangeDays = new System.Windows.Forms.NumericUpDown(); @@ -42,7 +43,10 @@ this.lblFirstDayOfWeek = new System.Windows.Forms.Label(); this.chkShowDayNames = new System.Windows.Forms.CheckBox(); this.chkShowWeekNumbers = new System.Windows.Forms.CheckBox(); + this.pctBoxPayPal = new System.Windows.Forms.PictureBox(); + this.toolTip1 = new System.Windows.Forms.ToolTip(this.components); ((System.ComponentModel.ISupportInitialize)(this.numRangeDays)).BeginInit(); + ((System.ComponentModel.ISupportInitialize)(this.pctBoxPayPal)).BeginInit(); this.SuspendLayout(); // // chkMailAlerts @@ -58,7 +62,7 @@ // lblRangeDays // this.lblRangeDays.AutoSize = true; - this.lblRangeDays.Location = new System.Drawing.Point(55, 29); + this.lblRangeDays.Location = new System.Drawing.Point(28, 29); this.lblRangeDays.Name = "lblRangeDays"; this.lblRangeDays.Size = new System.Drawing.Size(44, 17); this.lblRangeDays.TabIndex = 7; @@ -66,7 +70,7 @@ // // numRangeDays // - this.numRangeDays.Location = new System.Drawing.Point(115, 27); + this.numRangeDays.Location = new System.Drawing.Point(88, 27); this.numRangeDays.Maximum = new decimal(new int[] { 30, 0, @@ -193,6 +197,20 @@ this.chkShowWeekNumbers.Text = "Show Week Numbers"; this.chkShowWeekNumbers.UseVisualStyleBackColor = true; // + // pctBoxPayPal + // + this.pctBoxPayPal.Cursor = System.Windows.Forms.Cursors.Hand; + this.pctBoxPayPal.Image = global::Outlook2013TodoAddIn.Properties.Resources.buy_me_a_beer_small; + this.pctBoxPayPal.Location = new System.Drawing.Point(190, 21); + this.pctBoxPayPal.Name = "pctBoxPayPal"; + this.pctBoxPayPal.Size = new System.Drawing.Size(83, 30); + this.pctBoxPayPal.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize; + this.pctBoxPayPal.TabIndex = 21; + this.pctBoxPayPal.TabStop = false; + this.toolTip1.SetToolTip(this.pctBoxPayPal, "If you find it useful and have spare time you can drop me a line saying how you l" + + "ike the tool and such, or better yet, you can buy me a beer if you wish. ;-) "); + this.pctBoxPayPal.Click += new System.EventHandler(this.pictureBox1_Click); + // // FormConfiguration // this.AcceptButton = this.btnOK; @@ -200,6 +218,7 @@ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.CancelButton = this.btnCancel; this.ClientSize = new System.Drawing.Size(282, 482); + this.Controls.Add(this.pctBoxPayPal); this.Controls.Add(this.chkShowWeekNumbers); this.Controls.Add(this.chkShowDayNames); this.Controls.Add(this.lblFirstDayOfWeek); @@ -223,6 +242,7 @@ this.Text = "Configuration"; this.Load += new System.EventHandler(this.FormConfiguration_Load); ((System.ComponentModel.ISupportInitialize)(this.numRangeDays)).EndInit(); + ((System.ComponentModel.ISupportInitialize)(this.pctBoxPayPal)).EndInit(); this.ResumeLayout(false); this.PerformLayout(); @@ -244,5 +264,7 @@ private System.Windows.Forms.Label lblFirstDayOfWeek; private System.Windows.Forms.CheckBox chkShowDayNames; private System.Windows.Forms.CheckBox chkShowWeekNumbers; + private System.Windows.Forms.PictureBox pctBoxPayPal; + private System.Windows.Forms.ToolTip toolTip1; } } \ No newline at end of file diff --git a/Outlook2013TodoAddIn/Forms/FormConfiguration.cs b/Outlook2013TodoAddIn/Forms/FormConfiguration.cs index 6eeb7a1..579ffcf 100644 --- a/Outlook2013TodoAddIn/Forms/FormConfiguration.cs +++ b/Outlook2013TodoAddIn/Forms/FormConfiguration.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.Collections.Specialized; using System.ComponentModel; using System.Data; +using System.Diagnostics; using System.Drawing; using System.Linq; using System.Text; @@ -173,6 +174,16 @@ namespace Outlook2013TodoAddIn.Forms Properties.Settings.Default.FirstDayOfWeek = (System.DayOfWeek)Enum.Parse(typeof(System.DayOfWeek), this.cboFirstDayOfWeek.SelectedValue.ToString()); } + /// + /// Open the default web browser with a link to PayPal in case someone wants to buy me a beer + /// + /// Sender + /// EventArgs + private void pictureBox1_Click(object sender, EventArgs e) + { + Process.Start(Constants.DonateUrl); + } + #endregion "Methods" } } \ No newline at end of file diff --git a/Outlook2013TodoAddIn/Forms/FormConfiguration.resx b/Outlook2013TodoAddIn/Forms/FormConfiguration.resx index 29dcb1b..65a871b 100644 --- a/Outlook2013TodoAddIn/Forms/FormConfiguration.resx +++ b/Outlook2013TodoAddIn/Forms/FormConfiguration.resx @@ -117,4 +117,7 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 17, 17 + \ No newline at end of file diff --git a/Outlook2013TodoAddIn/Images/buy-me-a-beer-small.png b/Outlook2013TodoAddIn/Images/buy-me-a-beer-small.png new file mode 100644 index 0000000..8081496 Binary files /dev/null and b/Outlook2013TodoAddIn/Images/buy-me-a-beer-small.png differ diff --git a/Outlook2013TodoAddIn/Outlook2013TodoAddIn.csproj b/Outlook2013TodoAddIn/Outlook2013TodoAddIn.csproj index 31e2545..2d735ed 100644 --- a/Outlook2013TodoAddIn/Outlook2013TodoAddIn.csproj +++ b/Outlook2013TodoAddIn/Outlook2013TodoAddIn.csproj @@ -288,6 +288,7 @@ + diff --git a/Outlook2013TodoAddIn/Properties/Resources.Designer.cs b/Outlook2013TodoAddIn/Properties/Resources.Designer.cs index 3722d3c..ca88ddb 100644 --- a/Outlook2013TodoAddIn/Properties/Resources.Designer.cs +++ b/Outlook2013TodoAddIn/Properties/Resources.Designer.cs @@ -1,7 +1,7 @@ //------------------------------------------------------------------------------ // // This code was generated by a tool. -// Runtime Version:4.0.30319.18046 +// Runtime Version:4.0.30319.34014 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. @@ -60,6 +60,16 @@ namespace Outlook2013TodoAddIn.Properties { } } + /// + /// Looks up a localized resource of type System.Drawing.Bitmap. + /// + internal static System.Drawing.Bitmap buy_me_a_beer_small { + get { + object obj = ResourceManager.GetObject("buy_me_a_beer_small", resourceCulture); + return ((System.Drawing.Bitmap)(obj)); + } + } + /// /// Looks up a localized resource of type System.Drawing.Bitmap. /// diff --git a/Outlook2013TodoAddIn/Properties/Resources.resx b/Outlook2013TodoAddIn/Properties/Resources.resx index 383bc7f..048faf8 100644 --- a/Outlook2013TodoAddIn/Properties/Resources.resx +++ b/Outlook2013TodoAddIn/Properties/Resources.resx @@ -118,6 +118,9 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + ..\images\buy-me-a-beer-small.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a + ..\Images\Delete.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a