From 30060773b06d93ae08a8c6fa5836c81e595594ed Mon Sep 17 00:00:00 2001 From: crupest Date: Sat, 29 Jan 2022 21:07:48 +0800 Subject: ... --- src/osx/gui/Window.mm | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/osx') diff --git a/src/osx/gui/Window.mm b/src/osx/gui/Window.mm index 3bea5543..6ed53701 100644 --- a/src/osx/gui/Window.mm +++ b/src/osx/gui/Window.mm @@ -375,6 +375,12 @@ void OsxWindow::SetCursor(std::shared_ptr cursor) { } } +void OsxWindow::SetToForeground() { + if (!p_->window_) return; + [p_->window_ makeMainWindow]; + [p_->window_ orderFrontRegardless]; +} + IEvent* OsxWindow::CreateEvent() { return &p_->create_event_; } IEvent* OsxWindow::DestroyEvent() { return &p_->destroy_event_; } IEvent* OsxWindow::PaintEvent() { return &p_->paint_event_; } -- cgit v1.2.3