[qtcontacts-sqlite] Correct the derivation of global presence

Global presence should be updated when non-global presence details are
not excluded by the definition mask.  Also, unknown presence state
is never a better presence than any other defined value.
Merge pull request #93 from matthewvogt/global-presence

[qtcontacts-sqlite] Correct the derivation of global presence