[NUI] remove "_" and refactoring naming to pascal case.
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / GLWindow.cs
index 68788c4..c7af260 100755 (executable)
@@ -34,7 +34,7 @@ namespace Tizen.NUI
     [EditorBrowsable(EditorBrowsableState.Never)]
     public partial class GLWindow : BaseHandle
     {
-        internal GLWindow(global::System.IntPtr cPtr, bool cMemoryOwn) : base(Interop.GLWindow.GlWindow_SWIGUpcast(cPtr), cMemoryOwn)
+        internal GLWindow(global::System.IntPtr cPtr, bool cMemoryOwn) : base(Interop.GLWindow.GlWindowUpcast(cPtr), cMemoryOwn)
         {
 
         }
@@ -45,7 +45,7 @@ namespace Tizen.NUI
         /// </summary>
         /// <returns>A new GLWindow.</returns>
         [EditorBrowsable(EditorBrowsableState.Never)]
-        public GLWindow() : this(Interop.GLWindow.GlWindow_New__SWIG_0(), true)
+        public GLWindow() : this(Interop.GLWindow.GlWindowNew(), true)
         {
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
@@ -59,7 +59,7 @@ namespace Tizen.NUI
         /// <param name="isTranslucent">Whether Window is translucent.</param>
         /// <returns>A new Window.</returns>
         [EditorBrowsable(EditorBrowsableState.Never)]
-        public GLWindow(string name, Rectangle windowPosition = null, bool isTranslucent = false) : this(Interop.GLWindow.GlWindow_New__SWIG_1( Rectangle.getCPtr(windowPosition), name, "", isTranslucent), true)
+        public GLWindow(string name, Rectangle windowPosition = null, bool isTranslucent = false) : this(Interop.GLWindow.GlWindowNew(Rectangle.getCPtr(windowPosition), name, "", isTranslucent), true)
         {
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
@@ -106,12 +106,13 @@ namespace Tizen.NUI
         /// <summary>
         /// Gets or sets a size of the window.
         /// </summary>
+        /// <exception cref="ArgumentNullException"> Thrown when value is null. </exception>
         [EditorBrowsable(EditorBrowsableState.Never)]
         public Size2D WindowSize
         {
             get
             {
-                global::System.IntPtr intPtr = Interop.GLWindow.GlWindow_GetPositionSize(swigCPtr);
+                global::System.IntPtr intPtr = Interop.GLWindow.GlWindowGetPositionSize(swigCPtr);
                 var val = new Rectangle(intPtr, true);
                 Size2D ret = new Size2D(val.Width, val.Height);
                 val.Dispose();
@@ -120,12 +121,17 @@ namespace Tizen.NUI
             }
             set
             {
-                global::System.IntPtr intPtr = Interop.GLWindow.GlWindow_GetPositionSize(swigCPtr);
+                if (null == value)
+                {
+                    throw new ArgumentNullException(nameof(value));
+                }
+
+                global::System.IntPtr intPtr = Interop.GLWindow.GlWindowGetPositionSize(swigCPtr);
                 Rectangle val = new Rectangle(intPtr, true);
                 Rectangle ret = new Rectangle(val.X, val.Y, value.Width, value.Height);
                 val.Dispose();
 
-                Interop.GLWindow.GlWindow_SetPositionSize(swigCPtr, Rectangle.getCPtr(ret));
+                Interop.GLWindow.GlWindowSetPositionSize(swigCPtr, Rectangle.getCPtr(ret));
                 ret.Dispose();
             }
         }
@@ -158,9 +164,9 @@ namespace Tizen.NUI
         /// <param name="msaa">The bit of msaa.</param>
         /// <param name="version">The GLES version.</param>
         [EditorBrowsable(EditorBrowsableState.Never)]
-        public void SetEglConfig( bool depth, bool stencil, int msaa, GLESVersion version )
+        public void SetEglConfig(bool depth, bool stencil, int msaa, GLESVersion version)
         {
-            Interop.GLWindow.GlWindow_SetEglConfig(swigCPtr, depth, stencil, msaa, (int)version);
+            Interop.GLWindow.GlWindowSetEglConfig(swigCPtr, depth, stencil, msaa, (int)version);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -170,7 +176,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void Show()
         {
-            Interop.GLWindow.GlWindow_Show(swigCPtr);
+            Interop.GLWindow.GlWindowShow(swigCPtr);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -180,7 +186,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void Hide()
         {
-            Interop.GLWindow.GlWindow_Hide(swigCPtr);
+            Interop.GLWindow.GlWindowHide(swigCPtr);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -190,7 +196,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void Raise()
         {
-            Interop.GLWindow.GlWindow_Raise(swigCPtr);
+            Interop.GLWindow.GlWindowRaise(swigCPtr);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -200,7 +206,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void Lower()
         {
-            Interop.GLWindow.GlWindow_Lower(swigCPtr);
+            Interop.GLWindow.GlWindowLower(swigCPtr);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -210,7 +216,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void Activate()
         {
-            Interop.GLWindow.GlWindow_Activate(swigCPtr);
+            Interop.GLWindow.GlWindowActivate(swigCPtr);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -223,16 +229,16 @@ namespace Tizen.NUI
         {
             get
             {
-                global::System.IntPtr intPtr = Interop.GLWindow.GlWindow_GetPositionSize(swigCPtr);
+                global::System.IntPtr intPtr = Interop.GLWindow.GlWindowGetPositionSize(swigCPtr);
                 Rectangle val = new Rectangle(intPtr, true);
-                Rectangle ret = new Rectangle(val.X, val.Y, val.Width, val.Height );
+                Rectangle ret = new Rectangle(val.X, val.Y, val.Width, val.Height);
                 val.Dispose();
 
                 return ret;
             }
             set
             {
-                Interop.GLWindow.GlWindow_SetPositionSize(swigCPtr, Rectangle.getCPtr(value));
+                Interop.GLWindow.GlWindowSetPositionSize(swigCPtr, Rectangle.getCPtr(value));
             }
         }
 
@@ -243,7 +249,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public uint GetSupportedAuxiliaryHintCount()
         {
-            uint ret = Interop.GLWindow.GlWindow_GetSupportedAuxiliaryHintCount(swigCPtr);
+            uint ret = Interop.GLWindow.GlWindowGetSupportedAuxiliaryHintCount(swigCPtr);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
             return ret;
         }
@@ -256,7 +262,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public string GetSupportedAuxiliaryHint(uint index)
         {
-            string ret = Interop.GLWindow.GlWindow_GetSupportedAuxiliaryHint(swigCPtr, index);
+            string ret = Interop.GLWindow.GlWindowGetSupportedAuxiliaryHint(swigCPtr, index);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
             return ret;
         }
@@ -270,7 +276,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public uint AddAuxiliaryHint(string hint, string value)
         {
-            uint ret = Interop.GLWindow.GlWindow_AddAuxiliaryHint(swigCPtr, hint, value);
+            uint ret = Interop.GLWindow.GlWindowAddAuxiliaryHint(swigCPtr, hint, value);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
             return ret;
         }
@@ -283,7 +289,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public bool RemoveAuxiliaryHint(uint id)
         {
-            bool ret = Interop.GLWindow.GlWindow_RemoveAuxiliaryHint(swigCPtr, id);
+            bool ret = Interop.GLWindow.GlWindowRemoveAuxiliaryHint(swigCPtr, id);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
             return ret;
         }
@@ -297,7 +303,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public bool SetAuxiliaryHintValue(uint id, string value)
         {
-            bool ret = Interop.GLWindow.GlWindow_SetAuxiliaryHintValue(swigCPtr, id, value);
+            bool ret = Interop.GLWindow.GlWindowSetAuxiliaryHintValue(swigCPtr, id, value);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
             return ret;
         }
@@ -310,7 +316,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public string GetAuxiliaryHintValue(uint id)
         {
-            string ret = Interop.GLWindow.GlWindow_GetAuxiliaryHintValue(swigCPtr, id);
+            string ret = Interop.GLWindow.GlWindowGetAuxiliaryHintValue(swigCPtr, id);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
             return ret;
         }
@@ -323,7 +329,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public uint GetAuxiliaryHintId(string hint)
         {
-            uint ret = Interop.GLWindow.GlWindow_GetAuxiliaryHintId(swigCPtr, hint);
+            uint ret = Interop.GLWindow.GlWindowGetAuxiliaryHintId(swigCPtr, hint);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
             return ret;
         }
@@ -335,7 +341,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void SetInputRegion(Rectangle inputRegion)
         {
-            Interop.GLWindow.GlWindow_SetInputRegion(swigCPtr, Rectangle.getCPtr(inputRegion));
+            Interop.GLWindow.GlWindowSetInputRegion(swigCPtr, Rectangle.getCPtr(inputRegion));
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -351,7 +357,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void SetOpaqueState(bool opaque)
         {
-            Interop.GLWindow.GlWindow_SetOpaqueState(swigCPtr, opaque);
+            Interop.GLWindow.GlWindowSetOpaqueState(swigCPtr, opaque);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -363,7 +369,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public bool IsOpaqueState()
         {
-            bool ret = Interop.GLWindow.GlWindow_IsOpaqueState(swigCPtr);
+            bool ret = Interop.GLWindow.GlWindowIsOpaqueState(swigCPtr);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
             return ret;
         }
@@ -375,7 +381,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void SetPreferredOrientation(GLWindow.GLWindowOrientation orientation)
         {
-            Interop.GLWindow.GlWindow_SetPreferredOrientation(swigCPtr, (int)orientation);
+            Interop.GLWindow.GlWindowSetPreferredOrientation(swigCPtr, (int)orientation);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -386,7 +392,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public GLWindow.GLWindowOrientation GetCurrentOrientation()
         {
-            GLWindow.GLWindowOrientation ret = (GLWindow.GLWindowOrientation)Interop.GLWindow.GlWindow_GetCurrentOrientation(swigCPtr);
+            GLWindow.GLWindowOrientation ret = (GLWindow.GLWindowOrientation)Interop.GLWindow.GlWindowGetCurrentOrientation(swigCPtr);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
             return ret;
         }
@@ -396,9 +402,15 @@ namespace Tizen.NUI
         /// This API is for setting several orientations one time.
         /// </summary>
         /// <param name="orientations">The list of orientations.</param>
+        /// <exception cref="ArgumentNullException"> Thrown when orientations is null. </exception>
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void SetAvailableOrientations(List<GLWindow.GLWindowOrientation> orientations)
         {
+            if (null == orientations)
+            {
+                throw new ArgumentNullException(nameof(orientations));
+            }
+
             PropertyArray orientationArray = new PropertyArray();
             for (int i = 0; i < orientations.Count; i++)
             {
@@ -407,7 +419,7 @@ namespace Tizen.NUI
                 val.Dispose();
             }
 
-            Interop.GLWindow.GlWindow_SetAvailableOrientations(swigCPtr, PropertyArray.getCPtr(orientationArray), orientations.Count);
+            Interop.GLWindow.GlWindowSetAvailableOrientations(swigCPtr, PropertyArray.getCPtr(orientationArray), orientations.Count);
             orientationArray.Dispose();
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
@@ -419,7 +431,7 @@ namespace Tizen.NUI
         [EditorBrowsable(EditorBrowsableState.Never)]
         public void RenderOnce()
         {
-            Interop.GLWindow.GlWindow_RenderOnce(swigCPtr);
+            Interop.GLWindow.GlWindowRenderOnce(swigCPtr);
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
@@ -458,7 +470,7 @@ namespace Tizen.NUI
         /// <param name="glRenderFrame">The callback function to render to the frame</param>
         /// <param name="glTerminate">The callback function to clean-up application GL resource</param>
         [EditorBrowsable(EditorBrowsableState.Never)]
-        public void RegisterGlCallback( GLInitializeCallbackType glInit, GLRenderFrameCallbackType glRenderFrame, GLTerminateCallbackType glTerminate )
+        public void RegisterGlCallback(GLInitializeCallbackType glInit, GLRenderFrameCallbackType glRenderFrame, GLTerminateCallbackType glTerminate)
         {
             GLInitializeCallback = glInit;
             InitHandleRef = new HandleRef(this, Marshal.GetFunctionPointerForDelegate<Delegate>(GLInitializeCallback));
@@ -469,7 +481,7 @@ namespace Tizen.NUI
             GLTerminateCallback = glTerminate;
             TerminateHandlerRef = new HandleRef(this, Marshal.GetFunctionPointerForDelegate<Delegate>(GLTerminateCallback));
 
-            Interop.GLWindow.GlWindow_RegisterGlCallback(swigCPtr, InitHandleRef, RenderHandlerRef, TerminateHandlerRef);
+            Interop.GLWindow.GlWindowRegisterGlCallback(swigCPtr, InitHandleRef, RenderHandlerRef, TerminateHandlerRef);
 
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
@@ -501,7 +513,7 @@ namespace Tizen.NUI
         /// This will not be public opened.
         protected override void ReleaseSwigCPtr(System.Runtime.InteropServices.HandleRef swigCPtr)
         {
-            Interop.Window.delete_Window(swigCPtr);
+            Interop.Window.DeleteWindow(swigCPtr);
         }
     }
 }