1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-11-23 17:30:17 +01:00

Dialog for the name of a label: positioning fixes

Problems fixed:
1. When adding a label at playback position, the position of the dialog was calculated using the position of the edit cursor
2. When adding a label at selection, the dialog could be to the left of the Audacity Window, and indeed offscreen.
This commit is contained in:
David Bailes
2018-10-24 11:07:17 +01:00
parent d716b61b1e
commit 5494185a88
3 changed files with 11 additions and 6 deletions

View File

@@ -2102,7 +2102,7 @@ bool LabelTrack::OnChar(SelectedRegion &WXUNUSED(newSel), wxKeyEvent & event)
gPrefs->Read(wxT("/Gui/DialogForNameNewLabel"), &useDialog, false);
if (useDialog) {
wxString title;
if (MenuCommandHandler::DialogForLabelName(*p, charCode, title) ==
if (MenuCommandHandler::DialogForLabelName(*p, p->mViewInfo.selectedRegion, charCode, title) ==
wxID_CANCEL) {
return false;
}