Implemented new hotkeys for audio mode

Originally committed to SVN as r722.
This commit is contained in:
Rodrigo Braz Monteiro 2007-01-06 04:27:09 +00:00
parent 1a948d3bb9
commit 1d647a9b09
4 changed files with 25 additions and 1 deletions

View file

@ -130,7 +130,7 @@ wxPanel(parent,-1,wxDefaultPosition,wxDefaultSize,wxTAB_TRAVERSAL|wxBORDER_RAISE
temp->SetToolTip(_("Play current line (") + Hotkeys.GetText(_T("Audio Play Original Line")) + _T(")"));
ButtonSizer->Add(temp,0,wxRIGHT,0);
temp = new wxBitmapButton(this,Audio_Button_Stop,wxBITMAP(button_stop),wxDefaultPosition,wxSize(30,-1));
temp->SetToolTip(_("Stop"));
temp->SetToolTip(_("Stop (") + Hotkeys.GetText(_T("Audio Stop")) + _T(")"));
ButtonSizer->Add(temp,0,wxRIGHT,10);
temp = new wxBitmapButton(this,Audio_Button_Play_500ms_Before,wxBITMAP(button_play500before),wxDefaultPosition,wxSize(30,-1));

View file

@ -1946,6 +1946,21 @@ void AudioDisplay::OnKeyDown(wxKeyEvent &event) {
Play(start,end);
}
// Play/Stop
if (Hotkeys.IsPressed(_T("Audio Play or Stop"))) {
if (player->IsPlaying()) Stop();
else {
int start=0,end=0;
GetTimesSelection(start,end);
Play(start,end);
}
}
// Stop
if (Hotkeys.IsPressed(_T("Audio Stop"))) {
Stop();
}
// Increase length
if (Hotkeys.IsPressed(_T("Audio Karaoke Increase Len"))) {
if (karaoke->enabled) {

View file

@ -66,6 +66,13 @@ Please visit http://aegisub.net to download latest version
- Added a Call Tip feature to the edit box, so it shows the function prototype as you type it. (AMZ)
- Added a much-needed options dialog with all the relevant config.dat options in it. (AMZ)
- Added a Normal/Reverse dropdown to collisions on Script Properties. (AMZ)
- Several changes to audio mode (AMZ):
o Normal and SSA mode have been merged into one, all functionality available to both is now used at once. This is the same behavior as Sabbu has. (AMZ)
o Next line on commit is now on by default.
o Auto-commit will never change to the next line.
o When dragging line start/end markers, they will snap to keyframes or nearby subtitle start/end markers.
o The "Play" shortcut will always play, regardless of whether it was already playing or not. There is a new shortcut for "Stop".
o Styles for line start/end markers have changed.
= 1.10 beta - 2006.08.07 ===========================

View file

@ -368,6 +368,8 @@ void HotkeyManager::LoadDefaults() {
SetHotkey(_("Audio Next Line Alt"),_T("X"));
SetHotkey(_("Audio Play"),_T("Space"));
SetHotkey(_("Audio Play Alt"),_T("S"));
SetHotkey(_("Audio Play or Stop"),_T("B"));
SetHotkey(_("Audio Stop"),_T("H"));
SetHotkey(_("Audio Karaoke Increase Len"),_T("KP_Add"));
SetHotkey(_("Audio Karaoke Decrease Len"),_T("KP_Subtract"));
SetHotkey(_("Audio Karaoke Increase Len Shift"),_T("Shift-KP_Add"));