Set the size of a sheet when it's first loaded
Set the size of a sheet when it's first loaded
- Subject: Set the size of a sheet when it's first loaded
- From: Shane Stanley <email@hidden>
- Date: Thu, 25 Aug 2016 18:28:34 +1000
I have a window that is shown as a sheet over another window. The sheet contains a small table, and I want the sheet to be sized vertically to show however many rows are required. So just before I show the sheet I update the table and adjust the window's frame. This works fine -- except for the first time the sheet appears, when it always appears with the size set in the nib.
I'm using autolayout, and I'm calling the code to set the window's frame and reload the table's data before showing the sheet (but after calling window to ensure it's loaded). The table is being updated, but not the size. I've also tried setting the frame in the sheet controller's windowDidLoad, but that appears to be too late.
I'm sure I'm missing something simple...
--
Shane Stanley <email@hidden>
_______________________________________________
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