gmain: optimize "context->sources" hash table to use as set
Instead of tracking a (guint,GSource*)
tuple in the context->sources
dictionary, only track pointers to the source_id
.
With this we use the GHashTable
as Set (g_hash_table_add()
), which is
optimized and avoids storing a separate value array.
It's simple enough to do, because there are literally 5 references to
context->sources
. It's easy to review those usages and reason that the
handling is correct.