Removed debug messages.
This commit is contained in:
@@ -42,12 +42,6 @@ void BCDelightPMWidget::loadWidgetsFromResources()
|
|||||||
// Iteriert zum nächsten Eintrag und gibt den kompletten virtuellen Pfad zurück
|
// Iteriert zum nächsten Eintrag und gibt den kompletten virtuellen Pfad zurück
|
||||||
// z.B. ":/icons/ball_red.png"
|
// z.B. ":/icons/ball_red.png"
|
||||||
QString fullPath = it.next();
|
QString fullPath = it.next();
|
||||||
|
|
||||||
// Optional: Nur den Dateinamen holen (z.B. "ball_red.png")
|
|
||||||
// QString fileName = it.fileName();
|
|
||||||
|
|
||||||
qDebug() << "Gefundenes Icon:" << fullPath;
|
|
||||||
|
|
||||||
// Eine Zufallsfarbe für den Button-Hintergrund generieren
|
// Eine Zufallsfarbe für den Button-Hintergrund generieren
|
||||||
QStringList colors = {"#ff5555", "#50fa7b", "#8be9fd", "#ffb86c"};
|
QStringList colors = {"#ff5555", "#50fa7b", "#8be9fd", "#ffb86c"};
|
||||||
QString randomColor = colors.at(QRandomGenerator::global()->bounded(colors.size()));
|
QString randomColor = colors.at(QRandomGenerator::global()->bounded(colors.size()));
|
||||||
@@ -56,7 +50,6 @@ void BCDelightPMWidget::loadWidgetsFromResources()
|
|||||||
createFlyingWidget(fullPath, randomColor);
|
createFlyingWidget(fullPath, randomColor);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void BCDelightPMWidget::createFlyingWidget(const QString& iconPath, const QString &color)
|
void BCDelightPMWidget::createFlyingWidget(const QString& iconPath, const QString &color)
|
||||||
|
|||||||
@@ -62,7 +62,6 @@ BCDriverStateWidget::BCDriverStateWidget(QWidget* parent)
|
|||||||
// 'customMessage' ist optional. Wenn leer, wird ein Standardtext genommen.
|
// 'customMessage' ist optional. Wenn leer, wird ein Standardtext genommen.
|
||||||
void BCDriverStateWidget::onDriverStateChanged(BCDriver::DriverState state, const QString& customMessage)
|
void BCDriverStateWidget::onDriverStateChanged(BCDriver::DriverState state, const QString& customMessage)
|
||||||
{
|
{
|
||||||
qDebug() << " --- HELPER: " << state << " : " << customMessage;
|
|
||||||
Q_UNUSED(customMessage)
|
Q_UNUSED(customMessage)
|
||||||
_state = state;
|
_state = state;
|
||||||
updateStyle();
|
updateStyle();
|
||||||
|
|||||||
@@ -151,8 +151,6 @@ BCDriver::DriverStateResult BCDriverTinyCan::loadDriver()
|
|||||||
return _driverState;
|
return _driverState;
|
||||||
};
|
};
|
||||||
|
|
||||||
qDebug() << " --- DRIVER: " << cMHS_DRIVERNAME;
|
|
||||||
|
|
||||||
// #1. erstmal komplett zurücksetzen
|
// #1. erstmal komplett zurücksetzen
|
||||||
resetDriver();
|
resetDriver();
|
||||||
// #2. Treiber laden, initialisieren und
|
// #2. Treiber laden, initialisieren und
|
||||||
|
|||||||
@@ -262,7 +262,6 @@ void BCMainWindow::onShowMessage( const QString& message, int timeOut )
|
|||||||
|
|
||||||
void BCMainWindow::onStartAnimation()
|
void BCMainWindow::onStartAnimation()
|
||||||
{
|
{
|
||||||
qDebug() << " FEIN!";
|
|
||||||
_delightWidget->onStartChaos();
|
_delightWidget->onStartChaos();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -58,8 +58,6 @@ QWidget* BCValueDelegate::createEditor(QWidget *parent, const QStyleOptionViewIt
|
|||||||
{
|
{
|
||||||
const BCValue& bcValue = *(_valueList[ index.row()].get());
|
const BCValue& bcValue = *(_valueList[ index.row()].get());
|
||||||
|
|
||||||
qDebug() << " --- Create EDITOR: " << index.row() << " parent: " << parent->objectName();
|
|
||||||
|
|
||||||
Q_UNUSED(option)
|
Q_UNUSED(option)
|
||||||
Q_UNUSED(index)
|
Q_UNUSED(index)
|
||||||
|
|
||||||
@@ -68,7 +66,6 @@ QWidget* BCValueDelegate::createEditor(QWidget *parent, const QStyleOptionViewIt
|
|||||||
// Signal für sofortige Updates
|
// Signal für sofortige Updates
|
||||||
connect(valueEditor, &BCValueEditor::valueChanged, this, [this, valueEditor](int newValue)
|
connect(valueEditor, &BCValueEditor::valueChanged, this, [this, valueEditor](int newValue)
|
||||||
{
|
{
|
||||||
qDebug() << "---val changed: " << newValue;
|
|
||||||
// Commit data sofort bei Änderung
|
// Commit data sofort bei Änderung
|
||||||
emit const_cast<BCValueDelegate*>(this)->commitData(valueEditor);
|
emit const_cast<BCValueDelegate*>(this)->commitData(valueEditor);
|
||||||
});
|
});
|
||||||
@@ -87,14 +84,12 @@ void BCValueDelegate::setEditorData(QWidget *editor, const QModelIndex& index) c
|
|||||||
|
|
||||||
void BCValueDelegate::setModelData(QWidget *editor, QAbstractItemModel *model, const QModelIndex& index) const
|
void BCValueDelegate::setModelData(QWidget *editor, QAbstractItemModel *model, const QModelIndex& index) const
|
||||||
{
|
{
|
||||||
qDebug() << " hier 2!";
|
|
||||||
if( index.column() == 1)
|
if( index.column() == 1)
|
||||||
{
|
{
|
||||||
// Daten vom Editor zurück ins Model speichern (Beim Schließen)
|
// Daten vom Editor zurück ins Model speichern (Beim Schließen)
|
||||||
BCValueEditor* slider = qobject_cast<BCValueEditor*>(editor);
|
BCValueEditor* slider = qobject_cast<BCValueEditor*>(editor);
|
||||||
if (slider)
|
if (slider)
|
||||||
{
|
{
|
||||||
qDebug() << " --- ok";
|
|
||||||
int value = slider->getValue();
|
int value = slider->getValue();
|
||||||
model->setData(index, value, Qt::EditRole);
|
model->setData(index, value, Qt::EditRole);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -185,16 +185,12 @@ bool BCValueModel::setData(const QModelIndex& index, const QVariant& variant, in
|
|||||||
{
|
{
|
||||||
BCValuePtr value = _valueList[index.row()];
|
BCValuePtr value = _valueList[index.row()];
|
||||||
|
|
||||||
qDebug() << "--- YES! " << variant.toInt();
|
|
||||||
|
|
||||||
// Wir erwarten hier nur den Value-Teil (vom Slider/Editor)
|
// Wir erwarten hier nur den Value-Teil (vom Slider/Editor)
|
||||||
// Checken ob Int oder Double
|
// Checken ob Int oder Double
|
||||||
if (variant.canConvert<int>())
|
if (variant.canConvert<int>())
|
||||||
{
|
{
|
||||||
qDebug() << "--- new VALUE: " << variant.toInt();
|
|
||||||
if( variant.toInt() == 42)
|
if( variant.toInt() == 42)
|
||||||
{
|
{
|
||||||
qDebug() << "--- YES! " << variant.toInt();
|
|
||||||
//emit makeSimonHappy();
|
//emit makeSimonHappy();
|
||||||
}
|
}
|
||||||
// QUARK!
|
// QUARK!
|
||||||
|
|||||||
Reference in New Issue
Block a user