maemo-ui/src/mmyth_epg_grid_widget.h
author renatofilho
Wed Jul 04 21:32:20 2007 +0100 (2007-07-04)
branchtrunk
changeset 782 8e3f5544aa24
parent 208 c3c073032757
permissions -rw-r--r--
[svn r788] removed progress log
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
#define MMYTH_EPG_GRID_WIDGET_TYPE               (mmyth_epg_grid_widget_get_type ())
renatofilho@20
    15
#define MMYTH_EPG_GRID_WIDGET(obj)               (GTK_CHECK_CAST ((obj), MMYTH_EPG_GRID_WIDGET_TYPE, MMythEpgGridWidget))
renatofilho@20
    16
#define MMYTH_EPG_GRID_WIDGET_CLASS(klass)       (GTK_CHECK_CLASS_CAST ((klass), MMYTH_EPG_GRID_WIDGET_TYPE, MMythEpgGridWidgetClass))
renatofilho@20
    17
#define IS_MMYTH_EPG_GRID_WIDGET(obj)            (GTK_CHECK_TYPE ((obj), MMYTH_EPG_GRID_WIDGET_TYPE))
renatofilho@20
    18
#define IS_MMYTH_EPG_GRID_WIDGET_CLASS(klass)    (GTK_CHECK_CLASS_TYPE ((klass), MMYTH_EPG_GRID_WIDGET_TYPE))
renatofilho@20
    19
#define MMYTH_EPG_GRID_WIDGET_GET_CLASS(obj)     (G_TYPE_INSTANCE_GET_CLASS ((obj), MMYTH_EPG_GRID_WIDGET_TYPE, MMythEpgGridWidgetClass))
renatofilho@20
    20
#define MMYTH_EPG_GRID_WIDGET_GET_PRIVATE(obj)   (G_TYPE_INSTANCE_GET_PRIVATE ((obj), MMYTH_EPG_GRID_WIDGET_TYPE, MMythEpgGridWidgetPrivate))
renatofilho@754
    21
typedef struct _MMythEpgGridWidget MMythEpgGridWidget;
renatofilho@754
    22
typedef struct _MMythEpgGridWidgetClass MMythEpgGridWidgetClass;
renatofilho@754
    23
typedef struct _MMythEpgGridWidgetPrivate MMythEpgGridWidgetPrivate;
renatofilho@20
    24
renatofilho@754
    25
struct _MMythEpgGridWidgetClass {
renatofilho@754
    26
    GtkEventBoxClass parent_class;
renatofilho@20
    27
renatofilho@754
    28
    /*
renatofilho@754
    29
     * callbacks 
renatofilho@754
    30
     */
renatofilho@754
    31
    /*
renatofilho@754
    32
     * no one for now 
renatofilho@754
    33
     */
renatofilho@20
    34
};
renatofilho@20
    35
renatofilho@754
    36
struct _MMythEpgGridWidget {
renatofilho@754
    37
    GtkEventBox     event_box;
renatofilho@20
    38
renatofilho@754
    39
    /*
renatofilho@754
    40
     * Selected Widgets Logic
renatofilho@754
    41
     */
renatofilho@754
    42
    /*
renatofilho@754
    43
     * List os Service Model in the current view the data of this list are 
renatofilho@754
    44
     * GList for the programs of each service 
renatofilho@754
    45
     */
renatofilho@754
    46
    GList          *epg_view_model;
renatofilho@20
    47
renatofilho@754
    48
    /*
renatofilho@754
    49
     * Selected Schedule Item
renatofilho@754
    50
     */
renatofilho@754
    51
    GList          *selected_grid_item;
rosfran@208
    52
renatofilho@20
    53
};
renatofilho@20
    54
renatofilho@20
    55
renatofilho@754
    56
GType           mmyth_epg_grid_widget_get_type(void);
renatofilho@754
    57
GtkWidget      *mmyth_epg_grid_widget_new(void);
renatofilho@754
    58
/*
renatofilho@754
    59
 * DVBHScheduleEvent* mmyth_epg_grid_get_selected_schedule
renatofilho@754
    60
 * (MMythEpgGridWidget * object);
renatofilho@754
    61
 */
renatofilho@754
    62
void            mmyth_epg_grid_widget_update_service(MMythEpgGridWidget *
renatofilho@754
    63
                                                     object,
renatofilho@754
    64
                                                     GList *
renatofilho@754
    65
                                                     epg_grid_item_node);
renatofilho@754
    66
gboolean        mmyth_epg_grid_widget_key_press(MMythEpgGridWidget *
renatofilho@754
    67
                                                object, GtkWidget * widget,
renatofilho@754
    68
                                                GdkEventKey * event);
renatofilho@20
    69
renatofilho@20
    70
typedef struct _EpgGridItem EpgGridItem;
renatofilho@20
    71
renatofilho@754
    72
/*
renatofilho@754
    73
 * FIXME: auxiliary struct 
renatofilho@754
    74
 */
renatofilho@20
    75
struct _EpgGridItem {
renatofilho@20
    76
renatofilho@20
    77
    GMythProgramInfo *proginfo;
renatofilho@754
    78
    GtkWidget      *event_box;
renatofilho@20
    79
renatofilho@754
    80
    /*
renatofilho@754
    81
     * for callback purposes 
renatofilho@754
    82
     */
renatofilho@20
    83
    MMythEpgGridWidget *object;
renatofilho@20
    84
};
renatofilho@20
    85
renatofilho@20
    86
G_END_DECLS
renatofilho@754
    87
#endif                          /* __MMYTH_EPG_GRID_WIDGET_H__ */