mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-11-29 16:50:13 +01:00
2021-06-28 Fred Gleason <fredg@paravelsystems.com>
* Added a shaded rectangle background to the 'Button Log' and right-side widgets in rdairplay(1). Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
@@ -21968,3 +21968,6 @@
|
||||
2021-06-26 Fred Gleason <fredg@paravelsystems.com>
|
||||
* Added an 'AIR_WIDGET_BACKGROUND_COLOR' define to
|
||||
'rdairplay/colors.h'.
|
||||
2021-06-28 Fred Gleason <fredg@paravelsystems.com>
|
||||
* Added a shaded rectangle background to the 'Button Log' and
|
||||
right-side widgets in rdairplay(1).
|
||||
|
||||
@@ -350,8 +350,8 @@ void RDSoundPanel::setColor(RDAirPlayConf::PanelType type,int panel,int row,
|
||||
}
|
||||
|
||||
|
||||
void RDSoundPanel::duckVolume(RDAirPlayConf::PanelType type,int panel,int row,int col,
|
||||
int level,int fade,int mport)
|
||||
void RDSoundPanel::duckVolume(RDAirPlayConf::PanelType type,int panel,int row,
|
||||
int col,int level,int fade,int mport)
|
||||
{
|
||||
int edit_mport=mport;
|
||||
if (edit_mport==0) {
|
||||
@@ -363,12 +363,13 @@ void RDSoundPanel::duckVolume(RDAirPlayConf::PanelType type,int panel,int row,in
|
||||
panel_buttons[PanelOffset(type,panel)]->panelButton(j,i)->playDeck();
|
||||
if((row==j || row==-1) && (col==i || col==-1)) {
|
||||
if(mport==-1) {
|
||||
panel_buttons[PanelOffset(type,panel)]->panelButton(j,i)->setDuckVolume(level);
|
||||
panel_buttons[PanelOffset(type,panel)]->panelButton(j,i)->
|
||||
setDuckVolume(level);
|
||||
}
|
||||
if(deck!=NULL) {
|
||||
if(edit_mport==-1 ||
|
||||
edit_mport==panel_buttons[PanelOffset(type,panel)]->panelButton(j,i)->
|
||||
outputText().toInt()) {
|
||||
edit_mport==panel_buttons[PanelOffset(type,panel)]->
|
||||
panelButton(j,i)->outputText().toInt()) {
|
||||
deck->duckVolume(level,fade);
|
||||
}
|
||||
}
|
||||
@@ -912,7 +913,7 @@ void RDSoundPanel::wheelEvent(QWheelEvent *e)
|
||||
|
||||
void RDSoundPanel::UpdateButtonViewport()
|
||||
{
|
||||
QRect viewport(0,0,size().width()-10,size().height()-60);
|
||||
QRect viewport(0,0,size().width()-5,size().height()-60);
|
||||
RDButtonPanel *panel=panel_buttons[PanelOffset(panel_type,panel_number)];
|
||||
for(int i=0;i<panel_button_rows;i++) {
|
||||
for(int j=0;j<panel_button_columns;j++) {
|
||||
|
||||
@@ -56,6 +56,7 @@ dist_rdairplay_SOURCES = button_log.cpp button_log.h\
|
||||
pie_counter.cpp pie_counter.h\
|
||||
post_counter.cpp post_counter.h\
|
||||
rdairplay.cpp rdairplay.h\
|
||||
soundpanel.cpp soundpanel.h\
|
||||
start_button.cpp start_button.h\
|
||||
stop_counter.cpp stop_counter.h\
|
||||
topstrip.cpp topstrip.h\
|
||||
@@ -74,6 +75,7 @@ nodist_rdairplay_SOURCES = moc_button_log.cpp\
|
||||
moc_pie_counter.cpp\
|
||||
moc_post_counter.cpp\
|
||||
moc_rdairplay.cpp\
|
||||
moc_soundpanel.cpp\
|
||||
moc_start_button.cpp\
|
||||
moc_stop_counter.cpp\
|
||||
moc_topstrip.cpp\
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
//
|
||||
|
||||
#include <QMessageBox>
|
||||
#include <QPainter>
|
||||
|
||||
#include <rdapplication.h>
|
||||
#include <rdconf.h>
|
||||
@@ -893,14 +894,14 @@ void ListLog::resizeEvent(QResizeEvent *e)
|
||||
// Hour Selector
|
||||
//
|
||||
if(rda->airplayConf()->hourSelectorEnabled()) {
|
||||
list_hour_selector->setGeometry(0,0,size().width(),80);
|
||||
list_hour_selector->setGeometry(5,5,size().width()-10,82);
|
||||
}
|
||||
|
||||
//
|
||||
// Log Items
|
||||
//
|
||||
int list_y=0;
|
||||
int list_h=size().height()-60;
|
||||
int list_y=2;
|
||||
int list_h=size().height()-63;
|
||||
if(rda->airplayConf()->showCounters()) {
|
||||
list_h-=60;
|
||||
}
|
||||
@@ -909,28 +910,28 @@ void ListLog::resizeEvent(QResizeEvent *e)
|
||||
//
|
||||
// Audition Head/Tail Buttons
|
||||
//
|
||||
list_head_button->setGeometry(510,size().height()-55,90,50);
|
||||
list_tail_button->setGeometry(600,size().height()-55,90,50);
|
||||
list_head_button->setGeometry(5+510,size().height()-55,90,50);
|
||||
list_tail_button->setGeometry(5+600,size().height()-55,90,50);
|
||||
|
||||
//
|
||||
// Counters
|
||||
//
|
||||
list_groupbox->setGeometry(695,size().height()-61,153,58);
|
||||
list_stoptime_edit->setGeometry(773,size().height()-45,70,18);
|
||||
list_stoptime_label->setGeometry(703,size().height()-45,65,18);
|
||||
list_endtime_edit->setGeometry(773,size().height()-25,70,18);
|
||||
list_endtime_label->setGeometry(703,size().height()-25,65,18);
|
||||
list_groupbox->setGeometry(5+695,size().height()-61,153,58);
|
||||
list_stoptime_edit->setGeometry(5+773,size().height()-45,70,18);
|
||||
list_stoptime_label->setGeometry(5+703,size().height()-45,65,18);
|
||||
list_endtime_edit->setGeometry(5+773,size().height()-25,70,18);
|
||||
list_endtime_label->setGeometry(5+703,size().height()-25,65,18);
|
||||
|
||||
//
|
||||
// Bottom Buttons
|
||||
//
|
||||
list_take_button->setGeometry(10,size().height()-55,80,50);
|
||||
list_play_button->setGeometry(10,size().height()-55,80,50);
|
||||
list_next_button->setGeometry(90,size().height()-55,80,50);
|
||||
list_modify_button->setGeometry(170,size().height()-55,80,50);
|
||||
list_scroll_button->setGeometry(250,size().height()-55,80,50);
|
||||
list_refresh_button->setGeometry(330,size().height()-55,80,50);
|
||||
list_load_button->setGeometry(410,size().height()-55,
|
||||
list_take_button->setGeometry(5+10,size().height()-55,80,50);
|
||||
list_play_button->setGeometry(5+10,size().height()-55,80,50);
|
||||
list_next_button->setGeometry(5+90,size().height()-55,80,50);
|
||||
list_modify_button->setGeometry(5+170,size().height()-55,80,50);
|
||||
list_scroll_button->setGeometry(5+250,size().height()-55,80,50);
|
||||
list_refresh_button->setGeometry(5+330,size().height()-55,80,50);
|
||||
list_load_button->setGeometry(5+410,size().height()-55,
|
||||
80,50);
|
||||
list_h+=60;
|
||||
}
|
||||
@@ -938,28 +939,30 @@ void ListLog::resizeEvent(QResizeEvent *e)
|
||||
//
|
||||
// Audition Head/Tail Buttons
|
||||
//
|
||||
list_head_button->setGeometry(10,size().height()-113,90,50);
|
||||
list_tail_button->setGeometry(100,size().height()-113,90,50);
|
||||
list_head_button->setGeometry(5+10,size().height()-113,90,50);
|
||||
list_tail_button->setGeometry(5+100,size().height()-113,90,50);
|
||||
|
||||
//
|
||||
// Counters
|
||||
//
|
||||
list_groupbox->setGeometry(333,size().height()-116,158,58);
|
||||
list_stoptime_edit->setGeometry(412,size().height()-100,70,18);
|
||||
list_stoptime_label->setGeometry(342,size().height()-100,65,18);
|
||||
list_endtime_edit->setGeometry(412,size().height()-80,70,18);
|
||||
list_endtime_label->setGeometry(342,size().height()-80,65,18);
|
||||
list_groupbox->setGeometry(5+333,size().height()-116,158,58);
|
||||
list_stoptime_edit->setGeometry(5+412,size().height()-100,70,18);
|
||||
list_stoptime_label->setGeometry(5+342,size().height()-100,65,18);
|
||||
list_endtime_edit->setGeometry(5+412,size().height()-80,70,18);
|
||||
list_endtime_label->setGeometry(5+342,size().height()-80,65,18);
|
||||
|
||||
//
|
||||
// Bottom Buttons
|
||||
//
|
||||
list_take_button->setGeometry(10,size().height()-55,80,50);
|
||||
list_play_button->setGeometry(10,size().height()-55,80,50);
|
||||
list_next_button->setGeometry(90,size().height()-55,80,50);
|
||||
list_modify_button->setGeometry(170,size().height()-55,80,50);
|
||||
list_scroll_button->setGeometry(250,size().height()-55,80,50);
|
||||
list_refresh_button->setGeometry(330,size().height()-55,80,50);
|
||||
list_load_button->setGeometry(410,size().height()-55,80,50);
|
||||
list_take_button->setGeometry(5+10,size().height()-55,80,50);
|
||||
list_play_button->setGeometry(5+10,size().height()-55,80,50);
|
||||
list_next_button->setGeometry(5+90,size().height()-55,80,50);
|
||||
list_modify_button->setGeometry(5+170,size().height()-55,80,50);
|
||||
list_scroll_button->setGeometry(5+250,size().height()-55,80,50);
|
||||
list_refresh_button->setGeometry(5+330,size().height()-55,80,50);
|
||||
list_load_button->setGeometry(5+410,size().height()-55,80,50);
|
||||
|
||||
list_h+=4;
|
||||
}
|
||||
|
||||
if(rda->airplayConf()->hourSelectorEnabled()) {
|
||||
@@ -968,12 +971,20 @@ void ListLog::resizeEvent(QResizeEvent *e)
|
||||
list_h-=HOURSELECTOR_BUTTON_EDGE;
|
||||
}
|
||||
else {
|
||||
list_y+=2*HOURSELECTOR_BUTTON_EDGE;
|
||||
list_h-=2*HOURSELECTOR_BUTTON_EDGE;
|
||||
list_y+=(2*HOURSELECTOR_BUTTON_EDGE);
|
||||
list_h-=(2*HOURSELECTOR_BUTTON_EDGE);
|
||||
}
|
||||
}
|
||||
list_log_view->setGeometry(0,list_y,size().width(),list_h);
|
||||
list_log_view->setGeometry(5+0,5+list_y,size().width()-10,list_h-5);
|
||||
}
|
||||
|
||||
|
||||
void ListLog::paintEvent(QPaintEvent *e)
|
||||
{
|
||||
QPainter *p=new QPainter(this);
|
||||
p->fillRect(0,0,size().width(),size().height(),
|
||||
QColor(AIR_WIDGET_BACKGROUND_COLOR));
|
||||
delete p;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -72,6 +72,7 @@ class ListLog : public RDWidget
|
||||
|
||||
protected:
|
||||
void resizeEvent(QResizeEvent *e);
|
||||
void paintEvent(QPaintEvent *e);
|
||||
|
||||
private:
|
||||
enum PlayButtonMode {ButtonDisabled=0,ButtonPlay=1,ButtonStop=2};
|
||||
|
||||
@@ -275,9 +275,11 @@ void MainWidget::RunLocalMacros(RDMacro *rml)
|
||||
label+=(rml->arg(i)+" ");
|
||||
}
|
||||
label=label.left(label.length()-1);
|
||||
air_panel->setText(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
setText(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,label);
|
||||
air_panel->setColor(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
setColor(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,
|
||||
rml->arg(rml->argQuantity()-1));
|
||||
if(rml->echoRequested()) {
|
||||
@@ -312,7 +314,8 @@ void MainWidget::RunLocalMacros(RDMacro *rml)
|
||||
}
|
||||
return;
|
||||
}
|
||||
air_panel->setButton(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
setButton(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,rml->arg(3).toUInt());
|
||||
if(rml->echoRequested()) {
|
||||
rml->acknowledge(true);
|
||||
@@ -489,23 +492,27 @@ void MainWidget::RunLocalMacros(RDMacro *rml)
|
||||
}
|
||||
switch(rml->argQuantity()) {
|
||||
case 3:
|
||||
air_panel->play(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
play(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,RDLogLine::StartMacro);
|
||||
break;
|
||||
|
||||
case 4:
|
||||
air_panel->play(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
play(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,RDLogLine::StartMacro,rml->arg(3).toInt());
|
||||
break;
|
||||
|
||||
case 5:
|
||||
if(rml->arg(4).toInt()==1) {
|
||||
air_panel->play(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
play(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,
|
||||
RDLogLine::StartMacro,rml->arg(3).toInt(),true);
|
||||
}
|
||||
else {
|
||||
air_panel->play(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
play(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,RDLogLine::StartMacro,rml->arg(3).toInt());
|
||||
}
|
||||
break;
|
||||
@@ -629,34 +636,40 @@ void MainWidget::RunLocalMacros(RDMacro *rml)
|
||||
}
|
||||
switch(rml->argQuantity()) {
|
||||
case 3:
|
||||
air_panel->stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1);
|
||||
break;
|
||||
|
||||
case 4:
|
||||
air_panel->stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,rml->arg(3).toInt());
|
||||
break;
|
||||
|
||||
case 5:
|
||||
if(rml->arg(4).toInt()==1) {
|
||||
air_panel->stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,rml->arg(3).toInt(),true);
|
||||
}
|
||||
else {
|
||||
air_panel->stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,rml->arg(3).toInt(),false);
|
||||
}
|
||||
break;
|
||||
|
||||
case 6:
|
||||
if(rml->arg(4).toInt()==1) {
|
||||
air_panel->stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,rml->arg(3).toInt(),true,
|
||||
rml->arg(5).toInt());
|
||||
}
|
||||
else {
|
||||
air_panel->stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
air_panel->soundPanelWidget()->
|
||||
stop(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,rml->arg(3).toInt(),false,
|
||||
rml->arg(5).toInt());
|
||||
}
|
||||
@@ -697,11 +710,13 @@ void MainWidget::RunLocalMacros(RDMacro *rml)
|
||||
return;
|
||||
}
|
||||
if(rml->argQuantity()==3) {
|
||||
ret=air_panel->pause(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
ret=air_panel->soundPanelWidget()->
|
||||
pause(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1);
|
||||
}
|
||||
else {
|
||||
ret=air_panel->pause(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
ret=air_panel->soundPanelWidget()->
|
||||
pause(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,rml->arg(3).toInt());
|
||||
}
|
||||
if(rml->echoRequested()) {
|
||||
@@ -736,13 +751,16 @@ void MainWidget::RunLocalMacros(RDMacro *rml)
|
||||
return;
|
||||
}
|
||||
if(rml->argQuantity()==5) {
|
||||
air_panel->duckVolume(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,(rml->arg(3).toInt())*100,rml->arg(4).toInt());
|
||||
air_panel->soundPanelWidget()->
|
||||
duckVolume(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,(rml->arg(3).toInt())*100,
|
||||
rml->arg(4).toInt());
|
||||
}
|
||||
else {
|
||||
air_panel->duckVolume(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,(rml->arg(3).toInt())*100,rml->arg(4).toInt(),
|
||||
rml->arg(5).toInt());
|
||||
air_panel->soundPanelWidget()->
|
||||
duckVolume(panel_type,panel_number,rml->arg(2).toInt()-1,
|
||||
rml->arg(1).toInt()-1,(rml->arg(3).toInt())*100,
|
||||
rml->arg(4).toInt(),rml->arg(5).toInt());
|
||||
}
|
||||
if(rml->echoRequested()) {
|
||||
rml->acknowledge(true);
|
||||
@@ -955,8 +973,8 @@ bool MainWidget::GetPanel(QString str,RDAirPlayConf::PanelType *type,
|
||||
|
||||
case 'c':
|
||||
case 'C':
|
||||
*type=air_panel->currentType();
|
||||
*panel=air_panel->currentNumber();
|
||||
*type=air_panel->soundPanelWidget()->currentType();
|
||||
*panel=air_panel->soundPanelWidget()->currentNumber();
|
||||
return true;
|
||||
break;
|
||||
|
||||
|
||||
@@ -420,71 +420,88 @@ MainWidget::MainWidget(RDConfig *config,QWidget *parent)
|
||||
rda->airplayConf()->panels(RDAirPlayConf::UserPanel)){
|
||||
int card=-1;
|
||||
air_panel=
|
||||
new RDSoundPanel(rda->airplayConf()->panels(RDAirPlayConf::StationPanel),
|
||||
new SoundPanel(rda->airplayConf()->panels(RDAirPlayConf::StationPanel),
|
||||
rda->airplayConf()->panels(RDAirPlayConf::UserPanel),
|
||||
rda->airplayConf()->flashPanel(),
|
||||
"RDAirPlay",
|
||||
rda->airplayConf()->buttonLabelTemplate(),false,
|
||||
air_event_player,air_cart_dialog,this);
|
||||
air_panel->setPauseEnabled(rda->airplayConf()->panelPauseEnabled());
|
||||
air_panel->setCard(0,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->
|
||||
setPauseEnabled(rda->airplayConf()->panelPauseEnabled());
|
||||
air_panel->soundPanelWidget()->setCard(0,rda->airplayConf()->
|
||||
card(RDAirPlayConf::SoundPanel1Channel));
|
||||
air_panel->setPort(0,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setPort(0,rda->airplayConf()->
|
||||
port(RDAirPlayConf::SoundPanel1Channel));
|
||||
air_panel->setFocusPolicy(Qt::NoFocus);
|
||||
air_panel->soundPanelWidget()->setFocusPolicy(Qt::NoFocus);
|
||||
if((card=rda->airplayConf()->card(RDAirPlayConf::SoundPanel2Channel))<0) {
|
||||
air_panel->setCard(1,air_panel->card(RDAirPlayConf::MainLog1Channel));
|
||||
air_panel->setPort(1,air_panel->port(RDAirPlayConf::MainLog1Channel));
|
||||
air_panel->soundPanelWidget()->
|
||||
setCard(1,air_panel->
|
||||
soundPanelWidget()->card(RDAirPlayConf::MainLog1Channel));
|
||||
air_panel->soundPanelWidget()->
|
||||
setPort(1,air_panel->
|
||||
soundPanelWidget()->port(RDAirPlayConf::MainLog1Channel));
|
||||
}
|
||||
else {
|
||||
air_panel->setCard(1,card);
|
||||
air_panel->setPort(1,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setCard(1,card);
|
||||
air_panel->soundPanelWidget()->setPort(1,rda->airplayConf()->
|
||||
port(RDAirPlayConf::SoundPanel2Channel));
|
||||
}
|
||||
if((card=rda->airplayConf()->card(RDAirPlayConf::SoundPanel3Channel))<0) {
|
||||
air_panel->setCard(2,air_panel->card(RDAirPlayConf::MainLog2Channel));
|
||||
air_panel->setPort(2,air_panel->port(RDAirPlayConf::MainLog2Channel));
|
||||
air_panel->soundPanelWidget()->
|
||||
setCard(2,air_panel->
|
||||
soundPanelWidget()->card(RDAirPlayConf::MainLog2Channel));
|
||||
air_panel->soundPanelWidget()->
|
||||
setPort(2,air_panel->
|
||||
soundPanelWidget()->port(RDAirPlayConf::MainLog2Channel));
|
||||
}
|
||||
else {
|
||||
air_panel->setCard(2,card);
|
||||
air_panel->setPort(2,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setCard(2,card);
|
||||
air_panel->soundPanelWidget()->setPort(2,rda->airplayConf()->
|
||||
port(RDAirPlayConf::SoundPanel3Channel));
|
||||
}
|
||||
if((card=rda->airplayConf()->card(RDAirPlayConf::SoundPanel4Channel))<0) {
|
||||
air_panel->setCard(3,air_panel->card(RDAirPlayConf::SoundPanel1Channel));
|
||||
air_panel->setPort(3,air_panel->port(RDAirPlayConf::SoundPanel1Channel));
|
||||
air_panel->soundPanelWidget()->
|
||||
setCard(3,air_panel->
|
||||
soundPanelWidget()->card(RDAirPlayConf::SoundPanel1Channel));
|
||||
air_panel->soundPanelWidget()->
|
||||
setPort(3,air_panel->
|
||||
soundPanelWidget()->port(RDAirPlayConf::SoundPanel1Channel));
|
||||
}
|
||||
else {
|
||||
air_panel->setCard(3,card);
|
||||
air_panel->setPort(3,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setCard(3,card);
|
||||
air_panel->soundPanelWidget()->setPort(3,rda->airplayConf()->
|
||||
port(RDAirPlayConf::SoundPanel4Channel));
|
||||
}
|
||||
if((card=rda->airplayConf()->card(RDAirPlayConf::SoundPanel5Channel))<0) {
|
||||
air_panel->setCard(4,air_panel->card(RDAirPlayConf::CueChannel));
|
||||
air_panel->setPort(4,air_panel->port(RDAirPlayConf::CueChannel));
|
||||
air_panel->soundPanelWidget()->
|
||||
setCard(4,air_panel->
|
||||
soundPanelWidget()->card(RDAirPlayConf::CueChannel));
|
||||
air_panel->soundPanelWidget()->
|
||||
setPort(4,air_panel->
|
||||
soundPanelWidget()->port(RDAirPlayConf::CueChannel));
|
||||
}
|
||||
else {
|
||||
air_panel->setCard(4,card);
|
||||
air_panel->setPort(4,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setCard(4,card);
|
||||
air_panel->soundPanelWidget()->setPort(4,rda->airplayConf()->
|
||||
port(RDAirPlayConf::SoundPanel5Channel));
|
||||
}
|
||||
air_panel->setRmls(0,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setRmls(0,rda->airplayConf()->
|
||||
startRml(RDAirPlayConf::SoundPanel1Channel),
|
||||
rda->airplayConf()->
|
||||
stopRml(RDAirPlayConf::SoundPanel1Channel));
|
||||
air_panel->setRmls(1,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setRmls(1,rda->airplayConf()->
|
||||
startRml(RDAirPlayConf::SoundPanel2Channel),
|
||||
rda->airplayConf()->
|
||||
stopRml(RDAirPlayConf::SoundPanel2Channel));
|
||||
air_panel->setRmls(2,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setRmls(2,rda->airplayConf()->
|
||||
startRml(RDAirPlayConf::SoundPanel3Channel),
|
||||
rda->airplayConf()->
|
||||
stopRml(RDAirPlayConf::SoundPanel3Channel));
|
||||
air_panel->setRmls(3,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setRmls(3,rda->airplayConf()->
|
||||
startRml(RDAirPlayConf::SoundPanel4Channel),
|
||||
rda->airplayConf()->
|
||||
stopRml(RDAirPlayConf::SoundPanel4Channel));
|
||||
air_panel->setRmls(4,rda->airplayConf()->
|
||||
air_panel->soundPanelWidget()->setRmls(4,rda->airplayConf()->
|
||||
startRml(RDAirPlayConf::SoundPanel5Channel),
|
||||
rda->airplayConf()->
|
||||
stopRml(RDAirPlayConf::SoundPanel5Channel));
|
||||
@@ -503,12 +520,15 @@ MainWidget::MainWidget(RDConfig *config,QWidget *parent)
|
||||
channum[1]=2;
|
||||
}
|
||||
for(int i=0;i<PANEL_MAX_OUTPUTS;i++) {
|
||||
air_panel->setOutputText(i,QString().sprintf("%d",next_output++));
|
||||
air_panel->soundPanelWidget()->setOutputText(i,QString().sprintf("%d",next_output++));
|
||||
assigned=false;
|
||||
for(int j=0;j<2;j++) {
|
||||
if((air_panel->card((RDAirPlayConf::Channel)i)==air_log[0]->card(j))&&
|
||||
(air_panel->port((RDAirPlayConf::Channel)i)==air_log[0]->port(j))) {
|
||||
air_panel->setOutputText(i,QString().sprintf("%d",channum[j]));
|
||||
if((air_panel->soundPanelWidget()->
|
||||
card((RDAirPlayConf::Channel)i)==air_log[0]->card(j))&&
|
||||
(air_panel->soundPanelWidget()->
|
||||
port((RDAirPlayConf::Channel)i)==air_log[0]->port(j))) {
|
||||
air_panel->soundPanelWidget()->
|
||||
setOutputText(i,QString().sprintf("%d",channum[j]));
|
||||
next_output--;
|
||||
assigned=true;
|
||||
j=2;
|
||||
@@ -516,10 +536,13 @@ MainWidget::MainWidget(RDConfig *config,QWidget *parent)
|
||||
}
|
||||
if(!assigned) {
|
||||
for(int j=0;j<i;j++) {
|
||||
if((i!=j)&&(air_panel->card((RDAirPlayConf::Channel)i)==
|
||||
air_panel->card(j))&&
|
||||
(air_panel->port((RDAirPlayConf::Channel)i)==air_panel->port(j))) {
|
||||
air_panel->setOutputText(i,air_panel->outputText(j));
|
||||
if((i!=j)&&(air_panel->soundPanelWidget()->
|
||||
card((RDAirPlayConf::Channel)i)==
|
||||
air_panel->soundPanelWidget()->card(j))&&
|
||||
(air_panel->soundPanelWidget()->
|
||||
port((RDAirPlayConf::Channel)i)==air_panel->soundPanelWidget()->port(j))) {
|
||||
air_panel->soundPanelWidget()->
|
||||
setOutputText(i,air_panel->soundPanelWidget()->outputText(j));
|
||||
next_output--;
|
||||
j=PANEL_MAX_OUTPUTS;
|
||||
}
|
||||
@@ -527,14 +550,17 @@ MainWidget::MainWidget(RDConfig *config,QWidget *parent)
|
||||
}
|
||||
}
|
||||
|
||||
air_panel->setSvcName(rda->airplayConf()->defaultSvc());
|
||||
connect(rda->ripc(),SIGNAL(userChanged()),air_panel,SLOT(changeUser()));
|
||||
connect(air_master_timer,SIGNAL(timeout()),air_panel,SLOT(tickClock()));
|
||||
connect(air_panel,SIGNAL(selectClicked(unsigned,int,int)),
|
||||
air_panel->soundPanelWidget()->setSvcName(rda->airplayConf()->defaultSvc());
|
||||
connect(rda->ripc(),SIGNAL(userChanged()),
|
||||
air_panel->soundPanelWidget(),SLOT(changeUser()));
|
||||
connect(air_master_timer,SIGNAL(timeout()),
|
||||
air_panel->soundPanelWidget(),SLOT(tickClock()));
|
||||
connect(air_panel->soundPanelWidget(),
|
||||
SIGNAL(selectClicked(unsigned,int,int)),
|
||||
this,SLOT(selectClickedData(unsigned,int,int)));
|
||||
connect(air_panel,SIGNAL(channelStarted(int,int,int)),
|
||||
connect(air_panel->soundPanelWidget(),SIGNAL(channelStarted(int,int,int)),
|
||||
this,SLOT(panelChannelStartedData(int,int,int)));
|
||||
connect(air_panel,SIGNAL(channelStopped(int,int,int)),
|
||||
connect(air_panel->soundPanelWidget(),SIGNAL(channelStopped(int,int,int)),
|
||||
this,SLOT(panelChannelStoppedData(int,int,int)));
|
||||
}
|
||||
|
||||
@@ -887,12 +913,12 @@ void MainWidget::gpiStateChangedData(int matrix,int line,bool state)
|
||||
if(!state) {
|
||||
if((air_stop_gpi_matrices[RDAirPlayConf::SoundPanel1Channel]==matrix)&&
|
||||
(air_stop_gpi_lines[RDAirPlayConf::SoundPanel1Channel]==line)) {
|
||||
air_panel->channelStop(0);
|
||||
air_panel->soundPanelWidget()->channelStop(0);
|
||||
}
|
||||
for(unsigned i=6;i<10;i++) {
|
||||
if((air_stop_gpi_matrices[i]==matrix)&&
|
||||
(air_stop_gpi_lines[i]==line)) {
|
||||
air_panel->channelStop(i-5);
|
||||
air_panel->soundPanelWidget()->channelStop(i-5);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1144,7 +1170,7 @@ void MainWidget::logRenamedData(int log)
|
||||
case 0:
|
||||
air_log_button[0]->setText(tr("Main Log")+"\n["+labelname+"]");
|
||||
SetCaption();
|
||||
if(air_panel) {
|
||||
if(air_panel->soundPanelWidget()) {
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -1175,12 +1201,13 @@ void MainWidget::logReloadedData(int log)
|
||||
(const char *)air_log[0]->logName().toUtf8());
|
||||
if(air_log[0]->logName().isEmpty()) {
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setSvcName(rda->airplayConf()->defaultSvc());
|
||||
air_panel->soundPanelWidget()->
|
||||
setSvcName(rda->airplayConf()->defaultSvc());
|
||||
}
|
||||
}
|
||||
else {
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setSvcName(air_log[0]->serviceName());
|
||||
air_panel->soundPanelWidget()->setSvcName(air_log[0]->serviceName());
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -1534,24 +1561,29 @@ void MainWidget::selectClickedData(unsigned cartnum,int row,int col)
|
||||
|
||||
case StartButton::CopyTo:
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setButton(air_panel->currentType(),
|
||||
air_panel->currentNumber(),row,col,air_add_cart);
|
||||
air_panel->soundPanelWidget()->
|
||||
setButton(air_panel->soundPanelWidget()->currentType(),
|
||||
air_panel->soundPanelWidget()->currentNumber(),
|
||||
row,col,air_add_cart);
|
||||
}
|
||||
SetActionMode(StartButton::Stop);
|
||||
break;
|
||||
|
||||
case StartButton::AddTo:
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setButton(air_panel->currentType(),
|
||||
air_panel->currentNumber(),row,col,air_add_cart);
|
||||
air_panel->soundPanelWidget()->
|
||||
setButton(air_panel->soundPanelWidget()->currentType(),
|
||||
air_panel->soundPanelWidget()->currentNumber(),
|
||||
row,col,air_add_cart);
|
||||
}
|
||||
SetActionMode(StartButton::Stop);
|
||||
break;
|
||||
|
||||
case StartButton::DeleteFrom:
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setButton(air_panel->currentType(),
|
||||
air_panel->currentNumber(),row,col,0);
|
||||
air_panel->soundPanelWidget()->
|
||||
setButton(air_panel->soundPanelWidget()->currentType(),
|
||||
air_panel->soundPanelWidget()->currentNumber(),row,col,0);
|
||||
}
|
||||
SetActionMode(StartButton::Stop);
|
||||
break;
|
||||
@@ -1977,19 +2009,19 @@ void MainWidget::resizeEvent(QResizeEvent *e)
|
||||
// Sound Panel
|
||||
//
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setGeometry(510,140,w-510,h-215);
|
||||
air_panel->setGeometry(510,140,w-520,h-215);
|
||||
}
|
||||
|
||||
//
|
||||
// Voice Tracker
|
||||
//
|
||||
air_tracker->setGeometry(510,140,w-510,h-215);
|
||||
air_tracker->setGeometry(510,140,w-515,h-215);
|
||||
|
||||
//
|
||||
// Full Log Widgets
|
||||
//
|
||||
for(int i=0;i<RDAIRPLAY_LOG_QUANTITY;i++) {
|
||||
air_log_list[i]->setGeometry(510,140,w-530,h-210);
|
||||
air_log_list[i]->setGeometry(510,140,w-520,h-215);
|
||||
}
|
||||
|
||||
|
||||
@@ -2025,10 +2057,10 @@ void MainWidget::wheelEvent(QWheelEvent *e)
|
||||
{
|
||||
if((air_panel!=NULL)&&(e->orientation()==Qt::Vertical)) {
|
||||
if(e->delta()>0) {
|
||||
air_panel->panelDown();
|
||||
air_panel->soundPanelWidget()->panelDown();
|
||||
}
|
||||
if(e->delta()<0) {
|
||||
air_panel->panelUp();
|
||||
air_panel->soundPanelWidget()->panelUp();
|
||||
}
|
||||
}
|
||||
e->accept();
|
||||
@@ -2190,7 +2222,7 @@ void MainWidget::SetActionMode(StartButton::Mode mode)
|
||||
}
|
||||
air_button_list->setActionMode(RDAirPlayConf::Normal);
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setActionMode(RDAirPlayConf::Normal);
|
||||
air_panel->soundPanelWidget()->setActionMode(RDAirPlayConf::Normal);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -2229,7 +2261,7 @@ void MainWidget::SetActionMode(StartButton::Mode mode)
|
||||
}
|
||||
air_button_list->setActionMode(RDAirPlayConf::Normal);
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setActionMode(RDAirPlayConf::Normal);
|
||||
air_panel->soundPanelWidget()->setActionMode(RDAirPlayConf::Normal);
|
||||
}
|
||||
if(air_cart_dialog->
|
||||
exec(&air_add_cart,RDCart::All,air_log[0]->serviceName(),NULL)) {
|
||||
@@ -2251,7 +2283,7 @@ void MainWidget::SetActionMode(StartButton::Mode mode)
|
||||
}
|
||||
air_button_list->setActionMode(RDAirPlayConf::AddTo);
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setActionMode(RDAirPlayConf::AddTo);
|
||||
air_panel->soundPanelWidget()->setActionMode(RDAirPlayConf::AddTo);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -2266,7 +2298,7 @@ void MainWidget::SetActionMode(StartButton::Mode mode)
|
||||
}
|
||||
air_button_list->setActionMode(RDAirPlayConf::DeleteFrom);
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setActionMode(RDAirPlayConf::DeleteFrom);
|
||||
air_panel->soundPanelWidget()->setActionMode(RDAirPlayConf::DeleteFrom);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -2281,7 +2313,7 @@ void MainWidget::SetActionMode(StartButton::Mode mode)
|
||||
}
|
||||
air_button_list->setActionMode(RDAirPlayConf::MoveFrom);
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setActionMode(RDAirPlayConf::MoveFrom);
|
||||
air_panel->soundPanelWidget()->setActionMode(RDAirPlayConf::MoveFrom);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -2296,7 +2328,7 @@ void MainWidget::SetActionMode(StartButton::Mode mode)
|
||||
}
|
||||
air_button_list->setActionMode(RDAirPlayConf::MoveTo);
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setActionMode(RDAirPlayConf::MoveTo);
|
||||
air_panel->soundPanelWidget()->setActionMode(RDAirPlayConf::MoveTo);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -2311,7 +2343,7 @@ void MainWidget::SetActionMode(StartButton::Mode mode)
|
||||
}
|
||||
air_button_list->setActionMode(RDAirPlayConf::CopyFrom);
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setActionMode(RDAirPlayConf::CopyFrom);
|
||||
air_panel->soundPanelWidget()->setActionMode(RDAirPlayConf::CopyFrom);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -2326,7 +2358,7 @@ void MainWidget::SetActionMode(StartButton::Mode mode)
|
||||
}
|
||||
air_button_list->setActionMode(RDAirPlayConf::CopyTo);
|
||||
if(air_panel!=NULL) {
|
||||
air_panel->setActionMode(RDAirPlayConf::CopyTo);
|
||||
air_panel->soundPanelWidget()->setActionMode(RDAirPlayConf::CopyTo);
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
@@ -27,10 +27,10 @@
|
||||
#include <rdinstancelock.h>
|
||||
#include <rdmainwindow.h>
|
||||
#include <rdmeterstrip.h>
|
||||
#include <rdsound_panel.h>
|
||||
|
||||
#include "button_log.h"
|
||||
#include "colors.h"
|
||||
#include "soundpanel.h"
|
||||
#include "topstrip.h"
|
||||
#include "voicetracker.h"
|
||||
|
||||
@@ -111,7 +111,7 @@ class MainWidget : public RDMainWindow
|
||||
void ShowTracker(bool state);
|
||||
RDAirPlayConf::Channel PanelChannel(int mport) const;
|
||||
RDLogPlay *air_log[RDAIRPLAY_LOG_QUANTITY];
|
||||
RDSoundPanel *air_panel;
|
||||
SoundPanel *air_panel;
|
||||
VoiceTracker *air_tracker;
|
||||
QPushButton *air_tracker_button;
|
||||
RDMeterStrip *air_meter_strip;
|
||||
|
||||
@@ -32,6 +32,7 @@ x11 {
|
||||
SOURCES += pie_counter.cpp
|
||||
SOURCES += post_counter.cpp
|
||||
SOURCES += rdairplay.cpp
|
||||
SOURCES += soundpanel.cpp
|
||||
SOURCES += start_button.cpp
|
||||
SOURCES += stop_counter.cpp
|
||||
SOURCES += wall_clock.cpp
|
||||
@@ -50,6 +51,7 @@ x11 {
|
||||
HEADERS += pie_counter.h
|
||||
HEADERS += post_counter.h
|
||||
HEADERS += rdairplay.h
|
||||
HEADERS += soundpanel.h
|
||||
HEADERS += start_button.h
|
||||
HEADERS += stop_counter.h
|
||||
HEADERS += wall_clock.h
|
||||
|
||||
61
rdairplay/soundpanel.cpp
Normal file
61
rdairplay/soundpanel.cpp
Normal file
@@ -0,0 +1,61 @@
|
||||
// soundpanel.cpp
|
||||
//
|
||||
// RDSoundPanel panel for RDAirPlay
|
||||
//
|
||||
// (C) Copyright 2021 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
|
||||
// published by the Free Software Foundation.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public
|
||||
// License along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
//
|
||||
|
||||
#include <QPainter>
|
||||
|
||||
#include "colors.h"
|
||||
#include "soundpanel.h"
|
||||
|
||||
SoundPanel::SoundPanel(int station_panels,int user_panels,bool flash,
|
||||
const QString &caption,const QString &label_template,
|
||||
bool extended,RDEventPlayer *player,
|
||||
RDCartDialog *cart_dialog,QWidget *parent)
|
||||
: RDWidget(parent)
|
||||
{
|
||||
d_panel=new RDSoundPanel(station_panels,user_panels,flash,caption,
|
||||
label_template,extended,player,cart_dialog,this);
|
||||
}
|
||||
|
||||
|
||||
SoundPanel::~SoundPanel()
|
||||
{
|
||||
delete d_panel;
|
||||
}
|
||||
|
||||
|
||||
RDSoundPanel *SoundPanel::soundPanelWidget() const
|
||||
{
|
||||
return d_panel;
|
||||
}
|
||||
|
||||
|
||||
void SoundPanel::resizeEvent(QResizeEvent *e)
|
||||
{
|
||||
d_panel->setGeometry(5,5,size().width()-10,size().height()-10);
|
||||
}
|
||||
|
||||
|
||||
void SoundPanel::paintEvent(QPaintEvent *e)
|
||||
{
|
||||
QPainter *p=new QPainter(this);
|
||||
p->fillRect(0,0,size().width(),size().height(),
|
||||
QColor(AIR_WIDGET_BACKGROUND_COLOR));
|
||||
delete p;
|
||||
}
|
||||
46
rdairplay/soundpanel.h
Normal file
46
rdairplay/soundpanel.h
Normal file
@@ -0,0 +1,46 @@
|
||||
// soundpanel.h
|
||||
//
|
||||
// RDSoundPanel panel for RDAirPlay
|
||||
//
|
||||
// (C) Copyright 2021 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
|
||||
// published by the Free Software Foundation.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU General Public
|
||||
// License along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
//
|
||||
|
||||
#ifndef SOUNDPANEL_H
|
||||
#define SOUNDPANEL_H
|
||||
|
||||
#include <rdsound_panel.h>
|
||||
#include <rdwidget.h>
|
||||
|
||||
class SoundPanel : public RDWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
SoundPanel(int station_panels,int user_panels,bool flash,
|
||||
const QString &caption,const QString &label_template,
|
||||
bool extended,RDEventPlayer *player,RDCartDialog *cart_dialog,
|
||||
QWidget *parent=0);
|
||||
~SoundPanel();
|
||||
RDSoundPanel *soundPanelWidget() const;
|
||||
|
||||
protected:
|
||||
void resizeEvent(QResizeEvent *e);
|
||||
void paintEvent(QPaintEvent *e);
|
||||
|
||||
private:
|
||||
RDSoundPanel *d_panel;
|
||||
};
|
||||
|
||||
#endif // SOUNDPANEL_H
|
||||
@@ -20,6 +20,7 @@
|
||||
|
||||
#include <rdlist_logs.h>
|
||||
|
||||
#include "colors.h"
|
||||
#include "voicetracker.h"
|
||||
|
||||
VoiceTracker::VoiceTracker(QWidget *parent)
|
||||
@@ -35,7 +36,8 @@ VoiceTracker::VoiceTracker(QWidget *parent)
|
||||
|
||||
QSize VoiceTracker::sizeHint() const
|
||||
{
|
||||
return d_tracker_widget->sizeHint();
|
||||
return QSize(10+d_tracker_widget->sizeHint().width(),
|
||||
10+d_tracker_widget->sizeHint().height());
|
||||
}
|
||||
|
||||
|
||||
@@ -67,6 +69,14 @@ void VoiceTracker::unloadData()
|
||||
|
||||
void VoiceTracker::resizeEvent(QResizeEvent *e)
|
||||
{
|
||||
d_tracker_widget->setGeometry(0,0,size().width(),size().height());
|
||||
d_load_button->setGeometry(size().width()-90,size().height()-50,80,50);
|
||||
d_tracker_widget->setGeometry(5,5,size().width()-10,size().height()-10);
|
||||
d_load_button->setGeometry(size().width()-95,size().height()-55,80,50);
|
||||
}
|
||||
|
||||
|
||||
void VoiceTracker::paintEvent(QPaintEvent *e)
|
||||
{
|
||||
QPainter *p=new QPainter(this);
|
||||
p->fillRect(0,0,size().width(),size().height(),
|
||||
QColor(AIR_WIDGET_BACKGROUND_COLOR));
|
||||
}
|
||||
|
||||
@@ -40,6 +40,7 @@ class VoiceTracker : public RDWidget
|
||||
|
||||
protected:
|
||||
void resizeEvent(QResizeEvent *e);
|
||||
void paintEvent(QPaintEvent *e);
|
||||
|
||||
private:
|
||||
RDTrackerWidget *d_tracker_widget;
|
||||
|
||||
Reference in New Issue
Block a user