Rounded corner for the dialog

This commit is contained in:
Lam Wei Lun
2026-09-14 15:32:51 +08:00
parent 0131533ae0
commit 9ed8537343
3 changed files with 45 additions and 0 deletions
+7
View File
@@ -7,6 +7,8 @@
#include <memory>
#include <string>
#include <wx/bitmap.h>
namespace Slic3r { namespace GUI {
class SpeedDialWebDialog : public WebViewHostDialog
@@ -25,8 +27,13 @@ private:
void open_wiki(const std::string& id);
void send_actions();
void search_tabs();
void apply_rounded_shape();
void on_dpi_changed(const wxRect& suggested_rect) override;
bool m_page_ready{false};
// Rounded corners via a window shape region, since the webview itself is opaque.
int m_corner_radius{7};
wxBitmap m_shape_bmp;
// Guards the CallAfter in on_script_message across dialog destruction, same as
// PluginsDialog::m_alive (PluginsDialog.hpp:249).
std::shared_ptr<std::atomic<bool>> m_alive = std::make_shared<std::atomic<bool>>(true);