Fixed CPDocumentController missing method currentDocument

In this commit I've added the currentDocument method to the document controller

Also removed the firstEligibleExistingWindowController method from CPDocument
It did nothing but add confusion as it was not used anywhere else in the frameworks.
And it is not in cocoa.
added missing methods to CPDocumentController

documentForWindow
hasEditedDocuments

both are in cocoa
Merge pull request #1870 from BlairDuncan/documentControllerCurrentDocument

Fixed CPDocumentController missing method currentDocument
Formatting: whitespace.

Refs #1870.
Fixed: remove non-standard CPDocument API "firstEligibleExistingWindowController".

This method did not actually do anything, and was not part of the expected CPDocument API.

Refs #1870.