linux: fix some style issues

This commit is contained in:
Hylke Bons 2012-03-18 19:28:22 +00:00
parent 85d89086f8
commit 63a01375b9
3 changed files with 27 additions and 8 deletions

View file

@ -35,6 +35,7 @@ namespace SparkleShare {
private Label history_label;
private HBox layout_horizontal;
private ComboBox combo_box;
private HBox combo_box_wrapper;
private EventBox content_wrapper;
private ScrolledWindow scrolled_window;
private WebView web_view;
@ -176,9 +177,12 @@ namespace SparkleShare {
if (folders == null)
folders = Controller.Folders;
if (this.combo_box != null && this.combo_box.Parent != null)
this.layout_horizontal.Remove (this.combo_box);
if (this.combo_box_wrapper != null && this.combo_box_wrapper.Parent != null) {
this.layout_horizontal.Remove (this.combo_box_wrapper);
this.combo_box_wrapper.Remove (this.combo_box);
}
this.combo_box_wrapper = new HBox (false, 0);
this.combo_box = new ComboBox ();
CellRendererText cell = new CellRendererText();
@ -220,8 +224,11 @@ namespace SparkleShare {
Controller.SelectedFolder = selection;
};
this.combo_box_wrapper.PackStart (new Label (" "), false, false, 9);
this.combo_box_wrapper.PackStart (this.combo_box, true, true, 0);
this.layout_horizontal.BorderWidth = 9;
this.layout_horizontal.PackStart (this.combo_box, true, true, 0);
this.layout_horizontal.PackStart (this.combo_box_wrapper, true, true, 0);
this.layout_horizontal.ShowAll ();
}

View file

@ -189,8 +189,19 @@ namespace SparkleShare {
Sensitive = (Controller.SelectedPlugin.Path == null)
};
Label address_example = new Label ("1") { Xalign = 0, UseMarkup = true };
Label path_example = new Label ("2") { Xalign = 0, UseMarkup = true };
Label address_example = new Label () {
Xalign = 0,
UseMarkup = true,
Markup = "<span size=\"small\" fgcolor=\"" +
SecondaryTextColor + "\">" + Controller.SelectedPlugin.AddressExample + "</span>"
};
Label path_example = new Label () {
Xalign = 0,
UseMarkup = true,
Markup = "<span size=\"small\" fgcolor=\"" +
SecondaryTextColor + "\">" + Controller.SelectedPlugin.PathExample + "</span>"
};
// Select the first plugin by default
@ -220,7 +231,8 @@ namespace SparkleShare {
+ SecondaryTextColor + "\">" + example_text + "</span>";
});
};
Controller.CheckAddPage (address_entry.Text, path_entry.Text, 1);
// Update the address field text when the selection changes
tree.CursorChanged += delegate (object sender, EventArgs e) {
@ -319,7 +331,7 @@ namespace SparkleShare {
AddButton (cancel_button);
AddButton (add_button);
Controller.CheckAddPage (address_entry.Text, path_entry.Text, 1);
break;
}

View file

@ -281,7 +281,7 @@ namespace SparkleShare {
notify_item.Activated += delegate {
Program.Controller.ToggleNotifications ();
CreateMenu ();
// CreateMenu ();
};
this.menu.Add (notify_item);