diff options
author | Chris Xiong <chirs241097@gmail.com> | 2015-12-29 23:54:24 +0800 |
---|---|---|
committer | Chris Xiong <chirs241097@gmail.com> | 2015-12-29 23:54:24 +0800 |
commit | 8dc90ae27c24aec1851215f2cc28ee24eff01ea5 (patch) | |
tree | 13a604bf55804960ced6ec7559f626962a1265bd /qmpchannelswindow.cpp | |
parent | 40ea6580aaf3d19aa77f43551185a55013d216d9 (diff) | |
download | QMidiPlayer-8dc90ae27c24aec1851215f2cc28ee24eff01ea5.tar.xz |
Master Spark. (WTF)
Diffstat (limited to 'qmpchannelswindow.cpp')
-rw-r--r-- | qmpchannelswindow.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/qmpchannelswindow.cpp b/qmpchannelswindow.cpp index 6aca878..635918e 100644 --- a/qmpchannelswindow.cpp +++ b/qmpchannelswindow.cpp @@ -1,7 +1,6 @@ #include <QCheckBox> #include <QPushButton> #include <QComboBox> -#include <QLabel> #include "qmpchannelswindow.hpp" #include "ui_qmpchannelswindow.h" #include "qmpmainwindow.hpp" @@ -11,6 +10,7 @@ qmpchannelswindow::qmpchannelswindow(QWidget *parent) : ui(new Ui::qmpchannelswindow) { ui->setupUi(this); + pselectw=new qmppresetselect(this); connect(this,SIGNAL(dialogClosing()),parent,SLOT(dialogClosed())); for(int i=0;i<16;++i) { @@ -22,7 +22,9 @@ qmpchannelswindow::qmpchannelswindow(QWidget *parent) : QComboBox *cb=(QComboBox*)ui->twChannels->cellWidget(i,2); //stub cb->addItem("Internal fluidsynth"); - ui->twChannels->setCellWidget(i,3,new QLabel("")); + ui->twChannels->setCellWidget(i,3,new QDCLabel("")); + ((QDCLabel*)ui->twChannels->cellWidget(i,3))->setID(i); + connect(ui->twChannels->cellWidget(i,3),SIGNAL(onDoubleClick(int)),this,SLOT(showPresetWindow(int))); ui->twChannels->setCellWidget(i,4,new QPushButton("...")); } ui->twChannels->setColumnWidth(0,32); @@ -86,3 +88,9 @@ void qmpchannelswindow::on_pbUnsolo_clicked() ((qmpMainWindow*)this->parent())->getPlayer()->setSolo(i,false); } } + +void qmpchannelswindow::showPresetWindow(int chid) +{ + pselectw->show(); + pselectw->setupWindow(chid); +} |