Fix Linux build

This commit is contained in:
Hylke Bons 2012-02-19 21:33:25 +01:00
parent 51758c5385
commit 135e2fe73f
7 changed files with 25 additions and 19 deletions

View file

@ -91,7 +91,8 @@ namespace SparkleLib {
this.is_connected = false;
this.is_connecting = false;
this.socket.Dispose ();
if (this.socket != null)
this.socket.Close ();
OnDisconnected (e.Message);
return;
@ -158,7 +159,8 @@ namespace SparkleLib {
this.is_connected = false;
this.is_connecting = false;;
this.socket.Dispose ();
if (this.socket != null)
this.socket.Close ();
OnDisconnected ("Ping timeout");
return;
@ -244,6 +246,9 @@ namespace SparkleLib {
this.thread.Abort ();
this.thread.Join ();
if (this.socket != null)
this.socket.Close ();
base.Dispose ();
}

View file

@ -23,8 +23,8 @@ SOURCES = \
SparkleEventLog.cs \
SparkleEventLogController.cs \
SparkleExtensions.cs \
SparkleOptions.cs \
SparkleInvite.cs \
SparkleOptions.cs \
SparklePlugin.cs \
SparkleSetup.cs \
SparkleSetupController.cs \

View file

@ -74,6 +74,12 @@ namespace SparkleShare {
SparkleHelpers.DebugInfo ("Controller", "Enabled autostart on login");
}
}
public override void InstallProtocolHandler ()
{
// TODO
}
// Adds the SparkleShare folder to the user's

View file

@ -94,10 +94,6 @@ namespace SparkleShare {
// Enables SparkleShare to start automatically at login
public abstract void EnableSystemAutostart ();
// Installs a launcher so the user can launch SparkleShare
// from the Internet category if needed
public abstract void InstallLauncher ();
// Installs the sparkleshare:// protocol handler
public abstract void InstallProtocolHandler ();
@ -136,7 +132,6 @@ namespace SparkleShare {
public virtual void Initialize ()
{
InstallLauncher ();
EnableSystemAutostart ();
InstallProtocolHandler ();

View file

@ -57,7 +57,7 @@ namespace SparkleShare {
Title = _("Recent Events");
IconName = "folder-sparkleshare";
DeleteEvent += Close (object o, DeleteEventArgs args) {
DeleteEvent += delegate (object o, DeleteEventArgs args) {
Controller.WindowClosed ();
args.RetVal = true;
};
@ -269,15 +269,15 @@ namespace SparkleShare {
AddAccelGroup (accel_group);
// Close on Esc
close_1.AddAccelerator ("activate", accel_group, new AccelKey (Gdk.Key.W, Gdk.ModifierType.ControlMask,
AccelFlags.Visible));
close_1.AddAccelerator ("activate", accel_group, new AccelKey (Gdk.Key.W,
Gdk.ModifierType.ControlMask, AccelFlags.Visible));
close_1.Activated += delegate { HideAll (); };
close_1.Activated += delegate { Controller.WindowClosed (); };
// Close on Ctrl+W
close_2.AddAccelerator ("activate", accel_group, new AccelKey (Gdk.Key.Escape, Gdk.ModifierType.None,
AccelFlags.Visible));
close_2.Activated += delegate { HideAll (); };
close_2.AddAccelerator ("activate", accel_group, new AccelKey (Gdk.Key.Escape,
Gdk.ModifierType.None, AccelFlags.Visible));
close_2.Activated += delegate { Controller.WindowClosed (); };
file_menu.Append (close_1);
file_menu.Append (close_2);

View file

@ -287,7 +287,7 @@ namespace SparkleShare {
};
layout_address.PackStart (new Label () {
Markup = "<b>" + _("Address") + "</b>",
Markup = "<b>" + _("Address:") + "</b>",
Xalign = 0
}, true, true, 0);
@ -308,7 +308,7 @@ namespace SparkleShare {
};
layout_path.PackStart (new Label () {
Markup = "<b>" + _("Remote Path") + "</b>",
Markup = "<b>" + _("Remote Path:") + "</b>",
Xalign = 0
}, true, true, 0);
@ -476,7 +476,7 @@ namespace SparkleShare {
Button finish_button = new Button (_("Finish"));
finish_button.Clicked += delegate {
Controller.FinishedPageCompleted ();
Controller.FinishPageCompleted ();
};

View file

@ -64,7 +64,7 @@ namespace SparkleShare {
StatusIcon = new SparkleStatusIcon ();
if (Program.Controller.FirstRun)
Program.Controller.ShowSetupWindow (PageType.Setup)
Program.Controller.ShowSetupWindow (PageType.Setup);
}