Refactor CssResourceGenerator to share code.

In the context of writing a generator for supporting Google closure
stylesheet, this little refactoring is needed in order to share some
code between the different generators.

The draft implementation of GssResourceGenerator :
https://github.com/jDramaix/gss.gwt/pull/1

Related thread on contributors group :
https://groups.google.com/forum/#!topic/google-web-toolkit-contributors/e0qUfkqBSog

Change-Id: I1046d34dc92f2bd3baeb7d4852c146253f858e47
Merge remote-tracking branch 'upstream/master'