2 * Copyright(c) 2021 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
19 using System.ComponentModel;
26 /// <since_tizen> 3 </since_tizen>
27 [Obsolete("Deprecated in API6, Will be removed in API9, Please use WidgetView.WidgetAdded, WidgetDeleted events instead!")]
28 [EditorBrowsable(EditorBrowsableState.Never)]
29 public class WidgetViewSignal : Disposable
32 internal WidgetViewSignal(global::System.IntPtr cPtr, bool cMemoryOwn) : base(cPtr, cMemoryOwn)
37 /// This will not be public opened.
38 [EditorBrowsable(EditorBrowsableState.Never)]
39 protected override void ReleaseSwigCPtr(System.Runtime.InteropServices.HandleRef swigCPtr)
41 Interop.WidgetView.DeleteWidgetViewSignal(swigCPtr);
45 /// Queries whether there are any connected slots.
47 /// <returns>True if there are any slots connected to the signal</returns>
48 /// <since_tizen> 3 </since_tizen>
49 [Obsolete("Deprecated in API6, Will be removed in API9, Please use WidgetView.WidgetAdded, WidgetDeleted events instead!")]
50 [EditorBrowsable(EditorBrowsableState.Never)]
53 bool ret = Interop.WidgetView.WidgetViewSignalEmpty(SwigCPtr);
54 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
59 /// Queries the number of slots.
61 /// <returns>The number of slots connected to this signal</returns>
62 /// <since_tizen> 3 </since_tizen>
63 [Obsolete("Deprecated in API6, Will be removed in API9, Please use WidgetView.WidgetAdded, WidgetDeleted events instead!")]
64 [EditorBrowsable(EditorBrowsableState.Never)]
65 public uint GetConnectionCount()
67 uint ret = Interop.WidgetView.WidgetViewSignalGetConnectionCount(SwigCPtr);
68 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
73 /// Connects a function.
75 /// <param name="func">The function to connect</param>
76 /// <since_tizen> 3 </since_tizen>
77 [Obsolete("Deprecated in API6, Will be removed in API9, Please use WidgetView.WidgetAdded, WidgetDeleted events instead!")]
78 [EditorBrowsable(EditorBrowsableState.Never)]
79 public void Connect(System.Delegate func)
81 System.IntPtr ip = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate<System.Delegate>(func);
83 Interop.WidgetView.WidgetViewSignalConnect(SwigCPtr, new System.Runtime.InteropServices.HandleRef(this, ip));
84 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
89 /// Disconnects a function.
91 /// <param name="func">The function to disconnect</param>
92 /// <since_tizen> 3 </since_tizen>
93 [Obsolete("Deprecated in API6, Will be removed in API9, Please use WidgetView.WidgetAdded, WidgetDeleted events instead!")]
94 [EditorBrowsable(EditorBrowsableState.Never)]
95 public void Disconnect(System.Delegate func)
97 System.IntPtr ip = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate<System.Delegate>(func);
99 Interop.WidgetView.WidgetViewSignalDisconnect(SwigCPtr, new System.Runtime.InteropServices.HandleRef(this, ip));
100 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
105 /// Connects a member function.
107 /// <param name="arg">The member function to connect</param>
108 /// <since_tizen> 3 </since_tizen>
109 [Obsolete("Deprecated in API6, Will be removed in API9, Please use WidgetView.WidgetAdded, WidgetDeleted events instead!")]
110 [EditorBrowsable(EditorBrowsableState.Never)]
111 public void Emit(WidgetView arg)
113 Interop.WidgetView.WidgetViewSignalEmit(SwigCPtr, WidgetView.getCPtr(arg));
114 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
120 /// <since_tizen> 3 </since_tizen>
121 [Obsolete("Deprecated in API6, Will be removed in API9, Please use WidgetView.WidgetAdded, WidgetDeleted events instead!")]
122 [EditorBrowsable(EditorBrowsableState.Never)]
123 public WidgetViewSignal() : this(Interop.WidgetView.NewWidgetViewSignal(), true)
125 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();