TextLabel topLabel = new TextLabel();
topLabel.WidthResizePolicy = ResizePolicyType.FillToParent;
topLabel.HeightResizePolicy = ResizePolicyType.SizeRelativeToParent;
- topLabel.PivotPoint = AnchorPoint.TopCenter;
+ topLabel.PivotPoint = PivotPoint.TopCenter;
topLabel.SetSizeModeFactor(new Vector3(0.0f, 0.1f, 0.0f));
topLabel.BackgroundColor = new Color(43.0f / 255.0f, 145.0f / 255.0f, 175.0f / 255.0f, 1.0f);
topLabel.TextColor = Color.White;
topLabel.HorizontalAlignment = HorizontalAlignment.Begin;
topLabel.VerticalAlignment = VerticalAlignment.Center;
topLabel.PointSize = 42.0f;
- _window.GetDefaultLayer().Add(topLabel);
+ _window.Add(topLabel);
//StyleManager.Get().ApplyStyle(topLabel, _resPath + "/json/control-dashboard-theme.json", "TextFieldFontSize4");
topLabel.SetStyleName("TextFieldFontSize4");
_contentContainer.WidthResizePolicy = ResizePolicyType.FillToParent;
_contentContainer.HeightResizePolicy = ResizePolicyType.SizeRelativeToParent;
_contentContainer.SetSizeModeFactor(new Vector3(0.0f, 0.9f, 0.0f));
- _contentContainer.PivotPoint = AnchorPoint.BottomCenter;
+ _contentContainer.PivotPoint = PivotPoint.BottomCenter;
_contentContainer.Position = new Position(0, _window.Size.Height * 0.1f, 0);
_contentContainer.SetRelativeHeight(0, 0.07f);
_contentContainer.SetRelativeHeight(1, 0.26f);
_contentContainer.SetRelativeHeight(4, 0.07f);
_contentContainer.SetRelativeHeight(5, 0.26f);
_contentContainer.Focusable = (true);
- _window.GetDefaultLayer().Add(_contentContainer);
+ _window.Add(_contentContainer);
CreateContent();
{
PushButton button = new PushButton();
button.LabelText = "Popup";
- button.PivotPoint = AnchorPoint.Center;
+ button.PivotPoint = PivotPoint.Center;
button.MaximumSize = new Size2D(150, 100);
_popup = CreatePopup();
_popup.SetTitle(CreateTitle("Popup"));
button.Clicked += (obj, ee) =>
{
- _window.GetDefaultLayer().Add(_popup);
+ _window.Add(_popup);
_popup.SetDisplayState(Popup.DisplayStateType.Shown);
FocusManager.Instance.SetCurrentFocusView(View.DownCast((_popup.FindChildByName("Footer")).FindChildByName("OKButton")));
return true;
{
PushButton button = new PushButton();
button.LabelText = "Toast";
- button.PivotPoint = AnchorPoint.Center;
+ button.PivotPoint = PivotPoint.Center;
button.Clicked += (obj, ee) =>
{
- TypeInfo typeInfo = new TypeInfo(TypeRegistry.Get().GetTypeInfo("PopupToast"));
- if (typeInfo)
- {
- BaseHandle baseHandle = typeInfo.CreateInstance();
- if (baseHandle)
- {
- Popup toast = Popup.DownCast(baseHandle);
- TextLabel text = new TextLabel("This is a Toast.\nIt will auto-hide itself");
- text.TextColor = Color.White;
- text.MultiLine = true;
- text.HorizontalAlignment = HorizontalAlignment.Center;
- toast.SetTitle(text);
- _window.GetDefaultLayer().Add(toast);
- toast.SetDisplayState(Popup.DisplayStateType.Shown);
- }
- }
+ Popup toast = new Popup();
+ toast.SizeModeFactor = new Vector3(0.75f, 0.75f, 0.75f);
+ toast.WidthResizePolicy = ResizePolicyType.SizeRelativeToParent;
+ toast.HeightResizePolicy = ResizePolicyType.UseNaturalSize;
+ toast.ContextualMode = Popup.ContextualModeType.NonContextual;
+ toast.AnimationDuration = 0.65f;
+ toast.TailVisibility = false;
+
+ // Disable the dimmed backing.
+ toast.BackingEnabled = false;
+
+ // The toast popup should fade in (not zoom).
+ toast.AnimationMode = Popup.AnimationModeType.Fade;
+
+ // The toast popup should auto-hide.
+ toast.AutoHideDelay = 3000;
+
+ // Align to the bottom of the screen.
+ toast.ParentOrigin = new Position(0.5f, 0.94f, 0.5f);
+ toast.PivotPoint = PivotPoint.BottomCenter;
+
+ // Let events pass through the toast popup.
+ toast.TouchTransparent = true;
+
+ TextLabel text = new TextLabel("This is a Toast.\nIt will auto-hide itself");
+ text.TextColor = Color.White;
+ text.MultiLine = true;
+ text.HorizontalAlignment = HorizontalAlignment.Center;
+ toast.SetTitle(text);
+ _window.Add(toast);
+ toast.DisplayState = Popup.DisplayStateType.Shown;
+
return true;
};
_contentContainer.AddChild(button, new TableView.CellPosition(((uint)idx / 5) * 2 + 1, (uint)idx % 5));
footer.WidthResizePolicy = ResizePolicyType.FillToParent;
footer.HeightResizePolicy = ResizePolicyType.Fixed;
footer.Size = new Size(0.0f, 80.0f, 0.0f);
- footer.PivotPoint = AnchorPoint.Center;
+ footer.PivotPoint = PivotPoint.Center;
PushButton okButton = CreateOKButton();
- okButton.PivotPoint = AnchorPoint.Center;
+ okButton.PivotPoint = PivotPoint.Center;
okButton.WidthResizePolicy = ResizePolicyType.SizeFixedOffsetFromParent;
okButton.HeightResizePolicy = ResizePolicyType.SizeFixedOffsetFromParent;
okButton.SetSizeModeFactor(new Vector3(-20.0f, -20.0f, 0.0f));
PushButton cancelButton = CreateCancelButton();
- cancelButton.PivotPoint = AnchorPoint.Center;
+ cancelButton.PivotPoint = PivotPoint.Center;
cancelButton.WidthResizePolicy = ResizePolicyType.SizeFixedOffsetFromParent;
cancelButton.HeightResizePolicy = ResizePolicyType.SizeFixedOffsetFromParent;
cancelButton.SetSizeModeFactor(new Vector3(-20.0f, -20.0f, 0.0f));
TableView controlLayout = new TableView(1, 2);
- controlLayout.PivotPoint = AnchorPoint.Center;
+ controlLayout.PivotPoint = PivotPoint.Center;
controlLayout.WidthResizePolicy = ResizePolicyType.FillToParent;
controlLayout.HeightResizePolicy = ResizePolicyType.FillToParent;
controlLayout.SetCellPadding(new Size2D(10, 10));
FlexContainer container = new FlexContainer();
container.ParentOrigin = ParentOrigin.TopLeft;
- container.PivotPoint = AnchorPoint.TopLeft;
+ container.PivotPoint = PivotPoint.TopLeft;
container.FlexDirection = (int)FlexContainer.FlexDirectionType.Column;
container.WidthResizePolicy = ResizePolicyType.FillToParent;
container.HeightResizePolicy = ResizePolicyType.FillToParent;
- window.GetDefaultLayer().Add(container);
+ window.Add(container);
Random random = new Random();
// Create a container to layout the image and rating (in each row) horizontally
FlexContainer imageRow = new FlexContainer();
imageRow.ParentOrigin = ParentOrigin.TopLeft;
- imageRow.PivotPoint = AnchorPoint.TopLeft;
+ imageRow.PivotPoint = PivotPoint.TopLeft;
imageRow.FlexDirection = FlexContainer.FlexDirectionType.Row;
imageRow.Flex = 1.0f;
container.Add(imageRow);
// Add the rating control to the row
view.ParentOrigin = ParentOrigin.Center;
- view.PivotPoint = AnchorPoint.Center;
+ view.PivotPoint = PivotPoint.Center;
view.Size = new Vector3(200.0f, 40.0f, 0.0f);
view.Flex = 0.7f;
view.AlignSelf = (int)FlexContainer.Alignment.AlignCenter;
window.BackgroundColor = Color.White;
Size windowSize = new Size(window.Size.Width, window.Size.Height, 0.0f);
Tizen.Log.Debug("NUI", "Window size: " + windowSize.Width + ", " + windowSize.Height);
- window.GetDefaultLayer().Add(view);
+ window.Add(view);
TextLabel text = new TextLabel("Hello Mono World");
text.ParentOrigin = ParentOrigin.Center;
- text.PivotPoint = AnchorPoint.Center;
+ text.PivotPoint = PivotPoint.Center;
text.HorizontalAlignment = HorizontalAlignment.Center;
- window.GetDefaultLayer().Add(text);
+ window.Add(text);
Tizen.Log.Debug("NUI", "Text label text: " + text.Text );
downView = new View();
downView.Name = "downView";
- Window.Instance.GetDefaultLayer().Add(leftView);
- Window.Instance.GetDefaultLayer().Add(rightView);
- Window.Instance.GetDefaultLayer().Add(upView);
- Window.Instance.GetDefaultLayer().Add(downView);
+ Window.Instance.Add(leftView);
+ Window.Instance.Add(rightView);
+ Window.Instance.Add(upView);
+ Window.Instance.Add(downView);
view.LeftFocusableView = leftView;
tmpView = view.LeftFocusableView;
Tizen.Log.Debug("NUI", "Failed: RightFocusedView = " + tmpView.Name);
}
- Window.Instance.GetDefaultLayer().Add(view);
+ Window.Instance.Add(view);
view.UpFocusableView = upView;
tmpView = view.UpFocusableView;
Tizen.Log.Debug("NUI", "Failed: DownFocusedView = " + tmpView.Name);
}
- Window.Instance.GetDefaultLayer().Remove(leftView);
+ Window.Instance.Remove(leftView);
tmpView = view.LeftFocusableView;
if (!tmpView)
{
label.TextColor = Color.Red;
label.PointSize = 30.0f;
label.ParentOrigin = ParentOrigin.TopLeft;
- label.PivotPoint = AnchorPoint.TopLeft;
+ label.PivotPoint = PivotPoint.TopLeft;
label.Position = new Position(0.0f, 50.0f, 0.0f);
- Window.Instance.GetDefaultLayer().Add(label);
+ Window.Instance.Add(label);
label.VisibilityChanged += (sender, e) =>
{
if (e.Visibility)
PushButton button = new PushButton();
button.LabelText = "Change Visibility";
button.ParentOrigin = ParentOrigin.TopLeft;
- button.PivotPoint = AnchorPoint.TopLeft;
- Window.Instance.GetDefaultLayer().Add(button);
+ button.PivotPoint = PivotPoint.TopLeft;
+ Window.Instance.Add(button);
button.Clicked += (sender, e) =>
{
if (label.Visible)
image.ResourceUrl = _resPath + "/images/dog-anim.gif";
image.Size2D = new Size2D(150, 150);
image.ParentOrigin = ParentOrigin.TopLeft;
- image.PivotPoint = AnchorPoint.TopLeft;
+ image.PivotPoint = PivotPoint.TopLeft;
image.Position = new Position(0.0f, 150.0f, 0.0f);
image.ResourceReady += (sender, e) =>
{
Tizen.Log.Debug("NUI", "Resource is ready!");
};
- Window.Instance.GetDefaultLayer().Add(image);
+ Window.Instance.Add(image);
}
public void WindowDevelPropertyTest()
background = spin.Background;
Color backgroundColor = new Color();
- background.Find(ColorVisualProperty.MixColor).Get(backgroundColor);
+ background.Find(ColorVisualProperty.MixColor, "mixColor")?.Get(backgroundColor);
if( backgroundColor == Color.Red )
{
Tizen.Log.Debug("NUI", "Custom View Background property : test passed");
{
View container = new View();
container.Position = new Position(-800.0f, -800.0f, 0.0f);
- Window.Instance.GetDefaultLayer().Add(container);
- Tizen.Log.Debug("NUI", "winow layer count is "+Window.Instance.GetLayerCount());
+ Window.Instance.Add(container);
+ Tizen.Log.Debug("NUI", "winow layer count is "+Window.Instance.LayerCount);
Tizen.Log.Debug("NUI", "winow default layer child at 0 is "+Window.Instance.GetDefaultLayer().GetChildAt(0));
// Test downcast for native control
TextLabel myLabel = new TextLabel();
parent.Add(childs[i]);
}
- for (uint i = 0; i < parent.GetChildCount(); i++)
+ for (uint i = 0; i < parent.ChildCount; i++)
{
View child = parent.GetChildAt(i);
View childView = View.DownCast<View>(child);
button.BackgroundColor = Color.White;
View parentView = new View();
parentView.Add(button);
- PushButton view = PushButton.DownCast(parentView.GetChildAt(0));
+ PushButton view = parentView.GetChildAt(0) as PushButton;
if (view)
{
Tizen.Log.Debug("NUI", "NUI view GetTypeName= " + view.GetTypeName());
View actorTree = View.DownCast( handle );
- window.GetDefaultLayer().Add( actorTree );
+ window.Add( actorTree );
View year = actorTree.FindChildByName("Year");
View month = actorTree.FindChildByName("Month" );
private Spin _spinMonth; // spin control for month
private Spin _spinDay; // spin control for day
- private ImfManager _imfMgr;
- private TextField _textField;
- private PushButton _pushButton;
- public bool _toggle;
-
public Example() : base()
{
_container = new FlexContainer();
//_container.ParentOrigin = ParentOrigin.Center;
- _container.PivotPoint = AnchorPoint.Center;
+ _container.PivotPoint = PivotPoint.Center;
_container.FlexDirection = FlexContainer.FlexDirectionType.Row;
_container.Size = new Vector3(480.0f, 150.0f, 0.0f);
_container.Position2D = new Position2D(400, 400);
- window.GetDefaultLayer().Add(_container);
+ window.Add(_container);
// Create a Spin control for year
_spinYear = new Spin();
- _spinYear.PivotPoint = AnchorPoint.Center;
+ _spinYear.PivotPoint = PivotPoint.Center;
_spinYear.Flex = 0.3f;
_spinYear.FlexMargin = new Vector4(5.0f, 0.0f, 5.0f, 0.0f);
_container.Add(_spinYear);
// Create a Spin control for month
_spinMonth = new Spin();
- _spinMonth.PivotPoint = AnchorPoint.Center;
+ _spinMonth.PivotPoint = PivotPoint.Center;
_spinMonth.Flex = 0.3f;
_spinMonth.FlexMargin = new Vector4(5.0f, 0.0f, 5.0f, 0.0f);
_container.Add(_spinMonth);
// Create a Spin control for day
_spinDay = new Spin();
- _spinDay.PivotPoint = AnchorPoint.Center;
+ _spinDay.PivotPoint = PivotPoint.Center;
_spinDay.Flex = 0.3f;
_spinDay.FlexMargin = new Vector4(5.0f, 0.0f, 5.0f, 0.0f);
_container.Add(_spinDay);
FocusManager keyboardFocusManager = FocusManager.Instance;
keyboardFocusManager.PreFocusChange += OnKeyboardPreFocusChange;
keyboardFocusManager.FocusedViewActivated += OnFocusedViewActivated;
-
- ////////////////////////////////////////////////////////////////////////
- _imfMgr = ImfManager.Get();
- _imfMgr.ImfManagerActivated += _imfMgr_ImfManagerActivated;
-
- _textField = new TextField();
- _textField.Position2D = new Position2D(100, 100);
- _textField.Size2D = new Size2D(900, 100);
- _textField.Text = "imf manager test!";
- _textField.BackgroundColor = Color.Blue;
- _textField.TextColor = Color.White;
- window.GetDefaultLayer().Add(_textField);
-
- keyboardFocusManager.SetCurrentFocusView(_textField);
-
- _pushButton = new PushButton();
- _pushButton.Position2D = new Position2D(100, 210);
- _pushButton.Size2D = new Size2D(900, 100);
- _pushButton.LabelText = "imf activate";
- _pushButton.Clicked += _pushButton_Clicked;
- window.GetDefaultLayer().Add(_pushButton);
- }
-
- private bool _pushButton_Clicked(object source, EventArgs e)
- {
- Tizen.Log.Fatal("NUI", "_pushButton_Clicked event comes!");
-
- if (_toggle)
- {
- _imfMgr.Activate();
- _pushButton.LabelText = "imf activated";
- _toggle = false;
- }
- else
- {
- _imfMgr.Deactivate();
- _pushButton.LabelText = "imf deactivated";
- _toggle = true;
- }
- return true;
- }
-
- private void _imfMgr_ImfManagerActivated(object sender, ImfManager.ImfManagerActivatedEventArgs e)
- {
- Tizen.Log.Fatal("NUI", "_imfMgr_ImfManagerActivated event comes!");
}
private View OnKeyboardPreFocusChange(object source, FocusManager.PreFocusChangeEventArgs e)
private void OnFocusedViewActivated(object source, FocusManager.FocusedViewEnterKeyEventArgs e)
{
- // Make the text field in the current focused spin to take the key input
- KeyInputFocusManager manager = KeyInputFocusManager.Get();
- if (e.View == _spinYear.SpinText)
- {
- if (manager.GetCurrentFocusControl() != _spinYear.SpinText)
- {
- manager.SetFocus(_spinYear.SpinText);
- }
- }
- else if (e.View == _spinMonth.SpinText)
- {
- if (manager.GetCurrentFocusControl() != _spinMonth.SpinText)
- {
- manager.SetFocus(_spinMonth.SpinText);
- }
- }
- else if (e.View == _spinDay.SpinText)
- {
- if (manager.GetCurrentFocusControl() != _spinDay.SpinText)
- {
- manager.SetFocus(_spinDay.SpinText);
- }
- }
}
/// <summary>
container = new FlexContainer();
container.Size = new Size(Window.Instance.Size.Width, Window.Instance.Size.Height, 0);
- container.PivotPoint = AnchorPoint.TopLeft;
+ container.PivotPoint = PivotPoint.TopLeft;
container.Padding = new Vector4(100, 100, 100, 100);
container.FlexWrap = FlexContainer.WrapType.Wrap;
container.FlexDirection = FlexContainer.FlexDirectionType.Column;
- Window.Instance.GetDefaultLayer().Add(container);
+ Window.Instance.Add(container);
numOfSamples = samples.GetLength(0);
Tizen.Log.Debug("NUI", "NUM = " + numOfSamples);
pushButton1.MinimumSize = new Size2D(400, 200);
pushButton1.LabelText = "+PreFocusChange";
pushButton1.ParentOrigin = ParentOrigin.TopLeft;
- pushButton1.PivotPoint = AnchorPoint.TopLeft;
+ pushButton1.PivotPoint = PivotPoint.TopLeft;
pushButton1.Position2D = new Position2D(200, 800);
pushButton1.Clicked += (sender, e) =>
{
pushButton2.LabelText = "Remove Handler" + _cnt;
return true;
};
- Window.Instance.GetDefaultLayer().Add(pushButton1);
+ Window.Instance.Add(pushButton1);
pushButton2 = new PushButton();
pushButton2.MinimumSize = new Size2D(400, 200);
pushButton2.LabelText = "-PreFocusChange";
pushButton2.ParentOrigin = ParentOrigin.TopLeft;
- pushButton2.PivotPoint = AnchorPoint.TopLeft;
+ pushButton2.PivotPoint = PivotPoint.TopLeft;
pushButton2.Position2D = new Position2D(800, 800);
pushButton2.Clicked += (sender, e) =>
{
pushButton2.LabelText = "Remove Handler" + _cnt;
return true;
};
- Window.Instance.GetDefaultLayer().Add(pushButton2);
+ Window.Instance.Add(pushButton2);
//added
_ani = new Animation(2000);
// Add a _text label to the window
_text = new TextLabel("Hello Mono World");
_text.ParentOrigin = ParentOrigin.Center;
- _text.PivotPoint = AnchorPoint.Center;
+ _text.PivotPoint = PivotPoint.Center;
_text.HorizontalAlignment = HorizontalAlignment.Center;
_text.PointSize = 32.0f;
- _window.GetDefaultLayer().Add(_text);
+ _window.Add(_text);
}
// Callback for _animation finished signal handling
TextLabel pixelLabel = new TextLabel("Test Pixel Size 32.0f");
pixelLabel.Position2D = new Position2D(10, 10);
pixelLabel.PixelSize = 32.0f;
- window.GetDefaultLayer().Add(pixelLabel);
+ window.Add(pixelLabel);
TextLabel pointLabel = new TextLabel("Test Point Size 32.0f");
pointLabel.Position2D = new Position2D(10, 100);
pointLabel.PointSize = 32.0f;
- window.GetDefaultLayer().Add(pointLabel);
+ window.Add(pointLabel);
TextLabel ellipsis = new TextLabel("Ellipsis of TextLabel is enabled.");
ellipsis.Size2D = new Size2D(100, 100);
ellipsis.Position2D = new Position2D(10, 250);
ellipsis.PointSize = 20.0f;
ellipsis.Ellipsis = true;
- window.GetDefaultLayer().Add(ellipsis);
+ window.Add(ellipsis);
TextLabel autoScrollStopMode = new TextLabel("AutoScrollStopMode is finish-loop.");
autoScrollStopMode.Size2D = new Size2D(400, 100);
autoScrollStopMode.AutoScrollStopMode = AutoScrollStopMode.FinishLoop;
//autoScrollStopMode.AutoScrollLoopDelay = 10.0f;
autoScrollStopMode.EnableAutoScroll = true;
- window.GetDefaultLayer().Add(autoScrollStopMode);
+ window.Add(autoScrollStopMode);
_text = new TextLabel("Hello NUI World");
_text.ParentOrigin = ParentOrigin.Center;
- _text.PivotPoint = AnchorPoint.Center;
+ _text.PivotPoint = PivotPoint.Center;
_text.HorizontalAlignment = HorizontalAlignment.Center;
_text.PointSize = 32.0f;
_text.TextColor = Color.Magenta;
- window.GetDefaultLayer().Add(_text);
+ window.Add(_text);
_view = new View();
_view.Size = new Size(100, 100, 100);
_imageView.ResourceUrl = resources+"/images/00_popup_bg.9.png";
//_imageView.Border = new Rectangle(100, 100, 100, 100);
_imageView.ParentOrigin = ParentOrigin.TopLeft;
- _imageView.PivotPoint = AnchorPoint.TopLeft;
+ _imageView.PivotPoint = PivotPoint.TopLeft;
_imageView.Position = new Position(5.0f, 5.0f, 0.0f);
_imageView.PixelArea = new Vector4(0.0f, 0.0f, 0.5f, 0.5f);
_imageView.Size = new Size(200.0f, 80.0f, 0.0f);
_pushButton1 = new PushButton();
_pushButton1.ParentOrigin = ParentOrigin.BottomLeft;
- _pushButton1.PivotPoint = AnchorPoint.BottomLeft;
+ _pushButton1.PivotPoint = PivotPoint.BottomLeft;
_pushButton1.LabelText = "start animation";
_pushButton1.Position = new Vector3(0.0f, window.Size.Height * 0.1f, 0.0f);
_pushButton1.Clicked += OnPushButtonClicked1;
_pushButton2 = new PushButton();
_pushButton2.ParentOrigin = ParentOrigin.BottomLeft;
- _pushButton2.PivotPoint = AnchorPoint.BottomLeft;
+ _pushButton2.PivotPoint = PivotPoint.BottomLeft;
_pushButton2.LabelText = "reload image with same URL";
_pushButton2.Position = new Vector3(0.0f, window.Size.Height * 0.2f, 0.0f);
_pushButton2.Clicked += OnPushButtonClicked2;
ImageView syncImage = new ImageView();
syncImage.ParentOrigin = ParentOrigin.CenterLeft;
- syncImage.PivotPoint = AnchorPoint.CenterLeft;
+ syncImage.PivotPoint = PivotPoint.CenterLeft;
syncImage.PositionUsesAnchorPoint = true;
syncImage.Size2D = new Size2D(150, 150);
syncImage.ResourceUrl = resources+"/images/gallery-3.jpg";
_map.Add(NpatchImageVisualProperty.SynchronousLoading, new PropertyValue(true));
ImageView nPatchImage = new ImageView();
nPatchImage.ParentOrigin = ParentOrigin.BottomLeft;
- nPatchImage.PivotPoint = AnchorPoint.BottomLeft;
+ nPatchImage.PivotPoint = PivotPoint.BottomLeft;
nPatchImage.PositionUsesAnchorPoint = true;
nPatchImage.Size = new Size(300.0f, 100.0f, 0.0f);
nPatchImage.ImageMap = _map;
ImageView syncNineImage = new ImageView();
syncNineImage.ParentOrigin = ParentOrigin.CenterLeft;
- syncNineImage.PivotPoint = AnchorPoint.CenterLeft;
+ syncNineImage.PivotPoint = PivotPoint.CenterLeft;
syncNineImage.Position2D = new Position2D(0, 200);
syncNineImage.PositionUsesAnchorPoint = true;
syncNineImage.Size = new Size(150.0f, 150.0f, 0.0f);
_imageView = new ImageView();
_imageView.ResourceUrl = resources+"/images/gallery-3.jpg";
_imageView.ParentOrigin = ParentOrigin.Center;
- _imageView.PivotPoint = AnchorPoint.Center;
+ _imageView.PivotPoint = PivotPoint.Center;
_imageView.PixelArea = new Vector4(0.0f, 0.0f, 0.5f, 0.5f);
//_imageView.SetResizePolicy(ResizePolicyType.USE_NATURAL_SIZE, DimensionType.ALL_DIMENSIONS);
layer.Add(_imageView);
_window = Window.Instance;
_text1 = new TextLabel("PositionUsesAnchorPoint");
_text1.ParentOrigin = ParentOrigin.Center;
- _text1.PivotPoint = AnchorPoint.Center;
+ _text1.PivotPoint = PivotPoint.Center;
_text1.Position = new Position(0, 0, 0);
_text1.PositionUsesAnchorPoint = true;
_text1.HorizontalAlignment = HorizontalAlignment.Center;
_text1.Size2D = new Size2D(200, 100);
_text1.PointSize = 10.0f;
_text1.BackgroundColor = Color.Blue;
- _window.GetDefaultLayer().Add(_text1);
+ _window.Add(_text1);
_text2 = new TextLabel("PositionNotUsesAnchorPoint");
_text2.ParentOrigin = ParentOrigin.Center;
- _text2.PivotPoint = AnchorPoint.Center;
+ _text2.PivotPoint = PivotPoint.Center;
_text2.Position = new Position(0, 0, 0);
_text2.PositionUsesAnchorPoint = false;
_text2.HorizontalAlignment = HorizontalAlignment.Center;
_text2.Size2D = new Size2D(200, 100);
_text2.PointSize = 10.0f;
_text2.BackgroundColor = Color.Red;
- _window.GetDefaultLayer().Add(_text2);
+ _window.Add(_text2);
}
_imageView = new ImageView();
_imageView.ResourceUrl = resources+"/images/gallery-3.jpg";
_imageView.ParentOrigin = ParentOrigin.Center;
- _imageView.PivotPoint = AnchorPoint.Center;
+ _imageView.PivotPoint = PivotPoint.Center;
_imageView.PixelArea = new RelativeVector4(0.0f, 0.0f, 0.0f, 0.0f);
- _window.GetDefaultLayer().Add(_imageView);
+ _window.Add(_imageView);
}
// Callback for window touched signal handling
Size windowSize = new Size(window.Size.Width, window.Size.Height, 0.0f);
_scrollView.Size = new Size(windowSize.Width, windowSize.Height, 0.0f);
_scrollView.ParentOrigin = ParentOrigin.Center;
- _scrollView.PivotPoint = AnchorPoint.Center;
- window.GetDefaultLayer().Add(_scrollView);
+ _scrollView.PivotPoint = PivotPoint.Center;
+ window.Add(_scrollView);
// Add actors to a scroll view with 3 pages
int pageRows = 1;
pageActor.WidthResizePolicy = ResizePolicyType.FillToParent;
pageActor.HeightResizePolicy = ResizePolicyType.FillToParent;
pageActor.ParentOrigin = ParentOrigin.Center;
- pageActor.PivotPoint = AnchorPoint.Center;
+ pageActor.PivotPoint = PivotPoint.Center;
pageActor.Position = new Position(pageColumn * windowSize.Width, pageRow * windowSize.Height, 0.0f);
// Add images in a 3x4 grid layout for each page
int imageId = (row * imageColumns + column) % 2 + 1;
ImageView imageView = new ImageView(resources+"/images/image-" + imageId + ".jpg");
imageView.ParentOrigin = ParentOrigin.Center;
- imageView.PivotPoint = AnchorPoint.Center;
+ imageView.PivotPoint = PivotPoint.Center;
imageView.Size = new Size(imageSize.X, imageSize.Y, imageSize.Z);
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 );
// Create a horizontal scroll bar in the bottom of scroll view (which is optional)
_scrollBar = new ScrollBar(ScrollBar.Direction.Horizontal);
_scrollBar.ParentOrigin = ParentOrigin.BottomLeft;
- _scrollBar.PivotPoint = AnchorPoint.TopLeft;
+ _scrollBar.PivotPoint = PivotPoint.TopLeft;
_scrollBar.WidthResizePolicy = ResizePolicyType.FitToChildren;
_scrollBar.HeightResizePolicy = ResizePolicyType.FillToParent;
_scrollBar.Orientation = new Rotation( new Radian( new Degree( 270.0f ) ), Vector3.ZAxis );
_scrollView.FocusGained += OnKey;
_text = new TextLabel("View Touch Event Handler Test");
_text.ParentOrigin = ParentOrigin.Center;
- _text.PivotPoint = AnchorPoint.Center;
+ _text.PivotPoint = PivotPoint.Center;
_text.HorizontalAlignment = HorizontalAlignment.Center;
_text.PointSize = 20.0f;
_view.LabelText = "view" + i;
_view.MinimumSize = new Size2D(100, 50);
_view.ParentOrigin = ParentOrigin.TopLeft;
- _view.PivotPoint = AnchorPoint.TopLeft;
+ _view.PivotPoint = PivotPoint.TopLeft;
_view.Position2D = _myPos + new Position2D(20 * i, 10 * i);
- _window.GetDefaultLayer().Add(_view);
+ _window.Add(_view);
}
}
_view.LabelText = "view" + i;
_view.MinimumSize = new Size2D(100, 50);
_view.ParentOrigin = ParentOrigin.TopLeft;
- _view.PivotPoint = AnchorPoint.TopLeft;
+ _view.PivotPoint = PivotPoint.TopLeft;
_view.Position2D = _myPos + new Position2D(20 * i, 10 * i);
_view.SiblingOrder = i;
- _window.GetDefaultLayer().Add(_view);
+ _window.Add(_view);
}
}
_view.LabelText = "view" + i;
_view.MinimumSize = new Size2D(100, 50);
_view.ParentOrigin = ParentOrigin.TopLeft;
- _view.PivotPoint = AnchorPoint.TopLeft;
+ _view.PivotPoint = PivotPoint.TopLeft;
_view.Position2D = _myPos + new Position2D(20 * i, 10 * i);
_view.SiblingOrder = 10-i;
- _window.GetDefaultLayer().Add(_view);
+ _window.Add(_view);
}
}
_view.LabelText = "view" + i;
_view.MinimumSize = new Size2D(100, 50);
_view.ParentOrigin = ParentOrigin.TopLeft;
- _view.PivotPoint = AnchorPoint.TopLeft;
+ _view.PivotPoint = PivotPoint.TopLeft;
_view.Position2D = _myPos + new Position2D(20 * i, 10 * i);
if (i<5)
{
_view.SiblingOrder = i-5;
}
- _window.GetDefaultLayer().Add(_view);
+ _window.Add(_view);
}
}
_view.LabelText = "view" + i;
_view.MinimumSize = new Size2D(100, 50);
_view.ParentOrigin = ParentOrigin.TopLeft;
- _view.PivotPoint = AnchorPoint.TopLeft;
+ _view.PivotPoint = PivotPoint.TopLeft;
_view.Position2D = _myPos + new Position2D(20 * i, 10 * i);
if (i<5)
{
_view.SiblingOrder = 10-i;
}
- _window.GetDefaultLayer().Add(_view);
+ _window.Add(_view);
}
}
_view.MinimumSize = new Size2D(100, 50);
_view.LabelText = "sibling" + i;
_view.ParentOrigin = ParentOrigin.TopLeft;
- _view.PivotPoint = AnchorPoint.TopLeft;
+ _view.PivotPoint = PivotPoint.TopLeft;
_view.Position2D = _myPos + new Position2D(20 * i, 10 * i);
_view.Clicked += (sender, ee) =>
{
for (int i = 0; i < 10; i++)
{
- _window.GetDefaultLayer().Add(list_view[i]);
+ _window.Add(list_view[i]);
Tizen.Log.Debug("NUI", list_view[i].Name + "'s sibling order=" + list_view[i].SiblingOrder);
}
_txt.ParentOrigin = ParentOrigin.TopLeft;
- _txt.PivotPoint = AnchorPoint.TopLeft;
+ _txt.PivotPoint = PivotPoint.TopLeft;
_txt.Text = "on top: sibling#, sibling order=?";
_txt.Position2D = _myPos + new Position2D(-50, 200);
_txt.TextColor = Color.Blue;
- _window.GetDefaultLayer().Add(_txt);
+ _window.Add(_txt);
}
VisualTest _visualTest = new VisualTest();
_visualTest.TextVisual = "Hello NUI Text Visual!";
_visualTest.ParentOrigin = ParentOrigin.TopLeft;
- _visualTest.PivotPoint = AnchorPoint.TopLeft;
+ _visualTest.PivotPoint = PivotPoint.TopLeft;
_visualTest.Size2D = new Size2D(600, 200);
_visualTest.Position2D = new Position2D(50, 400);
_visualTest.BackgroundColor = Color.Yellow;
- _window.GetDefaultLayer().Add(_visualTest);
+ _window.Add(_visualTest);
}
catch (Exception e)
{
/* TEST CODE */
View view = new View();
view.ParentOrigin = ParentOrigin.TopLeft;
- view.PivotPoint = AnchorPoint.TopLeft;
+ view.PivotPoint = PivotPoint.TopLeft;
view.MinimumSize = new Size2D(100, 100);
view.BackgroundColor = Color.Red;
- _window.GetDefaultLayer().Add(view);
+ _window.Add(view);
Position position0 = new Position(200.0f, 200.0f, 0.0f);
Position position1 = new Position(300.0f, 300.0f, 0.0f);
/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd.
+* Copyright (c) 2017 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
pixelLabel.Position2D = new Position2D(10, 10);
pixelLabel.PixelSize = 32.0f;
pixelLabel.BackgroundColor = Color.Magenta;
- window.GetDefaultLayer().Add(pixelLabel);
+ window.Add(pixelLabel);
TextLabel pointLabel = new TextLabel("Test Point Size 32.0f");
pointLabel.Position2D = new Position2D(10, 100);
pointLabel.PointSize = 32.0f;
pointLabel.BackgroundColor = Color.Red;
- window.GetDefaultLayer().Add(pointLabel);
+ window.Add(pointLabel);
TextLabel ellipsis = new TextLabel("Ellipsis of TextLabel is enabled.");
ellipsis.Size2D = new Size2D(100, 80);
ellipsis.PointSize = 20.0f;
ellipsis.Ellipsis = true;
ellipsis.BackgroundColor = Color.Cyan;
- window.GetDefaultLayer().Add(ellipsis);
+ window.Add(ellipsis);
TextLabel autoScrollStopMode = new TextLabel("AutoScrollStopMode is finish-loop.");
autoScrollStopMode.Size2D = new Size2D(400, 50);
autoScrollStopMode.BackgroundColor = Color.Green;
autoScrollStopMode.AutoScrollStopMode = AutoScrollStopMode.FinishLoop;
autoScrollStopMode.EnableAutoScroll = true;
- window.GetDefaultLayer().Add(autoScrollStopMode);
+ window.Add(autoScrollStopMode);
TextField field = new TextField();
field.Size2D = new Size2D(400, 100);
hiddenMap.Add(HiddenInputProperty.SubstituteCount, new PropertyValue(4));
hiddenMap.Add(HiddenInputProperty.SubstituteCharacter, new PropertyValue(0x23));
field.HiddenInputSettings = hiddenMap;
- window.GetDefaultLayer().Add(field);
+ window.Add(field);
}
[STAThread]
// Add a _text label to the window
_text = new TextLabel("Hello Mono World");
_text.ParentOrigin = ParentOrigin.BottomCenter;
- _text.PivotPoint = AnchorPoint.BottomCenter;
+ _text.PivotPoint = PivotPoint.BottomCenter;
_text.HorizontalAlignment = HorizontalAlignment.Center;
_text.PointSize = 32.0f;
- window.GetDefaultLayer().Add(_text);
+ window.Add(_text);
_view1 = new View();
_view1.Size = new Vector3(200.0f, 200.0f, 0.0f);
_view1.BackgroundColor = Color.Green;
_view1.ParentOrigin = ParentOrigin.Center;
- _view1.PivotPoint = AnchorPoint.Center;
+ _view1.PivotPoint = PivotPoint.Center;
_view1.WidthResizePolicy = ResizePolicyType.Fixed;
_view1.HeightResizePolicy = ResizePolicyType.Fixed;
_view1.AddedToWindow += OnWindow;
- window.GetDefaultLayer().Add(_view1);
+ window.Add(_view1);
_view2 = new View();
_view2.BackgroundColor = Color.Red;
_view2.Size = new Vector3(50.0f, 50.0f, 0.0f);
_view2.ParentOrigin = ParentOrigin.TopLeft;
- _view2.PivotPoint = AnchorPoint.TopLeft;
+ _view2.PivotPoint = PivotPoint.TopLeft;
_view2.WidthResizePolicy = ResizePolicyType.Fixed;
_view2.HeightResizePolicy = ResizePolicyType.Fixed;
_view1.Add(_view2);
_view3.BackgroundColor = Color.Blue;
_view3.Size = new Vector3(50.0f, 50.0f, 0.0f);
_view3.ParentOrigin = ParentOrigin.TopLeft;
- _view3.PivotPoint = AnchorPoint.TopLeft;
+ _view3.PivotPoint = PivotPoint.TopLeft;
_view3.WidthResizePolicy = ResizePolicyType.Fixed;
_view3.HeightResizePolicy = ResizePolicyType.Fixed;
_view1.Add(_view3);
view[i].Position = new Position(300 + i * 300, 300, 0);
view[i].Name = "MyView" + i;
view[i].Focusable = true;
- Window.Instance.GetDefaultLayer().Add(view[i]);
+ Window.Instance.Add(view[i]);
view[i].FocusGained += FocusNavigationSample_FocusGained;
view[i].FocusLost += FocusNavigationSample_FocusLost;
view[i].Key += FocusNavigationSample_KeyEvent;
TableView titleLayout = new TableView(2, 1);
titleLayout.Name = ("TitleLayout");
- titleLayout.PivotPoint = AnchorPoint.TopLeft;
+ titleLayout.PivotPoint = PivotPoint.TopLeft;
titleLayout.Position2D = new Position2D(10, 10);
titleLayout.Size2D = new Size2D((int)(window.Size.Width * 0.9f), (int)(window.Size.Height * 0.9f));
titleLayout.SetCellPadding(new Size2D(10, 10));
titleLayout.BackgroundColor = Color.Cyan;
- window.GetDefaultLayer().Add(titleLayout);
+ window.Add(titleLayout);
_title = new TextLabel("Visual Transition / SVG / AGIF Example");
_title.Name = ("Title");
contentLayout.Name = ("ContentLayout");
contentLayout.WidthResizePolicy = ResizePolicyType.FillToParent;
contentLayout.HeightResizePolicy = ResizePolicyType.FillToParent;
- contentLayout.PivotPoint = AnchorPoint.TopLeft;
+ contentLayout.PivotPoint = PivotPoint.TopLeft;
contentLayout.SetCellPadding(new Size2D(10, 10));
contentLayout.BackgroundColor = Color.Magenta;
titleLayout.AddChild(contentLayout, new TableView.CellPosition(1, 0));
_shadowButton.LabelText = "Toggle Transition";
_shadowButton.Name = ("ToggleTransition");
_shadowButton.ParentOrigin = ParentOrigin.Center;
- _shadowButton.PivotPoint = AnchorPoint.Center;
+ _shadowButton.PivotPoint = PivotPoint.Center;
_shadowButton.Clicked += (obj, ev) =>
{
_active = !_active;
PushButton svgButton = new PushButton();
svgButton.LabelText = "SVG Visual Test";
svgButton.Name = ("svg_visual_test");
- svgButton.PivotPoint = AnchorPoint.Center;
+ svgButton.PivotPoint = PivotPoint.Center;
svgButton.WidthResizePolicy = ResizePolicyType.FillToParent;
svgButton.HeightResizePolicy = ResizePolicyType.FillToParent;
svgButton.Clicked += (obj, ev) =>
PushButton gifButton = new PushButton();
gifButton.LabelText = "AnimatedImage Visual Test";
gifButton.Name = ("gif_visual_test");
- gifButton.PivotPoint = AnchorPoint.Center;
+ gifButton.PivotPoint = PivotPoint.Center;
gifButton.WidthResizePolicy = ResizePolicyType.FillToParent;
gifButton.HeightResizePolicy = ResizePolicyType.FillToParent;
gifButton.Clicked += (obj, ev) =>
TableView titleLayout = new TableView(2, 1);
titleLayout.Name = ("TitleLayout");
- titleLayout.PivotPoint = AnchorPoint.TopLeft;
+ titleLayout.PivotPoint = PivotPoint.TopLeft;
titleLayout.Position2D = new Position2D(10, 10);
titleLayout.Size2D = new Size2D((int)(window.Size.Width * 0.9f), (int)(window.Size.Height * 0.9f));
titleLayout.SetCellPadding(new Size2D(10, 10));
titleLayout.BackgroundColor = Color.Cyan;
- window.GetDefaultLayer().Add(titleLayout);
+ window.Add(titleLayout);
_title = new TextLabel("Visual Transition Example");
_title.Name = ("Title");
contentLayout.Name = ("ContentLayout");
contentLayout.WidthResizePolicy = ResizePolicyType.FillToParent;
contentLayout.HeightResizePolicy = ResizePolicyType.FillToParent;
- contentLayout.PivotPoint = AnchorPoint.TopLeft;
+ contentLayout.PivotPoint = PivotPoint.TopLeft;
contentLayout.SetCellPadding(new Size2D(10, 10));
contentLayout.BackgroundColor = Color.Magenta;
titleLayout.AddChild(contentLayout, new TableView.CellPosition(1, 0));
_shadowButton1.LabelText = "Toggle Transition Position";
_shadowButton1.Name = ("ToggleTransition");
_shadowButton1.ParentOrigin = ParentOrigin.Center;
- _shadowButton1.PivotPoint = AnchorPoint.Center;
+ _shadowButton1.PivotPoint = PivotPoint.Center;
_shadowButton1.Clicked += (obj, ev) =>
{
_active1 = !_active1;
_shadowButton2.LabelText = "Toggle Transition Opacity";
_shadowButton2.Name = ("ToggleTransition");
_shadowButton2.ParentOrigin = ParentOrigin.Center;
- _shadowButton2.PivotPoint = AnchorPoint.Center;
+ _shadowButton2.PivotPoint = PivotPoint.Center;
_shadowButton2.Clicked += (obj, ev) =>
{
_active2 = !_active2;
_shadowButton3.LabelText = "Toggle Transition MixColor";
_shadowButton3.Name = ("ToggleTransition");
_shadowButton3.ParentOrigin = ParentOrigin.Center;
- _shadowButton3.PivotPoint = AnchorPoint.Center;
+ _shadowButton3.PivotPoint = PivotPoint.Center;
_shadowButton3.Clicked += (obj, ev) =>
{
_active3 = !_active3;
TableView titleLayout = new TableView(2, 1);
titleLayout.Name = ("TitleLayout");
- titleLayout.AnchorPoint = AnchorPoint.TopLeft;
+ titleLayout.PivotPoint = PivotPoint.TopLeft;
titleLayout.Position2D = new Position2D(10, 10);
titleLayout.Size2D = new Size2D((int)(window.Size.Width * 0.9f), (int)(window.Size.Height * 0.9f));
titleLayout.SetCellPadding(new Size2D(10, 10));
titleLayout.BackgroundColor = Color.Cyan;
- window.GetDefaultLayer().Add(titleLayout);
+ window.Add(titleLayout);
_title = new TextLabel("Visual Transition Example");
_title.Name = ("Title");
contentLayout.Name = ("ContentLayout");
contentLayout.WidthResizePolicy = ResizePolicyType.FillToParent;
contentLayout.HeightResizePolicy = ResizePolicyType.FillToParent;
- contentLayout.AnchorPoint = AnchorPoint.TopLeft;
+ contentLayout.PivotPoint = PivotPoint.TopLeft;
contentLayout.SetCellPadding(new Size2D(10, 10));
contentLayout.BackgroundColor = Color.Magenta;
titleLayout.AddChild(contentLayout, new TableView.CellPosition(1, 0));
_shadowButton1.LabelText = "Toggle Transition Position";
_shadowButton1.Name = ("ToggleTransition");
_shadowButton1.ParentOrigin = ParentOrigin.Center;
- _shadowButton1.AnchorPoint = AnchorPoint.Center;
+ _shadowButton1.PivotPoint = PivotPoint.Center;
_shadowButton1.Clicked += (obj, ev) =>
{
_active1 = !_active1;
/* Create a visual view. */
_visualView = new VisualView();
_visualView.ParentOrigin = ParentOrigin.TopLeft;
- _visualView.PivotPoint = AnchorPoint.TopLeft;
+ _visualView.PivotPoint = PivotPoint.TopLeft;
_visualView.Size = new Size(window.Size.Width, window.Size.Height, 0.0f);
/* color visual */
colorVisualMap1.Color = Color.Green;
_visualView.Background = colorVisualMap1.OutputVisualMap;
- window.GetDefaultLayer().Add(_visualView);
+ window.Add(_visualView);
/* image visual 1. */
imageVisualMap1 = new ImageVisual();
view[i].Position = new Position(400 + i * 800, 600, 0);
view[i].Focusable = true;
view[i].Name = "MyView" + i;
- Window.Instance.GetDefaultLayer().Add(view[i]);
+ Window.Instance.Add(view[i]);
view[i].FocusGained += VisualSample_FocusGained;
view[i].FocusLost += VisualSample_FocusLost;
view[i].Key += VisualSample_KeyEvent;
guide = new TextLabel();
- guide.PivotPoint = AnchorPoint.TopLeft;
+ guide.PivotPoint = PivotPoint.TopLeft;
guide.Size2D = new Size2D(800, 200);
guide.Padding = new Vector4(50, 50, 50, 50);
guide.MultiLine = true;
guide.Text = "Left/Right - Move focus\n" +
"Up/Down - Change Text\n" +
"Enter - Change BG image\n";
- Window.Instance.GetDefaultLayer().Add(guide);
+ Window.Instance.Add(guide);
Window.Instance.KeyEvent += Instance_Key;
FocusManager.Instance.SetCurrentFocusView(view[0]);
/* Create a visual view. */
_visualView = new VisualView();
_visualView.ParentOrigin = ParentOrigin.TopLeft;
- _visualView.PivotPoint = AnchorPoint.TopLeft;
+ _visualView.PivotPoint = PivotPoint.TopLeft;
_visualView.Size = new Size(window.Size.Width, window.Size.Height, 0.0f);
/* color visual */
colorVisualMap1.Color = Color.Green;
_visualView.Background = colorVisualMap1.OutputVisualMap;
- window.GetDefaultLayer().Add(_visualView);
+ window.Add(_visualView);
/* image visual 1. No transform setting case. */
imageVisualMap1 = new ImageVisual();
imageVisualMap1.URL = resources + "/images/image-1.jpg";
- imageVisualMap1.DepthIndex = 1.0f;
+ imageVisualMap1.DepthIndex = 1;
//_visualView.AddVisual("imageVisual1", imageVisualMap1);
/* image visual 2. Using RelativePosition and SizePolicyWidth setting case. */
imageVisualMap2.Origin = Visual.AlignType.TopBegin;
imageVisualMap2.AnchorPoint = Visual.AlignType.TopBegin;
/* Ensure imageVisual show */
- imageVisualMap2.DepthIndex = 9.0f;
+ imageVisualMap2.DepthIndex = 9;
_visualView.AddVisual("imageVisual2", imageVisualMap2);
/* If imageVisual2 added first, the it will be covered by imageVisual1.
so, we need to set their depth index to ensure they all can be showed.
contentLayout.SetCellPadding(new Size2D(0, 5));
contentLayout.BackgroundColor = Color.Red;//new Color(0.949f, 0.949f, 0.949f, 1.0f);
- window.GetDefaultLayer().Add(contentLayout);
+ window.Add(contentLayout);
_title = new TextLabel("Visuals Example");
_title.Name = "Title";
contentLayout.Name = "ContentLayout";
//contentLayout.WidthResizePolicy = ResizePolicyType.FillToParent;
//contentLayout.HeightResizePolicy = ResizePolicyType.FillToParent;
- contentLayout.PivotPoint = AnchorPoint.Center;
+ contentLayout.PivotPoint = PivotPoint.Center;
contentLayout.ParentOrigin = ParentOrigin.Center;
contentLayout.Size = new Vector3(window.Size.Width, window.Size.Height, 0.0f);
contentLayout.SetCellPadding(new Size2D(5, 5));
contentLayout.BackgroundColor = new Color(0.949f, 0.949f, 0.949f, 1.0f);
- window.GetDefaultLayer().Add(contentLayout);
+ window.Add(contentLayout);
TextLabel title = new TextLabel("Contacts List with Visuals");
title.Name = "Title";
internal static readonly int GRADIENT_VISUAL_SPREAD_METHOD = NDalicPINVOKE.GRADIENT_VISUAL_SPREAD_METHOD_get();
internal static readonly int IMAGE_VISUAL_URL = NDalicPINVOKE.IMAGE_VISUAL_URL_get();
+ internal static readonly int IMAGE_VISUAL_ALPHA_MASK_URL = NDalicPINVOKE.IMAGE_VISUAL_ALPHA_MASK_URL_get();
internal static readonly int IMAGE_VISUAL_FITTING_MODE = NDalicPINVOKE.IMAGE_VISUAL_FITTING_MODE_get();
internal static readonly int IMAGE_VISUAL_SAMPLING_MODE = NDalicPINVOKE.IMAGE_VISUAL_SAMPLING_MODE_get();
internal static readonly int IMAGE_VISUAL_DESIRED_WIDTH = NDalicPINVOKE.IMAGE_VISUAL_DESIRED_WIDTH_get();
public static extern void SWIGRegisterExceptionCallbacks_NDalic(
ExceptionDelegate applicationDelegate,
ExceptionDelegate arithmeticDelegate,
- ExceptionDelegate divideByZeroDelegate,
- ExceptionDelegate indexOutOfRangeDelegate,
+ ExceptionDelegate divideByZeroDelegate,
+ ExceptionDelegate indexOutOfRangeDelegate,
ExceptionDelegate invalidCastDelegate,
ExceptionDelegate invalidOperationDelegate,
ExceptionDelegate ioDelegate,
ExceptionDelegate nullReferenceDelegate,
- ExceptionDelegate outOfMemoryDelegate,
- ExceptionDelegate overflowDelegate,
+ ExceptionDelegate outOfMemoryDelegate,
+ ExceptionDelegate overflowDelegate,
ExceptionDelegate systemExceptionDelegate);
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="SWIGRegisterExceptionArgumentCallbacks_NDalic")]
if (pendingException != null)
pending = true;
return pending;
- }
+ }
}
public static void Set(global::System.Exception e) {
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_Animation_Clear")]
public static extern void Animation_Clear(global::System.Runtime.InteropServices.HandleRef jarg1);
+ [global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_Animation_SetProgressNotification")]
+ public static extern void Animation_SetProgressNotification(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
+
+ [global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_Animation_GetProgressNotification")]
+ public static extern float Animation_GetProgressNotification(global::System.Runtime.InteropServices.HandleRef jarg1);
+
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_Animation_FinishedSignal")]
public static extern global::System.IntPtr Animation_FinishedSignal(global::System.Runtime.InteropServices.HandleRef jarg1);
+ [global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_Animation_ProgressReachedSignal")]
+ public static extern global::System.IntPtr Animation_ProgressReachedSignal(global::System.Runtime.InteropServices.HandleRef jarg1);
+
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_Animation_AnimateBy__SWIG_0")]
public static extern void Animation_AnimateBy__SWIG_0(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3);
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_IMAGE_VISUAL_URL_get")]
public static extern int IMAGE_VISUAL_URL_get();
+ [global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_IMAGE_VISUAL_ALPHA_MASK_URL_get")]
+ public static extern int IMAGE_VISUAL_ALPHA_MASK_URL_get();
+
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_IMAGE_VISUAL_FITTING_MODE_get")]
public static extern int IMAGE_VISUAL_FITTING_MODE_get();
public static extern void VisualBase_GetNaturalSize(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_VisualBase_SetDepthIndex")]
- public static extern void VisualBase_SetDepthIndex(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
+ public static extern void VisualBase_SetDepthIndex(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_VisualBase_GetDepthIndex")]
- public static extern float VisualBase_GetDepthIndex(global::System.Runtime.InteropServices.HandleRef jarg1);
+ public static extern int VisualBase_GetDepthIndex(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("libdali-csharp-binder.so", EntryPoint="CSharp_Dali_VisualBase_CreatePropertyMap")]
public static extern void VisualBase_CreatePropertyMap(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+++ /dev/null
-/** Copyright (c) 2017 Samsung Electronics Co., Ltd.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*
-*/
-// This File has been auto-generated by SWIG and then modified using DALi Ruby Scripts
-//------------------------------------------------------------------------------
-// <auto-generated />
-//
-// This file was automatically generated by SWIG (http://www.swig.org).
-// Version 3.0.9
-//
-// Do not make changes to this file unless you know what you are doing--modify
-// the SWIG interface file instead.
-//------------------------------------------------------------------------------
-
-namespace Tizen.NUI
-{
-
- internal class Shader : Animatable
- {
- private global::System.Runtime.InteropServices.HandleRef swigCPtr;
-
- internal Shader(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.Shader_SWIGUpcast(cPtr), cMemoryOwn)
- {
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
- }
-
- internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Shader obj)
- {
- return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
- }
-
- protected override void Dispose(DisposeTypes type)
- {
- if (disposed)
- {
- return;
- }
-
- if (type == DisposeTypes.Explicit)
- {
- //Called by User
- //Release your own managed resources here.
- //You should release all of your own disposable objects here.
-
- }
-
- //Release your own unmanaged resources here.
- //You should not access any managed member here except static instance.
- //because the execution order of Finalizes is non-deterministic.
-
- if (swigCPtr.Handle != global::System.IntPtr.Zero)
- {
- if (swigCMemOwn)
- {
- swigCMemOwn = false;
- NDalicPINVOKE.delete_Shader(swigCPtr);
- }
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
- }
-
- base.Dispose(type);
- }
-
-
- public class Hint : global::System.IDisposable
- {
- private global::System.Runtime.InteropServices.HandleRef swigCPtr;
- protected bool swigCMemOwn;
-
- internal Hint(global::System.IntPtr cPtr, bool cMemoryOwn)
- {
- swigCMemOwn = cMemoryOwn;
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
- }
-
- internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Hint obj)
- {
- return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
- }
-
- //A Flag to check who called Dispose(). (By User or DisposeQueue)\r
- private bool isDisposeQueued = false;\r
- //A Flat to check if it is already disposed.\r
- protected bool disposed = false;
-
- ~Hint()\r
- {\r
- if (!isDisposeQueued)\r
- {\r
- isDisposeQueued = true;\r
- DisposeQueue.Instance.Add(this);\r
- }\r
- }\r
-\r
- public void Dispose()\r
- {\r
- //Throw excpetion if Dispose() is called in separate thread.\r
- if (!Window.IsInstalled())\r
- {\r
- throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");\r
- }\r
-\r
- if (isDisposeQueued)\r
- {\r
- Dispose(DisposeTypes.Implicit);\r
- }\r
- else\r
- {\r
- Dispose(DisposeTypes.Explicit);\r
- System.GC.SuppressFinalize(this);\r
- }\r
- }\r
-\r
- protected virtual void Dispose(DisposeTypes type)\r
- {\r
- if (disposed)\r
- {\r
- return;\r
- }\r
-\r
- if (type == DisposeTypes.Explicit)\r
- {\r
- //Called by User\r
- //Release your own managed resources here.\r
- //You should release all of your own disposable objects here.\r
-\r
- }\r
-\r
- //Release your own unmanaged resources here.\r
- //You should not access any managed member here except static instance.\r
- //because the execution order of Finalizes is non-deterministic.\r
-\r
- if (swigCPtr.Handle != global::System.IntPtr.Zero)\r
- {\r
- if (swigCMemOwn)\r
- {\r
- swigCMemOwn = false;\r
- NDalicPINVOKE.delete_Shader_Hint(swigCPtr);\r
- }\r
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);\r
- }\r
-\r
- disposed = true;\r
- }
-
- public Hint() : this(NDalicPINVOKE.new_Shader_Hint(), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public enum Value
- {
- NONE = 0x00,
- OUTPUT_IS_TRANSPARENT = 0x01,
- MODIFIES_GEOMETRY = 0x02
- }
-
- }
-
- public class Property : global::System.IDisposable
- {
- private global::System.Runtime.InteropServices.HandleRef swigCPtr;
- protected bool swigCMemOwn;
-
- internal Property(global::System.IntPtr cPtr, bool cMemoryOwn)
- {
- swigCMemOwn = cMemoryOwn;
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
- }
-
- internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Property obj)
- {
- return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
- }
-
- //A Flag to check who called Dispose(). (By User or DisposeQueue)\r
- private bool isDisposeQueued = false;\r
- //A Flat to check if it is already disposed.\r
- protected bool disposed = false;
-
- ~Property()\r
- {\r
- if (!isDisposeQueued)\r
- {\r
- isDisposeQueued = true;\r
- DisposeQueue.Instance.Add(this);\r
- }\r
- }\r
-\r
- public void Dispose()\r
- {\r
- //Throw excpetion if Dispose() is called in separate thread.\r
- if (!Window.IsInstalled())\r
- {\r
- throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");\r
- }\r
-\r
- if (isDisposeQueued)\r
- {\r
- Dispose(DisposeTypes.Implicit);\r
- }\r
- else\r
- {\r
- Dispose(DisposeTypes.Explicit);\r
- System.GC.SuppressFinalize(this);\r
- }\r
- }\r
-\r
- protected virtual void Dispose(DisposeTypes type)\r
- {\r
- if (disposed)\r
- {\r
- return;\r
- }\r
-\r
- if (type == DisposeTypes.Explicit)\r
- {\r
- //Called by User\r
- //Release your own managed resources here.\r
- //You should release all of your own disposable objects here.\r
-\r
- }\r
-\r
- //Release your own unmanaged resources here.\r
- //You should not access any managed member here except static instance.\r
- //because the execution order of Finalizes is non-deterministic.\r
-\r
- if (swigCPtr.Handle != global::System.IntPtr.Zero)\r
- {\r
- if (swigCMemOwn)\r
- {\r
- swigCMemOwn = false;\r
- NDalicPINVOKE.delete_Shader_Property(swigCPtr);\r
- }\r
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);\r
- }\r
-\r
- disposed = true;\r
- }
-
- public Property() : this(NDalicPINVOKE.new_Shader_Property(), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public static readonly int PROGRAM = NDalicPINVOKE.Shader_Property_PROGRAM_get();
-
- }
-
- public Shader(string vertexShader, string fragmentShader, Shader.Hint.Value hints) : this(NDalicPINVOKE.Shader_New__SWIG_0(vertexShader, fragmentShader, (int)hints), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
-
- }
- public Shader(string vertexShader, string fragmentShader) : this(NDalicPINVOKE.Shader_New__SWIG_1(vertexShader, fragmentShader), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
-
- }
- public Shader(Shader handle) : this(NDalicPINVOKE.new_Shader__SWIG_1(Shader.getCPtr(handle)), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
- public new static Shader DownCast(BaseHandle handle)
- {
- Shader ret = new Shader(NDalicPINVOKE.Shader_DownCast(BaseHandle.getCPtr(handle)), true);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public Shader Assign(Shader handle)
- {
- Shader ret = new Shader(NDalicPINVOKE.Shader_Assign(swigCPtr, Shader.getCPtr(handle)), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
- public Tizen.NUI.PropertyMap Program
- {
- get
- {
- Tizen.NUI.PropertyMap temp = new Tizen.NUI.PropertyMap();
- Tizen.NUI.Object.GetProperty(swigCPtr, Shader.Property.PROGRAM).Get(temp);
- return temp;
- }
- set
- {
- Tizen.NUI.Object.SetProperty(swigCPtr, Shader.Property.PROGRAM, new Tizen.NUI.PropertyValue(value));
- }
- }
-
- }
-
-}
///
///
/// </summary>
- internal sealed class ViewRegistry
+ public sealed class ViewRegistry
{
/// <summary>
/// ViewRegistry is a singleton
};
- public ViewRegistry()
+ private ViewRegistry()
{
_createCallback = new CreateControlDelegate(CreateControl);
_getPropertyCallback = new GetPropertyDelegate(GetProperty);
/// Store the mapping between this instance of control (View) and native part.
/// </summary>
/// <param name="view"> The instance of control (View)</param>
- public static void RegisterView(View view)
+ internal static void RegisterView(View view)
{
// We store a pointer to the RefObject for the control
RefObject refObj = view.GetObjectPtr();
/// Remove the this instance of control (View) and native part from the mapping table.
/// </summary>
/// <param name="view"> The instance of control (View)</param>
- public static void UnregisterView(View view)
+ internal static void UnregisterView(View view)
{
RefObject refObj = view.GetObjectPtr();
IntPtr refCptr = (IntPtr)RefObject.getCPtr(refObj);
}
}
+ [UnmanagedFunctionPointer(CallingConvention.StdCall)]
+ private delegate void AnimationProgressReachedEventCallbackType(IntPtr data);
+ private AnimationProgressReachedEventCallbackType _animationProgressReachedEventCallback;
+ private event EventHandler _animationProgressReachedEventHandler;
+ /**
+ * @brief Event for ProgressReached signal which can be used to subscribe/unsubscribe the event handler.
+ * ProgressReached signal is emitted when the Animation has reached a given progress percentage, this is set in the api SetProgressNotification.
+ */
+ public event EventHandler ProgressReached
+ {
+ add
+ {
+ if (_animationProgressReachedEventHandler == null)
+ {
+#if DEBUG_ON
+ Tizen.Log.Debug("NUI", "con1) ProgressReachedSignal().Empty = " + ProgressReachedSignal().Empty());
+ Tizen.Log.Debug("NUI", "con2) ProgressReachedSignal().GetConnectionCount = " + ProgressReachedSignal().GetConnectionCount());
+#endif
+ _animationProgressReachedEventCallback = OnProgressReached;
+ ProgressReachedSignal().Connect(_animationProgressReachedEventCallback);
+#if DEBUG_ON
+ Tizen.Log.Debug("NUI", "con3) ProgressReachedSignal().Empty = " + ProgressReachedSignal().Empty());
+ Tizen.Log.Debug("NUI", "con4) ProgressReachedSignal().GetConnectionCount = " + ProgressReachedSignal().GetConnectionCount());
+#endif
+ }
+
+ _animationProgressReachedEventHandler += value;
+ }
+ remove
+ {
+ _animationProgressReachedEventHandler -= value;
+
+ if (_animationProgressReachedEventHandler == null && ProgressReachedSignal().Empty() == false)
+ {
+#if DEBUG_ON
+ Tizen.Log.Debug("NUI", "discon1) ProgressReachedSignal().Empty = " + ProgressReachedSignal().Empty());
+ Tizen.Log.Debug("NUI", "discon2) ProgressReachedSignal().GetConnectionCount = " + ProgressReachedSignal().GetConnectionCount());
+#endif
+ ProgressReachedSignal().Disconnect(_animationProgressReachedEventHandler);
+#if DEBUG_ON
+ Tizen.Log.Debug("NUI", "discon3) ProgressReachedSignal().Empty = " + ProgressReachedSignal().Empty());
+ Tizen.Log.Debug("NUI", "discon4) ProgressReachedSignal().GetConnectionCount = " + ProgressReachedSignal().GetConnectionCount());
+#endif
+ }
+ }
+ }
+ private void OnProgressReached(IntPtr data)
+ {
+ if (_animationProgressReachedEventHandler != null)
+ {
+ //here we send all data to user event handlers
+ _animationProgressReachedEventHandler(this, null);
+ }
+ }
internal static Animation GetAnimationFromPtr(global::System.IntPtr cPtr)
{
}
}
+
+ /// <summary>
+ /// Gets/Sets the Progress notification marker which triggers the ProgressReachedSignal.<br>
+ /// percentage of animation progress should be greater than 0 and less than 1, e.g 0.3 for 30% <br>
+ /// One notification can be set on each animation
+ /// </summary>
+ public float ProgressNotification
+ {
+ set
+ {
+ NDalicPINVOKE.Animation_SetProgressNotification(swigCPtr, value);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ }
+ get
+ {
+ float ret = NDalicPINVOKE.Animation_GetProgressNotification(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+
/// <summary>
/// Animates a property value by a relative amount.<br>
/// </summary>
return ret;
}
+ internal AnimationSignal ProgressReachedSignal()
+ {
+ AnimationSignal ret = new AnimationSignal(NDalicPINVOKE.Animation_ProgressReachedSignal(swigCPtr), false);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
internal void AnimateBy(Property target, PropertyValue relativeValue)
{
NDalicPINVOKE.Animation_AnimateBy__SWIG_0(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(relativeValue));
Tizen.NUI.PropertyMap background = Background;
int visualType = 0;
- background.Find(Visual.Property.Type).Get(out visualType);
+ background.Find(Visual.Property.Type)?.Get(out visualType);
if (visualType == (int)Visual.Type.Color)
{
- background.Find(ColorVisualProperty.MixColor).Get(backgroundColor);
+ background.Find(ColorVisualProperty.MixColor)?.Get(backgroundColor);
}
return backgroundColor;
Tizen.NUI.PropertyMap background = Background;
int visualType = 0;
- background.Find(Visual.Property.Type).Get(out visualType);
+ background.Find(Visual.Property.Type)?.Get(out visualType);
if (visualType == (int)Visual.Type.Image)
{
- background.Find(ImageVisualProperty.URL).Get(out backgroundImage);
+ background.Find(ImageVisualProperty.URL)?.Get(out backgroundImage);
}
return backgroundImage;
/// </summary>
/// <pre>The View has been initialized.</pre>
/// <returns>The number of children</returns>
- public uint GetChildCount()
+ internal uint GetChildCount()
{
uint ret = NDalicPINVOKE.Actor_GetChildCount(swigCPtr);
if (NDalicPINVOKE.SWIGPendingException.Pending)
}
/// <summary>
+ /// Get the number of children held by the view.
+ /// </summary>
+ public uint ChildCount
+ {
+ get
+ {
+ return GetChildCount();
+ }
+ }
+
+ /// <summary>
/// Gets/Sets the status of whether an view should emit touch or hover signals.
/// </summary>
public bool Sensitive
// Create a text field
_textField = new TextField();
- _textField.PivotPoint = Tizen.NUI.AnchorPoint.Center;
+ _textField.PivotPoint = Tizen.NUI.PivotPoint.Center;
_textField.WidthResizePolicy = ResizePolicyType.SizeRelativeToParent;
_textField.HeightResizePolicy = ResizePolicyType.SizeRelativeToParent;
_textField.SizeModeFactor = new Vector3(1.0f, 0.45f, 1.0f);
namespace Tizen.NUI
{
-
- internal enum FilterModeType
+ public enum FilterModeType
{
NONE = 0,
DEFAULT,
namespace Tizen.NUI
{
- internal class Geometry : BaseHandle
+ public class Geometry : BaseHandle
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- public Geometry(Geometry handle) : this(NDalicPINVOKE.new_Geometry__SWIG_1(Geometry.getCPtr(handle)), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
- public static Geometry DownCast(BaseHandle handle)
+ internal static Geometry DownCast(BaseHandle handle)
{
Geometry ret = new Geometry(NDalicPINVOKE.Geometry_DownCast(BaseHandle.getCPtr(handle)), true);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
- public Geometry Assign(Geometry handle)
- {
- Geometry ret = new Geometry(NDalicPINVOKE.Geometry_Assign(swigCPtr, Geometry.getCPtr(handle)), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
public uint AddVertexBuffer(PropertyBuffer vertexBuffer)
{
uint ret = NDalicPINVOKE.Geometry_AddVertexBuffer(swigCPtr, PropertyBuffer.getCPtr(vertexBuffer));
using System.Runtime.InteropServices;
- internal class ImfManager : BaseHandle
+ public class ImfManager : BaseHandle
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
return ret;
}
- public void ApplyOptions(SWIGTYPE_p_InputMethodOptions options)
+ internal void ApplyOptions(SWIGTYPE_p_InputMethodOptions options)
{
NDalicManualPINVOKE.ImfManager_ApplyOptions(swigCPtr, SWIGTYPE_p_InputMethodOptions.getCPtr(options));
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- public ImfManager(SWIGTYPE_p_Dali__Internal__Adaptor__ImfManager imfManager) : this(NDalicManualPINVOKE.new_ImfManager__SWIG_1(SWIGTYPE_p_Dali__Internal__Adaptor__ImfManager.getCPtr(imfManager)), true)
+ internal ImfManager(SWIGTYPE_p_Dali__Internal__Adaptor__ImfManager imfManager) : this(NDalicManualPINVOKE.new_ImfManager__SWIG_1(SWIGTYPE_p_Dali__Internal__Adaptor__ImfManager.getCPtr(imfManager)), true)
{
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
///////////////////////////////////////////////////////////////////////////////
- public static ImfManager GetImfManagerFromPtr(global::System.IntPtr cPtr)
+ internal static ImfManager GetImfManagerFromPtr(global::System.IntPtr cPtr)
{
ImfManager ret = new ImfManager(cPtr, false);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
///////////////////////////////////////////////////////////////////////////////
- public class SWIGTYPE_p_Dali__Internal__Adaptor__ImfManager
+ internal class SWIGTYPE_p_Dali__Internal__Adaptor__ImfManager
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
}
}
- public class SWIGTYPE_p_InputMethodOptions
+ internal class SWIGTYPE_p_InputMethodOptions
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
internal class Property
{
- internal static readonly int CLIPPING_ENABLE = NDalicPINVOKE.Layer_Property_CLIPPING_ENABLE_get();
- internal static readonly int CLIPPING_BOX = NDalicPINVOKE.Layer_Property_CLIPPING_BOX_get();
internal static readonly int BEHAVIOR = NDalicPINVOKE.Layer_Property_BEHAVIOR_get();
}
}
}
- }
+ /// <summary>
+ /// Retrieves and sets the Layer's opacity.<br>
+ /// </summary>
+ public float Opacity
+ {
+ get
+ {
+ float temp = 0.0f;
+ GetProperty(View.Property.OPACITY).Get(out temp);
+ return temp;
+ }
+ set
+ {
+ SetProperty(View.Property.OPACITY, new Tizen.NUI.PropertyValue(value));
+ }
+ }
+
+ /// <summary>
+ /// Retrieves and sets the Layer's visibility.
+ /// </summary>
+ public bool Visibility
+ {
+ get
+ {
+ bool temp = false;
+ GetProperty(View.Property.VISIBLE).Get(out temp);
+ return temp;
+ }
+ set
+ {
+ SetProperty(View.Property.VISIBLE, new Tizen.NUI.PropertyValue(value));
+ }
+ }
+ /// <summary>
+ /// Get the number of children held by the layer.
+ /// </summary>
+ public uint ChildCount
+ {
+ get
+ {
+ uint ret = NDalicPINVOKE.Actor_GetChildCount(swigCPtr);
+ if (NDalicPINVOKE.SWIGPendingException.Pending)
+ throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+ }
+ }
}
public struct ImageVisualProperty
{
public static readonly int URL = NDalic.IMAGE_VISUAL_URL;
+ public static readonly int AlphaMaskURL = NDalic.IMAGE_VISUAL_ALPHA_MASK_URL;
public static readonly int FittingMode = NDalic.IMAGE_VISUAL_FITTING_MODE;
public static readonly int SamplingMode = NDalic.IMAGE_VISUAL_SAMPLING_MODE;
public static readonly int DesiredWidth = NDalic.IMAGE_VISUAL_DESIRED_WIDTH;
/// <summary>
/// AnchorPoint constants.
/// </summary>
- public struct AnchorPoint
+ public struct PivotPoint
{
public static float Top
{
}
public enum DisposeTypes
- {
- Explicit, //Called By User
+ {
+ Explicit, //Called By User
Implicit, //Called by DisposeQueue
}
}
namespace Tizen.NUI
{
- internal class PixelData : BaseHandle
+ public class PixelData : BaseHandle
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
namespace Tizen.NUI
{
-
- internal enum PixelFormat
+ public enum PixelFormat
{
INVALID = 0,
A8 = 1,
namespace Tizen.NUI
{
- internal class PropertyBuffer : BaseHandle
+ public class PropertyBuffer : BaseHandle
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- public PropertyBuffer(PropertyBuffer handle) : this(NDalicPINVOKE.new_PropertyBuffer__SWIG_1(PropertyBuffer.getCPtr(handle)), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
- public static PropertyBuffer DownCast(BaseHandle handle)
+ internal static PropertyBuffer DownCast(BaseHandle handle)
{
PropertyBuffer ret = new PropertyBuffer(NDalicPINVOKE.PropertyBuffer_DownCast(BaseHandle.getCPtr(handle)), true);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
- public PropertyBuffer Assign(PropertyBuffer handle)
- {
- PropertyBuffer ret = new PropertyBuffer(NDalicPINVOKE.PropertyBuffer_Assign(swigCPtr, PropertyBuffer.getCPtr(handle)), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
public void SetData(System.IntPtr data, uint size)
{
NDalicPINVOKE.PropertyBuffer_SetData(swigCPtr, data, size);
namespace Tizen.NUI
{
- internal class Renderer : Animatable
+ public class Renderer : Animatable
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
base.Dispose(type);
}
- public class Property : global::System.IDisposable
+ public class Property
{
- private global::System.Runtime.InteropServices.HandleRef swigCPtr;
- protected bool swigCMemOwn;
-
- internal Property(global::System.IntPtr cPtr, bool cMemoryOwn)
- {
- swigCMemOwn = cMemoryOwn;
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
- }
-
- internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Property obj)
- {
- return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
- }
-
- //A Flag to check who called Dispose(). (By User or DisposeQueue)
- private bool isDisposeQueued = false;
- //A Flat to check if it is already disposed.
- protected bool disposed = false;
-
-
- ~Property()
- {
- if (!isDisposeQueued)
- {
- isDisposeQueued = true;
- DisposeQueue.Instance.Add(this);
- }
- }
-
- public void Dispose()
- {
- //Throw excpetion if Dispose() is called in separate thread.
- if (!Window.IsInstalled())
- {
- throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
- }
-
- if (isDisposeQueued)
- {
- Dispose(DisposeTypes.Implicit);
- }
- else
- {
- Dispose(DisposeTypes.Explicit);
- System.GC.SuppressFinalize(this);
- }
- }
-
- protected virtual void Dispose(DisposeTypes type)
- {
- if (disposed)
- {
- return;
- }
-
- if (type == DisposeTypes.Explicit)
- {
- //Called by User
- //Release your own managed resources here.
- //You should release all of your own disposable objects here.
-
- }
-
- //Release your own unmanaged resources here.
- //You should not access any managed member here except static instance.
- //because the execution order of Finalizes is non-deterministic.
-
- if (swigCPtr.Handle != global::System.IntPtr.Zero)
- {
- if (swigCMemOwn)
- {
- swigCMemOwn = false;
- NDalicPINVOKE.delete_Renderer_Property(swigCPtr);
- }
- swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
- }
-
- disposed = true;
- }
-
- public Property() : this(NDalicPINVOKE.new_Renderer_Property(), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
-
public static readonly int DEPTH_INDEX = NDalicPINVOKE.Renderer_Property_DEPTH_INDEX_get();
public static readonly int FACE_CULLING_MODE = NDalicPINVOKE.Renderer_Property_FACE_CULLING_MODE_get();
public static readonly int BLEND_MODE = NDalicPINVOKE.Renderer_Property_BLEND_MODE_get();
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- public Renderer(Renderer handle) : this(NDalicPINVOKE.new_Renderer__SWIG_1(Renderer.getCPtr(handle)), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
- public new static Renderer DownCast(BaseHandle handle)
+ internal new static Renderer DownCast(BaseHandle handle)
{
Renderer ret = new Renderer(NDalicPINVOKE.Renderer_DownCast(BaseHandle.getCPtr(handle)), true);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
- public Renderer Assign(Renderer handle)
- {
- Renderer ret = new Renderer(NDalicPINVOKE.Renderer_Assign(swigCPtr, Renderer.getCPtr(handle)), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
public void SetGeometry(Geometry geometry)
{
NDalicPINVOKE.Renderer_SetGeometry(swigCPtr, Geometry.getCPtr(geometry));
namespace Tizen.NUI
{
- internal class Sampler : BaseHandle
+ public class Sampler : BaseHandle
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- public Sampler(Sampler handle) : this(NDalicPINVOKE.new_Sampler__SWIG_1(Sampler.getCPtr(handle)), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
- public static Sampler DownCast(BaseHandle handle)
+ internal static Sampler DownCast(BaseHandle handle)
{
Sampler ret = new Sampler(NDalicPINVOKE.Sampler_DownCast(BaseHandle.getCPtr(handle)), true);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
- public Sampler Assign(Sampler handle)
- {
- Sampler ret = new Sampler(NDalicPINVOKE.Sampler_Assign(swigCPtr, Sampler.getCPtr(handle)), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
public void SetFilterMode(FilterModeType minFilter, FilterModeType magFilter)
{
NDalicPINVOKE.Sampler_SetFilterMode(swigCPtr, (int)minFilter, (int)magFilter);
--- /dev/null
+/** Copyright (c) 2017 Samsung Electronics Co., Ltd.
+*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*
+*/
+// This File has been auto-generated by SWIG and then modified using DALi Ruby Scripts
+//------------------------------------------------------------------------------
+// <auto-generated />
+//
+// This file was automatically generated by SWIG (http://www.swig.org).
+// Version 3.0.9
+//
+// Do not make changes to this file unless you know what you are doing--modify
+// the SWIG interface file instead.
+//------------------------------------------------------------------------------
+
+namespace Tizen.NUI
+{
+
+ public class Shader : Animatable
+ {
+ private global::System.Runtime.InteropServices.HandleRef swigCPtr;
+
+ internal Shader(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.Shader_SWIGUpcast(cPtr), cMemoryOwn)
+ {
+ swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
+ }
+
+ internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Shader obj)
+ {
+ return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
+ }
+
+ protected override void Dispose(DisposeTypes type)
+ {
+ if (disposed)
+ {
+ return;
+ }
+
+ if (type == DisposeTypes.Explicit)
+ {
+ //Called by User
+ //Release your own managed resources here.
+ //You should release all of your own disposable objects here.
+
+ }
+
+ //Release your own unmanaged resources here.
+ //You should not access any managed member here except static instance.
+ //because the execution order of Finalizes is non-deterministic.
+
+ if (swigCPtr.Handle != global::System.IntPtr.Zero)
+ {
+ if (swigCMemOwn)
+ {
+ swigCMemOwn = false;
+ NDalicPINVOKE.delete_Shader(swigCPtr);
+ }
+ swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
+ }
+
+ base.Dispose(type);
+ }
+
+
+ public class Hint
+ {
+ public enum Value
+ {
+ NONE = 0x00,
+ OUTPUT_IS_TRANSPARENT = 0x01,
+ MODIFIES_GEOMETRY = 0x02
+ }
+ }
+
+ public class Property
+ {
+ public static readonly int PROGRAM = NDalicPINVOKE.Shader_Property_PROGRAM_get();
+ }
+
+ public Shader(string vertexShader, string fragmentShader, Shader.Hint.Value hints) : this(NDalicPINVOKE.Shader_New__SWIG_0(vertexShader, fragmentShader, (int)hints), true)
+ {
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+
+ }
+ public Shader(string vertexShader, string fragmentShader) : this(NDalicPINVOKE.Shader_New__SWIG_1(vertexShader, fragmentShader), true)
+ {
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+
+ }
+
+ internal new static Shader DownCast(BaseHandle handle)
+ {
+ Shader ret = new Shader(NDalicPINVOKE.Shader_DownCast(BaseHandle.getCPtr(handle)), true);
+ if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+ return ret;
+ }
+
+ public Tizen.NUI.PropertyMap Program
+ {
+ get
+ {
+ Tizen.NUI.PropertyMap temp = new Tizen.NUI.PropertyMap();
+ Tizen.NUI.Object.GetProperty(swigCPtr, Shader.Property.PROGRAM).Get(temp);
+ return temp;
+ }
+ set
+ {
+ Tizen.NUI.Object.SetProperty(swigCPtr, Shader.Property.PROGRAM, new Tizen.NUI.PropertyValue(value));
+ }
+ }
+ }
+
+}
namespace Tizen.NUI
{
- internal class Texture : BaseHandle
+ public class Texture : BaseHandle
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- public Texture(NativeImageInterface nativeImageInterface) : this(NDalicPINVOKE.Texture_New__SWIG_1(NativeImageInterface.getCPtr(nativeImageInterface)), true)
+ internal Texture(NativeImageInterface nativeImageInterface) : this(NDalicPINVOKE.Texture_New__SWIG_1(NativeImageInterface.getCPtr(nativeImageInterface)), true)
{
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- public Texture(Texture handle) : this(NDalicPINVOKE.new_Texture__SWIG_1(Texture.getCPtr(handle)), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
- public static Texture DownCast(BaseHandle handle)
+ internal static Texture DownCast(BaseHandle handle)
{
Texture ret = new Texture(NDalicPINVOKE.Texture_DownCast(BaseHandle.getCPtr(handle)), true);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
- public Texture Assign(Texture handle)
- {
- Texture ret = new Texture(NDalicPINVOKE.Texture_Assign(swigCPtr, Texture.getCPtr(handle)), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
public bool Upload(PixelData pixelData)
{
bool ret = NDalicPINVOKE.Texture_Upload__SWIG_0(swigCPtr, PixelData.getCPtr(pixelData));
namespace Tizen.NUI
{
- internal class TextureSet : BaseHandle
+ public class TextureSet : BaseHandle
{
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- public TextureSet(TextureSet handle) : this(NDalicPINVOKE.new_TextureSet__SWIG_1(TextureSet.getCPtr(handle)), true)
- {
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- }
- public static TextureSet DownCast(BaseHandle handle)
+ internal static TextureSet DownCast(BaseHandle handle)
{
TextureSet ret = new TextureSet(NDalicPINVOKE.TextureSet_DownCast(BaseHandle.getCPtr(handle)), true);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
- public TextureSet Assign(TextureSet handle)
- {
- TextureSet ret = new TextureSet(NDalicPINVOKE.TextureSet_Assign(swigCPtr, TextureSet.getCPtr(handle)), false);
- if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
- return ret;
- }
-
public void SetTexture(uint index, Texture texture)
{
NDalicPINVOKE.TextureSet_SetTexture(swigCPtr, index, Texture.getCPtr(texture));
namespace Tizen.NUI
{
-
- internal enum TextureType
+ public enum TextureType
{
TEXTURE_2D,
TEXTURE_CUBE
/// <summary>
/// the depth index of this visual.
/// </summary>
- public float DepthIndex
+ public int DepthIndex
{
set
{
return GetDepthIndex();
}
}
- internal void SetDepthIndex(float index)
+ internal void SetDepthIndex(int index)
{
NDalicPINVOKE.VisualBase_SetDepthIndex(swigCPtr, index);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- internal float GetDepthIndex()
+ internal int GetDepthIndex()
{
- float ret = NDalicPINVOKE.VisualBase_GetDepthIndex(swigCPtr);
+ int ret = NDalicPINVOKE.VisualBase_GetDepthIndex(swigCPtr);
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
private PropertyMap _visualTransformMap = null;
- private float? _depthIndex = null;
+ private int? _depthIndex = null;
protected PropertyMap _outputVisualMap = null;
internal string Name
/// By default, the depth index is 0.<br>
/// Optional.
/// </summary>
- public float DepthIndex
+ public int DepthIndex
{
get
{
- return _depthIndex ?? (0.0f);
+ return _depthIndex ?? (0);
}
set
{
}
private string _url = null;
+ private string _alphaMaskUrl = null;
private FittingModeType? _fittingMode = null;
private SamplingModeType? _samplingMode = null;
private int? _desiredWidth = null;
}
/// <summary>
+ /// Get or set the URL of the alpha mask.<br>
+ /// Optional.
+ /// </summary>
+ public string AlphaMaskURL
+ {
+ get
+ {
+ return _alphaMaskUrl;
+ }
+ set
+ {
+ _alphaMaskUrl = value;
+ UpdateVisual();
+ }
+ }
+
+ /// <summary>
/// Get or set fitting options, used when resizing images to fit desired dimensions.<br>
/// If not supplied, default is FittingModeType.ShrinkToFit.<br>
/// For Normal Quad images only.<br>
_outputVisualMap = new PropertyMap();
_outputVisualMap.Add(Visual.Property.Type, new PropertyValue((int)Visual.Type.Image));
_outputVisualMap.Add(ImageVisualProperty.URL, new PropertyValue(_url));
+ if (_alphaMaskUrl != null ) { _outputVisualMap.Add(ImageVisualProperty.AlphaMaskURL, new PropertyValue(_alphaMaskUrl)); }
if (_fittingMode != null) { _outputVisualMap.Add(ImageVisualProperty.FittingMode, new PropertyValue((int)_fittingMode)); }
if (_samplingMode != null) { _outputVisualMap.Add(ImageVisualProperty.SamplingMode, new PropertyValue((int)_samplingMode)); }
if (_desiredWidth != null) { _outputVisualMap.Add(ImageVisualProperty.DesiredWidth, new PropertyValue((int)_desiredWidth)); }
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- internal void Add(View view)
+ public void Add(View view)
{
NDalicPINVOKE.Stage_Add(stageCPtr, View.getCPtr(view));
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
}
- internal void Remove(View view)
+ public void Remove(View view)
{
NDalicPINVOKE.Stage_Remove(stageCPtr, View.getCPtr(view));
if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();