diff options
| author | SND\weimingzhi_cp <SND\weimingzhi_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97> | 2010-05-14 01:42:36 +0000 |
|---|---|---|
| committer | SND\weimingzhi_cp <SND\weimingzhi_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97> | 2010-05-14 01:42:36 +0000 |
| commit | dd25820ac8dfb3fa1168832db9bf56a1844e49ea (patch) | |
| tree | 63b53b3bdcdeb15ee675b63d44f19f7e0002b2c3 /gui | |
| parent | 1aea114c973f6ec8990fe29bfda40fca3432f636 (diff) | |
| download | pcsxr-dd25820ac8dfb3fa1168832db9bf56a1844e49ea.tar.gz | |
moved about dialog box out of glade2 file
git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@48009 e17a0e51-4ae3-4d35-97c3-1a29b211df97
Diffstat (limited to 'gui')
| -rw-r--r-- | gui/AboutDlg.c | 105 | ||||
| -rw-r--r-- | gui/AboutDlg.h | 24 | ||||
| -rw-r--r-- | gui/Gtk2Gui.c | 16 | ||||
| -rw-r--r-- | gui/Makefile.am | 3 | ||||
| -rw-r--r-- | gui/Makefile.in | 6 |
5 files changed, 137 insertions, 17 deletions
diff --git a/gui/AboutDlg.c b/gui/AboutDlg.c new file mode 100644 index 00000000..e69f4eb6 --- /dev/null +++ b/gui/AboutDlg.c @@ -0,0 +1,105 @@ +/* Pcsx - Pc Psx Emulator + * Copyright (C) 1999-2002 Pcsx Team + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1307 USA + */ + +#include "Linux.h" +#include <gtk/gtk.h> + +#define ABOUT_VERSION "svn" + +void RunAboutDialog(void) { + GtkWidget *AboutDlg; + + const gchar *authors[] = { + "PCSX-Reloaded Team:", + "edgbla <edgbla@yandex.ru>", + "Wei Mingzhi <whistler_wmz@users.sf.net>", + "", + "Contributors:", + "dario86", + "Firnis", + "Gabriele Gorla", + "Peter Collingbourne", + "shalma", + "Tristin Celestin", + "...and many others!", + "", + "PCSX-df Team:", + "Ryan Schultz <schultz.ryan@gmail.com>", + "Andrew Burton <adb@iinet.net.au>", + "Stephen Chao <stephen@digitalnexus.org>", + "Stefan Sikora <hoshy[AT]schrauberstube.de>", + "", + "PCSX Team:", + "Linuzappz <linuzappz@hotmail.com>", + "Shadow", + "Pete Bernert", + "NoComp", + "Nik3d", + NULL + }; + + const gchar *artists[] = { + "Ryan Schultz <schultz.ryan@gmail.com>", + "", + "Icon Design:", + "Romain Lafourcade", + NULL + }; + + const gchar *documenters[] = { + "Ryan Schultz <schultz.ryan@gmail.com>", + NULL + }; + + const gchar *copyright = N_( + "(c) 1999-2003 PCSX Team\n" + "(c) 2005-2009 PCSX-df Team\n" + "(c) 2009-2010 PCSX-Reloaded Team"); + + const gchar *license = N_( + "This program is free software; you can redistribute it and/or modify " + "it under the terms of the GNU General Public License as published by " + "the Free Software Foundation; either version 2 of the License, or " + "(at your option) any later version.\n" + "\n" + "This program is distributed in the hope that it will be useful, " + "but WITHOUT ANY WARRANTY; without even the implied warranty of " + "MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the " + "GNU General Public License for more details.\n" + "\n" + "You should have received a copy of the GNU General Public License " + "along with this program; if not, write to the Free Software " + "Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1307 USA."); + + AboutDlg = gtk_about_dialog_new(); + gtk_about_dialog_set_program_name(GTK_ABOUT_DIALOG(AboutDlg), "PCSX-Reloaded"); + gtk_about_dialog_set_version(GTK_ABOUT_DIALOG(AboutDlg), ABOUT_VERSION); + gtk_about_dialog_set_website(GTK_ABOUT_DIALOG(AboutDlg), "http://pcsxr.codeplex.com/"); + gtk_about_dialog_set_website_label(GTK_ABOUT_DIALOG(AboutDlg), "http://pcsxr.codeplex.com/"); + gtk_about_dialog_set_authors(GTK_ABOUT_DIALOG(AboutDlg), authors); + gtk_about_dialog_set_copyright(GTK_ABOUT_DIALOG(AboutDlg), _(copyright)); + gtk_about_dialog_set_documenters(GTK_ABOUT_DIALOG(AboutDlg), documenters); + gtk_about_dialog_set_artists(GTK_ABOUT_DIALOG(AboutDlg), artists); + gtk_about_dialog_set_translator_credits(GTK_ABOUT_DIALOG(AboutDlg), _("translator-credits")); + gtk_about_dialog_set_comments(GTK_ABOUT_DIALOG (AboutDlg), _("A PlayStation emulator.")); + gtk_about_dialog_set_license(GTK_ABOUT_DIALOG(AboutDlg), _(license)); + gtk_about_dialog_set_wrap_license(GTK_ABOUT_DIALOG(AboutDlg), TRUE); + + gtk_dialog_run(GTK_DIALOG(AboutDlg)); + gtk_widget_destroy(AboutDlg); +} diff --git a/gui/AboutDlg.h b/gui/AboutDlg.h new file mode 100644 index 00000000..e8b82aff --- /dev/null +++ b/gui/AboutDlg.h @@ -0,0 +1,24 @@ +/* Pcsx - Pc Psx Emulator + * Copyright (C) 1999-2002 Pcsx Team + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1307 USA + */ + +#ifndef ABOUTDLG_H +#define ABOUTDLG_H + +void RunAboutDialog(void); + +#endif diff --git a/gui/Gtk2Gui.c b/gui/Gtk2Gui.c index 0dff71e8..89da504f 100644 --- a/gui/Gtk2Gui.c +++ b/gui/Gtk2Gui.c @@ -38,6 +38,7 @@ #include "MemcardDlg.h" #include "ConfDlg.h" #include "DebugMemory.h" +#include "AboutDlg.h" // Functions Callbacks void OnFile_RunCd(); @@ -869,20 +870,7 @@ void on_states_save_other() { } void OnHelp_About(GtkWidget *widget, gpointer user_data) { - GladeXML *xml; - GtkWidget *about_dialog; - - xml = glade_xml_new(PACKAGE_DATA_DIR "pcsx.glade2", "AboutDlg", NULL); - - if (!xml) { - g_warning("We could not load the interface!"); - return; - } - - about_dialog = glade_xml_get_widget(xml, "AboutDlg"); - - gtk_dialog_run(GTK_DIALOG (about_dialog)); - gtk_widget_destroy(about_dialog); + RunAboutDialog(); } void SysMessage(const char *fmt, ...) { diff --git a/gui/Makefile.am b/gui/Makefile.am index b17d5e74..50e9e8f3 100644 --- a/gui/Makefile.am +++ b/gui/Makefile.am @@ -16,7 +16,8 @@ pcsx_SOURCES = \ MemcardDlg.c \ ConfDlg.c \ Cheat.c \ - DebugMemory.c + DebugMemory.c \ + AboutDlg.c pcsx_LDADD = \ $(GTK2_LIBS) $(GLADE2_LIBS) -lpthread -lz -lm -lXext -lXtst \ diff --git a/gui/Makefile.in b/gui/Makefile.in index adb67e1d..c262c296 100644 --- a/gui/Makefile.in +++ b/gui/Makefile.in @@ -50,7 +50,7 @@ am__installdirs = "$(DESTDIR)$(bindir)" PROGRAMS = $(bin_PROGRAMS) am_pcsx_OBJECTS = LnxMain.$(OBJEXT) Plugin.$(OBJEXT) Config.$(OBJEXT) \ Gtk2Gui.$(OBJEXT) MemcardDlg.$(OBJEXT) ConfDlg.$(OBJEXT) \ - Cheat.$(OBJEXT) DebugMemory.$(OBJEXT) + Cheat.$(OBJEXT) DebugMemory.$(OBJEXT) AboutDlg.$(OBJEXT) pcsx_OBJECTS = $(am_pcsx_OBJECTS) am__DEPENDENCIES_1 = pcsx_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ @@ -242,7 +242,8 @@ pcsx_SOURCES = \ MemcardDlg.c \ ConfDlg.c \ Cheat.c \ - DebugMemory.c + DebugMemory.c \ + AboutDlg.c pcsx_LDADD = \ $(GTK2_LIBS) $(GLADE2_LIBS) -lpthread -lz -lm -lXext -lXtst \ @@ -335,6 +336,7 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/AboutDlg.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Cheat.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ConfDlg.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Config.Po@am__quote@ |
