diff options
author | Neil Hodgson <nyamatongwe@gmail.com> | 2014-07-15 12:04:54 +1000 |
---|---|---|
committer | Neil Hodgson <nyamatongwe@gmail.com> | 2014-07-15 12:04:54 +1000 |
commit | baf2d31068737bf24102cee6a7fed33e0d00d1f3 (patch) | |
tree | f814f1a39637d7711ab0ce709fef0b2468fbb270 /src/Editor.h | |
parent | 7b7865ca3062d57ebe990468a9275180f0d60569 (diff) | |
download | scintilla-mirror-baf2d31068737bf24102cee6a7fed33e0d00d1f3.tar.gz |
Implement separate timers for each type of periodic activity and turn them on and off
as required. This saves power as there are fewer wake ups.
A tolerance value is provided so that platforms that support coalescing timers,
Windows 8+ and OS X 10.9+, can use them.
The previous global 100 millisecond timer may still be used by non-core platforms.
Diffstat (limited to 'src/Editor.h')
-rw-r--r-- | src/Editor.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/Editor.h b/src/Editor.h index 53da90906..d80292a0a 100644 --- a/src/Editor.h +++ b/src/Editor.h @@ -500,7 +500,13 @@ protected: // ScintillaBase subclass needs access to much of Editor void Tick(); bool Idle(); - virtual void SetTicking(bool on) = 0; + virtual void SetTicking(bool on); + enum TickReason { tickCaret, tickScroll, tickWiden, tickDwell, tickPlatform }; + virtual void TickFor(TickReason reason); + virtual bool FineTickerAvailable(); + virtual bool FineTickerRunning(TickReason reason); + virtual void FineTickerStart(TickReason reason, int millis, int tolerance); + virtual void FineTickerCancel(TickReason reason); virtual bool SetIdle(bool) { return false; } virtual void SetMouseCapture(bool on) = 0; virtual bool HaveMouseCapture() = 0; |