Emit 'activated' signal when clicked on a media type, connected in linking
[laugh.git] / src / laugh-media.h
blob1bde455028f7fd38b7a1a783d0c7a6c498c3ab22
1 /*
2 * Laugh.
4 * An glib SMIL library.
6 * Authored By Koos Vriezen <koos.vriezen@gmail.com>
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either
11 * version 2 of the License, or (at your option) any later version.
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with this library; if not, write to the
20 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
21 * Boston, MA 02111-1307, USA.
24 #ifndef _LAUGH_MEDIA_H
25 #define _LAUGH_MEDIA_H
27 #include "laugh-dom.h"
29 G_BEGIN_DECLS
31 #define LAUGH_TYPE_MEDIA laugh_media_get_type()
33 #define LAUGH_MEDIA(obj) \
34 (G_TYPE_CHECK_INSTANCE_CAST ((obj), \
35 LAUGH_TYPE_MEDIA, LaughMedia))
37 #define LAUGH_TYPE_MEDIA_CLASS(klass) \
38 (G_TYPE_CHECK_CLASS_CAST ((klass), \
39 LAUGH_TYPE_MEDIA, LaughMediaClass))
41 #define LAUGH_IS_MEDIA(obj) \
42 (G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
43 LAUGH_TYPE_MEDIA))
45 #define LAUGH_IS_MEDIA_CLASS(klass) \
46 (G_TYPE_CHECK_CLASS_TYPE ((klass), \
47 LAUGH_TYPE_MEDIA))
49 #define LAUGH_MEDIA_GET_CLASS(obj) \
50 (G_TYPE_INSTANCE_GET_CLASS ((obj), \
51 LAUGH_TYPE_MEDIA, LaughMediaClass))
53 typedef struct _LaughMedia LaughMedia;
54 typedef struct _LaughMediaClass LaughMediaClass;
55 typedef struct _LaughMediaPrivate LaughMediaPrivate;
57 struct _LaughMedia
59 LaughNode parent;
61 /*< public >*/
62 LaughTimingSegment *timing_segment;
64 /*< private >*/
65 LaughMediaPrivate *priv;
68 struct _LaughMediaClass
70 LaughNodeClass parent_class;
72 void (*activated) (LaughNode *node, gint x, gint y);
75 GType laugh_media_get_type (void) G_GNUC_CONST;
77 LaughNode *laugh_media_new (LaughDocument *doc, LaughNodeTagId id,
78 GHashTable *attributes);
80 G_END_DECLS
82 #endif