Replace flatten with writeFlattenable for desc.

This replaces calls to SkFlattenable::flatten(SkWriteBuffer&) with
calls to SkWriteBuffer::writeFlattenable(const SkFlattenable*) when
creating the descriptor for an SkScalerContext. This adds the identifier
of the flattenable to the descriptor to avoid collisions when two
flattenables take the same (or no) parameters. This used to be enforced
when the SkScalerContext re-created the flattenable from the descriptor,
but since this is no longer required these possible collisions may
occur.

Change-Id: I2b7efebebf20ffcc0f2b58a081ff0c58158f7d70
Reviewed-on: https://skia-review.googlesource.com/124054
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
1 file changed