diff --git a/src/midi_smfin.cpp b/src/midi_smfin.cpp index 0678ccb..0197855 100644 --- a/src/midi_smfin.cpp +++ b/src/midi_smfin.cpp @@ -85,7 +85,7 @@ class LoadSmfDialog : public wxDialog { auto channels_lbl = new wxStaticText(this, ID_Tracks_Text, _("Channels (&C):")); dlg_sizer->Add(channels_lbl); - auto chan_grid = new wxGridSizer(4, 4, 3, 3); + auto chan_grid = new wxGridSizer(4, 4, 5, 5); dlg_sizer->Add(chan_grid); for (int i = 0; i < 16; i++) { diff --git a/src/wavsplit.cpp b/src/wavsplit.cpp index ed6b044..96ce8b5 100644 --- a/src/wavsplit.cpp +++ b/src/wavsplit.cpp @@ -71,8 +71,7 @@ void SplitFile( } std::vector GetSplitPoints(Division *pDivision, double bpm, double offset_ms) { - std::vector ret; - ret.reserve(pDivision->notes_count()); + std::set ret; for (int i = 0; i < pDivision->notes_count(); i++) { auto note = pDivision->notes(i); @@ -80,8 +79,8 @@ std::vector GetSplitPoints(Division *pDivision, double bpm, double offse auto spb = 60 / bpm; auto time = spb * beat + offset_ms / 1000.0; - ret.push_back(time); + ret.insert(time); } - return ret; + return std::vector(ret.begin(), ret.end()); }