QA: replace direct access to GtkWidget->window member by function call
[QA] Fix large memory leak when removing DEM layers.
[QA] Fix memory leak in treeview tooltips and selection.
[QA] Fix memory leaks on reading in Viking files.

Don't set these string variables to NULL too early!
Otherwise testing it's value means it previously didn't call the free function.
[QA] Fix memory leaks in usage of the clipboard.

Refactor use of gdk_atom_name() since this returns an allocated string.
[QA] Fix incorrect iterator usage.
[QA] Fix large memory leak on viewing Track Properties.
[QA] Fix new tracks not shown after split called from the Track Properties dialog.
[QA] Fix memory leak on deleting TrackWaypoint layers.
[QA] Fix several memory leaks on program closure.

Not particularly important since the program is ending,
 but it should be done and aids tracing any other remaining memory faults.
[QA] Fix misc small memory leaks.
[QA] Fix name memory leaks in TrackWaypoint operations.
[QA] Fix memory leak in sorting layers.
[QA] Fix memory leak in drawing new tracks/routes.