diff options
| author | nyamatongwe <devnull@localhost> | 2012-09-05 08:40:49 +1000 |
|---|---|---|
| committer | nyamatongwe <devnull@localhost> | 2012-09-05 08:40:49 +1000 |
| commit | 9f6689d44770e6384a645a7be520bf7d8a9de2b6 (patch) | |
| tree | b2ae8ebac25fe913da24fc2b9909b836013d4b64 | |
| parent | 2d0f6c26824cbf68eb8c5a7490d0bb74965c41b6 (diff) | |
| download | scintilla-mirror-9f6689d44770e6384a645a7be520bf7d8a9de2b6.tar.gz | |
Fix crashes on Ubuntu with GTK+3 where scroll bar changes invalidate the
drawing surface.
| -rw-r--r-- | gtk/ScintillaGTK.cxx | 4 | ||||
| -rw-r--r-- | src/Editor.cxx | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/gtk/ScintillaGTK.cxx b/gtk/ScintillaGTK.cxx index be007e775..8a09b105b 100644 --- a/gtk/ScintillaGTK.cxx +++ b/gtk/ScintillaGTK.cxx @@ -1213,6 +1213,10 @@ bool ScintillaGTK::ModifyScrollBars(int nMax, int nPage) { modified = true; } #endif + if (modified && (paintState == painting)) { + paintState = paintAbandoned; + } + return modified; } diff --git a/src/Editor.cxx b/src/Editor.cxx index fea5a2336..2b2b1785d 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -3438,6 +3438,8 @@ void Editor::Paint(Surface *surfaceWindow, PRectangle rcArea) { AllocateGraphics(); RefreshStyleData(); + if (paintState == paintAbandoned) + return; // Scroll bars may have changed so need redraw RefreshPixMaps(surfaceWindow); StyleToPositionInView(PositionAfterArea(rcArea)); |
