Add Friulian translation
[glib.git] / gio / gnotificationbackend.h
blobd26123a97657392bd1f0442ce35ccb52e3655418
1 /*
2 * Copyright © 2013 Lars Uebernickel
4 * This program is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU Lesser General Public License as published
6 * by the Free Software Foundation; either version 2 of the licence or (at
7 * your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General
15 * Public License along with this library; if not, see <http://www.gnu.org/licenses/>.
17 * Authors: Lars Uebernickel <lars@uebernic.de>
20 #ifndef __G_NOTIFICATION_BACKEND_H__
21 #define __G_NOTIFICATION_BACKEND_H__
23 #include <gio/giotypes.h>
25 G_BEGIN_DECLS
27 #define G_TYPE_NOTIFICATION_BACKEND (g_notification_backend_get_type ())
28 #define G_NOTIFICATION_BACKEND(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), G_TYPE_NOTIFICATION_BACKEND, GNotificationBackend))
29 #define G_IS_NOTIFICATION_BACKEND(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), G_TYPE_NOTIFICATION_BACKEND))
30 #define G_NOTIFICATION_BACKEND_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k), G_TYPE_NOTIFICATION_BACKEND, GNotificationBackendClass))
31 #define G_NOTIFICATION_BACKEND_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), G_TYPE_NOTIFICATION_BACKEND, GNotificationBackendClass))
33 #define G_NOTIFICATION_BACKEND_EXTENSION_POINT_NAME "gnotification-backend"
35 typedef struct _GNotificationBackend GNotificationBackend;
36 typedef struct _GNotificationBackendClass GNotificationBackendClass;
38 struct _GNotificationBackend
40 GObject parent_instance;
42 GApplication *application;
43 GDBusConnection *dbus_connection;
46 struct _GNotificationBackendClass
48 GObjectClass parent_class;
50 gboolean (*is_supported) (void);
52 void (*send_notification) (GNotificationBackend *backend,
53 const gchar *id,
54 GNotification *notification);
56 void (*withdraw_notification) (GNotificationBackend *backend,
57 const gchar *id);
60 GType g_notification_backend_get_type (void);
62 GNotificationBackend * g_notification_backend_new_default (GApplication *application);
64 void g_notification_backend_send_notification (GNotificationBackend *backend,
65 const gchar *id,
66 GNotification *notification);
68 void g_notification_backend_withdraw_notification (GNotificationBackend *backend,
69 const gchar *id);
71 G_END_DECLS
73 #endif