summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLauro Moura <lauromoura@expertisesolutions.com.br>2019-03-22 09:13:15 +0100
committerXavi Artigas <xavierartigas@yahoo.es>2019-03-22 09:14:27 +0100
commit735b848660480e964664c601e4f6077cd606ab59 (patch)
treefd6072a64351bcf9894aaaa5d163a0bb538ac09b
parent82dd23ba0210f4d546f82b3f1099997595161800 (diff)
csharp: Changes after adding I to interfaces
Summary: Ref T7751 Depends on D8397 in the EFL repo Reviewers: segfaultxavi, vitor.sousa, felipealmeida Reviewed By: segfaultxavi Tags: #efl_language_bindings Maniphest Tasks: T7751 Differential Revision: https://phab.enlightenment.org/D8398
-rw-r--r--apps/csharp/life/src/life_main.cs14
-rw-r--r--apps/csharp/texteditor/src/texteditor_main.cs2
-rw-r--r--reference/csharp/ui/src/focus_main.cs4
-rw-r--r--reference/csharp/ui/src/ui_container.cs10
-rw-r--r--reference/csharp/ui/src/ui_sizing.cs2
-rw-r--r--tutorial/csharp/hello-gui/src/gui_main.cs2
6 files changed, 17 insertions, 17 deletions
diff --git a/apps/csharp/life/src/life_main.cs b/apps/csharp/life/src/life_main.cs
index a7c6777..3de8d68 100644
--- a/apps/csharp/life/src/life_main.cs
+++ b/apps/csharp/life/src/life_main.cs
@@ -10,14 +10,14 @@ public class LifeWindow
10 lifeRender.RenderLayout((Efl.Ui.Win)sender); 10 lifeRender.RenderLayout((Efl.Ui.Win)sender);
11 } 11 }
12 12
13 void QuitEvt(object sender, Efl.Gfx.EntityVisibilityChangedEvt_Args ev) 13 void QuitEvt(object sender, Efl.Gfx.IEntityVisibilityChangedEvt_Args ev)
14 { 14 {
15 // quit the mainloop 15 // quit the mainloop
16 if (ev.arg == false) 16 if (ev.arg == false)
17 Efl.Ui.Config.Exit(); 17 Efl.Ui.Config.Exit();
18 } 18 }
19 19
20 void TouchEvt(object sender, Efl.Input.InterfacePointerDownEvt_Args ev) 20 void TouchEvt(object sender, Efl.Input.IInterfacePointerDownEvt_Args ev)
21 { 21 {
22 int cellx, celly; 22 int cellx, celly;
23 Efl.Ui.Win win = (Efl.Ui.Win)sender; 23 Efl.Ui.Win win = (Efl.Ui.Win)sender;
@@ -29,7 +29,7 @@ public class LifeWindow
29 lifeRender.RenderCell(win, cellx, celly); 29 lifeRender.RenderCell(win, cellx, celly);
30 } 30 }
31 31
32 void KeyDownEvt(object sender, Efl.Input.InterfaceKeyDownEvt_Args ev) 32 void KeyDownEvt(object sender, Efl.Input.IInterfaceKeyDownEvt_Args ev)
33 { 33 {
34 Efl.Ui.Win win = (Efl.Ui.Win)sender; 34 Efl.Ui.Win win = (Efl.Ui.Win)sender;
35 if (ev.arg.GetKey() == "space") 35 if (ev.arg.GetKey() == "space")
@@ -43,7 +43,7 @@ public class LifeWindow
43 win.SetAutohide(true); 43 win.SetAutohide(true);
44 44
45 // when the user clicks "close" on a window there is a request to hide 45 // when the user clicks "close" on a window there is a request to hide
46 ((Efl.Gfx.Entity)win).VisibilityChangedEvt += QuitEvt; 46 ((Efl.Gfx.IEntity)win).VisibilityChangedEvt += QuitEvt;
47 47
48 Eina.Size2D sz; 48 Eina.Size2D sz;
49 sz.W = (int)(10 * LifeBoard.Width * win.GetScale()); 49 sz.W = (int)(10 * LifeBoard.Width * win.GetScale());
@@ -53,9 +53,9 @@ public class LifeWindow
53 lifeRender = new LifeRender(win, lifeBoard); 53 lifeRender = new LifeRender(win, lifeBoard);
54 lifeRender.Refresh(win); 54 lifeRender.Refresh(win);
55 55
56 ((Efl.Gfx.Entity)win).SizeChangedEvt += ResizeEvt; 56 ((Efl.Gfx.IEntity)win).SizeChangedEvt += ResizeEvt;
57 ((Efl.Input.Interface)win).PointerDownEvt += TouchEvt; 57 ((Efl.Input.IInterface)win).PointerDownEvt += TouchEvt;
58 ((Efl.Input.Interface)win).KeyDownEvt += KeyDownEvt; 58 ((Efl.Input.IInterface)win).KeyDownEvt += KeyDownEvt;
59 59
60 win.SetSize(sz); 60 win.SetSize(sz);
61 61
diff --git a/apps/csharp/texteditor/src/texteditor_main.cs b/apps/csharp/texteditor/src/texteditor_main.cs
index f697245..e0591f1 100644
--- a/apps/csharp/texteditor/src/texteditor_main.cs
+++ b/apps/csharp/texteditor/src/texteditor_main.cs
@@ -32,7 +32,7 @@ public class TextEditor
32 "texteditor_example.txt"); 32 "texteditor_example.txt");
33 33
34 // Quits the application 34 // Quits the application
35 private void GUIQuitCb(object sender, Efl.Gfx.EntityVisibilityChangedEvt_Args ea) 35 private void GUIQuitCb(object sender, Efl.Gfx.IEntityVisibilityChangedEvt_Args ea)
36 { 36 {
37 if (ea.arg == false) 37 if (ea.arg == false)
38 Efl.Ui.Config.Exit(); 38 Efl.Ui.Config.Exit();
diff --git a/reference/csharp/ui/src/focus_main.cs b/reference/csharp/ui/src/focus_main.cs
index a8d2615..d5948bd 100644
--- a/reference/csharp/ui/src/focus_main.cs
+++ b/reference/csharp/ui/src/focus_main.cs
@@ -4,7 +4,7 @@ public class Example
4{ 4{
5 public static void FocusChangedCb(object sender, EventArgs e) 5 public static void FocusChangedCb(object sender, EventArgs e)
6 { 6 {
7 Console.WriteLine($"Focus for object {((Efl.Text)sender).GetText()} changed to {((Efl.Ui.Widget)sender).GetFocus()}"); 7 Console.WriteLine($"Focus for object {((Efl.IText)sender).GetText()} changed to {((Efl.Ui.Widget)sender).GetFocus()}");
8 } 8 }
9 9
10#if WIN32 10#if WIN32
@@ -20,7 +20,7 @@ public class Example
20 win.SetWinType(Efl.Ui.WinType.Basic); 20 win.SetWinType(Efl.Ui.WinType.Basic);
21 win.SetText("Focus example"); 21 win.SetText("Focus example");
22 win.SetAutohide(true); 22 win.SetAutohide(true);
23 win.VisibilityChangedEvt += (object sender, Efl.Gfx.EntityVisibilityChangedEvt_Args e) => { 23 win.VisibilityChangedEvt += (object sender, Efl.Gfx.IEntityVisibilityChangedEvt_Args e) => {
24 // Exit the EFL main loop 24 // Exit the EFL main loop
25 if (e.arg == false) 25 if (e.arg == false)
26 Efl.Ui.Config.Exit(); 26 Efl.Ui.Config.Exit();
diff --git a/reference/csharp/ui/src/ui_container.cs b/reference/csharp/ui/src/ui_container.cs
index 8b611f1..fd1bdf1 100644
--- a/reference/csharp/ui/src/ui_container.cs
+++ b/reference/csharp/ui/src/ui_container.cs
@@ -70,7 +70,7 @@ public class Example
70 win.SetWinType(Efl.Ui.WinType.Basic); 70 win.SetWinType(Efl.Ui.WinType.Basic);
71 win.SetText("Container demo"); 71 win.SetText("Container demo");
72 win.SetAutohide(true); 72 win.SetAutohide(true);
73 win.VisibilityChangedEvt += (object sender, Efl.Gfx.EntityVisibilityChangedEvt_Args e) => { 73 win.VisibilityChangedEvt += (object sender, Efl.Gfx.IEntityVisibilityChangedEvt_Args e) => {
74 // Exit the EFL main loop 74 // Exit the EFL main loop
75 if (e.arg == false) 75 if (e.arg == false)
76 Efl.Ui.Config.Exit(); 76 Efl.Ui.Config.Exit();
@@ -86,19 +86,19 @@ public class Example
86 86
87 // Create some boxes and set them as the content of the first pane of the container 87 // Create some boxes and set them as the content of the first pane of the container
88 var box = CreateBox(win); 88 var box = CreateBox(win);
89 Efl.ContentConcrete.static_cast(vsplit.GetPart("first")).SetContent(box); 89 Efl.IContentConcrete.static_cast(vsplit.GetPart("first")).SetContent(box);
90 90
91 // Create a second, horizontally-split panes container and set it as the content of 91 // Create a second, horizontally-split panes container and set it as the content of
92 // the second pane of the first container 92 // the second pane of the first container
93 Efl.Ui.Panes hsplit = new Efl.Ui.Panes(win); 93 Efl.Ui.Panes hsplit = new Efl.Ui.Panes(win);
94 hsplit.SetDirection(Efl.Ui.Dir.Horizontal); 94 hsplit.SetDirection(Efl.Ui.Dir.Horizontal);
95 hsplit.SetSplitRatio(0.85); 95 hsplit.SetSplitRatio(0.85);
96 Efl.ContentConcrete.static_cast(vsplit.GetPart("second")).SetContent(hsplit); 96 Efl.IContentConcrete.static_cast(vsplit.GetPart("second")).SetContent(hsplit);
97 97
98 // Create a table and set it as the content of the first pane of the horizontal 98 // Create a table and set it as the content of the first pane of the horizontal
99 // container 99 // container
100 var table = CreateTable(win); 100 var table = CreateTable(win);
101 Efl.ContentConcrete.static_cast(hsplit.GetPart("first")).SetContent(table); 101 Efl.IContentConcrete.static_cast(hsplit.GetPart("first")).SetContent(table);
102 102
103 // Create a button and set it as the content of the second pane of the horizontal 103 // Create a button and set it as the content of the second pane of the horizontal
104 // container 104 // container
@@ -109,7 +109,7 @@ public class Example
109 // Exit the EFL main loop 109 // Exit the EFL main loop
110 Efl.Ui.Config.Exit(); 110 Efl.Ui.Config.Exit();
111 }; 111 };
112 Efl.ContentConcrete.static_cast(hsplit.GetPart("second")).SetContent(quit_btn); 112 Efl.IContentConcrete.static_cast(hsplit.GetPart("second")).SetContent(quit_btn);
113 113
114 // Start the EFL main loop 114 // Start the EFL main loop
115 Efl.Ui.Config.Run(); 115 Efl.Ui.Config.Run();
diff --git a/reference/csharp/ui/src/ui_sizing.cs b/reference/csharp/ui/src/ui_sizing.cs
index c8cdf90..f84fc4b 100644
--- a/reference/csharp/ui/src/ui_sizing.cs
+++ b/reference/csharp/ui/src/ui_sizing.cs
@@ -23,7 +23,7 @@ public class Example
23 win.SetWinType(Efl.Ui.WinType.Basic); 23 win.SetWinType(Efl.Ui.WinType.Basic);
24 win.SetText("Size Control"); 24 win.SetText("Size Control");
25 win.SetAutohide(true); 25 win.SetAutohide(true);
26 win.VisibilityChangedEvt += (object sender, Efl.Gfx.EntityVisibilityChangedEvt_Args e) => { 26 win.VisibilityChangedEvt += (object sender, Efl.Gfx.IEntityVisibilityChangedEvt_Args e) => {
27 // Exit the EFL main loop 27 // Exit the EFL main loop
28 if (e.arg == false) 28 if (e.arg == false)
29 Efl.Ui.Config.Exit(); 29 Efl.Ui.Config.Exit();
diff --git a/tutorial/csharp/hello-gui/src/gui_main.cs b/tutorial/csharp/hello-gui/src/gui_main.cs
index f27b8ac..28ce619 100644
--- a/tutorial/csharp/hello-gui/src/gui_main.cs
+++ b/tutorial/csharp/hello-gui/src/gui_main.cs
@@ -3,7 +3,7 @@ using System;
3public class Example 3public class Example
4{ 4{
5 // Callback to quit the application 5 // Callback to quit the application
6 public static void QuitCb(object sender, Efl.Gfx.EntityVisibilityChangedEvt_Args e) 6 public static void QuitCb(object sender, Efl.Gfx.IEntityVisibilityChangedEvt_Args e)
7 { 7 {
8 // Exit the EFL main loop 8 // Exit the EFL main loop
9 if (e.arg == false) 9 if (e.arg == false)