Fix WriteBackAllUsers ending a DB transaction without beginning one first.
Add checks for the transaction refcount going negative, or being left
at a non-zero value.
Purge cached user profile images after not being used for approx N days.
N currently defaults to 14.
Purging is currently done at termination.
Fix compilation when not using PCHs: missing includes.
Add X11 primary selection support to post window and panel items,
on supported platforms (X11, GTK, Motif).
Effectively a backport of http://trac.wxwidgets.org/changeset/70011
Resolves #1