Back to index

bamf  0.2.120
Classes | Defines | Typedefs | Functions
bamf-tab-source.h File Reference
#include "bamf.h"
#include <glib.h>
#include <glib-object.h>
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  _BamfTabSourceClass
struct  _BamfTabSource

Defines

#define BAMF_TYPE_TAB_SOURCE   (bamf_tab_source_get_type ())
#define BAMF_TAB_SOURCE(obj)   (G_TYPE_CHECK_INSTANCE_CAST ((obj), BAMF_TYPE_TAB_SOURCE, BamfTabSource))
#define BAMF_IS_TAB_SOURCE(obj)   (G_TYPE_CHECK_INSTANCE_TYPE ((obj), BAMF_TYPE_TAB_SOURCE))
#define BAMF_TAB_SOURCE_CLASS(klass)   (G_TYPE_CHECK_CLASS_CAST ((klass), BAMF_TYPE_TAB_SOURCE, BamfTabSourceClass))
#define BAMF_IS_TAB_SOURCE_CLASS(klass)   (G_TYPE_CHECK_CLASS_TYPE ((klass), BAMF_TYPE_TAB_SOURCE))
#define BAMF_TAB_SOURCE_GET_CLASS(obj)   (G_TYPE_INSTANCE_GET_CLASS ((obj), BAMF_TYPE_TAB_SOURCE, BamfTabSourceClass))

Typedefs

typedef struct _BamfTabSource
typedef struct _BamfTabSourceClass
typedef struct _BamfTabSourcePrivate

Functions

GType bamf_tab_source_get_type (void) G_GNUC_CONST
char ** bamf_tab_source_tab_ids (BamfTabSource *self)
void bamf_tab_source_show_tab (BamfTabSource *self, char *id)
gchar * bamf_tab_source_get_tab_preview (BamfTabSource *self, char *id)
char * bamf_tab_source_get_tab_uri (BamfTabSource *self, char *id)
guint32 bamf_tab_source_get_tab_xid (BamfTabSource *self, char *id)
BamfTabSource * bamf_tab_source_new (char *bus, char *path)

Class Documentation

struct _BamfTabSource

Definition at line 45 of file bamf-tab-source.h.

Class Members
GObject parent
BamfTabSourcePrivate * priv

Define Documentation

#define BAMF_IS_TAB_SOURCE (   obj)    (G_TYPE_CHECK_INSTANCE_TYPE ((obj), BAMF_TYPE_TAB_SOURCE))

Definition at line 30 of file bamf-tab-source.h.

#define BAMF_IS_TAB_SOURCE_CLASS (   klass)    (G_TYPE_CHECK_CLASS_TYPE ((klass), BAMF_TYPE_TAB_SOURCE))

Definition at line 32 of file bamf-tab-source.h.

#define BAMF_TAB_SOURCE (   obj)    (G_TYPE_CHECK_INSTANCE_CAST ((obj), BAMF_TYPE_TAB_SOURCE, BamfTabSource))

Definition at line 29 of file bamf-tab-source.h.

#define BAMF_TAB_SOURCE_CLASS (   klass)    (G_TYPE_CHECK_CLASS_CAST ((klass), BAMF_TYPE_TAB_SOURCE, BamfTabSourceClass))

Definition at line 31 of file bamf-tab-source.h.

#define BAMF_TAB_SOURCE_GET_CLASS (   obj)    (G_TYPE_INSTANCE_GET_CLASS ((obj), BAMF_TYPE_TAB_SOURCE, BamfTabSourceClass))

Definition at line 33 of file bamf-tab-source.h.

Definition at line 28 of file bamf-tab-source.h.


Typedef Documentation

typedef struct _BamfTabSource

Definition at line 35 of file bamf-tab-source.h.

typedef struct _BamfTabSourceClass

Definition at line 36 of file bamf-tab-source.h.

typedef struct _BamfTabSourcePrivate

Definition at line 37 of file bamf-tab-source.h.


Function Documentation

gchar* bamf_tab_source_get_tab_preview ( BamfTabSource *  self,
char *  id 
)

Definition at line 83 of file bamf-tab-source.c.

{
  g_return_val_if_fail (BAMF_IS_TAB_SOURCE (source), NULL);

  if (BAMF_TAB_SOURCE_GET_CLASS (source)->tab_preview)
    return BAMF_TAB_SOURCE_GET_CLASS (source)->tab_preview (source, tab_id);

  return NULL;
}

Here is the call graph for this function:

Here is the caller graph for this function:

char* bamf_tab_source_get_tab_uri ( BamfTabSource *  self,
char *  id 
)

Definition at line 95 of file bamf-tab-source.c.

{
  g_return_val_if_fail (BAMF_IS_TAB_SOURCE (source), NULL);

  if (BAMF_TAB_SOURCE_GET_CLASS (source)->tab_uri)
    return BAMF_TAB_SOURCE_GET_CLASS (source)->tab_uri (source, tab_id);

  return NULL;
}

Here is the call graph for this function:

guint32 bamf_tab_source_get_tab_xid ( BamfTabSource *  self,
char *  id 
)

Definition at line 107 of file bamf-tab-source.c.

{
  g_return_val_if_fail (BAMF_IS_TAB_SOURCE (source), 0);

  if (BAMF_TAB_SOURCE_GET_CLASS (source)->tab_xid)
    return BAMF_TAB_SOURCE_GET_CLASS (source)->tab_xid (source, tab_id);

  return 0;
}

Here is the call graph for this function:

Here is the caller graph for this function:

GType bamf_tab_source_get_type ( void  )
BamfTabSource* bamf_tab_source_new ( char *  bus,
char *  path 
)

Definition at line 447 of file bamf-tab-source.c.

{
  BamfTabSource *self;
  self = (BamfTabSource *) g_object_new (BAMF_TYPE_TAB_SOURCE,
                                         "path", path,
                                         "bus", bus,
                                         NULL);

  return self;
}

Here is the caller graph for this function:

void bamf_tab_source_show_tab ( BamfTabSource *  self,
char *  id 
)

Definition at line 81 of file bamf-tab-source.c.

{
  BamfTabSourcePrivate *priv;
  GError *error = NULL;

  g_return_if_fail (BAMF_IS_TAB_SOURCE (self));
  priv = self->priv;

  if (!bamf_dbus_browser__call_show_tab_sync (priv->proxy, id, NULL, &error))
    {
      g_warning ("Failed to show tab: %s", error->message);
      g_error_free (error);
    }
}

Here is the call graph for this function:

char** bamf_tab_source_tab_ids ( BamfTabSource *  self)

Definition at line 61 of file bamf-tab-source.c.

{
  BamfTabSourcePrivate *priv;
  GError *error = NULL;
  char **ids = NULL;

  g_return_val_if_fail (BAMF_IS_TAB_SOURCE (self), NULL);
  priv = self->priv;

  if (!bamf_dbus_browser__call_tab_ids_sync (priv->proxy, &ids, NULL, &error))
    {
      g_warning ("Failed to get tab ids: %s", error->message);
      g_error_free (error);
      return NULL;
    }

  return ids;
}

Here is the call graph for this function: