summaryrefslogtreecommitdiff
path: root/ElmSharp.Test
diff options
context:
space:
mode:
Diffstat (limited to 'ElmSharp.Test')
-rw-r--r--ElmSharp.Test/TC/PopupTest1.cs7
-rw-r--r--ElmSharp.Test/TestRunner.cs27
2 files changed, 17 insertions, 17 deletions
diff --git a/ElmSharp.Test/TC/PopupTest1.cs b/ElmSharp.Test/TC/PopupTest1.cs
index c3e0a5d..90eda9c 100644
--- a/ElmSharp.Test/TC/PopupTest1.cs
+++ b/ElmSharp.Test/TC/PopupTest1.cs
@@ -62,13 +62,18 @@ namespace ElmSharp.Test
popup.TimedOut += (s, e) =>
{
Console.WriteLine("Popup time out");
- popup.Show();
};
popup.Append("Label1");
popup.Append("Label2");
popup.Append("Label3");
+ popup.BackButtonPressed += (s, e) =>
+ {
+ Console.WriteLine("!!! BackButtonPressed Event on Popup!!");
+ popup.Hide();
+ };
+
btn.Clicked += (s, e) =>
{
popup.Show();
diff --git a/ElmSharp.Test/TestRunner.cs b/ElmSharp.Test/TestRunner.cs
index ebdab32..3ee156b 100644
--- a/ElmSharp.Test/TestRunner.cs
+++ b/ElmSharp.Test/TestRunner.cs
@@ -107,27 +107,19 @@ namespace ElmSharp.Test
window.Show();
if (isSecond)
{
- window.KeyGrab(EvasKeyEventArgs.PlatformBackButtonName, true);
- window.KeyUp += (s, e) =>
+ window.BackButtonPressed += (s, e) =>
{
- if (e.KeyName == EvasKeyEventArgs.PlatformBackButtonName)
- {
- window.Hide();
- window.Unrealize();
- GC.Collect();
- GC.WaitForPendingFinalizers();
- }
+ window.Hide();
+ window.Unrealize();
+ GC.Collect();
+ GC.WaitForPendingFinalizers();
};
}
else
{
- window.KeyGrab(EvasKeyEventArgs.PlatformBackButtonName, false);
- window.KeyUp += (s, e) =>
+ window.BackButtonPressed += (s, e) =>
{
- if (e.KeyName == EvasKeyEventArgs.PlatformBackButtonName)
- {
- UIExit();
- }
+ UIExit();
};
}
return window;
@@ -147,7 +139,10 @@ namespace ElmSharp.Test
WeightY = 1,
};
box.Show();
- conformant.SetContent(box);
+ var bg = new Background(_firstPageWindow);
+ bg.Color = Color.White;
+ bg.SetContent(box);
+ conformant.SetContent(bg);
GenList list = new GenList(_firstPageWindow)
{