path: root/reference
diff options
authorXavi Artigas <xavierartigas@yahoo.es>2019-04-17 11:03:21 +0200
committerXavi Artigas <xavierartigas@yahoo.es>2019-04-17 11:03:21 +0200
commitf47f1f3672ec35ec9ce5969572a6d4d6f8563125 (patch)
treee55779fa62e1544828ba8e4bdd8343f38c9d2917 /reference
parentmono-snippets: Add sample property snippet (diff)
mono-example: Remove ugly static_cast
Since https://phab.enlightenment.org/D8550 apps do not need to use static_cast nor Concrete classes.
Diffstat (limited to 'reference')
1 files changed, 4 insertions, 4 deletions
diff --git a/reference/csharp/ui/src/ui_container.cs b/reference/csharp/ui/src/ui_container.cs
index 97c1fc71..0cb9c230 100644
--- a/reference/csharp/ui/src/ui_container.cs
+++ b/reference/csharp/ui/src/ui_container.cs
@@ -79,19 +79,19 @@ public class Example : Efl.Csharp.Application
// Create some boxes and set them as the content of the first pane of the container
var box = CreateBox(win);
- Efl.IContentConcrete.static_cast(vsplit.GetPart("first")).SetContent(box);
+ (vsplit.GetPart("first") as Efl.IContent).SetContent(box);
// Create a second, horizontally-split panes container and set it as the content of
// the second pane of the first container
Efl.Ui.Panes hsplit = new Efl.Ui.Panes(win);
- Efl.IContentConcrete.static_cast(vsplit.GetPart("second")).SetContent(hsplit);
+ (vsplit.GetPart("second") as Efl.IContent).SetContent(hsplit);
// Create a table and set it as the content of the first pane of the horizontal
// container
var table = CreateTable(win);
- Efl.IContentConcrete.static_cast(hsplit.GetPart("first")).SetContent(table);
+ (hsplit.GetPart("first") as Efl.IContent).SetContent(table);
// Create a button and set it as the content of the second pane of the horizontal
// container
@@ -102,7 +102,7 @@ public class Example : Efl.Csharp.Application
// Exit the EFL main loop
- Efl.IContentConcrete.static_cast(hsplit.GetPart("second")).SetContent(quit_btn);
+ (hsplit.GetPart("second") as Efl.IContent).SetContent(quit_btn);
#if WIN32