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