Fix some bugs in CCScale9Sprite

Please review before merging.
Scale9Sprite tests have been updated in the cocos2d-js-tests repository. More bug fixes to be made.

 - handles default modes correctly
 - Bugs when the source is a sprite that is stored rotated in a spritesheet.