Evince
Evince is a document viewer capable of displaying multiple and single page document formats like PDF and Postscript.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
ev-media.c File Reference
#include <config.h>
#include "ev-media.h"
+ Include dependency graph for ev-media.c:

Go to the source code of this file.

Data Structures

struct  _EvMediaPrivate
 

Functions

static void ev_media_finalize (GObject *object)
 
static void ev_media_class_init (EvMediaClass *klass)
 
static void ev_media_init (EvMedia *media)
 
EvMediaev_media_new_for_uri (EvPage *page, const gchar *uri)
 
const gchar * ev_media_get_uri (EvMedia *media)
 
guint ev_media_get_page_index (EvMedia *media)
 
gboolean ev_media_get_show_controls (EvMedia *media)
 
void ev_media_set_show_controls (EvMedia *media, gboolean show_controls)
 

Function Documentation

static void ev_media_class_init ( EvMediaClass klass)
static

Definition at line 43 of file ev-media.c.

44 {
45  GObjectClass *g_object_class = G_OBJECT_CLASS (klass);
46 
47  g_object_class->finalize = ev_media_finalize;
48 
49  g_type_class_add_private (g_object_class, sizeof (EvMediaPrivate));
50 }
static void ev_media_finalize ( GObject *  object)
static

Definition at line 33 of file ev-media.c.

34 {
35  EvMedia *media = EV_MEDIA (object);
36 
37  g_clear_pointer (&media->priv->uri, g_free);
38 
39  G_OBJECT_CLASS (ev_media_parent_class)->finalize (object);
40 }

+ Here is the caller graph for this function:

guint ev_media_get_page_index ( EvMedia media)

Definition at line 83 of file ev-media.c.

84 {
85  g_return_val_if_fail (EV_IS_MEDIA (media), 0);
86 
87  return media->priv->page;
88 }

+ Here is the caller graph for this function:

gboolean ev_media_get_show_controls ( EvMedia media)

Definition at line 91 of file ev-media.c.

92 {
93  g_return_val_if_fail (EV_IS_MEDIA (media), FALSE);
94 
95  return media->priv->show_controls;
96 }

+ Here is the caller graph for this function:

const gchar* ev_media_get_uri ( EvMedia media)

Definition at line 75 of file ev-media.c.

76 {
77  g_return_val_if_fail (EV_IS_MEDIA (media), NULL);
78 
79  return media->priv->uri;
80 }

+ Here is the caller graph for this function:

static void ev_media_init ( EvMedia media)
static

Definition at line 53 of file ev-media.c.

54 {
55  media->priv = G_TYPE_INSTANCE_GET_PRIVATE (media, EV_TYPE_MEDIA, EvMediaPrivate);
56 }
EvMedia* ev_media_new_for_uri ( EvPage page,
const gchar *  uri 
)

Definition at line 59 of file ev-media.c.

61 {
62  EvMedia *media;
63 
64  g_return_val_if_fail (EV_IS_PAGE (page), NULL);
65  g_return_val_if_fail (uri != NULL, NULL);
66 
67  media = EV_MEDIA (g_object_new (EV_TYPE_MEDIA, NULL));
68  media->priv->page = page->index;
69  media->priv->uri = g_strdup (uri);
70 
71  return media;
72 }

+ Here is the caller graph for this function:

void ev_media_set_show_controls ( EvMedia media,
gboolean  show_controls 
)

Definition at line 99 of file ev-media.c.

101 {
102  g_return_if_fail (EV_IS_MEDIA (media));
103 
104  media->priv->show_controls = show_controls;
105 }

+ Here is the caller graph for this function: