blob: 1e84b8bbfc9e63c735b3200410bc45c79b977777 [file] [log] [blame]
aviau039001d2016-09-29 16:39:05 -04001/*
2 * Copyright (C) 2016 Savoir-faire Linux Inc.
3 * Author: Alexandre Viau <alexandre.viau@savoirfairelinux.com>
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 3 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 */
19
20#pragma once
21
22#include <gtk/gtk.h>
23
24class QModelIndex;
25class QString;
26class QVariant;
aviaufc213552016-11-01 12:39:39 -040027class ContactMethod;
aviau039001d2016-09-29 16:39:05 -040028
29G_BEGIN_DECLS
30
31#define WEBKIT_CHAT_CONTAINER_TYPE (webkit_chat_container_get_type ())
32#define WEBKIT_CHAT_CONTAINER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), WEBKIT_CHAT_CONTAINER_TYPE, WebKitChatContainer))
33#define WEBKIT_CHAT_CONTAINER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), WEBKIT_CHAT_CONTAINER_TYPE, WebKitChatContainerClass))
34#define IS_WEBKIT_CHAT_CONTAINER(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), WEBKIT_CHAT_CONTAINER_TYPE))
35#define IS_WEBKIT_CHAT_CONTAINER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), WEBKIT_CHAT_CONTAINER_TYPE))
36
37typedef struct _WebKitChatContainer WebKitChatContainer;
38typedef struct _WebKitChatContainerClass WebKitChatContainerClass;
39
aviaufc213552016-11-01 12:39:39 -040040GType webkit_chat_container_get_type (void) G_GNUC_CONST;
41GtkWidget* webkit_chat_container_new (void);
42void webkit_chat_container_clear (WebKitChatContainer *view);
43void webkit_chat_container_clear_sender_images (WebKitChatContainer *view);
44void webkit_chat_container_print_new_message (WebKitChatContainer *view, const QModelIndex &idx);
45void webkit_chat_container_update_message (WebKitChatContainer *view, const QModelIndex &idx);
46void webkit_chat_container_set_sender_image (WebKitChatContainer *view, ContactMethod *sender_contact_method, QVariant sender_image);
47gboolean webkit_chat_container_is_ready (WebKitChatContainer *view);
aviau039001d2016-09-29 16:39:05 -040048
49G_END_DECLS