Mercurial > pub > ImplabNet
annotate Implab.Fx.Test/OverlayTest.cs @ 148:e6d4b41f0101 v2
fixed timeout handling in promises
author | cin |
---|---|
date | Wed, 15 Apr 2015 07:30:20 +0300 |
parents | 91362ffbecf8 |
children | 037df317f126 |
rev | line source |
---|---|
77 | 1 using System.Windows.Forms; |
2 using Implab.Fx.Test.Sample; | |
3 using Implab.Fx; | |
4 | |
5 #if MONO | |
6 | |
7 using NUnit.Framework; | |
8 using TestClassAttribute = NUnit.Framework.TestFixtureAttribute; | |
9 using TestMethod = NUnit.Framework.TestAttribute; | |
10 | |
11 #else | |
12 | |
5
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
13 using Microsoft.VisualStudio.TestTools.UnitTesting; |
77 | 14 |
15 #endif | |
5
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
16 |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
17 namespace Implab.Fx.Test |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
18 { |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
19 [TestClass] |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
20 public class OverlayTest |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
21 { |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
22 [TestMethod] |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
23 public void TestMethod1() |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
24 { |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
25 var mainForm = new MainForm(); |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
26 |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
27 mainForm.ButtonEvent += (sender, args) => |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
28 { |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
29 var overlay = new OverlayForm(); |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
30 mainForm.OverlayFadeIn(overlay).Then( |
77 | 31 o => o.ButtonEvent += (s2, args2) => o.CloseFadeOut() |
5
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
32 ); |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
33 }; |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
34 |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
35 Application.Run(mainForm); |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
36 } |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
37 } |
f2559580b481
implemented overlay helpers and some animation heplers improvments
cin
parents:
diff
changeset
|
38 } |