• 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: Are sheets broken in Leopard or I am doing something very wrong?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Are sheets broken in Leopard or I am doing something very wrong?


  • Subject: Re: Are sheets broken in Leopard or I am doing something very wrong?
  • From: j o a r <email@hidden>
  • Date: Sat, 12 Jan 2008 15:28:44 -0800


On Jan 12, 2008, at 3:08 PM, Toplica Tanasković wrote:

I am trying to display custom sheet upon displaying new window in Cocoa document based app.
The problem is that sheet is not displayed as sheet but as normal standalone window!? As far as I remember
the method I'm using worked perfectly in Tiger. What am I doing wrong?


In this call:

	[NSApp beginSheet: connectionSheet
	   modalForWindow: window
		modalDelegate: self
	   didEndSelector: @selector(didEndSheet:returnCode:contextInfo:)
		  contextInfo: nil];

The variable "window" is *nil*. Whenever that's the case, your sheet will appear as a standalone window.

To fix this:

* Set the class of the files owner in your document nib to be PGWizDocument
* Connect the window outlet of the files owner (the document) to the window in the nib


j o a r


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Are sheets broken in Leopard or I am doing something very wrong? (From: Toplica Tanasković <email@hidden>)

  • Prev by Date: Trying to use NSStream
  • Next by Date: Re: Trying to use NSStream
  • Previous by thread: Are sheets broken in Leopard or I am doing something very wrong?
  • Next by thread: Trying to use NSStream
  • Index(es):
    • Date
    • Thread