mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-09-16 16:30:26 +02:00
2024-02-06 Fred Gleason <fredg@paravelsystems.com>
* Fixed a regression in rdairplay(1) that could cause the space bar to fail to start the next main log event. Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
parent
5895a7ca58
commit
f76691bae2
@ -24635,3 +24635,6 @@
|
||||
* Changed the 'AUDIO_CARDS.NAME' database field from 'varchar(64)'
|
||||
to 'text'.
|
||||
* Incremented the database version to 373.
|
||||
2024-02-06 Fred Gleason <fredg@paravelsystems.com>
|
||||
* Fixed a regression in rdairplay(1) that could cause the space bar
|
||||
to fail to start the next main log event.
|
||||
|
@ -2,7 +2,7 @@
|
||||
//
|
||||
// Rivendell Voice Tracker
|
||||
//
|
||||
// (C) Copyright 2002-2022 Fred Gleason <fredg@paravelsystems.com>
|
||||
// (C) Copyright 2002-2024 Fred Gleason <fredg@paravelsystems.com>
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License version 2 as
|
||||
@ -69,6 +69,7 @@ RDTrackerWidget::RDTrackerWidget(QString *import_path,QWidget *parent)
|
||||
d_menu_clicked_point=-1;
|
||||
d_shift_pressed=false;
|
||||
d_active=false;
|
||||
d_focus_policy=Qt::WheelFocus;
|
||||
|
||||
//
|
||||
// Create Palettes
|
||||
@ -428,6 +429,25 @@ bool RDTrackerWidget::isActive() const
|
||||
}
|
||||
|
||||
|
||||
void RDTrackerWidget::setFocusPolicy(Qt::FocusPolicy pol)
|
||||
{
|
||||
d_focus_policy=pol;
|
||||
d_play_button->setFocusPolicy(pol);
|
||||
d_stop_button->setFocusPolicy(pol);
|
||||
d_track1_button->setFocusPolicy(pol);
|
||||
d_record_button->setFocusPolicy(pol);
|
||||
d_track2_button->setFocusPolicy(pol);
|
||||
d_finished_button->setFocusPolicy(pol);
|
||||
d_post_button->setFocusPolicy(pol);
|
||||
d_reset_button->setFocusPolicy(pol);
|
||||
d_previous_button->setFocusPolicy(pol);
|
||||
d_next_button->setFocusPolicy(pol);
|
||||
d_insert_button->setFocusPolicy(pol);
|
||||
d_delete_button->setFocusPolicy(pol);
|
||||
d_log_view->setFocusPolicy(pol);
|
||||
}
|
||||
|
||||
|
||||
bool RDTrackerWidget::load(const QString &logname)
|
||||
{
|
||||
QString username;
|
||||
@ -3507,15 +3527,19 @@ void RDTrackerWidget::UpdateControls()
|
||||
d_track1_button->setPalette(d_record_palette);
|
||||
d_record_button->setEnabled(!d_group->name().isEmpty());
|
||||
d_record_button->setText(tr("Record"));
|
||||
if(d_focus_policy!=Qt::NoFocus) {
|
||||
d_record_button->setFocus();
|
||||
}
|
||||
}
|
||||
else {
|
||||
if((logline->transType()==RDLogLine::Segue)) {
|
||||
d_track1_button->
|
||||
setEnabled(!d_group->name().isEmpty());
|
||||
d_track1_button->setText(tr("Start"));
|
||||
d_track1_button->setPalette(d_start_palette);
|
||||
if(d_focus_policy!=Qt::NoFocus) {
|
||||
d_track1_button->setFocus();
|
||||
}
|
||||
d_record_button->
|
||||
setEnabled(!d_group->name().isEmpty());
|
||||
d_record_button->setText(tr("Import"));
|
||||
@ -3528,9 +3552,11 @@ void RDTrackerWidget::UpdateControls()
|
||||
d_record_button->
|
||||
setEnabled(!d_group->name().isEmpty());
|
||||
d_record_button->setText(tr("Record"));
|
||||
if(d_focus_policy!=Qt::NoFocus) {
|
||||
d_record_button->setFocus();
|
||||
}
|
||||
}
|
||||
}
|
||||
d_track2_button->setDisabled(true);
|
||||
d_finished_button->setPalette(d_done_palette);
|
||||
d_finished_button->setText(tr("Save"));
|
||||
@ -3553,7 +3579,9 @@ void RDTrackerWidget::UpdateControls()
|
||||
d_track1_button->setPalette(d_start_palette);
|
||||
d_record_button->setEnabled(true);
|
||||
d_record_button->setText(tr("Record"));
|
||||
if(d_focus_policy!=Qt::NoFocus) {
|
||||
d_record_button->setFocus();
|
||||
}
|
||||
d_track2_button->setDisabled(true);
|
||||
d_finished_button->setPalette(d_abort_palette);
|
||||
d_finished_button->setText(tr("Abort"));
|
||||
@ -3578,7 +3606,9 @@ void RDTrackerWidget::UpdateControls()
|
||||
if(d_wave_name[2].isEmpty()) {
|
||||
d_finished_button->setPalette(d_done_palette);
|
||||
d_finished_button->setText(tr("Save"));
|
||||
if(d_focus_policy!=Qt::NoFocus) {
|
||||
d_finished_button->setFocus();
|
||||
}
|
||||
d_track2_button->setDisabled(true);
|
||||
}
|
||||
else {
|
||||
@ -3598,8 +3628,10 @@ void RDTrackerWidget::UpdateControls()
|
||||
d_finished_button->setPalette(d_done_palette);
|
||||
d_track2_button->setDisabled(true);
|
||||
}
|
||||
if(d_focus_policy!=Qt::NoFocus) {
|
||||
d_track2_button->setFocus();
|
||||
}
|
||||
}
|
||||
d_finished_button->setEnabled(true);
|
||||
d_reset_button->setDisabled(true);
|
||||
d_insert_button->setDisabled(true);
|
||||
@ -3622,7 +3654,9 @@ void RDTrackerWidget::UpdateControls()
|
||||
d_finished_button->setPalette(d_done_palette);
|
||||
d_finished_button->setText(tr("Save"));
|
||||
d_finished_button->setEnabled(true);
|
||||
if(d_focus_policy!=Qt::NoFocus) {
|
||||
d_finished_button->setFocus();
|
||||
}
|
||||
d_reset_button->setDisabled(true);
|
||||
d_post_button->setDisabled(true);
|
||||
d_insert_button->setDisabled(true);
|
||||
@ -3650,7 +3684,7 @@ void RDTrackerWidget::UpdateControls()
|
||||
d_stop_button->setEnabled(true);
|
||||
d_next_button->setEnabled(transport_idle);
|
||||
d_previous_button->setEnabled(transport_idle);
|
||||
if(transport_idle) {
|
||||
if(transport_idle&&(d_focus_policy!=Qt::NoFocus)) {
|
||||
d_next_button->setFocus();
|
||||
}
|
||||
d_insert_button->setEnabled(transport_idle&&CanInsertTrack());
|
||||
@ -3674,7 +3708,7 @@ void RDTrackerWidget::UpdateControls()
|
||||
d_stop_button->setEnabled(true);
|
||||
d_next_button->setEnabled(transport_idle);
|
||||
d_previous_button->setEnabled(transport_idle);
|
||||
if(transport_idle) {
|
||||
if(transport_idle&&(d_focus_policy!=Qt::NoFocus)) {
|
||||
d_next_button->setFocus();
|
||||
}
|
||||
d_insert_button->setEnabled(transport_idle&&CanInsertTrack());
|
||||
|
@ -2,7 +2,7 @@
|
||||
//
|
||||
// Rivendell Voice Tracker
|
||||
//
|
||||
// (C) Copyright 2002-2021 Fred Gleason <fredg@paravelsystems.com>
|
||||
// (C) Copyright 2002-2024 Fred Gleason <fredg@paravelsystems.com>
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License version 2 as
|
||||
@ -70,6 +70,7 @@ class RDTrackerWidget : public RDWidget
|
||||
QSize sizeHint() const;
|
||||
QSizePolicy sizePolicy() const;
|
||||
bool isActive() const;
|
||||
void setFocusPolicy(Qt::FocusPolicy pol);
|
||||
|
||||
signals:
|
||||
void activeChanged(bool state);
|
||||
@ -219,7 +220,6 @@ class RDTrackerWidget : public RDWidget
|
||||
QPushButton *d_next_button;
|
||||
QPushButton *d_insert_button;
|
||||
QPushButton *d_delete_button;
|
||||
// QPushButton *d_close_button;
|
||||
RDEventPlayer *d_event_player;
|
||||
unsigned d_tracks;
|
||||
int d_time_remaining;
|
||||
@ -273,7 +273,7 @@ class RDTrackerWidget : public RDWidget
|
||||
QLabel *d_tracks_remaining_label_label;
|
||||
QLabel *d_time_remaining_label_label;
|
||||
QLabel *d_time_label;
|
||||
|
||||
Qt::FocusPolicy d_focus_policy;
|
||||
bool d_active;
|
||||
};
|
||||
|
||||
|
@ -26,6 +26,8 @@
|
||||
ModeDisplay::ModeDisplay(QWidget *parent)
|
||||
: RDPushButton(parent)
|
||||
{
|
||||
setFocusPolicy(Qt::NoFocus);
|
||||
|
||||
for(int i=0;i<RDAIRPLAY_LOG_QUANTITY;i++) {
|
||||
mode_mode[i]=RDAirPlayConf::Previous;
|
||||
}
|
||||
|
@ -29,6 +29,8 @@
|
||||
PostCounter::PostCounter(QWidget *parent)
|
||||
: RDPushButton(parent)
|
||||
{
|
||||
setFocusPolicy(Qt::NoFocus);
|
||||
|
||||
post_running=false;
|
||||
post_time_format="hh:mm:ss";
|
||||
post_time=QTime();
|
||||
|
@ -27,6 +27,8 @@ SoundPanel::SoundPanel(RDEventPlayer *player,RDCartDialog *cart_dialog,
|
||||
bool dump_panel_updates,QWidget *parent)
|
||||
: RDWidget(parent)
|
||||
{
|
||||
setFocusPolicy(Qt::NoFocus);
|
||||
|
||||
d_panel=
|
||||
new RDSoundPanel(rda->airplayConf()->panels(RDAirPlayConf::StationPanel),
|
||||
rda->airplayConf()->panels(RDAirPlayConf::UserPanel),
|
||||
|
@ -28,6 +28,8 @@
|
||||
StopCounter::StopCounter(QWidget *parent)
|
||||
: RDPushButton(parent)
|
||||
{
|
||||
setFocusPolicy(Qt::NoFocus);
|
||||
|
||||
stop_running=false;
|
||||
|
||||
stop_text=tr("Next Stop [none]");
|
||||
|
@ -27,12 +27,22 @@ VoiceTracker::VoiceTracker(QWidget *parent)
|
||||
: RDWidget(parent)
|
||||
{
|
||||
d_tracker_widget=new RDTrackerWidget(&d_import_path,this);
|
||||
if(rda->airplayConf()->barAction()==RDAirPlayConf::StartNext) {
|
||||
d_tracker_widget->setFocusPolicy(Qt::NoFocus);
|
||||
}
|
||||
else {
|
||||
d_tracker_widget->setFocusPolicy(Qt::StrongFocus);
|
||||
}
|
||||
|
||||
d_load_button=new QPushButton(tr("Load\nLog"),this);
|
||||
d_load_button->setFont(bigButtonFont());
|
||||
d_load_button->setFocusPolicy(Qt::NoFocus);
|
||||
|
||||
connect(d_load_button,SIGNAL(clicked()),this,SLOT(loadData()));
|
||||
connect(d_tracker_widget,SIGNAL(activeChanged(bool)),
|
||||
d_load_button,SLOT(setDisabled(bool)));
|
||||
|
||||
setFocusPolicy(Qt::NoFocus);
|
||||
}
|
||||
|
||||
|
||||
|
@ -29,6 +29,8 @@
|
||||
WallClock::WallClock(QWidget *parent)
|
||||
: RDPushButton(parent)
|
||||
{
|
||||
setFocusPolicy(Qt::NoFocus);
|
||||
|
||||
previous_time=QTime::currentTime();
|
||||
show_date=true;
|
||||
check_sync=true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user