[log] return day headers background colour

This commit is contained in:
Hylke Bons 2010-08-27 00:11:19 +01:00
parent 1e731fb92e
commit de8c566486
3 changed files with 13 additions and 5 deletions

View file

@ -35,7 +35,7 @@ namespace SparkleShare {
Add (label); Add (label);
// Only make links for files that exist // Only make links for files that exist
if (!File.Exists (url)) if (!url.StartsWith ("http://") && !File.Exists (url))
return; return;
// Use Tango blue for the links // Use Tango blue for the links
@ -44,10 +44,10 @@ namespace SparkleShare {
label.ModifyFg (StateType.Normal, color); label.ModifyFg (StateType.Normal, color);
// Open the URL when it is clicked // Open the URL when it is clicked
ButtonPressEvent += delegate { ButtonReleaseEvent += delegate {
Process process = new Process (); Process process = new Process ();
process.StartInfo.FileName = "xdg-open"; process.StartInfo.FileName = "gnome-open";
process.StartInfo.Arguments = url.Replace (" ", "\\ "); // Escape space-characters process.StartInfo.Arguments = url.Replace (" ", "\\ "); // Escape space-characters
process.Start (); process.Start ();

View file

@ -215,8 +215,11 @@ namespace SparkleShare {
foreach (ActivityDay activity_day in activity_days) { foreach (ActivityDay activity_day in activity_days) {
EventBox box = new EventBox ();
Label date_label = new Label ("") { Label date_label = new Label ("") {
UseMarkup = true, UseMarkup = true,
Xalign = 0,
Xpad = 9, Xpad = 9,
Ypad = 9 Ypad = 9
}; };
@ -242,7 +245,8 @@ namespace SparkleShare {
} }
layout_vertical.PackStart (date_label, true, true, 0); box.Add (date_label);
layout_vertical.PackStart (box, true, true, 0);
Gdk.Color color = Style.Foreground (StateType.Insensitive); Gdk.Color color = Style.Foreground (StateType.Insensitive);
string secondary_text_color = GdkColorToHex (color); string secondary_text_color = GdkColorToHex (color);
@ -261,7 +265,7 @@ namespace SparkleShare {
link.ModifyBg (StateType.Normal, background_color); link.ModifyBg (StateType.Normal, background_color);
link.ButtonPressEvent += delegate { link.ButtonReleaseEvent += delegate {
Destroy (); Destroy ();
}; };

View file

@ -127,11 +127,15 @@ namespace SparkleShare {
} }
// Recursively gets a folder's size in bytes
private double GetFolderSize (DirectoryInfo parent) private double GetFolderSize (DirectoryInfo parent)
{ {
double size = 0; double size = 0;
// Ignore the temporary rebase-apply directory.
// This prevents potential crashes when files are being
// queried whilst the files have already been deleted.
if (parent.Name.Equals ("rebase-apply")) if (parent.Name.Equals ("rebase-apply"))
return 0; return 0;