1 // Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
\r
2 // PROPRIETARY/CONFIDENTIAL
\r
3 // This software is the confidential and proprietary
\r
4 // information of SAMSUNG ELECTRONICS ("Confidential Information"). You shall
\r
5 // not disclose such Confidential Information and shall use it only in
\r
6 // accordance with the terms of the license agreement you entered into with
\r
7 // SAMSUNG ELECTRONICS. SAMSUNG make no representations or warranties about the
\r
8 // suitability of the software, either express or implied, including but not
\r
9 // limited to the implied warranties of merchantability, fitness for a
\r
10 // particular purpose, or non-infringement. SAMSUNG shall not be liable for any
\r
11 // damages suffered by licensee as a result of using, modifying or distributing
\r
12 // this software or its derivatives.
\r
14 // Copyright (c) 2017 Samsung Electronics Co., Ltd.
\r
16 // Licensed under the Apache License, Version 2.0 (the "License");
\r
17 // you may not use this file except in compliance with the License.
\r
18 // You may obtain a copy of the License at
\r
20 // http://www.apache.org/licenses/LICENSE-2.0
\r
22 // Unless required by applicable law or agreed to in writing, software
\r
23 // distributed under the License is distributed on an "AS IS" BASIS,
\r
24 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
25 // See the License for the specific language governing permissions and
\r
26 // limitations under the License.
\r
29 // This File has been auto-generated by SWIG and then modified using DALi Ruby Scripts
\r
30 // Some have been manually changed
\r
36 public class PushButton : Button
\r
38 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
\r
40 internal PushButton(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.PushButton_SWIGUpcast(cPtr), cMemoryOwn)
\r
42 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
\r
45 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PushButton obj)
\r
47 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
\r
52 DisposeQueue.Instance.Add(this);
\r
55 public override void Dispose()
\r
57 if (!Stage.IsInstalled())
\r
59 DisposeQueue.Instance.Add(this);
\r
65 if (swigCPtr.Handle != global::System.IntPtr.Zero)
\r
69 swigCMemOwn = false;
\r
70 NDalicPINVOKE.delete_PushButton(swigCPtr);
\r
72 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
\r
74 global::System.GC.SuppressFinalize(this);
\r
80 internal class Property : global::System.IDisposable
\r
82 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
\r
83 protected bool swigCMemOwn;
\r
85 internal Property(global::System.IntPtr cPtr, bool cMemoryOwn)
\r
87 swigCMemOwn = cMemoryOwn;
\r
88 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
\r
91 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Property obj)
\r
93 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
\r
101 public virtual void Dispose()
\r
105 if (swigCPtr.Handle != global::System.IntPtr.Zero)
\r
109 swigCMemOwn = false;
\r
110 NDalicPINVOKE.delete_PushButton_Property(swigCPtr);
\r
112 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
\r
114 global::System.GC.SuppressFinalize(this);
\r
118 internal Property() : this(NDalicPINVOKE.new_PushButton_Property(), true)
\r
120 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
123 internal static readonly int UNSELECTED_ICON = NDalicPINVOKE.PushButton_Property_UNSELECTED_ICON_get();
\r
124 internal static readonly int SELECTED_ICON = NDalicPINVOKE.PushButton_Property_SELECTED_ICON_get();
\r
125 internal static readonly int ICON_ALIGNMENT = NDalicPINVOKE.PushButton_Property_ICON_ALIGNMENT_get();
\r
126 internal static readonly int LABEL_PADDING = NDalicPINVOKE.PushButton_Property_LABEL_PADDING_get();
\r
127 internal static readonly int ICON_PADDING = NDalicPINVOKE.PushButton_Property_ICON_PADDING_get();
\r
131 public PushButton() : this(NDalicPINVOKE.PushButton_New(), true)
\r
133 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
136 internal PushButton(PushButton pushButton) : this(NDalicPINVOKE.new_PushButton__SWIG_1(PushButton.getCPtr(pushButton)), true)
\r
138 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
141 internal PushButton Assign(PushButton pushButton)
\r
143 PushButton ret = new PushButton(NDalicPINVOKE.PushButton_Assign(swigCPtr, PushButton.getCPtr(pushButton)), false);
\r
144 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
148 public new static PushButton DownCast(BaseHandle handle)
\r
150 PushButton ret = new PushButton(NDalicPINVOKE.PushButton_DownCast(BaseHandle.getCPtr(handle)), true);
\r
151 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
155 internal new void SetButtonImage(Image image)
\r
157 NDalicPINVOKE.PushButton_SetButtonImage__SWIG_0_0(swigCPtr, Image.getCPtr(image));
\r
158 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
161 internal void SetButtonImage(Actor image)
\r
163 NDalicPINVOKE.PushButton_SetButtonImage__SWIG_1(swigCPtr, Actor.getCPtr(image));
\r
164 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
167 internal void SetBackgroundImage(Actor image)
\r
169 NDalicPINVOKE.PushButton_SetBackgroundImage(swigCPtr, Actor.getCPtr(image));
\r
170 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
173 internal new void SetSelectedImage(Image image)
\r
175 NDalicPINVOKE.PushButton_SetSelectedImage__SWIG_0_0(swigCPtr, Image.getCPtr(image));
\r
176 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
179 internal void SetSelectedImage(Actor image)
\r
181 NDalicPINVOKE.PushButton_SetSelectedImage__SWIG_1(swigCPtr, Actor.getCPtr(image));
\r
182 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
185 internal void SetSelectedBackgroundImage(Actor image)
\r
187 NDalicPINVOKE.PushButton_SetSelectedBackgroundImage(swigCPtr, Actor.getCPtr(image));
\r
188 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
191 internal void SetDisabledBackgroundImage(Actor image)
\r
193 NDalicPINVOKE.PushButton_SetDisabledBackgroundImage(swigCPtr, Actor.getCPtr(image));
\r
194 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
197 internal void SetDisabledImage(Actor image)
\r
199 NDalicPINVOKE.PushButton_SetDisabledImage(swigCPtr, Actor.getCPtr(image));
\r
200 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
203 internal void SetDisabledSelectedImage(Actor image)
\r
205 NDalicPINVOKE.PushButton_SetDisabledSelectedImage(swigCPtr, Actor.getCPtr(image));
\r
206 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
\r
209 internal enum PropertyRange
\r
211 PROPERTY_START_INDEX = PropertyRanges.PROPERTY_REGISTRATION_START_INDEX,
\r
212 PROPERTY_END_INDEX = View.PropertyRange.PROPERTY_START_INDEX + 1000
\r
215 public string UnselectedIcon
\r
219 SetProperty(PushButton.Property.UNSELECTED_ICON, new Tizen.NUI.PropertyValue(value));
\r
222 public string SelectedIcon
\r
226 SetProperty(PushButton.Property.SELECTED_ICON, new Tizen.NUI.PropertyValue(value));
\r
229 public string IconAlignment
\r
234 GetProperty(PushButton.Property.ICON_ALIGNMENT).Get(out temp);
\r
239 SetProperty(PushButton.Property.ICON_ALIGNMENT, new Tizen.NUI.PropertyValue(value));
\r
242 public Vector4 LabelPadding
\r
246 Vector4 temp = new Vector4(0.0f, 0.0f, 0.0f, 0.0f);
\r
247 GetProperty(PushButton.Property.LABEL_PADDING).Get(temp);
\r
252 SetProperty(PushButton.Property.LABEL_PADDING, new Tizen.NUI.PropertyValue(value));
\r
256 public string IconPadding
\r
261 GetProperty(PushButton.Property.ICON_PADDING).Get(out temp);
\r
266 SetProperty(PushButton.Property.ICON_PADDING, new Tizen.NUI.PropertyValue(value));
\r