Mercurial > repos > IBDev-IBBoard.WarFoundry.GUI.GTK
annotate FrmAbout.cs @ 166:ef94bed818e1
* Swap to non-specific versions of GTK libraries to help us build on the server
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Mon, 08 Oct 2012 19:27:56 +0100 |
parents | b4416ca69153 |
children |
rev | line source |
---|---|
77 | 1 // This file (FrmAbout.cs) is a part of the IBBoard.WarFoundry.GUI.GTK project and is copyright 2010 IBBoard |
2 // | |
3 // The file and the library/program it is in are licensed and distributed, without warranty, under the GNU Affero GPL license, either version 3 of the License or (at your option) any later version. Please see COPYING for more information and the full license. | |
4 | |
5 using System; | |
6 using Gtk; | |
80
9c9af2ce8c43
Re #308: Make GTK# UI translatable
IBBoard <dev@ibboard.co.uk>
parents:
77
diff
changeset
|
7 using IBBoard.GtkSharp.Translatable; |
96
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
8 using IBBoard.Lang; |
77 | 9 |
10 namespace IBBoard.WarFoundry.GUI.GTK | |
11 { | |
80
9c9af2ce8c43
Re #308: Make GTK# UI translatable
IBBoard <dev@ibboard.co.uk>
parents:
77
diff
changeset
|
12 public partial class FrmAbout : TranslatableDialog |
77 | 13 { |
14 private static FrmAbout frm; | |
15 | |
16 public static FrmAbout GetForm() | |
17 { | |
18 if (frm == null) | |
19 { | |
20 frm = new FrmAbout(); | |
21 } | |
22 | |
23 return frm; | |
24 } | |
25 | |
26 private FrmAbout() | |
27 { | |
28 this.Build(); | |
96
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
29 Translation.TranslationChanged += Retranslate; |
93
e40d892a2298
Fixes #308: Make GTK# UI translatable
IBBoard <dev@ibboard.co.uk>
parents:
80
diff
changeset
|
30 Translate(); |
77 | 31 } |
32 | |
96
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
33 private void Retranslate() |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
34 { |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
35 Translate(); |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
36 } |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
37 |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
38 public override void Dispose() |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
39 { |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
40 Translation.TranslationChanged -= Retranslate; |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
41 base.Dispose(); |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
42 } |
b4416ca69153
Fixes #309: Add initial preference dialog with language support
IBBoard <dev@ibboard.co.uk>
parents:
94
diff
changeset
|
43 |
93
e40d892a2298
Fixes #308: Make GTK# UI translatable
IBBoard <dev@ibboard.co.uk>
parents:
80
diff
changeset
|
44 protected virtual void CloseClicked(object sender, System.EventArgs e) |
77 | 45 { |
93
e40d892a2298
Fixes #308: Make GTK# UI translatable
IBBoard <dev@ibboard.co.uk>
parents:
80
diff
changeset
|
46 Respond(ResponseType.Close); |
94
26e4525b49cf
Fixes #334: Add credits to "About" page
IBBoard <dev@ibboard.co.uk>
parents:
93
diff
changeset
|
47 } |
26e4525b49cf
Fixes #334: Add credits to "About" page
IBBoard <dev@ibboard.co.uk>
parents:
93
diff
changeset
|
48 |
26e4525b49cf
Fixes #334: Add credits to "About" page
IBBoard <dev@ibboard.co.uk>
parents:
93
diff
changeset
|
49 protected virtual void BttnCreditsClicked(object sender, System.EventArgs e) |
26e4525b49cf
Fixes #334: Add credits to "About" page
IBBoard <dev@ibboard.co.uk>
parents:
93
diff
changeset
|
50 { |
26e4525b49cf
Fixes #334: Add credits to "About" page
IBBoard <dev@ibboard.co.uk>
parents:
93
diff
changeset
|
51 FrmAboutCredits credits = new FrmAboutCredits(); |
26e4525b49cf
Fixes #334: Add credits to "About" page
IBBoard <dev@ibboard.co.uk>
parents:
93
diff
changeset
|
52 credits.Run(); |
26e4525b49cf
Fixes #334: Add credits to "About" page
IBBoard <dev@ibboard.co.uk>
parents:
93
diff
changeset
|
53 credits.Hide(); |
26e4525b49cf
Fixes #334: Add credits to "About" page
IBBoard <dev@ibboard.co.uk>
parents:
93
diff
changeset
|
54 } |
77 | 55 } |
56 } | |
57 |