removed debugging in projectM-qt

git-svn-id: https://projectm.svn.sourceforge.net/svnroot/projectm/trunk@939 6778bc44-b910-0410-a7a0-be141de4315d
This commit is contained in:
w1z7ard
2008-04-05 14:56:17 +00:00
parent 868ee908bd
commit fdcf3b9827
2 changed files with 3 additions and 25 deletions

View File

@ -995,30 +995,16 @@ void QProjectM_MainWindow::updateFilteredPlaylist ( const QString & text )
Nullable<unsigned int> activePresetId;
if (!presetSelected && activePresetIndex->hasValue()) {
qDebug() << "active preset index has value: " << activePresetIndex->value();
activePresetId = activePresetIndex->value();
} else if (presetSelected) {
qDebug() << "preset still selected (current = " << presetIndexBackup << ")";
const PlaylistItemVector & oldPlaylistItems = *historyHash.value(previousFilter);
if ((presetIndexBackup >=0) && (presetIndexBackup < oldPlaylistItems.size())) {
activePresetId = oldPlaylistItems[presetIndexBackup];
}
/*
int i = 0;
for ( PlaylistItemVector::const_iterator pos = oldPlaylistItems.begin(); pos != oldPlaylistItems.end();++pos )
{
if (presetIndexBackup == i) {
activePresetId = pos->id;
qDebug() << "preset still selected true id:" << activePresetId.value();
break;
}
i++;
}
*/
} else {
qDebug() << "active preset index does NOT have value.";
}
/// NEED A MUTEX TO STOP PROJECTM FROM SWITCHING PRESETS
@ -1027,7 +1013,6 @@ void QProjectM_MainWindow::updateFilteredPlaylist ( const QString & text )
Q_ASSERT(!qprojectM()->presetPositionValid());
bool presetExistsWithinFilter = false;
qDebug() << "preset position valid (preloop):" << qprojectM()->presetPositionValid();
if ( historyHash.contains ( filter ) )
{
const PlaylistItemVector & playlistItems = *historyHash.value ( filter );
@ -1038,7 +1023,6 @@ void QProjectM_MainWindow::updateFilteredPlaylist ( const QString & text )
playlistModel->appendRow ( data.url, data.name, data.rating);
if (activePresetId.hasValue() && data.id == activePresetId.value()) {
qDebug() << "new position is " << (playlistModel->rowCount()-1);
qprojectM()->selectPresetPosition(playlistModel->rowCount()-1);
presetExistsWithinFilter = true;
}
@ -1057,9 +1041,7 @@ void QProjectM_MainWindow::updateFilteredPlaylist ( const QString & text )
if ( ( data.name ).contains ( filter, Qt::CaseInsensitive ) )
{
playlistModel->appendRow ( data.url, data.name, data.rating);
qDebug() << "preset position valid (inner loop):" << qprojectM()->presetPositionValid();
if (activePresetId.hasValue() && data.id == activePresetId.value()) {
qDebug() << "new position is " << (playlistModel->rowCount()-1);
qprojectM()->selectPresetPosition(playlistModel->rowCount()-1);
presetExistsWithinFilter = true;
}
@ -1069,8 +1051,6 @@ void QProjectM_MainWindow::updateFilteredPlaylist ( const QString & text )
}
historyHash.insert ( filter, playlistItems2 );
}
qDebug() << "preset exists within filter: " << presetExistsWithinFilter;
qDebug() << "preset position valid:" << qprojectM()->presetPositionValid();
Q_ASSERT(presetExistsWithinFilter == qprojectM()->presetPositionValid());
previousFilter = filter;

View File

@ -109,14 +109,13 @@ void QProjectMConfigDialog::openTitleFontFileDialog() {
}
void QProjectMConfigDialog::saveConfig() {
qDebug() << "SAVE config";
projectM::Settings settings = _qprojectMWidget->qprojectM()->settings();
settings.meshX = _ui.meshSizeWidthSpinBox->value();
settings.meshY = _ui.meshSizeHeightSpinBox->value();
settings.windowHeight = _ui.windowHeightSpinBox->value();
settings.windowWidth = _ui.windowWidthSpinBox->value();
settings.windowWidth = _ui.windowWidthSpinBox->value();
settings.titleFontURL = _ui.titleFontPathLineEdit->text().toStdString();
settings.menuFontURL = _ui.menuFontPathLineEdit->text().toStdString();
settings.presetURL = _ui.startupPlaylistDirectoryLineEdit->text().toStdString();
@ -136,7 +135,7 @@ void QProjectMConfigDialog::saveConfig() {
qSettings.setValue("MenuOnStartup", _ui.menuOnStartupCheckBox->checkState() == Qt::Checked);
qSettings.setValue("PlaylistFile", _ui.startupPlaylistFileLineEdit->text());
qDebug() << "save end";
}
@ -151,7 +150,6 @@ void QProjectMConfigDialog::populateTextureSizeComboBox() {
void QProjectMConfigDialog::loadConfig() {
qDebug() << "load config BEGIN";
const projectM::Settings & settings = (* _qprojectMWidget->qprojectM()).settings();
_ui.meshSizeWidthSpinBox->setValue(settings.meshX);