Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 232855 | Differences between
and this patch

Collapse All | Expand All

(-)./mgeops-psp-3.0.8/src/AboutView_glade.cc (-1 / +1 lines)
Lines 35-41 Link Here
35
#  define N_(String) (String)
35
#  define N_(String) (String)
36
#endif
36
#endif
37
#include <gtkmmconfig.h>
37
#include <gtkmmconfig.h>
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION>2
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION<2
39
#include <sigc++/compatibility.h>
39
#include <sigc++/compatibility.h>
40
#define GMM_GTKMM_22_24(a,b) b
40
#define GMM_GTKMM_22_24(a,b) b
41
#else //gtkmm 2.2
41
#else //gtkmm 2.2
(-)./mgeops-psp-3.0.8/src/ConfigView_glade.cc (-15 / +15 lines)
Lines 35-41 Link Here
35
#  define N_(String) (String)
35
#  define N_(String) (String)
36
#endif
36
#endif
37
#include <gtkmmconfig.h>
37
#include <gtkmmconfig.h>
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION>2
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION<2
39
#include <sigc++/compatibility.h>
39
#include <sigc++/compatibility.h>
40
#define GMM_GTKMM_22_24(a,b) b
40
#define GMM_GTKMM_22_24(a,b) b
41
#else //gtkmm 2.2
41
#else //gtkmm 2.2
Lines 492-511 Link Here
492
   fxStatus->show();
492
   fxStatus->show();
493
   vpContent->show();
493
   vpContent->show();
494
   scrolledwindow6->show();
494
   scrolledwindow6->show();
495
   sdTimerValue->signal_changed().connect(SigC::slot(*this, &ConfigView_glade::on_sdTimerValue_changed), false);
495
   sdTimerValue->signal_changed().connect(sigc::mem_fun(*this, &ConfigView_glade::on_sdTimerValue_changed), false);
496
   sdTimerValue->signal_editing_done().connect(SigC::slot(*this, &ConfigView_glade::on_sdTimerValue_editing_done), false);
496
   sdTimerValue->signal_editing_done().connect(sigc::mem_fun(*this, &ConfigView_glade::on_sdTimerValue_editing_done), false);
497
   sdBattLevelValue->signal_changed().connect(SigC::slot(*this, &ConfigView_glade::on_sdBattLevelValue_changed), false);
497
   sdBattLevelValue->signal_changed().connect(sigc::mem_fun(*this, &ConfigView_glade::on_sdBattLevelValue_changed), false);
498
   sdRuntimeValue->signal_changed().connect(SigC::slot(*this, &ConfigView_glade::on_sdRuntimeValue_changed), false);
498
   sdRuntimeValue->signal_changed().connect(sigc::mem_fun(*this, &ConfigView_glade::on_sdRuntimeValue_changed), false);
499
   ckbtSdTimer->signal_toggled().connect(SigC::slot(*this, &ConfigView_glade::on_ckbtSdTimer_toggled), false);
499
   ckbtSdTimer->signal_toggled().connect(sigc::mem_fun(*this, &ConfigView_glade::on_ckbtSdTimer_toggled), false);
500
   ckbtBattLevel->signal_toggled().connect(SigC::slot(*this, &ConfigView_glade::on_ckbtBattLevel_toggled), false);
500
   ckbtBattLevel->signal_toggled().connect(sigc::mem_fun(*this, &ConfigView_glade::on_ckbtBattLevel_toggled), false);
501
   ckbtSdRuntime->signal_toggled().connect(SigC::slot(*this, &ConfigView_glade::on_ckbtSdRuntime_toggled), false);
501
   ckbtSdRuntime->signal_toggled().connect(sigc::mem_fun(*this, &ConfigView_glade::on_ckbtSdRuntime_toggled), false);
502
   customSdCommand->signal_changed().connect(SigC::slot(*this, &ConfigView_glade::on_customSdCommand_changed), false);
502
   customSdCommand->signal_changed().connect(sigc::mem_fun(*this, &ConfigView_glade::on_customSdCommand_changed), false);
503
   rbNoShutdown->signal_toggled().connect(SigC::slot(*this, &ConfigView_glade::on_rbShutdown_toggled), false);
503
   rbNoShutdown->signal_toggled().connect(sigc::mem_fun(*this, &ConfigView_glade::on_rbShutdown_toggled), false);
