Remove use of glib-mkenum and enum types

This is an (unfortunate) requirement of distributing code as a
library. However we're not distributing any of our GObject code
as libraries. So remove use of glib-mkenum and all the complexity
it entails.

Closes #532
Reviewed-by: Marius Vollmer <marius.vollmer@redhat.com>