annotate Implab.Fx.Test/OverlayTest.cs @ 211:3eb3255d8cc5 v2

Code review, added a non generic version of SyncContextPromise
author cin
date Tue, 21 Mar 2017 17:29:13 +0300
parents 037df317f126
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
77
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
1 using System.Windows.Forms;
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
2 using Implab.Fx.Test.Sample;
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
3 using Implab.Fx;
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
4
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
5 #if MONO
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
6
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
7 using NUnit.Framework;
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
8 using TestClassAttribute = NUnit.Framework.TestFixtureAttribute;
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
9 using TestMethod = NUnit.Framework.TestAttribute;
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
10
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
11 #else
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
12
5
f2559580b481 implemented overlay helpers and some animation heplers improvments
cin
parents:
diff changeset
13 using Microsoft.VisualStudio.TestTools.UnitTesting;
77
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
14
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
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();
155
037df317f126 minor fixes for vs2012
cin
parents: 77
diff changeset
30 mainForm.OverlayFadeIn(overlay).On(
77
91362ffbecf8 ported tests to mono
cin
parents: 5
diff changeset
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 }