From aa255d832bd769d2814c5bffcce30d02ccd27208 Mon Sep 17 00:00:00 2001 From: mitchell Date: Sun, 31 Mar 2019 21:57:39 -0400 Subject: Backport Avoid hangs in idle styling modes caused by high-priority idle work styling. Backport of changeset 7315:57ea0255c8aa, but without constexpr, as non-static data members cannot be constexpr in C++11. --- src/Editor.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/Editor.h') diff --git a/src/Editor.h b/src/Editor.h index 29150276a..cbdd171cf 100644 --- a/src/Editor.h +++ b/src/Editor.h @@ -522,6 +522,9 @@ protected: // ScintillaBase subclass needs access to much of Editor Sci::Position PositionAfterMaxStyling(Sci::Position posMax, bool scrolling) const; void StartIdleStyling(bool truncatedLastStyling); void StyleAreaBounded(PRectangle rcArea, bool scrolling); + bool SynchronousStylingToVisible() const noexcept { + return (idleStyling == SC_IDLESTYLING_NONE) || (idleStyling == SC_IDLESTYLING_AFTERVISIBLE); + } void IdleStyling(); virtual void IdleWork(); virtual void QueueIdleWork(WorkNeeded::workItems items, Sci::Position upTo=0); -- cgit v1.2.3