aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--doc/ScintillaHistory.html4
-rw-r--r--win32/ScintillaWin.cxx23
2 files changed, 14 insertions, 13 deletions
diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html
index fb750e384..b2cc9c40f 100644
--- a/doc/ScintillaHistory.html
+++ b/doc/ScintillaHistory.html
@@ -483,6 +483,10 @@
<a href="http://sourceforge.net/p/scintilla/feature-requests/887/">Feature #887.</a>
</li>
<li>
+ Fix another problem with drawing on Windows with Direct2D when returning from lock screen.
+ The whole window is redrawn as just redrawing the initially required area left other areas black.
+ </li>
+ <li>
When scroll width is tracked, take width of annotation lines into account.
</li>
<li>
diff --git a/win32/ScintillaWin.cxx b/win32/ScintillaWin.cxx
index 2ddc3944f..7bc05eec8 100644
--- a/win32/ScintillaWin.cxx
+++ b/win32/ScintillaWin.cxx
@@ -600,19 +600,16 @@ LRESULT ScintillaWin::WndPaint(uptr_t wParam) {
}
} else {
#if defined(USE_D2D)
- for (int attempt=0;attempt<2;attempt++) {
- EnsureRenderTarget();
- AutoSurface surfaceWindow(pRenderTarget, this);
- if (surfaceWindow) {
- pRenderTarget->BeginDraw();
- Paint(surfaceWindow, rcPaint);
- surfaceWindow->Release();
- HRESULT hr = pRenderTarget->EndDraw();
- if (hr == D2DERR_RECREATE_TARGET) {
- DropRenderTarget();
- } else {
- break;
- }
+ EnsureRenderTarget();
+ AutoSurface surfaceWindow(pRenderTarget, this);
+ if (surfaceWindow) {
+ pRenderTarget->BeginDraw();
+ Paint(surfaceWindow, rcPaint);
+ surfaceWindow->Release();
+ HRESULT hr = pRenderTarget->EndDraw();
+ if (hr == D2DERR_RECREATE_TARGET) {
+ DropRenderTarget();
+ paintState = paintAbandoned;
}
}
#endif