Fix wrong horizontal scroll bar position after restoring Window position
Fix #8466, close #8475pull/8506/head
parent
53b03cc5c5
commit
267da64d33
|
@ -1646,6 +1646,10 @@ LRESULT Notepad_plus::process(HWND hwnd, UINT message, WPARAM wParam, LPARAM lPa
|
|||
case WM_ACTIVATE:
|
||||
{
|
||||
_pEditView->getFocus();
|
||||
auto x = _pEditView->execute(SCI_GETXOFFSET);
|
||||
_pEditView->execute(SCI_SETXOFFSET, x);
|
||||
x = _pNonEditView->execute(SCI_GETXOFFSET);
|
||||
_pNonEditView->execute(SCI_SETXOFFSET, x);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
|
|
@ -221,13 +221,14 @@ public:
|
|||
{
|
||||
::DestroyWindow(_hSelf);
|
||||
_hSelf = NULL;
|
||||
_pScintillaFunc = NULL;
|
||||
};
|
||||
|
||||
virtual void init(HINSTANCE hInst, HWND hPere);
|
||||
|
||||
LRESULT execute(UINT Msg, WPARAM wParam=0, LPARAM lParam=0) const {
|
||||
try {
|
||||
return _pScintillaFunc(_pScintillaPtr, Msg, wParam, lParam);
|
||||
return (_pScintillaFunc) ? _pScintillaFunc(_pScintillaPtr, Msg, wParam, lParam) : -1;
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue