-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Move WOverview::drawNextPixmapPart() into new class WOverviewLMH (Low Mid High), also add new HSV waveform overview and interface, to select woverview type #17
Changes from 9 commits
70425b2
c44dd80
d482e9c
1f3d43b
6825d0a
95602c3
2018475
701b1f5
c19f67f
7dc7818
6caf25d
1e9694c
82b453e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,7 +41,8 @@ | |
#include "widget/wnumber.h" | ||
#include "widget/wnumberpos.h" | ||
#include "widget/wnumberrate.h" | ||
#include "widget/woverview.h" | ||
#include "widget/woverviewlmh.h" | ||
#include "widget/woverviewhsv.h" | ||
#include "widget/wspinny.h" | ||
#include "widget/wwaveformviewer.h" | ||
#include "waveform/waveformwidgetfactory.h" | ||
|
@@ -595,7 +596,13 @@ QWidget* LegacySkinParser::parseOverview(QDomElement node) { | |
if (pPlayer == NULL) | ||
return NULL; | ||
|
||
WOverview* overviewWidget = new WOverview(pSafeChannelStr, m_pConfig, m_pParent); | ||
WOverview* overviewWidget = NULL; | ||
|
||
// HSV or LMH waveform overview type | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. // HSV = "1" or "Filtered" = "0" (LMH) waveform overview type |
||
if( m_pConfig->getValueString(ConfigKey("[Waveform]","WaveformOverviewType"), "0").toInt() == 0 ) | ||
overviewWidget = new WOverviewLMH(pSafeChannelStr, m_pConfig, m_pParent); | ||
else | ||
overviewWidget = new WOverviewHSV(pSafeChannelStr, m_pConfig, m_pParent); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please brake the line at a reasonable point near column 80. Btw: I love braces in this case There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Like this: if( m_pConfig->getValueString(ConfigKey("[Waveform]","WaveformOverviewType"),
"0").toInt() == 0 ) {
overviewWidget = new WOverviewLMH(pSafeChannelStr, m_pConfig, m_pParent);
}
else
overviewWidget = new WOverviewHSV(pSafeChannelStr, m_pConfig, m_pParent); ? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. More like this: if (m_pConfig->getValueString(ConfigKey("[Waveform]", "WaveformOverviewType"),
"0").toInt() == 0) {
overviewWidget = new WOverviewLMH(pSafeChannelStr, m_pConfig, m_pParent);
} else {
overviewWidget = new WOverviewHSV(pSafeChannelStr, m_pConfig, m_pParent);
} There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. second line should be: if (m_pConfig->getValueString(ConfigKey("[Waveform]","WaveformOverviewType"),
"0").toInt() == 0) { or if (m_pConfig->getValueString(ConfigKey("[Waveform]","WaveformOverviewType"),
"0").toInt() == 0) { ? I mean ident |
||
|
||
connect(overviewWidget, SIGNAL(trackDropped(QString, QString)), | ||
m_pPlayerManager, SLOT(slotLoadToPlayer(QString, QString))); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add commends to clarify what "0" is and to clarify the relation between config options and ComboBox items/index.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wrote "By default we set filtered woverview", I must write something more?
Hmm... I don't understand, can you give an example?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// Waveform overview init
waveformOverviewComboBox->addItem( tr("Filtered") ); // "0"
waveformOverviewComboBox->addItem( tr("HSV") ); // "1"
// By default we set "Filtered" woverview = "0"
waveformOverviewComboBox->setCurrentIndex(
m_pConfig->getValueString(ConfigKey("[Waveform]","WaveformOverviewType"), "0").toInt());