Rebase on proper 2.x branch.
Renamed sublayerCount and added a comment about it.
Merge pull request #232 from dgileadi/fix-xml

Fix issue with editing/reloading XML