check adddialog entry fields kinda
This commit is contained in:
parent
17570f4d23
commit
161fcd1ec3
|
@ -96,6 +96,10 @@ namespace SparkleShare {
|
||||||
IconLookupFlags.GenericFallback);
|
IconLookupFlags.GenericFallback);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static bool IsGitUrl (string Url) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -468,6 +468,8 @@ namespace SparkleShare {
|
||||||
RemoteUrlExample.SetAlignment (0, 0);
|
RemoteUrlExample.SetAlignment (0, 0);
|
||||||
RemoteUrlLabel.Xalign = 1;
|
RemoteUrlLabel.Xalign = 1;
|
||||||
|
|
||||||
|
// NameEntry.Text;
|
||||||
|
|
||||||
HButtonBox ButtonBox = new HButtonBox ();
|
HButtonBox ButtonBox = new HButtonBox ();
|
||||||
ButtonBox.Layout = ButtonBoxStyle.End;
|
ButtonBox.Layout = ButtonBoxStyle.End;
|
||||||
ButtonBox.Spacing = 6;
|
ButtonBox.Spacing = 6;
|
||||||
|
@ -480,7 +482,17 @@ namespace SparkleShare {
|
||||||
AddDialog.Destroy ();
|
AddDialog.Destroy ();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
AddButton.State = StateType.Insensitive;
|
||||||
AddButton.Clicked += delegate {
|
AddButton.Clicked += delegate {
|
||||||
|
RemoteUrlCombo.Entry.Changed += delegate {
|
||||||
|
if (SparkleHelpers.IsGitUrl (RemoteUrlCombo.Entry.Text))
|
||||||
|
AddButton.State = StateType.Normal;
|
||||||
|
};
|
||||||
|
|
||||||
|
RemoteUrlCombo.Entry.Changed += delegate {
|
||||||
|
if (RemoteUrlCombo.Entry.Text.Length > 0)
|
||||||
|
AddButton.State = StateType.Normal;
|
||||||
|
};
|
||||||
|
|
||||||
AddDialog.Remove (AddDialog.Child);
|
AddDialog.Remove (AddDialog.Child);
|
||||||
VBox Box = new VBox (false, 24);
|
VBox Box = new VBox (false, 24);
|
||||||
|
|
Loading…
Reference in a new issue