Project Evil: allow SparkleShare to take full http(s) URIs without choking.

This commit is contained in:
Alex Hudson 2011-06-30 12:53:05 +01:00
parent 4797999952
commit f61212b930
2 changed files with 10 additions and 1 deletions

View file

@ -30,6 +30,12 @@ namespace SparkleLib {
{
remote_folder = remote_folder.Trim ("/".ToCharArray ());
if (server.StartsWith("http")) {
base.target_folder = target_folder;
base.remote_url = server;
return;
}
// Gitorious formatting
if (server.Contains ("gitorious.org")) {
server = "ssh://git@gitorious.org";

View file

@ -396,7 +396,10 @@ namespace SparkleShare {
};
accept_button.Clicked += delegate {
string url = "ssh://git@" + server + "/" + folder;
string url = "ssh://git@" + server + "/" + folder;
if (server.StartsWith("http")) {
url = server;
}
SparkleShare.Controller.FolderFetched += delegate {
Application.Invoke (delegate {