Code tidy up in GNOME Control Center



Hi all,

I'm interested in modernising some of the GObject code in G-C-C and wanted to check no one is opposed to it / give a heads up.

In particular, I plan to do the following:
- Get the panel code more consistent between panels.
- Use modern boilerplate GObject code (i.e. G_DEFINE_*_TYPE).
- Use g_auto macros where possible to make code simpler and reduce memory leaks (much easier when using G_DEFINE_*_TYPE).
- Use more modern GtkBuilder integration.
- Fix up inconsistent whitespace usage (currently I see 2/4/8 spaces and tabs all mixed together) - lower priority.

Upsides:
- Make the code more consistent, which will encourage new code to be consistent.
- Make it more attractive to new developers.
- "Drain the swamp" a bit to make it harder for bugs to occur.

The downside of these changes is:
- Big diffs that can make is harder to compare to older branches and can require unmerged branches to be updated.
- Some risk of introducing new bugs (which is why I'd like to do it at the start of 3.28).

I've got a branch (wip/rancell/g-define-type) that replaces all the old GObject macros with G_DEFINE_*_TYPE which should give you some idea of the sort of changes.

If no opposition, I plan to commit these changes per-panel (probably simpler panels before the more complex ones). Please let me know if there's any panels that someone is working on that I should avoid / do later.

Thanks!
--Robert


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]