Page 1 of 1

AddStatusBarField()

Posted: Mon May 15, 2006 1:33 pm
by Tranquil
Why does this command do not need a StatusBar Object number? Is this threadsave?

Posted: Mon May 15, 2006 2:19 pm
by va!n
Before using AddStatusBarField() you are using CreateStatusBar() and here you are defining the StatusBarID and on which Window the StatusBar should be created. So AddStatusBarField know where to draw the stuff. (same like when doing it with API only) I think it should make no problems in threads.

Posted: Mon May 15, 2006 2:30 pm
by Tranquil
Most APIs relay on the "calling thread". Sure, I will never add a statusbarfield in a thread but as I used this command today I thought about ist.

@Vain:
What do you think happens if your mainloop adds statusbarfields to your firstly created statusbar while your thread is doing the same on another window. Get the point?

Posted: Mon May 15, 2006 6:03 pm
by va!n
yeah, i got the point ^^ i dont know what happens, if two threads are trying to modify/change the DIM where the Fields and its width are stored.