Fix for #1633: setRepresentedFilename

Without this fix, CPWindow setRepresentedFilename is set as a string, not a CPURL (as specified by the variable type). (With tests)
Merge pull request #1741 from ahankinson/fix-issue1633

Fix for #1633: setRepresentedFilename