From c1b5b87ec353091f48147ecb9807ae7b1a3bcc13 Mon Sep 17 00:00:00 2001 From: besh81 Date: Thu, 11 Jul 2019 17:20:48 +0200 Subject: [PATCH] Fixed issue on dockpane close Now closing a dockpane when the x button is inside the place area don't show the dock indicator anymore. --- source/gui/place_parts.hpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/source/gui/place_parts.hpp b/source/gui/place_parts.hpp index 74dda204..03e21894 100644 --- a/source/gui/place_parts.hpp +++ b/source/gui/place_parts.hpp @@ -126,6 +126,12 @@ namespace nana { close_fn_ = std::move(fn); } + + bool hit_close() + { + return x_pointed_; + } + private: virtual void attached(widget_reference wdg, graph_reference graph) override { @@ -310,7 +316,9 @@ namespace nana { move_pos += moves_.start_container_pos; API::move_window(container_->handle(), move_pos); - notifier_->notify_move(); + + if(!caption_.get_drawer_trigger().hit_close()) + notifier_->notify_move(); } } }