Updating document class if it was renamed

Now.
Rename document class: ![2014-05-10 17 28 03](https://cloud.githubusercontent.com/assets/1700940/2936114/0e0dcbd2-d847-11e3-8946-348df4adf01f.png)
Result: ![2014-05-10 17 28 16](https://cloud.githubusercontent.com/assets/1700940/2936116/4763b37e-d847-11e3-9d04-d3d643a38560.png)

Result after fix: ![2014-05-10 17 28 16](https://cloud.githubusercontent.com/assets/1700940/2936123/a2638998-d847-11e3-91fb-21b751a06b30.png)