MCPcopy Create free account
hub / github.com/TypesettingTools/Aegisub / OnCloseWindow

Method OnCloseWindow

src/frame_main.cpp:309–327  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

307END_EVENT_TABLE()
308
309void FrameMain::OnCloseWindow(wxCloseEvent &event) {
310 wxEventBlocker blocker(this, wxEVT_CLOSE_WINDOW);
311
312 context->videoController->Stop();
313 context->audioController->Stop();
314
315 // Ask user if he wants to save first
316 if (context->subsController->TryToClose(event.CanVeto()) == wxCANCEL) {
317 event.Veto();
318 return;
319 }
320
321 context->dialog.reset();
322
323 // Store maximization state
324 OPT_SET("App/Maximized")->SetBool(IsMaximized());
325
326 Destroy();
327}
328
329void FrameMain::OnStatusClear(wxTimerEvent &) {
330 SetStatusText("",1);

Callers

nothing calls this directly

Calls 2

TryToCloseMethod · 0.80
StopMethod · 0.45

Tested by

no test coverage detected