Search
lxdream.org :: lxdream/src/gui/gtkui.h :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/gui/gtkui.h
changeset 435:7a5d71e8560b
next437:2c259474b474
author nkeynes
date Wed Oct 10 11:02:04 2007 +0000 (12 years ago)
permissions -rw-r--r--
last change First cut of new GUI
file annotate diff log raw
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/src/gui/gtkui.h Wed Oct 10 11:02:04 2007 +0000
1.3 @@ -0,0 +1,80 @@
1.4 +/**
1.5 + * $Id: gtkui.h,v 1.1 2007-10-10 11:02:04 nkeynes Exp $
1.6 + *
1.7 + * Core GTK-based user interface
1.8 + *
1.9 + * Copyright (c) 2005 Nathan Keynes.
1.10 + *
1.11 + * This program is free software; you can redistribute it and/or modify
1.12 + * it under the terms of the GNU General Public License as published by
1.13 + * the Free Software Foundation; either version 2 of the License, or
1.14 + * (at your option) any later version.
1.15 + *
1.16 + * This program is distributed in the hope that it will be useful,
1.17 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
1.18 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1.19 + * GNU General Public License for more details.
1.20 + */
1.21 +
1.22 +#ifndef __lxdream_gtkui_H
1.23 +#define __lxdream_gtkui_H
1.24 +
1.25 +#include <gtk/gtk.h>
1.26 +#include "gui.h"
1.27 +#include "cpu.h"
1.28 +
1.29 +/********************* Top-level windows *********************/
1.30 +
1.31 +typedef struct main_window_info *main_window_t;
1.32 +typedef struct debug_window_info *debug_window_t;
1.33 +typedef struct mmio_window_info *mmio_window_t;
1.34 +
1.35 +/**
1.36 + * Construct and show the main window, returning an
1.37 + * opaque pointer to the window.
1.38 + */
1.39 +main_window_t main_window_new( const gchar *title );
1.40 +
1.41 +GtkWidget *main_window_get_renderarea( main_window_t win );
1.42 +void main_window_set_running( main_window_t win, gboolean running );
1.43 +void main_window_set_framerate( main_window_t win, float rate );
1.44 +
1.45 +debug_window_t debug_window_new();
1.46 +
1.47 +void debug_window_show( debug_window_t win, gboolean show );
1.48 +void debug_window_set_running( debug_window_t win, gboolean running );
1.49 +void debug_window_update(debug_window_t win);
1.50 +
1.51 +mmio_window_t mmio_window_new();
1.52 +
1.53 +void mmio_window_show( mmio_window_t win, gboolean show );
1.54 +
1.55 +/******************** Video driver hooks *********************/
1.56 +
1.57 +GtkWidget *gtk_gui_get_renderarea();
1.58 +
1.59 +/******************* Callback declarations *******************/
1.60 +
1.61 +void mount_action_callback( GtkAction *action, gpointer user_data);
1.62 +void reset_action_callback( GtkAction *action, gpointer user_data);
1.63 +void pause_action_callback( GtkAction *action, gpointer user_data);
1.64 +void resume_action_callback( GtkAction *action, gpointer user_data);
1.65 +void load_state_action_callback( GtkAction *action, gpointer user_data);
1.66 +void save_state_action_callback( GtkAction *action, gpointer user_data);
1.67 +void about_action_callback( GtkAction *action, gpointer user_data);
1.68 +void exit_action_callback( GtkAction *action, gpointer user_data);
1.69 +
1.70 +void audio_settings_callback( GtkAction *action, gpointer user_data);
1.71 +void controller_settings_callback( GtkAction *action, gpointer user_data);
1.72 +void network_settings_callback( GtkAction *action, gpointer user_data);
1.73 +void video_settings_callback( GtkAction *action, gpointer user_data);
1.74 +void fullscreen_toggle_callback( GtkToggleAction *action, gpointer user_data);
1.75 +
1.76 +/*************** Constant colour/font values *****************/
1.77 +extern PangoFontDescription *gui_fixed_font;
1.78 +extern GdkColor gui_colour_normal, gui_colour_changed, gui_colour_error;
1.79 +extern GdkColor gui_colour_warn, gui_colour_pc, gui_colour_debug;
1.80 +extern GdkColor gui_colour_trace, gui_colour_break, gui_colour_temp_break;
1.81 +extern GdkColor gui_colour_white;
1.82 +
1.83 +#endif /* __lxdream_gtkui_H */
.