summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-07-26 00:53:17 +0100
committerCarl Hetherington <cth@carlh.net>2016-07-26 00:53:17 +0100
commit7d50d28d283570b0648450a2dc9448c988c39f46 (patch)
treeb0f7789aee008f8f1505c2bf1b581cff7cc05378 /src
parent7dfeb9c597e2391e262ec070112af22a71542967 (diff)
Expand vertical size of servers list in preferences (#913).
Remove a rather baroque sizer arrangement with a simpler wxBoxSizer which allows EditableLists to grow. There may have been a reason for the more complicated arrangement...
Diffstat (limited to 'src')
-rw-r--r--src/wx/editable_list.h16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/wx/editable_list.h b/src/wx/editable_list.h
index 4b203c0e2..8226c9cac 100644
--- a/src/wx/editable_list.h
+++ b/src/wx/editable_list.h
@@ -54,12 +54,8 @@ public:
, _column (column)
, _edit (0)
{
- wxBoxSizer* s = new wxBoxSizer (wxVERTICAL);
- SetSizer (s);
-
- _table = new wxFlexGridSizer (2, DCPOMATIC_SIZER_X_GAP, DCPOMATIC_SIZER_Y_GAP);
- _table->AddGrowableCol (0, 1);
- s->Add (_table, 1, wxEXPAND);
+ _sizer = new wxBoxSizer (wxHORIZONTAL);
+ SetSizer (_sizer);
long style = wxLC_REPORT | wxLC_SINGLE_SEL;
if (title) {
@@ -75,7 +71,7 @@ public:
_list->InsertColumn (i, ip);
}
- _table->Add (_list, 1, wxEXPAND | wxALL);
+ _sizer->Add (_list, 1, wxEXPAND);
{
wxSizer* s = new wxBoxSizer (wxVERTICAL);
@@ -87,7 +83,7 @@ public:
}
_remove = new wxButton (this, wxID_ANY, _("Remove"));
s->Add (_remove, 0, wxTOP | wxBOTTOM, 2);
- _table->Add (s, 0);
+ _sizer->Add (s, 0, wxLEFT, DCPOMATIC_SIZER_X_GAP);
}
_add->Bind (wxEVT_COMMAND_BUTTON_CLICKED, boost::bind (&EditableList::add_clicked, this));
@@ -128,7 +124,7 @@ public:
void layout ()
{
- _table->Layout ();
+ _sizer->Layout ();
}
boost::signals2::signal<void ()> SelectionChanged;
@@ -238,7 +234,7 @@ private:
wxButton* _edit;
wxButton* _remove;
wxListCtrl* _list;
- wxFlexGridSizer* _table;
+ wxBoxSizer* _sizer;
};
#endif