I sent this to the gconf-list as well, but I’m posting it here in case someone has some generic code that I can steal, or has some better idea.
Say I have an intensive process that should be rerun in response to changes in any one of twenty GConf configuration keys, how might I prevent my application from re-running that process 20 times instead of just once, when changing all the keys at one time?
At the moment, I think the only solution is to append each notification key to a GList, and use a g_timeout handler to notify my application about batches of changes, if anything changed, at regular intervals. That would not avoid all excess notifications, but it could avoid most.
Note that you can’t just turn off notification while making the changes, because the notification happens later, after you’ve turned notification back on again. It’s asynchronous.