504
   rbShutdown->signal_toggled().connect(SigC::slot(*this, &ConfigView_glade::on_rbShutdown_toggled), false);
504
   rbShutdown->signal_toggled().connect(sigc::mem_fun(*this, &ConfigView_glade::on_rbShutdown_toggled), false);
505
   rbCustomShutdown->signal_toggled().connect(SigC::slot(*this, &ConfigView_glade::on_rbCustomShutdown_toggled), false);
505
   rbCustomShutdown->signal_toggled().connect(sigc::mem_fun(*this, &ConfigView_glade::on_rbCustomShutdown_toggled), false);
506
   ckbtIconDisplay->signal_toggled().connect(SigC::slot(*this, &ConfigView_glade::on_ckbtIconDisplay_toggled), false);
506
   ckbtIconDisplay->signal_toggled().connect(sigc::mem_fun(*this, &ConfigView_glade::on_ckbtIconDisplay_toggled), false);
507
   btAdminMode->signal_released().connect(SigC::slot(*this, &ConfigView_glade::on_btAdminMode_released), false);
507
   btAdminMode->signal_released().connect(sigc::mem_fun(*this, &ConfigView_glade::on_btAdminMode_released), false);
508
   btSaveCfg->signal_released().connect(SigC::slot(*this, &ConfigView_glade::on_btSaveCfg_released), false);
508
   btSaveCfg->signal_released().connect(sigc::mem_fun(*this, &ConfigView_glade::on_btSaveCfg_released), false);
509
}
509
}
510
510
511
ConfigView_glade::~ConfigView_glade()
511
ConfigView_glade::~ConfigView_glade()
(-)./mgeops-psp-3.0.8/src/dlgInfo_glade.cc (-2 / +2 lines)
Lines 35-41 Link Here
35
#  define N_(String) (String)
35
#  define N_(String) (String)
36
#endif
36
#endif
37
#include <gtkmmconfig.h>
37
#include <gtkmmconfig.h>
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION>2
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION<2
39
#include <sigc++/compatibility.h>
39
#include <sigc++/compatibility.h>
40
#define GMM_GTKMM_22_24(a,b) b
40
#define GMM_GTKMM_22_24(a,b) b
41
#else //gtkmm 2.2
41
#else //gtkmm 2.2
Lines 93-99 Link Here
93
   imgContent->show();
93
   imgContent->show();
94
   lblContent->show();
94
   lblContent->show();
95
   hbox24->show();
95
   hbox24->show();
96
   closebutton1->signal_released().connect(SigC::slot(*this, &dlgInfo_glade::on_closebutton1_released), false);
96
   closebutton1->signal_released().connect(sigc::mem_fun(*this, &dlgInfo_glade::on_closebutton1_released), false);
97
}
97
}
98
98
99
dlgInfo_glade::~dlgInfo_glade()
99
dlgInfo_glade::~dlgInfo_glade()
(-)./mgeops-psp-3.0.8/src/dlgInfoOPS_glade.cc (-3 / +3 lines)
Lines 35-41 Link Here
35
#  define N_(String) (String)
35
#  define N_(String) (String)
36
#endif
36
#endif
37
#include <gtkmmconfig.h>
37
#include <gtkmmconfig.h>
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION>2
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION<2
39
#include <sigc++/compatibility.h>
39
#include <sigc++/compatibility.h>
40
#define GMM_GTKMM_22_24(a,b) b
40
#define GMM_GTKMM_22_24(a,b) b
41
#else //gtkmm 2.2
41
#else //gtkmm 2.2
Lines 266-273 Link Here
266
   ckbtRemindOPS->show();
266
   ckbtRemindOPS->show();
267
   vbox25->show();
267
   vbox25->show();
268
   hbox27->show();
268
   hbox27->show();
269
   button1->signal_released().connect(SigC::slot(*this, &dlgInfoOPS_glade::on_closebutton1_released), false);
269
   button1->signal_released().connect(sigc::mem_fun(*this, &dlgInfoOPS_glade::on_closebutton1_released), false);
270
   ckbtRemindOPS->signal_toggled().connect(SigC::slot(*this, &dlgInfoOPS_glade::on_ckbtRemindOPS_toggled), false);
270
   ckbtRemindOPS->signal_toggled().connect(sigc::mem_fun(*this, &dlgInfoOPS_glade::on_ckbtRemindOPS_toggled), false);
