Skip to content

ActivityIndicator as state machine#198

Merged
deathaxe merged 6 commits intomasterfrom
feat/activity-indicator-statemachine
Feb 15, 2026
Merged

ActivityIndicator as state machine#198
deathaxe merged 6 commits intomasterfrom
feat/activity-indicator-statemachine

Conversation

@deathaxe
Copy link
Member

This commit implements a state machine to ensure only single _tick() being in flight via sublime.set_timeout().

It replaces _running & _invocation_id by _state attribute, to indicate required states, especially the "STOPPING" one.

This commit replaces _running & _invocation_id by _state attribute,
to ensure only single _tick being in flight.
@deathaxe deathaxe force-pushed the feat/activity-indicator-statemachine branch from fd005ec to ae6c9e3 Compare February 13, 2026 19:32
This commit converts _tick() method, bound to instance, into a weak method
in order to avoid re-creating a weakref each tick.
@deathaxe deathaxe force-pushed the feat/activity-indicator-statemachine branch from 3d9fb36 to 09ddeaa Compare February 13, 2026 22:33
Mypy complains about inplace replacement of bound methods.
@deathaxe deathaxe merged commit 925f5e6 into master Feb 15, 2026
1 check passed
@deathaxe deathaxe deleted the feat/activity-indicator-statemachine branch February 15, 2026 08:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants