• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Window minimize erases content?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Window minimize erases content?


  • Subject: Re: Window minimize erases content?
  • From: Andrew Platzer <email@hidden>
  • Date: Wed, 30 May 2001 10:18:44 -0700

On Wednesday, May 30, 2001, at 07:59 , Darrell Walisser wrote:
I have a NSWindow, created manually as a retained window, whose
contentview is set to a NSQuickDrawView. To draw to the window port, I
call LockPortBits() and GetPortBits(), then draw directly to window memory
using my own routines.
My problem is that when the window is minimized and unminimized,
the port gets colored with the Aqua pinstrip background. Since my app
will be drawing into the window buffer even when it is minimized, it is
important to me that this works correctly. Any clues as to how I might fix
this? Do I need to redraw and flush the entire window buffer when I detect
a minimize?

If the window is marked 'One shot', the default in IB, that means that the window's backing store is tossed on minimize. When the window is unminimized, the content view and it's subviews are drawn again. It sounds like you might be drawing outside of the normal drawRect: call. Consider a call to -[NSQuickDrawView drawRect:] as an update request and redraw your QD stuff. Or turn off the 'One shot' flag for the window in IB.

Andrew
__________________________________________________________________
A n d r e w P l a t z e r
A p p l i c a t i o n F r a m e w o r k s
A p p l e


  • Prev by Date: Re: Carbon Framework - DataBrowser Tweaks
  • Next by Date: RE: Simple Port Traffic?
  • Previous by thread: Window minimize erases content?
  • Next by thread: Re: Window minimize erases content?
  • Index(es):
    • Date
    • Thread