Bugfix for Sprite9Slice bug #897 and refactoring

This was originally a refactoring branch to move Inspector related code from the AppDelegate to a more separated place.

Several higher level test cases were added to ensure the property inspector panes are still working.

I added to the bugfix on top of this as this was a good situation to integrate the code with more test coverage.