[global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_Window_GetLastTouchEvent")]
public static extern global::System.IntPtr GetLastTouchEvent(global::System.Runtime.InteropServices.HandleRef window);
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_Window_InternalRetrievingLastKeyEvent")]
+ public static extern void InternalRetrievingLastKeyEvent(global::System.Runtime.InteropServices.HandleRef window, global::System.Runtime.InteropServices.HandleRef key);
+
+ [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_Window_InternalRetrievingLastTouchEvent")]
+ public static extern void InternalRetrievingLastTouchEvent(global::System.Runtime.InteropServices.HandleRef window, global::System.Runtime.InteropServices.HandleRef touch);
+
[global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_Window_SetNeedsRotationCompletedAcknowledgement")]
public static extern void SetNeedsRotationCompletedAcknowledgement(global::System.Runtime.InteropServices.HandleRef window, bool needAcknowledgement);
private string windowTitle;
private List<Layer> childLayers = new List<Layer>();
private LayoutController localController;
+ private Key internalLastKeyEvent;
+ private Touch internalLastTouchEvent;
static internal bool IsSupportedMultiWindow()
{
[EditorBrowsable(EditorBrowsableState.Never)]
public Key GetLastKeyEvent()
{
- Key ret = new Key(Interop.Window.GetLastKeyEvent(SwigCPtr), false);
+ if(internalLastKeyEvent == null)
+ {
+ internalLastKeyEvent = new Key();
+ }
+ Interop.Window.InternalRetrievingLastKeyEvent(SwigCPtr, internalLastKeyEvent.SwigCPtr);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
+ return internalLastKeyEvent;
}
/// <summary>
[EditorBrowsable(EditorBrowsableState.Never)]
public Touch GetLastTouchEvent()
{
- Touch ret = new Touch(Interop.Window.GetLastTouchEvent(SwigCPtr), false);
+ if(internalLastTouchEvent == null)
+ {
+ internalLastTouchEvent = new Touch();
+ }
+ Interop.Window.InternalRetrievingLastTouchEvent(SwigCPtr, internalLastTouchEvent.SwigCPtr);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
+ return internalLastTouchEvent;
}
/// <summary>
childLayers.Clear();
localController?.Dispose();
+
+ internalLastKeyEvent?.Dispose();
+ internalLastKeyEvent = null;
+ internalLastTouchEvent?.Dispose();
+ internalLastTouchEvent = null;
}