Skip to content

Commit b100ec6

Browse files
authored
SourceDialog: only pack type_box when needed (#924)
1 parent 18654f3 commit b100ec6

1 file changed

Lines changed: 5 additions & 6 deletions

File tree

src/SourceDialog/SourceDialog.vala

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -108,11 +108,6 @@ public class Maya.View.SourceDialog : Granite.Dialog {
108108
list_store.set (iter, 0, backend.get_name (), 1, backend);
109109
}
110110

111-
if (backends_manager.backends.size <= 1) {
112-
type_combobox.no_show_all = true;
113-
type_label.no_show_all = true;
114-
}
115-
116111
type_combobox.set_active (0);
117112

118113
color_button_blue = new Gtk.RadioButton (null) {
@@ -259,7 +254,11 @@ public class Maya.View.SourceDialog : Granite.Dialog {
259254
margin_start = 12,
260255
vexpand = true
261256
};
262-
main_box.add (type_box);
257+
258+
if (backends_manager.backends.size > 1) {
259+
main_box.add (type_box);
260+
}
261+
263262
main_box.add (name_box);
264263
main_box.add (color_box);
265264
main_box.add (is_default_check);

0 commit comments

Comments
 (0)