/[cits3200i]/branches/gps-running-clean-r116/HighScorePlugin/Util/WarningDialog.cs


UCC Code Repository

Contents of /branches/gps-running-clean-r116/HighScorePlugin/Util/WarningDialog.cs

Parent Directory Parent Directory | Revision Log Revision Log


Revision 5 - (show annotations) (download)
Sun Sep 5 15:48:34 2010 UTC (11 years, 3 months ago) by rvvs89
File size: 3146 byte(s)
Branching a local copy of the HEAD revision of the gps-running project on Google Code.
We will probably have to use this project as a template for our own plugins if we want to support SportTracks 2.1.
1 /*
2 Copyright (C) 2007, 2008 Kristian Bisgaard Lassen
3 Copyright (C) 2010 Kristian Helkjaer Lassen
4
5 This library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 3 of the License, or (at your option) any later version.
9
10 This library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public
16 License along with this library. If not, see <http://www.gnu.org/licenses/>.
17 */
18
19 using System;
20 using System.Collections.Generic;
21 using System.Text;
22 using System.Windows.Forms;
23 using ZoneFiveSoftware.Common.Visuals;
24
25 namespace GpsRunningPlugin.Util
26 {
27 class WarningDialog : Form
28 {
29 private ZoneFiveSoftware.Common.Visuals.Button ok;
30 private ZoneFiveSoftware.Common.Visuals.TextBox textBox1;
31
32 public WarningDialog(String message)
33 {
34 InitializeComponent();
35 this.textBox1.Text = message;
36 this.StartPosition = FormStartPosition.CenterScreen;
37 this.FormBorderStyle = FormBorderStyle.FixedDialog;
38 ShowDialog();
39 }
40
41 private void InitializeComponent()
42 {
43 this.ok = new ZoneFiveSoftware.Common.Visuals.Button();
44 this.textBox1 = new ZoneFiveSoftware.Common.Visuals.TextBox();
45 this.SuspendLayout();
46 //
47 // ok
48 //
49 this.ok.Location = new System.Drawing.Point(102, 96);
50 this.ok.Name = "ok";
51 this.ok.Size = new System.Drawing.Size(75, 23);
52 this.ok.TabIndex = 1;
53 this.ok.Text = CommonResources.Text.ActionOk;
54 //this.ok.UseVisualStyleBackColor = true;
55 this.ok.Click += new System.EventHandler(this.ok_Click);
56 //
57 // textBox1
58 //
59 this.textBox1.Location = new System.Drawing.Point(13, 13);
60 this.textBox1.Multiline = true;
61 this.textBox1.Name = "textBox1";
62 this.textBox1.ReadOnly = true;
63 //this.textBox1.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
64 this.textBox1.Size = new System.Drawing.Size(256, 77);
65 this.textBox1.TabIndex = 2;
66 //
67 // WarningDialog
68 //
69 this.ClientSize = new System.Drawing.Size(281, 131);
70 this.Controls.Add(this.textBox1);
71 this.Controls.Add(this.ok);
72 this.Name = "WarningDialog";
73 this.StartPosition = System.Windows.Forms.FormStartPosition.WindowsDefaultBounds;
74 this.Text = StringResources.Warning;
75 this.ResumeLayout(false);
76 this.PerformLayout();
77
78 }
79
80 private void ok_Click(object sender, EventArgs e)
81 {
82 Dispose();
83 }
84 }
85 }

Managed by UCC Webmasters ViewVC Help
Powered by ViewVC 1.1.26