appinfo: add g_app_info_set_as_last_used_for_type()
authorCosimo Cecchi <cosimoc@gnome.org>
Wed, 15 Dec 2010 16:56:22 +0000 (17:56 +0100)
committerCosimo Cecchi <cosimoc@gnome.org>
Mon, 20 Dec 2010 14:43:58 +0000 (15:43 +0100)
commit678bcad92c2a6350cd5dbf4ea3a567d99cf4c29d
tree79707f3dd66fe11efc8da23e6e1ffd9d019fb490
parent01ba7bd8e8984609d411b70a8ac9db4e8b64fb06
appinfo: add g_app_info_set_as_last_used_for_type()

This commit also changes (maintaining compatibility) the way
user-specified default applications are stored (as in, those for which
g_app_info_set_as_default_for_type() has been called.

We now store the default application for a content type in a new group
in the mimeapps.list keyfile, and "Added Associations" tracks only the
applications that have been added by the user, following a
most-recently-used first order.

This is useful in GtkAppChooser-like widgets to pre-select the last used
application when constructing a widget.

https://bugzilla.gnome.org/show_bug.cgi?id=636311
docs/reference/gio/gio-sections.txt
gio/gappinfo.c
gio/gappinfo.h
gio/gdesktopappinfo.c
gio/gio.symbols
gio/tests/desktop-app-info.c