{
Vector2 temp = new Vector2(0.0f, 0.0f);
GetProperty(View.Property.SCREEN_POSITION).Get(temp);
- // Dali's default layer is default center origin. need to change as top left.
- // NUI's Layer is like a transparent film which covers entire window. (Layer is not an actor of Dali)
- // otherwise, this makes ScreenPosition as wrong value.
- temp -= (Window.Instance.GetSize() * 0.5f);
return temp;
}
}
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
if(Window.Instance != null)
{
- this.SetParentOrigin(Tizen.NUI.ParentOrigin.TopLeft);
this.SetAnchorPoint(Tizen.NUI.PivotPoint.TopLeft);
this.SetResizePolicy(ResizePolicyType.FillToParent, DimensionType.AllDimensions);
}
throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- internal void SetParentOrigin(Vector3 origin)
- {
- NDalicPINVOKE.Actor_SetParentOrigin(swigCPtr, Vector3.getCPtr(origin));
- if (NDalicPINVOKE.SWIGPendingException.Pending)
- throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
/// <summary>
/// Downcasts a handle to layer handle.
/// </summary>
protected override void OnCreate()
{
base.OnCreate();
-
- // Dali's default layer is default center origin. need to change as top left.
- // NUI's Layer is like a transparent film which covers entire window. (Layer is not an actor of Dali)
- // otherwise, this makes ScreenPosition as wrong value.
- Layer defaultLayer = Window.GetDefaultLayer();
- defaultLayer.SetParentOrigin(Tizen.NUI.ParentOrigin.TopLeft);
- defaultLayer.SetAnchorPoint(Tizen.NUI.PivotPoint.TopLeft);
}
/// <summary>