271
}
271
}
272
272
273
dlgInfoOPS_glade::~dlgInfoOPS_glade()
273
dlgInfoOPS_glade::~dlgInfoOPS_glade()
(-)./mgeops-psp-3.0.8/src/EventWin.cc (-17 / +14 lines)
Lines 9-14 Link Here
9
#include "gettext.h"
9
#include "gettext.h"
10
10
11
#  include <gdkmm.h>
11
#  include <gdkmm.h>
12
#include <string.h>
13
#include <time.h>
14
#include <locale.h>
15
#include <langinfo.h>
12
16
13
#include "EventWin.hh"
17
#include "EventWin.hh"
14
// FIXME: a supprimer??
18
// FIXME: a supprimer??
Lines 73-95 Link Here
73
77
74
void EventWin::addEvent(Glib::ustring eventName, int evtSeverity)
78
void EventWin::addEvent(Glib::ustring eventName, int evtSeverity)
75
{
79
{
76
  time_t		currentTime = time(NULL);
77
  Glib::ustring	newEvent;
80
  Glib::ustring	newEvent;
78
  char			i18nTime[32];
81
  struct tm *gmt;
79
  char			*tmp;
82
  char timebuf[64];
80
83
  time_t AnnoDomini;
81
  // FIXME: ?buggy? Glib::Date *timeStamp = new class Glib::Date ();
84
82
  // seems not to manage H:M:S (limitation to be bugged upstream!)
85
  setlocale(LC_ALL,"");
83
  //   Glib::Date *i18nTimeNew = new class Glib::Date ();
86
  time(&AnnoDomini);
84
  //   i18nTimeNew->set_time(time(NULL));
87
  gmt=localtime(&AnnoDomini);
85
  //   std::cout << "TEST TIME = " << i18nTimeNew->format_string ("%c").c_str() << std::endl;
88
  strftime(timebuf, sizeof(timebuf), nl_langinfo (D_T_FMT), gmt);
86
  
89
  timebuf[sizeof(timebuf)-1] = '\0';
87
  // Create the timestamp
88
  strftime (&i18nTime[0], 32, "%c", localtime(&currentTime));
89
  if ((tmp=strstr(i18nTime, "CEST")) != NULL)
90
	*(tmp--) = '\0';
91
92
  std::cout << "Event: " << Glib::locale_to_utf8(i18nTime) << std::endl;
93
90
94
  // FIXME: make a table for event transition
91
  // FIXME: make a table for event transition
95
  // No status change
92
  // No status change
Lines 124-130 Link Here
124
  // Create the new row
121
  // Create the new row
125
  Gtk::TreeModel::Row row = *(refListModel->append());
122
  Gtk::TreeModel::Row row = *(refListModel->append());
126
  row[eventColumns.eventText] = newEvent.c_str();
123
  row[eventColumns.eventText] = newEvent.c_str();
127
  row[eventColumns.eventDate] = Glib::ustring(Glib::locale_to_utf8(i18nTime));
124
  row[eventColumns.eventDate] = Glib::ustring(timebuf);
128
  row[eventColumns.eventIcon] = Gtk::Image(getSeverityIcon(evtSeverity)).get_pixbuf();
125
  row[eventColumns.eventIcon] = Gtk::Image(getSeverityIcon(evtSeverity)).get_pixbuf();
129
126
130
  // Set focus on the last event
127
  // Set focus on the last event
(-)./mgeops-psp-3.0.8/src/EventWin_glade.cc (-1 / +1 lines)
Lines 35-41 Link Here
35
#  define N_(String) (String)
35
#  define N_(String) (String)
36
#endif
36
#endif
37
#include <gtkmmconfig.h>
37
#include <gtkmmconfig.h>
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION>2
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION<2
39
#include <sigc++/compatibility.h>
39
#include <sigc++/compatibility.h>
40
#define GMM_GTKMM_22_24(a,b) b
40
#define GMM_GTKMM_22_24(a,b) b
41
#else //gtkmm 2.2
41
#else //gtkmm 2.2
(-)./mgeops-psp-3.0.8/src/MainWindow_glade.cc (-12 / +12 lines)
Lines 35-41 Link Here
35
#  define N_(String) (String)
35
#  define N_(String) (String)
36
#endif
36
#endif
37
#include <gtkmmconfig.h>
37
#include <gtkmmconfig.h>
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION>2
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION<2
39
#include <sigc++/compatibility.h>
39
#include <sigc++/compatibility.h>
40
#define GMM_GTKMM_22_24(a,b) b
40
#define GMM_GTKMM_22_24(a,b) b
41
#else //gtkmm 2.2
41
#else //gtkmm 2.2
Lines 1253-1269 Link Here
1253
   eventbox9->show();
1253
   eventbox9->show();
1254
   vbox4->show();
1254
   vbox4->show();
1255
   hbox7->show();
1255
   hbox7->show();
1256
   btStatus->signal_enter().connect(SigC::slot(*this, &MainWindow_glade::on_btStatus_enter), false);
1256
   btStatus->signal_enter().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btStatus_enter), false);
