mirror of
https://github.com/Lorenzooone/cc3dsfs.git
synced 2026-09-15 20:15:25 -05:00
Fix bad application quitting with multiple windows
This commit is contained in:
@@ -290,6 +290,8 @@ void WindowScreen::poll() {
|
||||
break;
|
||||
}
|
||||
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -324,8 +326,8 @@ void WindowScreen::display_thread(CaptureData* capture_data) {
|
||||
this->display_call(false);
|
||||
}
|
||||
}
|
||||
if(this->m_win.isOpen())
|
||||
this->m_win.close();
|
||||
if(!this->main_thread_owns_window)
|
||||
this->m_win.setActive(false);
|
||||
this->done_display = true;
|
||||
}
|
||||
|
||||
@@ -335,6 +337,13 @@ void WindowScreen::end() {
|
||||
this->display_lock.unlock();
|
||||
}
|
||||
|
||||
void WindowScreen::after_thread_join() {
|
||||
if(this->m_win.isOpen()) {
|
||||
this->m_win.setActive(true);
|
||||
this->m_win.close();
|
||||
}
|
||||
}
|
||||
|
||||
void WindowScreen::draw(double frame_time, VideoOutputData* out_buf) {
|
||||
if(!this->done_display)
|
||||
return;
|
||||
@@ -537,7 +546,7 @@ void WindowScreen::window_factory(bool is_main_thread) {
|
||||
}
|
||||
|
||||
void WindowScreen::pre_texture_conversion_processing() {
|
||||
//Place preprocessing effects here
|
||||
//Place preprocessing window-specific effects here
|
||||
this->in_tex.update((uint8_t*)this->saved_buf, IN_VIDEO_WIDTH, IN_VIDEO_HEIGHT, 0, 0);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user