{"action":"opened","issue":{"url":"https://api.github.com/repos/lionheart/openradar-mirror/issues/11809","repository_url":"https://api.github.com/repos/lionheart/openradar-mirror","labels_url":"https://api.github.com/repos/lionheart/openradar-mirror/issues/11809/labels{/name}","comments_url":"https://api.github.com/repos/lionheart/openradar-mirror/issues/11809/comments","events_url":"https://api.github.com/repos/lionheart/openradar-mirror/issues/11809/events","html_url":"https://github.com/lionheart/openradar-mirror/issues/11809","id":148555292,"number":11809,"title":"18565021: NSViewController's viewDidLoad is called before its parent NSWindowController is set","user":{"login":"openradar-mirror","id":13605213,"avatar_url":"https://avatars.githubusercontent.com/u/13605213?v=3","gravatar_id":"","url":"https://api.github.com/users/openradar-mirror","html_url":"https://github.com/openradar-mirror","followers_url":"https://api.github.com/users/openradar-mirror/followers","following_url":"https://api.github.com/users/openradar-mirror/following{/other_user}","gists_url":"https://api.github.com/users/openradar-mirror/gists{/gist_id}","starred_url":"https://api.github.com/users/openradar-mirror/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openradar-mirror/subscriptions","organizations_url":"https://api.github.com/users/openradar-mirror/orgs","repos_url":"https://api.github.com/users/openradar-mirror/repos","events_url":"https://api.github.com/users/openradar-mirror/events{/privacy}","received_events_url":"https://api.github.com/users/openradar-mirror/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/lionheart/openradar-mirror/labels/classification:other%20bug","name":"classification:other bug","color":"e11d21"},{"url":"https://api.github.com/repos/lionheart/openradar-mirror/labels/reproducible:always","name":"reproducible:always","color":"5319e7"},{"url":"https://api.github.com/repos/lionheart/openradar-mirror/labels/status:open","name":"status:open","color":"009800"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/lionheart/openradar-mirror/milestones/6","html_url":"https://github.com/lionheart/openradar-mirror/milestones/OS%20X","labels_url":"https://api.github.com/repos/lionheart/openradar-mirror/milestones/6/labels","id":1237420,"number":6,"title":"OS X","description":null,"creator":{"login":"openradar-mirror","id":13605213,"avatar_url":"https://avatars.githubusercontent.com/u/13605213?v=3","gravatar_id":"","url":"https://api.github.com/users/openradar-mirror","html_url":"https://github.com/openradar-mirror","followers_url":"https://api.github.com/users/openradar-mirror/followers","following_url":"https://api.github.com/users/openradar-mirror/following{/other_user}","gists_url":"https://api.github.com/users/openradar-mirror/gists{/gist_id}","starred_url":"https://api.github.com/users/openradar-mirror/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openradar-mirror/subscriptions","organizations_url":"https://api.github.com/users/openradar-mirror/orgs","repos_url":"https://api.github.com/users/openradar-mirror/repos","events_url":"https://api.github.com/users/openradar-mirror/events{/privacy}","received_events_url":"https://api.github.com/users/openradar-mirror/received_events","type":"User","site_admin":false},"open_issues":1110,"closed_issues":1,"state":"open","created_at":"2015-08-03T02:08:32Z","updated_at":"2016-04-15T05:02:07Z","due_on":null,"closed_at":null},"comments":0,"created_at":"2016-04-15T05:02:07Z","updated_at":"2016-04-15T05:02:07Z","closed_at":null,"body":"#### Description\n\nSummary:\r\nIn the default Storyboard-based Document-based app template, a the NSViewController's viewDidLoad method executes before the NSWindowController is set on the NSViewController. This means the NSViewController can't access properties of the NSWindowController, or more importantly the NSDocument subclass, in the viewDidLoad method.\r\n\r\nviewDidLoad should load after the parent windowController is set.\r\n\r\nSteps to Reproduce:\r\n1. Build & run attached project.\r\n2. Create a New Document if one doesn't open automatically.\r\n3. Check the statement logged to the Console\r\n\r\nExpected Results:\r\nWithin the NSDocument's makeWindowControllers method the NSViewController's window, windowController, and document should be not null. \r\n\r\nActual Results:\r\nThey are null.\r\n\r\nVersion:\r\nXcode Version 6.1 (6A1042b), OS X 10.10 (14A379a)\r\n\r\nNotes:\r\n\r\n\r\nConfiguration:\r\n\r\n\r\nAttachments:\r\n'DocumentTest.zip' was successfully uploaded.\n\n-\nProduct Version: Xcode Version 6.1 (6A1042b), OS X 10.10 (14A379a)\nCreated: 2014-10-07T04:29:36.799237\nOriginated: 2014-10-06T21:27:00\nOpen Radar Link: http://www.openradar.me/18565021"}}