diff --git a/far2l/src/viewer.cpp b/far2l/src/viewer.cpp index 0110f43c7..b0403bf9b 100644 --- a/far2l/src/viewer.cpp +++ b/far2l/src/viewer.cpp @@ -268,6 +268,12 @@ void Viewer::KeepInitParameters() InitHex = VM.Hex; } +void Viewer::Show() +{ + if (!OpenFailed) + ScreenObject::Show(); +} + int Viewer::OpenFile(FileHolderPtr NewFileHolder, int warning) { VM.CodePage = DefCodePage; diff --git a/far2l/src/viewer.hpp b/far2l/src/viewer.hpp index f7cef9296..002e8a174 100644 --- a/far2l/src/viewer.hpp +++ b/far2l/src/viewer.hpp @@ -190,6 +190,7 @@ class Viewer : public ScreenObject int OpenFile(FileHolderPtr NewFileHolder, int warning); void SetViewKeyBar(KeyBar *ViewKeyBar); + virtual void Show(); virtual int ProcessKey(FarKey Key); virtual int ProcessMouse(MOUSE_EVENT_RECORD *MouseEvent); virtual int64_t VMProcess(MacroOpcode OpCode, void *vParam = nullptr, int64_t iParam = 0);