Re: WTL, GUI and Thread

"Konstantin Mironovich" <[email protected]>
Newsgroups gmane.comp.windows.wtl
Organization ixbt.com
Message-ID <90537E5E923D45A0BAA5E2C3F8AE4AFC@klm>
counter-example (for the case) before clause "see also"

-km
  ----- Original Message ----- 
  From: Johann Gerell
  To: [email protected]
  Sent: Friday, December 04, 2009 2:56 PM
  Subject: RE: [wtl] WTL, GUI and Thread



  Ehum?

  Are you calling PostMessage overcomplicated and mentioning
  IBindStatusCallback as a counter-example, all in the same breath?

  That's a higher sense of humor.

  Your example of volatile gives little information on how a GUI thread can 
be
  notified of a change to it. You still need to communicate between the
  threads. Atomically changing volatile data has some use, but it's (as you
  sort of mention) limited to lock-free scenarios.

  /Johann

  -----Original Message-----
  From: [email protected] [mailto:[email protected]] On Behalf Of
  Konstantin Mironovich
  Sent: den 4 december 2009 12:09
  To: [email protected]
  Subject: Re: [wtl] WTL, GUI and Thread

  seems overcomplicated.

  volatile int statusID; // will be enough for current case.

  statusID = STATUS_XXX; // is atomic operation so any lock is not needed

  see also IBindStatusCallback as a good example of how a status info could 
be
  http://msdn.microsoft.com/en-us/library/ms775060(VS.85).aspx

  -km
  ----- Original Message ----- 
  From: Johann Gerell
  To: [email protected]
  Sent: Friday, December 04, 2009 10:29 AM
  Subject: RE: [wtl] WTL, GUI and Thread

  http://www.codeproject.com/KB/threads/usingworkerthreads.aspx

  -----Original Message-----
  From: [email protected] [mailto:[email protected]] On Behalf Of Andrey
  Sergienko
  Sent: den 4 december 2009 07:42
  To: Dick Dievendorff
  Subject: Re[2]: [wtl] WTL, GUI and Thread

  Hello.

  Can you, please, put a piece of code here for example or give me a link
  where to read about that?
  Thanks!

  > Your long-running thread can't make UI function calls. But it can issue
  > PostMessage to put user-defined status update messages onto the message
  > queue of your UI thread.

  -- 
  Regards
  Andrey mailto:[email protected]

  ------------------------------------

  Yahoo! Groups Links

  [Non-text portions of this message have been removed]

  ------------------------------------

  Yahoo! Groups Links



   


[Non-text portions of this message have been removed]



------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/wtl/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/wtl/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected] 
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.