1 /* ev-document-layers.c
2 * this file is part of evince, a gnome document_links viewer
4 * Copyright (C) 2008 Carlos Garcia Campos <carlosgc@gnome.org>
6 * Evince is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * Evince is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
23 #include "ev-document-layers.h"
26 ev_document_layers_get_type (void)
28 static GType type = 0;
30 if (G_UNLIKELY (type == 0)) {
31 const GTypeInfo our_info = {
32 sizeof (EvDocumentLayersIface),
37 type = g_type_register_static (G_TYPE_INTERFACE,
39 &our_info, (GTypeFlags)0);
46 ev_document_layers_has_layers (EvDocumentLayers *document_layers)
48 EvDocumentLayersIface *iface = EV_DOCUMENT_LAYERS_GET_IFACE (document_layers);
50 return iface->has_layers (document_layers);
54 ev_document_layers_get_layers (EvDocumentLayers *document_layers)
56 EvDocumentLayersIface *iface = EV_DOCUMENT_LAYERS_GET_IFACE (document_layers);
58 return iface->get_layers (document_layers);
62 ev_document_layers_show_layer (EvDocumentLayers *document_layers,
65 EvDocumentLayersIface *iface = EV_DOCUMENT_LAYERS_GET_IFACE (document_layers);
67 iface->show_layer (document_layers, layer);
71 ev_document_layers_hide_layer (EvDocumentLayers *document_layers,
74 EvDocumentLayersIface *iface = EV_DOCUMENT_LAYERS_GET_IFACE (document_layers);
76 iface->hide_layer (document_layers, layer);
80 ev_document_layers_layer_is_visible (EvDocumentLayers *document_layers,
83 EvDocumentLayersIface *iface = EV_DOCUMENT_LAYERS_GET_IFACE (document_layers);
85 return iface->layer_is_visible (document_layers, layer);