Skip to content

Commit

Permalink
Merge pull request #5286 from nextcloud/bugfix/bad-qproperties
Browse files Browse the repository at this point in the history
Fix warnings on QPROPERTY-s
  • Loading branch information
claucambra authored Jan 2, 2023
2 parents 417ff48 + 733034a commit 7918a34
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 4 deletions.
2 changes: 2 additions & 0 deletions src/gui/settingsdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,8 @@ SettingsDialog::SettingsDialog(ownCloudGui *gui, QWidget *parent)
auto *networkSettings = new NetworkSettings;
_ui->stack->addWidget(networkSettings);

connect(_ui->stack, &QStackedWidget::currentChanged, this, &SettingsDialog::currentPageChanged);

_actionGroupWidgets.insert(generalAction, generalSettings);
_actionGroupWidgets.insert(networkAction, networkSettings);

Expand Down
3 changes: 2 additions & 1 deletion src/gui/settingsdialog.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class ownCloudGui;
class SettingsDialog : public QDialog
{
Q_OBJECT
Q_PROPERTY(QWidget* currentPage READ currentPage)
Q_PROPERTY(QWidget* currentPage READ currentPage NOTIFY currentPageChanged)

public:
explicit SettingsDialog(ownCloudGui *gui, QWidget *parent = nullptr);
Expand All @@ -63,6 +63,7 @@ public slots:
signals:
void styleChanged();
void onActivate();
void currentPageChanged();

protected:
void reject() override;
Expand Down
2 changes: 2 additions & 0 deletions src/gui/wizard/slideshow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ void SlideShow::setInterval(int interval)

_interval = interval;
maybeRestartTimer();

emit intervalChanged();
}

int SlideShow::currentSlide() const
Expand Down
3 changes: 2 additions & 1 deletion src/gui/wizard/slideshow.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ namespace OCC {
class SlideShow : public QWidget
{
Q_OBJECT
Q_PROPERTY(int interval READ interval WRITE setInterval)
Q_PROPERTY(int interval READ interval WRITE setInterval NOTIFY intervalChanged)
Q_PROPERTY(int currentSlide READ currentSlide WRITE setCurrentSlide NOTIFY currentSlideChanged)

public:
Expand Down Expand Up @@ -57,6 +57,7 @@ public slots:
signals:
void clicked();
void currentSlideChanged(int index);
void intervalChanged();

protected:
void mousePressEvent(QMouseEvent *event) override;
Expand Down
4 changes: 2 additions & 2 deletions src/libsync/theme.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ class OWNCLOUDSYNC_EXPORT Theme : public QObject
Q_PROPERTY(QString version READ version CONSTANT)
Q_PROPERTY(QString helpUrl READ helpUrl CONSTANT)
Q_PROPERTY(QString conflictHelpUrl READ conflictHelpUrl CONSTANT)
Q_PROPERTY(QString overrideServerUrl READ overrideServerUrl)
Q_PROPERTY(bool forceOverrideServerUrl READ forceOverrideServerUrl)
Q_PROPERTY(QString overrideServerUrl READ overrideServerUrl CONSTANT)
Q_PROPERTY(bool forceOverrideServerUrl READ forceOverrideServerUrl CONSTANT)
#ifndef TOKEN_AUTH_ONLY
Q_PROPERTY(QColor wizardHeaderTitleColor READ wizardHeaderTitleColor CONSTANT)
Q_PROPERTY(QColor wizardHeaderBackgroundColor READ wizardHeaderBackgroundColor CONSTANT)
Expand Down

0 comments on commit 7918a34

Please sign in to comment.