From 46b8a31f5c1c75a22b648ca394a4de8a50898513 Mon Sep 17 00:00:00 2001 From: dongsug-song <35130733+dongsug-song@users.noreply.github.com> Date: Wed, 18 Sep 2019 13:36:10 +0900 Subject: [PATCH] [NUI] Reduce code duplication - refactor dispose codes (#1010) * [NUI] Refactor disposable pattern in public folder * [NUI] Refactor disposable pattern in internal folder * [NUI] Fix tizenfx api version as 6 --- .../src/internal/AccessibilityActionSignal.cs | 40 +-- .../internal/AccessibilityFocusOvershotSignal.cs | 50 +--- src/Tizen.NUI/src/internal/AccessibilityManager.cs | 10 - src/Tizen.NUI/src/internal/ActivatedSignalType.cs | 60 +---- src/Tizen.NUI/src/internal/AdaptorSignalType.cs | 38 +-- src/Tizen.NUI/src/internal/Alignment.cs | 64 +---- src/Tizen.NUI/src/internal/AngleAxis.cs | 51 +--- src/Tizen.NUI/src/internal/AngleThresholdPair.cs | 49 +--- .../AnimatablePropertyComponentRegistration.cs | 49 +--- .../src/internal/AnimatablePropertyRegistration.cs | 51 +--- src/Tizen.NUI/src/internal/AnimationSignal.cs | 52 +--- src/Tizen.NUI/src/internal/Any.cs | 100 +------- src/Tizen.NUI/src/internal/Application.cs | 30 +-- .../src/internal/ApplicationControlSignal.cs | 52 +--- src/Tizen.NUI/src/internal/ApplicationSignal.cs | 51 +--- src/Tizen.NUI/src/internal/AsyncImageLoader.cs | 11 - .../src/internal/AuthenticationSignalType.cs | 63 +---- src/Tizen.NUI/src/internal/BaseObject.cs | 10 - src/Tizen.NUI/src/internal/BlendEquationType.cs | 2 - src/Tizen.NUI/src/internal/BlendFactorType.cs | 2 - src/Tizen.NUI/src/internal/BlendModeType.cs | 2 - src/Tizen.NUI/src/internal/BufferImage.cs | 24 +- src/Tizen.NUI/src/internal/Builder.cs | 28 +- src/Tizen.NUI/src/internal/ButtonSignal.cs | 51 +--- .../src/internal/ChildPropertyRegistration.cs | 51 +--- src/Tizen.NUI/src/internal/ConnectionTracker.cs | 11 - .../src/internal/ConnectionTrackerInterface.cs | 11 - .../src/internal/ContentReceivedSignalType.cs | 57 +---- src/Tizen.NUI/src/internal/ControlKeySignal.cs | 52 +--- src/Tizen.NUI/src/internal/CreateWidgetFunction.cs | 2 - src/Tizen.NUI/src/internal/CustomActor.cs | 11 - src/Tizen.NUI/src/internal/CustomActorImpl.cs | 13 +- .../src/internal/CustomAlgorithmInterface.cs | 50 +--- src/Tizen.NUI/src/internal/DaliEventHandler.cs | 9 +- src/Tizen.NUI/src/internal/DaliException.cs | 51 +--- .../src/internal/DefaultItemLayoutProperty.cs | 2 - src/Tizen.NUI/src/internal/DefaultRuler.cs | 10 - src/Tizen.NUI/src/internal/DepthFunctionType.cs | 2 - src/Tizen.NUI/src/internal/DepthTestModeType.cs | 2 - src/Tizen.NUI/src/internal/DepthWriteModeType.cs | 2 - src/Tizen.NUI/src/internal/DirectionType.cs | 2 - src/Tizen.NUI/src/internal/Disposable.cs | 89 +++++++ src/Tizen.NUI/src/internal/DisposeQueue.cs | 1 - src/Tizen.NUI/src/internal/EncodedBufferImage.cs | 11 - src/Tizen.NUI/src/internal/EventThreadCallback.cs | 53 +--- src/Tizen.NUI/src/internal/FaceCullingModeType.cs | 2 - src/Tizen.NUI/src/internal/FixedRuler.cs | 11 - src/Tizen.NUI/src/internal/FloatSignal.cs | 54 +--- src/Tizen.NUI/src/internal/FocusChangedSignal.cs | 53 +--- .../src/internal/FocusGroupChangedSignal.cs | 52 +--- src/Tizen.NUI/src/internal/FontDescription.cs | 51 +--- src/Tizen.NUI/src/internal/FontMetrics.cs | 51 +--- src/Tizen.NUI/src/internal/FrameBuffer.cs | 11 - src/Tizen.NUI/src/internal/FrameBufferImage.cs | 26 +- src/Tizen.NUI/src/internal/FriendAssembly.cs | 5 - src/Tizen.NUI/src/internal/GaussianBlurView.cs | 26 +- .../src/internal/GaussianBlurViewSignal.cs | 52 +--- src/Tizen.NUI/src/internal/GlyphInfo.cs | 51 +--- src/Tizen.NUI/src/internal/HoverSignal.cs | 54 +--- src/Tizen.NUI/src/internal/Image.cs | 21 +- src/Tizen.NUI/src/internal/ImageSignal.cs | 52 +--- src/Tizen.NUI/src/internal/InputMethodOptions.cs | 49 +--- src/Tizen.NUI/src/internal/Item.cs | 59 +---- src/Tizen.NUI/src/internal/ItemContainer.cs | 61 +---- src/Tizen.NUI/src/internal/ItemFactory.cs | 54 +--- src/Tizen.NUI/src/internal/ItemIdContainer.cs | 58 +---- src/Tizen.NUI/src/internal/ItemLayout.cs | 12 - src/Tizen.NUI/src/internal/ItemRange.cs | 57 +---- src/Tizen.NUI/src/internal/KeyEventSignal.cs | 51 +--- src/Tizen.NUI/src/internal/KeyInputFocusManager.cs | 10 - src/Tizen.NUI/src/internal/KeyInputFocusSignal.cs | 51 +--- .../src/internal/KeyboardEventSignalType.cs | 60 +---- .../src/internal/KeyboardResizedSignalType.cs | 59 +---- .../src/internal/KeyboardTypeSignalType.cs | 59 +---- .../src/internal/LanguageChangedSignalType.cs | 59 +---- .../src/internal/Layouting/LayoutController.cs | 34 +-- src/Tizen.NUI/src/internal/Layouting/LayoutItem.cs | 1 - src/Tizen.NUI/src/internal/ListEventSignalType.cs | 63 +---- src/Tizen.NUI/src/internal/LoadingState.cs | 2 - .../src/internal/LongPressGestureDetectedSignal.cs | 54 +--- src/Tizen.NUI/src/internal/LowBatterySignalType.cs | 60 +---- src/Tizen.NUI/src/internal/LowMemorySignalType.cs | 50 +--- src/Tizen.NUI/src/internal/Matrix.cs | 52 +--- src/Tizen.NUI/src/internal/Matrix3.cs | 51 +--- src/Tizen.NUI/src/internal/NDalic.cs | 4 - src/Tizen.NUI/src/internal/NUICoreBackend.cs | 18 +- src/Tizen.NUI/src/internal/NUIWidgetCoreBackend.cs | 1 - src/Tizen.NUI/src/internal/NativeImage.cs | 12 - src/Tizen.NUI/src/internal/NativeImageInterface.cs | 12 - src/Tizen.NUI/src/internal/Object.cs | 2 - src/Tizen.NUI/src/internal/ObjectCreatedSignal.cs | 51 +--- .../src/internal/ObjectDestroyedSignal.cs | 51 +--- src/Tizen.NUI/src/internal/ObjectRegistry.cs | 19 +- src/Tizen.NUI/src/internal/PageFactory.cs | 51 +--- src/Tizen.NUI/src/internal/PagePanSignal.cs | 51 +--- .../src/internal/PageTurnLandscapeView.cs | 10 - src/Tizen.NUI/src/internal/PageTurnPortraitView.cs | 13 +- src/Tizen.NUI/src/internal/PageTurnSignal.cs | 51 +--- .../src/internal/PanGestureDetectedSignal.cs | 52 +--- .../src/internal/PinchGestureDetectedSignal.cs | 52 +--- src/Tizen.NUI/src/internal/PreFocusChangeSignal.cs | 53 +--- .../src/internal/ProgressBarValueChangedSignal.cs | 51 +--- src/Tizen.NUI/src/internal/PropertyHelper.cs | 3 +- src/Tizen.NUI/src/internal/PropertyRangeManager.cs | 5 - src/Tizen.NUI/src/internal/PropertyRanges.cs | 2 - src/Tizen.NUI/src/internal/PropertyRegistration.cs | 51 +--- src/Tizen.NUI/src/internal/RefObject.cs | 55 +--- src/Tizen.NUI/src/internal/Registry.cs | 2 - src/Tizen.NUI/src/internal/RenderBufferFormat.cs | 2 - src/Tizen.NUI/src/internal/RenderModeType.cs | 2 - src/Tizen.NUI/src/internal/RenderTaskList.cs | 12 - src/Tizen.NUI/src/internal/RenderTaskSignal.cs | 51 +--- src/Tizen.NUI/src/internal/RenderingType.cs | 2 - src/Tizen.NUI/src/internal/ResizedSignal.cs | 49 +--- src/Tizen.NUI/src/internal/Ruler.cs | 10 - src/Tizen.NUI/src/internal/RulerDomain.cs | 58 +---- src/Tizen.NUI/src/internal/RulerPtr.cs | 57 +---- .../src/internal/SWIGTYPE_p_CallbackBase.cs | 1 - .../SWIGTYPE_p_Configuration__ContextLoss.cs | 2 - .../src/internal/SWIGTYPE_p_Dali__CallbackBase.cs | 1 - .../src/internal/SWIGTYPE_p_Dali__Constraint.cs | 2 - .../SWIGTYPE_p_Dali__CustomActorImpl__Extension.cs | 2 - .../internal/SWIGTYPE_p_Dali__FunctorDelegate.cs | 1 - .../internal/SWIGTYPE_p_Dali__Internal__Texture.cs | 2 - .../SWIGTYPE_p_Dali__Internal__TypeRegistry.cs | 2 - ...i__IntrusivePtrT_Dali__Toolkit__ItemLayout_t.cs | 2 - .../SWIGTYPE_p_Dali__RectT_unsigned_int_t.cs | 2 - .../src/internal/SWIGTYPE_p_Dali__RenderSurface.cs | 3 - ...ool_fDali__Actor_Dali__TouchEvent_const_RF_t.cs | 2 - ...ibilityManager_R_Dali__TouchEvent_const_RF_t.cs | 2 - ..._Dali__DevelActor__VisibilityChange__TypeF_t.cs | 2 - ...__Toolkit__Control_Dali__Toolkit__ControlF_t.cs | 2 - ...Editor_Dali__Toolkit__TextEditor__InputStyle.cs | 2 - ...ali__Toolkit__TextField__InputStyle__MaskF_t.cs | 2 - ...i__SignalT_void_fuint32_t_Dali__PixelDataF_t.cs | 2 - .../SWIGTYPE_p_Dali__Toolkit__ClampState.cs | 2 - ..._p_Dali__Toolkit__Internal__AsyncImageLoader.cs | 2 - ..._Dali__Toolkit__Internal__Control__Extension.cs | 2 - ...PE_p_Dali__Toolkit__Internal__TransitionData.cs | 2 - ...TYPE_p_Dali__Toolkit__Internal__Visual__Base.cs | 2 - ...TYPE_p_Dali__Toolkit__ItemFactory__Extension.cs | 2 - .../src/internal/SWIGTYPE_p_Dali__TouchEvent.cs | 2 - ...eTraitsT_uint32_t_t__IS_TRIVIAL_TYPE__true_t.cs | 2 - .../src/internal/SWIGTYPE_p_Dali__Widget__Impl.cs | 2 - .../src/internal/SWIGTYPE_p_FunctorDelegate.cs | 2 - .../internal/SWIGTYPE_p_KeyboardFocusManager.cs | 2 - .../internal/SWIGTYPE_p_PropertyInputContainer.cs | 2 - src/Tizen.NUI/src/internal/SWIGTYPE_p_double.cs | 2 - .../src/internal/SWIGTYPE_p_f_float__float.cs | 2 - ...Dali__Property__Index__Dali__Property__Value.cs | 2 - ...t_int_r_q_const__Dali__Property__Value__void.cs | 2 - ...aseObject_p_Dali__ConnectionTrackerInterface.cs | 2 - ..._string_r_q_const__Dali__Property__Map__bool.cs | 2 - ...p_q_const__Dali__Any__AnyContainerBase__void.cs | 2 - .../internal/SWIGTYPE_p_f_r_Dali__Vector2__bool.cs | 2 - ...ContainerBase__p_Dali__Any__AnyContainerBase.cs | 2 - ...SWIGTYPE_p_f_r_q_const__Dali__Vector3__float.cs | 2 - src/Tizen.NUI/src/internal/SWIGTYPE_p_float.cs | 2 - src/Tizen.NUI/src/internal/SWIGTYPE_p_int.cs | 2 - ...IGTYPE_p_p_Dali__TextAbstraction__VectorBlob.cs | 2 - .../src/internal/SWIGTYPE_p_std__type_info.cs | 2 - ...orT_Dali__TextAbstraction__FontDescription_t.cs | 2 - src/Tizen.NUI/src/internal/SWIGTYPE_p_time_t.cs | 2 - src/Tizen.NUI/src/internal/SWIGTYPE_p_tm.cs | 1 - src/Tizen.NUI/src/internal/SWIGTYPE_p_uint16_t.cs | 1 - src/Tizen.NUI/src/internal/SWIGTYPE_p_uint8_t.cs | 2 - .../src/internal/SWIGTYPE_p_unsigned_char.cs | 2 - .../src/internal/SWIGTYPE_p_unsigned_int.cs | 2 - .../src/internal/SWIGTYPE_p_unsigned_short.cs | 2 - .../src/internal/ScrollStateChangedSignal.cs | 50 +--- .../src/internal/ScrollViewSnapStartedSignal.cs | 51 +--- src/Tizen.NUI/src/internal/ScrollableSignal.cs | 51 +--- src/Tizen.NUI/src/internal/SignalConnectorType.cs | 51 +--- src/Tizen.NUI/src/internal/SignalObserver.cs | 61 +---- .../src/internal/SliderMarkReachedSignal.cs | 51 +--- .../src/internal/SliderValueChangedSignal.cs | 51 +--- src/Tizen.NUI/src/internal/SlotObserver.cs | 63 +---- src/Tizen.NUI/src/internal/SnapType.cs | 2 - src/Tizen.NUI/src/internal/StageWheelSignal.cs | 51 +--- .../src/internal/StateChangedSignalType.cs | 48 +--- src/Tizen.NUI/src/internal/StatusSignalType.cs | 60 +---- src/Tizen.NUI/src/internal/StencilFunctionType.cs | 2 - src/Tizen.NUI/src/internal/StencilOperationType.cs | 2 - src/Tizen.NUI/src/internal/StringValuePair.cs | 51 +--- src/Tizen.NUI/src/internal/StyleChangedSignal.cs | 51 +--- .../src/internal/TapGestureDetectedSignal.cs | 50 +--- src/Tizen.NUI/src/internal/TextEditorSignal.cs | 50 +--- src/Tizen.NUI/src/internal/TextFieldSignal.cs | 51 +--- src/Tizen.NUI/src/internal/TimePeriod.cs | 51 +--- src/Tizen.NUI/src/internal/TimerSignalType.cs | 53 +--- src/Tizen.NUI/src/internal/ToolkitPropertyRange.cs | 2 - src/Tizen.NUI/src/internal/TooltipPositionType.cs | 2 - src/Tizen.NUI/src/internal/TouchDataSignal.cs | 52 +--- src/Tizen.NUI/src/internal/TouchPoint.cs | 53 +--- src/Tizen.NUI/src/internal/TouchPointContainer.cs | 53 +--- src/Tizen.NUI/src/internal/TouchSignal.cs | 51 +--- src/Tizen.NUI/src/internal/TypeAction.cs | 51 +--- src/Tizen.NUI/src/internal/TypeRegistration.cs | 50 +--- src/Tizen.NUI/src/internal/Uint16Pair.cs | 60 +---- src/Tizen.NUI/src/internal/VectorBase.cs | 51 +--- src/Tizen.NUI/src/internal/VectorBlob.cs | 49 +--- src/Tizen.NUI/src/internal/VectorUint16Pair.cs | 52 +--- src/Tizen.NUI/src/internal/VectorUnsignedChar.cs | 52 +--- src/Tizen.NUI/src/internal/VideoViewSignal.cs | 133 ++++------ src/Tizen.NUI/src/internal/ViewImpl.cs | 11 - .../internal/ViewLayoutDirectionChangedSignal.cs | 48 +--- .../src/internal/ViewResourceReadySignal.cs | 50 +--- src/Tizen.NUI/src/internal/ViewSignal.cs | 53 +--- .../src/internal/ViewVisibilityChangedSignal.cs | 50 +--- src/Tizen.NUI/src/internal/ViewWrapperImpl.cs | 9 +- src/Tizen.NUI/src/internal/VisualEventSignal.cs | 45 +--- src/Tizen.NUI/src/internal/VoidSignal.cs | 51 +--- src/Tizen.NUI/src/internal/WatchApplication.cs | 11 +- src/Tizen.NUI/src/internal/WatchBoolSignal.cs | 50 +--- src/Tizen.NUI/src/internal/WatchTimeSignal.cs | 50 +--- src/Tizen.NUI/src/internal/WeakEventHandler.cs | 3 +- .../src/internal/WebViewPageLoadErrorSignal.cs | 43 +--- .../src/internal/WebViewPageLoadSignal.cs | 43 +--- src/Tizen.NUI/src/internal/WheelSignal.cs | 53 +--- src/Tizen.NUI/src/internal/WidgetApplication.cs | 7 - src/Tizen.NUI/src/internal/WidgetImpl.cs | 7 - src/Tizen.NUI/src/internal/WidgetImplPtr.cs | 1 - src/Tizen.NUI/src/internal/WidgetViewSignal.cs | 33 +-- .../src/internal/WindowFocusSignalType.cs | 52 +--- src/Tizen.NUI/src/internal/doublep.cs | 51 +--- src/Tizen.NUI/src/internal/floatp.cs | 51 +--- src/Tizen.NUI/src/internal/intp.cs | 51 +--- src/Tizen.NUI/src/internal/uintp.cs | 51 +--- src/Tizen.NUI/src/internal/ushortp.cs | 51 +--- src/Tizen.NUI/src/public/Adaptor.cs | 56 +--- src/Tizen.NUI/src/public/AlphaFunction.cs | 57 +---- src/Tizen.NUI/src/public/Animatable.cs | 10 - src/Tizen.NUI/src/public/Animation.cs | 13 - src/Tizen.NUI/src/public/AutofillContainer.cs | 8 - .../BaseComponents/AnimatedVectorImageView.cs | 7 - .../src/public/BaseComponents/FlexContainer.cs | 7 - .../src/public/BaseComponents/TableView.cs | 66 +---- .../src/public/BaseComponents/TextEditor.cs | 8 - .../src/public/BaseComponents/TextField.cs | 13 +- .../src/public/BaseComponents/TextLabel.cs | 7 - .../public/BaseComponents/VectorAnimationView.cs | 7 - .../src/public/BaseComponents/VideoView.cs | 7 - src/Tizen.NUI/src/public/BaseComponents/View.cs | 7 - src/Tizen.NUI/src/public/Color.cs | 59 +---- src/Tizen.NUI/src/public/Container.cs | 1 - src/Tizen.NUI/src/public/CubeTransitionEffect.cs | 8 - src/Tizen.NUI/src/public/CustomViewRegistry.cs | 2 - src/Tizen.NUI/src/public/Degree.cs | 62 +---- src/Tizen.NUI/src/public/DirectionBias.cs | 1 - src/Tizen.NUI/src/public/Extents.cs | 60 +---- src/Tizen.NUI/src/public/FilterModeType.cs | 1 - src/Tizen.NUI/src/public/FontClient.cs | 48 +--- src/Tizen.NUI/src/public/Geometry.cs | 10 - src/Tizen.NUI/src/public/Gesture.cs | 59 +---- src/Tizen.NUI/src/public/GestureDetector.cs | 8 - src/Tizen.NUI/src/public/GraphicsTypeConverter.cs | 2 - src/Tizen.NUI/src/public/GraphicsTypeManager.cs | 1 - src/Tizen.NUI/src/public/Hover.cs | 58 +---- src/Tizen.NUI/src/public/InputMethodContext.cs | 8 - src/Tizen.NUI/src/public/Key.cs | 58 +---- src/Tizen.NUI/src/public/KeyFrames.cs | 7 - src/Tizen.NUI/src/public/Layer.cs | 9 - src/Tizen.NUI/src/public/LongPressGesture.cs | 7 - .../src/public/LongPressGestureDetector.cs | 8 - src/Tizen.NUI/src/public/PaddingType.cs | 60 +---- src/Tizen.NUI/src/public/PanGesture.cs | 10 - src/Tizen.NUI/src/public/Path.cs | 11 - src/Tizen.NUI/src/public/PinchGesture.cs | 10 - src/Tizen.NUI/src/public/PinchGestureDetector.cs | 13 - src/Tizen.NUI/src/public/PixelBuffer.cs | 10 - src/Tizen.NUI/src/public/PixelData.cs | 9 - src/Tizen.NUI/src/public/Position.cs | 58 +---- src/Tizen.NUI/src/public/Position2D.cs | 64 +---- src/Tizen.NUI/src/public/Property.cs | 284 ++------------------- src/Tizen.NUI/src/public/PropertyBuffer.cs | 10 - src/Tizen.NUI/src/public/PropertyCondition.cs | 11 +- src/Tizen.NUI/src/public/PropertyNotification.cs | 10 - src/Tizen.NUI/src/public/PropertyNotifySignal.cs | 60 +---- src/Tizen.NUI/src/public/Radian.cs | 58 +---- src/Tizen.NUI/src/public/Rectangle.cs | 56 +--- src/Tizen.NUI/src/public/RelativeVector2.cs | 58 +---- src/Tizen.NUI/src/public/RelativeVector3.cs | 58 +---- src/Tizen.NUI/src/public/RelativeVector4.cs | 58 +---- src/Tizen.NUI/src/public/RelayoutContainer.cs | 58 +---- src/Tizen.NUI/src/public/Rotation.cs | 59 +---- src/Tizen.NUI/src/public/Sampler.cs | 10 - src/Tizen.NUI/src/public/ScrollViewEffect.cs | 8 - .../src/public/ScrollViewPagePathEffect.cs | 8 - src/Tizen.NUI/src/public/Size.cs | 57 +---- src/Tizen.NUI/src/public/Size2D.cs | 58 +---- src/Tizen.NUI/src/public/TapGesture.cs | 8 - src/Tizen.NUI/src/public/TapGestureDetector.cs | 10 - src/Tizen.NUI/src/public/Texture.cs | 10 - src/Tizen.NUI/src/public/TextureSet.cs | 10 - src/Tizen.NUI/src/public/Timer.cs | 7 - src/Tizen.NUI/src/public/Touch.cs | 8 - src/Tizen.NUI/src/public/TransitionData.cs | 10 - src/Tizen.NUI/src/public/TypeInfo.cs | 10 - src/Tizen.NUI/src/public/TypeRegistry.cs | 11 - src/Tizen.NUI/src/public/UIComponents/Button.cs | 8 - .../src/public/UIComponents/CheckBoxButton.cs | 7 - src/Tizen.NUI/src/public/UIComponents/Popup.cs | 8 - .../src/public/UIComponents/ProgressBar.cs | 8 - .../src/public/UIComponents/PushButton.cs | 7 - .../src/public/UIComponents/RadioButton.cs | 8 - src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs | 7 - src/Tizen.NUI/src/public/UIComponents/Slider.cs | 8 - src/Tizen.NUI/src/public/Vector2.cs | 56 +--- src/Tizen.NUI/src/public/Vector3.cs | 56 +--- src/Tizen.NUI/src/public/Vector4.cs | 57 +---- src/Tizen.NUI/src/public/ViewWrapper.cs | 8 - src/Tizen.NUI/src/public/VisualBase.cs | 9 - src/Tizen.NUI/src/public/WatchTime.cs | 57 +---- src/Tizen.NUI/src/public/Wheel.cs | 61 +---- src/Tizen.NUI/src/public/Widget.cs | 7 - src/Tizen.NUI/src/public/WidgetView.cs | 9 - src/Tizen.NUI/src/public/WidgetViewManager.cs | 10 - 317 files changed, 667 insertions(+), 8396 deletions(-) create mode 100755 src/Tizen.NUI/src/internal/Disposable.cs mode change 100644 => 100755 src/Tizen.NUI/src/internal/WebViewPageLoadErrorSignal.cs mode change 100644 => 100755 src/Tizen.NUI/src/internal/WebViewPageLoadSignal.cs diff --git a/src/Tizen.NUI/src/internal/AccessibilityActionSignal.cs b/src/Tizen.NUI/src/internal/AccessibilityActionSignal.cs index d78a25d..d1bca05 100755 --- a/src/Tizen.NUI/src/internal/AccessibilityActionSignal.cs +++ b/src/Tizen.NUI/src/internal/AccessibilityActionSignal.cs @@ -18,7 +18,7 @@ namespace Tizen.NUI { - internal class AccessibilityActionSignal : global::System.IDisposable + internal class AccessibilityActionSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,40 +34,7 @@ namespace Tizen.NUI 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; - - ~AccessibilityActionSignal() - { - 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) + protected override void Dispose(DisposeTypes type) { if (disposed) { @@ -99,7 +66,6 @@ namespace Tizen.NUI disposed = true; } - public bool Empty() { bool ret = Interop.AccessibilityManage.AccessibilityActionSignal_Empty(swigCPtr); @@ -143,7 +109,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/AccessibilityFocusOvershotSignal.cs b/src/Tizen.NUI/src/internal/AccessibilityFocusOvershotSignal.cs index 72be9ef..07f6162 100755 --- a/src/Tizen.NUI/src/internal/AccessibilityFocusOvershotSignal.cs +++ b/src/Tizen.NUI/src/internal/AccessibilityFocusOvershotSignal.cs @@ -18,7 +18,7 @@ namespace Tizen.NUI { using Tizen.NUI.BaseComponents; - internal class AccessibilityFocusOvershotSignal : global::System.IDisposable + internal class AccessibilityFocusOvershotSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +34,12 @@ namespace Tizen.NUI 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; - - ~AccessibilityFocusOvershotSignal() - { - 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) + 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. @@ -96,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -141,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/AccessibilityManager.cs b/src/Tizen.NUI/src/internal/AccessibilityManager.cs index 96ddfbe..0d92ca1 100755 --- a/src/Tizen.NUI/src/internal/AccessibilityManager.cs +++ b/src/Tizen.NUI/src/internal/AccessibilityManager.cs @@ -43,14 +43,6 @@ namespace Tizen.NUI 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. @@ -2776,7 +2768,5 @@ namespace Tizen.NUI OVERSHOT_PREVIOUS = -1, OVERSHOT_NEXT = 1 } - } - } diff --git a/src/Tizen.NUI/src/internal/ActivatedSignalType.cs b/src/Tizen.NUI/src/internal/ActivatedSignalType.cs index c06628d..1f8dfb6 100755 --- a/src/Tizen.NUI/src/internal/ActivatedSignalType.cs +++ b/src/Tizen.NUI/src/internal/ActivatedSignalType.cs @@ -20,7 +20,7 @@ using System.ComponentModel; namespace Tizen.NUI { - internal class ActivatedSignalType : global::System.IDisposable + internal class ActivatedSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -40,69 +40,17 @@ namespace Tizen.NUI 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. - /// - /// 3 - protected bool disposed = false; - /// /// Dispose /// /// 3 - ~ActivatedSignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose - /// - /// 3 - 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); - } - } - - /// - /// Dispose - /// - /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -117,7 +65,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -191,7 +139,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/AdaptorSignalType.cs b/src/Tizen.NUI/src/internal/AdaptorSignalType.cs index ea7891a..585d0e6 100755 --- a/src/Tizen.NUI/src/internal/AdaptorSignalType.cs +++ b/src/Tizen.NUI/src/internal/AdaptorSignalType.cs @@ -18,13 +18,7 @@ using System.ComponentModel; namespace Tizen.NUI { - /// - /// public class AdaptorSignalType : global::System.IDisposable - /// - /// 4 - /// This will be changed internal API after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - public class AdaptorSignalType : global::System.IDisposable + internal class AdaptorSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -49,35 +43,21 @@ namespace Tizen.NUI /// /// Dispose /// - /// 3 - /// This will be changed internal API after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - ~AdaptorSignalType() - { - Dispose(); - } - - /// - /// Dispose - /// /// 4 /// This will be changed internal API after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public virtual void Dispose() + protected override void Dispose(DisposeTypes type) { - lock (this) + if (swigCPtr.Handle != global::System.IntPtr.Zero) { - if (swigCPtr.Handle != global::System.IntPtr.Zero) + if (swigCMemOwn) { - if (swigCMemOwn) - { - swigCMemOwn = false; - Interop.Adaptor.delete_AdaptorSignalType(swigCPtr); - } - swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); + swigCMemOwn = false; + Interop.Adaptor.delete_AdaptorSignalType(swigCPtr); } - global::System.GC.SuppressFinalize(this); + swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } + base.Dispose(type); } /// @@ -163,7 +143,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/Alignment.cs b/src/Tizen.NUI/src/internal/Alignment.cs index 377a090..08e4ef2 100755 --- a/src/Tizen.NUI/src/internal/Alignment.cs +++ b/src/Tizen.NUI/src/internal/Alignment.cs @@ -41,14 +41,6 @@ namespace Tizen.NUI 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. @@ -66,10 +58,8 @@ namespace Tizen.NUI base.Dispose(type); } - - /// 3 - public new class Padding : global::System.IDisposable + public new class Padding : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// 3 @@ -85,58 +75,15 @@ namespace Tizen.NUI { 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. - /// 3 - protected bool disposed = false; - - ~Padding() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// 3 - 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); - } - } - + /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -151,7 +98,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// 3 @@ -229,7 +176,6 @@ namespace Tizen.NUI return ret; } } - } public Alignment(Alignment.Type horizontal, Alignment.Type vertical) : this(Interop.Alignment.Alignment_New__SWIG_0((int)horizontal, (int)vertical), true) @@ -326,7 +272,5 @@ namespace Tizen.NUI ShrinkToFit, ShrinkToFitKeepAspect } - } - } diff --git a/src/Tizen.NUI/src/internal/AngleAxis.cs b/src/Tizen.NUI/src/internal/AngleAxis.cs index e83939e..0d35be4 100755 --- a/src/Tizen.NUI/src/internal/AngleAxis.cs +++ b/src/Tizen.NUI/src/internal/AngleAxis.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class AngleAxis : global::System.IDisposable + internal class AngleAxis : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +33,13 @@ namespace Tizen.NUI 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; - - ~AngleAxis() - { - 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) + 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. @@ -96,10 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public AngleAxis() : this(Interop.AngleAxis.new_AngleAxis__SWIG_0(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); @@ -141,7 +98,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/AngleThresholdPair.cs b/src/Tizen.NUI/src/internal/AngleThresholdPair.cs index eefe171..e4a6bbe 100755 --- a/src/Tizen.NUI/src/internal/AngleThresholdPair.cs +++ b/src/Tizen.NUI/src/internal/AngleThresholdPair.cs @@ -18,7 +18,7 @@ namespace Tizen.NUI { - internal class AngleThresholdPair : global::System.IDisposable + internal class AngleThresholdPair : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +34,13 @@ namespace Tizen.NUI 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; - - ~AngleThresholdPair() - { - 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) + 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. @@ -96,7 +55,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public AngleThresholdPair() : this(Interop.AngleThresholdPair.new_AngleThresholdPair__SWIG_0(), true) @@ -145,7 +104,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/AnimatablePropertyComponentRegistration.cs b/src/Tizen.NUI/src/internal/AnimatablePropertyComponentRegistration.cs index ccffa3e..9177bc5 100755 --- a/src/Tizen.NUI/src/internal/AnimatablePropertyComponentRegistration.cs +++ b/src/Tizen.NUI/src/internal/AnimatablePropertyComponentRegistration.cs @@ -18,7 +18,7 @@ namespace Tizen.NUI { - internal class AnimatablePropertyComponentRegistration : global::System.IDisposable + internal class AnimatablePropertyComponentRegistration : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +34,13 @@ namespace Tizen.NUI 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; - - ~AnimatablePropertyComponentRegistration() - { - 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) + 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. @@ -96,7 +55,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -104,7 +63,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/AnimatablePropertyRegistration.cs b/src/Tizen.NUI/src/internal/AnimatablePropertyRegistration.cs index f6abc74..71956fb 100755 --- a/src/Tizen.NUI/src/internal/AnimatablePropertyRegistration.cs +++ b/src/Tizen.NUI/src/internal/AnimatablePropertyRegistration.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class AnimatablePropertyRegistration : global::System.IDisposable + internal class AnimatablePropertyRegistration : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +33,13 @@ namespace Tizen.NUI 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; - - ~AnimatablePropertyRegistration() - { - 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) + 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. @@ -96,10 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public AnimatablePropertyRegistration(TypeRegistration registered, string name, int index, PropertyType type) : this(Interop.NDalic.new_AnimatablePropertyRegistration__SWIG_0(TypeRegistration.getCPtr(registered), name, index, (int)type), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); @@ -109,7 +66,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/AnimationSignal.cs b/src/Tizen.NUI/src/internal/AnimationSignal.cs index fb53d65..2fa28f8 100755 --- a/src/Tizen.NUI/src/internal/AnimationSignal.cs +++ b/src/Tizen.NUI/src/internal/AnimationSignal.cs @@ -18,7 +18,7 @@ namespace Tizen.NUI { - internal class AnimationSignal : global::System.IDisposable + internal class AnimationSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +34,13 @@ namespace Tizen.NUI 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; - - ~AnimationSignal() - { - 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) + 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. @@ -96,10 +55,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.Animation.AnimationSignal_Empty(swigCPtr); @@ -123,7 +81,6 @@ namespace Tizen.NUI } } - public void Connect(System.IntPtr callback) { Interop.Animation.AnimationSignal_Connect(swigCPtr, new System.Runtime.InteropServices.HandleRef(this, callback)); @@ -135,7 +92,6 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - public void Disconnect(System.Delegate func) { System.IntPtr ip = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate(func); @@ -155,7 +111,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/Any.cs b/src/Tizen.NUI/src/internal/Any.cs index 71532a4..68db9c8 100755 --- a/src/Tizen.NUI/src/internal/Any.cs +++ b/src/Tizen.NUI/src/internal/Any.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class Any : global::System.IDisposable + internal class Any : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +33,13 @@ namespace Tizen.NUI 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; - - ~Any() - { - 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) + 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. @@ -96,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -138,7 +96,7 @@ namespace Tizen.NUI } /// 3 - public class AnyContainerBase : global::System.IDisposable + public class AnyContainerBase : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// 3 @@ -155,57 +113,14 @@ namespace Tizen.NUI 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. - /// 3 - protected bool disposed = false; - - ~AnyContainerBase() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// 3 - 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); - } - } - - /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -220,7 +135,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// 3 @@ -281,7 +196,6 @@ namespace Tizen.NUI return ret; } } - } public Any.AnyContainerBase mContainer @@ -299,7 +213,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/Application.cs b/src/Tizen.NUI/src/internal/Application.cs index 43bb36f..228492c 100755 --- a/src/Tizen.NUI/src/internal/Application.cs +++ b/src/Tizen.NUI/src/internal/Application.cs @@ -14,20 +14,18 @@ * limitations under the License. * */ +using System; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.ComponentModel; +using System.Runtime.InteropServices; +using System.Threading; +using System.Threading.Tasks; +using Tizen.NUI.Binding; +using Tizen.NUI.Binding.Internals; namespace Tizen.NUI { - - using System; - using System.Collections.Generic; - using System.Collections.ObjectModel; - using System.ComponentModel; - using System.Runtime.InteropServices; - using System.Threading; - using System.Threading.Tasks; - using Tizen.NUI.Binding; - using Tizen.NUI.Binding.Internals; - /** * @brief Event arguments that passed via NUIApplicationInit signal * @@ -476,14 +474,6 @@ namespace Tizen.NUI 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. @@ -1481,7 +1471,5 @@ namespace Tizen.NUI Opaque = 0, Transparent = 1 } - } - } diff --git a/src/Tizen.NUI/src/internal/ApplicationControlSignal.cs b/src/Tizen.NUI/src/internal/ApplicationControlSignal.cs index 337eea8..8e36d1b 100755 --- a/src/Tizen.NUI/src/internal/ApplicationControlSignal.cs +++ b/src/Tizen.NUI/src/internal/ApplicationControlSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ApplicationControlSignal : global::System.IDisposable + internal class ApplicationControlSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +33,13 @@ namespace Tizen.NUI 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; - - ~ApplicationControlSignal() - { - 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) + 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. @@ -96,11 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - - public bool Empty() { bool ret = Interop.ApplicationControlSignal.ApplicationControlSignal_Empty(swigCPtr); @@ -143,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ApplicationSignal.cs b/src/Tizen.NUI/src/internal/ApplicationSignal.cs index f08a5aa..2473a54 100755 --- a/src/Tizen.NUI/src/internal/ApplicationSignal.cs +++ b/src/Tizen.NUI/src/internal/ApplicationSignal.cs @@ -18,7 +18,7 @@ namespace Tizen.NUI { - internal class ApplicationSignal : global::System.IDisposable + internal class ApplicationSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +34,13 @@ namespace Tizen.NUI 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; - - ~ApplicationSignal() - { - 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) + 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. @@ -96,11 +55,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - - public bool Empty() { bool ret = Interop.ApplicationSignal.ApplicationSignal_Empty(swigCPtr); @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/AsyncImageLoader.cs b/src/Tizen.NUI/src/internal/AsyncImageLoader.cs index 931c349..1632ed2 100755 --- a/src/Tizen.NUI/src/internal/AsyncImageLoader.cs +++ b/src/Tizen.NUI/src/internal/AsyncImageLoader.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class AsyncImageLoader : BaseHandle { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,14 +38,6 @@ namespace Tizen.NUI 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. @@ -128,7 +119,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/AuthenticationSignalType.cs b/src/Tizen.NUI/src/internal/AuthenticationSignalType.cs index 07b54a4..1a8b9c3 100755 --- a/src/Tizen.NUI/src/internal/AuthenticationSignalType.cs +++ b/src/Tizen.NUI/src/internal/AuthenticationSignalType.cs @@ -20,7 +20,7 @@ using System.ComponentModel; namespace Tizen.NUI { - internal class AuthenticationSignalType : global::System.IDisposable + internal class AuthenticationSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -41,73 +41,18 @@ namespace Tizen.NUI 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. - /// - /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - protected bool disposed = false; - - /// - /// Dispose - /// - /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - ~AuthenticationSignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose - /// - /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - 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); - } - } - /// /// Dispose /// /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -122,7 +67,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -201,7 +146,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/BaseObject.cs b/src/Tizen.NUI/src/internal/BaseObject.cs index c9a0853..1578b53 100755 --- a/src/Tizen.NUI/src/internal/BaseObject.cs +++ b/src/Tizen.NUI/src/internal/BaseObject.cs @@ -40,14 +40,6 @@ namespace Tizen.NUI 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. @@ -92,7 +84,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/BlendEquationType.cs b/src/Tizen.NUI/src/internal/BlendEquationType.cs index bfb0c74..cf6e4e4 100755 --- a/src/Tizen.NUI/src/internal/BlendEquationType.cs +++ b/src/Tizen.NUI/src/internal/BlendEquationType.cs @@ -17,12 +17,10 @@ namespace Tizen.NUI { - internal enum BlendEquationType { ADD = 0x8006, SUBTRACT = 0x800A, REVERSE_SUBTRACT = 0x800B } - } diff --git a/src/Tizen.NUI/src/internal/BlendFactorType.cs b/src/Tizen.NUI/src/internal/BlendFactorType.cs index 9fc34a5..7d4e89e 100755 --- a/src/Tizen.NUI/src/internal/BlendFactorType.cs +++ b/src/Tizen.NUI/src/internal/BlendFactorType.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal enum BlendFactorType { ZERO = 0, @@ -36,5 +35,4 @@ namespace Tizen.NUI CONSTANT_ALPHA = 0x8003, ONE_MINUS_CONSTANT_ALPHA = 0x8004 } - } diff --git a/src/Tizen.NUI/src/internal/BlendModeType.cs b/src/Tizen.NUI/src/internal/BlendModeType.cs index 4a19abf..686d7f7 100755 --- a/src/Tizen.NUI/src/internal/BlendModeType.cs +++ b/src/Tizen.NUI/src/internal/BlendModeType.cs @@ -17,12 +17,10 @@ namespace Tizen.NUI { - internal enum BlendModeType { OFF, AUTO, ON } - } diff --git a/src/Tizen.NUI/src/internal/BufferImage.cs b/src/Tizen.NUI/src/internal/BufferImage.cs index b75bda5..87a3eb4 100755 --- a/src/Tizen.NUI/src/internal/BufferImage.cs +++ b/src/Tizen.NUI/src/internal/BufferImage.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class BufferImage : Image { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,19 +38,10 @@ namespace Tizen.NUI 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) @@ -65,33 +55,31 @@ namespace Tizen.NUI base.Dispose(type); } - - public BufferImage(uint width, uint height, PixelFormat pixelformat) : this(Interop.BufferImage.BufferImage_New__SWIG_0(width, height, (int)pixelformat), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public BufferImage(uint width, uint height) : this(Interop.BufferImage.BufferImage_New__SWIG_1(width, height), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public BufferImage(byte[] pixelBuffer, uint width, uint height, PixelFormat pixelFormat, uint stride) : this(Interop.BufferImage.BufferImage_New__SWIG_2(pixelBuffer, width, height, (int)pixelFormat, stride), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public BufferImage(byte[] pixelBuffer, uint width, uint height, PixelFormat pixelFormat) : this(Interop.BufferImage.BufferImage_New__SWIG_3(pixelBuffer, width, height, (int)pixelFormat), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public BufferImage(byte[] pixelBuffer, uint width, uint height) : this(Interop.BufferImage.BufferImage_New__SWIG_4(pixelBuffer, width, height), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public new static BufferImage DownCast(BaseHandle handle) { BufferImage ret = Registry.GetManagedBaseHandleFromNativePtr(handle) as BufferImage; @@ -165,7 +153,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/Builder.cs b/src/Tizen.NUI/src/internal/Builder.cs index ef00e45..8752f83 100755 --- a/src/Tizen.NUI/src/internal/Builder.cs +++ b/src/Tizen.NUI/src/internal/Builder.cs @@ -15,14 +15,12 @@ * */ +using System; +using System.Runtime.InteropServices; +using Tizen.NUI.BaseComponents; + namespace Tizen.NUI { - - using System; - using System.Runtime.InteropServices; - using Tizen.NUI.BaseComponents; - - internal class Builder : BaseHandle { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -44,19 +42,9 @@ namespace Tizen.NUI 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) @@ -70,8 +58,6 @@ namespace Tizen.NUI base.Dispose(type); } - - /// 3 public class QuitEventArgs : EventArgs { @@ -148,13 +134,11 @@ namespace Tizen.NUI } } - - public Builder() : this(Interop.Builder.Builder_New(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public void LoadFromString(string data, Builder.UIFormat format) { Interop.Builder.Builder_LoadFromString__SWIG_0(swigCPtr, data, (int)format); @@ -307,7 +291,5 @@ namespace Tizen.NUI { JSON } - } - } diff --git a/src/Tizen.NUI/src/internal/ButtonSignal.cs b/src/Tizen.NUI/src/internal/ButtonSignal.cs index 42da6fa..73d834a 100755 --- a/src/Tizen.NUI/src/internal/ButtonSignal.cs +++ b/src/Tizen.NUI/src/internal/ButtonSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ButtonSignal : global::System.IDisposable + internal class ButtonSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +33,13 @@ namespace Tizen.NUI 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; - - ~ButtonSignal() - { - 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) + 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. @@ -96,10 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.ButtonSignal.ButtonSignal_Empty(swigCPtr); @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ChildPropertyRegistration.cs b/src/Tizen.NUI/src/internal/ChildPropertyRegistration.cs index 6244046..e54ad5a 100755 --- a/src/Tizen.NUI/src/internal/ChildPropertyRegistration.cs +++ b/src/Tizen.NUI/src/internal/ChildPropertyRegistration.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ChildPropertyRegistration : global::System.IDisposable + internal class ChildPropertyRegistration : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +33,13 @@ namespace Tizen.NUI 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; - - ~ChildPropertyRegistration() - { - 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) + 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. @@ -96,15 +54,12 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public ChildPropertyRegistration(TypeRegistration registered, string name, int index, PropertyType type) : this(Interop.NDalic.new_ChildPropertyRegistration(TypeRegistration.getCPtr(registered), name, index, (int)type), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ConnectionTracker.cs b/src/Tizen.NUI/src/internal/ConnectionTracker.cs index ed07317..3f81d22 100755 --- a/src/Tizen.NUI/src/internal/ConnectionTracker.cs +++ b/src/Tizen.NUI/src/internal/ConnectionTracker.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class ConnectionTracker : ConnectionTrackerInterface { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,14 +38,6 @@ namespace Tizen.NUI 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. @@ -88,7 +79,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/ConnectionTrackerInterface.cs b/src/Tizen.NUI/src/internal/ConnectionTrackerInterface.cs index c47eada..532309e 100755 --- a/src/Tizen.NUI/src/internal/ConnectionTrackerInterface.cs +++ b/src/Tizen.NUI/src/internal/ConnectionTrackerInterface.cs @@ -45,14 +45,6 @@ namespace Tizen.NUI 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. @@ -70,7 +62,6 @@ namespace Tizen.NUI base.Dispose(type); } - /// /// Called when a signal is connected. /// @@ -82,7 +73,5 @@ namespace Tizen.NUI Interop.ConnectionTracker.ConnectionTrackerInterface_SignalConnected(swigCPtr, SlotObserver.getCPtr(slotObserver), SWIGTYPE_p_CallbackBase.getCPtr(callback)); if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ContentReceivedSignalType.cs b/src/Tizen.NUI/src/internal/ContentReceivedSignalType.cs index b24b5fd..d0fa143 100755 --- a/src/Tizen.NUI/src/internal/ContentReceivedSignalType.cs +++ b/src/Tizen.NUI/src/internal/ContentReceivedSignalType.cs @@ -20,7 +20,7 @@ using System.ComponentModel; namespace Tizen.NUI { - internal class ContentReceivedSignalType : global::System.IDisposable + internal class ContentReceivedSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -39,65 +39,16 @@ namespace Tizen.NUI 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; - - /// - /// Dispose - /// - ~ContentReceivedSignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose - /// - 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); - } - } - /// /// Dispose /// - protected virtual void Dispose(DisposeTypes type) + 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. @@ -111,7 +62,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -181,7 +132,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ControlKeySignal.cs b/src/Tizen.NUI/src/internal/ControlKeySignal.cs index b8c4089..011c83c 100755 --- a/src/Tizen.NUI/src/internal/ControlKeySignal.cs +++ b/src/Tizen.NUI/src/internal/ControlKeySignal.cs @@ -19,8 +19,7 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - - internal class ControlKeySignal : global::System.IDisposable + internal class ControlKeySignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -36,55 +35,13 @@ namespace Tizen.NUI 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; - - - ~ControlKeySignal() - { - 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) + 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. @@ -99,10 +56,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.ControlKeySignal.ControlKeySignal_Empty(swigCPtr); @@ -146,7 +102,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/CreateWidgetFunction.cs b/src/Tizen.NUI/src/internal/CreateWidgetFunction.cs index 29d2cfb..5edb3d2 100755 --- a/src/Tizen.NUI/src/internal/CreateWidgetFunction.cs +++ b/src/Tizen.NUI/src/internal/CreateWidgetFunction.cs @@ -16,7 +16,6 @@ */ namespace Tizen.NUI { - internal class CreateWidgetFunction { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -36,5 +35,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/CustomActor.cs b/src/Tizen.NUI/src/internal/CustomActor.cs index a97098a..aab57d2 100755 --- a/src/Tizen.NUI/src/internal/CustomActor.cs +++ b/src/Tizen.NUI/src/internal/CustomActor.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class CustomActor : Animatable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,14 +38,6 @@ namespace Tizen.NUI 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. @@ -99,7 +90,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/CustomActorImpl.cs b/src/Tizen.NUI/src/internal/CustomActorImpl.cs index 0a0a166..ddde9eb 100755 --- a/src/Tizen.NUI/src/internal/CustomActorImpl.cs +++ b/src/Tizen.NUI/src/internal/CustomActorImpl.cs @@ -14,11 +14,10 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - internal class CustomActorImpl : RefObject { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -40,14 +39,6 @@ namespace Tizen.NUI 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. @@ -235,7 +226,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/CustomAlgorithmInterface.cs b/src/Tizen.NUI/src/internal/CustomAlgorithmInterface.cs index 2809839..a9be735 100755 --- a/src/Tizen.NUI/src/internal/CustomAlgorithmInterface.cs +++ b/src/Tizen.NUI/src/internal/CustomAlgorithmInterface.cs @@ -20,8 +20,7 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - - internal class CustomAlgorithmInterface : global::System.IDisposable + internal class CustomAlgorithmInterface : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -37,55 +36,13 @@ namespace Tizen.NUI 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; - - - ~CustomAlgorithmInterface() - { - 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) + 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. @@ -100,7 +57,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public virtual View GetNextFocusableView(View current, View proposed, View.FocusDirection direction) @@ -144,5 +101,4 @@ namespace Tizen.NUI private static global::System.Type[] swigMethodTypes0 = new global::System.Type[] { typeof(View), typeof(View), typeof(View.FocusDirection) }; } - } diff --git a/src/Tizen.NUI/src/internal/DaliEventHandler.cs b/src/Tizen.NUI/src/internal/DaliEventHandler.cs index fd13b6b..ca2e008 100755 --- a/src/Tizen.NUI/src/internal/DaliEventHandler.cs +++ b/src/Tizen.NUI/src/internal/DaliEventHandler.cs @@ -14,12 +14,11 @@ * limitations under the License. * */ +using System; +using System.Runtime.InteropServices; + namespace Tizen.NUI { - - using System; - using System.Runtime.InteropServices; - /// /// [UnmanagedFunctionPointer(CallingConvention.StdCall)] /// @@ -51,6 +50,4 @@ namespace Tizen.NUI /// 3 [UnmanagedFunctionPointer(CallingConvention.StdCall)] public delegate R EventHandlerWithReturnType(T source, U e); - - } diff --git a/src/Tizen.NUI/src/internal/DaliException.cs b/src/Tizen.NUI/src/internal/DaliException.cs index d964faa..8e257cf 100755 --- a/src/Tizen.NUI/src/internal/DaliException.cs +++ b/src/Tizen.NUI/src/internal/DaliException.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class DaliException : global::System.IDisposable + internal class DaliException : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~DaliException() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public DaliException(string location, string condition) : this(Interop.DaliException.new_DaliException(location, condition), true) @@ -134,7 +91,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/DefaultItemLayoutProperty.cs b/src/Tizen.NUI/src/internal/DefaultItemLayoutProperty.cs index 6fe2cfe..ffec5b0 100755 --- a/src/Tizen.NUI/src/internal/DefaultItemLayoutProperty.cs +++ b/src/Tizen.NUI/src/internal/DefaultItemLayoutProperty.cs @@ -19,7 +19,6 @@ using System.ComponentModel; namespace Tizen.NUI { - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] public enum DefaultItemLayoutProperty @@ -180,5 +179,4 @@ namespace Tizen.NUI /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. SPIRAL_TOP_ITEM_ALIGNMENT } - } diff --git a/src/Tizen.NUI/src/internal/DefaultRuler.cs b/src/Tizen.NUI/src/internal/DefaultRuler.cs index 9d67187..cc120e6 100755 --- a/src/Tizen.NUI/src/internal/DefaultRuler.cs +++ b/src/Tizen.NUI/src/internal/DefaultRuler.cs @@ -44,14 +44,6 @@ namespace Tizen.NUI 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. @@ -111,7 +103,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/DepthFunctionType.cs b/src/Tizen.NUI/src/internal/DepthFunctionType.cs index 2b8a0d9..5ee947e 100755 --- a/src/Tizen.NUI/src/internal/DepthFunctionType.cs +++ b/src/Tizen.NUI/src/internal/DepthFunctionType.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal enum DepthFunctionType { NEVER, @@ -29,5 +28,4 @@ namespace Tizen.NUI LESS_EQUAL, GREATER_EQUAL } - } diff --git a/src/Tizen.NUI/src/internal/DepthTestModeType.cs b/src/Tizen.NUI/src/internal/DepthTestModeType.cs index 7420386..59fcc67 100755 --- a/src/Tizen.NUI/src/internal/DepthTestModeType.cs +++ b/src/Tizen.NUI/src/internal/DepthTestModeType.cs @@ -17,12 +17,10 @@ namespace Tizen.NUI { - internal enum DepthTestModeType { OFF, AUTO, ON } - } diff --git a/src/Tizen.NUI/src/internal/DepthWriteModeType.cs b/src/Tizen.NUI/src/internal/DepthWriteModeType.cs index 1fe05b1..378c98a 100755 --- a/src/Tizen.NUI/src/internal/DepthWriteModeType.cs +++ b/src/Tizen.NUI/src/internal/DepthWriteModeType.cs @@ -17,12 +17,10 @@ namespace Tizen.NUI { - internal enum DepthWriteModeType { OFF, AUTO, ON } - } diff --git a/src/Tizen.NUI/src/internal/DirectionType.cs b/src/Tizen.NUI/src/internal/DirectionType.cs index 24c7261..634159d 100755 --- a/src/Tizen.NUI/src/internal/DirectionType.cs +++ b/src/Tizen.NUI/src/internal/DirectionType.cs @@ -17,11 +17,9 @@ namespace Tizen.NUI { - internal enum DirectionType { LEFT_TO_RIGHT = 0, RIGHT_TO_LEFT } - } diff --git a/src/Tizen.NUI/src/internal/Disposable.cs b/src/Tizen.NUI/src/internal/Disposable.cs new file mode 100755 index 0000000..c4627af --- /dev/null +++ b/src/Tizen.NUI/src/internal/Disposable.cs @@ -0,0 +1,89 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Tizen.NUI +{ + /// + /// Disposable class. + /// + /// 6 + public class Disposable : global::System.IDisposable + { + /// + /// A Flat to check if it is already disposed. + /// + /// 6 + protected bool disposed = false; + private bool isDisposeQueued = false; + + /// + /// Create an instance of BaseHandle. + /// + /// 6 + public Disposable() + { + } + + /// + /// Dispose. + /// + /// 6 + ~Disposable() + { + if (!isDisposeQueued) + { + isDisposeQueued = true; + DisposeQueue.Instance.Add(this); + } + } + + /// + /// Dispose. + /// + /// 6 + 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); + } + } + + /// + /// Dispose. + /// + /// 6 + 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. + + disposed = true; + } + } +} diff --git a/src/Tizen.NUI/src/internal/DisposeQueue.cs b/src/Tizen.NUI/src/internal/DisposeQueue.cs index 2f8e275..b69ed23 100755 --- a/src/Tizen.NUI/src/internal/DisposeQueue.cs +++ b/src/Tizen.NUI/src/internal/DisposeQueue.cs @@ -12,7 +12,6 @@ using System.Collections.Generic; namespace Tizen.NUI { - internal class DisposeQueue { private static readonly DisposeQueue _disposableQueue = new DisposeQueue(); diff --git a/src/Tizen.NUI/src/internal/EncodedBufferImage.cs b/src/Tizen.NUI/src/internal/EncodedBufferImage.cs index 8aaf9f7..c44dda2 100755 --- a/src/Tizen.NUI/src/internal/EncodedBufferImage.cs +++ b/src/Tizen.NUI/src/internal/EncodedBufferImage.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class EncodedBufferImage : Image { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,14 +38,6 @@ namespace Tizen.NUI 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. @@ -97,7 +88,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/EventThreadCallback.cs b/src/Tizen.NUI/src/internal/EventThreadCallback.cs index bbc687e..fa8c731 100755 --- a/src/Tizen.NUI/src/internal/EventThreadCallback.cs +++ b/src/Tizen.NUI/src/internal/EventThreadCallback.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using System.ComponentModel; namespace Tizen.NUI { - - internal class EventThreadCallback : global::System.IDisposable + internal class EventThreadCallback : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -36,55 +36,15 @@ namespace Tizen.NUI 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; - - - ~EventThreadCallback() - { - //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) + /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. + [EditorBrowsable(EditorBrowsableState.Never)] + 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. @@ -99,7 +59,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public EventThreadCallback(CallbackDelegate func) : this(Interop.EventThreadCallback.new_EventThreadCallback(func), true) @@ -119,5 +79,4 @@ namespace Tizen.NUI throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } } - } diff --git a/src/Tizen.NUI/src/internal/FaceCullingModeType.cs b/src/Tizen.NUI/src/internal/FaceCullingModeType.cs index dbd8e08..07971d3 100755 --- a/src/Tizen.NUI/src/internal/FaceCullingModeType.cs +++ b/src/Tizen.NUI/src/internal/FaceCullingModeType.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal enum FaceCullingModeType { NONE, @@ -25,5 +24,4 @@ namespace Tizen.NUI BACK, FRONT_AND_BACK } - } diff --git a/src/Tizen.NUI/src/internal/FixedRuler.cs b/src/Tizen.NUI/src/internal/FixedRuler.cs index 644e5b3..288f4aa 100755 --- a/src/Tizen.NUI/src/internal/FixedRuler.cs +++ b/src/Tizen.NUI/src/internal/FixedRuler.cs @@ -19,7 +19,6 @@ using System.ComponentModel; namespace Tizen.NUI { - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] public class FixedRuler : Ruler @@ -45,14 +44,6 @@ namespace Tizen.NUI 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. @@ -119,7 +110,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/FloatSignal.cs b/src/Tizen.NUI/src/internal/FloatSignal.cs index 57f2289..7db553d 100755 --- a/src/Tizen.NUI/src/internal/FloatSignal.cs +++ b/src/Tizen.NUI/src/internal/FloatSignal.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using System.ComponentModel; namespace Tizen.NUI { - - internal class FloatSignal : global::System.IDisposable + internal class FloatSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,15 @@ namespace Tizen.NUI 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; - - - ~FloatSignal() - { - 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) + /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. + [EditorBrowsable(EditorBrowsableState.Never)] + 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. @@ -97,7 +57,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -143,7 +103,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/FocusChangedSignal.cs b/src/Tizen.NUI/src/internal/FocusChangedSignal.cs index 3069d19..780286f 100755 --- a/src/Tizen.NUI/src/internal/FocusChangedSignal.cs +++ b/src/Tizen.NUI/src/internal/FocusChangedSignal.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - internal class FocusChangedSignal : global::System.IDisposable + internal class FocusChangedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~FocusChangedSignal() - { - 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) + 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. @@ -97,10 +55,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.FocusChangedSignal.FocusChangedSignal_Empty(swigCPtr); @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/FocusGroupChangedSignal.cs b/src/Tizen.NUI/src/internal/FocusGroupChangedSignal.cs index 67eda6b..7fa01a8 100755 --- a/src/Tizen.NUI/src/internal/FocusGroupChangedSignal.cs +++ b/src/Tizen.NUI/src/internal/FocusGroupChangedSignal.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - internal class FocusGroupChangedSignal : global::System.IDisposable + internal class FocusGroupChangedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~FocusGroupChangedSignal() - { - 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) + 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. @@ -97,7 +55,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/FontDescription.cs b/src/Tizen.NUI/src/internal/FontDescription.cs index 7541b56..6d54d54 100755 --- a/src/Tizen.NUI/src/internal/FontDescription.cs +++ b/src/Tizen.NUI/src/internal/FontDescription.cs @@ -16,8 +16,7 @@ */ namespace Tizen.NUI { - - internal class FontDescription : global::System.IDisposable + internal class FontDescription : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -33,55 +32,13 @@ namespace Tizen.NUI 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; - - ~FontDescription() - { - 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) + 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. @@ -95,7 +52,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public FontDescription() : this(Interop.FontClient.new_FontDescription(), true) @@ -177,7 +134,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/FontMetrics.cs b/src/Tizen.NUI/src/internal/FontMetrics.cs index 257c929..e209d50 100755 --- a/src/Tizen.NUI/src/internal/FontMetrics.cs +++ b/src/Tizen.NUI/src/internal/FontMetrics.cs @@ -16,8 +16,7 @@ */ namespace Tizen.NUI { - - internal class FontMetrics : global::System.IDisposable + internal class FontMetrics : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -33,55 +32,13 @@ namespace Tizen.NUI 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; - - ~FontMetrics() - { - 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) + 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. @@ -95,7 +52,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public FontMetrics() : this(Interop.FontClient.new_FontMetrics__SWIG_0(), true) @@ -182,7 +139,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/FrameBuffer.cs b/src/Tizen.NUI/src/internal/FrameBuffer.cs index 277235f..c4ceb11 100755 --- a/src/Tizen.NUI/src/internal/FrameBuffer.cs +++ b/src/Tizen.NUI/src/internal/FrameBuffer.cs @@ -19,7 +19,6 @@ using System.Runtime.InteropServices; namespace Tizen.NUI { - internal class FrameBuffer : BaseHandle { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -41,14 +40,6 @@ namespace Tizen.NUI 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. @@ -109,7 +100,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/FrameBufferImage.cs b/src/Tizen.NUI/src/internal/FrameBufferImage.cs index bc7fc77..20ed16e 100755 --- a/src/Tizen.NUI/src/internal/FrameBufferImage.cs +++ b/src/Tizen.NUI/src/internal/FrameBufferImage.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class FrameBufferImage : Image { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,19 +38,9 @@ namespace Tizen.NUI 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) @@ -65,37 +54,36 @@ namespace Tizen.NUI base.Dispose(type); } - public FrameBufferImage(uint width, uint height, PixelFormat pixelFormat, RenderBufferFormat bufferFormat) : this(Interop.FrameBufferImage.FrameBufferImage_New__SWIG_0(width, height, (int)pixelFormat, (int)bufferFormat), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public FrameBufferImage(uint width, uint height, PixelFormat pixelFormat) : this(Interop.FrameBufferImage.FrameBufferImage_New__SWIG_1(width, height, (int)pixelFormat), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public FrameBufferImage(uint width, uint height) : this(Interop.FrameBufferImage.FrameBufferImage_New__SWIG_2(width, height), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public FrameBufferImage(uint width) : this(Interop.FrameBufferImage.FrameBufferImage_New__SWIG_3(width), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public FrameBufferImage() : this(Interop.FrameBufferImage.FrameBufferImage_New__SWIG_4(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public FrameBufferImage(NativeImageInterface image) : this(Interop.FrameBufferImage.FrameBufferImage_New__SWIG_5(NativeImageInterface.getCPtr(image)), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public new static FrameBufferImage DownCast(BaseHandle handle) { FrameBufferImage ret = Registry.GetManagedBaseHandleFromNativePtr(handle) as FrameBufferImage; @@ -114,7 +102,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/FriendAssembly.cs b/src/Tizen.NUI/src/internal/FriendAssembly.cs index d0864b7..3e2e42a 100755 --- a/src/Tizen.NUI/src/internal/FriendAssembly.cs +++ b/src/Tizen.NUI/src/internal/FriendAssembly.cs @@ -33,8 +33,3 @@ using System.Runtime.CompilerServices; [assembly: InternalsVisibleTo("Tizen.TV.FLUX, PublicKey=0024000004800000940000000602000000240000525341310004000001000100ed445c2a988d35b99e5766f42eef33d89d1f67225db051f011abcfce47a4788875c39750a2e5695f1ec117f41d96610419811762669f98131db30a6e64c6bb8fde3731f373f6cda4c0087d121f5108559f216dc015807dc46ec5a4d1b63f5deff64c01754a0db0dc849bc300672572cbd2697432ab6c193ebf9fade6bf0f2aad")] [assembly: InternalsVisibleTo("Tizen.TV.FLUX.Component, PublicKey=0024000004800000940000000602000000240000525341310004000001000100ed445c2a988d35b99e5766f42eef33d89d1f67225db051f011abcfce47a4788875c39750a2e5695f1ec117f41d96610419811762669f98131db30a6e64c6bb8fde3731f373f6cda4c0087d121f5108559f216dc015807dc46ec5a4d1b63f5deff64c01754a0db0dc849bc300672572cbd2697432ab6c193ebf9fade6bf0f2aad")] [assembly: InternalsVisibleTo("Tizen.TV.FLUX.Example, PublicKey=0024000004800000940000000602000000240000525341310004000001000100ed445c2a988d35b99e5766f42eef33d89d1f67225db051f011abcfce47a4788875c39750a2e5695f1ec117f41d96610419811762669f98131db30a6e64c6bb8fde3731f373f6cda4c0087d121f5108559f216dc015807dc46ec5a4d1b63f5deff64c01754a0db0dc849bc300672572cbd2697432ab6c193ebf9fade6bf0f2aad")] - - -namespace Tizen.NUI -{ -} diff --git a/src/Tizen.NUI/src/internal/GaussianBlurView.cs b/src/Tizen.NUI/src/internal/GaussianBlurView.cs index 57be582..405f162 100755 --- a/src/Tizen.NUI/src/internal/GaussianBlurView.cs +++ b/src/Tizen.NUI/src/internal/GaussianBlurView.cs @@ -14,16 +14,12 @@ * limitations under the License. * */ - +using System; +using System.Runtime.InteropServices; using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - - using System; - using System.Runtime.InteropServices; - - internal class GaussianBlurView : View { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -45,14 +41,6 @@ namespace Tizen.NUI 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. @@ -70,8 +58,6 @@ namespace Tizen.NUI base.Dispose(type); } - - /// 3 public class FinishedEventArgs : EventArgs { @@ -145,18 +131,18 @@ namespace Tizen.NUI public GaussianBlurView() : this(Interop.GaussianBlurView.GaussianBlurView_New__SWIG_0(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public GaussianBlurView(uint numSamples, float blurBellCurveWidth, PixelFormat renderTargetPixelFormat, float downsampleWidthScale, float downsampleHeightScale, bool blurUserImage) : this(Interop.GaussianBlurView.GaussianBlurView_New__SWIG_1(numSamples, blurBellCurveWidth, (int)renderTargetPixelFormat, downsampleWidthScale, downsampleHeightScale, blurUserImage), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public GaussianBlurView(uint numSamples, float blurBellCurveWidth, PixelFormat renderTargetPixelFormat, float downsampleWidthScale, float downsampleHeightScale) : this(Interop.GaussianBlurView.GaussianBlurView_New__SWIG_2(numSamples, blurBellCurveWidth, (int)renderTargetPixelFormat, downsampleWidthScale, downsampleHeightScale), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public GaussianBlurView(GaussianBlurView handle) : this(Interop.GaussianBlurView.new_GaussianBlurView__SWIG_1(GaussianBlurView.getCPtr(handle)), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); @@ -245,7 +231,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/GaussianBlurViewSignal.cs b/src/Tizen.NUI/src/internal/GaussianBlurViewSignal.cs index 61194c0..17bc0e2 100755 --- a/src/Tizen.NUI/src/internal/GaussianBlurViewSignal.cs +++ b/src/Tizen.NUI/src/internal/GaussianBlurViewSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class GaussianBlurViewSignal : global::System.IDisposable + internal class GaussianBlurViewSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~GaussianBlurViewSignal() - { - 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) + 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. @@ -97,10 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.GaussianBlurViewSignal.GaussianBlurViewSignal_Empty(swigCPtr); @@ -143,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/GlyphInfo.cs b/src/Tizen.NUI/src/internal/GlyphInfo.cs index ddacf15..2f0f1b3 100755 --- a/src/Tizen.NUI/src/internal/GlyphInfo.cs +++ b/src/Tizen.NUI/src/internal/GlyphInfo.cs @@ -16,8 +16,7 @@ */ namespace Tizen.NUI { - - internal class GlyphInfo : global::System.IDisposable + internal class GlyphInfo : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -33,55 +32,13 @@ namespace Tizen.NUI 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; - - ~GlyphInfo() - { - 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) + 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. @@ -95,7 +52,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public GlyphInfo() : this(Interop.GlytphInfo.new_GlyphInfo__SWIG_0(), true) @@ -227,7 +184,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/HoverSignal.cs b/src/Tizen.NUI/src/internal/HoverSignal.cs index 43a1fea..06e940e 100755 --- a/src/Tizen.NUI/src/internal/HoverSignal.cs +++ b/src/Tizen.NUI/src/internal/HoverSignal.cs @@ -14,12 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - - internal class HoverSignal : global::System.IDisposable + internal class HoverSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -35,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~HoverSignal() - { - 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) + 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. @@ -98,10 +55,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.ActorHoverSignal.ActorHoverSignal_Empty(swigCPtr); @@ -145,7 +101,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/Image.cs b/src/Tizen.NUI/src/internal/Image.cs index bf791d9..9374f69 100755 --- a/src/Tizen.NUI/src/internal/Image.cs +++ b/src/Tizen.NUI/src/internal/Image.cs @@ -14,14 +14,11 @@ * limitations under the License. * */ +using System; +using System.Runtime.InteropServices; namespace Tizen.NUI { - - using System; - using System.Runtime.InteropServices; - - internal class Image : BaseHandle { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -43,14 +40,6 @@ namespace Tizen.NUI 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. @@ -68,8 +57,6 @@ namespace Tizen.NUI base.Dispose(type); } - - /** * @brief Event arguments that passed via Uploaded signal * @@ -151,7 +138,6 @@ namespace Tizen.NUI } } - public static Image GetImageFromPtr(global::System.IntPtr cPtr) { Image ret = new Image(cPtr, false); @@ -159,7 +145,6 @@ namespace Tizen.NUI return ret; } - public Image() : this(Interop.Image.new_Image__SWIG_0(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); @@ -204,7 +189,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/ImageSignal.cs b/src/Tizen.NUI/src/internal/ImageSignal.cs index 21a1c6d..7b97aa5 100755 --- a/src/Tizen.NUI/src/internal/ImageSignal.cs +++ b/src/Tizen.NUI/src/internal/ImageSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ImageSignal : global::System.IDisposable + internal class ImageSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~ImageSignal() - { - 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) + 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. @@ -97,10 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.Image.ImageSignal_Empty(swigCPtr); @@ -143,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/InputMethodOptions.cs b/src/Tizen.NUI/src/internal/InputMethodOptions.cs index 4a37dd7..ca9d805 100755 --- a/src/Tizen.NUI/src/internal/InputMethodOptions.cs +++ b/src/Tizen.NUI/src/internal/InputMethodOptions.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class InputMethodOptions : global::System.IDisposable + internal class InputMethodOptions : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,53 +33,13 @@ namespace Tizen.NUI 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; - - ~InputMethodOptions() - { - 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) + 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. @@ -95,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public InputMethodOptions() : this(Interop.InputMethodOptions.new_InputMethodOptions(), true) @@ -128,7 +87,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/Item.cs b/src/Tizen.NUI/src/internal/Item.cs index 3017b56..0b3ce74 100755 --- a/src/Tizen.NUI/src/internal/Item.cs +++ b/src/Tizen.NUI/src/internal/Item.cs @@ -16,14 +16,13 @@ */ using System.ComponentModel; +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public class Item : global::System.IDisposable + public class Item : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -42,63 +41,15 @@ namespace Tizen.NUI 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 Flag to check if it is already disposed. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - protected bool disposed = false; - - - /// Destructor. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - ~Item() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - 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); - } - } - - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -113,7 +64,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. @@ -171,7 +122,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/ItemContainer.cs b/src/Tizen.NUI/src/internal/ItemContainer.cs index aa3682c..c7ef5eb 100755 --- a/src/Tizen.NUI/src/internal/ItemContainer.cs +++ b/src/Tizen.NUI/src/internal/ItemContainer.cs @@ -22,8 +22,8 @@ namespace Tizen.NUI /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public class ItemContainer : global::System.IDisposable, global::System.Collections.IEnumerable - , global::System.Collections.Generic.IEnumerable + public class ItemContainer : Disposable, global::System.Collections.IEnumerable, + global::System.Collections.Generic.IEnumerable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -42,62 +42,15 @@ namespace Tizen.NUI 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 Flag to check if it is already disposed. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - protected bool disposed = false; - - /// Destructor. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - ~ItemContainer() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - 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); - } - } - - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -112,7 +65,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. @@ -255,8 +208,8 @@ namespace Tizen.NUI /// tricky to detect unmanaged code that modifies the collection under our feet. /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public sealed class ItemContainerEnumerator : global::System.Collections.IEnumerator - , global::System.Collections.Generic.IEnumerator + public sealed class ItemContainerEnumerator : global::System.Collections.IEnumerator, + global::System.Collections.Generic.IEnumerator { private ItemContainer collectionRef; private int currentIndex; @@ -498,7 +451,5 @@ namespace Tizen.NUI Interop.ItemContainer.ItemContainer_SetRange(swigCPtr, index, ItemContainer.getCPtr(values)); if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ItemFactory.cs b/src/Tizen.NUI/src/internal/ItemFactory.cs index d595f03..129f296 100755 --- a/src/Tizen.NUI/src/internal/ItemFactory.cs +++ b/src/Tizen.NUI/src/internal/ItemFactory.cs @@ -23,7 +23,7 @@ namespace Tizen.NUI { /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public class ItemFactory : global::System.IDisposable + public class ItemFactory : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -42,62 +42,15 @@ namespace Tizen.NUI 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 Flag to check if it is already disposed. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - protected bool disposed = false; - - /// Destructor. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - ~ItemFactory() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - 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); - } - } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -112,7 +65,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. @@ -203,5 +156,4 @@ namespace Tizen.NUI private static global::System.Type[] swigMethodTypes1 = new global::System.Type[] { typeof(uint) }; private static global::System.Type[] swigMethodTypes2 = new global::System.Type[] { typeof(uint), typeof(View) }; } - } diff --git a/src/Tizen.NUI/src/internal/ItemIdContainer.cs b/src/Tizen.NUI/src/internal/ItemIdContainer.cs index 021fd65..55f30d5 100755 --- a/src/Tizen.NUI/src/internal/ItemIdContainer.cs +++ b/src/Tizen.NUI/src/internal/ItemIdContainer.cs @@ -19,11 +19,10 @@ using System.ComponentModel; namespace Tizen.NUI { - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public class ItemIdContainer : global::System.IDisposable, global::System.Collections.IEnumerable - , global::System.Collections.Generic.IList + public class ItemIdContainer : Disposable, global::System.Collections.IEnumerable, + global::System.Collections.Generic.IList { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -42,62 +41,15 @@ namespace Tizen.NUI 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 Flag to check if it is already disposed. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - protected bool disposed = false; - - /// Destructor. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - ~ItemIdContainer() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - 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); - } - } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -112,7 +64,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. @@ -534,7 +486,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/ItemLayout.cs b/src/Tizen.NUI/src/internal/ItemLayout.cs index b74ad08..85b2ec8 100755 --- a/src/Tizen.NUI/src/internal/ItemLayout.cs +++ b/src/Tizen.NUI/src/internal/ItemLayout.cs @@ -20,7 +20,6 @@ using System.ComponentModel; namespace Tizen.NUI { - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] public class ItemLayout : RefObject @@ -46,14 +45,6 @@ namespace Tizen.NUI 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. @@ -71,7 +62,6 @@ namespace Tizen.NUI base.Dispose(type); } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] public void SetLayoutProperties(PropertyMap properties) @@ -237,7 +227,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/ItemRange.cs b/src/Tizen.NUI/src/internal/ItemRange.cs index 48fe8c7..90074d2 100755 --- a/src/Tizen.NUI/src/internal/ItemRange.cs +++ b/src/Tizen.NUI/src/internal/ItemRange.cs @@ -19,10 +19,9 @@ using System.ComponentModel; namespace Tizen.NUI { - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public class ItemRange : global::System.IDisposable + public class ItemRange : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -41,62 +40,15 @@ namespace Tizen.NUI 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 Flag to check if it is already disposed. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - protected bool disposed = false; - - /// Destructor. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - ~ItemRange() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - 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); - } - } - - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -111,10 +63,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] public ItemRange(uint beginItem, uint endItem) : this(Interop.ItemRange.new_ItemRange__SWIG_0(beginItem, endItem), true) @@ -189,7 +140,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/KeyEventSignal.cs b/src/Tizen.NUI/src/internal/KeyEventSignal.cs index a5c1407..82717e6 100755 --- a/src/Tizen.NUI/src/internal/KeyEventSignal.cs +++ b/src/Tizen.NUI/src/internal/KeyEventSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class KeyEventSignal : global::System.IDisposable + internal class KeyEventSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~KeyEventSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/KeyInputFocusManager.cs b/src/Tizen.NUI/src/internal/KeyInputFocusManager.cs index 6a583fa..be18bb5 100755 --- a/src/Tizen.NUI/src/internal/KeyInputFocusManager.cs +++ b/src/Tizen.NUI/src/internal/KeyInputFocusManager.cs @@ -40,19 +40,10 @@ namespace Tizen.NUI 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) @@ -104,5 +95,4 @@ namespace Tizen.NUI return ret; } } - } diff --git a/src/Tizen.NUI/src/internal/KeyInputFocusSignal.cs b/src/Tizen.NUI/src/internal/KeyInputFocusSignal.cs index bdcd842..9268f43 100755 --- a/src/Tizen.NUI/src/internal/KeyInputFocusSignal.cs +++ b/src/Tizen.NUI/src/internal/KeyInputFocusSignal.cs @@ -19,8 +19,7 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - - internal class KeyInputFocusSignal : global::System.IDisposable + internal class KeyInputFocusSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -36,55 +35,13 @@ namespace Tizen.NUI 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; - - - ~KeyInputFocusSignal() - { - 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) + 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. @@ -99,7 +56,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -144,7 +101,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/KeyboardEventSignalType.cs b/src/Tizen.NUI/src/internal/KeyboardEventSignalType.cs index 016470f..cd4fe6b 100755 --- a/src/Tizen.NUI/src/internal/KeyboardEventSignalType.cs +++ b/src/Tizen.NUI/src/internal/KeyboardEventSignalType.cs @@ -20,7 +20,7 @@ using System.ComponentModel; namespace Tizen.NUI { - internal class KeyboardEventSignalType : global::System.IDisposable + internal class KeyboardEventSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -40,69 +40,17 @@ namespace Tizen.NUI 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. - /// - /// 3 - protected bool disposed = false; - /// /// Dispose /// /// 3 - ~KeyboardEventSignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose - /// - /// 3 - 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); - } - } - - /// - /// Dispose - /// - /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -117,7 +65,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -194,7 +142,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/KeyboardResizedSignalType.cs b/src/Tizen.NUI/src/internal/KeyboardResizedSignalType.cs index 9b1d820..559483c 100755 --- a/src/Tizen.NUI/src/internal/KeyboardResizedSignalType.cs +++ b/src/Tizen.NUI/src/internal/KeyboardResizedSignalType.cs @@ -20,7 +20,7 @@ using System.ComponentModel; namespace Tizen.NUI { - internal class KeyboardResizedSignalType : global::System.IDisposable + internal class KeyboardResizedSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -40,68 +40,17 @@ namespace Tizen.NUI 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. - /// - /// 4 - protected bool disposed = false; - - /// - /// Dispose - /// - ~KeyboardResizedSignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose - /// - /// 4 - 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); - } - } - /// /// Dispose /// /// 4 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -116,7 +65,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -190,7 +139,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/KeyboardTypeSignalType.cs b/src/Tizen.NUI/src/internal/KeyboardTypeSignalType.cs index cf94a4d..e73d757 100755 --- a/src/Tizen.NUI/src/internal/KeyboardTypeSignalType.cs +++ b/src/Tizen.NUI/src/internal/KeyboardTypeSignalType.cs @@ -22,7 +22,7 @@ namespace Tizen.NUI /// KeyboardTypeSignalType /// /// 4 - public class KeyboardTypeSignalType : global::System.IDisposable + public class KeyboardTypeSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -42,69 +42,17 @@ namespace Tizen.NUI 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. - /// - /// 4 - protected bool disposed = false; - - /// - /// Dispose - /// - /// 3 - ~KeyboardTypeSignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// /// Dispose /// /// 4 - 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); - } - } - - /// - /// Dispose - /// - /// 4 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -119,7 +67,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -193,6 +141,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } } diff --git a/src/Tizen.NUI/src/internal/LanguageChangedSignalType.cs b/src/Tizen.NUI/src/internal/LanguageChangedSignalType.cs index f7bee66..b6a70ab 100755 --- a/src/Tizen.NUI/src/internal/LanguageChangedSignalType.cs +++ b/src/Tizen.NUI/src/internal/LanguageChangedSignalType.cs @@ -20,7 +20,7 @@ using System.ComponentModel; namespace Tizen.NUI { - internal class LanguageChangedSignalType : global::System.IDisposable + internal class LanguageChangedSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -40,68 +40,17 @@ namespace Tizen.NUI 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. - /// - /// 4 - protected bool disposed = false; - - /// - /// Dispose - /// - ~LanguageChangedSignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose - /// - /// 4 - 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); - } - } - /// /// Dispose /// /// 4 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -116,7 +65,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -189,7 +138,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/Layouting/LayoutController.cs b/src/Tizen.NUI/src/internal/Layouting/LayoutController.cs index b980777..249f99d 100755 --- a/src/Tizen.NUI/src/internal/Layouting/LayoutController.cs +++ b/src/Tizen.NUI/src/internal/Layouting/LayoutController.cs @@ -27,7 +27,7 @@ namespace Tizen.NUI /// [Draft] The class that initiates the Measuring and Layouting of the tree, /// It sets a callback that becomes the entry point into the C# Layouting. /// - internal class LayoutController : global::System.IDisposable + internal class LayoutController : Disposable { static bool LayoutDebugController = false; // Debug flag @@ -38,9 +38,6 @@ namespace Tizen.NUI event Callback _instance; - // A Flag to check if it is already disposed. - protected bool disposed = false; - private Window _window; Animation _coreAnimation; @@ -93,21 +90,6 @@ namespace Tizen.NUI } /// - /// Destructor which adds LayoutController to the Dispose queue. - /// - ~LayoutController() - { - } - - /// - /// Explict Dispose. - /// - public void Dispose() - { - Dispose(DisposeTypes.Explicit); - } - - /// /// Add transition data for a LayoutItem to the transition stack. /// /// Transition data for a LayoutItem. @@ -132,20 +114,13 @@ namespace Tizen.NUI /// /// Dispose Explict or Implicit /// - protected virtual void Dispose(DisposeTypes type) + protected override void Dispose(DisposeTypes type) { if (disposed) { return; } - if (type == DisposeTypes.Explicit) - { - //Called by User code - //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. @@ -156,7 +131,7 @@ namespace Tizen.NUI unmanagedLayoutController = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } // Traverse through children from the provided root. @@ -223,7 +198,7 @@ namespace Tizen.NUI else { // Parent not a View so assume it's a Layer which is the size of the window. - rootSize = _window.WindowSize; + rootSize = new Size2D(_window.Size.Width, _window.Size.Height); } // Determine measure specification for root. @@ -577,5 +552,4 @@ namespace Tizen.NUI } } // class LayoutController - } // namespace Tizen.NUI diff --git a/src/Tizen.NUI/src/internal/Layouting/LayoutItem.cs b/src/Tizen.NUI/src/internal/Layouting/LayoutItem.cs index 27b0c72..ba97aef 100755 --- a/src/Tizen.NUI/src/internal/Layouting/LayoutItem.cs +++ b/src/Tizen.NUI/src/internal/Layouting/LayoutItem.cs @@ -539,6 +539,5 @@ namespace Tizen.NUI return changed; } - } } diff --git a/src/Tizen.NUI/src/internal/ListEventSignalType.cs b/src/Tizen.NUI/src/internal/ListEventSignalType.cs index f36f669..220ac44 100755 --- a/src/Tizen.NUI/src/internal/ListEventSignalType.cs +++ b/src/Tizen.NUI/src/internal/ListEventSignalType.cs @@ -20,7 +20,7 @@ using System.ComponentModel; namespace Tizen.NUI { - internal class ListEventSignalType : global::System.IDisposable + internal class ListEventSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -41,73 +41,18 @@ namespace Tizen.NUI 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. - /// - /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - protected bool disposed = false; - - /// - /// Dispose - /// - /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - ~ListEventSignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose - /// - /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - 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); - } - } - /// /// Dispose /// /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -122,7 +67,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -202,7 +147,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/LoadingState.cs b/src/Tizen.NUI/src/internal/LoadingState.cs index f9901ae..f4b0017 100755 --- a/src/Tizen.NUI/src/internal/LoadingState.cs +++ b/src/Tizen.NUI/src/internal/LoadingState.cs @@ -17,12 +17,10 @@ namespace Tizen.NUI { - internal enum LoadingState { ResourceLoading, ResourceLoadingSucceeded, ResourceLoadingFailed } - } diff --git a/src/Tizen.NUI/src/internal/LongPressGestureDetectedSignal.cs b/src/Tizen.NUI/src/internal/LongPressGestureDetectedSignal.cs index d6a8ee1..c15dcf0 100755 --- a/src/Tizen.NUI/src/internal/LongPressGestureDetectedSignal.cs +++ b/src/Tizen.NUI/src/internal/LongPressGestureDetectedSignal.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - internal class LongPressGestureDetectedSignal : global::System.IDisposable + internal class LongPressGestureDetectedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~LongPressGestureDetectedSignal() - { - 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) + 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. @@ -97,11 +55,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - - public bool Empty() { bool ret = Interop.LongPressGestureDetectedSignal.LongPressGestureDetectedSignal_Empty(swigCPtr); @@ -144,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/LowBatterySignalType.cs b/src/Tizen.NUI/src/internal/LowBatterySignalType.cs index 83b3b65..1e1b3f7 100755 --- a/src/Tizen.NUI/src/internal/LowBatterySignalType.cs +++ b/src/Tizen.NUI/src/internal/LowBatterySignalType.cs @@ -17,11 +17,10 @@ namespace Tizen.NUI { - /// /// LowBatterySignalType. /// - internal class LowBatterySignalType : global::System.IDisposable + internal class LowBatterySignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -41,69 +40,18 @@ namespace Tizen.NUI 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; - - - /// - /// Distructor. - /// - ~LowBatterySignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose. - /// - 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); - } - } - /// /// you can override it to clean-up your own resources. /// /// DisposeTypes /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -117,7 +65,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -181,8 +129,6 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/LowMemorySignalType.cs b/src/Tizen.NUI/src/internal/LowMemorySignalType.cs index a03fa83..61b3571 100755 --- a/src/Tizen.NUI/src/internal/LowMemorySignalType.cs +++ b/src/Tizen.NUI/src/internal/LowMemorySignalType.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class LowMemorySignalType : global::System.IDisposable + internal class LowMemorySignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +33,13 @@ namespace Tizen.NUI 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; - - ~LowMemorySignalType() - { - 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) + 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. @@ -95,7 +53,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -140,7 +98,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/Matrix.cs b/src/Tizen.NUI/src/internal/Matrix.cs index 879341a..0f692d5 100755 --- a/src/Tizen.NUI/src/internal/Matrix.cs +++ b/src/Tizen.NUI/src/internal/Matrix.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class Matrix : global::System.IDisposable + internal class Matrix : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,56 +33,13 @@ namespace Tizen.NUI 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; - - - ~Matrix() - { - 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) + 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. @@ -98,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -316,7 +272,5 @@ namespace Tizen.NUI Interop.Matrix.Matrix_GetTransformComponents(swigCPtr, Vector3.getCPtr(position), Rotation.getCPtr(rotation), Vector3.getCPtr(scale)); if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/Matrix3.cs b/src/Tizen.NUI/src/internal/Matrix3.cs index 210afa9..733f31e 100755 --- a/src/Tizen.NUI/src/internal/Matrix3.cs +++ b/src/Tizen.NUI/src/internal/Matrix3.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class Matrix3 : global::System.IDisposable + internal class Matrix3 : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~Matrix3() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public static Matrix3 IDENTITY @@ -212,7 +169,5 @@ namespace Tizen.NUI Interop.Matrix.Matrix3_Multiply(Matrix3.getCPtr(result), Matrix3.getCPtr(lhs), Matrix3.getCPtr(rhs)); if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/NDalic.cs b/src/Tizen.NUI/src/internal/NDalic.cs index b5c1918..fcb2fbd 100755 --- a/src/Tizen.NUI/src/internal/NDalic.cs +++ b/src/Tizen.NUI/src/internal/NDalic.cs @@ -19,7 +19,6 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - internal class NDalic { public static uint int_to_uint(int x) @@ -29,7 +28,6 @@ namespace Tizen.NUI return ret; } - public static readonly int VISUAL_PROPERTY_TRANSFORM = Interop.Visual.Visual_Property_TRANSFORM_get(); public static readonly int VISUAL_PROPERTY_PREMULTIPLIED_ALPHA = Interop.Visual.Visual_Property_PREMULTIPLIED_ALPHA_get(); public static readonly int VISUAL_PROPERTY_MIX_COLOR = Interop.Visual.Visual_Property_MIX_COLOR_get(); @@ -940,7 +938,5 @@ namespace Tizen.NUI internal static readonly int TOOLTIP_TAIL_VISIBILITY = Interop.NDalicToolTip.TOOLTIP_TAIL_VISIBILITY_get(); internal static readonly int TOOLTIP_TAIL_ABOVE_VISUAL = Interop.NDalicToolTip.TOOLTIP_TAIL_ABOVE_VISUAL_get(); internal static readonly int TOOLTIP_TAIL_BELOW_VISUAL = Interop.NDalicToolTip.TOOLTIP_TAIL_BELOW_VISUAL_get(); - } - } diff --git a/src/Tizen.NUI/src/internal/NUICoreBackend.cs b/src/Tizen.NUI/src/internal/NUICoreBackend.cs index bf7f0d2..76cce47 100755 --- a/src/Tizen.NUI/src/internal/NUICoreBackend.cs +++ b/src/Tizen.NUI/src/internal/NUICoreBackend.cs @@ -17,7 +17,6 @@ using System; using System.Collections.Generic; - using Tizen.Applications.CoreBackend; using Tizen.Applications; @@ -97,7 +96,6 @@ namespace Tizen.NUI Handlers.Add(evType, handler); } - /// /// The Dispose function. /// @@ -331,14 +329,12 @@ namespace Tizen.NUI handler?.Invoke(); } - - internal Application ApplicationHandle - { - get - { - return _application; - } - } - + internal Application ApplicationHandle + { + get + { + return _application; + } + } } } diff --git a/src/Tizen.NUI/src/internal/NUIWidgetCoreBackend.cs b/src/Tizen.NUI/src/internal/NUIWidgetCoreBackend.cs index 55c7193..7798fd6 100755 --- a/src/Tizen.NUI/src/internal/NUIWidgetCoreBackend.cs +++ b/src/Tizen.NUI/src/internal/NUIWidgetCoreBackend.cs @@ -17,7 +17,6 @@ using System; using System.Collections.Generic; - using Tizen.Applications.CoreBackend; using Tizen.Applications; diff --git a/src/Tizen.NUI/src/internal/NativeImage.cs b/src/Tizen.NUI/src/internal/NativeImage.cs index 88096b8..7d1a24f 100755 --- a/src/Tizen.NUI/src/internal/NativeImage.cs +++ b/src/Tizen.NUI/src/internal/NativeImage.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class NativeImage : Image { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,14 +38,6 @@ namespace Tizen.NUI 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. @@ -64,7 +55,6 @@ namespace Tizen.NUI base.Dispose(type); } - public NativeImage(NativeImageInterface nativeImageInterface) : this(Interop.NativeImageInterface.NativeImage_New(NativeImageInterface.getCPtr(nativeImageInterface)), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); @@ -108,7 +98,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/NativeImageInterface.cs b/src/Tizen.NUI/src/internal/NativeImageInterface.cs index 1c75c89..9149bae 100755 --- a/src/Tizen.NUI/src/internal/NativeImageInterface.cs +++ b/src/Tizen.NUI/src/internal/NativeImageInterface.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class NativeImageInterface : RefObject { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,19 +38,10 @@ namespace Tizen.NUI 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) @@ -111,7 +101,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/Object.cs b/src/Tizen.NUI/src/internal/Object.cs index 0339019..b452a43 100755 --- a/src/Tizen.NUI/src/internal/Object.cs +++ b/src/Tizen.NUI/src/internal/Object.cs @@ -15,7 +15,6 @@ * */ - namespace Tizen.NUI { /// @@ -48,5 +47,4 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } } - } diff --git a/src/Tizen.NUI/src/internal/ObjectCreatedSignal.cs b/src/Tizen.NUI/src/internal/ObjectCreatedSignal.cs index 172d23e..9ad5cbf 100755 --- a/src/Tizen.NUI/src/internal/ObjectCreatedSignal.cs +++ b/src/Tizen.NUI/src/internal/ObjectCreatedSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ObjectCreatedSignal : global::System.IDisposable + internal class ObjectCreatedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~ObjectCreatedSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ObjectDestroyedSignal.cs b/src/Tizen.NUI/src/internal/ObjectDestroyedSignal.cs index e5c26e9..2c68569 100755 --- a/src/Tizen.NUI/src/internal/ObjectDestroyedSignal.cs +++ b/src/Tizen.NUI/src/internal/ObjectDestroyedSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ObjectDestroyedSignal : global::System.IDisposable + internal class ObjectDestroyedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~ObjectDestroyedSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ObjectRegistry.cs b/src/Tizen.NUI/src/internal/ObjectRegistry.cs index bf0c9a7..47aa6ef 100755 --- a/src/Tizen.NUI/src/internal/ObjectRegistry.cs +++ b/src/Tizen.NUI/src/internal/ObjectRegistry.cs @@ -14,14 +14,11 @@ * limitations under the License. * */ +using System; +using System.Runtime.InteropServices; namespace Tizen.NUI { - - using System; - using System.Runtime.InteropServices; - - internal class ObjectRegistry : BaseHandle { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -43,14 +40,6 @@ namespace Tizen.NUI 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. @@ -68,7 +57,6 @@ namespace Tizen.NUI base.Dispose(type); } - /// 3 public class ObjectCreatedEventArgs : EventArgs { @@ -107,7 +95,6 @@ namespace Tizen.NUI } } - [UnmanagedFunctionPointer(CallingConvention.StdCall)] private delegate void ObjectCreatedEventCallbackDelegate(IntPtr baseHandle); private DaliEventHandler _objectRegistryObjectCreatedEventHandler; @@ -241,7 +228,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/PageFactory.cs b/src/Tizen.NUI/src/internal/PageFactory.cs index 6052942..8a14b78 100755 --- a/src/Tizen.NUI/src/internal/PageFactory.cs +++ b/src/Tizen.NUI/src/internal/PageFactory.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class PageFactory : global::System.IDisposable + internal class PageFactory : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~PageFactory() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public virtual uint GetNumberOfPages() @@ -113,7 +70,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/PagePanSignal.cs b/src/Tizen.NUI/src/internal/PagePanSignal.cs index 1639ef7..53bf25b 100755 --- a/src/Tizen.NUI/src/internal/PagePanSignal.cs +++ b/src/Tizen.NUI/src/internal/PagePanSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class PagePanSignal : global::System.IDisposable + internal class PagePanSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~PagePanSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/PageTurnLandscapeView.cs b/src/Tizen.NUI/src/internal/PageTurnLandscapeView.cs index 5b56dba..948b385 100755 --- a/src/Tizen.NUI/src/internal/PageTurnLandscapeView.cs +++ b/src/Tizen.NUI/src/internal/PageTurnLandscapeView.cs @@ -39,14 +39,6 @@ namespace Tizen.NUI 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. @@ -87,7 +79,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/PageTurnPortraitView.cs b/src/Tizen.NUI/src/internal/PageTurnPortraitView.cs index 0ad68df..9c77da9 100755 --- a/src/Tizen.NUI/src/internal/PageTurnPortraitView.cs +++ b/src/Tizen.NUI/src/internal/PageTurnPortraitView.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class PageTurnPortraitView : PageTurnView { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,14 +38,6 @@ namespace Tizen.NUI 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. @@ -67,8 +58,8 @@ namespace Tizen.NUI public PageTurnPortraitView(PageFactory pageFactory, Vector2 pageSize) : this(Interop.PageTurnPortraitView.PageTurnPortraitView_New(PageFactory.getCPtr(pageFactory), Vector2.getCPtr(pageSize)), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public PageTurnPortraitView(PageTurnPortraitView pageTurnPortraitView) : this(Interop.PageTurnPortraitView.new_PageTurnPortraitView__SWIG_1(PageTurnPortraitView.getCPtr(pageTurnPortraitView)), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); @@ -87,7 +78,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/PageTurnSignal.cs b/src/Tizen.NUI/src/internal/PageTurnSignal.cs index fc17266..3bf1c29 100755 --- a/src/Tizen.NUI/src/internal/PageTurnSignal.cs +++ b/src/Tizen.NUI/src/internal/PageTurnSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class PageTurnSignal : global::System.IDisposable + internal class PageTurnSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~PageTurnSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/PanGestureDetectedSignal.cs b/src/Tizen.NUI/src/internal/PanGestureDetectedSignal.cs index 396ef1f..f96c3d9 100755 --- a/src/Tizen.NUI/src/internal/PanGestureDetectedSignal.cs +++ b/src/Tizen.NUI/src/internal/PanGestureDetectedSignal.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - internal class PanGestureDetectedSignal : global::System.IDisposable + internal class PanGestureDetectedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~PanGestureDetectedSignal() - { - 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) + 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. @@ -97,7 +55,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -143,7 +101,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/PinchGestureDetectedSignal.cs b/src/Tizen.NUI/src/internal/PinchGestureDetectedSignal.cs index a1216b4..f98f7de 100755 --- a/src/Tizen.NUI/src/internal/PinchGestureDetectedSignal.cs +++ b/src/Tizen.NUI/src/internal/PinchGestureDetectedSignal.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - internal class PinchGestureDetectedSignal : global::System.IDisposable + internal class PinchGestureDetectedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~PinchGestureDetectedSignal() - { - 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) + 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. @@ -97,7 +55,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/PreFocusChangeSignal.cs b/src/Tizen.NUI/src/internal/PreFocusChangeSignal.cs index bcb1c31..838d6e8 100755 --- a/src/Tizen.NUI/src/internal/PreFocusChangeSignal.cs +++ b/src/Tizen.NUI/src/internal/PreFocusChangeSignal.cs @@ -15,16 +15,15 @@ * */ -using Tizen.NUI.BaseComponents; - using System; +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { internal delegate IntPtr SwigDelegatePreFocusChangeSignal(IntPtr current, IntPtr proposed, View.FocusDirection direction); - internal class PreFocusChangeSignal : global::System.IDisposable + internal class PreFocusChangeSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -40,55 +39,13 @@ namespace Tizen.NUI 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; - - - ~PreFocusChangeSignal() - { - 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) + 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. @@ -103,7 +60,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -146,7 +103,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ProgressBarValueChangedSignal.cs b/src/Tizen.NUI/src/internal/ProgressBarValueChangedSignal.cs index 3ad1ad9..6c7b618 100755 --- a/src/Tizen.NUI/src/internal/ProgressBarValueChangedSignal.cs +++ b/src/Tizen.NUI/src/internal/ProgressBarValueChangedSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ProgressBarValueChangedSignal : global::System.IDisposable + internal class ProgressBarValueChangedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~ProgressBarValueChangedSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/PropertyHelper.cs b/src/Tizen.NUI/src/internal/PropertyHelper.cs index c50cfa8..06a91ed 100755 --- a/src/Tizen.NUI/src/internal/PropertyHelper.cs +++ b/src/Tizen.NUI/src/internal/PropertyHelper.cs @@ -14,11 +14,10 @@ * limitations under the License. * */ +using System.Text; namespace Tizen.NUI { - using System.Text; - internal static class PropertyHelper { /// diff --git a/src/Tizen.NUI/src/internal/PropertyRangeManager.cs b/src/Tizen.NUI/src/internal/PropertyRangeManager.cs index d6e8f63..42be51c 100755 --- a/src/Tizen.NUI/src/internal/PropertyRangeManager.cs +++ b/src/Tizen.NUI/src/internal/PropertyRangeManager.cs @@ -109,7 +109,6 @@ namespace Tizen.NUI } - /// 3 public struct PropertyRange { @@ -129,7 +128,6 @@ namespace Tizen.NUI } } - /// 3 public int startEventIndex; // start of the property range /// 3 @@ -140,8 +138,5 @@ namespace Tizen.NUI /// 3 public int lastUsedAnimationIndex; // last used of the property index }; - - - } } diff --git a/src/Tizen.NUI/src/internal/PropertyRanges.cs b/src/Tizen.NUI/src/internal/PropertyRanges.cs index da3814f..b063505 100755 --- a/src/Tizen.NUI/src/internal/PropertyRanges.cs +++ b/src/Tizen.NUI/src/internal/PropertyRanges.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal enum PropertyRanges { DEFAULT_OBJECT_PROPERTY_START_INDEX = 0, @@ -39,5 +38,4 @@ namespace Tizen.NUI PROPERTY_CUSTOM_MAX_INDEX = 59999999, CORE_PROPERTY_MAX_INDEX = PROPERTY_CUSTOM_MAX_INDEX } - } diff --git a/src/Tizen.NUI/src/internal/PropertyRegistration.cs b/src/Tizen.NUI/src/internal/PropertyRegistration.cs index f23ebd9..585d1da 100755 --- a/src/Tizen.NUI/src/internal/PropertyRegistration.cs +++ b/src/Tizen.NUI/src/internal/PropertyRegistration.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class PropertyRegistration : global::System.IDisposable + internal class PropertyRegistration : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~PropertyRegistration() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -105,7 +62,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/RefObject.cs b/src/Tizen.NUI/src/internal/RefObject.cs index 48172a9..30f069b 100755 --- a/src/Tizen.NUI/src/internal/RefObject.cs +++ b/src/Tizen.NUI/src/internal/RefObject.cs @@ -21,7 +21,7 @@ namespace Tizen.NUI { /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public class RefObject : global::System.IDisposable + public class RefObject : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -40,62 +40,15 @@ namespace Tizen.NUI 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 Flag to check if it is already disposed. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - protected bool disposed = false; - - /// Destructor. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - ~RefObject() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - 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); - } - } - - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -110,7 +63,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. @@ -146,7 +99,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/Registry.cs b/src/Tizen.NUI/src/internal/Registry.cs index 1f951a2..18e0e93 100755 --- a/src/Tizen.NUI/src/internal/Registry.cs +++ b/src/Tizen.NUI/src/internal/Registry.cs @@ -169,7 +169,5 @@ namespace Tizen.NUI Tizen.Log.Fatal("NUI", $"Error! current thread({currentId}) which is NOT main thread({mainThreadId}) utilizes NUI object!"); } } - - } } diff --git a/src/Tizen.NUI/src/internal/RenderBufferFormat.cs b/src/Tizen.NUI/src/internal/RenderBufferFormat.cs index f3b7c65..4c4d4ec 100755 --- a/src/Tizen.NUI/src/internal/RenderBufferFormat.cs +++ b/src/Tizen.NUI/src/internal/RenderBufferFormat.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal enum RenderBufferFormat { COLOR, @@ -25,5 +24,4 @@ namespace Tizen.NUI COLOR_STENCIL, COLOR_DEPTH_STENCIL } - } diff --git a/src/Tizen.NUI/src/internal/RenderModeType.cs b/src/Tizen.NUI/src/internal/RenderModeType.cs index 96ed16a..db1d4a1 100755 --- a/src/Tizen.NUI/src/internal/RenderModeType.cs +++ b/src/Tizen.NUI/src/internal/RenderModeType.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal enum RenderModeType { NONE, @@ -26,5 +25,4 @@ namespace Tizen.NUI STENCIL, COLOR_STENCIL } - } diff --git a/src/Tizen.NUI/src/internal/RenderTaskList.cs b/src/Tizen.NUI/src/internal/RenderTaskList.cs index 9550090..d38997f 100755 --- a/src/Tizen.NUI/src/internal/RenderTaskList.cs +++ b/src/Tizen.NUI/src/internal/RenderTaskList.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class RenderTaskList : BaseHandle { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -39,19 +38,10 @@ namespace Tizen.NUI 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) @@ -115,7 +105,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/RenderTaskSignal.cs b/src/Tizen.NUI/src/internal/RenderTaskSignal.cs index 3e15af6..e8e3d85 100755 --- a/src/Tizen.NUI/src/internal/RenderTaskSignal.cs +++ b/src/Tizen.NUI/src/internal/RenderTaskSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class RenderTaskSignal : global::System.IDisposable + internal class RenderTaskSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~RenderTaskSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -105,7 +62,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/RenderingType.cs b/src/Tizen.NUI/src/internal/RenderingType.cs index 796d83a..2eac9e9 100755 --- a/src/Tizen.NUI/src/internal/RenderingType.cs +++ b/src/Tizen.NUI/src/internal/RenderingType.cs @@ -17,11 +17,9 @@ namespace Tizen.NUI { - internal enum RenderingType { RENDERING_SHARED_ATLAS, RENDERING_VECTOR_BASED } - } diff --git a/src/Tizen.NUI/src/internal/ResizedSignal.cs b/src/Tizen.NUI/src/internal/ResizedSignal.cs index 54e4462..0be79b4 100755 --- a/src/Tizen.NUI/src/internal/ResizedSignal.cs +++ b/src/Tizen.NUI/src/internal/ResizedSignal.cs @@ -18,7 +18,7 @@ namespace Tizen.NUI { - internal class ResizedSignal : global::System.IDisposable + internal class ResizedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,53 +34,13 @@ namespace Tizen.NUI 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; - - ~ResizedSignal() - { - 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) + 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. @@ -95,10 +55,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.ResizedSignal.ResizedSignal_Empty(swigCPtr); @@ -141,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/Ruler.cs b/src/Tizen.NUI/src/internal/Ruler.cs index 8df78bc..9187dbc 100755 --- a/src/Tizen.NUI/src/internal/Ruler.cs +++ b/src/Tizen.NUI/src/internal/Ruler.cs @@ -44,14 +44,6 @@ namespace Tizen.NUI 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. @@ -263,7 +255,5 @@ namespace Tizen.NUI /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. Free } - } - } diff --git a/src/Tizen.NUI/src/internal/RulerDomain.cs b/src/Tizen.NUI/src/internal/RulerDomain.cs index 1f6a998..5d3b5cd 100755 --- a/src/Tizen.NUI/src/internal/RulerDomain.cs +++ b/src/Tizen.NUI/src/internal/RulerDomain.cs @@ -19,10 +19,9 @@ using System.ComponentModel; namespace Tizen.NUI { - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public class RulerDomain : global::System.IDisposable + public class RulerDomain : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -41,63 +40,15 @@ namespace Tizen.NUI 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 Flag to check if it is already disposed. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - protected bool disposed = false; - - - /// Destructor. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - ~RulerDomain() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - 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); - } - } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -112,10 +63,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] public RulerDomain(float min, float max, bool enabled) : this(Interop.Ruler.new_RulerDomain__SWIG_0(min, max, enabled), true) @@ -223,7 +173,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/RulerPtr.cs b/src/Tizen.NUI/src/internal/RulerPtr.cs index 6b13b65..a10b99c 100755 --- a/src/Tizen.NUI/src/internal/RulerPtr.cs +++ b/src/Tizen.NUI/src/internal/RulerPtr.cs @@ -21,7 +21,7 @@ namespace Tizen.NUI { /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - public class RulerPtr : global::System.IDisposable + public class RulerPtr : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -40,64 +40,15 @@ namespace Tizen.NUI 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 Flag to check if it is already disposed. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - protected bool disposed = false; - - /// Destructor. - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - - ~RulerPtr() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. - [EditorBrowsable(EditorBrowsableState.Never)] - public void Dispose() - { - mRuler = null; - //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); - } - } - /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] - protected virtual void Dispose(DisposeTypes type) + 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. @@ -112,7 +63,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -418,7 +369,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_CallbackBase.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_CallbackBase.cs index ff1c2a8..05b6b42 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_CallbackBase.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_CallbackBase.cs @@ -36,5 +36,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Configuration__ContextLoss.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Configuration__ContextLoss.cs index f861201..d33dba5 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Configuration__ContextLoss.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Configuration__ContextLoss.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Configuration__ContextLoss { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__CallbackBase.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__CallbackBase.cs index 4909b41..991889e 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__CallbackBase.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__CallbackBase.cs @@ -36,5 +36,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Constraint.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Constraint.cs index d0b0127..caa4856 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Constraint.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Constraint.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Constraint { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__CustomActorImpl__Extension.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__CustomActorImpl__Extension.cs index c9befa2..111aba9 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__CustomActorImpl__Extension.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__CustomActorImpl__Extension.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__CustomActorImpl__Extension { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__FunctorDelegate.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__FunctorDelegate.cs index a820f4a..3b1466d 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__FunctorDelegate.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__FunctorDelegate.cs @@ -36,5 +36,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Internal__Texture.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Internal__Texture.cs index 3fbcf72..9942def 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Internal__Texture.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Internal__Texture.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Internal__Texture { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Internal__TypeRegistry.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Internal__TypeRegistry.cs index 472a681..e9b1918 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Internal__TypeRegistry.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Internal__TypeRegistry.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Internal__TypeRegistry { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__IntrusivePtrT_Dali__Toolkit__ItemLayout_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__IntrusivePtrT_Dali__Toolkit__ItemLayout_t.cs index b6a2520..2eb8e01 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__IntrusivePtrT_Dali__Toolkit__ItemLayout_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__IntrusivePtrT_Dali__Toolkit__ItemLayout_t.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__IntrusivePtrT_Dali__Toolkit__ItemLayout_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__RectT_unsigned_int_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__RectT_unsigned_int_t.cs index 3246a31..997b0ea 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__RectT_unsigned_int_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__RectT_unsigned_int_t.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__RectT_unsigned_int_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__RenderSurface.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__RenderSurface.cs index e117d4d..c9c1c29 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__RenderSurface.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__RenderSurface.cs @@ -14,10 +14,8 @@ * limitations under the License. * */ - namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__RenderSurface { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -37,5 +35,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_bool_fDali__Actor_Dali__TouchEvent_const_RF_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_bool_fDali__Actor_Dali__TouchEvent_const_RF_t.cs index 3531893..a634018 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_bool_fDali__Actor_Dali__TouchEvent_const_RF_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_bool_fDali__Actor_Dali__TouchEvent_const_RF_t.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__SignalT_bool_fDali__Actor_Dali__TouchEvent_const_RF_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_bool_fDali__Toolkit__AccessibilityManager_R_Dali__TouchEvent_const_RF_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_bool_fDali__Toolkit__AccessibilityManager_R_Dali__TouchEvent_const_RF_t.cs index 88e24e6..b1ca17d 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_bool_fDali__Toolkit__AccessibilityManager_R_Dali__TouchEvent_const_RF_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_bool_fDali__Toolkit__AccessibilityManager_R_Dali__TouchEvent_const_RF_t.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__SignalT_bool_fDali__Toolkit__AccessibilityManager_R_Dali__TouchEvent_const_RF_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Actor_bool_Dali__DevelActor__VisibilityChange__TypeF_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Actor_bool_Dali__DevelActor__VisibilityChange__TypeF_t.cs index f07cda2..16dbd49 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Actor_bool_Dali__DevelActor__VisibilityChange__TypeF_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Actor_bool_Dali__DevelActor__VisibilityChange__TypeF_t.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__SignalT_void_fDali__Actor_bool_Dali__DevelActor__VisibilityChange__TypeF_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__Control_Dali__Toolkit__ControlF_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__Control_Dali__Toolkit__ControlF_t.cs index bae8b9e..3a5516e 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__Control_Dali__Toolkit__ControlF_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__Control_Dali__Toolkit__ControlF_t.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__Control_Dali__Toolkit__ControlF_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextEditor_Dali__Toolkit__TextEditor__InputStyle.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextEditor_Dali__Toolkit__TextEditor__InputStyle.cs index b096399..584d7e3 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextEditor_Dali__Toolkit__TextEditor__InputStyle.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextEditor_Dali__Toolkit__TextEditor__InputStyle.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextEditor_Dali__Toolkit__TextEditor__InputStyle__MaskF_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextField_Dali__Toolkit__TextField__InputStyle__MaskF_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextField_Dali__Toolkit__TextField__InputStyle__MaskF_t.cs index c09e5f3..4cc4d36 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextField_Dali__Toolkit__TextField__InputStyle__MaskF_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextField_Dali__Toolkit__TextField__InputStyle__MaskF_t.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__SignalT_void_fDali__Toolkit__TextField_Dali__Toolkit__TextField__InputStyle__MaskF_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fuint32_t_Dali__PixelDataF_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fuint32_t_Dali__PixelDataF_t.cs index d523deb..7e31510 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fuint32_t_Dali__PixelDataF_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__SignalT_void_fuint32_t_Dali__PixelDataF_t.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__SignalT_void_fuint32_t_Dali__PixelDataF_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__ClampState.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__ClampState.cs index 510b8b5..bcbc7bb 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__ClampState.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__ClampState.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Toolkit__ClampState { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__AsyncImageLoader.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__AsyncImageLoader.cs index e288d78..7cf067a 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__AsyncImageLoader.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__AsyncImageLoader.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Toolkit__Internal__AsyncImageLoader { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__Control__Extension.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__Control__Extension.cs index 4628a67..8487838 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__Control__Extension.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__Control__Extension.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Toolkit__Internal__Control__Extension { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__TransitionData.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__TransitionData.cs index 049002a..625bb3c 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__TransitionData.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__TransitionData.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Toolkit__Internal__TransitionData { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__Visual__Base.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__Visual__Base.cs index 4533321..8443f55 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__Visual__Base.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__Internal__Visual__Base.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Toolkit__Internal__Visual__Base { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__ItemFactory__Extension.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__ItemFactory__Extension.cs index cd942db..1ecbffa 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__ItemFactory__Extension.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Toolkit__ItemFactory__Extension.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Toolkit__ItemFactory__Extension { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__TouchEvent.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__TouchEvent.cs index a5e71bc..7bedde3 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__TouchEvent.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__TouchEvent.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__TouchEvent { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__VectorT_uint32_t_TypeTraitsT_uint32_t_t__IS_TRIVIAL_TYPE__true_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__VectorT_uint32_t_TypeTraitsT_uint32_t_t__IS_TRIVIAL_TYPE__true_t.cs index 4194a8a..3806269 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__VectorT_uint32_t_TypeTraitsT_uint32_t_t__IS_TRIVIAL_TYPE__true_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__VectorT_uint32_t_TypeTraitsT_uint32_t_t__IS_TRIVIAL_TYPE__true_t.cs @@ -16,7 +16,6 @@ */ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__VectorT_uint32_t_TypeTraitsT_uint32_t_t__IS_TRIVIAL_TYPE__true_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -36,5 +35,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Widget__Impl.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Widget__Impl.cs index bd4e5fd..6fafd04 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Widget__Impl.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_Dali__Widget__Impl.cs @@ -16,7 +16,6 @@ */ namespace Tizen.NUI { - internal class SWIGTYPE_p_Dali__Widget__Impl { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -36,5 +35,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_FunctorDelegate.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_FunctorDelegate.cs index 171b20b..25a3178 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_FunctorDelegate.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_FunctorDelegate.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_FunctorDelegate { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_KeyboardFocusManager.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_KeyboardFocusManager.cs index b1a5186..1aeae47 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_KeyboardFocusManager.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_KeyboardFocusManager.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_KeyboardFocusManager { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_PropertyInputContainer.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_PropertyInputContainer.cs index 32f9d65..8298431 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_PropertyInputContainer.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_PropertyInputContainer.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_PropertyInputContainer { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_double.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_double.cs index 048186e..e6952c1 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_double.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_double.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_double { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_float__float.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_float__float.cs index 209b5fe..e25a4cf 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_float__float.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_float__float.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_f_float__float { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_Dali__Property__Index__Dali__Property__Value.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_Dali__Property__Index__Dali__Property__Value.cs index fa6d79c..e07a843 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_Dali__Property__Index__Dali__Property__Value.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_Dali__Property__Index__Dali__Property__Value.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_f_p_Dali__BaseObject_Dali__Property__Index__Dali__Property__Value { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_int_r_q_const__Dali__Property__Value__void.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_int_r_q_const__Dali__Property__Value__void.cs index e332f4f..80c02c9 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_int_r_q_const__Dali__Property__Value__void.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_int_r_q_const__Dali__Property__Value__void.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_f_p_Dali__BaseObject_int_r_q_const__Dali__Property__Value__void { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_p_Dali__ConnectionTrackerInterface.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_p_Dali__ConnectionTrackerInterface.cs index cce5fc9..3fa4b86 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_p_Dali__ConnectionTrackerInterface.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_p_Dali__ConnectionTrackerInterface.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_f_p_Dali__BaseObject_p_Dali__ConnectionTrackerInterface_r_q_const__std__string_p_Dali__FunctorDelegate__bool { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_r_q_const__std__string_r_q_const__Dali__Property__Map__bool.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_r_q_const__std__string_r_q_const__Dali__Property__Map__bool.cs index 3b8400b..5ec30f7 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_r_q_const__std__string_r_q_const__Dali__Property__Map__bool.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_Dali__BaseObject_r_q_const__std__string_r_q_const__Dali__Property__Map__bool.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_f_p_Dali__BaseObject_r_q_const__std__string_r_q_const__Dali__Property__Map__bool { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_q_const__Dali__Any__AnyContainerBase__void.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_q_const__Dali__Any__AnyContainerBase__void.cs index ca1cbb9..378112d 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_q_const__Dali__Any__AnyContainerBase__void.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_p_q_const__Dali__Any__AnyContainerBase__void.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_f_p_q_const__Dali__Any__AnyContainerBase__void { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_Dali__Vector2__bool.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_Dali__Vector2__bool.cs index bc2f6af..7cd643a 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_Dali__Vector2__bool.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_Dali__Vector2__bool.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_f_r_Dali__Vector2__bool { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_q_const__Dali__Any__AnyContainerBase__p_Dali__Any__AnyContainerBase.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_q_const__Dali__Any__AnyContainerBase__p_Dali__Any__AnyContainerBase.cs index d44c6c1..1bef1b6 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_q_const__Dali__Any__AnyContainerBase__p_Dali__Any__AnyContainerBase.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_q_const__Dali__Any__AnyContainerBase__p_Dali__Any__AnyContainerBase.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_f_r_q_const__Dali__Any__AnyContainerBase__p_Dali__Any__AnyContainerBase { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_q_const__Dali__Vector3__float.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_q_const__Dali__Vector3__float.cs index aa663d7..261bc0d 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_q_const__Dali__Vector3__float.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_f_r_q_const__Dali__Vector3__float.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_f_r_q_const__Dali__Vector3__float { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_float.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_float.cs index a014065..40255be 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_float.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_float.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_float { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_int.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_int.cs index a00f2ee..af6c90c 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_int.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_int.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_int { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_p_Dali__TextAbstraction__VectorBlob.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_p_Dali__TextAbstraction__VectorBlob.cs index 2f7b446..75493a5 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_p_Dali__TextAbstraction__VectorBlob.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_p_Dali__TextAbstraction__VectorBlob.cs @@ -16,7 +16,6 @@ */ namespace Tizen.NUI { - internal class SWIGTYPE_p_p_Dali__TextAbstraction__VectorBlob { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -36,5 +35,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_std__type_info.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_std__type_info.cs index d6a09d8..947e45b 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_std__type_info.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_std__type_info.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_std__type_info { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_std__vectorT_Dali__TextAbstraction__FontDescription_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_std__vectorT_Dali__TextAbstraction__FontDescription_t.cs index 5eb7709..c728166 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_std__vectorT_Dali__TextAbstraction__FontDescription_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_std__vectorT_Dali__TextAbstraction__FontDescription_t.cs @@ -16,7 +16,6 @@ */ namespace Tizen.NUI { - internal class SWIGTYPE_p_std__vectorT_Dali__TextAbstraction__FontDescription_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -36,5 +35,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_time_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_time_t.cs index 61b4137..d516232 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_time_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_time_t.cs @@ -16,7 +16,6 @@ */ namespace Tizen.NUI { - internal class SWIGTYPE_p_time_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -36,5 +35,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_tm.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_tm.cs index f56115d..cc7e45e 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_tm.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_tm.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_tm { private global::System.Runtime.InteropServices.HandleRef swigCPtr; diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_uint16_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_uint16_t.cs index 26d0d36..849f755 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_uint16_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_uint16_t.cs @@ -36,5 +36,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_uint8_t.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_uint8_t.cs index 3504f15..fe171eb 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_uint8_t.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_uint8_t.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_uint8_t { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_char.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_char.cs index 4be1d02..5a893cc 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_char.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_char.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_unsigned_char { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_int.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_int.cs index 0da738e..8ba2654 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_int.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_int.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_unsigned_int { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_short.cs b/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_short.cs index 812757c..4b7daaf 100755 --- a/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_short.cs +++ b/src/Tizen.NUI/src/internal/SWIGTYPE_p_unsigned_short.cs @@ -10,7 +10,6 @@ namespace Tizen.NUI { - internal class SWIGTYPE_p_unsigned_short { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -30,5 +29,4 @@ namespace Tizen.NUI return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } } - } diff --git a/src/Tizen.NUI/src/internal/ScrollStateChangedSignal.cs b/src/Tizen.NUI/src/internal/ScrollStateChangedSignal.cs index 2ec6026..cf1328e 100755 --- a/src/Tizen.NUI/src/internal/ScrollStateChangedSignal.cs +++ b/src/Tizen.NUI/src/internal/ScrollStateChangedSignal.cs @@ -20,7 +20,7 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - internal class ScrollStateChangedSignal : global::System.IDisposable + internal class ScrollStateChangedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -36,55 +36,13 @@ namespace Tizen.NUI 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; - - - ~ScrollStateChangedSignal() - { - 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) + 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. @@ -99,7 +57,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -144,7 +102,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ScrollViewSnapStartedSignal.cs b/src/Tizen.NUI/src/internal/ScrollViewSnapStartedSignal.cs index 7dda667..5c593f8 100755 --- a/src/Tizen.NUI/src/internal/ScrollViewSnapStartedSignal.cs +++ b/src/Tizen.NUI/src/internal/ScrollViewSnapStartedSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ScrollViewSnapStartedSignal : global::System.IDisposable + internal class ScrollViewSnapStartedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~ScrollViewSnapStartedSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ScrollableSignal.cs b/src/Tizen.NUI/src/internal/ScrollableSignal.cs index b2ad240..831163e 100755 --- a/src/Tizen.NUI/src/internal/ScrollableSignal.cs +++ b/src/Tizen.NUI/src/internal/ScrollableSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ScrollableSignal : global::System.IDisposable + internal class ScrollableSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~ScrollableSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/SignalConnectorType.cs b/src/Tizen.NUI/src/internal/SignalConnectorType.cs index f2c2f43..d042c03 100755 --- a/src/Tizen.NUI/src/internal/SignalConnectorType.cs +++ b/src/Tizen.NUI/src/internal/SignalConnectorType.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class SignalConnectorType : global::System.IDisposable + internal class SignalConnectorType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~SignalConnectorType() - { - 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) + 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. @@ -97,14 +54,12 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public SignalConnectorType(TypeRegistration typeRegistration, string name, SWIGTYPE_p_f_p_Dali__BaseObject_p_Dali__ConnectionTrackerInterface_r_q_const__std__string_p_Dali__FunctorDelegate__bool func) : this(Interop.NDalic.new_SignalConnectorType(TypeRegistration.getCPtr(typeRegistration), name, SWIGTYPE_p_f_p_Dali__BaseObject_p_Dali__ConnectionTrackerInterface_r_q_const__std__string_p_Dali__FunctorDelegate__bool.getCPtr(func)), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/SignalObserver.cs b/src/Tizen.NUI/src/internal/SignalObserver.cs index 3f403f2..476ee2c 100755 --- a/src/Tizen.NUI/src/internal/SignalObserver.cs +++ b/src/Tizen.NUI/src/internal/SignalObserver.cs @@ -18,10 +18,9 @@ using System; using System.Runtime.InteropServices; using System.ComponentModel; - namespace Tizen.NUI { - internal class SignalObserver : global::System.IDisposable + internal class SignalObserver : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -41,69 +40,17 @@ namespace Tizen.NUI 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. - /// - /// 4 - protected bool disposed = false; - - /// - /// Dispose - /// - /// 3 - ~SignalObserver() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// /// Dispose /// /// 4 - 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); - } - } - - /// - /// Dispose - /// - /// 4 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -118,7 +65,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -132,7 +79,5 @@ namespace Tizen.NUI Interop.SignalObserver.SignalObserver_SignalDisconnected(swigCPtr, SlotObserver.getCPtr(slotObserver), SWIGTYPE_p_Dali__CallbackBase.getCPtr(callback)); if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/SliderMarkReachedSignal.cs b/src/Tizen.NUI/src/internal/SliderMarkReachedSignal.cs index f197b6a..89bf545 100755 --- a/src/Tizen.NUI/src/internal/SliderMarkReachedSignal.cs +++ b/src/Tizen.NUI/src/internal/SliderMarkReachedSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class SliderMarkReachedSignal : global::System.IDisposable + internal class SliderMarkReachedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~SliderMarkReachedSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -144,7 +101,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/SliderValueChangedSignal.cs b/src/Tizen.NUI/src/internal/SliderValueChangedSignal.cs index 0fe6268..94c2e6a 100755 --- a/src/Tizen.NUI/src/internal/SliderValueChangedSignal.cs +++ b/src/Tizen.NUI/src/internal/SliderValueChangedSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class SliderValueChangedSignal : global::System.IDisposable + internal class SliderValueChangedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~SliderValueChangedSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/SlotObserver.cs b/src/Tizen.NUI/src/internal/SlotObserver.cs index e71ba5d..f85fa13 100755 --- a/src/Tizen.NUI/src/internal/SlotObserver.cs +++ b/src/Tizen.NUI/src/internal/SlotObserver.cs @@ -20,7 +20,7 @@ using System.ComponentModel; namespace Tizen.NUI { - internal class SlotObserver : global::System.IDisposable + internal class SlotObserver : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// swigCMemOwn. @@ -38,69 +38,17 @@ namespace Tizen.NUI 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. - /// - /// 4 - protected bool disposed = false; - - /// - /// Dispose. - /// - /// 3 - ~SlotObserver() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// /// Dispose. /// /// 4 - 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); - } - } - - /// - /// Dispose. - /// - /// 4 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -115,7 +63,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -129,15 +77,10 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_delete_SlotObserver")] public static extern void delete_SlotObserver(global::System.Runtime.InteropServices.HandleRef jarg1); - [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_SlotObserver_SlotDisconnected")] public static extern void SlotObserver_SlotDisconnected(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2); - - } - } diff --git a/src/Tizen.NUI/src/internal/SnapType.cs b/src/Tizen.NUI/src/internal/SnapType.cs index a293775..9ecf44d 100755 --- a/src/Tizen.NUI/src/internal/SnapType.cs +++ b/src/Tizen.NUI/src/internal/SnapType.cs @@ -17,11 +17,9 @@ namespace Tizen.NUI { - internal enum SnapType { Snap, Flick } - } diff --git a/src/Tizen.NUI/src/internal/StageWheelSignal.cs b/src/Tizen.NUI/src/internal/StageWheelSignal.cs index bd7cda7..da83e24 100755 --- a/src/Tizen.NUI/src/internal/StageWheelSignal.cs +++ b/src/Tizen.NUI/src/internal/StageWheelSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class StageWheelSignal : global::System.IDisposable + internal class StageWheelSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~StageWheelSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/StateChangedSignalType.cs b/src/Tizen.NUI/src/internal/StateChangedSignalType.cs index 7db3a4c..a743f70 100755 --- a/src/Tizen.NUI/src/internal/StateChangedSignalType.cs +++ b/src/Tizen.NUI/src/internal/StateChangedSignalType.cs @@ -17,7 +17,7 @@ namespace Tizen.NUI { - internal class StateChangedSignalType : global::System.IDisposable + internal class StateChangedSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -33,53 +33,13 @@ namespace Tizen.NUI 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; - - ~StateChangedSignalType() - { - 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) + 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. @@ -94,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -139,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/StatusSignalType.cs b/src/Tizen.NUI/src/internal/StatusSignalType.cs index 80c778c..80a196f 100755 --- a/src/Tizen.NUI/src/internal/StatusSignalType.cs +++ b/src/Tizen.NUI/src/internal/StatusSignalType.cs @@ -20,7 +20,7 @@ using System.ComponentModel; namespace Tizen.NUI { - internal class StatusSignalType : global::System.IDisposable + internal class StatusSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -40,69 +40,17 @@ namespace Tizen.NUI 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. - /// - /// 3 - protected bool disposed = false; - /// /// Dispose /// /// 3 - ~StatusSignalType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose - /// - /// 3 - 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); - } - } - - /// - /// Dispose - /// - /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -117,7 +65,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -191,7 +139,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/StencilFunctionType.cs b/src/Tizen.NUI/src/internal/StencilFunctionType.cs index d35854f..0c2ebed 100755 --- a/src/Tizen.NUI/src/internal/StencilFunctionType.cs +++ b/src/Tizen.NUI/src/internal/StencilFunctionType.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal enum StencilFunctionType { NEVER, @@ -29,5 +28,4 @@ namespace Tizen.NUI GREATER_EQUAL, ALWAYS } - } diff --git a/src/Tizen.NUI/src/internal/StencilOperationType.cs b/src/Tizen.NUI/src/internal/StencilOperationType.cs index 4e7a7ee..294c905 100755 --- a/src/Tizen.NUI/src/internal/StencilOperationType.cs +++ b/src/Tizen.NUI/src/internal/StencilOperationType.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal enum StencilOperationType { ZERO, @@ -29,5 +28,4 @@ namespace Tizen.NUI INCREMENT_WRAP, DECREMENT_WRAP } - } diff --git a/src/Tizen.NUI/src/internal/StringValuePair.cs b/src/Tizen.NUI/src/internal/StringValuePair.cs index 3f16e60..35e171a 100755 --- a/src/Tizen.NUI/src/internal/StringValuePair.cs +++ b/src/Tizen.NUI/src/internal/StringValuePair.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class StringValuePair : global::System.IDisposable + internal class StringValuePair : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -33,55 +32,14 @@ namespace Tizen.NUI { 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; - - - ~StringValuePair() - { - 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) + 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. @@ -96,8 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } + public StringValuePair() : this(Interop.StringValuePair.new_StringValuePair__SWIG_0(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); @@ -143,7 +102,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/StyleChangedSignal.cs b/src/Tizen.NUI/src/internal/StyleChangedSignal.cs index 23b0090..09e9c92 100755 --- a/src/Tizen.NUI/src/internal/StyleChangedSignal.cs +++ b/src/Tizen.NUI/src/internal/StyleChangedSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class StyleChangedSignal : global::System.IDisposable + internal class StyleChangedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~StyleChangedSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/TapGestureDetectedSignal.cs b/src/Tizen.NUI/src/internal/TapGestureDetectedSignal.cs index 0ab4dc1..3f450c6 100755 --- a/src/Tizen.NUI/src/internal/TapGestureDetectedSignal.cs +++ b/src/Tizen.NUI/src/internal/TapGestureDetectedSignal.cs @@ -18,7 +18,7 @@ namespace Tizen.NUI { using Tizen.NUI.BaseComponents; - internal class TapGestureDetectedSignal : global::System.IDisposable + internal class TapGestureDetectedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~TapGestureDetectedSignal() - { - 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) + 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. @@ -97,7 +55,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/TextEditorSignal.cs b/src/Tizen.NUI/src/internal/TextEditorSignal.cs index e77cc76..2a466e4 100755 --- a/src/Tizen.NUI/src/internal/TextEditorSignal.cs +++ b/src/Tizen.NUI/src/internal/TextEditorSignal.cs @@ -20,7 +20,7 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - internal class TextEditorSignal : global::System.IDisposable + internal class TextEditorSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -36,55 +36,13 @@ namespace Tizen.NUI 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; - - - ~TextEditorSignal() - { - 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) + 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. @@ -99,7 +57,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -145,7 +103,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/TextFieldSignal.cs b/src/Tizen.NUI/src/internal/TextFieldSignal.cs index cbc0922..87fbf6a 100755 --- a/src/Tizen.NUI/src/internal/TextFieldSignal.cs +++ b/src/Tizen.NUI/src/internal/TextFieldSignal.cs @@ -19,8 +19,7 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - - internal class TextFieldSignal : global::System.IDisposable + internal class TextFieldSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -36,55 +35,13 @@ namespace Tizen.NUI 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; - - - ~TextFieldSignal() - { - 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) + 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. @@ -99,7 +56,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -145,7 +102,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/TimePeriod.cs b/src/Tizen.NUI/src/internal/TimePeriod.cs index 1ca231d..775577f 100755 --- a/src/Tizen.NUI/src/internal/TimePeriod.cs +++ b/src/Tizen.NUI/src/internal/TimePeriod.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class TimePeriod : global::System.IDisposable + internal class TimePeriod : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~TimePeriod() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -140,7 +97,5 @@ namespace Tizen.NUI return ret; } } - } - } diff --git a/src/Tizen.NUI/src/internal/TimerSignalType.cs b/src/Tizen.NUI/src/internal/TimerSignalType.cs index 07a2487..45fffc3 100755 --- a/src/Tizen.NUI/src/internal/TimerSignalType.cs +++ b/src/Tizen.NUI/src/internal/TimerSignalType.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class TimerSignalType : global::System.IDisposable + internal class TimerSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~TimerSignalType() - { - 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) + 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. @@ -97,10 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.Timer.TimerSignalType_Empty(swigCPtr); @@ -145,7 +101,6 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - public bool Emit() { bool ret = Interop.Timer.TimerSignalType_Emit(swigCPtr); @@ -157,7 +112,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ToolkitPropertyRange.cs b/src/Tizen.NUI/src/internal/ToolkitPropertyRange.cs index be07035..20adf51 100755 --- a/src/Tizen.NUI/src/internal/ToolkitPropertyRange.cs +++ b/src/Tizen.NUI/src/internal/ToolkitPropertyRange.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - internal enum ToolkitPropertyRange { VISUAL_PROPERTY_BASE_START_INDEX = PropertyRanges.CORE_PROPERTY_MAX_INDEX + 1, @@ -25,5 +24,4 @@ namespace Tizen.NUI VISUAL_PROPERTY_START_INDEX = VISUAL_PROPERTY_BASE_END_INDEX + 1, VISUAL_PROPERTY_END_INDEX = VISUAL_PROPERTY_START_INDEX + 100000 } - } diff --git a/src/Tizen.NUI/src/internal/TooltipPositionType.cs b/src/Tizen.NUI/src/internal/TooltipPositionType.cs index d518c96..54527dd 100755 --- a/src/Tizen.NUI/src/internal/TooltipPositionType.cs +++ b/src/Tizen.NUI/src/internal/TooltipPositionType.cs @@ -17,12 +17,10 @@ namespace Tizen.NUI { - internal enum TooltipPositionType { ABOVE, BELOW, HOVER_POINT } - } diff --git a/src/Tizen.NUI/src/internal/TouchDataSignal.cs b/src/Tizen.NUI/src/internal/TouchDataSignal.cs index 7b2c267..1a8986a 100755 --- a/src/Tizen.NUI/src/internal/TouchDataSignal.cs +++ b/src/Tizen.NUI/src/internal/TouchDataSignal.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - internal class TouchDataSignal : global::System.IDisposable + internal class TouchDataSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~TouchDataSignal() - { - 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) + 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. @@ -97,7 +55,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -144,7 +102,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/TouchPoint.cs b/src/Tizen.NUI/src/internal/TouchPoint.cs index 36f8924..a91916f 100755 --- a/src/Tizen.NUI/src/internal/TouchPoint.cs +++ b/src/Tizen.NUI/src/internal/TouchPoint.cs @@ -14,12 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - - using Tizen.NUI.BaseComponents; - internal class TouchPoint : global::System.IDisposable + internal class TouchPoint : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -35,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~TouchPoint() - { - 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) + 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. @@ -98,7 +55,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -203,7 +160,5 @@ namespace Tizen.NUI Interrupted, Last } - } - } diff --git a/src/Tizen.NUI/src/internal/TouchPointContainer.cs b/src/Tizen.NUI/src/internal/TouchPointContainer.cs index 12a04da..e2a291b 100755 --- a/src/Tizen.NUI/src/internal/TouchPointContainer.cs +++ b/src/Tizen.NUI/src/internal/TouchPointContainer.cs @@ -17,9 +17,8 @@ namespace Tizen.NUI { - - internal class TouchPointContainer : global::System.IDisposable, global::System.Collections.IEnumerable - , global::System.Collections.Generic.IEnumerable + internal class TouchPointContainer : Disposable, global::System.Collections.IEnumerable, + global::System.Collections.Generic.IEnumerable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -35,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~TouchPointContainer() - { - 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) + 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. @@ -98,7 +55,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public TouchPointContainer(global::System.Collections.ICollection c) : this() @@ -426,7 +383,5 @@ namespace Tizen.NUI Interop.TouchPointContainer.TouchPointContainer_SetRange(swigCPtr, index, TouchPointContainer.getCPtr(values)); if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/TouchSignal.cs b/src/Tizen.NUI/src/internal/TouchSignal.cs index d227a23..4a6cb63 100755 --- a/src/Tizen.NUI/src/internal/TouchSignal.cs +++ b/src/Tizen.NUI/src/internal/TouchSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class TouchSignal : global::System.IDisposable + internal class TouchSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~TouchSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/TypeAction.cs b/src/Tizen.NUI/src/internal/TypeAction.cs index 6e06aaa..5025d60 100755 --- a/src/Tizen.NUI/src/internal/TypeAction.cs +++ b/src/Tizen.NUI/src/internal/TypeAction.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class TypeAction : global::System.IDisposable + internal class TypeAction : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~TypeAction() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -105,7 +62,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/TypeRegistration.cs b/src/Tizen.NUI/src/internal/TypeRegistration.cs index 9eb2903..df288e6 100755 --- a/src/Tizen.NUI/src/internal/TypeRegistration.cs +++ b/src/Tizen.NUI/src/internal/TypeRegistration.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class TypeRegistration : global::System.IDisposable + internal class TypeRegistration : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -33,55 +32,14 @@ namespace Tizen.NUI { 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; - - - ~TypeRegistration() - { - 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) + 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. @@ -96,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } static private global::System.IntPtr SwigConstructTypeRegistration(SWIGTYPE_p_std__type_info registerType, SWIGTYPE_p_std__type_info baseType, System.Delegate f) @@ -157,7 +115,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } } - } - } diff --git a/src/Tizen.NUI/src/internal/Uint16Pair.cs b/src/Tizen.NUI/src/internal/Uint16Pair.cs index a2272dc..0b462b1 100755 --- a/src/Tizen.NUI/src/internal/Uint16Pair.cs +++ b/src/Tizen.NUI/src/internal/Uint16Pair.cs @@ -31,7 +31,7 @@ namespace Tizen.NUI /// common architectures.
///
/// 3 - internal class Uint16Pair : global::System.IDisposable + internal class Uint16Pair : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// swigCMemOwn. @@ -49,69 +49,17 @@ namespace Tizen.NUI 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. - /// - /// 3 - protected bool disposed = false; - /// /// Dispose. /// /// 3 - ~Uint16Pair() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// - /// Dispose. - /// - /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -126,7 +74,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -323,7 +271,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/VectorBase.cs b/src/Tizen.NUI/src/internal/VectorBase.cs index a87f5cb..b0fb7f4 100755 --- a/src/Tizen.NUI/src/internal/VectorBase.cs +++ b/src/Tizen.NUI/src/internal/VectorBase.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class VectorBase : global::System.IDisposable + internal class VectorBase : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~VectorBase() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -134,7 +91,5 @@ namespace Tizen.NUI Interop.VectorBase.VectorBase_Release(swigCPtr); if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/VectorBlob.cs b/src/Tizen.NUI/src/internal/VectorBlob.cs index 1820d4e..fd7778c 100755 --- a/src/Tizen.NUI/src/internal/VectorBlob.cs +++ b/src/Tizen.NUI/src/internal/VectorBlob.cs @@ -16,8 +16,7 @@ */ namespace Tizen.NUI { - - internal class VectorBlob : global::System.IDisposable + internal class VectorBlob : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -33,55 +32,13 @@ namespace Tizen.NUI 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; - - ~VectorBlob() - { - 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) + 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. @@ -95,7 +52,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public byte R diff --git a/src/Tizen.NUI/src/internal/VectorUint16Pair.cs b/src/Tizen.NUI/src/internal/VectorUint16Pair.cs index 182f2bf..4d1ee16 100755 --- a/src/Tizen.NUI/src/internal/VectorUint16Pair.cs +++ b/src/Tizen.NUI/src/internal/VectorUint16Pair.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class VectorUint16Pair : global::System.IDisposable + internal class VectorUint16Pair : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~VectorUint16Pair() - { - 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) + 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. @@ -97,10 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public VectorUint16Pair() : this(Interop.VectorUint16Pair.new_VectorUint16Pair__SWIG_0(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); @@ -218,7 +174,5 @@ namespace Tizen.NUI } public static readonly int BaseType = Interop.VectorUint16Pair.VectorUint16Pair_BaseType_get(); - } - } diff --git a/src/Tizen.NUI/src/internal/VectorUnsignedChar.cs b/src/Tizen.NUI/src/internal/VectorUnsignedChar.cs index 74f0f13..26e81b7 100755 --- a/src/Tizen.NUI/src/internal/VectorUnsignedChar.cs +++ b/src/Tizen.NUI/src/internal/VectorUnsignedChar.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class VectorUnsignedChar : global::System.IDisposable + internal class VectorUnsignedChar : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~VectorUnsignedChar() - { - 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) + 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. @@ -97,10 +54,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public VectorUnsignedChar() : this(Interop.VectorUnsignedChar.new_VectorUnsignedChar__SWIG_0(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); @@ -218,7 +174,5 @@ namespace Tizen.NUI } public static readonly int BaseType = Interop.VectorUnsignedChar.VectorUnsignedChar_BaseType_get(); - } - } diff --git a/src/Tizen.NUI/src/internal/VideoViewSignal.cs b/src/Tizen.NUI/src/internal/VideoViewSignal.cs index bbc61d8..050953d 100755 --- a/src/Tizen.NUI/src/internal/VideoViewSignal.cs +++ b/src/Tizen.NUI/src/internal/VideoViewSignal.cs @@ -19,68 +19,29 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - internal class VideoViewSignal : global::System.IDisposable { - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - protected bool swigCMemOwn; - - internal VideoViewSignal(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(VideoViewSignal 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; - + internal class VideoViewSignal : Disposable + { + private global::System.Runtime.InteropServices.HandleRef swigCPtr; + protected bool swigCMemOwn; - ~VideoViewSignal() + internal VideoViewSignal(global::System.IntPtr cPtr, bool cMemoryOwn) { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } + swigCMemOwn = cMemoryOwn; + swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); } - public void Dispose() + internal static global::System.Runtime.InteropServices.HandleRef getCPtr(VideoViewSignal obj) { - //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); - } + return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } - protected virtual void Dispose(DisposeTypes type) + 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. @@ -95,47 +56,51 @@ namespace Tizen.NUI { swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { - bool ret = Interop.VideoView.VideoViewSignal_Empty(swigCPtr); - if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - return ret; - } - - public uint GetConnectionCount() { - uint ret = Interop.VideoView.VideoViewSignal_GetConnectionCount(swigCPtr); - if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - return ret; - } - - public void Connect(System.Delegate func) { -System.IntPtr ip = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate(func); - { - Interop.VideoView.VideoViewSignal_Connect(swigCPtr, new System.Runtime.InteropServices.HandleRef(this, ip)); - if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } - } + public bool Empty() + { + bool ret = Interop.VideoView.VideoViewSignal_Empty(swigCPtr); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } - public void Disconnect(System.Delegate func) { -System.IntPtr ip = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate(func); - { - Interop.VideoView.VideoViewSignal_Disconnect(swigCPtr, new System.Runtime.InteropServices.HandleRef(this, ip)); - if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } - } + public uint GetConnectionCount() + { + uint ret = Interop.VideoView.VideoViewSignal_GetConnectionCount(swigCPtr); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + return ret; + } - public void Emit(VideoView arg) { - Interop.VideoView.VideoViewSignal_Emit(swigCPtr, VideoView.getCPtr(arg)); - if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public void Connect(System.Delegate func) + { + System.IntPtr ip = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate(func); + { + Interop.VideoView.VideoViewSignal_Connect(swigCPtr, new System.Runtime.InteropServices.HandleRef(this, ip)); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + } - public VideoViewSignal() : this(Interop.VideoView.new_VideoViewSignal(), true) { - if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } + public void Disconnect(System.Delegate func) + { + System.IntPtr ip = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate(func); + { + Interop.VideoView.VideoViewSignal_Disconnect(swigCPtr, new System.Runtime.InteropServices.HandleRef(this, ip)); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + } -} + public void Emit(VideoView arg) + { + Interop.VideoView.VideoViewSignal_Emit(swigCPtr, VideoView.getCPtr(arg)); + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + public VideoViewSignal() : this(Interop.VideoView.new_VideoViewSignal(), true) + { + if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); + } + } } diff --git a/src/Tizen.NUI/src/internal/ViewImpl.cs b/src/Tizen.NUI/src/internal/ViewImpl.cs index a7a2827..48385f4 100755 --- a/src/Tizen.NUI/src/internal/ViewImpl.cs +++ b/src/Tizen.NUI/src/internal/ViewImpl.cs @@ -22,7 +22,6 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - internal class ViewImpl : CustomActorImpl { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -44,14 +43,6 @@ namespace Tizen.NUI 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. @@ -69,7 +60,6 @@ namespace Tizen.NUI base.Dispose(type); } - public static View New() { View ret = new View(Interop.ViewImpl.ViewImpl_New(), true); @@ -1020,5 +1010,4 @@ namespace Tizen.NUI private static global::System.Type[] swigMethodTypes39 = new global::System.Type[] { typeof(SlotObserver), typeof(SWIGTYPE_p_Dali__CallbackBase) }; private static global::System.Type[] swigMethodTypes40 = new global::System.Type[] { typeof(SlotObserver), typeof(SWIGTYPE_p_Dali__CallbackBase) }; } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/internal/ViewLayoutDirectionChangedSignal.cs b/src/Tizen.NUI/src/internal/ViewLayoutDirectionChangedSignal.cs index 338c99a..8bf3c92 100755 --- a/src/Tizen.NUI/src/internal/ViewLayoutDirectionChangedSignal.cs +++ b/src/Tizen.NUI/src/internal/ViewLayoutDirectionChangedSignal.cs @@ -19,8 +19,7 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - - internal class ViewLayoutDirectionChangedSignal : global::System.IDisposable + internal class ViewLayoutDirectionChangedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -36,53 +35,13 @@ namespace Tizen.NUI 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; - - ~ViewLayoutDirectionChangedSignal() - { - 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) + 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. @@ -97,7 +56,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -142,6 +101,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } } \ No newline at end of file diff --git a/src/Tizen.NUI/src/internal/ViewResourceReadySignal.cs b/src/Tizen.NUI/src/internal/ViewResourceReadySignal.cs index fb8d0a5..37b8a57 100755 --- a/src/Tizen.NUI/src/internal/ViewResourceReadySignal.cs +++ b/src/Tizen.NUI/src/internal/ViewResourceReadySignal.cs @@ -20,7 +20,7 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - internal class ViewResourceReadySignal : global::System.IDisposable + internal class ViewResourceReadySignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -36,55 +36,13 @@ namespace Tizen.NUI 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; - - - ~ViewResourceReadySignal() - { - 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) + 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. @@ -99,7 +57,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -144,7 +102,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ViewSignal.cs b/src/Tizen.NUI/src/internal/ViewSignal.cs index 09ee2b7..8b8dc46 100755 --- a/src/Tizen.NUI/src/internal/ViewSignal.cs +++ b/src/Tizen.NUI/src/internal/ViewSignal.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - internal class ViewSignal : global::System.IDisposable + internal class ViewSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~ViewSignal() - { - 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) + 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. @@ -97,10 +55,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.ActorSignal.ActorSignal_Empty(swigCPtr); @@ -143,7 +100,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ViewVisibilityChangedSignal.cs b/src/Tizen.NUI/src/internal/ViewVisibilityChangedSignal.cs index 92de512..8d6dd2f 100755 --- a/src/Tizen.NUI/src/internal/ViewVisibilityChangedSignal.cs +++ b/src/Tizen.NUI/src/internal/ViewVisibilityChangedSignal.cs @@ -19,7 +19,7 @@ using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - internal class ViewVisibilityChangedSignal : global::System.IDisposable + internal class ViewVisibilityChangedSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -35,55 +35,13 @@ namespace Tizen.NUI 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; - - - ~ViewVisibilityChangedSignal() - { - 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) + 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. @@ -98,7 +56,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -144,7 +102,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/ViewWrapperImpl.cs b/src/Tizen.NUI/src/internal/ViewWrapperImpl.cs index ab9baf6..fe457b5 100755 --- a/src/Tizen.NUI/src/internal/ViewWrapperImpl.cs +++ b/src/Tizen.NUI/src/internal/ViewWrapperImpl.cs @@ -16,6 +16,7 @@ */ using System.Runtime.InteropServices; using Tizen.NUI.BaseComponents; + namespace Tizen.NUI { internal sealed class ViewWrapperImpl : ViewImpl @@ -154,14 +155,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/internal/VisualEventSignal.cs b/src/Tizen.NUI/src/internal/VisualEventSignal.cs index 24149a1..ee1cd3a 100755 --- a/src/Tizen.NUI/src/internal/VisualEventSignal.cs +++ b/src/Tizen.NUI/src/internal/VisualEventSignal.cs @@ -20,55 +20,20 @@ using System.Runtime.InteropServices; namespace Tizen.NUI { - internal class VisualEventSignal : IDisposable + internal class VisualEventSignal : Disposable { public VisualEventSignal() : this(Interop.VisualEventSignal.New(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - ~VisualEventSignal() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - public void Dispose() - { - 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); - GC.SuppressFinalize(this); - } - } - - protected virtual void Dispose(DisposeTypes type) + 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. @@ -82,7 +47,7 @@ namespace Tizen.NUI } swigCPtr = new HandleRef(null, IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -140,9 +105,5 @@ namespace Tizen.NUI private HandleRef swigCPtr; protected bool swigCMemOwn; - - private bool isDisposeQueued = false; - protected bool disposed = false; - } } diff --git a/src/Tizen.NUI/src/internal/VoidSignal.cs b/src/Tizen.NUI/src/internal/VoidSignal.cs index afa7b44..3013dbc 100755 --- a/src/Tizen.NUI/src/internal/VoidSignal.cs +++ b/src/Tizen.NUI/src/internal/VoidSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class VoidSignal : global::System.IDisposable + internal class VoidSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~VoidSignal() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -149,7 +106,5 @@ namespace Tizen.NUI Interop.VoidSignal.VoidSignal_Emit(swigCPtr); if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/WatchApplication.cs b/src/Tizen.NUI/src/internal/WatchApplication.cs index ed884af..6019117 100755 --- a/src/Tizen.NUI/src/internal/WatchApplication.cs +++ b/src/Tizen.NUI/src/internal/WatchApplication.cs @@ -17,6 +17,7 @@ using System; using System.Runtime.InteropServices; + namespace Tizen.NUI { internal class WatchApplication : Application @@ -40,14 +41,6 @@ namespace Tizen.NUI 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. @@ -373,7 +366,5 @@ namespace Tizen.NUI } private static WatchApplication _instance; //singleton - } - } diff --git a/src/Tizen.NUI/src/internal/WatchBoolSignal.cs b/src/Tizen.NUI/src/internal/WatchBoolSignal.cs index a83af3f..589823f 100755 --- a/src/Tizen.NUI/src/internal/WatchBoolSignal.cs +++ b/src/Tizen.NUI/src/internal/WatchBoolSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class WatchBoolSignal : global::System.IDisposable + internal class WatchBoolSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +33,13 @@ namespace Tizen.NUI 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; - - ~WatchBoolSignal() - { - 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) + 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. @@ -96,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -141,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/WatchTimeSignal.cs b/src/Tizen.NUI/src/internal/WatchTimeSignal.cs index 31bd24c..58fcd52 100755 --- a/src/Tizen.NUI/src/internal/WatchTimeSignal.cs +++ b/src/Tizen.NUI/src/internal/WatchTimeSignal.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class WatchTimeSignal : global::System.IDisposable + internal class WatchTimeSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,54 +33,13 @@ namespace Tizen.NUI 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; - - ~WatchTimeSignal() - { - 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) + 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. @@ -96,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -141,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/WeakEventHandler.cs b/src/Tizen.NUI/src/internal/WeakEventHandler.cs index b273b60..d05b11f 100755 --- a/src/Tizen.NUI/src/internal/WeakEventHandler.cs +++ b/src/Tizen.NUI/src/internal/WeakEventHandler.cs @@ -26,7 +26,6 @@ namespace Tizen.NUI } } } -} - + } } diff --git a/src/Tizen.NUI/src/internal/WebViewPageLoadErrorSignal.cs b/src/Tizen.NUI/src/internal/WebViewPageLoadErrorSignal.cs old mode 100644 new mode 100755 index 8903feb..a871b49 --- a/src/Tizen.NUI/src/internal/WebViewPageLoadErrorSignal.cs +++ b/src/Tizen.NUI/src/internal/WebViewPageLoadErrorSignal.cs @@ -17,7 +17,7 @@ namespace Tizen.NUI { - internal class WebViewPageLoadErrorSignal : global::System.IDisposable + internal class WebViewPageLoadErrorSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -26,48 +26,13 @@ namespace Tizen.NUI 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; - //A Flat to check if it is already disposed. - protected bool disposed; - - ~WebViewPageLoadErrorSignal() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - public void Dispose() - { - if (isDisposeQueued) - { - Dispose(false); - } - else - { - Dispose(true); - System.GC.SuppressFinalize(this); - } - } - - protected virtual void Dispose(bool disposing) + protected override void Dispose(DisposeTypes type) { if (disposed) { return; } - if (disposing) - { - //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. @@ -78,7 +43,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public void Connect(System.Delegate func) @@ -109,7 +74,5 @@ namespace Tizen.NUI { swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); } - } - } diff --git a/src/Tizen.NUI/src/internal/WebViewPageLoadSignal.cs b/src/Tizen.NUI/src/internal/WebViewPageLoadSignal.cs old mode 100644 new mode 100755 index f7da87f..90fdd4a --- a/src/Tizen.NUI/src/internal/WebViewPageLoadSignal.cs +++ b/src/Tizen.NUI/src/internal/WebViewPageLoadSignal.cs @@ -17,7 +17,7 @@ namespace Tizen.NUI { - internal class WebViewPageLoadSignal : global::System.IDisposable + internal class WebViewPageLoadSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; @@ -26,48 +26,13 @@ namespace Tizen.NUI 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; - //A Flat to check if it is already disposed. - protected bool disposed; - - ~WebViewPageLoadSignal() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - public void Dispose() - { - if (isDisposeQueued) - { - Dispose(false); - } - else - { - Dispose(true); - System.GC.SuppressFinalize(this); - } - } - - protected virtual void Dispose(bool disposing) + protected override void Dispose(DisposeTypes type) { if (disposed) { return; } - if (disposing) - { - //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. @@ -78,7 +43,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public void Connect(System.Delegate func) @@ -109,7 +74,5 @@ namespace Tizen.NUI { swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); } - } - } diff --git a/src/Tizen.NUI/src/internal/WheelSignal.cs b/src/Tizen.NUI/src/internal/WheelSignal.cs index eb42710..0b979af 100755 --- a/src/Tizen.NUI/src/internal/WheelSignal.cs +++ b/src/Tizen.NUI/src/internal/WheelSignal.cs @@ -14,11 +14,11 @@ * limitations under the License. * */ +using Tizen.NUI.BaseComponents; namespace Tizen.NUI { - using Tizen.NUI.BaseComponents; - internal class WheelSignal : global::System.IDisposable + internal class WheelSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +34,13 @@ namespace Tizen.NUI 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; - - - ~WheelSignal() - { - 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) + 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. @@ -97,10 +55,9 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - public bool Empty() { bool ret = Interop.ActorWheelSignal.ActorWheelSignal_Empty(swigCPtr); @@ -144,7 +101,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/WidgetApplication.cs b/src/Tizen.NUI/src/internal/WidgetApplication.cs index d89728c..263f96d 100755 --- a/src/Tizen.NUI/src/internal/WidgetApplication.cs +++ b/src/Tizen.NUI/src/internal/WidgetApplication.cs @@ -44,13 +44,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/internal/WidgetImpl.cs b/src/Tizen.NUI/src/internal/WidgetImpl.cs index e23fda4..884e547 100755 --- a/src/Tizen.NUI/src/internal/WidgetImpl.cs +++ b/src/Tizen.NUI/src/internal/WidgetImpl.cs @@ -46,13 +46,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/internal/WidgetImplPtr.cs b/src/Tizen.NUI/src/internal/WidgetImplPtr.cs index 3f49a8a..21f4a36 100755 --- a/src/Tizen.NUI/src/internal/WidgetImplPtr.cs +++ b/src/Tizen.NUI/src/internal/WidgetImplPtr.cs @@ -16,7 +16,6 @@ */ namespace Tizen.NUI { - internal class WidgetImplPtr { private global::System.Runtime.InteropServices.HandleRef swigCPtr; diff --git a/src/Tizen.NUI/src/internal/WidgetViewSignal.cs b/src/Tizen.NUI/src/internal/WidgetViewSignal.cs index 07a57f5..d016f2b 100755 --- a/src/Tizen.NUI/src/internal/WidgetViewSignal.cs +++ b/src/Tizen.NUI/src/internal/WidgetViewSignal.cs @@ -15,7 +15,7 @@ namespace Tizen.NUI /// WidgetViewSignal /// /// 3 - public class WidgetViewSignal : global::System.IDisposable + public class WidgetViewSignal : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -39,30 +39,24 @@ namespace Tizen.NUI /// Dispose /// /// 3 - ~WidgetViewSignal() + protected override void Dispose(DisposeTypes type) { - Dispose(); - } + if (disposed) + { + return; + } - /// - /// Dispose - /// - /// 3 - public virtual void Dispose() - { - lock (this) + if (swigCPtr.Handle != global::System.IntPtr.Zero) { - if (swigCPtr.Handle != global::System.IntPtr.Zero) + if (swigCMemOwn) { - if (swigCMemOwn) - { - swigCMemOwn = false; - Interop.WidgetView.delete_WidgetViewSignal(swigCPtr); - } - swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); + swigCMemOwn = false; + Interop.WidgetView.delete_WidgetViewSignal(swigCPtr); } - global::System.GC.SuppressFinalize(this); + swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } + + base.Dispose(type); } /// @@ -136,6 +130,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } } diff --git a/src/Tizen.NUI/src/internal/WindowFocusSignalType.cs b/src/Tizen.NUI/src/internal/WindowFocusSignalType.cs index c065cac..025d71f 100755 --- a/src/Tizen.NUI/src/internal/WindowFocusSignalType.cs +++ b/src/Tizen.NUI/src/internal/WindowFocusSignalType.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class WindowFocusSignalType : global::System.IDisposable + internal class WindowFocusSignalType : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,56 +33,13 @@ namespace Tizen.NUI 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; - - - ~WindowFocusSignalType() - { - 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) + 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. @@ -98,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public bool Empty() @@ -143,7 +99,5 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - } - } diff --git a/src/Tizen.NUI/src/internal/doublep.cs b/src/Tizen.NUI/src/internal/doublep.cs index 8a7874a..131527c 100755 --- a/src/Tizen.NUI/src/internal/doublep.cs +++ b/src/Tizen.NUI/src/internal/doublep.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class doublep : global::System.IDisposable + internal class doublep : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~doublep() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public doublep() : this(Interop.doublep.new_doublep(), true) @@ -133,7 +90,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/floatp.cs b/src/Tizen.NUI/src/internal/floatp.cs index aadf385..c3fb0e5 100755 --- a/src/Tizen.NUI/src/internal/floatp.cs +++ b/src/Tizen.NUI/src/internal/floatp.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class floatp : global::System.IDisposable + internal class floatp : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~floatp() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public floatp() : this(Interop.floatp.new_floatp(), true) @@ -133,7 +90,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/intp.cs b/src/Tizen.NUI/src/internal/intp.cs index 8bfc321..f85eac8 100755 --- a/src/Tizen.NUI/src/internal/intp.cs +++ b/src/Tizen.NUI/src/internal/intp.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class intp : global::System.IDisposable + internal class intp : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~intp() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public intp() : this(Interop.intp.new_intp(), true) @@ -133,7 +90,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/uintp.cs b/src/Tizen.NUI/src/internal/uintp.cs index a600c6d..88e0084 100755 --- a/src/Tizen.NUI/src/internal/uintp.cs +++ b/src/Tizen.NUI/src/internal/uintp.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class uintp : global::System.IDisposable + internal class uintp : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~uintp() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } @@ -134,7 +91,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/internal/ushortp.cs b/src/Tizen.NUI/src/internal/ushortp.cs index 8ee811b..d47d4ca 100755 --- a/src/Tizen.NUI/src/internal/ushortp.cs +++ b/src/Tizen.NUI/src/internal/ushortp.cs @@ -17,8 +17,7 @@ namespace Tizen.NUI { - - internal class ushortp : global::System.IDisposable + internal class ushortp : Disposable { private global::System.Runtime.InteropServices.HandleRef swigCPtr; protected bool swigCMemOwn; @@ -34,55 +33,13 @@ namespace Tizen.NUI 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; - - - ~ushortp() - { - 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) + 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. @@ -97,7 +54,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } public ushortp() : this(Interop.ushortp.new_ushortp(), true) @@ -133,7 +90,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } diff --git a/src/Tizen.NUI/src/public/Adaptor.cs b/src/Tizen.NUI/src/public/Adaptor.cs index 1f127ad..ac320a0 100755 --- a/src/Tizen.NUI/src/public/Adaptor.cs +++ b/src/Tizen.NUI/src/public/Adaptor.cs @@ -37,24 +37,15 @@ namespace Tizen.NUI /// /// /// 4 - public class Adaptor : global::System.IDisposable + public class Adaptor : Disposable { /// swigCMemOwn. /// 4 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 4 - protected bool disposed = false; - private static readonly Adaptor instance = Adaptor.Get(); private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - private EventHandler _resizedEventHandler; private ResizedCallbackDelegate _resizedCallbackDelegate; @@ -67,19 +58,6 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); } - /// - /// Dispose. - /// - /// 3 - ~Adaptor() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - [UnmanagedFunctionPointer(CallingConvention.StdCall)] private delegate void ResizedCallbackDelegate(IntPtr adaptor); @@ -149,26 +127,6 @@ namespace Tizen.NUI } } - /// 4 - 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); - } - } - /// /// Feeds a wheel event to the adaptor. /// @@ -406,21 +364,13 @@ namespace Tizen.NUI /// Dispose. ///
/// 4 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -432,7 +382,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private void OnResized(IntPtr adaptor) diff --git a/src/Tizen.NUI/src/public/AlphaFunction.cs b/src/Tizen.NUI/src/public/AlphaFunction.cs index ec84884..57d19ad 100755 --- a/src/Tizen.NUI/src/public/AlphaFunction.cs +++ b/src/Tizen.NUI/src/public/AlphaFunction.cs @@ -24,20 +24,12 @@ namespace Tizen.NUI /// the animation before computing the final animation value. ///
/// 3 - public class AlphaFunction : global::System.IDisposable + public class AlphaFunction : Disposable { /// swigCMemOwn. /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; /// /// The constructor.
@@ -96,19 +88,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~AlphaFunction() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// This specifies the various types of BuiltinFunctions. /// /// 3 @@ -198,29 +177,6 @@ namespace Tizen.NUI } /// - /// To make the AlphaFunction instance be disposed. - /// - /// 3 - 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); - } - } - - /// /// Retrives the control points of the alpha function.
///
/// A Vector2 which will be used as the first control point of the curve. @@ -359,20 +315,13 @@ namespace Tizen.NUI /// To make the AlphaFunction instance be disposed. ///
/// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -386,7 +335,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Animatable.cs b/src/Tizen.NUI/src/public/Animatable.cs index f1aabe3..3ea415f 100755 --- a/src/Tizen.NUI/src/public/Animatable.cs +++ b/src/Tizen.NUI/src/public/Animatable.cs @@ -256,14 +256,6 @@ namespace Tizen.NUI 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. @@ -280,7 +272,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } diff --git a/src/Tizen.NUI/src/public/Animation.cs b/src/Tizen.NUI/src/public/Animation.cs index 3eb7772..6fcec31 100755 --- a/src/Tizen.NUI/src/public/Animation.cs +++ b/src/Tizen.NUI/src/public/Animation.cs @@ -1345,17 +1345,6 @@ namespace Tizen.NUI { return; } - if(type == DisposeTypes.Explicit) - { - //Called by User - //Release your own managed resources here. - //You should release all of your own disposable objects here. - - } - else if(type == DisposeTypes.Implicit) - { - - } if (this != null) { @@ -1406,7 +1395,5 @@ namespace Tizen.NUI { return (int)(sec * 1000); } - } - } diff --git a/src/Tizen.NUI/src/public/AutofillContainer.cs b/src/Tizen.NUI/src/public/AutofillContainer.cs index 3d45b92..f7155b8 100755 --- a/src/Tizen.NUI/src/public/AutofillContainer.cs +++ b/src/Tizen.NUI/src/public/AutofillContainer.cs @@ -293,14 +293,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/BaseComponents/AnimatedVectorImageView.cs b/src/Tizen.NUI/src/public/BaseComponents/AnimatedVectorImageView.cs index 543275f..d07312c 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/AnimatedVectorImageView.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/AnimatedVectorImageView.cs @@ -70,13 +70,6 @@ namespace Tizen.NUI.BaseComponents tlog.Fatal(tag, $" <<< [{GetId()}]AnimatedVectorImageView.Dispose(type={type})!"); - 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. diff --git a/src/Tizen.NUI/src/public/BaseComponents/FlexContainer.cs b/src/Tizen.NUI/src/public/BaseComponents/FlexContainer.cs index 05d704b..101dc79 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/FlexContainer.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/FlexContainer.cs @@ -407,13 +407,6 @@ namespace Tizen.NUI.BaseComponents 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. diff --git a/src/Tizen.NUI/src/public/BaseComponents/TableView.cs b/src/Tizen.NUI/src/public/BaseComponents/TableView.cs index f21fef6..ba98516 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TableView.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TableView.cs @@ -604,13 +604,6 @@ namespace Tizen.NUI.BaseComponents 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. @@ -632,22 +625,14 @@ namespace Tizen.NUI.BaseComponents /// Class to specify the layout position for the child view. ///
/// 3 - public class CellPosition : global::System.IDisposable + public class CellPosition : Disposable { /// /// swigCMemOwn /// /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; /// /// The constructor. @@ -711,19 +696,6 @@ namespace Tizen.NUI.BaseComponents } /// - /// Dispose. - /// - /// 3 - ~CellPosition() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The index of a row. /// /// 3 @@ -864,30 +836,6 @@ namespace Tizen.NUI.BaseComponents } } - - /// - /// Dispose. - /// - /// 3 - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(CellPosition obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; @@ -898,20 +846,13 @@ namespace Tizen.NUI.BaseComponents /// /// DisposeTypes /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -925,9 +866,8 @@ namespace Tizen.NUI.BaseComponents } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - } internal new class Property diff --git a/src/Tizen.NUI/src/public/BaseComponents/TextEditor.cs b/src/Tizen.NUI/src/public/BaseComponents/TextEditor.cs index 6d4b73d..6b8eb74 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TextEditor.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TextEditor.cs @@ -2094,13 +2094,6 @@ namespace Tizen.NUI.BaseComponents 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. @@ -2137,7 +2130,6 @@ namespace Tizen.NUI.BaseComponents //here we send all data to user event handlers _textEditorTextChangedEventHandler(this, e); } - } private void OnScrollStateChanged(IntPtr textEditor, ScrollState state) diff --git a/src/Tizen.NUI/src/public/BaseComponents/TextField.cs b/src/Tizen.NUI/src/public/BaseComponents/TextField.cs index 25554d9..884c84f 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TextField.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TextField.cs @@ -1975,7 +1975,7 @@ namespace Tizen.NUI.BaseComponents /// /// The Enable selection property. /// - /// 5.5 + /// 6 /// This will be released at Tizen.NET API Level 5, so currently this would be used as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] public bool EnableGrabHandle @@ -1994,7 +1994,7 @@ namespace Tizen.NUI.BaseComponents /// /// The Enable selection property. /// - /// 5.5 + /// 6 /// This will be released at Tizen.NET API Level 5, so currently this would be used as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] public bool EnableGrabHandlePopup @@ -2144,7 +2144,7 @@ namespace Tizen.NUI.BaseComponents /// /// Select the whole text. /// - /// 5.5 + /// 6 /// This will be released at Tizen.NET API Level 5.5, so currently this would be used as inhouse API. [EditorBrowsable(EditorBrowsableState.Never)] public void SelectWholeText() @@ -2191,13 +2191,6 @@ namespace Tizen.NUI.BaseComponents 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. diff --git a/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs b/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs index 0678009..a99f5a4 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs @@ -1325,13 +1325,6 @@ namespace Tizen.NUI.BaseComponents 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. diff --git a/src/Tizen.NUI/src/public/BaseComponents/VectorAnimationView.cs b/src/Tizen.NUI/src/public/BaseComponents/VectorAnimationView.cs index 852f357..556d3d1 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/VectorAnimationView.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/VectorAnimationView.cs @@ -66,13 +66,6 @@ namespace Tizen.NUI.BaseComponents } tlog.Fatal(tag, $"<<< [{GetId()}] VectorAnimationView.Dispose(type={type})"); - 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. diff --git a/src/Tizen.NUI/src/public/BaseComponents/VideoView.cs b/src/Tizen.NUI/src/public/BaseComponents/VideoView.cs index 04afe6f..f03ccef 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/VideoView.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/VideoView.cs @@ -372,13 +372,6 @@ namespace Tizen.NUI.BaseComponents 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. diff --git a/src/Tizen.NUI/src/public/BaseComponents/View.cs b/src/Tizen.NUI/src/public/BaseComponents/View.cs index f6ae496..8373923 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/View.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/View.cs @@ -5339,13 +5339,6 @@ namespace Tizen.NUI.BaseComponents //_mergedStyle = null; - 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. diff --git a/src/Tizen.NUI/src/public/Color.cs b/src/Tizen.NUI/src/public/Color.cs index 45b089f..e273330 100755 --- a/src/Tizen.NUI/src/public/Color.cs +++ b/src/Tizen.NUI/src/public/Color.cs @@ -26,9 +26,8 @@ namespace Tizen.NUI /// The Color class. ///
[Tizen.NUI.Binding.TypeConverter(typeof(ColorTypeConverter))] - public class Color : global::System.IDisposable + public class Color : Disposable { - /// /// Gets the black colored Color class. /// @@ -89,16 +88,7 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - private readonly bool hashDummy; /// @@ -142,19 +132,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~Color() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The red component. /// /// 3 @@ -355,29 +332,6 @@ namespace Tizen.NUI } /// - /// To make a color instance be disposed. - /// - /// 3 - 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); - } - } - - /// /// Checks if two color classes are same. /// /// A color to be compared. @@ -500,20 +454,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -527,7 +474,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private Color Add(Color rhs) diff --git a/src/Tizen.NUI/src/public/Container.cs b/src/Tizen.NUI/src/public/Container.cs index 9f21585..8266f9c 100755 --- a/src/Tizen.NUI/src/public/Container.cs +++ b/src/Tizen.NUI/src/public/Container.cs @@ -138,6 +138,5 @@ namespace Tizen.NUI } internal abstract View FindCurrentChildById(uint id); - } } // namespace Tizen.NUI diff --git a/src/Tizen.NUI/src/public/CubeTransitionEffect.cs b/src/Tizen.NUI/src/public/CubeTransitionEffect.cs index 1f5571a..1a07650 100755 --- a/src/Tizen.NUI/src/public/CubeTransitionEffect.cs +++ b/src/Tizen.NUI/src/public/CubeTransitionEffect.cs @@ -215,14 +215,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/CustomViewRegistry.cs b/src/Tizen.NUI/src/public/CustomViewRegistry.cs index 92b0d2b..cbdf7f8 100755 --- a/src/Tizen.NUI/src/public/CustomViewRegistry.cs +++ b/src/Tizen.NUI/src/public/CustomViewRegistry.cs @@ -496,8 +496,6 @@ namespace Tizen.NUI { throw new global::System.InvalidOperationException("failed to find the control to write a property to: cptr = " + refObjectPtr); } - } - } } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Degree.cs b/src/Tizen.NUI/src/public/Degree.cs index c9806a4..4f49439 100755 --- a/src/Tizen.NUI/src/public/Degree.cs +++ b/src/Tizen.NUI/src/public/Degree.cs @@ -17,32 +17,21 @@ namespace Tizen.NUI { - /// /// An angle in degrees.
/// This reduces ambiguity when using methods which accept angles in degrees or radians.
///
/// 3 - public class Degree : global::System.IDisposable + public class Degree : Disposable { - /// /// swigCMemOwn. /// /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The constructor. /// @@ -79,19 +68,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~Degree() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The value of degree. /// /// 3 @@ -110,29 +86,6 @@ namespace Tizen.NUI } } - /// - /// Dispose. - /// - /// 3 - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Degree obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; @@ -142,20 +95,13 @@ namespace Tizen.NUI /// Dispose. ///
/// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -169,9 +115,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/DirectionBias.cs b/src/Tizen.NUI/src/public/DirectionBias.cs index cd6df2e..84b29b1 100755 --- a/src/Tizen.NUI/src/public/DirectionBias.cs +++ b/src/Tizen.NUI/src/public/DirectionBias.cs @@ -39,5 +39,4 @@ namespace Tizen.NUI /// 3 DirectionBiasRight = 1 } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Extents.cs b/src/Tizen.NUI/src/public/Extents.cs index 504505c..0836bf2 100755 --- a/src/Tizen.NUI/src/public/Extents.cs +++ b/src/Tizen.NUI/src/public/Extents.cs @@ -24,7 +24,7 @@ namespace Tizen.NUI ///
/// 4 [TypeConverter(typeof(ExtentsTypeConverter))] - public class Extents : global::System.IDisposable + public class Extents : Disposable { /// @@ -33,17 +33,8 @@ namespace Tizen.NUI /// 4 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 4 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// Constructor. /// @@ -83,19 +74,6 @@ namespace Tizen.NUI } /// - /// Destructor. - /// - /// 4 - ~Extents() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The Start extent. /// /// 4 @@ -172,29 +150,6 @@ namespace Tizen.NUI } /// - /// To make a Extents instance be disposed. - /// - /// 4 - 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); - } - } - - /// /// Equality operator. /// /// The Extents to test against. @@ -244,20 +199,13 @@ namespace Tizen.NUI /// /// Extents type /// 4 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -271,9 +219,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - } - } diff --git a/src/Tizen.NUI/src/public/FilterModeType.cs b/src/Tizen.NUI/src/public/FilterModeType.cs index 6dd8490..00e16f1 100755 --- a/src/Tizen.NUI/src/public/FilterModeType.cs +++ b/src/Tizen.NUI/src/public/FilterModeType.cs @@ -64,5 +64,4 @@ namespace Tizen.NUI /// 3 LINEAR_MIPMAP_LINEAR } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/FontClient.cs b/src/Tizen.NUI/src/public/FontClient.cs index 1484ecf..231f716 100755 --- a/src/Tizen.NUI/src/public/FontClient.cs +++ b/src/Tizen.NUI/src/public/FontClient.cs @@ -393,17 +393,10 @@ namespace Tizen.NUI return ret; } - internal class GlyphBufferData : global::System.IDisposable + internal class GlyphBufferData : Disposable { protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; public GlyphBufferData() : this(Interop.FontClient.new_FontClient_GlyphBufferData(), true) { @@ -416,15 +409,6 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); } - ~GlyphBufferData() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /*public byte[] Buffer { set @@ -486,44 +470,18 @@ namespace Tizen.NUI } } - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(GlyphBufferData obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; } - protected virtual void Dispose(DisposeTypes type) + 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. @@ -537,7 +495,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } } diff --git a/src/Tizen.NUI/src/public/Geometry.cs b/src/Tizen.NUI/src/public/Geometry.cs index 7415038..1ffb8e4 100755 --- a/src/Tizen.NUI/src/public/Geometry.cs +++ b/src/Tizen.NUI/src/public/Geometry.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - /// /// Geometry is handle to an object that can be used to define a geometric elements. /// @@ -173,14 +172,6 @@ namespace Tizen.NUI 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. @@ -197,6 +188,5 @@ namespace Tizen.NUI base.Dispose(type); } - } } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Gesture.cs b/src/Tizen.NUI/src/public/Gesture.cs index cc9d1d3..b26540e 100755 --- a/src/Tizen.NUI/src/public/Gesture.cs +++ b/src/Tizen.NUI/src/public/Gesture.cs @@ -17,14 +17,13 @@ namespace Tizen.NUI { - /// /// Base structure for different gestures that an application can receive.
/// A Gesture is an event that is produced from a combination of several touch events /// in a particular order or within a certain time frame (for example, pinch).
///
/// 3 - public class Gesture : global::System.IDisposable + public class Gesture : Disposable { /// /// swigCMemOwn. @@ -32,17 +31,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The Copy constructor. /// @@ -60,19 +50,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~Gesture() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// Enumeration for type of gesture. /// /// 3 @@ -219,29 +196,6 @@ namespace Tizen.NUI } } - /// - /// Dispose. - /// - /// 3 - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Gesture obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; @@ -251,20 +205,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -278,7 +225,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/GestureDetector.cs b/src/Tizen.NUI/src/public/GestureDetector.cs index df63df2..265bff7 100755 --- a/src/Tizen.NUI/src/public/GestureDetector.cs +++ b/src/Tizen.NUI/src/public/GestureDetector.cs @@ -151,14 +151,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/GraphicsTypeConverter.cs b/src/Tizen.NUI/src/public/GraphicsTypeConverter.cs index f039b06..7dec52e 100755 --- a/src/Tizen.NUI/src/public/GraphicsTypeConverter.cs +++ b/src/Tizen.NUI/src/public/GraphicsTypeConverter.cs @@ -81,7 +81,5 @@ namespace Tizen.NUI { return value * (defaultDpi / Window.Instance.Dpi.X); } - } - } diff --git a/src/Tizen.NUI/src/public/GraphicsTypeManager.cs b/src/Tizen.NUI/src/public/GraphicsTypeManager.cs index 169a54c..e0351d2 100755 --- a/src/Tizen.NUI/src/public/GraphicsTypeManager.cs +++ b/src/Tizen.NUI/src/public/GraphicsTypeManager.cs @@ -111,5 +111,4 @@ namespace Tizen.NUI private volatile static GraphicsTypeManager _graphicsTypeManager; private GraphicsTypeConverter _typeConverter; } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Hover.cs b/src/Tizen.NUI/src/public/Hover.cs index 1865101..824f9db 100755 --- a/src/Tizen.NUI/src/public/Hover.cs +++ b/src/Tizen.NUI/src/public/Hover.cs @@ -25,7 +25,7 @@ namespace Tizen.NUI /// hovered or the points where a hover has stopped.
///
/// 3 - public class Hover : global::System.IDisposable + public class Hover : Disposable { /// /// swigCMemOwn @@ -33,17 +33,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The default constructor. /// @@ -69,19 +60,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~Hover() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The time (in ms) that the hover event occurred. /// /// 3 @@ -219,29 +197,6 @@ namespace Tizen.NUI return ret; } - /// - /// Dispose. - /// - /// 3 - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Hover obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; @@ -265,20 +220,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -292,7 +240,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/InputMethodContext.cs b/src/Tizen.NUI/src/public/InputMethodContext.cs index 3fa18cb..5d8acd2 100755 --- a/src/Tizen.NUI/src/public/InputMethodContext.cs +++ b/src/Tizen.NUI/src/public/InputMethodContext.cs @@ -761,14 +761,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/Key.cs b/src/Tizen.NUI/src/public/Key.cs index 7a3e362..7e11b26 100755 --- a/src/Tizen.NUI/src/public/Key.cs +++ b/src/Tizen.NUI/src/public/Key.cs @@ -24,7 +24,7 @@ namespace Tizen.NUI /// The key structure is used to store a key press. ///
/// 3 - public class Key : global::System.IDisposable + public class Key : Disposable { /// /// swigCMemOwn @@ -32,17 +32,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The default constructor. /// @@ -73,19 +64,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~Key() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// Enumeration for specifying the state of the key event. /// /// 3 @@ -392,29 +370,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// Checks to see if the Shift key modifier has been supplied. /// /// True if Shift modifier. @@ -467,20 +422,13 @@ namespace Tizen.NUI /// /// The dispose type. /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -494,7 +442,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } } diff --git a/src/Tizen.NUI/src/public/KeyFrames.cs b/src/Tizen.NUI/src/public/KeyFrames.cs index 1c5963e..657a931 100755 --- a/src/Tizen.NUI/src/public/KeyFrames.cs +++ b/src/Tizen.NUI/src/public/KeyFrames.cs @@ -123,13 +123,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/Layer.cs b/src/Tizen.NUI/src/public/Layer.cs index 8874abf..35c8e3b 100755 --- a/src/Tizen.NUI/src/public/Layer.cs +++ b/src/Tizen.NUI/src/public/Layer.cs @@ -22,7 +22,6 @@ using Tizen.NUI.Binding; namespace Tizen.NUI { - /// /// Layers provide a mechanism for overlaying groups of actors on top of each other. /// @@ -688,13 +687,6 @@ namespace Tizen.NUI 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. @@ -710,7 +702,6 @@ namespace Tizen.NUI } base.Dispose(type); - } private void SetBehavior(LayerBehavior behavior) diff --git a/src/Tizen.NUI/src/public/LongPressGesture.cs b/src/Tizen.NUI/src/public/LongPressGesture.cs index 60d2b6b..f497012 100755 --- a/src/Tizen.NUI/src/public/LongPressGesture.cs +++ b/src/Tizen.NUI/src/public/LongPressGesture.cs @@ -152,13 +152,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/LongPressGestureDetector.cs b/src/Tizen.NUI/src/public/LongPressGestureDetector.cs index 9752d2f..c6f7a73 100755 --- a/src/Tizen.NUI/src/public/LongPressGestureDetector.cs +++ b/src/Tizen.NUI/src/public/LongPressGestureDetector.cs @@ -224,14 +224,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/PaddingType.cs b/src/Tizen.NUI/src/public/PaddingType.cs index 5a286c7..35a324d 100755 --- a/src/Tizen.NUI/src/public/PaddingType.cs +++ b/src/Tizen.NUI/src/public/PaddingType.cs @@ -24,7 +24,7 @@ namespace Tizen.NUI /// The gesture state. ///
/// 3 - public class PaddingType : global::System.IDisposable + public class PaddingType : Disposable { /// /// swigCMemOwn @@ -32,14 +32,6 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; private global::System.Runtime.InteropServices.HandleRef swigCPtr; /// @@ -71,19 +63,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~PaddingType() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The Start value. /// /// 4 @@ -278,30 +257,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - - /// /// Equals /// /// The object should be compared. @@ -359,21 +314,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -388,8 +335,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/PanGesture.cs b/src/Tizen.NUI/src/public/PanGesture.cs index 9cd694b..84c7bb6 100755 --- a/src/Tizen.NUI/src/public/PanGesture.cs +++ b/src/Tizen.NUI/src/public/PanGesture.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - /// /// A PanGesture is emitted when the user moves one or more fingers in a particular direction.
/// A pan gesture will end in the following ways:
@@ -344,13 +343,6 @@ namespace Tizen.NUI 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. @@ -367,7 +359,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Path.cs b/src/Tizen.NUI/src/public/Path.cs index 8bb8c12..46f895d 100755 --- a/src/Tizen.NUI/src/public/Path.cs +++ b/src/Tizen.NUI/src/public/Path.cs @@ -37,7 +37,6 @@ namespace Tizen.NUI public Path() : this(Interop.Path.Path_New(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } internal Path(global::System.IntPtr cPtr, bool cMemoryOwn) : base(Interop.Path.Path_SWIGUpcast(cPtr), cMemoryOwn) @@ -45,7 +44,6 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); } - /// /// Enumeration for the Points. /// @@ -186,13 +184,6 @@ namespace Tizen.NUI 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. @@ -215,7 +206,5 @@ namespace Tizen.NUI internal static readonly int POINTS = Interop.Path.Path_Property_POINTS_get(); internal static readonly int CONTROL_POINTS = Interop.Path.Path_Property_CONTROL_POINTS_get(); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/PinchGesture.cs b/src/Tizen.NUI/src/public/PinchGesture.cs index 850c06f..36e2d9b 100755 --- a/src/Tizen.NUI/src/public/PinchGesture.cs +++ b/src/Tizen.NUI/src/public/PinchGesture.cs @@ -33,7 +33,6 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); } - /// /// The scale factor from the start of the pinch gesture till the latest pinch gesture.
/// If the user is moving their fingers away from each other, then @@ -182,13 +181,6 @@ namespace Tizen.NUI 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. @@ -205,7 +197,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/PinchGestureDetector.cs b/src/Tizen.NUI/src/public/PinchGestureDetector.cs index 384b840..87fdd11 100755 --- a/src/Tizen.NUI/src/public/PinchGestureDetector.cs +++ b/src/Tizen.NUI/src/public/PinchGestureDetector.cs @@ -33,7 +33,6 @@ namespace Tizen.NUI private DaliEventHandler _pinchGestureEventHandler; private DetectedCallbackDelegate _pinchGestureCallbackDelegate; - /// /// Creates an initialized PinchGestureDetector. /// @@ -147,19 +146,10 @@ namespace Tizen.NUI 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) @@ -186,7 +176,6 @@ namespace Tizen.NUI //Here we send all data to user event handlers. _pinchGestureEventHandler(this, e); } - } /// @@ -236,7 +225,5 @@ namespace Tizen.NUI } } } - } - } diff --git a/src/Tizen.NUI/src/public/PixelBuffer.cs b/src/Tizen.NUI/src/public/PixelBuffer.cs index b4708ad..5027838 100755 --- a/src/Tizen.NUI/src/public/PixelBuffer.cs +++ b/src/Tizen.NUI/src/public/PixelBuffer.cs @@ -278,14 +278,6 @@ namespace Tizen.NUI 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. @@ -301,7 +293,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } diff --git a/src/Tizen.NUI/src/public/PixelData.cs b/src/Tizen.NUI/src/public/PixelData.cs index b0a3c8a..13fa8ea 100755 --- a/src/Tizen.NUI/src/public/PixelData.cs +++ b/src/Tizen.NUI/src/public/PixelData.cs @@ -136,19 +136,10 @@ namespace Tizen.NUI 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) diff --git a/src/Tizen.NUI/src/public/Position.cs b/src/Tizen.NUI/src/public/Position.cs index 37e2c88..d3fe104 100755 --- a/src/Tizen.NUI/src/public/Position.cs +++ b/src/Tizen.NUI/src/public/Position.cs @@ -27,22 +27,14 @@ namespace Tizen.NUI /// /// 3 [Tizen.NUI.Binding.TypeConverter(typeof(PositionTypeConverter))] - public class Position : global::System.IDisposable + public class Position : Disposable { /// /// swigCMemOwn /// /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; /// /// The constructor. @@ -81,20 +73,6 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); } - - /// - /// Dispose. - /// - /// 3 - ~Position() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// /// ParentOrigin constants. It's 0.0. /// @@ -807,29 +785,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// Compares if rhs is equal to. /// /// The vector to compare. @@ -871,20 +826,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -898,7 +846,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } diff --git a/src/Tizen.NUI/src/public/Position2D.cs b/src/Tizen.NUI/src/public/Position2D.cs index 41cf4f0..e7c9f6f 100755 --- a/src/Tizen.NUI/src/public/Position2D.cs +++ b/src/Tizen.NUI/src/public/Position2D.cs @@ -20,29 +20,19 @@ using Tizen.NUI.Binding; namespace Tizen.NUI { - /// /// Position2D is a two-dimensional vector. /// /// 3 [Tizen.NUI.Binding.TypeConverter(typeof(Position2DTypeConverter))] - public class Position2D : global::System.IDisposable + public class Position2D : Disposable { /// /// swigCMemOwn /// /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - private Position2DChangedCallback callback = null; /// @@ -87,19 +77,6 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - /// - /// Dispose. - /// - /// 3 - ~Position2D() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - internal delegate void Position2DChangedCallback(int x, int y); /// @@ -188,29 +165,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// The addition operator. /// /// The vector to add. @@ -384,20 +338,13 @@ namespace Tizen.NUI /// /// The dispose type. /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -411,7 +358,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private Position2D Add(Position2D rhs) @@ -428,7 +375,6 @@ namespace Tizen.NUI return ret; } - private Position2D Multiply(Position2D rhs) { Position2D ret = new Position2D(Interop.Vector2.Vector2_Multiply__SWIG_0(swigCPtr, Position2D.getCPtr(rhs)), true); @@ -443,7 +389,6 @@ namespace Tizen.NUI return ret; } - private Position2D Divide(Position2D rhs) { Position2D ret = new Position2D(Interop.Vector2.Vector2_Divide__SWIG_0(swigCPtr, Position2D.getCPtr(rhs)), true); @@ -471,8 +416,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } - diff --git a/src/Tizen.NUI/src/public/Property.cs b/src/Tizen.NUI/src/public/Property.cs index 6d9c098..1ab8c26 100755 --- a/src/Tizen.NUI/src/public/Property.cs +++ b/src/Tizen.NUI/src/public/Property.cs @@ -26,24 +26,15 @@ namespace Tizen.NUI /// An array of property values. /// /// 3 - public class PropertyArray : global::System.IDisposable + public class PropertyArray : Disposable { /// /// swigCMemOwn /// /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The constructor. /// @@ -65,19 +56,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~PropertyArray() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The operator to access an element. /// /// The element index to access. No bounds checking is performed. @@ -219,29 +197,6 @@ namespace Tizen.NUI return ret; } - /// - /// Dispose. - /// - /// 3 - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PropertyArray obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; @@ -251,20 +206,13 @@ namespace Tizen.NUI /// Dispose. ///
/// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -278,7 +226,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } /// @@ -298,25 +246,16 @@ namespace Tizen.NUI /// A key type which can be either a std::string or a Property::Index. /// /// 3 - public class PropertyKey : global::System.IDisposable + public class PropertyKey : Disposable { /// /// swigCMemOwn /// /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - - /// + /// /// The constructor. /// /// The string key. @@ -343,19 +282,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~PropertyKey() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The type of key. /// /// 3 @@ -431,29 +357,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// Compares if rhs is equal to. /// /// A string key to compare against. @@ -540,20 +443,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -567,7 +463,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } @@ -575,24 +471,15 @@ namespace Tizen.NUI /// A map of property values, the key type could be string or Property::Index. ///
/// 3 - public class PropertyMap : global::System.IDisposable + public class PropertyMap : Disposable { /// /// swigCMemOwn /// /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The constructor. /// @@ -619,19 +506,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~PropertyMap() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The operator to access the element with the specified string key.
/// If an element with the key does not exist, then it is created.
///
@@ -662,29 +536,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// Retrieves the number of elements in the map. /// /// The number of elements in the map. @@ -896,20 +747,13 @@ namespace Tizen.NUI /// Dispose. ///
/// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -923,7 +767,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } @@ -931,24 +775,15 @@ namespace Tizen.NUI /// A value-type representing a property value. ///
/// 3 - public class PropertyValue : global::System.IDisposable + public class PropertyValue : Disposable { /// /// swigCMemOwn /// /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// Creates a Size2D property value. /// @@ -988,6 +823,7 @@ namespace Tizen.NUI { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } + /// /// The default constructor. /// @@ -1168,19 +1004,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~PropertyValue() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// An extension to the property value class that allows us to create a /// Property value from a C# object, for example, integer, float, or string.
///
@@ -1277,29 +1100,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// Retrieves a Size2D value. /// /// On return, a Size2D value. @@ -1603,20 +1403,13 @@ namespace Tizen.NUI /// Dispose. ///
/// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -1630,7 +1423,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } @@ -1962,24 +1755,16 @@ namespace Tizen.NUI } } - internal class Property : global::System.IDisposable + internal class Property : Disposable { /// /// swigCMemOwn /// /// 3 protected bool swigCMemOwn; - /// - /// 3 - /// A Flat to check if it is already disposed. - /// - protected bool disposed = false; private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// This constructor creates a property instance. /// @@ -2034,15 +1819,6 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr); } - ~Property() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - /// /// Gets or sets the index of the property. /// @@ -2126,44 +1902,18 @@ namespace Tizen.NUI } } - 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); - } - } - 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; } - protected virtual void Dispose(DisposeTypes type) + 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. @@ -2177,7 +1927,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/PropertyBuffer.cs b/src/Tizen.NUI/src/public/PropertyBuffer.cs index 6e6afa1..2ceb1c3 100755 --- a/src/Tizen.NUI/src/public/PropertyBuffer.cs +++ b/src/Tizen.NUI/src/public/PropertyBuffer.cs @@ -86,14 +86,6 @@ namespace Tizen.NUI 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. @@ -110,7 +102,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/PropertyCondition.cs b/src/Tizen.NUI/src/public/PropertyCondition.cs index 08ab942..a69bb78 100755 --- a/src/Tizen.NUI/src/public/PropertyCondition.cs +++ b/src/Tizen.NUI/src/public/PropertyCondition.cs @@ -50,6 +50,7 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } + /// /// Retrieves the arguments that this condition uses /// @@ -160,14 +161,6 @@ namespace Tizen.NUI 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. @@ -184,7 +177,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/PropertyNotification.cs b/src/Tizen.NUI/src/public/PropertyNotification.cs index 7636081..1f8113c 100755 --- a/src/Tizen.NUI/src/public/PropertyNotification.cs +++ b/src/Tizen.NUI/src/public/PropertyNotification.cs @@ -263,14 +263,6 @@ namespace Tizen.NUI 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. @@ -325,7 +317,5 @@ namespace Tizen.NUI } } } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/PropertyNotifySignal.cs b/src/Tizen.NUI/src/public/PropertyNotifySignal.cs index 993eb00..65f9306 100755 --- a/src/Tizen.NUI/src/public/PropertyNotifySignal.cs +++ b/src/Tizen.NUI/src/public/PropertyNotifySignal.cs @@ -22,24 +22,16 @@ namespace Tizen.NUI /// Signal connection class for PropertyNotification ///
/// 4 - public class PropertyNotifySignal : global::System.IDisposable + public class PropertyNotifySignal : Disposable { /// /// swigCMemOwn /// /// 4 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 4 - protected bool disposed = false; private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The constructor. /// @@ -56,42 +48,6 @@ namespace Tizen.NUI } /// - /// Dispose - /// - /// 3 - ~PropertyNotifySignal() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// Dispose - /// - /// 4 - 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); - } - } - - /// /// Queries whether there are any connected slots. /// /// True if there are any slots connected to the signal. @@ -164,21 +120,13 @@ namespace Tizen.NUI ///
/// The dispose type. /// 4 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -193,9 +141,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Radian.cs b/src/Tizen.NUI/src/public/Radian.cs index 546bc02..61872da 100755 --- a/src/Tizen.NUI/src/public/Radian.cs +++ b/src/Tizen.NUI/src/public/Radian.cs @@ -21,7 +21,7 @@ namespace Tizen.NUI /// An angle in radians. ///
/// 3 - public class Radian : global::System.IDisposable + public class Radian : Disposable { /// /// swigCMemOwn @@ -29,17 +29,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The default constructor, initializes to 0. /// @@ -76,19 +67,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~Radian() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The value in radians. /// /// 3 @@ -108,29 +86,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// Conversion to float. /// /// The float value of this radian. @@ -151,20 +106,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -178,7 +126,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Rectangle.cs b/src/Tizen.NUI/src/public/Rectangle.cs index e1b6269..4610e03 100755 --- a/src/Tizen.NUI/src/public/Rectangle.cs +++ b/src/Tizen.NUI/src/public/Rectangle.cs @@ -24,7 +24,7 @@ namespace Tizen.NUI ///
/// 3 [TypeConverter(typeof(RectangleTypeConverter))] - public class Rectangle : global::System.IDisposable + public class Rectangle : Disposable { /// /// swigCMemOwn @@ -32,17 +32,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The constructor. /// @@ -72,19 +63,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~Rectangle() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The x position of the rectangle. /// /// 3 @@ -306,29 +284,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// Equality operator. /// /// The object to compare with the current object. @@ -481,20 +436,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. diff --git a/src/Tizen.NUI/src/public/RelativeVector2.cs b/src/Tizen.NUI/src/public/RelativeVector2.cs index 0d1da73..74fa825 100755 --- a/src/Tizen.NUI/src/public/RelativeVector2.cs +++ b/src/Tizen.NUI/src/public/RelativeVector2.cs @@ -25,7 +25,7 @@ namespace Tizen.NUI ///
/// 3 [TypeConverter(typeof(RelativeVector2TypeConverter))] - public class RelativeVector2 : global::System.IDisposable + public class RelativeVector2 : Disposable { /// /// swigCMemOwn @@ -33,17 +33,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The constructor. /// @@ -91,19 +82,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~RelativeVector2() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The x component. /// /// 3 @@ -241,29 +219,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// The const array subscript operator overload. Should be 0, 1. /// /// The subscript index. @@ -382,20 +337,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -409,7 +357,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private RelativeVector2 Add(RelativeVector2 rhs) diff --git a/src/Tizen.NUI/src/public/RelativeVector3.cs b/src/Tizen.NUI/src/public/RelativeVector3.cs index fd03f70..6bf0d0a 100755 --- a/src/Tizen.NUI/src/public/RelativeVector3.cs +++ b/src/Tizen.NUI/src/public/RelativeVector3.cs @@ -26,7 +26,7 @@ namespace Tizen.NUI ///
/// 3 [TypeConverter(typeof(RelativeVector3TypeConverter))] - public class RelativeVector3 : global::System.IDisposable + public class RelativeVector3 : Disposable { /// /// swigCMemOwn @@ -34,17 +34,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The constructor. /// @@ -87,19 +78,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~RelativeVector3() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The x component. /// /// 3 @@ -251,29 +229,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// The const array subscript operator overload. Should be 0, 1 or 2. /// /// The subscript index. @@ -413,20 +368,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -440,7 +388,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private RelativeVector3 Add(RelativeVector3 rhs) diff --git a/src/Tizen.NUI/src/public/RelativeVector4.cs b/src/Tizen.NUI/src/public/RelativeVector4.cs index ab61882..8b3e9b9 100755 --- a/src/Tizen.NUI/src/public/RelativeVector4.cs +++ b/src/Tizen.NUI/src/public/RelativeVector4.cs @@ -25,7 +25,7 @@ namespace Tizen.NUI ///
/// 3 [TypeConverter(typeof(RelativeVector4TypeConverter))] - public class RelativeVector4 : global::System.IDisposable + public class RelativeVector4 : Disposable { /// /// swigCMemOwn @@ -33,17 +33,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The constructor. /// @@ -87,19 +78,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~RelativeVector4() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The x component. /// /// 3 @@ -270,29 +248,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// The const array subscript operator overload. Should be 0, 1 3 or 3. /// /// The subscript index. @@ -442,20 +397,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -469,7 +417,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private RelativeVector4 Add(RelativeVector4 rhs) diff --git a/src/Tizen.NUI/src/public/RelayoutContainer.cs b/src/Tizen.NUI/src/public/RelayoutContainer.cs index b8ba881..3c300f8 100755 --- a/src/Tizen.NUI/src/public/RelayoutContainer.cs +++ b/src/Tizen.NUI/src/public/RelayoutContainer.cs @@ -23,7 +23,7 @@ namespace Tizen.NUI /// An interface to encapsulate the information required for relayout. ///
/// 3 - public class RelayoutContainer : global::System.IDisposable + public class RelayoutContainer : Disposable { /// /// swigCMemOwn @@ -31,53 +31,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - - /// - /// Dispose. - /// - /// 3 - ~RelayoutContainer() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// - /// To make the RelayoutContainer instance be disposed. - /// - /// 3 - 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); - } - } - /// /// Adds relayout information to the container if it doesn't already exist. /// @@ -105,20 +60,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -132,7 +80,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } } } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Rotation.cs b/src/Tizen.NUI/src/public/Rotation.cs index e4b29ff..dd3cc19 100755 --- a/src/Tizen.NUI/src/public/Rotation.cs +++ b/src/Tizen.NUI/src/public/Rotation.cs @@ -24,7 +24,7 @@ namespace Tizen.NUI ///
/// 3 [TypeConverter(typeof(RotationTypeConverter))] - public class Rotation : global::System.IDisposable + public class Rotation : Disposable { /// /// swigCMemOwn @@ -32,18 +32,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - - /// /// The default constructor. /// @@ -65,19 +55,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - ~Rotation() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// (0.0f,0.0f,0.0f,1.0f). /// /// 3 @@ -278,29 +255,6 @@ namespace Tizen.NUI } /// - /// To make the Rotation instance be disposed. - /// - /// 3 - 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); - } - } - - /// /// Helper to check if this is an identity quaternion. /// /// True if this is identity quaternion. @@ -431,20 +385,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -458,7 +405,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private Rotation Add(Rotation other) diff --git a/src/Tizen.NUI/src/public/Sampler.cs b/src/Tizen.NUI/src/public/Sampler.cs index 45e4c3b..27a4030 100755 --- a/src/Tizen.NUI/src/public/Sampler.cs +++ b/src/Tizen.NUI/src/public/Sampler.cs @@ -32,7 +32,6 @@ namespace Tizen.NUI public Sampler() : this(Interop.Sampler.Sampler_New(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } /// @@ -93,19 +92,10 @@ namespace Tizen.NUI 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) diff --git a/src/Tizen.NUI/src/public/ScrollViewEffect.cs b/src/Tizen.NUI/src/public/ScrollViewEffect.cs index 5235d8c..6d5e51c 100755 --- a/src/Tizen.NUI/src/public/ScrollViewEffect.cs +++ b/src/Tizen.NUI/src/public/ScrollViewEffect.cs @@ -56,14 +56,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/ScrollViewPagePathEffect.cs b/src/Tizen.NUI/src/public/ScrollViewPagePathEffect.cs index f91806d..b302d2a 100755 --- a/src/Tizen.NUI/src/public/ScrollViewPagePathEffect.cs +++ b/src/Tizen.NUI/src/public/ScrollViewPagePathEffect.cs @@ -51,14 +51,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/Size.cs b/src/Tizen.NUI/src/public/Size.cs index f648567..de62cc9 100755 --- a/src/Tizen.NUI/src/public/Size.cs +++ b/src/Tizen.NUI/src/public/Size.cs @@ -26,18 +26,12 @@ namespace Tizen.NUI /// /// 5 [Tizen.NUI.Binding.TypeConverter(typeof(SizeTypeConverter))] - public class Size : global::System.IDisposable + public class Size : Disposable { /// swigCMemOwn. /// 5 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 5 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; //A Flag to check who called Dispose(). (By User or DisposeQueue) @@ -75,18 +69,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - ~Size() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The Zero constant, (0.0f, 0.0f, 0.0f). /// /// 5 @@ -262,29 +244,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 5 - 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); - } - } - - /// /// Determines whether the specified object is equal to the current object. /// /// The object to compare with the current object. @@ -338,8 +297,6 @@ namespace Tizen.NUI return ret; } - - /// /// The type cast operator, Size to Vector3. /// @@ -382,21 +339,13 @@ namespace Tizen.NUI /// Dispose. ///
/// 5 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -411,7 +360,7 @@ namespace Tizen.NUI swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private Size Add(Size rhs) diff --git a/src/Tizen.NUI/src/public/Size2D.cs b/src/Tizen.NUI/src/public/Size2D.cs index 6512742..6da1c88 100755 --- a/src/Tizen.NUI/src/public/Size2D.cs +++ b/src/Tizen.NUI/src/public/Size2D.cs @@ -24,7 +24,7 @@ namespace Tizen.NUI ///
/// 3 [Tizen.NUI.Binding.TypeConverter(typeof(Size2DTypeConverter))] - public class Size2D : global::System.IDisposable + public class Size2D : Disposable { /// /// swigCMemOwn @@ -32,17 +32,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - private Size2DChangedCallback callback = null; /// @@ -65,19 +56,6 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - /// - /// Dispose. - /// - /// 3 - ~Size2D() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - internal delegate void Size2DChangedCallback(int width, int height); /// @@ -243,29 +221,6 @@ namespace Tizen.NUI } /// - /// Dispose. - /// - /// 3 - 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); - } - } - - /// /// Determines whether the specified object is equal to the current object. /// /// The object to compare with the current object. @@ -352,20 +307,13 @@ namespace Tizen.NUI /// Dispose. /// /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -379,7 +327,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private Size2D Add(Size2D rhs) diff --git a/src/Tizen.NUI/src/public/TapGesture.cs b/src/Tizen.NUI/src/public/TapGesture.cs index e45e447..89f491a 100755 --- a/src/Tizen.NUI/src/public/TapGesture.cs +++ b/src/Tizen.NUI/src/public/TapGesture.cs @@ -178,13 +178,6 @@ namespace Tizen.NUI 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. @@ -202,5 +195,4 @@ namespace Tizen.NUI base.Dispose(type); } } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/TapGestureDetector.cs b/src/Tizen.NUI/src/public/TapGestureDetector.cs index 2f7dec3..86a0087 100755 --- a/src/Tizen.NUI/src/public/TapGestureDetector.cs +++ b/src/Tizen.NUI/src/public/TapGestureDetector.cs @@ -42,7 +42,6 @@ namespace Tizen.NUI public TapGestureDetector() : this(Interop.TapGestureDetector.TapGestureDetector_New__SWIG_0(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } /// @@ -210,14 +209,6 @@ namespace Tizen.NUI 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. @@ -305,5 +296,4 @@ namespace Tizen.NUI } } } - } diff --git a/src/Tizen.NUI/src/public/Texture.cs b/src/Tizen.NUI/src/public/Texture.cs index 76a531e..df69300 100755 --- a/src/Tizen.NUI/src/public/Texture.cs +++ b/src/Tizen.NUI/src/public/Texture.cs @@ -132,14 +132,6 @@ namespace Tizen.NUI 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. @@ -156,7 +148,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/TextureSet.cs b/src/Tizen.NUI/src/public/TextureSet.cs index 1328137..a92b909 100755 --- a/src/Tizen.NUI/src/public/TextureSet.cs +++ b/src/Tizen.NUI/src/public/TextureSet.cs @@ -35,7 +35,6 @@ namespace Tizen.NUI public TextureSet() : this(Interop.TextureSet.TextureSet_New(), true) { if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - } internal TextureSet(global::System.IntPtr cPtr, bool cMemoryOwn) : base(Interop.TextureSet.TextureSet_SWIGUpcast(cPtr), cMemoryOwn) @@ -139,14 +138,6 @@ namespace Tizen.NUI 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. @@ -164,5 +155,4 @@ namespace Tizen.NUI base.Dispose(type); } } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Timer.cs b/src/Tizen.NUI/src/public/Timer.cs index 98d9d66..5147c39 100755 --- a/src/Tizen.NUI/src/public/Timer.cs +++ b/src/Tizen.NUI/src/public/Timer.cs @@ -212,13 +212,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/Touch.cs b/src/Tizen.NUI/src/public/Touch.cs index a0c94fb..88344e5 100755 --- a/src/Tizen.NUI/src/public/Touch.cs +++ b/src/Tizen.NUI/src/public/Touch.cs @@ -252,13 +252,6 @@ namespace Tizen.NUI 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. @@ -275,7 +268,6 @@ namespace Tizen.NUI base.Dispose(type); } - } /// diff --git a/src/Tizen.NUI/src/public/TransitionData.cs b/src/Tizen.NUI/src/public/TransitionData.cs index f8588f1..14aa694 100755 --- a/src/Tizen.NUI/src/public/TransitionData.cs +++ b/src/Tizen.NUI/src/public/TransitionData.cs @@ -104,14 +104,6 @@ namespace Tizen.NUI 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. @@ -128,7 +120,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/TypeInfo.cs b/src/Tizen.NUI/src/public/TypeInfo.cs index 111f5bd..1b61798 100755 --- a/src/Tizen.NUI/src/public/TypeInfo.cs +++ b/src/Tizen.NUI/src/public/TypeInfo.cs @@ -129,14 +129,6 @@ namespace Tizen.NUI 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. @@ -153,7 +145,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/TypeRegistry.cs b/src/Tizen.NUI/src/public/TypeRegistry.cs index 310c819..8945881 100755 --- a/src/Tizen.NUI/src/public/TypeRegistry.cs +++ b/src/Tizen.NUI/src/public/TypeRegistry.cs @@ -48,14 +48,6 @@ namespace Tizen.NUI 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. @@ -155,8 +147,5 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); return ret; } - } - } - diff --git a/src/Tizen.NUI/src/public/UIComponents/Button.cs b/src/Tizen.NUI/src/public/UIComponents/Button.cs index 3ce7dce..15324be 100755 --- a/src/Tizen.NUI/src/public/UIComponents/Button.cs +++ b/src/Tizen.NUI/src/public/UIComponents/Button.cs @@ -947,14 +947,6 @@ namespace Tizen.NUI.UIComponents 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. diff --git a/src/Tizen.NUI/src/public/UIComponents/CheckBoxButton.cs b/src/Tizen.NUI/src/public/UIComponents/CheckBoxButton.cs index bb42607..c3b6356 100755 --- a/src/Tizen.NUI/src/public/UIComponents/CheckBoxButton.cs +++ b/src/Tizen.NUI/src/public/UIComponents/CheckBoxButton.cs @@ -60,13 +60,6 @@ namespace Tizen.NUI.UIComponents 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. diff --git a/src/Tizen.NUI/src/public/UIComponents/Popup.cs b/src/Tizen.NUI/src/public/UIComponents/Popup.cs index 56da2fb..1794dab 100755 --- a/src/Tizen.NUI/src/public/UIComponents/Popup.cs +++ b/src/Tizen.NUI/src/public/UIComponents/Popup.cs @@ -1270,14 +1270,6 @@ namespace Tizen.NUI.UIComponents 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. diff --git a/src/Tizen.NUI/src/public/UIComponents/ProgressBar.cs b/src/Tizen.NUI/src/public/UIComponents/ProgressBar.cs index 9e20056..ee9757b 100755 --- a/src/Tizen.NUI/src/public/UIComponents/ProgressBar.cs +++ b/src/Tizen.NUI/src/public/UIComponents/ProgressBar.cs @@ -408,14 +408,6 @@ namespace Tizen.NUI.UIComponents 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. diff --git a/src/Tizen.NUI/src/public/UIComponents/PushButton.cs b/src/Tizen.NUI/src/public/UIComponents/PushButton.cs index cdafc06..7b6ef6c 100755 --- a/src/Tizen.NUI/src/public/UIComponents/PushButton.cs +++ b/src/Tizen.NUI/src/public/UIComponents/PushButton.cs @@ -127,13 +127,6 @@ namespace Tizen.NUI.UIComponents 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. diff --git a/src/Tizen.NUI/src/public/UIComponents/RadioButton.cs b/src/Tizen.NUI/src/public/UIComponents/RadioButton.cs index 3de4fc1..5f433d7 100755 --- a/src/Tizen.NUI/src/public/UIComponents/RadioButton.cs +++ b/src/Tizen.NUI/src/public/UIComponents/RadioButton.cs @@ -75,14 +75,6 @@ namespace Tizen.NUI.UIComponents 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. diff --git a/src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs b/src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs index e1df8a9..fc848e7 100755 --- a/src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs +++ b/src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs @@ -628,13 +628,6 @@ namespace Tizen.NUI.UIComponents 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. diff --git a/src/Tizen.NUI/src/public/UIComponents/Slider.cs b/src/Tizen.NUI/src/public/UIComponents/Slider.cs index 767f870..b8785db 100755 --- a/src/Tizen.NUI/src/public/UIComponents/Slider.cs +++ b/src/Tizen.NUI/src/public/UIComponents/Slider.cs @@ -732,14 +732,6 @@ namespace Tizen.NUI.UIComponents 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. diff --git a/src/Tizen.NUI/src/public/Vector2.cs b/src/Tizen.NUI/src/public/Vector2.cs index 20e18d9..7c7b8c8 100755 --- a/src/Tizen.NUI/src/public/Vector2.cs +++ b/src/Tizen.NUI/src/public/Vector2.cs @@ -25,7 +25,7 @@ namespace Tizen.NUI /// /// 3 [TypeConverter(typeof(Vector2TypeConverter))] - public class Vector2 : global::System.IDisposable + public class Vector2 : Disposable { /// /// swigCMemOwn. @@ -33,14 +33,7 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; /// /// The default constructor initializes the vector to 0. @@ -99,19 +92,6 @@ namespace Tizen.NUI } /// - /// Destructor. - /// - /// 3 - ~Vector2() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// (1.0f,1.0f). /// /// 3 @@ -448,29 +428,6 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - /// - /// Dispose. - /// - /// 3 - 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); - } - } - internal static Vector2 GetVector2FromPtr(global::System.IntPtr cPtr) { Vector2 ret = new Vector2(cPtr, false); @@ -496,20 +453,13 @@ namespace Tizen.NUI /// /// The dispose type /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -523,7 +473,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private Vector2 Add(Vector2 rhs) diff --git a/src/Tizen.NUI/src/public/Vector3.cs b/src/Tizen.NUI/src/public/Vector3.cs index c27670c..1e5cb08 100755 --- a/src/Tizen.NUI/src/public/Vector3.cs +++ b/src/Tizen.NUI/src/public/Vector3.cs @@ -25,21 +25,14 @@ namespace Tizen.NUI /// /// 3 [TypeConverter(typeof(Vector3TypeConverter))] - public class Vector3 : global::System.IDisposable + public class Vector3 : Disposable { /// /// swigCMemOwn. /// /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; /// /// The constructor. @@ -99,19 +92,6 @@ namespace Tizen.NUI } /// - /// Destructor. - /// - /// 3 - ~Vector3() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// (1.0f,1.0f,1.0f). /// /// 3 @@ -597,29 +577,6 @@ namespace Tizen.NUI return ret; } - /// - /// Dispose. - /// - /// 3 - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Vector3 obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; @@ -645,20 +602,13 @@ namespace Tizen.NUI /// /// The dispose type /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -672,7 +622,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private Vector3 Add(Vector3 rhs) diff --git a/src/Tizen.NUI/src/public/Vector4.cs b/src/Tizen.NUI/src/public/Vector4.cs index 96c8948..05706ce 100755 --- a/src/Tizen.NUI/src/public/Vector4.cs +++ b/src/Tizen.NUI/src/public/Vector4.cs @@ -25,7 +25,7 @@ namespace Tizen.NUI /// /// 3 [TypeConverter(typeof(Vector4TypeConverter))] - public class Vector4 : global::System.IDisposable + public class Vector4 : Disposable { /// /// swigCMemOwn. @@ -33,15 +33,7 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; /// /// The default constructor initializes the vector to 0. @@ -102,19 +94,6 @@ namespace Tizen.NUI } /// - /// Destructor. - /// - /// 3 - ~Vector4() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// (1.0f,1.0f,1.0f,1.0f). /// /// 3 @@ -590,29 +569,6 @@ namespace Tizen.NUI if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); } - /// - /// Dispose. - /// - /// 3 - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Vector4 obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; @@ -666,20 +622,13 @@ namespace Tizen.NUI /// /// The dispose type /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -693,7 +642,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } private Vector4 Add(Vector4 rhs) diff --git a/src/Tizen.NUI/src/public/ViewWrapper.cs b/src/Tizen.NUI/src/public/ViewWrapper.cs index 9d61088..794d801 100755 --- a/src/Tizen.NUI/src/public/ViewWrapper.cs +++ b/src/Tizen.NUI/src/public/ViewWrapper.cs @@ -56,14 +56,6 @@ namespace Tizen.NUI 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. diff --git a/src/Tizen.NUI/src/public/VisualBase.cs b/src/Tizen.NUI/src/public/VisualBase.cs index f53f63f..b792be0 100755 --- a/src/Tizen.NUI/src/public/VisualBase.cs +++ b/src/Tizen.NUI/src/public/VisualBase.cs @@ -196,13 +196,6 @@ namespace Tizen.NUI 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. @@ -219,7 +212,5 @@ namespace Tizen.NUI base.Dispose(type); } - } - } diff --git a/src/Tizen.NUI/src/public/WatchTime.cs b/src/Tizen.NUI/src/public/WatchTime.cs index 6ae6c72..c157b59 100755 --- a/src/Tizen.NUI/src/public/WatchTime.cs +++ b/src/Tizen.NUI/src/public/WatchTime.cs @@ -24,7 +24,7 @@ namespace Tizen.NUI /// on receiving timeTick signal. /// /// 4 - public class WatchTime : global::System.IDisposable + public class WatchTime : Disposable { /// /// swigCMemOwn. @@ -32,15 +32,7 @@ namespace Tizen.NUI /// 4 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 4 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; /// /// Constructor. @@ -58,18 +50,6 @@ namespace Tizen.NUI } /// - /// Distructor. - /// - ~WatchTime() - { - if (!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// Get the current hour. /// /// The return value is always positive.The WatchTime needs to be initialized. @@ -217,29 +197,6 @@ namespace Tizen.NUI } } - /// - /// To make watch time instance be disposed. - /// - /// 4 - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(WatchTime obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; @@ -348,21 +305,13 @@ namespace Tizen.NUI /// /// DisposeTypes /// 4 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -379,7 +328,5 @@ namespace Tizen.NUI disposed = true; } - } - } diff --git a/src/Tizen.NUI/src/public/Wheel.cs b/src/Tizen.NUI/src/public/Wheel.cs index 2165580..fd666a5 100755 --- a/src/Tizen.NUI/src/public/Wheel.cs +++ b/src/Tizen.NUI/src/public/Wheel.cs @@ -17,7 +17,6 @@ namespace Tizen.NUI { - /// /// The wheel event structure is used to store a wheel rolling, it facilitates processing of the wheel rolling and passing to other libraries like Toolkit.
/// There is a key modifier which relates to keys like Alt, Shift, and Ctrl functions are supplied to check if they have been pressed when the wheel is being rolled.
@@ -25,7 +24,7 @@ namespace Tizen.NUI /// The mouse wheel event can be sent to the specific actor but the custom wheel event will be sent to the window.
///
/// 3 - public class Wheel : global::System.IDisposable + public class Wheel : Disposable { /// /// swigCMemOwn. @@ -33,17 +32,8 @@ namespace Tizen.NUI /// 3 protected bool swigCMemOwn; - /// - /// A Flat to check if it is already disposed. - /// - /// 3 - protected bool disposed = false; - private global::System.Runtime.InteropServices.HandleRef swigCPtr; - //A Flag to check who called Dispose(). (By User or DisposeQueue) - private bool isDisposeQueued = false; - /// /// The default constructor. /// @@ -75,19 +65,6 @@ namespace Tizen.NUI } /// - /// Destructor. - /// - /// 3 - ~Wheel() - { - if(!isDisposeQueued) - { - isDisposeQueued = true; - DisposeQueue.Instance.Add(this); - } - } - - /// /// The type of the wheel event. /// /// 3 @@ -306,29 +283,6 @@ namespace Tizen.NUI return ret; } - /// - /// Dispose. - /// - /// 3 - 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); - } - } - internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Wheel obj) { return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr; @@ -346,20 +300,13 @@ namespace Tizen.NUI /// /// The type dispose, it could be from user, or called by DisposeQueue. /// 3 - protected virtual void Dispose(DisposeTypes type) + 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. @@ -373,9 +320,7 @@ namespace Tizen.NUI } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); } - disposed = true; + base.Dispose(type); } - } - } \ No newline at end of file diff --git a/src/Tizen.NUI/src/public/Widget.cs b/src/Tizen.NUI/src/public/Widget.cs index 43130bb..2043943 100755 --- a/src/Tizen.NUI/src/public/Widget.cs +++ b/src/Tizen.NUI/src/public/Widget.cs @@ -166,13 +166,6 @@ namespace Tizen.NUI return; } - if (type == DisposeTypes.Explicit) - { - //Called by User - //Release your own managed resources here. - //You should release all of your own disposable objects here. - } - if (swigCPtr.Handle != global::System.IntPtr.Zero) { if (swigCMemOwn) diff --git a/src/Tizen.NUI/src/public/WidgetView.cs b/src/Tizen.NUI/src/public/WidgetView.cs index 4c42e7b..e40e8ef 100755 --- a/src/Tizen.NUI/src/public/WidgetView.cs +++ b/src/Tizen.NUI/src/public/WidgetView.cs @@ -581,14 +581,6 @@ namespace Tizen.NUI 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. @@ -635,7 +627,6 @@ namespace Tizen.NUI base.Dispose(type); } - // Callback for WidgetView WidgetAdded signal private void OnWidgetAdded(IntPtr data) { diff --git a/src/Tizen.NUI/src/public/WidgetViewManager.cs b/src/Tizen.NUI/src/public/WidgetViewManager.cs index 732f5eb..8fbf4fb 100755 --- a/src/Tizen.NUI/src/public/WidgetViewManager.cs +++ b/src/Tizen.NUI/src/public/WidgetViewManager.cs @@ -27,7 +27,6 @@ namespace Tizen.NUI { - /// /// WidgetViewManager manages addition of WidgetView controls. /// This class provides the functionality of adding the widget views and controlling the widgets. @@ -102,13 +101,6 @@ namespace Tizen.NUI 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. @@ -123,7 +115,5 @@ namespace Tizen.NUI } base.Dispose(type); } - } - } \ No newline at end of file -- 2.7.4