From 663a36df4aaea583e7cd56ad35b26d05f6151746 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Thu, 31 Mar 2022 17:29:32 +0200 Subject: Show overlay as a window on top (override redirect and always on top) instead of a child window and capture window and render that --- src/gui/Button.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/gui') diff --git a/src/gui/Button.cpp b/src/gui/Button.cpp index d7df26a..1436f86 100644 --- a/src/gui/Button.cpp +++ b/src/gui/Button.cpp @@ -71,6 +71,12 @@ namespace gsr { rect.set_color(border_color); window.draw(rect); } + } else { + // Background + mgl::Rectangle rect(size); + rect.set_position(position); + rect.set_color(mgl::Color(20, 20, 20, 225)); + window.draw(rect); } } } \ No newline at end of file -- cgit v1.2.3