1257
   btStatus->signal_released().connect(SigC::slot(*this, &MainWindow_glade::on_btStatus_released), false);
1257
   btStatus->signal_released().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btStatus_released), false);
1258
   btHistory->signal_enter().connect(SigC::slot(*this, &MainWindow_glade::on_btHistory_enter), false);
1258
   btHistory->signal_enter().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btHistory_enter), false);
1259
   btHistory->signal_released().connect(SigC::slot(*this, &MainWindow_glade::on_btHistory_released), false);
1259
   btHistory->signal_released().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btHistory_released), false);
1260
   btConfig->signal_enter().connect(SigC::slot(*this, &MainWindow_glade::on_btConfig_enter), false);
1260
   btConfig->signal_enter().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btConfig_enter), false);
1261
   btConfig->signal_released().connect(SigC::slot(*this, &MainWindow_glade::on_btConfig_released), false);
1261
   btConfig->signal_released().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btConfig_released), false);
1262
   btHelp->signal_enter().connect(SigC::slot(*this, &MainWindow_glade::on_btHelp_enter), false);
1262
   btHelp->signal_enter().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btHelp_enter), false);
1263
   btHelp->signal_released().connect(SigC::slot(*this, &MainWindow_glade::on_btHelp_released), false);
1263
   btHelp->signal_released().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btHelp_released), false);
1264
   btAbout->signal_enter().connect(SigC::slot(*this, &MainWindow_glade::on_btAbout_enter), false);
1264
   btAbout->signal_enter().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btAbout_enter), false);
1265
   btAbout->signal_released().connect(SigC::slot(*this, &MainWindow_glade::on_btAbout_released), false);
1265
   btAbout->signal_released().connect(sigc::mem_fun(*this, &MainWindow_glade::on_btAbout_released), false);
1266
   btExit->signal_released().connect(SigC::slot(*this, &MainWindow_glade::gtk_main_quit), true);
1266
   btExit->signal_released().connect(sigc::mem_fun(*this, &MainWindow_glade::gtk_main_quit), true);
1267
   btExit->grab_default();
1267
   btExit->grab_default();
1268
}
1268
}
1269
1269
(-)./mgeops-psp-3.0.8/src/NutConfig.cpp (-4 / +4 lines)
Lines 33-40 Link Here
33
	case MgeUtils::SYSTEM_TYPE_MDK:
33
	case MgeUtils::SYSTEM_TYPE_MDK:
34
	case MgeUtils::SYSTEM_TYPE_MDK_2007:
34
	case MgeUtils::SYSTEM_TYPE_MDK_2007:
35
	default:
35
	default:
36
	  nutCfgDir = new Glib::ustring("/etc/ups/");
36
	  nutCfgDir = new Glib::ustring("/etc/nut/");
37
	  nutUser = new Glib::ustring("ups");
37
	  nutUser = new Glib::ustring("nut");
38
	  break;
38
	  break;
39
	}
39
	}
40
  bIsNutConfigured = false; //isNutConfigured();
40
  bIsNutConfigured = false; //isNutConfigured();
Lines 76-83 Link Here
76
	case MgeUtils::SYSTEM_TYPE_MDK:
76
	case MgeUtils::SYSTEM_TYPE_MDK:
77
	case MgeUtils::SYSTEM_TYPE_MDK_2007:
77
	case MgeUtils::SYSTEM_TYPE_MDK_2007:
78
	default:
78
	default:
79
	  nutCfgDir = new Glib::ustring("/etc/ups/");
79
	  nutCfgDir = new Glib::ustring("/etc/nut/");
80
	  nutUser = new Glib::ustring("ups");
80
	  nutUser = new Glib::ustring("nut");
