cf12defd28
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
90 lines
1.7 KiB
Plaintext
90 lines
1.7 KiB
Plaintext
// This file is generated by kconfig_compiler_kf6 from test14.kcfg.
|
|
// All changes you do to this file will be lost.
|
|
#ifndef TEST14_H
|
|
#define TEST14_H
|
|
|
|
#include <qglobal.h>
|
|
#include <kconfigskeleton.h>
|
|
#include <QCoreApplication>
|
|
#include <QDebug>
|
|
#include <qqmlintegration.h>
|
|
|
|
class Test14 : public KConfigSkeleton
|
|
{
|
|
Q_OBJECT
|
|
QML_ELEMENT
|
|
public:
|
|
|
|
Test14( );
|
|
~Test14() override;
|
|
|
|
Q_PROPERTY(QUrl picturesDir READ picturesDir CONSTANT)
|
|
Q_PROPERTY(bool isPicturesDirImmutable READ isPicturesDirImmutable CONSTANT)
|
|
/**
|
|
Get picturesDir
|
|
*/
|
|
QUrl picturesDir() const
|
|
{
|
|
return mPicturesDir;
|
|
}
|
|
|
|
/**
|
|
Is picturesDir Immutable
|
|
*/
|
|
bool isPicturesDirImmutable() const
|
|
{
|
|
return isImmutable( QStringLiteral( "picturesDir" ) );
|
|
}
|
|
|
|
/**
|
|
Set brightness
|
|
*/
|
|
void setBrightness( double v )
|
|
{
|
|
if (v != mBrightness && !isBrightnessImmutable()) {
|
|
mBrightness = v;
|
|
Q_EMIT brightnessChanged();
|
|
}
|
|
}
|
|
|
|
Q_PROPERTY(double brightness READ brightness WRITE setBrightness NOTIFY brightnessChanged)
|
|
Q_PROPERTY(bool isBrightnessImmutable READ isBrightnessImmutable CONSTANT)
|
|
/**
|
|
Get brightness
|
|
*/
|
|
double brightness() const
|
|
{
|
|
return mBrightness;
|
|
}
|
|
|
|
/**
|
|
Is brightness Immutable
|
|
*/
|
|
bool isBrightnessImmutable() const
|
|
{
|
|
return isImmutable( QStringLiteral( "brightness" ) );
|
|
}
|
|
|
|
|
|
enum {
|
|
signalBrightnessChanged = 1
|
|
};
|
|
|
|
Q_SIGNALS:
|
|
void brightnessChanged();
|
|
|
|
private:
|
|
void itemChanged(quint64 signalFlag);
|
|
|
|
protected:
|
|
|
|
// kamoso
|
|
QUrl mPicturesDir;
|
|
double mBrightness;
|
|
|
|
private:
|
|
};
|
|
|
|
#endif
|
|
|