realbasic-nug
[Top] [All Lists]

Re: Don't update a window?

To: REALbasic NUG <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: Don't update a window?
From: Seth Willits <seth at freaksw dot com>
Date: Fri, 31 Dec 2004 15:30:38 -0800
Delivered-to: realbasic-nug at lists dot realsoftware dot com
References: <7729531304123115087fc1df7f at mail dot gmail dot com>
On Dec 31, 2004, at 3:08 PM, Dave wrote:

I have a window whose left and width values I'd like to change
"simultaneously".  The "self.left = xxx" and "self.width = yyy" lines
are right next to eachother, but when I execute the code, the window
flickers.  It moves, updates, widens, and updates.  How can I get it
to move, widen, and THEN update?


Window moving and resizing doesn't take place until after the method ends or the event loop comes around again. It's easy to see this with the code:

  self.Width = self.Width * 2
  App.DoEvents // toggle me on and off.
  while not UserCancelled
  wend


If you're seeing otherwise, either you're using an older version of REALbasic where this didn't happen, or maybe you're in a thread?



Seth Willits
------------------------------------------------------------------------ ---
President and Head Developer of Freak Software - http://www.freaksw.com
REALbasic Guru at ResExcellence - http://www.resexcellence.com/realbasic

"A computer without Windows is like a cake without mustard."
    -- A Bringer of Truth
------------------------------------------------------------------------ ---

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

<Prev in Thread] Current Thread [Next in Thread>