81
	  break;
81
	  break;
82
	}
82
	}
83
  // FIXME: load serialised config from wizard.conf
83
  // FIXME: load serialised config from wizard.conf
(-)./mgeops-psp-3.0.8/src/psp.cc (+1 lines)
Lines 11-16 Link Here
11
#include <fstream>
11
#include <fstream>
12
#include <glibmm.h>
12
#include <glibmm.h>
13
#include <gdkmm.h>
13
#include <gdkmm.h>
14
#include <string.h>
14
#include <pangomm.h> // FIXME: needed there????
15
#include <pangomm.h> // FIXME: needed there????
15
#include <string.h>
16
#include <string.h>
16
17
(-)./mgeops-psp-3.0.8/src/splashwin.cc (-1 / +1 lines)
Lines 21-27 Link Here
21
#include "dlgInfo.hh"
21
#include "dlgInfo.hh"
22
22
23
splashwin *splashWinPtr;
23
splashwin *splashWinPtr;
24
SigC::Connection handle1, handle2;
24
sigc::connection handle1, handle2;
25
25
26
int callFinalize()
26
int callFinalize()
27
{
27
{
(-)./mgeops-psp-3.0.8/src/splashwin_glade.cc (-1 / +1 lines)
Lines 35-41 Link Here
35
#  define N_(String) (String)
35
#  define N_(String) (String)
36
#endif
36
#endif
37
#include <gtkmmconfig.h>
37
#include <gtkmmconfig.h>
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION>2
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION<2
39
#include <sigc++/compatibility.h>
39
#include <sigc++/compatibility.h>
40
#define GMM_GTKMM_22_24(a,b) b
40
#define GMM_GTKMM_22_24(a,b) b
41
#else //gtkmm 2.2
41
#else //gtkmm 2.2
(-)./mgeops-psp-3.0.8/src/StatusView_glade.cc (-1 / +1 lines)
Lines 35-41 Link Here
35
#  define N_(String) (String)
35
#  define N_(String) (String)
36
#endif
36
#endif
37
#include <gtkmmconfig.h>
37
#include <gtkmmconfig.h>
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION>2
38
#if GTKMM_MAJOR_VERSION==2 && GTKMM_MINOR_VERSION<2
39
#include <sigc++/compatibility.h>
39
#include <sigc++/compatibility.h>
40
#define GMM_GTKMM_22_24(a,b) b
40
#define GMM_GTKMM_22_24(a,b) b
41
#else //gtkmm 2.2
41
#else //gtkmm 2.2
(-)./mgeops-psp-3.0.8/src/SystemService.cpp (-1 / +8 lines)
Lines 203-209 Link Here
203
	  break;
203
	  break;
204
	case MgeUtils::SYSTEM_TYPE_SUSE:
204
	case MgeUtils::SYSTEM_TYPE_SUSE:
205
	case MgeUtils::SYSTEM_TYPE_RHFC:
205
	case MgeUtils::SYSTEM_TYPE_RHFC:
206
	default:
207
	  // FIXME: test if good!?
206
	  // FIXME: test if good!?
208
	  //if ((Glib::file_test ("/var/lib/ups/upsd.pid", Glib::FILE_TEST_EXISTS) == true)
207
	  //if ((Glib::file_test ("/var/lib/ups/upsd.pid", Glib::FILE_TEST_EXISTS) == true)
209
	  //	  && (Glib::file_test ("/var/lib/ups/upsmon.pid", Glib::FILE_TEST_EXISTS) == true))
208
	  //	  && (Glib::file_test ("/var/lib/ups/upsmon.pid", Glib::FILE_TEST_EXISTS) == true))
Lines 212-217 Link Here
212
	  else
211
	  else
213
		retCode = false;
212
		retCode = false;
214
	  break;
213
	  break;
214
	default:
215
	  if ((Glib::file_test ("/var/lib/nut/upsd.pid", Glib::FILE_TEST_EXISTS) == true)
216
	  	  && (Glib::file_test ("/var/run/upsmon.pid", Glib::FILE_TEST_EXISTS) == true))
217
218
		retCode = true;
219
	  else
220
		retCode = false;
221
	  break;
215
	}
222
	}
216
  if (retCode == true)
223
  if (retCode == true)
217
	std::cout << "Services are already started" << std::endl;
224
	std::cout << "Services are already started" << std::endl;

Return to bug 232855