[banshee] [GtkBaseClient] Added --debug-gtkrc support
- From: Gabriel Burt <gburt src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [banshee] [GtkBaseClient] Added --debug-gtkrc support
- Date: Wed, 5 May 2010 20:06:56 +0000 (UTC)
commit 77c017dc376d830a121618e9737546163491bafb
Author: Aaron Bockover <abockover novell com>
Date: Mon May 3 18:14:02 2010 -0400
[GtkBaseClient] Added --debug-gtkrc support
If this option is passed, gtkrc files will be reloaded if modified since
the last load, and all styles will be reparsed. This is quite useful
when hacking on gtkrc files that affect Banshee.
.../Banshee.Gui/GtkBaseClient.cs | 11 +++++++++++
1 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/src/Core/Banshee.ThickClient/Banshee.Gui/GtkBaseClient.cs b/src/Core/Banshee.ThickClient/Banshee.Gui/GtkBaseClient.cs
index 41db508..0dc4ae5 100644
--- a/src/Core/Banshee.ThickClient/Banshee.Gui/GtkBaseClient.cs
+++ b/src/Core/Banshee.ThickClient/Banshee.Gui/GtkBaseClient.cs
@@ -108,6 +108,17 @@ namespace Banshee.Gui
GLib.Thread.Init ();
}
Gtk.Application.Init ();
+
+ if (ApplicationContext.CommandLine.Contains ("debug-gtkrc")) {
+ Log.Information ("Note: gtkrc files will be checked for reload every 5 seconds!");
+ GLib.Timeout.Add (5000, delegate {
+ if (Gtk.Rc.ReparseAll ()) {
+ Gtk.Rc.ResetStyles (Gtk.Settings.Default);
+ Log.Information ("gtkrc has been reloaded");
+ }
+ return true;
+ });
+ }
}
protected virtual void PostInitializeGtk ()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]