1. Dominic Kexel
  2. Regnancy

Source

Regnancy / client / cpuspinnercontroller.py

Dominic Kexel 8b6bb37 

Dominic Kexel 965f8b0 


Dominic Kexel 8b6bb37 
Dominic Kexel 965f8b0 
Dominic Kexel 8b6bb37 





Dominic Kexel 89e0d23 
Dominic Kexel 8b6bb37 




#!/usr/bin/python
# -*- coding: utf-8 -*-

from framework.event import TickEvent, QuitEvent


class CPUSpinnerController:

    def __init__(self):
        self.keepGoing = True

    def run(self, ev):
        while self.keepGoing:
            TickEvent().post(ev)

    def notify(self, event):
        if isinstance(event, QuitEvent):
            self.keepGoing = False