void IViewContent.Load(FileOpenInformation fileOpenInformation) { this.textEditorImpl.DirtyChanged -= HandleDirtyChanged; this.textEditor.TextChanged -= HandleTextChanged; textEditorImpl.Load(fileOpenInformation); RunFirstTimeFoldUpdate(textEditor.Text); textEditorImpl.InformLoadComplete(); this.textEditor.TextChanged += HandleTextChanged; this.textEditorImpl.DirtyChanged += HandleDirtyChanged; }
async Task Load(bool reloading) { textEditorImpl.DirtyChanged -= HandleDirtyChanged; textEditor.TextChanged -= HandleTextChanged; await textEditorImpl.Load(FilePath, Encoding, reloading); await RunFirstTimeFoldUpdate(textEditor.Text); textEditorImpl.InformLoadComplete(); textEditor.TextChanged += HandleTextChanged; textEditorImpl.DirtyChanged += HandleDirtyChanged; }