From 69f8cd98ee3b78f2e4ee509d30e5e828456ef702 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Fri, 29 Oct 2021 12:23:32 +0300 Subject: [PATCH] Move Bufferable::refresh_async's definition to the header --- source/core/bufferable.cpp | 5 ----- source/core/bufferable.h | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/source/core/bufferable.cpp b/source/core/bufferable.cpp index 0a480e25..a0ff06c8 100644 --- a/source/core/bufferable.cpp +++ b/source/core/bufferable.cpp @@ -60,11 +60,6 @@ unsigned Bufferable::get_required_buffer_size() const return last->offset+last->get_data_size(); } -Bufferable::AsyncUpdater *Bufferable::refresh_async() const -{ - return dirty ? new AsyncUpdater(*this) : 0; -} - void Bufferable::unlink_from_buffer() { if(prev_in_buffer) diff --git a/source/core/bufferable.h b/source/core/bufferable.h index c40c891e..f1d52fb3 100644 --- a/source/core/bufferable.h +++ b/source/core/bufferable.h @@ -57,7 +57,7 @@ public: /** Returns an object which can be used to upload data to the buffer using mapped memory. */ - AsyncUpdater *refresh_async() const; + AsyncUpdater *refresh_async() const { return dirty ? new AsyncUpdater(*this) : 0; } private: void unlink_from_buffer(); -- 2.45.2