From: hyunho Date: Wed, 9 Sep 2020 01:00:48 +0000 (+0900) Subject: Fix current buffer assign position X-Git-Tag: submit/tizen/20200909.013131~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F36%2F243636%2F1;p=platform%2Fcore%2Fappfw%2Fwidget-viewer.git Fix current buffer assign position - current buffer should be assigned before OnChanged Change-Id: I5e755d7d0da3a25b9a3f7c9aa46fa4433f68e9d3 Signed-off-by: hyunho --- diff --git a/watch-holder-base/src/watch_base.cc b/watch-holder-base/src/watch_base.cc index 4eae633d..1c7d5a46 100644 --- a/watch-holder-base/src/watch_base.cc +++ b/watch-holder-base/src/watch_base.cc @@ -169,11 +169,12 @@ void WatchBase::OnBufferChanged(int type, if (impl_->current_buffer_ == nullptr) { LOGD("first added !!!! %d %s", type, GetAppId().c_str()); + impl_->current_buffer_ = tbm; OnAdded(GetAppId(), GetInstId(), GetPid(), tbm); } else { + impl_->current_buffer_ = tbm; OnChanged(GetAppId(), GetInstId(), GetPid(), tbm); } - impl_->current_buffer_ = tbm; } void WatchBase::OnAdded(const std::string& appId, const std::string& instId,