Skip to content

Commit

Permalink
Some spaces identation changed to tabs
Browse files Browse the repository at this point in the history
  • Loading branch information
Fanda Vacek committed Jan 20, 2024
1 parent 3057ad0 commit be45d72
Show file tree
Hide file tree
Showing 7 changed files with 42 additions and 42 deletions.
14 changes: 7 additions & 7 deletions libqf/libqfqmlwidgets/src/reports/processor/style/brush.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@ QBrush Brush::brush()
{
qfLogFuncFrame() << this << "is dirty:" << isDirty();
if(isDirty()) {
setDirty(false);
{
setDirty(false);
{
QVariant v = basedOn();
qfDebug() << "\t based on:" << v.toString();
if(v.isValid()) {
QObject *o = styleobjectFromVariant(v);
QObject *o = styleobjectFromVariant(v);
Brush *based_on = qobject_cast<Brush*>(o);
qfDebug() << "\t\t based on object:" << based_on;
if(based_on) {
m_brush = based_on->brush();
}
if(based_on) {
m_brush = based_on->brush();
}
}
}
{
Expand All @@ -54,5 +54,5 @@ QBrush Brush::brush()
m_brush.setStyle(Qt::SolidPattern);
}
}
return m_brush;
return m_brush;
}
18 changes: 9 additions & 9 deletions libqf/libqfqmlwidgets/src/reports/processor/style/sheet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,21 +43,21 @@ void Sheet::createStyleCache_helper(QObject *parent)

QObject *Sheet::styleObjectForName(StyleObject::StyleGroup style_object_group, const QString &name, bool should_exist)
{
ObjectMap om = m_definedStyles.value(style_object_group);
QObject *ret = om.value(name);
if(ret == nullptr && should_exist)
qfError() << "Cannot find style object for style group:" << style_object_group << "name:" + name;
return ret;
ObjectMap om = m_definedStyles.value(style_object_group);
QObject *ret = om.value(name);
if(ret == nullptr && should_exist)
qfError() << "Cannot find style object for style group:" << style_object_group << "name:" + name;
return ret;
}

void Sheet::setStyleObjectForName(StyleObject::StyleGroup style_object_group, const QString &name, QObject *o)
{
//qfInfo() << Q_FUNC_INFO << name << style_object_group << o;
ObjectMap &om = m_definedStyles[style_object_group];
if(o)
om[name] = o;
ObjectMap &om = m_definedStyles[style_object_group];
if(o)
om[name] = o;
else
om.remove(name);
om.remove(name);
}

QQmlListProperty<Color> Sheet::colors()
Expand Down
28 changes: 14 additions & 14 deletions libqf/libqfqmlwidgets/src/reports/processor/style/styleobject.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,23 +72,23 @@ Sheet *StyleObject::rootStyleSheet()

QObject *StyleObject::styleobjectFromVariant(const QVariant &v, StyleGroup style_group, bool should_exist)
{
QObject *ret = nullptr;
if(v.isValid()) {
ret = v.value<QObject*>();
if(!ret) {
QObject *ret = nullptr;
if(v.isValid()) {
ret = v.value<QObject*>();
if(!ret) {
#if QT_VERSION_MAJOR >= 6
if(v.typeId() == QMetaType::QString) {
if(v.typeId() == QMetaType::QString) {
#else
if(v.type() == QVariant::String) {
if(v.type() == QVariant::String) {
#endif
StyleGroup sg = style_group;
if(sg == SGOwn)
sg = m_styleGroup;
ret = rootStyleSheet()->styleObjectForName(sg, v.toString(), should_exist);
}
}
}
return ret;
StyleGroup sg = style_group;
if(sg == SGOwn)
sg = m_styleGroup;
ret = rootStyleSheet()->styleObjectForName(sg, v.toString(), should_exist);
}
}
}
return ret;
}
/*
QString StyleObject::nextSequentialName()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,17 +115,17 @@ int CardReaderPlugin::findRunId(int si_id, int si_finish_time, QString *err_msg)
bool is_relays = getPlugin<EventPlugin>()->eventConfig()->isRelays();
if(is_relays) {
q.exec("SELECT id, leg, startTimeMs, finishTimeMs FROM runs WHERE siId=" QF_IARG(si_id)
" AND isRunning"
" ORDER BY leg DESC"
, qf::core::Exception::Throw);
" AND isRunning"
" ORDER BY leg DESC"
, qf::core::Exception::Throw);
}
else {
int stage_no = currentStageId();
q.exec("SELECT id, startTimeMs, finishTimeMs FROM runs WHERE stageId=" QF_IARG(stage_no)
" AND siId=" QF_IARG(si_id)
" AND isRunning"
//" ORDER BY finishTimeMs"
, qf::core::Exception::Throw);
" AND siId=" QF_IARG(si_id)
" AND isRunning"
//" ORDER BY finishTimeMs"
, qf::core::Exception::Throw);

}
while(q.next()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ void QrOPunch::init()
}
if (ss.isWriteLogFile()) {
m_logFileFs.close();
m_logFileFs.open(ss.logFileName().toLocal8Bit(), std::ios_base::app);
if (!m_logFileFs) {
m_logFileFs.open(ss.logFileName().toLocal8Bit(), std::ios_base::app);
if (!m_logFileFs) {
qfError() << "Failed to open file for logging: " << ss.logFileName();
} else {
qfInfo() << "Opened file for logging: " << ss.logFileName();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ void QrOPunchWidget::onBtChooseLogFileClicked()
if (svc) {
QrOPunchSettings ss = svc->settings();
QString file = QFileDialog::getSaveFileName(this, tr("Choose file to log requests"), ss.logFileName(),
{}, nullptr, QFileDialog::DontConfirmOverwrite);
{}, nullptr, QFileDialog::DontConfirmOverwrite);
if (!file.isEmpty())
ui->edLogFile->setText(file);
}
Expand Down
4 changes: 2 additions & 2 deletions quickevent/app/quickevent/plugins/Core/src/coreplugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ void CorePlugin::onInstalled()
{
auto *page = new ReportsSettingsPage();
settingsDialog()->addPage(page);
setReportsDir(page->reportsDirectory());
qfInfo() << "Reports dir set to:" << reportsDir();
setReportsDir(page->reportsDirectoryFromSettings());
qfInfo() << "Reports dir set to:" << effectiveReportsDir();
}

auto *a_file = fwk->menuBar()->actionForPath("file", true);
Expand Down

0 comments on commit be45d72

Please sign in to comment.