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

Method Close

src/subs_controller.cpp:227–237  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

225}
226
227void SubsController::Close() {
228 undo_stack.clear();
229 redo_stack.clear();
230 autosaved_commit_id = saved_commit_id = commit_id + 1;
231 filename.clear();
232 AssFile blank;
233 blank.swap(*context->ass);
234 context->ass->LoadDefault(true, OPT_GET("Subtitle Format/ASS/Default Style Catalog")->GetString());
235 context->ass->Commit("", AssFile::COMMIT_NEW);
236 FileOpen(filename);
237}
238
239int SubsController::TryToClose(bool allow_cancel) const {
240 if (!IsModified())

Callers 12

ShowSearchReplaceDialogFunction · 0.45
clipboard_setFunction · 0.45
GetClipboardFunction · 0.45
SetClipboardFunction · 0.45
OnExitMethod · 0.45
CloseAllMethod · 0.45
CloseSubtitlesMethod · 0.45
operator()Function · 0.45
subtitle_closeClass · 0.45
edit_line_pasteClass · 0.45
ValidateFunction · 0.45
app_languageClass · 0.45

Calls 4

swapMethod · 0.80
LoadDefaultMethod · 0.80
clearMethod · 0.45
CommitMethod · 0.45

Tested by

no test coverage detected