Move the inheritance logic to XMLFile class. Revert RenderPath class.

- Fix the original XMLFile used in the inheritance from being patched in the resource cache.
- Support multi-level inheritance.
- Support for all classes that use XMLFile for loading.
Sync at 2014-01-28 23:24:39 +0800.