apps: handle 'app-state-changed' move in shell-app-usage

commit 0af108211c moved which
object the app-state-changed signal is emitted from.

This commit updates shell-app-usage.c to keep up with the times.

https://bugzilla.gnome.org/show_bug.cgi?id=658503
This commit is contained in:
Ray Strode 2011-09-07 15:20:10 -04:00
parent 45a1ceaa54
commit 98649f9397

View File

@ -307,7 +307,7 @@ increment_usage_for_app (ShellAppUsage *self,
}
static void
on_app_state_changed (ShellWindowTracker *tracker,
on_app_state_changed (ShellAppSystem *app_system,
ShellApp *app,
gpointer user_data)
{
@ -391,6 +391,7 @@ shell_app_usage_init (ShellAppUsage *self)
char *shell_userdata_dir, *path;
GDBusConnection *session_bus;
ShellWindowTracker *tracker;
ShellAppSystem *app_system;
global = shell_global_get ();
@ -398,7 +399,9 @@ shell_app_usage_init (ShellAppUsage *self)
tracker = shell_window_tracker_get_default ();
g_signal_connect (tracker, "notify::focus-app", G_CALLBACK (on_focus_app_changed), self);
g_signal_connect (tracker, "app-state-changed", G_CALLBACK (on_app_state_changed), self);
app_system = shell_app_system_get_default ();
g_signal_connect (app_system, "app-state-changed", G_CALLBACK (on_app_state_changed), self);
session_bus = g_bus_get_sync (G_BUS_TYPE_SESSION, NULL, NULL);
self->session_proxy = g_dbus_proxy_new_sync (session_bus,