2 * Copyright (c) 2016 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.
22 internal delegate IntPtr SwigDelegatePreFocusChangeSignal(IntPtr current, IntPtr proposed, View.FocusDirection direction);
24 internal class PreFocusChangeSignal : global::System.IDisposable {
25 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
26 protected bool swigCMemOwn;
28 internal PreFocusChangeSignal(global::System.IntPtr cPtr, bool cMemoryOwn) {
29 swigCMemOwn = cMemoryOwn;
30 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
33 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PreFocusChangeSignal obj) {
34 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
37 ~PreFocusChangeSignal() {
38 DisposeQueue.Instance.Add(this);
41 public virtual void Dispose() {
42 if (!Stage.IsInstalled()) {
43 DisposeQueue.Instance.Add(this);
48 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
51 NDalicManualPINVOKE.delete_PreFocusChangeSignal(swigCPtr);
53 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
55 global::System.GC.SuppressFinalize(this);
60 bool ret = NDalicManualPINVOKE.PreFocusChangeSignal_Empty(swigCPtr);
61 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
65 public uint GetConnectionCount() {
66 uint ret = NDalicManualPINVOKE.PreFocusChangeSignal_GetConnectionCount(swigCPtr);
67 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
71 public void Connect(FocusManager.PreFocusChangeEventCallback func) {
72 NDalicManualPINVOKE.PreFocusChangeSignal_Connect(swigCPtr, func);
73 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
76 public void Disconnect(System.Delegate func) {
77 System.IntPtr ip = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate(func);
79 NDalicManualPINVOKE.PreFocusChangeSignal_Disconnect(swigCPtr, new System.Runtime.InteropServices.HandleRef(this, ip));
80 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
84 public Actor Emit(Actor arg1, Actor arg2, View.FocusDirection arg3) {
85 Actor ret = new Actor(NDalicManualPINVOKE.PreFocusChangeSignal_Emit(swigCPtr, Actor.getCPtr(arg1), Actor.getCPtr(arg2), (int)arg3), true);
86 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
90 public PreFocusChangeSignal() : this(NDalicManualPINVOKE.new_PreFocusChangeSignal(), true) {
91 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();