diff options
author | Igor Nazarov <i.nazarov@samsung.com> | 2017-06-22 20:27:47 +0300 |
---|---|---|
committer | Igor Nazarov <i.nazarov@samsung.com> | 2017-06-22 20:32:51 +0300 |
commit | 2178780e8e1f80e0c8efbc5cc84ee2fe4a792dfa (patch) | |
tree | e0ebbd7e878809ca906b1475a1d7889f27602650 | |
parent | c77c504f6cf095f092dde0b523d418a8b8ff05dd (diff) | |
download | gallery-2178780e8e1f80e0c8efbc5cc84ee2fe4a792dfa.tar.gz gallery-2178780e8e1f80e0c8efbc5cc84ee2fe4a792dfa.tar.bz2 gallery-2178780e8e1f80e0c8efbc5cc84ee2fe4a792dfa.zip |
[Gallery] Code refactoring
- ucl::RefCountAware::m_rc made private. Added public functions instead;
- Widget casting functions renamed in "ucl/gui/helpers.h";
- Fixed type mismatch for getUseCount() method;
- Other changes.
Change-Id: I9253860d333bfc111a8de0d4c0f28227593c1c9e
-rw-r--r-- | inc/gallery/presenters/Dialog.h | 2 | ||||
-rw-r--r-- | inc/gallery/presenters/Dialog.hpp | 2 | ||||
-rw-r--r-- | inc/gallery/presenters/Page.h | 1 | ||||
-rw-r--r-- | inc/gallery/presenters/ProcessingPresenter.h | 1 | ||||
-rw-r--r-- | src/presenters/Dialog.cpp | 2 | ||||
-rw-r--r-- | src/presenters/Page.cpp | 4 | ||||
-rw-r--r-- | src/presenters/ProcessingPresenter.cpp | 6 | ||||
-rw-r--r-- | ucl/inc/ucl/gui/Genlist.h | 16 | ||||
-rw-r--r-- | ucl/inc/ucl/gui/Genlist.hpp | 12 | ||||
-rw-r--r-- | ucl/inc/ucl/gui/Widget.h | 10 | ||||
-rw-r--r-- | ucl/inc/ucl/gui/helpers.h | 32 | ||||
-rw-r--r-- | ucl/inc/ucl/gui/types.h | 1 | ||||
-rw-r--r-- | ucl/inc/ucl/misc/RefCountAware.h | 4 | ||||
-rw-r--r-- | ucl/inc/ucl/misc/RefCountAware.hpp | 18 | ||||
-rw-r--r-- | ucl/inc/ucl/util/memory/BaseRef.h | 2 | ||||
-rw-r--r-- | ucl/inc/ucl/util/memory/BaseRef.hpp | 2 | ||||
-rw-r--r-- | ucl/inc/ucl/util/memory/IRefCountObj.h | 2 | ||||
-rw-r--r-- | ucl/inc/ucl/util/memory/RefCountObj.h | 2 | ||||
-rw-r--r-- | ucl/inc/ucl/util/memory/RefCountObj.hpp | 2 | ||||
-rw-r--r-- | ucl/src/gui/ElmWidget.cpp | 2 | ||||
-rw-r--r-- | ucl/src/gui/NaviItem.cpp | 4 | ||||
-rw-r--r-- | ucl/src/gui/Widget.cpp | 26 | ||||
-rw-r--r-- | ucl/src/mvp/GuiPresenter.cpp | 12 |
23 files changed, 91 insertions, 74 deletions
diff --git a/inc/gallery/presenters/Dialog.h b/inc/gallery/presenters/Dialog.h index f820c07..7c26010 100644 --- a/inc/gallery/presenters/Dialog.h +++ b/inc/gallery/presenters/Dialog.h @@ -60,6 +60,8 @@ namespace gallery { protected: ucl::StyledWidgetSRef m_popup; + private: + DialogSRef m_selfRef; bool m_isDismissed; }; } diff --git a/inc/gallery/presenters/Dialog.hpp b/inc/gallery/presenters/Dialog.hpp index ed2c8f7..5bd8ecb 100644 --- a/inc/gallery/presenters/Dialog.hpp +++ b/inc/gallery/presenters/Dialog.hpp @@ -30,7 +30,7 @@ namespace gallery { UCL_FAIL_RETURN(onPrepare(), "onPrepare() failed!"); - m_rc->ref(); + m_selfRef = asShared(*this); return ucl::RES_OK; } diff --git a/inc/gallery/presenters/Page.h b/inc/gallery/presenters/Page.h index d8132dc..b98569c 100644 --- a/inc/gallery/presenters/Page.h +++ b/inc/gallery/presenters/Page.h @@ -80,6 +80,7 @@ namespace gallery { const ucl::NaviframeSRef m_navi; const ExitRequestHandler m_onExitRequest; ucl::NaviItem m_item; + PageSRef m_selfRef; }; // Non-member functions // diff --git a/inc/gallery/presenters/ProcessingPresenter.h b/inc/gallery/presenters/ProcessingPresenter.h index 1276093..ff0477a 100644 --- a/inc/gallery/presenters/ProcessingPresenter.h +++ b/inc/gallery/presenters/ProcessingPresenter.h @@ -100,6 +100,7 @@ namespace gallery { DismissHandler m_dismissHandler; Ecore_Timer *m_timer; State m_state; + ProcessingPresenterSRef m_selfRef; bool m_mayComplete; bool m_isComplete; bool m_isDismissed; diff --git a/src/presenters/Dialog.cpp b/src/presenters/Dialog.cpp index 826b9fa..33d415c 100644 --- a/src/presenters/Dialog.cpp +++ b/src/presenters/Dialog.cpp @@ -70,7 +70,7 @@ namespace gallery { deactivateBy(m_popup.get()); m_popup.reset(); - m_rc->unref(); + m_selfRef.reset(); broadcastActivate(); } diff --git a/src/presenters/Page.cpp b/src/presenters/Page.cpp index ae3f71e..de4b8eb 100644 --- a/src/presenters/Page.cpp +++ b/src/presenters/Page.cpp @@ -73,7 +73,7 @@ namespace gallery { m_item.setData(this); m_item.setDelCallback(CALLBACK_A(Page::onItemDel)); - m_rc->ref(); + m_selfRef = asShared(*this); if (!m_navi->isInTransition() && isAtTop()) { dispatchTopPageChanged(); @@ -95,7 +95,7 @@ namespace gallery { void Page::onItemDel(Evas_Object *obj, void *eventInfo) { m_item = nullptr; - m_rc->unref(); + m_selfRef.reset(); } void Page::exit() diff --git a/src/presenters/ProcessingPresenter.cpp b/src/presenters/ProcessingPresenter.cpp index 7238837..d3c71e5 100644 --- a/src/presenters/ProcessingPresenter.cpp +++ b/src/presenters/ProcessingPresenter.cpp @@ -276,9 +276,7 @@ namespace gallery { deactivateBy(m_popup.get()); broadcastActivate(); m_popup.reset(); - if (m_isComplete) { - m_rc->unref(); - } + m_selfRef.reset(); } } @@ -354,7 +352,7 @@ namespace gallery { FAIL_LOG(createIcon(), "createIcon() failed!"); } - m_rc->ref(); + m_selfRef = asShared(*this); tryShowPopup(); } diff --git a/ucl/inc/ucl/gui/Genlist.h b/ucl/inc/ucl/gui/Genlist.h index ea2e660..ebbb43e 100644 --- a/ucl/inc/ucl/gui/Genlist.h +++ b/ucl/inc/ucl/gui/Genlist.h @@ -65,25 +65,25 @@ namespace ucl { GenlistItem append(const Elm_Genlist_Item_Class *itc, const void *data, SmartCbHandler onSelect = nullptr, - GenlistItem parent = nullptr, - GenlistItem::Type type = GenlistItem::Type::SIMPLE); + GenlistItem::Type type = GenlistItem::Type::SIMPLE, + GenlistItem parent = nullptr); GenlistItem prepend(const Elm_Genlist_Item_Class *itc, const void *data, SmartCbHandler onSelect = nullptr, - GenlistItem parent = nullptr, - GenlistItem::Type type = GenlistItem::Type::SIMPLE); + GenlistItem::Type type = GenlistItem::Type::SIMPLE, + GenlistItem parent = nullptr); GenlistItem insertAfter(GenlistItem after, const Elm_Genlist_Item_Class *itc, const void *data, SmartCbHandler onSelect = nullptr, - GenlistItem parent = nullptr, - GenlistItem::Type type = GenlistItem::Type::SIMPLE); + GenlistItem::Type type = GenlistItem::Type::SIMPLE, + GenlistItem parent = nullptr); GenlistItem insertBefore(GenlistItem before, const Elm_Genlist_Item_Class *itc, const void *data, SmartCbHandler onSelect = nullptr, - GenlistItem parent = nullptr, - GenlistItem::Type type = GenlistItem::Type::SIMPLE); + GenlistItem::Type type = GenlistItem::Type::SIMPLE, + GenlistItem parent = nullptr); }; } diff --git a/ucl/inc/ucl/gui/Genlist.hpp b/ucl/inc/ucl/gui/Genlist.hpp index 83eed72..d3cfed0 100644 --- a/ucl/inc/ucl/gui/Genlist.hpp +++ b/ucl/inc/ucl/gui/Genlist.hpp @@ -90,7 +90,7 @@ namespace ucl { inline GenlistItem Genlist::append(const Elm_Genlist_Item_Class *const itc, const void *const data, const SmartCbHandler onSelect, - const GenlistItem parent, const GenlistItem::Type type) + const GenlistItem::Type type, const GenlistItem parent) { return GenlistItem(elm_genlist_item_append( getEo(), itc, data, parent, @@ -100,7 +100,7 @@ namespace ucl { inline GenlistItem Genlist::prepend(const Elm_Genlist_Item_Class *const itc, const void *const data, SmartCbHandler onSelect, - const GenlistItem parent, const GenlistItem::Type type) + const GenlistItem::Type type, const GenlistItem parent) { return GenlistItem(elm_genlist_item_prepend( getEo(), itc, data, parent, @@ -110,8 +110,8 @@ namespace ucl { inline GenlistItem Genlist::insertAfter(const GenlistItem after, const Elm_Genlist_Item_Class *const itc, const void *const data, - const SmartCbHandler onSelect, const GenlistItem parent, - const GenlistItem::Type type) + const SmartCbHandler onSelect, const GenlistItem::Type type, + const GenlistItem parent) { return GenlistItem(elm_genlist_item_insert_after( getEo(), itc, data, parent, after, @@ -121,8 +121,8 @@ namespace ucl { inline GenlistItem Genlist::insertBefore(const GenlistItem before, const Elm_Genlist_Item_Class *itc, const void *data, - const SmartCbHandler onSelect, const GenlistItem parent, - const GenlistItem::Type type) + const SmartCbHandler onSelect, const GenlistItem::Type type, + const GenlistItem parent) { return GenlistItem(elm_genlist_item_insert_before( getEo(), itc, data, parent, before, diff --git a/ucl/inc/ucl/gui/Widget.h b/ucl/inc/ucl/gui/Widget.h index 2048a7d..e60c5ec 100644 --- a/ucl/inc/ucl/gui/Widget.h +++ b/ucl/inc/ucl/gui/Widget.h @@ -135,11 +135,11 @@ namespace ucl { private: Evas_Object *m_eo; EventProxies m_eventProxies; - bool m_isOwner: 1; - bool m_isBoundToEo: 1; - bool m_isEoRefKept: 1; - bool m_isSelfRefKept: 1; - bool m_isSelfRefUnique: 1; + WidgetSRef m_selfRef; + bool m_isOwner; + bool m_isBoundToEo; + bool m_isEoRefKept; + bool m_isSelfRefUnique; }; // Non-member functions // diff --git a/ucl/inc/ucl/gui/helpers.h b/ucl/inc/ucl/gui/helpers.h index f598c17..d42eccb 100644 --- a/ucl/inc/ucl/gui/helpers.h +++ b/ucl/inc/ucl/gui/helpers.h @@ -29,59 +29,59 @@ namespace ucl { // Widget casting functions from Evas_Object // template <class WIDGET_TYPE> - inline auto staticCast(Evas_Object *eo) -> + inline auto staticWidgetCast(Evas_Object *eo) -> decltype(static_cast<WIDGET_TYPE *>(asWidget(eo))) { return static_cast<WIDGET_TYPE *>(asWidget(eo)); } template <class WIDGET_TYPE> - inline auto staticCast(const Evas_Object *eo) -> + inline auto staticWidgetCast(const Evas_Object *eo) -> decltype(static_cast<WIDGET_TYPE *>(asWidget(eo))) { return static_cast<WIDGET_TYPE *>(asWidget(eo)); } template <class WIDGET_TYPE> - inline auto dynamicCast(Evas_Object *eo) -> + inline auto dynamicWidgetCast(Evas_Object *eo) -> decltype(dynamic_cast<WIDGET_TYPE *>(asWidget(eo))) { return dynamic_cast<WIDGET_TYPE *>(asWidget(eo)); } template <class WIDGET_TYPE> - inline auto dynamicCast(const Evas_Object *eo) -> + inline auto dynamicWidgetCast(const Evas_Object *eo) -> decltype(dynamic_cast<WIDGET_TYPE *>(asWidget(eo))) { return dynamic_cast<WIDGET_TYPE *>(asWidget(eo)); } template <class WIDGET_TYPE> - inline auto staticRefCast(Evas_Object *eo) -> - decltype(asShared(staticCast<WIDGET_TYPE>(eo))) + inline auto staticWidgetRefCast(Evas_Object *eo) -> + decltype(asShared(staticWidgetCast<WIDGET_TYPE>(eo))) { - return asShared(staticCast<WIDGET_TYPE>(eo)); + return asShared(staticWidgetCast<WIDGET_TYPE>(eo)); } template <class WIDGET_TYPE> - inline auto staticRefCast(const Evas_Object *eo) -> - decltype(asShared(staticCast<WIDGET_TYPE>(eo))) + inline auto staticWidgetRefCast(const Evas_Object *eo) -> + decltype(asShared(staticWidgetCast<WIDGET_TYPE>(eo))) { - return asShared(staticCast<WIDGET_TYPE>(eo)); + return asShared(staticWidgetCast<WIDGET_TYPE>(eo)); } template <class WIDGET_TYPE> - inline auto dynamicRefCast(Evas_Object *eo) -> - decltype(asShared(dynamicCast<WIDGET_TYPE>(eo))) + inline auto dynamicWidgetRefCast(Evas_Object *eo) -> + decltype(asShared(dynamicWidgetCast<WIDGET_TYPE>(eo))) { - return asShared(dynamicCast<WIDGET_TYPE>(eo)); + return asShared(dynamicWidgetCast<WIDGET_TYPE>(eo)); } template <class WIDGET_TYPE> - inline auto dynamicRefCast(const Evas_Object *eo) -> - decltype(asShared(dynamicCast<WIDGET_TYPE>(eo))) + inline auto dynamicWidgetRefCast(const Evas_Object *eo) -> + decltype(asShared(dynamicWidgetCast<WIDGET_TYPE>(eo))) { - return asShared(dynamicCast<WIDGET_TYPE>(eo)); + return asShared(dynamicWidgetCast<WIDGET_TYPE>(eo)); } } diff --git a/ucl/inc/ucl/gui/types.h b/ucl/inc/ucl/gui/types.h index 4063b33..6d43d76 100644 --- a/ucl/inc/ucl/gui/types.h +++ b/ucl/inc/ucl/gui/types.h @@ -26,6 +26,7 @@ #include "ucl/misc/Aspect.h" #include "ucl/misc/TString.h" +#include "ucl/misc/ConstCString.h" #include "ucl/misc/Variant.h" namespace ucl { diff --git a/ucl/inc/ucl/misc/RefCountAware.h b/ucl/inc/ucl/misc/RefCountAware.h index e75ecb9..6ea5ee9 100644 --- a/ucl/inc/ucl/misc/RefCountAware.h +++ b/ucl/inc/ucl/misc/RefCountAware.h @@ -27,6 +27,8 @@ namespace ucl { class RefCountAware : public Polymorphic { public: bool isShared() const; + UInt getUseCount() const; + const void *getObjPtr() const; template <class T> SharedRef<T> asSharedThis(T *thisAlias) const; @@ -43,7 +45,7 @@ namespace ucl { // Signal to RefCountObj<T, C> to pass IRefCountObj to constructor enum { _IS_REF_COUNT_AWARE }; - protected: + private: IRefCountObj *const m_rc; }; diff --git a/ucl/inc/ucl/misc/RefCountAware.hpp b/ucl/inc/ucl/misc/RefCountAware.hpp index 3906d0e..8fb3812 100644 --- a/ucl/inc/ucl/misc/RefCountAware.hpp +++ b/ucl/inc/ucl/misc/RefCountAware.hpp @@ -28,6 +28,24 @@ namespace ucl { return !!m_rc; } + inline UInt RefCountAware::getUseCount() const + { + if (!isShared()) { + UCL_ELOG("NOT SHARED: %s", typeid(*this).name()); + return 0; + } + return m_rc->getUseCount(); + } + + inline const void *RefCountAware::getObjPtr() const + { + if (!isShared()) { + UCL_ELOG("NOT SHARED: %s", typeid(*this).name()); + return nullptr; + } + return m_rc->getObjPtr(); + } + template <class T> inline SharedRef<T> RefCountAware::asSharedThis(T *const thisAlias) const { diff --git a/ucl/inc/ucl/util/memory/BaseRef.h b/ucl/inc/ucl/util/memory/BaseRef.h index f82a2c9..8146eae 100644 --- a/ucl/inc/ucl/util/memory/BaseRef.h +++ b/ucl/inc/ucl/util/memory/BaseRef.h @@ -34,7 +34,7 @@ namespace ucl { friend class WeakRef; public: - int getUseCount() const noexcept; + UInt getUseCount() const noexcept; protected: constexpr BaseRef() noexcept; diff --git a/ucl/inc/ucl/util/memory/BaseRef.hpp b/ucl/inc/ucl/util/memory/BaseRef.hpp index adde1c9..312c38e 100644 --- a/ucl/inc/ucl/util/memory/BaseRef.hpp +++ b/ucl/inc/ucl/util/memory/BaseRef.hpp @@ -51,7 +51,7 @@ namespace ucl { } template <class T> - inline int BaseRef<T>::getUseCount() const noexcept + inline UInt BaseRef<T>::getUseCount() const noexcept { return (m_rc ? m_rc->getUseCount() : 0); } diff --git a/ucl/inc/ucl/util/memory/IRefCountObj.h b/ucl/inc/ucl/util/memory/IRefCountObj.h index c2397d4..69d6a1c 100644 --- a/ucl/inc/ucl/util/memory/IRefCountObj.h +++ b/ucl/inc/ucl/util/memory/IRefCountObj.h @@ -28,7 +28,7 @@ namespace ucl { virtual bool refNz() noexcept = 0; virtual void refWeak() noexcept = 0; virtual void unrefWeak() noexcept = 0; - virtual unsigned getUseCount() const noexcept = 0; + virtual UInt getUseCount() const noexcept = 0; virtual const void *getObjPtr() const noexcept = 0; protected: virtual ~IRefCountObj() = default; diff --git a/ucl/inc/ucl/util/memory/RefCountObj.h b/ucl/inc/ucl/util/memory/RefCountObj.h index 9832ff6..7237aa4 100644 --- a/ucl/inc/ucl/util/memory/RefCountObj.h +++ b/ucl/inc/ucl/util/memory/RefCountObj.h @@ -37,7 +37,7 @@ namespace ucl { virtual bool refNz() noexcept final override; virtual void refWeak() noexcept final override; virtual void unrefWeak() noexcept final override; - virtual unsigned getUseCount() const noexcept final override; + virtual UInt getUseCount() const noexcept final override; virtual const void *getObjPtr() const noexcept final override; private: diff --git a/ucl/inc/ucl/util/memory/RefCountObj.hpp b/ucl/inc/ucl/util/memory/RefCountObj.hpp index d3b4e97..8a2c065 100644 --- a/ucl/inc/ucl/util/memory/RefCountObj.hpp +++ b/ucl/inc/ucl/util/memory/RefCountObj.hpp @@ -79,7 +79,7 @@ namespace ucl { } template <class T, class C> - inline unsigned RefCountObj<T, C>::getUseCount() const noexcept + inline UInt RefCountObj<T, C>::getUseCount() const noexcept { return m_useCounter.get(); } diff --git a/ucl/src/gui/ElmWidget.cpp b/ucl/src/gui/ElmWidget.cpp index 7c39f81..b7d227e 100644 --- a/ucl/src/gui/ElmWidget.cpp +++ b/ucl/src/gui/ElmWidget.cpp @@ -70,6 +70,6 @@ namespace ucl { Window *ElmWidget::getWindow() const { - return dynamicCast<Window>(getTopWidget()); + return dynamicWidgetCast<Window>(getTopWidget()); } } diff --git a/ucl/src/gui/NaviItem.cpp b/ucl/src/gui/NaviItem.cpp index dd212bf..02f5da2 100644 --- a/ucl/src/gui/NaviItem.cpp +++ b/ucl/src/gui/NaviItem.cpp @@ -23,7 +23,7 @@ namespace ucl { void NaviItem::popTo() const { - const auto navi = dynamicCast<Naviframe>(getWidget()); + const auto navi = dynamicWidgetCast<Naviframe>(getWidget()); const bool needStartTransition = (navi && (navi->getTopItem() != *this)); @@ -36,7 +36,7 @@ namespace ucl { void NaviItem::promote() const { - const auto navi = dynamicCast<Naviframe>(getWidget()); + const auto navi = dynamicWidgetCast<Naviframe>(getWidget()); const bool needStartTransition = (navi && (navi->getTopItem() != *this)); diff --git a/ucl/src/gui/Widget.cpp b/ucl/src/gui/Widget.cpp index d2c0dd6..096c6e1 100644 --- a/ucl/src/gui/Widget.cpp +++ b/ucl/src/gui/Widget.cpp @@ -117,12 +117,11 @@ namespace ucl { m_isOwner(isOwner), m_isBoundToEo(false), m_isEoRefKept(false), - m_isSelfRefKept(false), m_isSelfRefUnique(false) { UCL_ASSERT(m_eo, "m_eo is NULL!"); - if (m_rc) { + if (isShared()) { evas_object_event_callback_priority_add(m_eo, EVAS_CALLBACK_DEL, EO_CALLBACK_PRIORITY_AFTER, CALLBACK_A(Widget::onEoDel), this); @@ -139,7 +138,7 @@ namespace ucl { unbindFromEo(); } - if (m_rc) { + if (isShared()) { evas_object_event_callback_del_full(m_eo, EVAS_CALLBACK_DEL, CALLBACK_A(Widget::onEoDel), this); } @@ -177,7 +176,7 @@ namespace ucl { { updateEoRef(); - if (m_rc) { + if (isShared()) { updateSelfRef(); } } @@ -202,14 +201,10 @@ namespace ucl { void Widget::updateSelfRef() { - if (needKeepSelfRef()) { - if (!m_isSelfRefKept) { - m_isSelfRefKept = true; - m_rc->ref(); - } - } else if (m_isSelfRefKept) { - m_isSelfRefKept = false; - m_rc->unref(); + if (!needKeepSelfRef()) { + m_selfRef.reset(); + } else if (!m_selfRef) { + m_selfRef = asShared(*this); } } @@ -228,8 +223,8 @@ namespace ucl { void Widget::onEoDel(Evas *e, Evas_Object *obj, void *event_info) { - if (!m_isSelfRefKept) { - FLOG("UNEXPECTED! m_isSelfRefKept: %d;", m_isSelfRefKept); + if (!m_selfRef) { + FLOG("UNEXPECTED! m_selfRef is NULL!"); m_eo = nullptr; return; } @@ -239,8 +234,7 @@ namespace ucl { m_isOwner, m_isEoRefKept, m_isSelfRefUnique); m_eo = nullptr; } - m_isSelfRefKept = false; - m_rc->unref(); + m_selfRef.reset(); } void Widget::onUniqueChanged(bool isUnique) diff --git a/ucl/src/mvp/GuiPresenter.cpp b/ucl/src/mvp/GuiPresenter.cpp index e7d7bd9..e23bc02 100644 --- a/ucl/src/mvp/GuiPresenter.cpp +++ b/ucl/src/mvp/GuiPresenter.cpp @@ -60,7 +60,7 @@ namespace ucl { } if (flags & PF_ADD_SELF_EXCEPT) { - addDeactivatorException(m_rc->getObjPtr()); + addDeactivatorException(getObjPtr()); } m_isPrepared = true; @@ -89,7 +89,7 @@ namespace ucl { } if (flags & PF_ADD_SELF_EXCEPT) { - addDeactivatorException(m_rc->getObjPtr()); + addDeactivatorException(getObjPtr()); } m_window = parent.m_window; @@ -125,22 +125,22 @@ namespace ucl { void GuiPresenter::sendActivate(Widget &sender) { - sendDeactivator(sender, impl::ACTIVATE_BY, m_rc->getObjPtr()); + sendDeactivator(sender, impl::ACTIVATE_BY, getObjPtr()); } void GuiPresenter::sendDeactivate(Widget &sender) { - sendDeactivator(sender, impl::DEACTIVATE_BY, m_rc->getObjPtr()); + sendDeactivator(sender, impl::DEACTIVATE_BY, getObjPtr()); } void GuiPresenter::broadcastActivate() { - broadcastDeactivator(impl::ACTIVATE_BY, m_rc->getObjPtr()); + broadcastDeactivator(impl::ACTIVATE_BY, getObjPtr()); } void GuiPresenter::broadcastDeactivate() { - broadcastDeactivator(impl::DEACTIVATE_BY, m_rc->getObjPtr()); + broadcastDeactivator(impl::DEACTIVATE_BY, getObjPtr()); } void GuiPresenter::sendDeactivator(Widget &sender, |