← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #406532]: cant temporarily stop event observations

 

Question #406532 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/406532

    Status: Answered => Open

geo is still having a problem:
hhmmm I wonder if I'm over doing the observer as in

 instead of:
-----------------
regionX.stopObserver()
#Do something here
regionX.onChange(onchangedFunction) #<-- I don't think this is needed
regionX.observe(FOREVER, background=True)

just Do:
------------
regionX.stopObserver()
#Do something here
regionX.observe(FOREVER, background=True)


Also, are the observers global? for example 

I'm doing the following:
------------------------------------
def eventHandler(event)
    regionX.stopObserver()
    #Do something here
    regionX.observe(FOREVER, background=True)


Where I should be doing:
-------------------------------------
def eventHandler(event)
    event.stopObserver()
    #Do something here
    event.observe(FOREVER, background=True)

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.