private Dali.Application _application;
private TableView _contentContainer;
private Timer _timer;
- private Stage _stage;
+ private Window _window;
private Popup _popup;
private ProgressBar _progressBar;
public void OnInitialize(object source, NUIApplicationInitEventArgs e)
{
Console.WriteLine("Customized Application Initialize event handler");
- _stage = Stage.GetCurrent();
- _stage.BackgroundColor = Color.White;
+ _window = Window.Instance;
+ _window.BackgroundColor = Color.White;
// Top label
TextLabel topLabel = new TextLabel();
topLabel.HorizontalAlignment = "BEGIN";
topLabel.VerticalAlignment = "CENTER";
topLabel.PointSize = 42.0f;
- _stage.Add(topLabel);
+ _window.Add(topLabel);
// Grid container to contain items. Use tableView because FlexContainer support focus navigation just two direction ( up/down or left/right )
_contentContainer = new TableView(6, 5);
_contentContainer.SetResizePolicy(ResizePolicyType.SIZE_RELATIVE_TO_PARENT, DimensionType.HEIGHT);
_contentContainer.SetSizeModeFactor(new Vector3(0.0f, 0.9f, 0.0f));
_contentContainer.AnchorPoint = NDalic.AnchorPointBottomCenter;
- _contentContainer.Position = new Position(0, _stage.Size.Height * 0.1f, 0);
+ _contentContainer.Position = new Position(0, _window.Size.Height * 0.1f, 0);
_contentContainer.SetRelativeHeight(0, 0.07f);
_contentContainer.SetRelativeHeight(1, 0.26f);
_contentContainer.SetRelativeHeight(2, 0.07f);
_contentContainer.SetRelativeHeight(4, 0.07f);
_contentContainer.SetRelativeHeight(5, 0.26f);
_contentContainer.SetKeyboardFocusable(true);
- _stage.Add(_contentContainer);
+ _window.Add(_contentContainer);
CreateContent();
{
// Make label for item
TextLabel itemLabel = new TextLabel(" " + item.name);
- itemLabel.Size = new Vector3(_stage.GetSize().Width * 0.2f, _stage.GetSize().Height * 0.05f, 0.0f);
+ itemLabel.Size = new Vector3(_window.GetSize().Width * 0.2f, _window.GetSize().Height * 0.05f, 0.0f);
itemLabel.HorizontalAlignment = "BEGIN";
itemLabel.VerticalAlignment = "BOTTOM";
itemLabel.PointSize = 18.0f;
_contentContainer.AddChild(itemLabel, new TableView.CellPosition(((uint)idx / 5) * 2, (uint)idx % 5));
- // If item is implemented in public, attach it on stage
+ // If item is implemented in public, attach it on window
if (item.isImplemented)
{
if (item.name.CompareTo("PushButton") == 0)
button.Clicked += (obj, ee) =>
{
- _stage.Add(_popup);
+ _window.Add(_popup);
_popup.SetDisplayState(Popup.DisplayStateType.SHOWN);
FocusManager.Instance.SetCurrentFocusView((_popup.FindChildByName("Footer")).FindChildByName("OKButton"));
return true;
text.MultiLine = true;
text.HorizontalAlignment = "center";
toast.SetTitle(text);
- _stage.Add(toast);
+ _window.Add(toast);
toast.SetDisplayState(Popup.DisplayStateType.SHOWN);
}
}
else
{
ImageView notSupportView = new ImageView("images/not_yet_sign.png");
- notSupportView.Size = new Vector3(_stage.GetSize().Width * 0.2f, _stage.GetSize().Height * 0.25f, 0.0f);
+ notSupportView.Size = new Vector3(_window.GetSize().Width * 0.2f, _window.GetSize().Height * 0.25f, 0.0f);
notSupportView.SetKeyboardFocusable(true);
_contentContainer.AddChild(notSupportView, new TableView.CellPosition(((uint)idx / 5) * 2 + 1, (uint)idx % 5));
private Dali.Application _application;
private Animation _animation;
private TextLabel _text;
- private Stage _stage;
+ private Window _window;
public Example(Dali.Application application)
{
public void Initialize(object source, NUIApplicationInitEventArgs e)
{
Console.WriteLine("Customized Application Initialize event handler");
- _stage = Stage.Instance;
- _stage.BackgroundColor = Color.White;
- _stage.Touch += OnStageTouched;
+ _window = Window.Instance;
+ _window.BackgroundColor = Color.White;
+ _window.Touch += OnWindowTouched;
// Add a _text label to the stage
_text = new TextLabel("Hello Mono World");
_text.HorizontalAlignment = "CENTER";
_text.PointSize = 32.0f;
_text.TextColor = Color.Magenta;
- _stage.Add(_text);
+ _window.Add(_text);
_animation = new Animation
{
}
}
- // Callback for stage touched signal handling
- public void OnStageTouched(object sender, Stage.TouchEventArgs e)
+ // Callback for window touched signal handling
+ public void OnWindowTouched(object sender, Window.TouchEventArgs e)
{
// Only animate the _text label when touch down happens
if (e.Touch.GetState(0) == PointStateType.DOWN)
private bool _isAniFinised = true;
private Layer layer, _layer1, _layer2;
private PushButton _pushButton1, _pushButton2;
- private Stage stage;
+ private Window window;
public Example(Dali.Application application)
{
public void Initialize(object source, NUIApplicationInitEventArgs e)
{
Log("Customized Application Initialize event handler");
- stage = Stage.Instance;
- stage.BackgroundColor = Color.Cyan;
- stage.Touch += OnStageTouched;
- stage.Wheel += OnStageWheelMoved;
- stage.Key += OnStageKeyPressed;
- //stage.EventProcessingFinished += OnStageEventProcessingFinished;
-
- layer = stage.GetDefaultLayer();
+ window = Window.Instance;
+ window.BackgroundColor = Color.Cyan;
+ window.Touch += OnWindowTouched;
+ window.Wheel += OnWindowWheelMoved;
+ window.Key += OnWindowKeyPressed;
+ //window.EventProcessingFinished += OnWindowEventProcessingFinished;
+
+ layer = window.GetDefaultLayer();
_layer1 = new Layer();
_layer2 = new Layer();
- stage.AddLayer(_layer1);
- stage.AddLayer(_layer2);
+ window.Add(_layer1);
+ window.Add(_layer2);
Log("_layer1.Behavior =" + _layer1.Behavior);
if (_layer1.Behavior == Layer.LayerBehavior.LAYER_UI)
{
_layer1.Behavior = Layer.LayerBehavior.LAYER_2D;
Log("again _layer1.Behavior =" + _layer1.Behavior);
}
- // Add a ImageView to the stage
+ // Add a ImageView to the window
_imageView = new ImageView();
_imageView.ResourceUrl = "./images/gallery-3.jpg";
_imageView.ParentOrigin = ParentOrigin.Center;
_pushButton1.ParentOrigin = ParentOrigin.BottomLeft;
_pushButton1.AnchorPoint = AnchorPoint.BottomLeft;
_pushButton1.LabelText = "start animation";
- _pushButton1.Position = new Vector3(0.0f, stage.Size.Height * 0.1f, 0.0f);
+ _pushButton1.Position = new Vector3(0.0f, window.Size.Height * 0.1f, 0.0f);
_pushButton1.Clicked += OnPushButtonClicked1;
_layer1.Add(_pushButton1);
_pushButton2.ParentOrigin = ParentOrigin.BottomLeft;
_pushButton2.AnchorPoint = AnchorPoint.BottomLeft;
_pushButton2.LabelText = "reload image with same URL";
- _pushButton2.Position = new Vector3(0.0f, stage.Size.Height * 0.2f, 0.0f);
+ _pushButton2.Position = new Vector3(0.0f, window.Size.Height * 0.2f, 0.0f);
_pushButton2.Clicked += OnPushButtonClicked2;
_layer2.Add(_pushButton2);
_animation.TargetProperty = "Size";
KeyFrames _keyFrames = new KeyFrames();
_keyFrames.Add(0.0f, new Size(0.0f, 0.0f, 0.0f));
- _keyFrames.Add(0.3f, new Size((stage.Size * 0.7f)));
- _keyFrames.Add(1.0f, new Size(stage.Size));
+ _keyFrames.Add(0.3f, new Size((window.Size * 0.7f)));
+ _keyFrames.Add(1.0f, new Size(window.Size));
_animation.AnimateBetween(_imageView, _keyFrames, Animation.Interpolation.Linear);
_animation.EndAction = Animation.EndActions.Discard;
}
}
- public void OnStageEventProcessingFinished(object sender, EventArgs e)
+ public void OnWindowEventProcessingFinished(object sender, EventArgs e)
{
- Log("OnStageEventProcessingFinished()!");
+ Log("OnWindowEventProcessingFinished()!");
if (e != null)
{
Log("e != null !");
}
}
- public void OnStageKeyPressed(object sender, Stage.KeyEventArgs e)
+ public void OnWindowKeyPressed(object sender, Window.KeyEventArgs e)
{
- Log("OnStageKeyEventOccured()!");
+ Log("OnWindowKeyEventOccured()!");
Log("keyPressedName=" + e.Key.KeyPressedName);
Log("state=" + e.Key.State);
}
- public void OnStageWheelMoved(object sender, Stage.WheelEventArgs e)
+ public void OnWindowWheelMoved(object sender, Window.WheelEventArgs e)
{
- Log("OnStageWheelEventOccured()!");
+ Log("OnWindowWheelEventOccured()!");
Log("direction=" + e.Wheel.Direction);
Log("type=" + e.Wheel.Type);
}
- // Callback for stage touched signal handling
- public void OnStageTouched(object sender, Stage.TouchEventArgs e)
+ // Callback for window touched signal handling
+ public void OnWindowTouched(object sender, Window.TouchEventArgs e)
{
- Log("OnStageTouched()! e.TouchData.GetState(0)=" + e.Touch.GetState(0));
+ Log("OnWindowTouched()! e.TouchData.GetState(0)=" + e.Touch.GetState(0));
}
public void MainLoop()
private void CreateScrollView()
{
- Stage stage = Stage.GetCurrent();
- stage.BackgroundColor = Color.White;
+ Window window = Window.Instance;
+ window.BackgroundColor = Color.White;
// Create a scroll view
_scrollView = new ScrollView();
- Size2D stageSize = stage.Size;
- _scrollView.Size = new Position(stageSize.Width, stageSize.Height, 0.0f);
+ Size2D windowSize = window.Size;
+ _scrollView.Size = new Position(windowSize.Width, windowSize.Height, 0.0f);
_scrollView.ParentOrigin = NDalic.ParentOriginCenter;
_scrollView.AnchorPoint = NDalic.AnchorPointCenter;
- stage.Add(_scrollView);
+ window.Add(_scrollView);
// Add actors to a scroll view with 3 pages
int pageRows = 1;
pageActor.SetResizePolicy(ResizePolicyType.FILL_TO_PARENT, DimensionType.ALL_DIMENSIONS);
pageActor.ParentOrigin = NDalic.ParentOriginCenter;
pageActor.AnchorPoint = NDalic.AnchorPointCenter;
- pageActor.Position = new Position(pageColumn * stageSize.Width, pageRow * stageSize.Height, 0.0f);
+ pageActor.Position = new Position(pageColumn * windowSize.Width, pageRow * windowSize.Height, 0.0f);
// Add images in a 3x4 grid layout for each page
int imageRows = 4;
int imageColumns = 3;
float margin = 10.0f;
- Position imageSize = new Position((stageSize.Width / imageColumns) - margin, (stageSize.Height / imageRows) - margin, 0.0f);
+ Position imageSize = new Position((windowSize.Width / imageColumns) - margin, (windowSize.Height / imageRows) - margin, 0.0f);
for (int row = 0; row < imageRows; row++)
{
imageView.ParentOrigin = NDalic.ParentOriginCenter;
imageView.AnchorPoint = NDalic.AnchorPointCenter;
imageView.Size = imageSize;
- imageView.Position = new Position(margin * 0.5f + (imageSize.X + margin) * column - stageSize.Width * 0.5f + imageSize.X * 0.5f,
- margin * 0.5f + (imageSize.Y + margin) * row - stageSize.Height * 0.5f + imageSize.Y * 0.5f, 0.0f);
+ imageView.Position = new Position(margin * 0.5f + (imageSize.X + margin) * column - windowSize.Width * 0.5f + imageSize.X * 0.5f,
+ margin * 0.5f + (imageSize.Y + margin) * row - windowSize.Height * 0.5f + imageSize.Y * 0.5f, 0.0f);
pageActor.Add(imageView);
}
}
// Set scroll view to have 3 pages in X axis and allow page snapping,
// and also disable scrolling in Y axis.
- RulerPtr scrollRulerX = new RulerPtr(new FixedRuler(stageSize.Width));
+ RulerPtr scrollRulerX = new RulerPtr(new FixedRuler(windowSize.Width));
RulerPtr scrollRulerY = new RulerPtr(new DefaultRuler());
- scrollRulerX.SetDomain(new RulerDomain(0.0f, stageSize.Width * pageColumns, true));
+ scrollRulerX.SetDomain(new RulerDomain(0.0f, windowSize.Width * pageColumns, true));
scrollRulerY.Disable();
_scrollView.SetRulerX(scrollRulerX);
_scrollView.SetRulerY(scrollRulerY);
// Only animate the _text label when touch down happens
if (e.Touch.GetState(0) == PointStateType.DOWN)
{
- Console.WriteLine("Customized Stage Touch event handler");
+ Console.WriteLine("Customized Window Touch event handler");
// Create a new _animation
if (_animation)
{
public void Initialize(object source, NUIApplicationInitEventArgs e)
{
Log("Initialize() is called!");
- Stage stage = Stage.GetCurrent();
- stage.BackgroundColor = Color.White;
- stage.Touch += OnStageTouched;
- stage.Touch += OnStageTouched2;
- stage.Wheel += OnStageWheelEvent;
+ Window window = Window.Instance;
+ window.BackgroundColor = Color.White;
+ window.Touch += OnWindowTouched;
+ window.Touch += OnWindowTouched2;
+ window.Wheel += OnWindowWheelEvent;
- // Add a _text label to the stage
+ // Add a _text label to the window
_text = new TextLabel("Hello Mono World");
_text.ParentOrigin = ParentOrigin.BottomCenter;
_text.AnchorPoint = AnchorPoint.BottomCenter;
_text.HorizontalAlignment = "CENTER";
_text.PointSize = 32.0f;
- stage.Add(_text);
+ window.Add(_text);
_view1 = new View();
_view1.Size = new Vector3(200.0f, 200.0f, 0.0f);
_view1.ParentOrigin = ParentOrigin.Center;
_view1.AnchorPoint = AnchorPoint.Center;
_view1.SetResizePolicy(ResizePolicyType.FIXED, DimensionType.ALL_DIMENSIONS);
- _view1.OnStageEvent += OnStage;
- stage.Add(_view1);
+ _view1.OnWindowEvent += OnWindow;
+ window.Add(_view1);
_view2 = new View();
_view2.BackgroundColor = Color.Red;
_animation.Play();
}
- // Callback for stage touched signal handling
- public void OnStageTouched(object source, Stage.TouchEventArgs e)
+ // Callback for window touched signal handling
+ public void OnWindowTouched(object source, Window.TouchEventArgs e)
{
// Only animate the _text label when touch down happens
if (e.Touch.GetState(0) == PointStateType.DOWN)
{
- Log("OnStageTouched() is called! PointStateType.DOWN came!");
+ Log("OnWindowTouched() is called! PointStateType.DOWN came!");
myCount++;
if (myCount > 1)
{
}
}
- // Callback for stage touched signal handling
- public void OnStageTouched2(object source, Stage.TouchEventArgs e)
+ // Callback for window touched signal handling
+ public void OnWindowTouched2(object source, Window.TouchEventArgs e)
{
- Log("OnStageTouched2() is called!state=" + e.Touch.GetState(0));
+ Log("OnWindowTouched2() is called!state=" + e.Touch.GetState(0));
}
public void OnEventProcessingFinished(object source)
Log("OnEventProcessingFinished() is called!");
}
- public void OnStageWheelEvent(object source, Stage.WheelEventArgs e)
+ public void OnWindowWheelEvent(object source, Window.WheelEventArgs e)
{
- Log("OnStageWheelEvent() is called!");
+ Log("OnWindowWheelEvent() is called!");
}
- public void OnStage(object source, View.OnStageEventArgs e)
+ public void OnWindow(object source, View.OnWindowEventArgs e)
{
- Log("OnStage() is called!");
+ Log("OnWindow() is called!");
}
public void MainLoop()
public void Initialize(object source, NUIApplicationInitEventArgs e)
{
- Stage stage = Stage.Instance;
- stage.BackgroundColor = Color.White;
+ Window window = Window.Instance;
+ window.BackgroundColor = Color.White;
TableView contentLayout = new TableView(4, 1);
contentLayout.Name = ("ContentLayout");
contentLayout.SetCellPadding(new Size2D(0, 5));
contentLayout.BackgroundColor = new Color(0.949f, 0.949f, 0.949f, 1.0f);
- stage.GetDefaultLayer().Add(contentLayout);
+ window.GetDefaultLayer().Add(contentLayout);
_title = new TextLabel("Visuals Example");
_title.Name = "Title";
private void Initialize(object source, NUIApplicationInitEventArgs e)
{
- Stage stage = Stage.Instance;
- stage.BackgroundColor = Color.White;
+ Window window = Window.Instance;
+ window.BackgroundColor = Color.White;
TableView contentLayout = new TableView(14, 1);
contentLayout.Name = "ContentLayout";
contentLayout.SetCellPadding(new Size2D(5, 5));
contentLayout.BackgroundColor = new Color(0.949f, 0.949f, 0.949f, 1.0f);
- stage.GetDefaultLayer().Add(contentLayout);
+ window.GetDefaultLayer().Add(contentLayout);
TextLabel title = new TextLabel("Contacts List with Visuals");
title.Name = "Title";
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
public override void Dispose()
{
- if (!Stage.IsInstalled())
+ if (!Window.IsInstalled())
{
DisposeQueue.Instance.Add(this);
return;
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
public virtual void Dispose()
{
- if (!Stage.IsInstalled())
+ if (!Window.IsInstalled())
{
DisposeQueue.Instance.Add(this);
return;
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
+++ /dev/null
-//------------------------------------------------------------------------------
-// <auto-generated />
-//
-// This file was automatically generated by SWIG (http://www.swig.org).
-// Version 3.0.10
-//
-// Do not make changes to this file unless you know what you are doing--modify
-// the SWIG interface file instead.
-//------------------------------------------------------------------------------
-
-namespace Dali {
-
-using System;
-using System.Runtime.InteropServices;
-
-
-public class Stage : BaseHandle {
- private global::System.Runtime.InteropServices.HandleRef swigCPtr;
-
- internal Stage(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.Stage_SWIGUpcast(cPtr), cMemoryOwn) {
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
- }
-
- internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Stage obj) {
- return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
- }
-
- ~Stage() {
- DisposeQueue.Instance.Add(this);
- }
-
- public override void Dispose() {
- if (!Stage.IsInstalled()) {
- DisposeQueue.Instance.Add(this);
- return;
- }
-
- lock(this) {
- if (swigCPtr.Handle != global::System.IntPtr.Zero) {
- if (swigCMemOwn) {
- swigCMemOwn = false;
- NDalicPINVOKE.delete_Stage(swigCPtr);
- }
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
- }
- global::System.GC.SuppressFinalize(this);
- base.Dispose();
- }
- }
-
-
-
-
- /**
- * @brief Event arguments that passed via Touch signal
- *
- */
- public class TouchEventArgs : EventArgs
- {
- private Touch _touch;
-
- /**
- * @brief Touch - contains the information of touch points
- *
- */
- public Touch Touch
- {
- get
- {
- return _touch;
- }
- set
- {
- _touch = value;
- }
- }
- }
-
- private event EventHandler<TouchEventArgs> _stageTouchHandler;
- private EventCallbackDelegateType1<IntPtr> _stageTouchCallbackDelegate;
-
- /**
- * @brief Event for TouchEvent signal which can be used to subscribe/unsubscribe the event handler
- * TouchEvent signal is emitted when the screen is touched and when the touch ends
- * (i.e. the down & up touch events only).
- *
- */
- public event EventHandler<TouchEventArgs> Touch
- {
- add
- {
- lock(this)
- {
- _stageTouchHandler += value;
- _stageTouchCallbackDelegate = OnStageTouch;
- this.TouchSignal().Connect(_stageTouchCallbackDelegate);
- }
- }
- remove
- {
- lock(this)
- {
- if (_stageTouchHandler != null)
- {
- this.TouchSignal().Disconnect(_stageTouchCallbackDelegate);
- }
- _stageTouchHandler -= value;
- }
- }
- }
-
- private void OnStageTouch(IntPtr data)
- {
- TouchEventArgs e = new TouchEventArgs();
-
- if( data != null )
- {
- e.Touch = Dali.Touch.GetTouchFromPtr( data );
- }
-
- if (_stageTouchHandler != null)
- {
- _stageTouchHandler(this, e);
- }
- }
-
- /**
- * @brief Wheel arguments that passed via Wheel signal
- *
- */
- public class WheelEventArgs : EventArgs
- {
- private Wheel _wheel;
-
- /**
- * @brief Wheel - store a wheel rolling type MOUSE_WHEEL or CUSTOM_WHEEL
- *
- */
- public Wheel Wheel
- {
- get
- {
- return _wheel;
- }
- set
- {
- _wheel = value;
- }
- }
- }
-
- private event EventHandler<WheelEventArgs> _stageWheelHandler;
- private EventCallbackDelegateType1<IntPtr> _stageWheelCallbackDelegate;
-
- /**
- * @brief Event for Wheel signal which can be used to subscribe/unsubscribe the event handler
- * Wheel signal is emitted is emitted when wheel event is received.
- *
- */
- public event EventHandler<WheelEventArgs> Wheel
- {
- add
- {
- lock(this)
- {
- _stageWheelHandler += value;
- _stageWheelCallbackDelegate = OnStageWheel;
- this.WheelEventSignal().Connect(_stageWheelCallbackDelegate);
- }
- }
- remove
- {
- lock(this)
- {
- if (_stageWheelHandler != null)
- {
- this.WheelEventSignal().Disconnect(_stageWheelCallbackDelegate);
- }
- _stageWheelHandler -= value;
- }
- }
- }
-
- private void OnStageWheel(IntPtr data)
- {
- WheelEventArgs e = new WheelEventArgs();
-
- if( data != null )
- {
- e.Wheel = Dali.Wheel.GetWheelFromPtr( data );
- }
-
- if (_stageWheelHandler != null)
- {
- _stageWheelHandler(this, e);
- }
- }
-
- /**
- * @brief Event arguments that passed via Key signal
- *
- */
- public class KeyEventArgs : EventArgs
- {
- private Key _key;
-
- /**
- * @brief Key - is the keyevent sent to Stage.
- *
- */
- public Key Key
- {
- get
- {
- return _key;
- }
- set
- {
- _key = value;
- }
- }
- }
-
- private event EventHandler<KeyEventArgs> _stageKeyHandler;
- private EventCallbackDelegateType1<IntPtr> _stageKeyCallbackDelegate;
-
- /**
- * @brief Event for Key signal which can be used to subscribe/unsubscribe the event handler
- * Key signal is emitted is emitted when key event is received.
- *
- */
- public event EventHandler<KeyEventArgs> Key
- {
- add
- {
- lock(this)
- {
- _stageKeyHandler += value;
- _stageKeyCallbackDelegate = OnStageKey;
- this.KeyEventSignal().Connect(_stageKeyCallbackDelegate);
- }
- }
- remove
- {
- lock(this)
- {
- if (_stageKeyHandler != null)
- {
- this.KeyEventSignal().Disconnect(_stageKeyCallbackDelegate);
- }
- _stageKeyHandler -= value;
- }
- }
- }
-
- // Callback for Stage KeyEventsignal
- private void OnStageKey(IntPtr data)
- {
- KeyEventArgs e = new KeyEventArgs();
-
- if( data != null )
- {
- e.Key = Dali.Key.GetKeyFromPtr( data );
- }
-
- if (_stageKeyHandler != null)
- {
- //here we send all data to user event handlers
- _stageKeyHandler(this, e);
- }
- }
-
-
- private event EventHandler _stageEventProcessingFinishedEventHandler;
- private EventCallbackDelegateType0 _stageEventProcessingFinishedEventCallbackDelegate;
-
- /**
- * @brief Event for EventProcessingFinished signal which can be used to subscribe/unsubscribe the event handler
- * provided by the user. EventProcessingFinished signal is emitted just after the event processing is finished.
- *
- */
- public event EventHandler EventProcessingFinished
- {
- add
- {
- lock(this)
- {
- _stageEventProcessingFinishedEventHandler += value;
- _stageEventProcessingFinishedEventCallbackDelegate = OnEventProcessingFinished;
- this.EventProcessingFinishedSignal().Connect(_stageEventProcessingFinishedEventCallbackDelegate);
- }
- }
- remove
- {
- lock(this)
- {
- if (_stageEventProcessingFinishedEventHandler != null)
- {
- this.EventProcessingFinishedSignal().Disconnect(_stageEventProcessingFinishedEventCallbackDelegate);
- }
- _stageEventProcessingFinishedEventHandler -= value;
- }
- }
- }
-
- // Callback for Stage EventProcessingFinishedSignal
- private void OnEventProcessingFinished()
- {
- if (_stageEventProcessingFinishedEventHandler != null)
- {
- _stageEventProcessingFinishedEventHandler(this, null);
- }
- }
-
-
- private EventHandler _stageContextLostEventHandler;
- private EventCallbackDelegateType0 _stageContextLostEventCallbackDelegate;
-
- /**
- * @brief Event for ContextLost signal which can be used to subscribe/unsubscribe the event handler
- * ContextLost signal is emitted when the GL context is lost (Platform specific behaviour).
- *
- */
- public event EventHandler ContextLost
- {
- add
- {
- lock(this)
- {
- _stageContextLostEventHandler += value;
- _stageContextLostEventCallbackDelegate = OnContextLost;
- this.ContextLostSignal().Connect(_stageContextLostEventCallbackDelegate);
- }
- }
- remove
- {
- lock(this)
- {
- if (_stageContextLostEventHandler != null)
- {
- this.ContextLostSignal().Disconnect(_stageContextLostEventCallbackDelegate);
- }
-
- _stageContextLostEventHandler -= value;
- }
- }
- }
-
- // Callback for Stage ContextLostSignal
- private void OnContextLost()
- {
- if (_stageContextLostEventHandler != null)
- {
- _stageContextLostEventHandler(this, null);
- }
- }
-
-
- private EventHandler _stageContextRegainedEventHandler;
- private EventCallbackDelegateType0 _stageContextRegainedEventCallbackDelegate;
-
- /**
- * @brief Event for ContextRegained signal which can be used to subscribe/unsubscribe the event handler
- * provided by the user. ContextRegained signal is emitted when the GL context is regained (Platform specific
- * behaviour).
- *
- */
- public event EventHandler ContextRegained
- {
- add
- {
- lock(this)
- {
- _stageContextRegainedEventHandler += value;
- _stageContextRegainedEventCallbackDelegate = OnContextRegained;
- this.ContextRegainedSignal().Connect(_stageContextRegainedEventCallbackDelegate);
- }
- }
- remove
- {
- lock(this)
- {
- if (_stageContextRegainedEventHandler != null)
- {
- this.ContextRegainedSignal().Disconnect(_stageContextRegainedEventCallbackDelegate);
- }
-
- _stageContextRegainedEventHandler -= value;
- }
- }
- }
-
- // Callback for Stage ContextRegainedSignal
- private void OnContextRegained()
- {
- if (_stageContextRegainedEventHandler != null)
- {
- _stageContextRegainedEventHandler(this, null);
- }
- }
-
-
- private EventHandler _stageSceneCreatedEventHandler;
- private EventCallbackDelegateType0 _stageSceneCreatedEventCallbackDelegate;
-
- /**
- * @brief Event for SceneCreated signal which can be used to subscribe/unsubscribe the event handler
- * SceneCreated signal is emitted after the initial scene is created.
- *
- */
- public event EventHandler SceneCreated
- {
- add
- {
- lock(this)
- {
- _stageSceneCreatedEventHandler += value;
- _stageSceneCreatedEventCallbackDelegate = OnSceneCreated;
- this.SceneCreatedSignal().Connect(_stageSceneCreatedEventCallbackDelegate);
- }
- }
- remove
- {
- lock(this)
- {
- if (_stageSceneCreatedEventHandler != null)
- {
- this.SceneCreatedSignal().Disconnect(_stageSceneCreatedEventCallbackDelegate);
- }
-
- _stageSceneCreatedEventHandler -= value;
- }
- }
- }
-
- // Callback for Stage SceneCreatedSignal
- private void OnSceneCreated()
- {
- if (_stageSceneCreatedEventHandler != null)
- {
- _stageSceneCreatedEventHandler(this, null);
- }
- }
-
-
- public Vector2 Size
- {
- get
- {
- Vector2 ret = GetSize();
- return ret;
- }
- }
-
- public Vector4 BackgroundColor
- {
- set
- {
- SetBackgroundColor(value);
- }
- get
- {
- Vector4 ret = GetBackgroundColor();
- return ret;
- }
- }
-
- private static readonly Stage instance = Stage.GetCurrent();
-
- public static Stage Instance
- {
- get
- {
- return instance;
- }
- }
-
- public Layer GetDefaultLayer()
- {
- return this.GetRootLayer();
- }
-
- public void AddLayer(Layer layer)
- {
- NDalicPINVOKE.Stage_Add(swigCPtr, Layer.getCPtr(layer));
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public void RemoveLayer(Layer layer)
- {
- NDalicPINVOKE.Stage_Remove(swigCPtr, Layer.getCPtr(layer));
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public static Vector4 DEFAULT_BACKGROUND_COLOR {
- get {
- global::System.IntPtr cPtr = NDalicPINVOKE.Stage_DEFAULT_BACKGROUND_COLOR_get();
- Vector4 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector4(cPtr, false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- }
-
- public static Vector4 DEBUG_BACKGROUND_COLOR {
- get {
- global::System.IntPtr cPtr = NDalicPINVOKE.Stage_DEBUG_BACKGROUND_COLOR_get();
- Vector4 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector4(cPtr, false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
- }
-
- public Stage() : this(NDalicPINVOKE.new_Stage__SWIG_0(), true) {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public static Stage GetCurrent() {
- Stage ret = new Stage(NDalicPINVOKE.Stage_GetCurrent(), true);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public static bool IsInstalled() {
- bool ret = NDalicPINVOKE.Stage_IsInstalled();
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public Stage(Stage handle) : this(NDalicPINVOKE.new_Stage__SWIG_1(Stage.getCPtr(handle)), true) {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public Stage Assign(Stage rhs) {
- Stage ret = new Stage(NDalicPINVOKE.Stage_Assign(swigCPtr, Stage.getCPtr(rhs)), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public void Add(View view) {
- NDalicPINVOKE.Stage_Add(swigCPtr, View.getCPtr(view));
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public void Remove(View view) {
- NDalicPINVOKE.Stage_Remove(swigCPtr, View.getCPtr(view));
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public Vector2 GetSize() {
- Vector2 ret = new Vector2(NDalicPINVOKE.Stage_GetSize(swigCPtr), true);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public RenderTaskList GetRenderTaskList() {
- RenderTaskList ret = new RenderTaskList(NDalicPINVOKE.Stage_GetRenderTaskList(swigCPtr), true);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public uint GetLayerCount() {
- uint ret = NDalicPINVOKE.Stage_GetLayerCount(swigCPtr);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public Layer GetLayer(uint depth) {
- Layer ret = new Layer(NDalicPINVOKE.Stage_GetLayer(swigCPtr, depth), true);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public Layer GetRootLayer() {
- Layer ret = new Layer(NDalicPINVOKE.Stage_GetRootLayer(swigCPtr), true);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public void SetBackgroundColor(Vector4 color) {
- NDalicPINVOKE.Stage_SetBackgroundColor(swigCPtr, Vector4.getCPtr(color));
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public Vector4 GetBackgroundColor() {
- Vector4 ret = new Vector4(NDalicPINVOKE.Stage_GetBackgroundColor(swigCPtr), true);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public Vector2 GetDpi() {
- Vector2 ret = new Vector2(NDalicPINVOKE.Stage_GetDpi(swigCPtr), true);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public ObjectRegistry GetObjectRegistry() {
- ObjectRegistry ret = new ObjectRegistry(NDalicPINVOKE.Stage_GetObjectRegistry(swigCPtr), true);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public void KeepRendering(float durationSeconds) {
- NDalicPINVOKE.Stage_KeepRendering(swigCPtr, durationSeconds);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public KeyEventSignal KeyEventSignal() {
- KeyEventSignal ret = new KeyEventSignal(NDalicPINVOKE.Stage_KeyEventSignal(swigCPtr), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public VoidSignal EventProcessingFinishedSignal() {
- VoidSignal ret = new VoidSignal(NDalicPINVOKE.Stage_EventProcessingFinishedSignal(swigCPtr), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public TouchSignal TouchSignal() {
- TouchSignal ret = new TouchSignal(NDalicPINVOKE.Stage_TouchSignal(swigCPtr), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public StageWheelSignal WheelEventSignal() {
- StageWheelSignal ret = new StageWheelSignal(NDalicPINVOKE.Stage_WheelEventSignal(swigCPtr), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public VoidSignal ContextLostSignal() {
- VoidSignal ret = new VoidSignal(NDalicPINVOKE.Stage_ContextLostSignal(swigCPtr), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public VoidSignal ContextRegainedSignal() {
- VoidSignal ret = new VoidSignal(NDalicPINVOKE.Stage_ContextRegainedSignal(swigCPtr), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public VoidSignal SceneCreatedSignal() {
- VoidSignal ret = new VoidSignal(NDalicPINVOKE.Stage_SceneCreatedSignal(swigCPtr), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
-}
-
-}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
public virtual void Dispose()
{
- if (!Stage.IsInstalled())
+ if (!Window.IsInstalled())
{
DisposeQueue.Instance.Add(this);
return;
}
/**
- * @brief Event arguments that passed via OnStage signal
+ * @brief Event arguments that passed via OnWindow signal
*
*/
- public class OnStageEventArgs : EventArgs
+ public class OnWindowEventArgs : EventArgs
{
private View _view;
/**
- * @brief View - is the view that is being connected to the stage
+ * @brief View - is the view that is being connected to the window
*
*/
public View View
}
/**
- * @brief Event arguments that passed via OffStage signal
+ * @brief Event arguments that passed via OffWindow signal
*
*/
- public class OffStageEventArgs : EventArgs
+ public class OffWindowEventArgs : EventArgs
{
private View _view;
/**
- * @brief View - is the view that is being disconnected from the stage
+ * @brief View - is the view that is being disconnected from the window
*
*/
public View View
private WheelCallbackDelegate _viewWheelCallbackDelegate;
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
- private delegate void OnStageEventCallbackDelegate(IntPtr control);
+ private delegate void OnWindowEventCallbackDelegate(IntPtr control);
- private DaliEventHandler<object,OnStageEventArgs> _viewOnStageEventHandler;
- private OnStageEventCallbackDelegate _viewOnStageEventCallbackDelegate;
+ private DaliEventHandler<object,OnWindowEventArgs> _viewOnWindowEventHandler;
+ private OnWindowEventCallbackDelegate _viewOnWindowEventCallbackDelegate;
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
- private delegate void OffStageEventCallbackDelegate(IntPtr control);
+ private delegate void OffWindowEventCallbackDelegate(IntPtr control);
- private DaliEventHandler<object,OffStageEventArgs> _viewOffStageEventHandler;
- private OffStageEventCallbackDelegate _viewOffStageEventCallbackDelegate;
+ private DaliEventHandler<object,OffWindowEventArgs> _viewOffWindowEventHandler;
+ private OffWindowEventCallbackDelegate _viewOffWindowEventCallbackDelegate;
/**
* @brief Event for KeyInputFocusGained signal which can be used to subscribe/unsubscribe the event handler
}
/**
- * @brief Event for OnStage signal which can be used to subscribe/unsubscribe the event handler
- * (in the type of OnStageEventHandler) provided by the user.
- * OnStage signal is emitted after the view has been connected to the stage.
+ * @brief Event for OnWindow signal which can be used to subscribe/unsubscribe the event handler
+ * (in the type of OnWindowEventHandler) provided by the user.
+ * OnWindow signal is emitted after the view has been connected to the window.
*/
- public event DaliEventHandler<object,OnStageEventArgs> OnStageEvent
+ public event DaliEventHandler<object,OnWindowEventArgs> OnWindowEvent
{
add
{
lock (this)
{
// Restricted to only one listener
- if (_viewOnStageEventHandler == null)
+ if (_viewOnWindowEventHandler == null)
{
- _viewOnStageEventHandler += value;
+ _viewOnWindowEventHandler += value;
- _viewOnStageEventCallbackDelegate = new OnStageEventCallbackDelegate(OnStage);
- this.OnStageSignal().Connect(_viewOnStageEventCallbackDelegate);
+ _viewOnWindowEventCallbackDelegate = new OnWindowEventCallbackDelegate(OnWindow);
+ this.OnWindowSignal().Connect(_viewOnWindowEventCallbackDelegate);
}
}
}
{
lock (this)
{
- if (_viewOnStageEventHandler != null)
+ if (_viewOnWindowEventHandler != null)
{
- this.OnStageSignal().Disconnect(_viewOnStageEventCallbackDelegate);
+ this.OnWindowSignal().Disconnect(_viewOnWindowEventCallbackDelegate);
}
- _viewOnStageEventHandler -= value;
+ _viewOnWindowEventHandler -= value;
}
}
}
- // Callback for View OnStage signal
- private void OnStage(IntPtr data)
+ // Callback for View OnWindow signal
+ private void OnWindow(IntPtr data)
{
- OnStageEventArgs e = new OnStageEventArgs();
+ OnWindowEventArgs e = new OnWindowEventArgs();
- // Populate all members of "e" (OnStageEventArgs) with real data
+ // Populate all members of "e" (OnWindowEventArgs) with real data
e.View = View.GetViewFromPtr(data);
- //Console.WriteLine("############# OnStage()! e.View.Name=" + e.View.Name);
+ //Console.WriteLine("############# OnWindow()! e.View.Name=" + e.View.Name);
- if (_viewOnStageEventHandler != null)
+ if (_viewOnWindowEventHandler != null)
{
//here we send all data to user event handlers
- _viewOnStageEventHandler(this, e);
+ _viewOnWindowEventHandler(this, e);
}
}
/**
- * @brief Event for OffStage signal which can be used to subscribe/unsubscribe the event handler
- * (in the type of OffStageEventHandler) provided by the user.
- * OffStage signal is emitted after the view has been disconnected from the stage.
+ * @brief Event for OffWindow signal which can be used to subscribe/unsubscribe the event handler
+ * (in the type of OffWindowEventHandler) provided by the user.
+ * OffWindow signal is emitted after the view has been disconnected from the window.
*/
- public event DaliEventHandler<object,OffStageEventArgs> OffStageEvent
+ public event DaliEventHandler<object,OffWindowEventArgs> OffWindowEvent
{
add
{
lock (this)
{
// Restricted to only one listener
- if (_viewOffStageEventHandler == null)
+ if (_viewOffWindowEventHandler == null)
{
- _viewOffStageEventHandler += value;
+ _viewOffWindowEventHandler += value;
- _viewOffStageEventCallbackDelegate = new OffStageEventCallbackDelegate(OffStage);
- this.OnStageSignal().Connect(_viewOffStageEventCallbackDelegate);
+ _viewOffWindowEventCallbackDelegate = new OffWindowEventCallbackDelegate(OffWindow);
+ this.OnWindowSignal().Connect(_viewOffWindowEventCallbackDelegate);
}
}
}
{
lock (this)
{
- if (_viewOffStageEventHandler != null)
+ if (_viewOffWindowEventHandler != null)
{
- this.OnStageSignal().Disconnect(_viewOffStageEventCallbackDelegate);
+ this.OnWindowSignal().Disconnect(_viewOffWindowEventCallbackDelegate);
}
- _viewOffStageEventHandler -= value;
+ _viewOffWindowEventHandler -= value;
}
}
}
- // Callback for View OffStage signal
- private void OffStage(IntPtr data)
+ // Callback for View OffWindow signal
+ private void OffWindow(IntPtr data)
{
- OffStageEventArgs e = new OffStageEventArgs();
+ OffWindowEventArgs e = new OffWindowEventArgs();
- // Populate all members of "e" (OffStageEventArgs) with real data
+ // Populate all members of "e" (OffWindowEventArgs) with real data
e.View = View.GetViewFromPtr(data);
- if (_viewOffStageEventHandler != null)
+ if (_viewOffWindowEventHandler != null)
{
//here we send all data to user event handlers
- _viewOffStageEventHandler(this, e);
+ _viewOffWindowEventHandler(this, e);
}
}
if (!view)
{
- view = Stage.Instance.GetRootLayer().FindChildById(id);
+ view = Window.Instance.GetRootLayer().FindChildById(id);
}
return view;
/**
* @brief The left focusable view.
* @note This will return NULL if not set.
- * This will also return NULL if the specified left focusable view is not on stage.
+ * This will also return NULL if the specified left focusable view is not on window.
*
*/
public View LeftFocusableView
/**
* @brief The right focusable view.
* @note This will return NULL if not set.
- * This will also return NULL if the specified right focusable view is not on stage.
+ * This will also return NULL if the specified right focusable view is not on window.
*
*/
public View RightFocusableView
/**
* @brief The up focusable view.
* @note This will return NULL if not set.
- * This will also return NULL if the specified up focusable view is not on stage.
+ * This will also return NULL if the specified up focusable view is not on window.
*
*/
public View UpFocusableView
/**
* @brief The down focusable view.
* @note This will return NULL if not set.
- * This will also return NULL if the specified down focusable view is not on stage.
+ * This will also return NULL if the specified down focusable view is not on window.
*
*/
public View DownFocusableView
}
}
- public bool IsOnStage
+ public bool IsOnWindow
{
get
{
- return OnStage();
+ return OnWindow();
}
}
return ret;
}
- public bool OnStage()
+ public bool OnWindow()
{
bool ret = NDalicPINVOKE.Actor_OnStage(swigCPtr);
if (NDalicPINVOKE.SWIGPendingException.Pending)
return ret;
}
- public ViewSignal OnStageSignal()
+ public ViewSignal OnWindowSignal()
{
ViewSignal ret = new ViewSignal(NDalicPINVOKE.Actor_OnStageSignal(swigCPtr), false);
if (NDalicPINVOKE.SWIGPendingException.Pending)
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
public override void Dispose()
{
- if (!Stage.IsInstalled())
+ if (!Window.IsInstalled())
{
DisposeQueue.Instance.Add(this);
return;
public override void Dispose()
{
- if (!Stage.IsInstalled())
+ if (!Window.IsInstalled())
{
DisposeQueue.Instance.Add(this);
return;
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
}
public virtual void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
public class Window : BaseHandle {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
+ private global::System.Runtime.InteropServices.HandleRef stageCPtr;
internal Window(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.Window_SWIGUpcast(cPtr), cMemoryOwn) {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
+ stageCPtr = new global::System.Runtime.InteropServices.HandleRef(this, NDalicPINVOKE.Stage_GetCurrent());
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Window obj) {
}
public override void Dispose() {
- if (!Stage.IsInstalled()) {
+ if (!Window.IsInstalled()) {
DisposeQueue.Instance.Add(this);
return;
}
if (swigCMemOwn) {
swigCMemOwn = false;
NDalicPINVOKE.delete_Window(swigCPtr);
+ NDalicPINVOKE.delete_Stage(stageCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
-
+ public static bool IsInstalled() {
+ bool ret = NDalicPINVOKE.Stage_IsInstalled();
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
public void SetAcceptFocus( bool accept )
{
NDalicPINVOKE.SetAcceptFocus(swigCPtr, accept);
return ret;
}
+ public Layer GetDefaultLayer()
+ {
+ return this.GetRootLayer();
+ }
+
+ public void Add(Layer layer)
+ {
+ NDalicPINVOKE.Stage_Add(stageCPtr, Layer.getCPtr(layer));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+
+ public void Remove(Layer layer)
+ {
+ NDalicPINVOKE.Stage_Remove(stageCPtr, Layer.getCPtr(layer));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+
+ public void Add(View view) {
+ NDalicPINVOKE.Stage_Add(stageCPtr, View.getCPtr(view));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+
+ public void Remove(View view) {
+ NDalicPINVOKE.Stage_Remove(stageCPtr, View.getCPtr(view));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+
+ public Vector2 GetSize() {
+ Vector2 ret = new Vector2(NDalicPINVOKE.Stage_GetSize(stageCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public RenderTaskList GetRenderTaskList() {
+ RenderTaskList ret = new RenderTaskList(NDalicPINVOKE.Stage_GetRenderTaskList(stageCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public uint GetLayerCount() {
+ uint ret = NDalicPINVOKE.Stage_GetLayerCount(stageCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public Layer GetLayer(uint depth) {
+ Layer ret = new Layer(NDalicPINVOKE.Stage_GetLayer(stageCPtr, depth), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public Layer GetRootLayer() {
+ Layer ret = new Layer(NDalicPINVOKE.Stage_GetRootLayer(stageCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public void SetBackgroundColor(Vector4 color) {
+ NDalicPINVOKE.Stage_SetBackgroundColor(stageCPtr, Vector4.getCPtr(color));
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+
+ public Vector4 GetBackgroundColor() {
+ Vector4 ret = new Vector4(NDalicPINVOKE.Stage_GetBackgroundColor(stageCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public Vector2 GetDpi() {
+ Vector2 ret = new Vector2(NDalicPINVOKE.Stage_GetDpi(stageCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public ObjectRegistry GetObjectRegistry() {
+ ObjectRegistry ret = new ObjectRegistry(NDalicPINVOKE.Stage_GetObjectRegistry(stageCPtr), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public void KeepRendering(float durationSeconds) {
+ NDalicPINVOKE.Stage_KeepRendering(stageCPtr, durationSeconds);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+
+ public KeyEventSignal KeyEventSignal() {
+ KeyEventSignal ret = new KeyEventSignal(NDalicPINVOKE.Stage_KeyEventSignal(stageCPtr), false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public VoidSignal EventProcessingFinishedSignal() {
+ VoidSignal ret = new VoidSignal(NDalicPINVOKE.Stage_EventProcessingFinishedSignal(stageCPtr), false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public TouchSignal TouchSignal() {
+ TouchSignal ret = new TouchSignal(NDalicPINVOKE.Stage_TouchSignal(stageCPtr), false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ private StageWheelSignal WheelEventSignal() {
+ StageWheelSignal ret = new StageWheelSignal(NDalicPINVOKE.Stage_WheelEventSignal(stageCPtr), false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public VoidSignal ContextLostSignal() {
+ VoidSignal ret = new VoidSignal(NDalicPINVOKE.Stage_ContextLostSignal(stageCPtr), false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public VoidSignal ContextRegainedSignal() {
+ VoidSignal ret = new VoidSignal(NDalicPINVOKE.Stage_ContextRegainedSignal(stageCPtr), false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public VoidSignal SceneCreatedSignal() {
+ VoidSignal ret = new VoidSignal(NDalicPINVOKE.Stage_SceneCreatedSignal(stageCPtr), false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public static Vector4 DEFAULT_BACKGROUND_COLOR {
+ get {
+ global::System.IntPtr cPtr = NDalicPINVOKE.Stage_DEFAULT_BACKGROUND_COLOR_get();
+ Vector4 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector4(cPtr, false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ public static Vector4 DEBUG_BACKGROUND_COLOR {
+ get {
+ global::System.IntPtr cPtr = NDalicPINVOKE.Stage_DEBUG_BACKGROUND_COLOR_get();
+ Vector4 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector4(cPtr, false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
+ private static readonly Window instance = Application.Instance.GetWindow();
+ public static Window Instance
+ {
+ get
+ {
+ return instance;
+ }
+ }
+
public enum WindowOrientation {
PORTRAIT = 0,
LANDSCAPE = 90,
AUTO = 2
}
+
+
+ /**
+ * @brief Event arguments that passed via Touch signal
+ *
+ */
+ public class TouchEventArgs : EventArgs
+ {
+ private Touch _touch;
+
+ /**
+ * @brief Touch - contains the information of touch points
+ *
+ */
+ public Touch Touch
+ {
+ get
+ {
+ return _touch;
+ }
+ set
+ {
+ _touch = value;
+ }
+ }
+ }
+
+ private event EventHandler<TouchEventArgs> _stageTouchHandler;
+ private EventCallbackDelegateType1<IntPtr> _stageTouchCallbackDelegate;
+
+ /**
+ * @brief Event for TouchEvent signal which can be used to subscribe/unsubscribe the event handler
+ * TouchEvent signal is emitted when the screen is touched and when the touch ends
+ * (i.e. the down & up touch events only).
+ *
+ */
+ public event EventHandler<TouchEventArgs> Touch
+ {
+ add
+ {
+ lock(this)
+ {
+ _stageTouchHandler += value;
+ _stageTouchCallbackDelegate = OnStageTouch;
+ this.TouchSignal().Connect(_stageTouchCallbackDelegate);
+ }
+ }
+ remove
+ {
+ lock(this)
+ {
+ if (_stageTouchHandler != null)
+ {
+ this.TouchSignal().Disconnect(_stageTouchCallbackDelegate);
+ }
+ _stageTouchHandler -= value;
+ }
+ }
+ }
+
+ private void OnStageTouch(IntPtr data)
+ {
+ TouchEventArgs e = new TouchEventArgs();
+
+ if( data != null )
+ {
+ e.Touch = Dali.Touch.GetTouchFromPtr( data );
+ }
+
+ if (_stageTouchHandler != null)
+ {
+ _stageTouchHandler(this, e);
+ }
+ }
+
+ /**
+ * @brief Wheel arguments that passed via Wheel signal
+ *
+ */
+ public class WheelEventArgs : EventArgs
+ {
+ private Wheel _wheel;
+
+ /**
+ * @brief Wheel - store a wheel rolling type MOUSE_WHEEL or CUSTOM_WHEEL
+ *
+ */
+ public Wheel Wheel
+ {
+ get
+ {
+ return _wheel;
+ }
+ set
+ {
+ _wheel = value;
+ }
+ }
+ }
+
+ private event EventHandler<WheelEventArgs> _stageWheelHandler;
+ private EventCallbackDelegateType1<IntPtr> _stageWheelCallbackDelegate;
+
+ /**
+ * @brief Event for Wheel signal which can be used to subscribe/unsubscribe the event handler
+ * Wheel signal is emitted is emitted when wheel event is received.
+ *
+ */
+ public event EventHandler<WheelEventArgs> Wheel
+ {
+ add
+ {
+ lock(this)
+ {
+ _stageWheelHandler += value;
+ _stageWheelCallbackDelegate = OnStageWheel;
+ this.WheelEventSignal().Connect(_stageWheelCallbackDelegate);
+ }
+ }
+ remove
+ {
+ lock(this)
+ {
+ if (_stageWheelHandler != null)
+ {
+ this.WheelEventSignal().Disconnect(_stageWheelCallbackDelegate);
+ }
+ _stageWheelHandler -= value;
+ }
+ }
+ }
+
+ private void OnStageWheel(IntPtr data)
+ {
+ WheelEventArgs e = new WheelEventArgs();
+
+ if( data != null )
+ {
+ e.Wheel = Dali.Wheel.GetWheelFromPtr( data );
+ }
+
+ if (_stageWheelHandler != null)
+ {
+ _stageWheelHandler(this, e);
+ }
+ }
+
+ /**
+ * @brief Event arguments that passed via Key signal
+ *
+ */
+ public class KeyEventArgs : EventArgs
+ {
+ private Key _key;
+
+ /**
+ * @brief Key - is the keyevent sent to Stage.
+ *
+ */
+ public Key Key
+ {
+ get
+ {
+ return _key;
+ }
+ set
+ {
+ _key = value;
+ }
+ }
+ }
+
+ private event EventHandler<KeyEventArgs> _stageKeyHandler;
+ private EventCallbackDelegateType1<IntPtr> _stageKeyCallbackDelegate;
+
+ /**
+ * @brief Event for Key signal which can be used to subscribe/unsubscribe the event handler
+ * Key signal is emitted is emitted when key event is received.
+ *
+ */
+ public event EventHandler<KeyEventArgs> Key
+ {
+ add
+ {
+ lock(this)
+ {
+ _stageKeyHandler += value;
+ _stageKeyCallbackDelegate = OnStageKey;
+ this.KeyEventSignal().Connect(_stageKeyCallbackDelegate);
+ }
+ }
+ remove
+ {
+ lock(this)
+ {
+ if (_stageKeyHandler != null)
+ {
+ this.KeyEventSignal().Disconnect(_stageKeyCallbackDelegate);
+ }
+ _stageKeyHandler -= value;
+ }
+ }
+ }
+
+ // Callback for Stage KeyEventsignal
+ private void OnStageKey(IntPtr data)
+ {
+ KeyEventArgs e = new KeyEventArgs();
+
+ if( data != null )
+ {
+ e.Key = Dali.Key.GetKeyFromPtr( data );
+ }
+
+ if (_stageKeyHandler != null)
+ {
+ //here we send all data to user event handlers
+ _stageKeyHandler(this, e);
+ }
+ }
+
+
+ private event EventHandler _stageEventProcessingFinishedEventHandler;
+ private EventCallbackDelegateType0 _stageEventProcessingFinishedEventCallbackDelegate;
+
+ /**
+ * @brief Event for EventProcessingFinished signal which can be used to subscribe/unsubscribe the event handler
+ * provided by the user. EventProcessingFinished signal is emitted just after the event processing is finished.
+ *
+ */
+ public event EventHandler EventProcessingFinished
+ {
+ add
+ {
+ lock(this)
+ {
+ _stageEventProcessingFinishedEventHandler += value;
+ _stageEventProcessingFinishedEventCallbackDelegate = OnEventProcessingFinished;
+ this.EventProcessingFinishedSignal().Connect(_stageEventProcessingFinishedEventCallbackDelegate);
+ }
+ }
+ remove
+ {
+ lock(this)
+ {
+ if (_stageEventProcessingFinishedEventHandler != null)
+ {
+ this.EventProcessingFinishedSignal().Disconnect(_stageEventProcessingFinishedEventCallbackDelegate);
+ }
+ _stageEventProcessingFinishedEventHandler -= value;
+ }
+ }
+ }
+
+ // Callback for Stage EventProcessingFinishedSignal
+ private void OnEventProcessingFinished()
+ {
+ if (_stageEventProcessingFinishedEventHandler != null)
+ {
+ _stageEventProcessingFinishedEventHandler(this, null);
+ }
+ }
+
+
+ private EventHandler _stageContextLostEventHandler;
+ private EventCallbackDelegateType0 _stageContextLostEventCallbackDelegate;
+
+ /**
+ * @brief Event for ContextLost signal which can be used to subscribe/unsubscribe the event handler
+ * ContextLost signal is emitted when the GL context is lost (Platform specific behaviour).
+ *
+ */
+ public event EventHandler ContextLost
+ {
+ add
+ {
+ lock(this)
+ {
+ _stageContextLostEventHandler += value;
+ _stageContextLostEventCallbackDelegate = OnContextLost;
+ this.ContextLostSignal().Connect(_stageContextLostEventCallbackDelegate);
+ }
+ }
+ remove
+ {
+ lock(this)
+ {
+ if (_stageContextLostEventHandler != null)
+ {
+ this.ContextLostSignal().Disconnect(_stageContextLostEventCallbackDelegate);
+ }
+
+ _stageContextLostEventHandler -= value;
+ }
+ }
+ }
+
+ // Callback for Stage ContextLostSignal
+ private void OnContextLost()
+ {
+ if (_stageContextLostEventHandler != null)
+ {
+ _stageContextLostEventHandler(this, null);
+ }
+ }
+
+
+ private EventHandler _stageContextRegainedEventHandler;
+ private EventCallbackDelegateType0 _stageContextRegainedEventCallbackDelegate;
+
+ /**
+ * @brief Event for ContextRegained signal which can be used to subscribe/unsubscribe the event handler
+ * provided by the user. ContextRegained signal is emitted when the GL context is regained (Platform specific
+ * behaviour).
+ *
+ */
+ public event EventHandler ContextRegained
+ {
+ add
+ {
+ lock(this)
+ {
+ _stageContextRegainedEventHandler += value;
+ _stageContextRegainedEventCallbackDelegate = OnContextRegained;
+ this.ContextRegainedSignal().Connect(_stageContextRegainedEventCallbackDelegate);
+ }
+ }
+ remove
+ {
+ lock(this)
+ {
+ if (_stageContextRegainedEventHandler != null)
+ {
+ this.ContextRegainedSignal().Disconnect(_stageContextRegainedEventCallbackDelegate);
+ }
+
+ _stageContextRegainedEventHandler -= value;
+ }
+ }
+ }
+
+ // Callback for Stage ContextRegainedSignal
+ private void OnContextRegained()
+ {
+ if (_stageContextRegainedEventHandler != null)
+ {
+ _stageContextRegainedEventHandler(this, null);
+ }
+ }
+
+
+ private EventHandler _stageSceneCreatedEventHandler;
+ private EventCallbackDelegateType0 _stageSceneCreatedEventCallbackDelegate;
+
+ /**
+ * @brief Event for SceneCreated signal which can be used to subscribe/unsubscribe the event handler
+ * SceneCreated signal is emitted after the initial scene is created.
+ *
+ */
+ public event EventHandler SceneCreated
+ {
+ add
+ {
+ lock(this)
+ {
+ _stageSceneCreatedEventHandler += value;
+ _stageSceneCreatedEventCallbackDelegate = OnSceneCreated;
+ this.SceneCreatedSignal().Connect(_stageSceneCreatedEventCallbackDelegate);
+ }
+ }
+ remove
+ {
+ lock(this)
+ {
+ if (_stageSceneCreatedEventHandler != null)
+ {
+ this.SceneCreatedSignal().Disconnect(_stageSceneCreatedEventCallbackDelegate);
+ }
+
+ _stageSceneCreatedEventHandler -= value;
+ }
+ }
+ }
+
+ // Callback for Stage SceneCreatedSignal
+ private void OnSceneCreated()
+ {
+ if (_stageSceneCreatedEventHandler != null)
+ {
+ _stageSceneCreatedEventHandler(this, null);
+ }
+ }
+
+
+ public Vector2 Size
+ {
+ get
+ {
+ Vector2 ret = GetSize();
+ return ret;
+ }
+ }
+
+ public Vector4 BackgroundColor
+ {
+ set
+ {
+ SetBackgroundColor(value);
+ }
+ get
+ {
+ Vector4 ret = GetBackgroundColor();
+ return ret;
+ }
+ }
+
}
}