summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDonghee Ye <donghee.ye@samsung.com>2017-03-06 10:32:11 +0900
committerDonghee Ye <donghee.ye@samsung.com>2017-03-06 20:14:10 +0900
commit357772bfbd8179d2a73eb6d967b621a66f25d389 (patch)
tree36a8a0b29587af71a27b7d6cfeb8bf91126165cc
parentf7a48259f341b5928699ee7422b39c04b4d2c9c8 (diff)
downloadelm-sharp-357772bfbd8179d2a73eb6d967b621a66f25d389.tar.gz
elm-sharp-357772bfbd8179d2a73eb6d967b621a66f25d389.tar.bz2
elm-sharp-357772bfbd8179d2a73eb6d967b621a66f25d389.zip
Add Window Role property
Change-Id: I0645dc99b2d1424446202f8165011a7d1dbabdd8
-rw-r--r--ElmSharp/ElmSharp/Window.cs12
-rw-r--r--ElmSharp/Interop/Interop.Elementary.Win.cs12
-rw-r--r--packaging/elm-sharp.spec2
3 files changed, 25 insertions, 1 deletions
diff --git a/ElmSharp/ElmSharp/Window.cs b/ElmSharp/ElmSharp/Window.cs
index 0bb0df7..be5a376 100644
--- a/ElmSharp/ElmSharp/Window.cs
+++ b/ElmSharp/ElmSharp/Window.cs
@@ -161,6 +161,18 @@ namespace ElmSharp
}
}
+ public string Role
+ {
+ get
+ {
+ return Interop.Elementary.elm_win_role_get(Handle);
+ }
+ set
+ {
+ Interop.Elementary.elm_win_role_set(Handle, value);
+ }
+ }
+
public StatusBarMode StatusBarMode
{
get
diff --git a/ElmSharp/Interop/Interop.Elementary.Win.cs b/ElmSharp/Interop/Interop.Elementary.Win.cs
index 345e918..89af78e 100644
--- a/ElmSharp/Interop/Interop.Elementary.Win.cs
+++ b/ElmSharp/Interop/Interop.Elementary.Win.cs
@@ -58,6 +58,18 @@ internal static partial class Interop
internal static extern void elm_win_alpha_set(IntPtr obj, bool alpha);
[DllImport(Libraries.Elementary)]
+ internal static extern IntPtr _elm_win_role_get(IntPtr obj);
+
+ internal static string elm_win_role_get(IntPtr obj)
+ {
+ var text = _elm_win_role_get(obj);
+ return Marshal.PtrToStringAnsi(text);
+ }
+
+ [DllImport(Libraries.Elementary)]
+ internal static extern void elm_win_role_set(IntPtr obj, string role);
+
+ [DllImport(Libraries.Elementary)]
internal static extern void elm_win_autodel_set(IntPtr obj, bool autodel);
[DllImport(Libraries.Elementary)]
diff --git a/packaging/elm-sharp.spec b/packaging/elm-sharp.spec
index 2adb00e..f84fa0b 100644
--- a/packaging/elm-sharp.spec
+++ b/packaging/elm-sharp.spec
@@ -1,4 +1,4 @@
-%define DEV_VERSION beta-011
+%define DEV_VERSION beta-012
Name: elm-sharp
Summary: C# Binding for Elementary