maemo-ui/src/mmyth_epg_grid_widget.h
author rosfran
Thu May 03 16:07:36 2007 +0100 (2007-05-03)
branchtrunk
changeset 626 9df91aff5479
parent 20 7174e23f7617
child 754 cb885ee44618
permissions -rw-r--r--
[svn r632] Added new LiveTV test case.
renatofilho@20
     1
#ifndef __MMYTH_EPG_GRID_WIDGET_H__
renatofilho@20
     2
#define __MMYTH_EPG_GRID_WIDGET_H__
renatofilho@20
     3
renatofilho@20
     4
#include <glib-object.h>
renatofilho@20
     5
#include <gdk/gdk.h>
renatofilho@20
     6
#include <gtk/gtkvbox.h>
renatofilho@20
     7
#include <gtk/gtkeventbox.h>
renatofilho@20
     8
rosfran@208
     9
#include <gmyth/gmyth_common.h>
rosfran@208
    10
#include <gmyth/gmyth_backendinfo.h>
renatofilho@20
    11
#define MAX_DISPLAY_CHANS 4
renatofilho@20
    12
renatofilho@20
    13
G_BEGIN_DECLS
renatofilho@20
    14
renatofilho@20
    15
#define MMYTH_EPG_GRID_WIDGET_TYPE               (mmyth_epg_grid_widget_get_type ())
renatofilho@20
    16
#define MMYTH_EPG_GRID_WIDGET(obj)               (GTK_CHECK_CAST ((obj), MMYTH_EPG_GRID_WIDGET_TYPE, MMythEpgGridWidget))
renatofilho@20
    17
#define MMYTH_EPG_GRID_WIDGET_CLASS(klass)       (GTK_CHECK_CLASS_CAST ((klass), MMYTH_EPG_GRID_WIDGET_TYPE, MMythEpgGridWidgetClass))
renatofilho@20
    18
#define IS_MMYTH_EPG_GRID_WIDGET(obj)            (GTK_CHECK_TYPE ((obj), MMYTH_EPG_GRID_WIDGET_TYPE))
renatofilho@20
    19
#define IS_MMYTH_EPG_GRID_WIDGET_CLASS(klass)    (GTK_CHECK_CLASS_TYPE ((klass), MMYTH_EPG_GRID_WIDGET_TYPE))
renatofilho@20
    20
#define MMYTH_EPG_GRID_WIDGET_GET_CLASS(obj)     (G_TYPE_INSTANCE_GET_CLASS ((obj), MMYTH_EPG_GRID_WIDGET_TYPE, MMythEpgGridWidgetClass))
renatofilho@20
    21
#define MMYTH_EPG_GRID_WIDGET_GET_PRIVATE(obj)   (G_TYPE_INSTANCE_GET_PRIVATE ((obj), MMYTH_EPG_GRID_WIDGET_TYPE, MMythEpgGridWidgetPrivate))
renatofilho@20
    22
renatofilho@20
    23
renatofilho@20
    24
typedef struct _MMythEpgGridWidget         MMythEpgGridWidget;
renatofilho@20
    25
typedef struct _MMythEpgGridWidgetClass    MMythEpgGridWidgetClass;
renatofilho@20
    26
typedef struct _MMythEpgGridWidgetPrivate  MMythEpgGridWidgetPrivate;
renatofilho@20
    27
renatofilho@20
    28
struct _MMythEpgGridWidgetClass
renatofilho@20
    29
{
renatofilho@20
    30
  GtkEventBoxClass parent_class;
renatofilho@20
    31
renatofilho@20
    32
  /* callbacks */
renatofilho@20
    33
  /* no one for now */
renatofilho@20
    34
};
renatofilho@20
    35
renatofilho@20
    36
struct _MMythEpgGridWidget
renatofilho@20
    37
{
renatofilho@20
    38
    GtkEventBox event_box;
renatofilho@20
    39
renatofilho@20
    40
    /* Selected Widgets Logic*/
renatofilho@20
    41
    /* List os Service Model in the current view
renatofilho@20
    42
     * the data of this list are GList for the programs
renatofilho@20
    43
     * of each service */
renatofilho@20
    44
    GList *epg_view_model;
renatofilho@20
    45
renatofilho@20
    46
    /* Selected Schedule Item*/
renatofilho@20
    47
    GList *selected_grid_item;  
rosfran@208
    48
renatofilho@20
    49
};
renatofilho@20
    50
renatofilho@20
    51
renatofilho@20
    52
GType          mmyth_epg_grid_widget_get_type        (void);
renatofilho@20
    53
GtkWidget*     mmyth_epg_grid_widget_new             (void);
renatofilho@20
    54
/*DVBHScheduleEvent*    mmyth_epg_grid_get_selected_schedule  (MMythEpgGridWidget * object);*/
renatofilho@20
    55
void           mmyth_epg_grid_widget_update_service  (MMythEpgGridWidget * object, 
renatofilho@20
    56
                                                      GList *epg_grid_item_node);
renatofilho@20
    57
gboolean       mmyth_epg_grid_widget_key_press       (MMythEpgGridWidget * object, 
renatofilho@20
    58
                                                      GtkWidget * widget, 
renatofilho@20
    59
                                                      GdkEventKey * event);
renatofilho@20
    60
renatofilho@20
    61
typedef struct _EpgGridItem EpgGridItem;
renatofilho@20
    62
renatofilho@20
    63
/* FIXME: auxiliary struct */
renatofilho@20
    64
struct _EpgGridItem {
renatofilho@20
    65
renatofilho@20
    66
    GMythProgramInfo *proginfo;
renatofilho@20
    67
    GtkWidget *event_box;
renatofilho@20
    68
renatofilho@20
    69
    /* for callback purposes */
renatofilho@20
    70
    MMythEpgGridWidget *object;
renatofilho@20
    71
};
renatofilho@20
    72
renatofilho@20
    73
G_END_DECLS
renatofilho@20
    74
renatofilho@20
    75
#endif /* __MMYTH_EPG_GRID_WIDGET_H__ */