ephy-embed-container.h 2.91 KB
Newer Older
1
/* -*- Mode: C; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
Xan Lopez's avatar
Xan Lopez committed
2 3 4
/*
 *  Copyright © 2007 Xan Lopez
 *
Michael Catanzaro's avatar
Michael Catanzaro committed
5 6 7
 *  This file is part of Epiphany.
 *
 *  Epiphany is free software: you can redistribute it and/or modify
Xan Lopez's avatar
Xan Lopez committed
8
 *  it under the terms of the GNU General Public License as published by
Michael Catanzaro's avatar
Michael Catanzaro committed
9 10
 *  the Free Software Foundation, either version 3 of the License, or
 *  (at your option) any later version.
Xan Lopez's avatar
Xan Lopez committed
11
 *
Michael Catanzaro's avatar
Michael Catanzaro committed
12
 *  Epiphany is distributed in the hope that it will be useful,
Xan Lopez's avatar
Xan Lopez committed
13 14 15 16 17
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
Michael Catanzaro's avatar
Michael Catanzaro committed
18
 *  along with Epiphany.  If not, see <http://www.gnu.org/licenses/>.
Xan Lopez's avatar
Xan Lopez committed
19 20
 */

21
#pragma once
Xan Lopez's avatar
Xan Lopez committed
22 23

#include "ephy-embed.h"
24
#include "ephy-web-view.h"
Xan Lopez's avatar
Xan Lopez committed
25 26 27 28 29 30

#include <glib-object.h>
#include <glib.h>

G_BEGIN_DECLS

31
#define EPHY_TYPE_EMBED_CONTAINER (ephy_embed_container_get_type ())
32

33
G_DECLARE_INTERFACE (EphyEmbedContainer, ephy_embed_container, EPHY, EMBED_CONTAINER, GObject)
Xan Lopez's avatar
Xan Lopez committed
34

35
struct _EphyEmbedContainerInterface
Xan Lopez's avatar
Xan Lopez committed
36
{
37 38
  GTypeInterface parent_iface;

39 40 41 42
  gint (* add_child)               (EphyEmbedContainer *container,
                                    EphyEmbed *child,
                                    gint position,
                                    gboolean set_active);
Xan Lopez's avatar
Xan Lopez committed
43

44 45
  void (* set_active_child)        (EphyEmbedContainer *container,
                                    EphyEmbed *child);
Xan Lopez's avatar
Xan Lopez committed
46

47 48
  void (* remove_child)            (EphyEmbedContainer *container,
                                    EphyEmbed *child);
Xan Lopez's avatar
Xan Lopez committed
49 50 51

  EphyEmbed * (* get_active_child) (EphyEmbedContainer *container);

52
  GList * (* get_children)         (EphyEmbedContainer *container);
Xan Lopez's avatar
Xan Lopez committed
53

54
  gboolean (* get_is_popup)        (EphyEmbedContainer *container);
55 56

  guint (* get_n_children)         (EphyEmbedContainer *container);
Xan Lopez's avatar
Xan Lopez committed
57 58
};

59 60 61 62 63 64 65 66 67 68 69
gint              ephy_embed_container_add_child        (EphyEmbedContainer *container,
                                                         EphyEmbed          *child,
                                                         gint                position,
                                                         gboolean            set_active);
void              ephy_embed_container_set_active_child (EphyEmbedContainer *container,
                                                         EphyEmbed          *child);
void              ephy_embed_container_remove_child     (EphyEmbedContainer *container,
                                                         EphyEmbed          *child);
EphyEmbed *       ephy_embed_container_get_active_child (EphyEmbedContainer *container);
GList *           ephy_embed_container_get_children     (EphyEmbedContainer *container);
gboolean          ephy_embed_container_get_is_popup     (EphyEmbedContainer *container);
70
guint             ephy_embed_container_get_n_children   (EphyEmbedContainer *container);
Xan Lopez's avatar
Xan Lopez committed
71 72

G_END_DECLS