summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeonghyun Yun <jh0506.yun@samsung.com>2017-04-12 18:10:45 -0700
committerGerrit Code Review <gerrit@review.vlan103.tizen.org>2017-04-12 18:10:45 -0700
commit35334fc5b010cc8d0f4bf68268a233e1b9f87f4f (patch)
tree913584bc61ef6488e03f29c6a0eb6f7d3b28a0bd
parent2c4b3eb6b9742c3e129ae431058539219e2cfc7e (diff)
parent8418aafa1ed86beb4ae1195d58650fdca872feaf (diff)
downloadelm-sharp-35334fc5b010cc8d0f4bf68268a233e1b9f87f4f.tar.gz
elm-sharp-35334fc5b010cc8d0f4bf68268a233e1b9f87f4f.tar.bz2
elm-sharp-35334fc5b010cc8d0f4bf68268a233e1b9f87f4f.zip
Merge "Add API to show/hide the indicator" into tizen
-rwxr-xr-xElmSharp/ElmSharp/Window.cs37
-rw-r--r--ElmSharp/Interop/Interop.Elementary.Win.cs4
-rw-r--r--packaging/elm-sharp.spec2
3 files changed, 39 insertions, 4 deletions
diff --git a/ElmSharp/ElmSharp/Window.cs b/ElmSharp/ElmSharp/Window.cs
index 52391de..5025e4b 100755
--- a/ElmSharp/ElmSharp/Window.cs
+++ b/ElmSharp/ElmSharp/Window.cs
@@ -78,6 +78,25 @@ namespace ElmSharp
}
/// <summary>
+ /// Indicator mode.
+ /// </summary>
+ public enum IndicatorMode
+ {
+ /// <summary>
+ /// Unknown indicator state.
+ /// </summary>
+ Unknown = 0,
+ /// <summary>
+ /// Hides the indicator.
+ /// </summary>
+ Hide,
+ /// <summary>
+ /// Shows the indicator.
+ /// </summary>
+ Show,
+ };
+
+ /// <summary>
/// The Window is container that contain the graphical user interface of a program.
/// </summary>
public class Window : Widget
@@ -112,7 +131,7 @@ namespace ElmSharp
{
Name = name;
Realize(parent);
- Interop.Elementary.elm_win_indicator_mode_set(Handle, 2 /* ELM_WIN_INDICATOR_SHOW */);
+ IndicatorMode = IndicatorMode.Show;
_deleteRequest = new SmartEvent(this, "delete,request");
_rotationChanged = new SmartEvent(this, "wm,rotation,changed");
@@ -297,6 +316,22 @@ namespace ElmSharp
}
/// <summary>
+ /// Gets or sets the window's indicator mode.
+ /// </summary>
+ /// <value>The indicator mode.</value>
+ public IndicatorMode IndicatorMode
+ {
+ get
+ {
+ return Interop.Elementary.elm_win_indicator_mode_get(RealHandle);
+ }
+ set
+ {
+ Interop.Elementary.elm_win_indicator_mode_set(RealHandle, value);
+ }
+ }
+
+ /// <summary>
/// This function sends a request to the Windows Manager to activate the Window.
/// If honored by the WM, the window receives the keyboard focus.
/// </summary>
diff --git a/ElmSharp/Interop/Interop.Elementary.Win.cs b/ElmSharp/Interop/Interop.Elementary.Win.cs
index 30871f0..6a8ac80 100644
--- a/ElmSharp/Interop/Interop.Elementary.Win.cs
+++ b/ElmSharp/Interop/Interop.Elementary.Win.cs
@@ -83,10 +83,10 @@ internal static partial class Interop
internal static extern int elm_win_indicator_opacity_get(IntPtr obj);
[DllImport(Libraries.Elementary)]
- internal static extern void elm_win_indicator_mode_set(IntPtr obj, int mode);
+ internal static extern void elm_win_indicator_mode_set(IntPtr obj, IndicatorMode mode);
[DllImport(Libraries.Elementary)]
- internal static extern int elm_win_indicator_mode_get(IntPtr obj);
+ internal static extern IndicatorMode elm_win_indicator_mode_get(IntPtr obj);
[DllImport(Libraries.Elementary)]
internal static extern void elm_win_conformant_set(IntPtr obj, bool conformant);
diff --git a/packaging/elm-sharp.spec b/packaging/elm-sharp.spec
index 5a8658a..17f1e13 100644
--- a/packaging/elm-sharp.spec
+++ b/packaging/elm-sharp.spec
@@ -1,4 +1,4 @@
-%define DEV_VERSION beta-019
+%define DEV_VERSION beta-020
Name: elm-sharp
Summary: C# Binding for Elementary