Skip to content

Commit

Permalink
HexEditor crashes Notepad++ v8 while launch Distraction Free mode wit…
Browse files Browse the repository at this point in the history
…h Dark mode activated #51

- workaround to avoid the crash by disabling ::SetFocus(), this results in a flickering statusbar which is therefore also disabled until a better fix is found
  • Loading branch information
chcg committed Feb 2, 2022
1 parent 9f00187 commit 0cc944e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions HexEditor/src/HEXDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -980,7 +980,9 @@ void HexEdit::MoveView(void)
else if (::IsWindowVisible(_hParentHandle) == FALSE)
{
::ShowWindow(_hParentHandle, SW_SHOW);
#ifdef ENABLE_CRASH_51
::SetFocus(_hParentHandle);
#endif
::ShowWindow(_hSelf, SW_HIDE);
::ShowWindow(_hListCtrl, SW_HIDE);
}
Expand Down Expand Up @@ -4239,6 +4241,7 @@ void HexEdit::DeleteBookmarkLines(void)

void HexEdit::SetStatusBar(void)
{
#ifdef ENABLE_FLICKERING_STATUSBAR_WITHOUT_51
if (_pCurProp && _pCurProp->isVisible == TRUE)
{
TCHAR buffer[64] = { 0 };
Expand All @@ -4262,6 +4265,7 @@ void HexEdit::SetStatusBar(void)
/* display information in which mode it is (BigEndian or Little) */
::SendMessage(_hParent, NPPM_SETSTATUSBAR, STATUSBAR_UNICODE_TYPE, (LPARAM)(_pCurProp->isLittle == FALSE ? _T("BigEndian") : _T("LittleEndian")));
}
#endif
}


Expand Down

0 comments on commit 0cc944e

Please sign in to comment.