mirror of https://github.com/PCSX2/pcsx2.git
Begin work on renovating the Null plugins. (On the Linux side, anyways, though some of that will spill over to the Windows side.) Starting with FWnull.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@1105 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
45bb6f3d2f
commit
74e0e786b7
|
@ -1,147 +0,0 @@
|
||||||
/* FWnull
|
|
||||||
* Copyright (C) 2004-2005 PCSX2 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <stdlib.h>
|
|
||||||
#include <string.h>
|
|
||||||
#include <errno.h>
|
|
||||||
|
|
||||||
#include "FW.h"
|
|
||||||
|
|
||||||
const unsigned char version = PS2E_FW_VERSION;
|
|
||||||
const unsigned char revision = 0;
|
|
||||||
const unsigned char build = 4; // increase that with each version
|
|
||||||
|
|
||||||
static char *libraryName = "FWnull Driver";
|
|
||||||
|
|
||||||
s8 *fwregs;
|
|
||||||
|
|
||||||
#define fwRs32(mem) (*(s32*)&fwregs[(mem) & 0xffff])
|
|
||||||
#define fwRu32(mem) (*(u32*)&fwregs[(mem) & 0xffff])
|
|
||||||
|
|
||||||
|
|
||||||
u32 CALLBACK PS2EgetLibType() {
|
|
||||||
return PS2E_LT_FW;
|
|
||||||
}
|
|
||||||
|
|
||||||
char* CALLBACK PS2EgetLibName() {
|
|
||||||
return libraryName;
|
|
||||||
}
|
|
||||||
|
|
||||||
u32 CALLBACK PS2EgetLibVersion2(u32 type) {
|
|
||||||
return (version<<16) | (revision<<8) | build;
|
|
||||||
}
|
|
||||||
|
|
||||||
void __Log(char *fmt, ...) {
|
|
||||||
va_list list;
|
|
||||||
|
|
||||||
if (!conf.Log || fwLog == NULL) return;
|
|
||||||
|
|
||||||
va_start(list, fmt);
|
|
||||||
vfprintf(fwLog, fmt, list);
|
|
||||||
va_end(list);
|
|
||||||
}
|
|
||||||
|
|
||||||
s32 CALLBACK FWinit() {
|
|
||||||
LoadConfig();
|
|
||||||
#ifdef FW_LOG
|
|
||||||
fwLog = fopen("logs/fwLog.txt", "w");
|
|
||||||
if (fwLog) setvbuf(fwLog, NULL, _IONBF, 0);
|
|
||||||
FW_LOG("FWnull plugin version %d,%d\n",revision,build);
|
|
||||||
FW_LOG("FW init\n");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
fwregs = (s8*)malloc(0x10000);
|
|
||||||
if (fwregs == NULL) {
|
|
||||||
SysMessage("Error allocating Memory\n"); return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CALLBACK FWshutdown() {
|
|
||||||
free(fwregs);
|
|
||||||
|
|
||||||
#ifdef FW_LOG
|
|
||||||
if (fwLog) fclose(fwLog);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
s32 CALLBACK FWopen(void *pDsp) {
|
|
||||||
#ifdef FW_LOG
|
|
||||||
FW_LOG("FW open\n");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef _WIN32
|
|
||||||
#else
|
|
||||||
//Display* dsp = *(Display**)pDsp;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
void CALLBACK FWclose() {
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
u32 CALLBACK FWread32(u32 addr) {
|
|
||||||
u32 ret=0;
|
|
||||||
|
|
||||||
switch (addr) {
|
|
||||||
case 0x1f808410:
|
|
||||||
ret = 0x8;
|
|
||||||
break;
|
|
||||||
|
|
||||||
default:
|
|
||||||
ret = fwRu32(addr);
|
|
||||||
}
|
|
||||||
#ifdef FW_LOG
|
|
||||||
FW_LOG("FW read mem 0x%x: 0x%x\n", addr, ret);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void CALLBACK FWwrite32(u32 addr, u32 value) {
|
|
||||||
switch (addr) {
|
|
||||||
default:
|
|
||||||
fwRu32(addr) = value;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
#ifdef FW_LOG
|
|
||||||
FW_LOG("FW write mem 0x%x: 0x%x\n", addr, value);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
void CALLBACK FWirqCallback(void (*callback)()) {
|
|
||||||
FWirq = callback;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
s32 CALLBACK FWfreeze(int mode, freezeData *data) {
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
s32 CALLBACK FWtest() {
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/* FWnull
|
/* FWnull
|
||||||
* Copyright (C) 2004-2005 PCSX2 Team
|
* Copyright (C) 2004-2009 PCSX2 Team
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
@ -16,14 +16,16 @@
|
||||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifndef __FW_H__
|
#ifndef __FW_H__
|
||||||
#define __FW_H__
|
#define __FW_H__
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
|
extern "C"
|
||||||
|
{
|
||||||
#define FWdefs
|
#define FWdefs
|
||||||
#include "PS2Edefs.h"
|
#include "PS2Edefs.h"
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
|
|
||||||
|
@ -35,25 +37,32 @@
|
||||||
#include <gtk/gtk.h>
|
#include <gtk/gtk.h>
|
||||||
#include <X11/Xlib.h>
|
#include <X11/Xlib.h>
|
||||||
|
|
||||||
#define __inline inline
|
#endif
|
||||||
|
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
#define EXPORT_C_(type) extern "C" __declspec(dllexport) type CALLBACK
|
||||||
|
#else
|
||||||
|
#define EXPORT_C_(type) extern "C" type
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define FW_LOG __Log
|
#define FW_LOG __Log
|
||||||
|
|
||||||
typedef struct {
|
#define fwRs32(mem) (*(s32*)&fwregs[(mem) & 0xffff])
|
||||||
int Log;
|
#define fwRu32(mem) (*(u32*)&fwregs[(mem) & 0xffff])
|
||||||
|
|
||||||
|
typedef struct
|
||||||
|
{
|
||||||
|
int Log;
|
||||||
} Config;
|
} Config;
|
||||||
|
|
||||||
Config conf;
|
extern Config conf;
|
||||||
void (*FWirq)();
|
extern FILE *fwLog;
|
||||||
|
|
||||||
void SaveConfig();
|
extern void (*FWirq)();
|
||||||
void LoadConfig();
|
|
||||||
|
|
||||||
FILE *fwLog;
|
extern void __Log(char *fmt, ...);
|
||||||
void __Log(char *fmt, ...);
|
extern void SysMessage(char *fmt, ...);
|
||||||
|
extern void SaveConfig();
|
||||||
void SysMessage(char *fmt, ...);
|
extern void LoadConfig();
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/* FireWire
|
/* FWnull
|
||||||
* Copyright (C) 2002-2004 FireWire Team
|
* Copyright (C) 2004-2009 PCSX2 Team
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
@ -20,23 +20,33 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
#include <sys/stat.h>
|
||||||
#include <gtk/gtk.h>
|
#include <gtk/gtk.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
|
#include <string>
|
||||||
|
using namespace std;
|
||||||
|
|
||||||
#include "interface.h"
|
|
||||||
#include "support.h"
|
|
||||||
#include "callbacks.h"
|
|
||||||
#include "FW.h"
|
#include "FW.h"
|
||||||
#include "Config.h"
|
#include "Config.h"
|
||||||
|
|
||||||
GtkWidget *MsgDlg;
|
extern "C"
|
||||||
|
{
|
||||||
|
#include "interface.h"
|
||||||
|
#include "support.h"
|
||||||
|
//#include "callbacks.h"
|
||||||
|
}
|
||||||
|
|
||||||
void OnMsg_Ok() {
|
GtkWidget *MsgDlg, *About, *Conf;
|
||||||
|
extern string s_strIniPath;
|
||||||
|
|
||||||
|
void OnMsg_Ok()
|
||||||
|
{
|
||||||
gtk_widget_destroy(MsgDlg);
|
gtk_widget_destroy(MsgDlg);
|
||||||
gtk_main_quit();
|
gtk_main_quit();
|
||||||
}
|
}
|
||||||
|
|
||||||
void cfgSysMessage(char *fmt, ...) {
|
void cfgSysMessage(char *fmt, ...)
|
||||||
|
{
|
||||||
GtkWidget *Ok,*Txt;
|
GtkWidget *Ok,*Txt;
|
||||||
GtkWidget *Box,*Box1;
|
GtkWidget *Box,*Box1;
|
||||||
va_list list;
|
va_list list;
|
||||||
|
@ -46,7 +56,7 @@ void cfgSysMessage(char *fmt, ...) {
|
||||||
vsprintf(msg, fmt, list);
|
vsprintf(msg, fmt, list);
|
||||||
va_end(list);
|
va_end(list);
|
||||||
|
|
||||||
if (msg[strlen(msg)-1] == '\n') msg[strlen(msg)-1] = 0;
|
if (msg[strlen(msg) - 1] == '\n') msg[strlen(msg)-1] = 0;
|
||||||
|
|
||||||
MsgDlg = gtk_window_new (GTK_WINDOW_POPUP);
|
MsgDlg = gtk_window_new (GTK_WINDOW_POPUP);
|
||||||
gtk_window_set_position(GTK_WINDOW(MsgDlg), GTK_WIN_POS_CENTER);
|
gtk_window_set_position(GTK_WINDOW(MsgDlg), GTK_WIN_POS_CENTER);
|
||||||
|
@ -77,21 +87,19 @@ void cfgSysMessage(char *fmt, ...) {
|
||||||
gtk_main();
|
gtk_main();
|
||||||
}
|
}
|
||||||
|
|
||||||
GtkWidget *About;
|
void OnAbout_Ok(GtkButton *button, gpointer user_data)
|
||||||
|
{
|
||||||
void OnAbout_Ok(GtkButton *button, gpointer user_data) {
|
|
||||||
gtk_widget_destroy(About);
|
gtk_widget_destroy(About);
|
||||||
gtk_main_quit();
|
gtk_main_quit();
|
||||||
}
|
}
|
||||||
|
|
||||||
void CFGabout() {
|
void CFGabout()
|
||||||
|
{
|
||||||
About = create_About();
|
About = create_About();
|
||||||
gtk_widget_show_all(About);
|
gtk_widget_show_all(About);
|
||||||
gtk_main();
|
gtk_main();
|
||||||
}
|
}
|
||||||
|
|
||||||
GtkWidget *Conf;
|
|
||||||
|
|
||||||
void OnConf_Ok(GtkButton *button, gpointer user_data) {
|
void OnConf_Ok(GtkButton *button, gpointer user_data) {
|
||||||
SaveConfig();
|
SaveConfig();
|
||||||
|
|
||||||
|
@ -99,12 +107,14 @@ void OnConf_Ok(GtkButton *button, gpointer user_data) {
|
||||||
gtk_main_quit();
|
gtk_main_quit();
|
||||||
}
|
}
|
||||||
|
|
||||||
void OnConf_Cancel(GtkButton *button, gpointer user_data) {
|
void OnConf_Cancel(GtkButton *button, gpointer user_data)
|
||||||
|
{
|
||||||
gtk_widget_destroy(Conf);
|
gtk_widget_destroy(Conf);
|
||||||
gtk_main_quit();
|
gtk_main_quit();
|
||||||
}
|
}
|
||||||
|
|
||||||
void CFGconfigure() {
|
void CFGconfigure()
|
||||||
|
{
|
||||||
Conf = create_Config();
|
Conf = create_Config();
|
||||||
|
|
||||||
LoadConfig();
|
LoadConfig();
|
||||||
|
@ -119,7 +129,7 @@ long CFGmessage(char *msg) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int main(int argc, char *argv[]) {
|
/*int main(int argc, char *argv[]) {
|
||||||
gtk_init(NULL, NULL);
|
gtk_init(NULL, NULL);
|
||||||
|
|
||||||
if (!strcmp(argv[1], "configure")) {
|
if (!strcmp(argv[1], "configure")) {
|
||||||
|
@ -131,4 +141,39 @@ int main(int argc, char *argv[]) {
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
}*/
|
||||||
|
|
||||||
|
void LoadConfig()
|
||||||
|
{
|
||||||
|
FILE *f;
|
||||||
|
char cfg[255];
|
||||||
|
|
||||||
|
strcpy(cfg, s_strIniPath.c_str());
|
||||||
|
f = fopen(cfg, "r");
|
||||||
|
if (f == NULL)
|
||||||
|
{
|
||||||
|
printf("failed to open %s\n", s_strIniPath.c_str());
|
||||||
|
SaveConfig();//save and return
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//fscanf(f, "options = %hhx\n", &confOptions);
|
||||||
|
fclose(f);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void SaveConfig()
|
||||||
|
{
|
||||||
|
FILE *f;
|
||||||
|
char cfg[255];
|
||||||
|
|
||||||
|
strcpy(cfg, s_strIniPath.c_str());
|
||||||
|
f = fopen(cfg,"w");
|
||||||
|
if (f == NULL)
|
||||||
|
{
|
||||||
|
printf("failed to open %s\n", s_strIniPath.c_str());
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//fprintf(f, "options = %hhx\n", confOptions);
|
||||||
|
fclose(f);
|
||||||
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/* USBlinuz
|
/* FWnull
|
||||||
* Copyright (C) 2002-2004 USBlinuz Team
|
* Copyright (C) 2004-2009 PCSX2 Team
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
@ -18,3 +18,8 @@
|
||||||
|
|
||||||
void SaveConf();
|
void SaveConf();
|
||||||
void LoadConf();
|
void LoadConf();
|
||||||
|
|
||||||
|
extern long CFGmessage(char *msg);
|
||||||
|
extern void CFGconfigure();
|
||||||
|
extern void cfgSysMessage(char *fmt, ...);
|
||||||
|
extern void CFGabout();
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/* FireWire
|
/* FWnull
|
||||||
* Copyright (C) 2002-2004 FireWire Team
|
* Copyright (C) 2004-2009 PCSX2 Team
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
@ -26,10 +26,11 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
#include "FW.h"
|
#include "FW.h"
|
||||||
|
#include "Config.h"
|
||||||
|
|
||||||
int ExecCfg(char *arg)
|
int ExecCfg(char *arg)
|
||||||
{
|
{
|
||||||
char cfg[256];
|
/*char cfg[256];
|
||||||
struct stat buf;
|
struct stat buf;
|
||||||
|
|
||||||
strcpy(cfg, "./cfgFWnull");
|
strcpy(cfg, "./cfgFWnull");
|
||||||
|
@ -61,7 +62,7 @@ int ExecCfg(char *arg)
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("cfgFWnull file not found!\n");
|
printf("cfgFWnull file not found!\n");
|
||||||
return -1;
|
return -1;*/
|
||||||
}
|
}
|
||||||
|
|
||||||
void SysMessage(char *fmt, ...)
|
void SysMessage(char *fmt, ...)
|
||||||
|
@ -74,25 +75,28 @@ void SysMessage(char *fmt, ...)
|
||||||
vsprintf(msg, fmt, list);
|
vsprintf(msg, fmt, list);
|
||||||
va_end(list);
|
va_end(list);
|
||||||
|
|
||||||
sprintf(cmd, "message \"%s\"", msg);
|
//sprintf(cmd, "message \"%s\"", msg);
|
||||||
ExecCfg(cmd);
|
cfgSysMessage(msg);
|
||||||
|
//ExecCfg(cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FWconfigure()
|
void FWconfigure()
|
||||||
{
|
{
|
||||||
char *file;
|
//char *file;
|
||||||
getcwd(file, ArraySize(file));
|
//getcwd(file, ArraySize(file));
|
||||||
chdir("plugins");
|
//chdir("plugins");
|
||||||
ExecCfg("configure");
|
//ExecCfg("configure");
|
||||||
chdir(file);
|
//chdir(file);
|
||||||
|
CFGconfigure();
|
||||||
}
|
}
|
||||||
|
|
||||||
void FWabout()
|
void FWabout()
|
||||||
{
|
{
|
||||||
char *file;
|
//char *file;
|
||||||
getcwd(file, ArraySize(file));
|
//getcwd(file, ArraySize(file));
|
||||||
chdir("plugins");
|
//chdir("plugins");
|
||||||
ExecCfg("about");
|
//ExecCfg("about");
|
||||||
chdir(file);
|
//chdir(file);
|
||||||
|
CFGabout();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/* FireWire
|
/* FWnull
|
||||||
* Copyright (C) 2002-2004 USBlinuz Team
|
* Copyright (C) 2004-2009 PCSX2 Team
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
@ -15,37 +15,3 @@
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
#include <string.h>
|
|
||||||
#include <unistd.h>
|
|
||||||
#include <sys/stat.h>
|
|
||||||
|
|
||||||
#include "FW.h"
|
|
||||||
|
|
||||||
void LoadConfig() {
|
|
||||||
FILE *f;
|
|
||||||
char cfg[256];
|
|
||||||
|
|
||||||
sprintf(cfg, "%s/.PS2E/FWnull.cfg", getenv("HOME"));
|
|
||||||
f = fopen(cfg, "r");
|
|
||||||
if (f == NULL) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
fclose(f);
|
|
||||||
}
|
|
||||||
|
|
||||||
void SaveConfig() {
|
|
||||||
FILE *f;
|
|
||||||
char cfg[256];
|
|
||||||
|
|
||||||
sprintf(cfg, "%s/.PS2E", getenv("HOME"));
|
|
||||||
mkdir(cfg, 0755);
|
|
||||||
sprintf(cfg, "%s/.PS2E/FWnull.cfg", getenv("HOME"));
|
|
||||||
f = fopen(cfg, "w");
|
|
||||||
if (f == NULL)
|
|
||||||
return;
|
|
||||||
fclose(f);
|
|
||||||
}
|
|
||||||
|
|
|
@ -1,34 +0,0 @@
|
||||||
#ifdef HAVE_CONFIG_H
|
|
||||||
# include <config.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <gtk/gtk.h>
|
|
||||||
|
|
||||||
#include "callbacks.h"
|
|
||||||
#include "interface.h"
|
|
||||||
#include "support.h"
|
|
||||||
|
|
||||||
|
|
||||||
void
|
|
||||||
OnConf_Ok (GtkButton *button,
|
|
||||||
gpointer user_data)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void
|
|
||||||
OnConf_Cancel (GtkButton *button,
|
|
||||||
gpointer user_data)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void
|
|
||||||
OnAbout_Ok (GtkButton *button,
|
|
||||||
gpointer user_data)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
|
@ -1,300 +1,443 @@
|
||||||
<?xml version="1.0"?>
|
<?xml version="1.0" standalone="no"?> <!--*- mode: xml -*-->
|
||||||
<GTK-Interface>
|
<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
|
||||||
|
|
||||||
<project>
|
<glade-interface>
|
||||||
<name>FireWire</name>
|
|
||||||
<program_name>dev9linuz</program_name>
|
|
||||||
<directory></directory>
|
|
||||||
<source_directory></source_directory>
|
|
||||||
<pixmaps_directory>pixmaps</pixmaps_directory>
|
|
||||||
<language>C</language>
|
|
||||||
<gnome_support>False</gnome_support>
|
|
||||||
<gettext_support>False</gettext_support>
|
|
||||||
<output_main_file>False</output_main_file>
|
|
||||||
<output_build_files>False</output_build_files>
|
|
||||||
<backup_source_files>False</backup_source_files>
|
|
||||||
</project>
|
|
||||||
|
|
||||||
<widget>
|
<widget class="GtkWindow" id="Config">
|
||||||
<class>GtkWindow</class>
|
<property name="border_width">5</property>
|
||||||
<name>Config</name>
|
<property name="visible">True</property>
|
||||||
<border_width>5</border_width>
|
<property name="title" translatable="yes">DEV9config</property>
|
||||||
<title>DEV9config</title>
|
<property name="type">GTK_WINDOW_TOPLEVEL</property>
|
||||||
<type>GTK_WINDOW_TOPLEVEL</type>
|
<property name="window_position">GTK_WIN_POS_NONE</property>
|
||||||
<position>GTK_WIN_POS_CENTER</position>
|
<property name="modal">False</property>
|
||||||
<modal>False</modal>
|
<property name="resizable">True</property>
|
||||||
<allow_shrink>False</allow_shrink>
|
<property name="destroy_with_parent">False</property>
|
||||||
<allow_grow>True</allow_grow>
|
<property name="decorated">True</property>
|
||||||
<auto_shrink>False</auto_shrink>
|
<property name="skip_taskbar_hint">False</property>
|
||||||
|
<property name="skip_pager_hint">False</property>
|
||||||
|
<property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property>
|
||||||
|
<property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
|
||||||
|
<property name="focus_on_map">True</property>
|
||||||
|
<property name="urgency_hint">False</property>
|
||||||
|
|
||||||
<widget>
|
<child>
|
||||||
<class>GtkVBox</class>
|
<widget class="GtkVBox" id="vbox1">
|
||||||
<name>vbox1</name>
|
<property name="border_width">5</property>
|
||||||
<border_width>5</border_width>
|
<property name="visible">True</property>
|
||||||
<homogeneous>False</homogeneous>
|
<property name="homogeneous">False</property>
|
||||||
<spacing>5</spacing>
|
<property name="spacing">5</property>
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkFrame</class>
|
|
||||||
<name>frame2</name>
|
|
||||||
<label>Ethernet</label>
|
|
||||||
<label_xalign>0</label_xalign>
|
|
||||||
<shadow_type>GTK_SHADOW_ETCHED_IN</shadow_type>
|
|
||||||
<child>
|
<child>
|
||||||
<padding>0</padding>
|
<widget class="GtkFrame" id="frame2">
|
||||||
<expand>True</expand>
|
<property name="visible">True</property>
|
||||||
<fill>True</fill>
|
<property name="label_xalign">0</property>
|
||||||
|
<property name="label_yalign">0.5</property>
|
||||||
|
<property name="shadow_type">GTK_SHADOW_ETCHED_IN</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkHBox" id="hbox1">
|
||||||
|
<property name="border_width">5</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="homogeneous">True</property>
|
||||||
|
<property name="spacing">5</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkLabel" id="label4">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="label" translatable="yes">Device:</property>
|
||||||
|
<property name="use_underline">False</property>
|
||||||
|
<property name="use_markup">False</property>
|
||||||
|
<property name="justify">GTK_JUSTIFY_CENTER</property>
|
||||||
|
<property name="wrap">False</property>
|
||||||
|
<property name="selectable">False</property>
|
||||||
|
<property name="xalign">0.5</property>
|
||||||
|
<property name="yalign">0.5</property>
|
||||||
|
<property name="xpad">0</property>
|
||||||
|
<property name="ypad">0</property>
|
||||||
|
<property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
|
||||||
|
<property name="width_chars">-1</property>
|
||||||
|
<property name="single_line_mode">False</property>
|
||||||
|
<property name="angle">0</property>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="padding">0</property>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">False</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkCombo" id="GtkCombo_Eth">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="value_in_list">False</property>
|
||||||
|
<property name="allow_empty">True</property>
|
||||||
|
<property name="case_sensitive">False</property>
|
||||||
|
<property name="enable_arrow_keys">True</property>
|
||||||
|
<property name="enable_arrows_always">False</property>
|
||||||
|
|
||||||
|
<child internal-child="entry">
|
||||||
|
<widget class="GtkEntry" id="combo-entry1">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_focus">True</property>
|
||||||
|
<property name="editable">True</property>
|
||||||
|
<property name="visibility">True</property>
|
||||||
|
<property name="max_length">0</property>
|
||||||
|
<property name="text" translatable="yes"></property>
|
||||||
|
<property name="has_frame">True</property>
|
||||||
|
<property name="invisible_char">*</property>
|
||||||
|
<property name="activates_default">False</property>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child internal-child="list">
|
||||||
|
<widget class="GtkList" id="convertwidget1">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="selection_mode">GTK_SELECTION_BROWSE</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkListItem" id="convertwidget2">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkLabel" id="convertwidget3">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="label" translatable="yes"></property>
|
||||||
|
<property name="use_underline">False</property>
|
||||||
|
<property name="use_markup">False</property>
|
||||||
|
<property name="justify">GTK_JUSTIFY_LEFT</property>
|
||||||
|
<property name="wrap">False</property>
|
||||||
|
<property name="selectable">False</property>
|
||||||
|
<property name="xalign">0</property>
|
||||||
|
<property name="yalign">0.5</property>
|
||||||
|
<property name="xpad">0</property>
|
||||||
|
<property name="ypad">0</property>
|
||||||
|
<property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
|
||||||
|
<property name="width_chars">-1</property>
|
||||||
|
<property name="single_line_mode">False</property>
|
||||||
|
<property name="angle">0</property>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="padding">0</property>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">False</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkLabel" id="label1">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="label" translatable="yes">Ethernet</property>
|
||||||
|
<property name="use_underline">False</property>
|
||||||
|
<property name="use_markup">False</property>
|
||||||
|
<property name="justify">GTK_JUSTIFY_LEFT</property>
|
||||||
|
<property name="wrap">False</property>
|
||||||
|
<property name="selectable">False</property>
|
||||||
|
<property name="xalign">0.5</property>
|
||||||
|
<property name="yalign">0.5</property>
|
||||||
|
<property name="xpad">0</property>
|
||||||
|
<property name="ypad">0</property>
|
||||||
|
<property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
|
||||||
|
<property name="width_chars">-1</property>
|
||||||
|
<property name="single_line_mode">False</property>
|
||||||
|
<property name="angle">0</property>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="type">label_item</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="padding">0</property>
|
||||||
|
<property name="expand">True</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkHBox</class>
|
|
||||||
<name>hbox1</name>
|
|
||||||
<border_width>5</border_width>
|
|
||||||
<homogeneous>True</homogeneous>
|
|
||||||
<spacing>5</spacing>
|
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkLabel</class>
|
|
||||||
<name>label4</name>
|
|
||||||
<label>Device:</label>
|
|
||||||
<justify>GTK_JUSTIFY_CENTER</justify>
|
|
||||||
<wrap>False</wrap>
|
|
||||||
<xalign>0.5</xalign>
|
|
||||||
<yalign>0.5</yalign>
|
|
||||||
<xpad>0</xpad>
|
|
||||||
<ypad>0</ypad>
|
|
||||||
<child>
|
|
||||||
<padding>0</padding>
|
|
||||||
<expand>False</expand>
|
|
||||||
<fill>False</fill>
|
|
||||||
</child>
|
|
||||||
</widget>
|
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkCombo</class>
|
|
||||||
<name>GtkCombo_Eth</name>
|
|
||||||
<width>130</width>
|
|
||||||
<value_in_list>False</value_in_list>
|
|
||||||
<ok_if_empty>True</ok_if_empty>
|
|
||||||
<case_sensitive>False</case_sensitive>
|
|
||||||
<use_arrows>True</use_arrows>
|
|
||||||
<use_arrows_always>False</use_arrows_always>
|
|
||||||
<items></items>
|
|
||||||
<child>
|
|
||||||
<padding>0</padding>
|
|
||||||
<expand>False</expand>
|
|
||||||
<fill>False</fill>
|
|
||||||
</child>
|
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkEntry</class>
|
|
||||||
<child_name>GtkCombo:entry</child_name>
|
|
||||||
<name>combo-entry1</name>
|
|
||||||
<can_focus>True</can_focus>
|
|
||||||
<editable>True</editable>
|
|
||||||
<text_visible>True</text_visible>
|
|
||||||
<text_max_length>0</text_max_length>
|
|
||||||
<text></text>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkFrame</class>
|
|
||||||
<name>frame3</name>
|
|
||||||
<label>Hdd</label>
|
|
||||||
<label_xalign>0</label_xalign>
|
|
||||||
<shadow_type>GTK_SHADOW_ETCHED_IN</shadow_type>
|
|
||||||
<child>
|
<child>
|
||||||
<padding>0</padding>
|
<widget class="GtkFrame" id="frame3">
|
||||||
<expand>True</expand>
|
<property name="visible">True</property>
|
||||||
<fill>True</fill>
|
<property name="label_xalign">0</property>
|
||||||
|
<property name="label_yalign">0.5</property>
|
||||||
|
<property name="shadow_type">GTK_SHADOW_ETCHED_IN</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkHBox" id="hbox2">
|
||||||
|
<property name="border_width">5</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="homogeneous">True</property>
|
||||||
|
<property name="spacing">5</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkLabel" id="label5">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="label" translatable="yes">Device:</property>
|
||||||
|
<property name="use_underline">False</property>
|
||||||
|
<property name="use_markup">False</property>
|
||||||
|
<property name="justify">GTK_JUSTIFY_CENTER</property>
|
||||||
|
<property name="wrap">False</property>
|
||||||
|
<property name="selectable">False</property>
|
||||||
|
<property name="xalign">0.5</property>
|
||||||
|
<property name="yalign">0.5</property>
|
||||||
|
<property name="xpad">0</property>
|
||||||
|
<property name="ypad">0</property>
|
||||||
|
<property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
|
||||||
|
<property name="width_chars">-1</property>
|
||||||
|
<property name="single_line_mode">False</property>
|
||||||
|
<property name="angle">0</property>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="padding">0</property>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">False</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkCombo" id="GtkCombo_Hdd">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="value_in_list">False</property>
|
||||||
|
<property name="allow_empty">True</property>
|
||||||
|
<property name="case_sensitive">False</property>
|
||||||
|
<property name="enable_arrow_keys">True</property>
|
||||||
|
<property name="enable_arrows_always">False</property>
|
||||||
|
|
||||||
|
<child internal-child="entry">
|
||||||
|
<widget class="GtkEntry" id="entry1">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_focus">True</property>
|
||||||
|
<property name="editable">True</property>
|
||||||
|
<property name="visibility">True</property>
|
||||||
|
<property name="max_length">0</property>
|
||||||
|
<property name="text" translatable="yes"></property>
|
||||||
|
<property name="has_frame">True</property>
|
||||||
|
<property name="invisible_char">*</property>
|
||||||
|
<property name="activates_default">False</property>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child internal-child="list">
|
||||||
|
<widget class="GtkList" id="convertwidget4">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="selection_mode">GTK_SELECTION_BROWSE</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkListItem" id="convertwidget5">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkLabel" id="convertwidget6">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="label" translatable="yes"></property>
|
||||||
|
<property name="use_underline">False</property>
|
||||||
|
<property name="use_markup">False</property>
|
||||||
|
<property name="justify">GTK_JUSTIFY_LEFT</property>
|
||||||
|
<property name="wrap">False</property>
|
||||||
|
<property name="selectable">False</property>
|
||||||
|
<property name="xalign">0</property>
|
||||||
|
<property name="yalign">0.5</property>
|
||||||
|
<property name="xpad">0</property>
|
||||||
|
<property name="ypad">0</property>
|
||||||
|
<property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
|
||||||
|
<property name="width_chars">-1</property>
|
||||||
|
<property name="single_line_mode">False</property>
|
||||||
|
<property name="angle">0</property>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="padding">0</property>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">False</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkLabel" id="label15">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="label" translatable="yes">Hdd</property>
|
||||||
|
<property name="use_underline">False</property>
|
||||||
|
<property name="use_markup">False</property>
|
||||||
|
<property name="justify">GTK_JUSTIFY_LEFT</property>
|
||||||
|
<property name="wrap">False</property>
|
||||||
|
<property name="selectable">False</property>
|
||||||
|
<property name="xalign">0.5</property>
|
||||||
|
<property name="yalign">0.5</property>
|
||||||
|
<property name="xpad">0</property>
|
||||||
|
<property name="ypad">0</property>
|
||||||
|
<property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
|
||||||
|
<property name="width_chars">-1</property>
|
||||||
|
<property name="single_line_mode">False</property>
|
||||||
|
<property name="angle">0</property>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="type">label_item</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="padding">0</property>
|
||||||
|
<property name="expand">True</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkHBox</class>
|
|
||||||
<name>hbox2</name>
|
|
||||||
<border_width>5</border_width>
|
|
||||||
<homogeneous>True</homogeneous>
|
|
||||||
<spacing>5</spacing>
|
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkLabel</class>
|
|
||||||
<name>label5</name>
|
|
||||||
<label>Device:</label>
|
|
||||||
<justify>GTK_JUSTIFY_CENTER</justify>
|
|
||||||
<wrap>False</wrap>
|
|
||||||
<xalign>0.5</xalign>
|
|
||||||
<yalign>0.5</yalign>
|
|
||||||
<xpad>0</xpad>
|
|
||||||
<ypad>0</ypad>
|
|
||||||
<child>
|
|
||||||
<padding>0</padding>
|
|
||||||
<expand>False</expand>
|
|
||||||
<fill>False</fill>
|
|
||||||
</child>
|
|
||||||
</widget>
|
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkCombo</class>
|
|
||||||
<name>GtkCombo_Hdd</name>
|
|
||||||
<width>130</width>
|
|
||||||
<value_in_list>False</value_in_list>
|
|
||||||
<ok_if_empty>True</ok_if_empty>
|
|
||||||
<case_sensitive>False</case_sensitive>
|
|
||||||
<use_arrows>True</use_arrows>
|
|
||||||
<use_arrows_always>False</use_arrows_always>
|
|
||||||
<items></items>
|
|
||||||
<child>
|
|
||||||
<padding>0</padding>
|
|
||||||
<expand>False</expand>
|
|
||||||
<fill>False</fill>
|
|
||||||
</child>
|
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkEntry</class>
|
|
||||||
<child_name>GtkCombo:entry</child_name>
|
|
||||||
<name>entry1</name>
|
|
||||||
<can_focus>True</can_focus>
|
|
||||||
<editable>True</editable>
|
|
||||||
<text_visible>True</text_visible>
|
|
||||||
<text_max_length>0</text_max_length>
|
|
||||||
<text></text>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkHButtonBox</class>
|
|
||||||
<name>hbuttonbox1</name>
|
|
||||||
<layout_style>GTK_BUTTONBOX_DEFAULT_STYLE</layout_style>
|
|
||||||
<spacing>30</spacing>
|
|
||||||
<child_min_width>85</child_min_width>
|
|
||||||
<child_min_height>27</child_min_height>
|
|
||||||
<child_ipad_x>7</child_ipad_x>
|
|
||||||
<child_ipad_y>0</child_ipad_y>
|
|
||||||
<child>
|
<child>
|
||||||
<padding>0</padding>
|
<widget class="GtkHButtonBox" id="hbuttonbox1">
|
||||||
<expand>True</expand>
|
<property name="visible">True</property>
|
||||||
<fill>True</fill>
|
<property name="layout_style">GTK_BUTTONBOX_DEFAULT_STYLE</property>
|
||||||
|
<property name="spacing">30</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkButton" id="button1">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_default">True</property>
|
||||||
|
<property name="can_focus">True</property>
|
||||||
|
<property name="label" translatable="yes">Ok</property>
|
||||||
|
<property name="use_underline">True</property>
|
||||||
|
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||||
|
<property name="focus_on_click">True</property>
|
||||||
|
<signal name="clicked" handler="OnConf_Ok"/>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkButton" id="button2">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_default">True</property>
|
||||||
|
<property name="can_focus">True</property>
|
||||||
|
<property name="label" translatable="yes">Cancel</property>
|
||||||
|
<property name="use_underline">True</property>
|
||||||
|
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||||
|
<property name="focus_on_click">True</property>
|
||||||
|
<signal name="clicked" handler="OnConf_Cancel"/>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="padding">0</property>
|
||||||
|
<property name="expand">True</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
</packing>
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkButton</class>
|
|
||||||
<name>button1</name>
|
|
||||||
<can_default>True</can_default>
|
|
||||||
<can_focus>True</can_focus>
|
|
||||||
<signal>
|
|
||||||
<name>clicked</name>
|
|
||||||
<handler>OnConf_Ok</handler>
|
|
||||||
<last_modification_time>Sat, 06 Apr 2002 17:07:56 GMT</last_modification_time>
|
|
||||||
</signal>
|
|
||||||
<label>Ok</label>
|
|
||||||
<relief>GTK_RELIEF_NORMAL</relief>
|
|
||||||
</widget>
|
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkButton</class>
|
|
||||||
<name>button2</name>
|
|
||||||
<can_default>True</can_default>
|
|
||||||
<can_focus>True</can_focus>
|
|
||||||
<signal>
|
|
||||||
<name>clicked</name>
|
|
||||||
<handler>OnConf_Cancel</handler>
|
|
||||||
<last_modification_time>Sat, 06 Apr 2002 17:08:08 GMT</last_modification_time>
|
|
||||||
</signal>
|
|
||||||
<label>Cancel</label>
|
|
||||||
<relief>GTK_RELIEF_NORMAL</relief>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
</widget>
|
||||||
</widget>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
|
|
||||||
<widget>
|
<widget class="GtkWindow" id="About">
|
||||||
<class>GtkWindow</class>
|
<property name="border_width">5</property>
|
||||||
<name>About</name>
|
<property name="visible">True</property>
|
||||||
<border_width>5</border_width>
|
<property name="title" translatable="yes">DEV9about</property>
|
||||||
<title>DEV9about</title>
|
<property name="type">GTK_WINDOW_TOPLEVEL</property>
|
||||||
<type>GTK_WINDOW_TOPLEVEL</type>
|
<property name="window_position">GTK_WIN_POS_NONE</property>
|
||||||
<position>GTK_WIN_POS_CENTER</position>
|
<property name="modal">False</property>
|
||||||
<modal>False</modal>
|
<property name="resizable">True</property>
|
||||||
<allow_shrink>False</allow_shrink>
|
<property name="destroy_with_parent">False</property>
|
||||||
<allow_grow>True</allow_grow>
|
<property name="decorated">True</property>
|
||||||
<auto_shrink>False</auto_shrink>
|
<property name="skip_taskbar_hint">False</property>
|
||||||
|
<property name="skip_pager_hint">False</property>
|
||||||
|
<property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property>
|
||||||
|
<property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
|
||||||
|
<property name="focus_on_map">True</property>
|
||||||
|
<property name="urgency_hint">False</property>
|
||||||
|
|
||||||
<widget>
|
<child>
|
||||||
<class>GtkVBox</class>
|
<widget class="GtkVBox" id="vbox2">
|
||||||
<name>vbox2</name>
|
<property name="border_width">5</property>
|
||||||
<border_width>5</border_width>
|
<property name="visible">True</property>
|
||||||
<homogeneous>False</homogeneous>
|
<property name="homogeneous">False</property>
|
||||||
<spacing>5</spacing>
|
<property name="spacing">5</property>
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkLabel</class>
|
|
||||||
<name>label2</name>
|
|
||||||
<label>FireWire Driver</label>
|
|
||||||
<justify>GTK_JUSTIFY_CENTER</justify>
|
|
||||||
<wrap>False</wrap>
|
|
||||||
<xalign>0.5</xalign>
|
|
||||||
<yalign>0.5</yalign>
|
|
||||||
<xpad>0</xpad>
|
|
||||||
<ypad>0</ypad>
|
|
||||||
<child>
|
<child>
|
||||||
<padding>0</padding>
|
<widget class="GtkLabel" id="label2">
|
||||||
<expand>False</expand>
|
<property name="visible">True</property>
|
||||||
<fill>False</fill>
|
<property name="label" translatable="yes">FireWire Driver</property>
|
||||||
</child>
|
<property name="use_underline">False</property>
|
||||||
</widget>
|
<property name="use_markup">False</property>
|
||||||
|
<property name="justify">GTK_JUSTIFY_CENTER</property>
|
||||||
<widget>
|
<property name="wrap">False</property>
|
||||||
<class>GtkLabel</class>
|
<property name="selectable">False</property>
|
||||||
<name>label3</name>
|
<property name="xalign">0.5</property>
|
||||||
<label>Author: linuzappz <linuzappz@hotmail.com></label>
|
<property name="yalign">0.5</property>
|
||||||
<justify>GTK_JUSTIFY_LEFT</justify>
|
<property name="xpad">0</property>
|
||||||
<wrap>False</wrap>
|
<property name="ypad">0</property>
|
||||||
<xalign>0.5</xalign>
|
<property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
|
||||||
<yalign>0.5</yalign>
|
<property name="width_chars">-1</property>
|
||||||
<xpad>0</xpad>
|
<property name="single_line_mode">False</property>
|
||||||
<ypad>0</ypad>
|
<property name="angle">0</property>
|
||||||
<child>
|
</widget>
|
||||||
<padding>0</padding>
|
<packing>
|
||||||
<expand>False</expand>
|
<property name="padding">0</property>
|
||||||
<fill>False</fill>
|
<property name="expand">False</property>
|
||||||
</child>
|
<property name="fill">False</property>
|
||||||
</widget>
|
</packing>
|
||||||
|
|
||||||
<widget>
|
|
||||||
<class>GtkHButtonBox</class>
|
|
||||||
<name>hbuttonbox2</name>
|
|
||||||
<layout_style>GTK_BUTTONBOX_DEFAULT_STYLE</layout_style>
|
|
||||||
<spacing>30</spacing>
|
|
||||||
<child_min_width>85</child_min_width>
|
|
||||||
<child_min_height>27</child_min_height>
|
|
||||||
<child_ipad_x>7</child_ipad_x>
|
|
||||||
<child_ipad_y>0</child_ipad_y>
|
|
||||||
<child>
|
|
||||||
<padding>0</padding>
|
|
||||||
<expand>True</expand>
|
|
||||||
<fill>True</fill>
|
|
||||||
</child>
|
</child>
|
||||||
|
|
||||||
<widget>
|
<child>
|
||||||
<class>GtkButton</class>
|
<widget class="GtkLabel" id="label3">
|
||||||
<name>button3</name>
|
<property name="visible">True</property>
|
||||||
<can_default>True</can_default>
|
<property name="label" translatable="yes">Author: linuzappz <linuzappz@hotmail.com></property>
|
||||||
<can_focus>True</can_focus>
|
<property name="use_underline">False</property>
|
||||||
<signal>
|
<property name="use_markup">False</property>
|
||||||
<name>clicked</name>
|
<property name="justify">GTK_JUSTIFY_LEFT</property>
|
||||||
<handler>OnAbout_Ok</handler>
|
<property name="wrap">False</property>
|
||||||
<last_modification_time>Sun, 07 Apr 2002 03:43:49 GMT</last_modification_time>
|
<property name="selectable">False</property>
|
||||||
</signal>
|
<property name="xalign">0.5</property>
|
||||||
<label>Ok</label>
|
<property name="yalign">0.5</property>
|
||||||
<relief>GTK_RELIEF_NORMAL</relief>
|
<property name="xpad">0</property>
|
||||||
</widget>
|
<property name="ypad">0</property>
|
||||||
|
<property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
|
||||||
|
<property name="width_chars">-1</property>
|
||||||
|
<property name="single_line_mode">False</property>
|
||||||
|
<property name="angle">0</property>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="padding">0</property>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">False</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkHButtonBox" id="hbuttonbox2">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="layout_style">GTK_BUTTONBOX_DEFAULT_STYLE</property>
|
||||||
|
<property name="spacing">30</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<widget class="GtkButton" id="button3">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_default">True</property>
|
||||||
|
<property name="can_focus">True</property>
|
||||||
|
<property name="label" translatable="yes">Ok</property>
|
||||||
|
<property name="use_underline">True</property>
|
||||||
|
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||||
|
<property name="focus_on_click">True</property>
|
||||||
|
<signal name="clicked" handler="OnAbout_Ok"/>
|
||||||
|
</widget>
|
||||||
|
</child>
|
||||||
|
</widget>
|
||||||
|
<packing>
|
||||||
|
<property name="padding">0</property>
|
||||||
|
<property name="expand">True</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
</widget>
|
</child>
|
||||||
</widget>
|
</widget>
|
||||||
|
|
||||||
</GTK-Interface>
|
</glade-interface>
|
||||||
|
|
|
@ -1,219 +0,0 @@
|
||||||
/*
|
|
||||||
* DO NOT EDIT THIS FILE - it is generated by Glade.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
|
||||||
# include <config.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <sys/types.h>
|
|
||||||
#include <sys/stat.h>
|
|
||||||
#include <unistd.h>
|
|
||||||
#include <string.h>
|
|
||||||
|
|
||||||
#include <gdk/gdkkeysyms.h>
|
|
||||||
#include <gtk/gtk.h>
|
|
||||||
|
|
||||||
#include "callbacks.h"
|
|
||||||
#include "interface.h"
|
|
||||||
#include "support.h"
|
|
||||||
|
|
||||||
GtkWidget*
|
|
||||||
create_Config (void)
|
|
||||||
{
|
|
||||||
GtkWidget *Config;
|
|
||||||
GtkWidget *vbox1;
|
|
||||||
GtkWidget *frame2;
|
|
||||||
GtkWidget *hbox1;
|
|
||||||
GtkWidget *label4;
|
|
||||||
GtkWidget *GtkCombo_Eth;
|
|
||||||
GtkWidget *combo_entry1;
|
|
||||||
GtkWidget *frame3;
|
|
||||||
GtkWidget *hbox2;
|
|
||||||
GtkWidget *label5;
|
|
||||||
GtkWidget *GtkCombo_Hdd;
|
|
||||||
GtkWidget *entry1;
|
|
||||||
GtkWidget *hbuttonbox1;
|
|
||||||
GtkWidget *button1;
|
|
||||||
GtkWidget *button2;
|
|
||||||
|
|
||||||
Config = gtk_window_new (GTK_WINDOW_TOPLEVEL);
|
|
||||||
gtk_object_set_data (GTK_OBJECT (Config), "Config", Config);
|
|
||||||
gtk_container_set_border_width (GTK_CONTAINER (Config), 5);
|
|
||||||
gtk_window_set_title (GTK_WINDOW (Config), "DEV9config");
|
|
||||||
gtk_window_set_position (GTK_WINDOW (Config), GTK_WIN_POS_CENTER);
|
|
||||||
|
|
||||||
vbox1 = gtk_vbox_new (FALSE, 5);
|
|
||||||
gtk_widget_ref (vbox1);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "vbox1", vbox1,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (vbox1);
|
|
||||||
gtk_container_add (GTK_CONTAINER (Config), vbox1);
|
|
||||||
gtk_container_set_border_width (GTK_CONTAINER (vbox1), 5);
|
|
||||||
|
|
||||||
frame2 = gtk_frame_new ("Ethernet");
|
|
||||||
gtk_widget_ref (frame2);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "frame2", frame2,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (frame2);
|
|
||||||
gtk_box_pack_start (GTK_BOX (vbox1), frame2, TRUE, TRUE, 0);
|
|
||||||
|
|
||||||
hbox1 = gtk_hbox_new (TRUE, 5);
|
|
||||||
gtk_widget_ref (hbox1);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "hbox1", hbox1,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (hbox1);
|
|
||||||
gtk_container_add (GTK_CONTAINER (frame2), hbox1);
|
|
||||||
gtk_container_set_border_width (GTK_CONTAINER (hbox1), 5);
|
|
||||||
|
|
||||||
label4 = gtk_label_new ("Device:");
|
|
||||||
gtk_widget_ref (label4);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "label4", label4,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (label4);
|
|
||||||
gtk_box_pack_start (GTK_BOX (hbox1), label4, FALSE, FALSE, 0);
|
|
||||||
|
|
||||||
GtkCombo_Eth = gtk_combo_new ();
|
|
||||||
gtk_widget_ref (GtkCombo_Eth);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "GtkCombo_Eth", GtkCombo_Eth,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (GtkCombo_Eth);
|
|
||||||
gtk_box_pack_start (GTK_BOX (hbox1), GtkCombo_Eth, FALSE, FALSE, 0);
|
|
||||||
gtk_widget_set_usize (GtkCombo_Eth, 130, -2);
|
|
||||||
|
|
||||||
combo_entry1 = GTK_COMBO (GtkCombo_Eth)->entry;
|
|
||||||
gtk_widget_ref (combo_entry1);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "combo_entry1", combo_entry1,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (combo_entry1);
|
|
||||||
|
|
||||||
frame3 = gtk_frame_new ("Hdd");
|
|
||||||
gtk_widget_ref (frame3);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "frame3", frame3,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (frame3);
|
|
||||||
gtk_box_pack_start (GTK_BOX (vbox1), frame3, TRUE, TRUE, 0);
|
|
||||||
|
|
||||||
hbox2 = gtk_hbox_new (TRUE, 5);
|
|
||||||
gtk_widget_ref (hbox2);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "hbox2", hbox2,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (hbox2);
|
|
||||||
gtk_container_add (GTK_CONTAINER (frame3), hbox2);
|
|
||||||
gtk_container_set_border_width (GTK_CONTAINER (hbox2), 5);
|
|
||||||
|
|
||||||
label5 = gtk_label_new ("Device:");
|
|
||||||
gtk_widget_ref (label5);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "label5", label5,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (label5);
|
|
||||||
gtk_box_pack_start (GTK_BOX (hbox2), label5, FALSE, FALSE, 0);
|
|
||||||
|
|
||||||
GtkCombo_Hdd = gtk_combo_new ();
|
|
||||||
gtk_widget_ref (GtkCombo_Hdd);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "GtkCombo_Hdd", GtkCombo_Hdd,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (GtkCombo_Hdd);
|
|
||||||
gtk_box_pack_start (GTK_BOX (hbox2), GtkCombo_Hdd, FALSE, FALSE, 0);
|
|
||||||
gtk_widget_set_usize (GtkCombo_Hdd, 130, -2);
|
|
||||||
|
|
||||||
entry1 = GTK_COMBO (GtkCombo_Hdd)->entry;
|
|
||||||
gtk_widget_ref (entry1);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "entry1", entry1,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (entry1);
|
|
||||||
|
|
||||||
hbuttonbox1 = gtk_hbutton_box_new ();
|
|
||||||
gtk_widget_ref (hbuttonbox1);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "hbuttonbox1", hbuttonbox1,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (hbuttonbox1);
|
|
||||||
gtk_box_pack_start (GTK_BOX (vbox1), hbuttonbox1, TRUE, TRUE, 0);
|
|
||||||
|
|
||||||
button1 = gtk_button_new_with_label ("Ok");
|
|
||||||
gtk_widget_ref (button1);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "button1", button1,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (button1);
|
|
||||||
gtk_container_add (GTK_CONTAINER (hbuttonbox1), button1);
|
|
||||||
GTK_WIDGET_SET_FLAGS (button1, GTK_CAN_DEFAULT);
|
|
||||||
|
|
||||||
button2 = gtk_button_new_with_label ("Cancel");
|
|
||||||
gtk_widget_ref (button2);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (Config), "button2", button2,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (button2);
|
|
||||||
gtk_container_add (GTK_CONTAINER (hbuttonbox1), button2);
|
|
||||||
GTK_WIDGET_SET_FLAGS (button2, GTK_CAN_DEFAULT);
|
|
||||||
|
|
||||||
gtk_signal_connect (GTK_OBJECT (button1), "clicked",
|
|
||||||
GTK_SIGNAL_FUNC (OnConf_Ok),
|
|
||||||
NULL);
|
|
||||||
gtk_signal_connect (GTK_OBJECT (button2), "clicked",
|
|
||||||
GTK_SIGNAL_FUNC (OnConf_Cancel),
|
|
||||||
NULL);
|
|
||||||
|
|
||||||
return Config;
|
|
||||||
}
|
|
||||||
|
|
||||||
GtkWidget*
|
|
||||||
create_About (void)
|
|
||||||
{
|
|
||||||
GtkWidget *About;
|
|
||||||
GtkWidget *vbox2;
|
|
||||||
GtkWidget *label2;
|
|
||||||
GtkWidget *label3;
|
|
||||||
GtkWidget *hbuttonbox2;
|
|
||||||
GtkWidget *button3;
|
|
||||||
|
|
||||||
About = gtk_window_new (GTK_WINDOW_TOPLEVEL);
|
|
||||||
gtk_object_set_data (GTK_OBJECT (About), "About", About);
|
|
||||||
gtk_container_set_border_width (GTK_CONTAINER (About), 5);
|
|
||||||
gtk_window_set_title (GTK_WINDOW (About), "DEV9about");
|
|
||||||
gtk_window_set_position (GTK_WINDOW (About), GTK_WIN_POS_CENTER);
|
|
||||||
|
|
||||||
vbox2 = gtk_vbox_new (FALSE, 5);
|
|
||||||
gtk_widget_ref (vbox2);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (About), "vbox2", vbox2,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (vbox2);
|
|
||||||
gtk_container_add (GTK_CONTAINER (About), vbox2);
|
|
||||||
gtk_container_set_border_width (GTK_CONTAINER (vbox2), 5);
|
|
||||||
|
|
||||||
label2 = gtk_label_new ("DEV9linuz Driver");
|
|
||||||
gtk_widget_ref (label2);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (About), "label2", label2,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (label2);
|
|
||||||
gtk_box_pack_start (GTK_BOX (vbox2), label2, FALSE, FALSE, 0);
|
|
||||||
|
|
||||||
label3 = gtk_label_new ("Author: linuzappz <linuzappz@hotmail.com>");
|
|
||||||
gtk_widget_ref (label3);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (About), "label3", label3,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (label3);
|
|
||||||
gtk_box_pack_start (GTK_BOX (vbox2), label3, FALSE, FALSE, 0);
|
|
||||||
gtk_label_set_justify (GTK_LABEL (label3), GTK_JUSTIFY_LEFT);
|
|
||||||
|
|
||||||
hbuttonbox2 = gtk_hbutton_box_new ();
|
|
||||||
gtk_widget_ref (hbuttonbox2);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (About), "hbuttonbox2", hbuttonbox2,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (hbuttonbox2);
|
|
||||||
gtk_box_pack_start (GTK_BOX (vbox2), hbuttonbox2, TRUE, TRUE, 0);
|
|
||||||
|
|
||||||
button3 = gtk_button_new_with_label ("Ok");
|
|
||||||
gtk_widget_ref (button3);
|
|
||||||
gtk_object_set_data_full (GTK_OBJECT (About), "button3", button3,
|
|
||||||
(GtkDestroyNotify) gtk_widget_unref);
|
|
||||||
gtk_widget_show (button3);
|
|
||||||
gtk_container_add (GTK_CONTAINER (hbuttonbox2), button3);
|
|
||||||
GTK_WIDGET_SET_FLAGS (button3, GTK_CAN_DEFAULT);
|
|
||||||
|
|
||||||
gtk_signal_connect (GTK_OBJECT (button3), "clicked",
|
|
||||||
GTK_SIGNAL_FUNC (OnAbout_Ok),
|
|
||||||
NULL);
|
|
||||||
|
|
||||||
return About;
|
|
||||||
}
|
|
||||||
|
|
|
@ -1,162 +0,0 @@
|
||||||
/*
|
|
||||||
* DO NOT EDIT THIS FILE - it is generated by Glade.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
|
||||||
# include <config.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <sys/types.h>
|
|
||||||
#include <sys/stat.h>
|
|
||||||
#include <unistd.h>
|
|
||||||
#include <string.h>
|
|
||||||
|
|
||||||
#include <gtk/gtk.h>
|
|
||||||
|
|
||||||
#include "support.h"
|
|
||||||
|
|
||||||
/* This is an internally used function to check if a pixmap file exists. */
|
|
||||||
static gchar* check_file_exists (const gchar *directory,
|
|
||||||
const gchar *filename);
|
|
||||||
|
|
||||||
/* This is an internally used function to create pixmaps. */
|
|
||||||
static GtkWidget* create_dummy_pixmap (GtkWidget *widget);
|
|
||||||
|
|
||||||
GtkWidget*
|
|
||||||
lookup_widget (GtkWidget *widget,
|
|
||||||
const gchar *widget_name)
|
|
||||||
{
|
|
||||||
GtkWidget *parent, *found_widget;
|
|
||||||
|
|
||||||
for (;;)
|
|
||||||
{
|
|
||||||
if (GTK_IS_MENU (widget))
|
|
||||||
parent = gtk_menu_get_attach_widget (GTK_MENU (widget));
|
|
||||||
else
|
|
||||||
parent = widget->parent;
|
|
||||||
if (parent == NULL)
|
|
||||||
break;
|
|
||||||
widget = parent;
|
|
||||||
}
|
|
||||||
|
|
||||||
found_widget = (GtkWidget*) gtk_object_get_data (GTK_OBJECT (widget),
|
|
||||||
widget_name);
|
|
||||||
if (!found_widget)
|
|
||||||
g_warning ("Widget not found: %s", widget_name);
|
|
||||||
return found_widget;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* This is a dummy pixmap we use when a pixmap can't be found. */
|
|
||||||
static char *dummy_pixmap_xpm[] = {
|
|
||||||
/* columns rows colors chars-per-pixel */
|
|
||||||
"1 1 1 1",
|
|
||||||
" c None",
|
|
||||||
/* pixels */
|
|
||||||
" "
|
|
||||||
};
|
|
||||||
|
|
||||||
/* This is an internally used function to create pixmaps. */
|
|
||||||
static GtkWidget*
|
|
||||||
create_dummy_pixmap (GtkWidget *widget)
|
|
||||||
{
|
|
||||||
GdkColormap *colormap;
|
|
||||||
GdkPixmap *gdkpixmap;
|
|
||||||
GdkBitmap *mask;
|
|
||||||
GtkWidget *pixmap;
|
|
||||||
|
|
||||||
colormap = gtk_widget_get_colormap (widget);
|
|
||||||
gdkpixmap = gdk_pixmap_colormap_create_from_xpm_d (NULL, colormap, &mask,
|
|
||||||
NULL, dummy_pixmap_xpm);
|
|
||||||
if (gdkpixmap == NULL)
|
|
||||||
g_error ("Couldn't create replacement pixmap.");
|
|
||||||
pixmap = gtk_pixmap_new (gdkpixmap, mask);
|
|
||||||
gdk_pixmap_unref (gdkpixmap);
|
|
||||||
gdk_bitmap_unref (mask);
|
|
||||||
return pixmap;
|
|
||||||
}
|
|
||||||
|
|
||||||
static GList *pixmaps_directories = NULL;
|
|
||||||
|
|
||||||
/* Use this function to set the directory containing installed pixmaps. */
|
|
||||||
void
|
|
||||||
add_pixmap_directory (const gchar *directory)
|
|
||||||
{
|
|
||||||
pixmaps_directories = g_list_prepend (pixmaps_directories,
|
|
||||||
g_strdup (directory));
|
|
||||||
}
|
|
||||||
|
|
||||||
/* This is an internally used function to create pixmaps. */
|
|
||||||
GtkWidget*
|
|
||||||
create_pixmap (GtkWidget *widget,
|
|
||||||
const gchar *filename)
|
|
||||||
{
|
|
||||||
gchar *found_filename = NULL;
|
|
||||||
GdkColormap *colormap;
|
|
||||||
GdkPixmap *gdkpixmap;
|
|
||||||
GdkBitmap *mask;
|
|
||||||
GtkWidget *pixmap;
|
|
||||||
GList *elem;
|
|
||||||
|
|
||||||
if (!filename || !filename[0])
|
|
||||||
return create_dummy_pixmap (widget);
|
|
||||||
|
|
||||||
/* We first try any pixmaps directories set by the application. */
|
|
||||||
elem = pixmaps_directories;
|
|
||||||
while (elem)
|
|
||||||
{
|
|
||||||
found_filename = check_file_exists ((gchar*)elem->data, filename);
|
|
||||||
if (found_filename)
|
|
||||||
break;
|
|
||||||
elem = elem->next;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* If we haven't found the pixmap, try the source directory. */
|
|
||||||
if (!found_filename)
|
|
||||||
{
|
|
||||||
found_filename = check_file_exists ("pixmaps", filename);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!found_filename)
|
|
||||||
{
|
|
||||||
g_warning ("Couldn't find pixmap file: %s", filename);
|
|
||||||
return create_dummy_pixmap (widget);
|
|
||||||
}
|
|
||||||
|
|
||||||
colormap = gtk_widget_get_colormap (widget);
|
|
||||||
gdkpixmap = gdk_pixmap_colormap_create_from_xpm (NULL, colormap, &mask,
|
|
||||||
NULL, found_filename);
|
|
||||||
if (gdkpixmap == NULL)
|
|
||||||
{
|
|
||||||
g_warning ("Error loading pixmap file: %s", found_filename);
|
|
||||||
g_free (found_filename);
|
|
||||||
return create_dummy_pixmap (widget);
|
|
||||||
}
|
|
||||||
g_free (found_filename);
|
|
||||||
pixmap = gtk_pixmap_new (gdkpixmap, mask);
|
|
||||||
gdk_pixmap_unref (gdkpixmap);
|
|
||||||
gdk_bitmap_unref (mask);
|
|
||||||
return pixmap;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* This is an internally used function to check if a pixmap file exists. */
|
|
||||||
static gchar*
|
|
||||||
check_file_exists (const gchar *directory,
|
|
||||||
const gchar *filename)
|
|
||||||
{
|
|
||||||
gchar *full_filename;
|
|
||||||
struct stat s;
|
|
||||||
gint status;
|
|
||||||
|
|
||||||
full_filename = (gchar*) g_malloc (strlen (directory) + 1
|
|
||||||
+ strlen (filename) + 1);
|
|
||||||
strcpy (full_filename, directory);
|
|
||||||
strcat (full_filename, G_DIR_SEPARATOR_S);
|
|
||||||
strcat (full_filename, filename);
|
|
||||||
|
|
||||||
status = stat (full_filename, &s);
|
|
||||||
if (status == 0 && S_ISREG (s.st_mode))
|
|
||||||
return full_filename;
|
|
||||||
g_free (full_filename);
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
|
@ -8,6 +8,31 @@
|
||||||
|
|
||||||
#include <gtk/gtk.h>
|
#include <gtk/gtk.h>
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Standard gettext macros.
|
||||||
|
*/
|
||||||
|
#ifdef ENABLE_NLS
|
||||||
|
# include <libintl.h>
|
||||||
|
# undef _
|
||||||
|
# define _(String) dgettext (PACKAGE, String)
|
||||||
|
# define Q_(String) g_strip_context ((String), gettext (String))
|
||||||
|
# ifdef gettext_noop
|
||||||
|
# define N_(String) gettext_noop (String)
|
||||||
|
# else
|
||||||
|
# define N_(String) (String)
|
||||||
|
# endif
|
||||||
|
#else
|
||||||
|
# define textdomain(String) (String)
|
||||||
|
# define gettext(String) (String)
|
||||||
|
# define dgettext(Domain,Message) (Message)
|
||||||
|
# define dcgettext(Domain,Message,Type) (Message)
|
||||||
|
# define bindtextdomain(Domain,Directory) (Domain)
|
||||||
|
# define _(String) (String)
|
||||||
|
# define Q_(String) g_strip_context ((String), (String))
|
||||||
|
# define N_(String) (String)
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Public Functions.
|
* Public Functions.
|
||||||
*/
|
*/
|
||||||
|
@ -21,8 +46,6 @@
|
||||||
GtkWidget* lookup_widget (GtkWidget *widget,
|
GtkWidget* lookup_widget (GtkWidget *widget,
|
||||||
const gchar *widget_name);
|
const gchar *widget_name);
|
||||||
|
|
||||||
/* get_widget() is deprecated. Use lookup_widget instead. */
|
|
||||||
#define get_widget lookup_widget
|
|
||||||
|
|
||||||
/* Use this function to set the directory containing installed pixmaps. */
|
/* Use this function to set the directory containing installed pixmaps. */
|
||||||
void add_pixmap_directory (const gchar *directory);
|
void add_pixmap_directory (const gchar *directory);
|
||||||
|
@ -32,7 +55,15 @@ void add_pixmap_directory (const gchar *directory);
|
||||||
* Private Functions.
|
* Private Functions.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* This is used to create the pixmaps in the interface. */
|
/* This is used to create the pixmaps used in the interface. */
|
||||||
GtkWidget* create_pixmap (GtkWidget *widget,
|
GtkWidget* create_pixmap (GtkWidget *widget,
|
||||||
const gchar *filename);
|
const gchar *filename);
|
||||||
|
|
||||||
|
/* This is used to create the pixbufs used in the interface. */
|
||||||
|
GdkPixbuf* create_pixbuf (const gchar *filename);
|
||||||
|
|
||||||
|
/* This is used to set ATK action descriptions. */
|
||||||
|
void glade_set_atk_action_description (AtkAction *action,
|
||||||
|
const gchar *action_name,
|
||||||
|
const gchar *description);
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,33 @@
|
||||||
|
# Create a shared library libFWnull
|
||||||
|
AUTOMAKE_OPTIONS = foreign
|
||||||
|
noinst_LIBRARIES = libFWnull.a
|
||||||
|
INCLUDES = -I@srcdir@/../../common/include -I@srcdir@/../../3rdparty -I@srcdir@/Linux
|
||||||
|
|
||||||
|
libFWnull_a_CXXFLAGS = $(shell pkg-config --cflags gtk+-2.0)
|
||||||
|
libFWnull_a_CFLAGS = $(shell pkg-config --cflags gtk+-2.0)
|
||||||
|
|
||||||
|
# Create a shared object by faking an exe (thanks to ODE makefiles)
|
||||||
|
traplibdir=$(prefix)
|
||||||
|
|
||||||
|
if DEBUGBUILD
|
||||||
|
preext=d
|
||||||
|
endif
|
||||||
|
|
||||||
|
EXEEXT=$(preext)@so_ext@
|
||||||
|
|
||||||
|
traplib_PROGRAMS=libFWnull
|
||||||
|
libFWnull_SOURCES=
|
||||||
|
libFWnull_DEPENDENCIES = libFWnull.a
|
||||||
|
libFWnull_LDFLAGS= @SHARED_LDFLAGS@
|
||||||
|
libFWnull_LDFLAGS+=-Wl,-soname,@libFWnull_SONAME@
|
||||||
|
libFWnull_LDADD=$(libFWnull_a_OBJECTS)
|
||||||
|
|
||||||
|
libFWnull_a_SOURCES = FW.cpp Linux/Config.cpp Linux/Linux.cpp \
|
||||||
|
FW.h Linux/Config.h Linux/Linux.h
|
||||||
|
|
||||||
|
libFWnull_a_SOURCES += \
|
||||||
|
Linux/interface.h Linux/support.c \
|
||||||
|
Linux/interface.c Linux/support.h \
|
||||||
|
Linux/callbacks.c Linux/callbacks.h
|
||||||
|
|
||||||
|
#SUBDIRS = Linux
|
|
@ -161,7 +161,7 @@
|
||||||
>
|
>
|
||||||
</File>
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\FW.c"
|
RelativePath="..\FW.cpp"
|
||||||
>
|
>
|
||||||
</File>
|
</File>
|
||||||
<File
|
<File
|
||||||
|
|
|
@ -23,7 +23,7 @@ BOOL CALLBACK ConfigureDlgProc(HWND hW, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||||
switch(uMsg) {
|
switch(uMsg) {
|
||||||
case WM_INITDIALOG:
|
case WM_INITDIALOG:
|
||||||
LoadConfig();
|
LoadConfig();
|
||||||
if (conf.Log) CheckDlgButton(hW, IDC_LOGGING, TRUE);
|
if (conf.Log) CheckDlgButton(hW, IDC_LOGGING, TRUE);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
case WM_COMMAND:
|
case WM_COMMAND:
|
||||||
|
|
|
@ -6,9 +6,30 @@ echo ---------------
|
||||||
|
|
||||||
curdir=`pwd`
|
curdir=`pwd`
|
||||||
|
|
||||||
cd ${curdir}/Linux
|
|
||||||
|
if test "${FWnullOPTIONS+set}" != set ; then
|
||||||
|
export FWnullOPTIONS=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ $# -gt 0 ] && [ $1 = "all" ]
|
||||||
|
then
|
||||||
|
|
||||||
|
aclocal
|
||||||
|
automake -a
|
||||||
|
autoconf
|
||||||
|
|
||||||
|
./configure ${FWnullOPTIONS} --prefix=${PCSX2PLUGINS}
|
||||||
make clean
|
make clean
|
||||||
|
make install
|
||||||
|
|
||||||
|
else
|
||||||
make $@
|
make $@
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ $? -ne 0 ]
|
||||||
|
then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
if [ -s cfgFWnull ] && [ -s libFWnull.so ]
|
if [ -s cfgFWnull ] && [ -s libFWnull.so ]
|
||||||
then
|
then
|
||||||
|
|
|
@ -0,0 +1,80 @@
|
||||||
|
AC_INIT(FWnull, 0.5,arcum42@gmail.com)
|
||||||
|
|
||||||
|
AM_INIT_AUTOMAKE(FWnull,0.5)
|
||||||
|
|
||||||
|
AC_PROG_CC([gcc g++ cl KCC CC cxx cc++ xlC aCC c++])
|
||||||
|
AC_PROG_CXX([gcc g++ cl KCC CC cxx cc++ xlC aCC c++])
|
||||||
|
AC_PROG_CPP([gcc g++ cl KCC CC cxx cc++ xlC aCC c++])
|
||||||
|
|
||||||
|
AC_PROG_INSTALL
|
||||||
|
AC_PROG_RANLIB
|
||||||
|
|
||||||
|
dnl necessary for compiling assembly
|
||||||
|
AM_PROG_AS
|
||||||
|
|
||||||
|
AC_SUBST(FWnull_CURRENT, 0)
|
||||||
|
AC_SUBST(FWnull_REVISION, 5)
|
||||||
|
AC_SUBST(FWnull_AGE, 0)
|
||||||
|
AC_SUBST(FWnull_RELEASE,[$FWnull_CURRENT].[$FWnull_REVISION].[$FWnull_AGE])
|
||||||
|
AC_SUBST(FWnull_SONAME,libFWnull.so.[$FWnull_CURRENT].[$FWnull_REVISION].[$FWnull_AGE])
|
||||||
|
|
||||||
|
CFLAGS=
|
||||||
|
CPPFLAGS=
|
||||||
|
CXXFLAGS=
|
||||||
|
|
||||||
|
dnl Check for debug build
|
||||||
|
AC_MSG_CHECKING(debug build)
|
||||||
|
AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug], [debug build]),
|
||||||
|
debug=$enableval,debug=no)
|
||||||
|
if test "x$debug" == xyes
|
||||||
|
then
|
||||||
|
AC_DEFINE(_DEBUG,1,[_DEBUG])
|
||||||
|
CFLAGS+="-g -fPIC -Wall -Wno-unused-value "
|
||||||
|
CPPFLAGS+="-g -fPIC -Wall -Wno-unused-value "
|
||||||
|
CXXFLAGS+="-g -fPIC -Wall -Wno-unused-value "
|
||||||
|
else
|
||||||
|
AC_DEFINE(NDEBUG,1,[NDEBUG])
|
||||||
|
CFLAGS+="-O3 -fomit-frame-pointer -fPIC -Wall -Wno-unused-value "
|
||||||
|
CPPFLAGS+="-O3 -fomit-frame-pointer -fPIC -Wall -Wno-unused-value "
|
||||||
|
CXXFLAGS+="-O3 -fomit-frame-pointer -fPIC -Wall -Wno-unused-value "
|
||||||
|
fi
|
||||||
|
AM_CONDITIONAL(DEBUGBUILD, test x$debug = xyes)
|
||||||
|
AC_MSG_RESULT($debug)
|
||||||
|
|
||||||
|
AC_DEFINE(__LINUX__,1,[__LINUX__])
|
||||||
|
|
||||||
|
dnl Check for dev build
|
||||||
|
AC_MSG_CHECKING(for development build...)
|
||||||
|
AC_ARG_ENABLE(devbuild, AC_HELP_STRING([--enable-devbuild], [Special Build for developers that simplifies testing and adds extra checks]),
|
||||||
|
devbuild=$enableval,devbuild=no)
|
||||||
|
if test "x$devbuild" == xyes
|
||||||
|
then
|
||||||
|
AC_DEFINE(FWnull_DEVBUILD,1,[FWnull_DEVBUILD])
|
||||||
|
fi
|
||||||
|
AC_MSG_RESULT($devbuild)
|
||||||
|
AM_CONDITIONAL(RELEASE_TO_PUBLIC, test x$devbuild = xno)
|
||||||
|
|
||||||
|
AC_CHECK_FUNCS([ _aligned_malloc _aligned_free ], AC_DEFINE(HAVE_ALIGNED_MALLOC))
|
||||||
|
|
||||||
|
dnl gtk
|
||||||
|
AC_MSG_CHECKING(gtk2+)
|
||||||
|
AC_CHECK_PROG(GTK_CONFIG, pkg-config, pkg-config)
|
||||||
|
LIBS+=$(pkg-config --libs gtk+-2.0)
|
||||||
|
|
||||||
|
dnl bindir = pcsx2exe
|
||||||
|
|
||||||
|
dnl assuming linux environment
|
||||||
|
so_ext=".so.$FWnull_RELEASE"
|
||||||
|
SHARED_LDFLAGS="-shared"
|
||||||
|
AC_SUBST(so_ext)
|
||||||
|
AC_SUBST(SHARED_LDFLAGS)
|
||||||
|
|
||||||
|
AC_CHECK_LIB(stdc++,main,[LIBS="$LIBS -lstdc++"])
|
||||||
|
|
||||||
|
AC_OUTPUT([
|
||||||
|
Makefile
|
||||||
|
])
|
||||||
|
|
||||||
|
echo "Configuration:"
|
||||||
|
echo " Debug build? $debug"
|
||||||
|
echo " Dev build? $devbuild"
|
|
@ -0,0 +1 @@
|
||||||
|
/usr/share/automake-1.10/install-sh
|
|
@ -0,0 +1 @@
|
||||||
|
/usr/share/automake-1.10/missing
|
Loading…
Reference in New Issue