Release 4.0.0-preview1-00301
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / ScrollViewEffect.cs
1 /*
2  * Copyright(c) 2017 Samsung Electronics Co., Ltd.
3  *
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
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
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.
15  *
16  */
17
18 namespace Tizen.NUI
19 {
20     /// <summary>
21     /// ScrollView Effect base class, used to apply custom effects to a
22     /// ScrollView instance.
23     /// </summary>
24     /// <since_tizen> 3 </since_tizen>
25     public class ScrollViewEffect : BaseHandle
26     {
27         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
28
29         internal ScrollViewEffect(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.ScrollViewEffect_SWIGUpcast(cPtr), cMemoryOwn)
30         {
31             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
32         }
33
34         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ScrollViewEffect obj)
35         {
36             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
37         }
38
39         /// <summary>
40         /// Dispose.
41         /// </summary>
42         /// <since_tizen> 3 </since_tizen>
43         protected override void Dispose(DisposeTypes type)
44         {
45             if (disposed)
46             {
47                 return;
48             }
49
50             if (type == DisposeTypes.Explicit)
51             {
52                 //Called by User
53                 //Release your own managed resources here.
54                 //You should release all of your own disposable objects here.
55
56             }
57
58             //Release your own unmanaged resources here.
59             //You should not access any managed member here except static instance.
60             //because the execution order of Finalizes is non-deterministic.
61
62             if (swigCPtr.Handle != global::System.IntPtr.Zero)
63             {
64                 if (swigCMemOwn)
65                 {
66                     swigCMemOwn = false;
67                     NDalicPINVOKE.delete_ScrollViewEffect(swigCPtr);
68                 }
69                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
70             }
71
72             base.Dispose(type);
73         }
74
75         /// <summary>
76         /// The constructor.
77         /// </summary>
78         /// <since_tizen> 3 </since_tizen>
79         public ScrollViewEffect() : this(NDalicPINVOKE.new_ScrollViewEffect(), true)
80         {
81             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
82         }
83
84     }
85
86 }