diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/wx/audio_mapping_view.cc | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/src/wx/audio_mapping_view.cc b/src/wx/audio_mapping_view.cc index 2413502b8..67ece1f7b 100644 --- a/src/wx/audio_mapping_view.cc +++ b/src/wx/audio_mapping_view.cc @@ -261,10 +261,18 @@ AudioMappingView::paint_row_labels (wxDC& dc) ); } - /* Group labels and lines */ - int y = TOP_HEIGHT; - for (auto i: _input_groups) { + for (auto const& i: _input_groups) { + dc.DrawLine (wxPoint(MINIMUM_COLUMN_WIDTH, y), wxPoint(MINIMUM_COLUMN_WIDTH * 2, y)); + y += (i.to - i.from + 1) * ROW_HEIGHT; + } + dc.DrawLine (wxPoint(MINIMUM_COLUMN_WIDTH, y), wxPoint(MINIMUM_COLUMN_WIDTH * 2, y)); + + /* Group labels and lines; be careful here as wxDCClipper does not restore the old + * clipping rectangle after it is destroyed + */ + y = TOP_HEIGHT; + for (auto const& i: _input_groups) { int const height = (i.to - i.from + 1) * ROW_HEIGHT; dc.GetTextExtent (std_to_wx(i.name), &label_width, &label_height); if (label_width > height) { @@ -286,11 +294,8 @@ AudioMappingView::paint_row_labels (wxDC& dc) ); } - dc.DrawLine (wxPoint(MINIMUM_COLUMN_WIDTH, y), wxPoint(MINIMUM_COLUMN_WIDTH * 2, y)); y += height; } - - dc.DrawLine (wxPoint(MINIMUM_COLUMN_WIDTH, y), wxPoint(MINIMUM_COLUMN_WIDTH * 2, y)); } void |
