2
Tracks which menu items get used by users and works to promote those
3
higher in the search rankings than others.
5
Copyright 2011 Canonical Ltd.
8
Ted Gould <ted@canonical.com>
10
This program is free software: you can redistribute it and/or modify it
11
under the terms of the GNU General Public License version 3, as published
12
by the Free Software Foundation.
14
This program is distributed in the hope that it will be useful, but
15
WITHOUT ANY WARRANTY; without even the implied warranties of
16
MERCHANTABILITY, SATISFACTORY QUALITY, or FITNESS FOR A PARTICULAR
17
PURPOSE. See the GNU General Public License for more details.
19
You should have received a copy of the GNU General Public License along
20
with this program. If not, see <http://www.gnu.org/licenses/>.
23
#ifndef __USAGE_TRACKER_H__
24
#define __USAGE_TRACKER_H__
26
#include <glib-object.h>
30
#define USAGE_TRACKER_TYPE (usage_tracker_get_type ())
31
#define USAGE_TRACKER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), USAGE_TRACKER_TYPE, UsageTracker))
32
#define USAGE_TRACKER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), USAGE_TRACKER_TYPE, UsageTrackerClass))
33
#define IS_USAGE_TRACKER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), USAGE_TRACKER_TYPE))
34
#define IS_USAGE_TRACKER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), USAGE_TRACKER_TYPE))
35
#define USAGE_TRACKER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), USAGE_TRACKER_TYPE, UsageTrackerClass))
37
typedef struct _UsageTracker UsageTracker;
38
typedef struct _UsageTrackerClass UsageTrackerClass;
39
typedef struct _UsageTrackerPrivate UsageTrackerPrivate;
41
struct _UsageTrackerClass {
42
GObjectClass parent_class;
45
struct _UsageTracker {
48
UsageTrackerPrivate * priv;
51
GType usage_tracker_get_type (void);
52
UsageTracker * usage_tracker_new (void);
53
void usage_tracker_mark_usage (UsageTracker * self, const gchar * application, const gchar * entry);
54
guint usage_tracker_get_usage (UsageTracker * self, const gchar * application, const gchar * entry);
55
UsageTracker * usage_tracker_get_instance (void);