[effects] Use arg="true" in the kcfg files
Summary: By changing all kcfg to have arg="true" we can pass in the same KSharedConfigPtr into all effects. This allows to have fake config in the tests and in the planned effect demo mode. Also it means that we don't have to hardcode the name kwinrc into the files. In the configs - where we cannot access the effectshandler - we use the define KWIN_CONFIG which gets generated based on the compile time arguments. Reviewers: #kwin, #plasma Subscribers: plasma-devel, kwin Tags: #kwin Differential Revision: https://phabricator.kde.org/D3571icc-effect-5.14.5
parent
af9f81700f
commit
2132b1e0c8
|
@ -75,13 +75,13 @@ void SlidingPopupsTest::initTestCase()
|
||||||
for (QString name : builtinNames) {
|
for (QString name : builtinNames) {
|
||||||
plugins.writeEntry(name + QStringLiteral("Enabled"), false);
|
plugins.writeEntry(name + QStringLiteral("Enabled"), false);
|
||||||
}
|
}
|
||||||
|
KConfigGroup wobblyGroup = config->group("Effect-Wobbly");
|
||||||
|
wobblyGroup.writeEntry(QStringLiteral("Settings"), QStringLiteral("Custom"));
|
||||||
|
wobblyGroup.writeEntry(QStringLiteral("OpenEffect"), true);
|
||||||
|
wobblyGroup.writeEntry(QStringLiteral("CloseEffect"), true);
|
||||||
|
|
||||||
config->sync();
|
config->sync();
|
||||||
kwinApp()->setConfig(config);
|
kwinApp()->setConfig(config);
|
||||||
// TODO: make effects use KWin's config directly
|
|
||||||
KSharedConfig::openConfig(QStringLiteral(KWIN_CONFIG), KConfig::NoGlobals)->group("Effect-Wobbly").writeEntry(QStringLiteral("Settings"), QStringLiteral("Custom"));
|
|
||||||
KSharedConfig::openConfig(QStringLiteral(KWIN_CONFIG), KConfig::NoGlobals)->group("Effect-Wobbly").writeEntry(QStringLiteral("OpenEffect"), true);
|
|
||||||
KSharedConfig::openConfig(QStringLiteral(KWIN_CONFIG), KConfig::NoGlobals)->group("Effect-Wobbly").writeEntry(QStringLiteral("CloseEffect"), true);
|
|
||||||
|
|
||||||
if (QFile::exists(QStringLiteral("/dev/dri/card0"))) {
|
if (QFile::exists(QStringLiteral("/dev/dri/card0"))) {
|
||||||
qputenv("KWIN_COMPOSE", QByteArrayLiteral("O2"));
|
qputenv("KWIN_COMPOSE", QByteArrayLiteral("O2"));
|
||||||
|
|
|
@ -23,3 +23,10 @@ MockEffectsHandler::MockEffectsHandler(KWin::CompositingType type)
|
||||||
: EffectsHandler(type)
|
: EffectsHandler(type)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
KSharedConfigPtr MockEffectsHandler::config() const
|
||||||
|
{
|
||||||
|
static const KSharedConfigPtr s_config = KSharedConfig::openConfig(QString(), KConfig::SimpleConfig);
|
||||||
|
return s_config;
|
||||||
|
}
|
||||||
|
|
|
@ -260,6 +260,8 @@ public:
|
||||||
}
|
}
|
||||||
void hideOnScreenMessage(OnScreenMessageHideFlags flags = OnScreenMessageHideFlags()) override { Q_UNUSED(flags)}
|
void hideOnScreenMessage(OnScreenMessageHideFlags flags = OnScreenMessageHideFlags()) override { Q_UNUSED(flags)}
|
||||||
|
|
||||||
|
KSharedConfigPtr config() const override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
bool m_animationsSuported = true;
|
bool m_animationsSuported = true;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1621,6 +1621,11 @@ void EffectsHandlerImpl::hideOnScreenMessage(OnScreenMessageHideFlags flags)
|
||||||
OSD::hide(osdFlags);
|
OSD::hide(osdFlags);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
KSharedConfigPtr EffectsHandlerImpl::config() const
|
||||||
|
{
|
||||||
|
return kwinApp()->config();
|
||||||
|
}
|
||||||
|
|
||||||
//****************************************
|
//****************************************
|
||||||
// EffectWindowImpl
|
// EffectWindowImpl
|
||||||
//****************************************
|
//****************************************
|
||||||
|
|
|
@ -241,6 +241,8 @@ public:
|
||||||
void showOnScreenMessage(const QString &message, const QString &iconName = QString()) override;
|
void showOnScreenMessage(const QString &message, const QString &iconName = QString()) override;
|
||||||
void hideOnScreenMessage(OnScreenMessageHideFlags flags = OnScreenMessageHideFlags()) override;
|
void hideOnScreenMessage(OnScreenMessageHideFlags flags = OnScreenMessageHideFlags()) override;
|
||||||
|
|
||||||
|
KSharedConfigPtr config() const override;
|
||||||
|
|
||||||
Scene *scene() const {
|
Scene *scene() const {
|
||||||
return m_scene;
|
return m_scene;
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,6 +39,7 @@ static const QByteArray s_blurAtomName = QByteArrayLiteral("_KDE_NET_WM_BLUR_BEH
|
||||||
|
|
||||||
BlurEffect::BlurEffect()
|
BlurEffect::BlurEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<BlurConfig>();
|
||||||
shader = BlurShader::create();
|
shader = BlurShader::create();
|
||||||
m_simpleShader = ShaderManager::instance()->generateShaderFromResources(ShaderTrait::MapTexture, QString(), QStringLiteral("logout-blur.frag"));
|
m_simpleShader = ShaderManager::instance()->generateShaderFromResources(ShaderTrait::MapTexture, QString(), QStringLiteral("logout-blur.frag"));
|
||||||
if (!m_simpleShader->isValid()) {
|
if (!m_simpleShader->isValid()) {
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-Blur">
|
<group name="Effect-Blur">
|
||||||
<entry name="BlurRadius" type="Int">
|
<entry name="BlurRadius" type="Int">
|
||||||
<default>12</default>
|
<default>12</default>
|
||||||
|
|
|
@ -20,6 +20,7 @@
|
||||||
#include "blur_config.h"
|
#include "blur_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "blurconfig.h"
|
#include "blurconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
|
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
#include <KAboutData>
|
#include <KAboutData>
|
||||||
|
@ -36,6 +37,7 @@ BlurEffectConfig::BlurEffectConfig(QWidget *parent, const QVariantList &args)
|
||||||
: KCModule(KAboutData::pluginData(QStringLiteral("blur")), parent, args)
|
: KCModule(KAboutData::pluginData(QStringLiteral("blur")), parent, args)
|
||||||
{
|
{
|
||||||
ui.setupUi(this);
|
ui.setupUi(this);
|
||||||
|
BlurConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(BlurConfig::self(), this);
|
addConfig(BlurConfig::self(), this);
|
||||||
|
|
||||||
load();
|
load();
|
||||||
|
|
|
@ -54,6 +54,7 @@ CoverSwitchEffect::CoverSwitchEffect()
|
||||||
, primaryTabBox(false)
|
, primaryTabBox(false)
|
||||||
, secondaryTabBox(false)
|
, secondaryTabBox(false)
|
||||||
{
|
{
|
||||||
|
initConfig<CoverSwitchConfig>();
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
|
|
||||||
// Caption frame
|
// Caption frame
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-CoverSwitch">
|
<group name="Effect-CoverSwitch">
|
||||||
<entry name="Duration" type="UInt">
|
<entry name="Duration" type="UInt">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -20,6 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "coverswitch_config.h"
|
#include "coverswitch_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "coverswitchconfig.h"
|
#include "coverswitchconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
|
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
#include <KAboutData>
|
#include <KAboutData>
|
||||||
|
@ -48,6 +49,7 @@ CoverSwitchEffectConfig::CoverSwitchEffectConfig(QWidget* parent, const QVariant
|
||||||
|
|
||||||
layout->addWidget(m_ui);
|
layout->addWidget(m_ui);
|
||||||
|
|
||||||
|
CoverSwitchConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(CoverSwitchConfig::self(), m_ui);
|
addConfig(CoverSwitchConfig::self(), m_ui);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -95,6 +95,7 @@ CubeEffect::CubeEffect()
|
||||||
, m_cylinderAction(new QAction(this))
|
, m_cylinderAction(new QAction(this))
|
||||||
, m_sphereAction(new QAction(this))
|
, m_sphereAction(new QAction(this))
|
||||||
{
|
{
|
||||||
|
initConfig<CubeConfig>();
|
||||||
desktopNameFont.setBold(true);
|
desktopNameFont.setBold(true);
|
||||||
desktopNameFont.setPointSize(14);
|
desktopNameFont.setPointSize(14);
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-Cube">
|
<group name="Effect-Cube">
|
||||||
<entry name="BorderActivate" type="IntList" />
|
<entry name="BorderActivate" type="IntList" />
|
||||||
<entry name="BorderActivateCylinder" type="IntList" />
|
<entry name="BorderActivateCylinder" type="IntList" />
|
||||||
|
|
|
@ -20,6 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "cube_config.h"
|
#include "cube_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "cubeconfig.h"
|
#include "cubeconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -85,6 +86,7 @@ CubeEffectConfig::CubeEffectConfig(QWidget* parent, const QVariantList& args) :
|
||||||
capsSelectionChanged();
|
capsSelectionChanged();
|
||||||
connect(m_ui->kcfg_Caps, SIGNAL(stateChanged(int)), this, SLOT(capsSelectionChanged()));
|
connect(m_ui->kcfg_Caps, SIGNAL(stateChanged(int)), this, SLOT(capsSelectionChanged()));
|
||||||
m_ui->kcfg_Wallpaper->setFilter(QStringLiteral("*.png *.jpeg *.jpg "));
|
m_ui->kcfg_Wallpaper->setFilter(QStringLiteral("*.png *.jpeg *.jpg "));
|
||||||
|
CubeConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(CubeConfig::self(), m_ui);
|
addConfig(CubeConfig::self(), m_ui);
|
||||||
load();
|
load();
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,6 +37,7 @@ CubeSlideEffect::CubeSlideEffect()
|
||||||
, desktopChangedWhileMoving(false)
|
, desktopChangedWhileMoving(false)
|
||||||
, progressRestriction(0.0f)
|
, progressRestriction(0.0f)
|
||||||
{
|
{
|
||||||
|
initConfig<CubeSlideConfig>();
|
||||||
connect(effects, SIGNAL(desktopChanged(int,int)), this, SLOT(slotDesktopChanged(int,int)));
|
connect(effects, SIGNAL(desktopChanged(int,int)), this, SLOT(slotDesktopChanged(int,int)));
|
||||||
connect(effects, SIGNAL(windowStepUserMovedResized(KWin::EffectWindow*,QRect)), this, SLOT(slotWindowStepUserMovedResized(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowStepUserMovedResized(KWin::EffectWindow*,QRect)), this, SLOT(slotWindowStepUserMovedResized(KWin::EffectWindow*)));
|
||||||
connect(effects, SIGNAL(windowFinishUserMovedResized(KWin::EffectWindow*)), this, SLOT(slotWindowFinishUserMovedResized(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowFinishUserMovedResized(KWin::EffectWindow*)), this, SLOT(slotWindowFinishUserMovedResized(KWin::EffectWindow*)));
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-CubeSlide">
|
<group name="Effect-CubeSlide">
|
||||||
<entry name="RotationDuration" type="Int">
|
<entry name="RotationDuration" type="Int">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -20,6 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "cubeslide_config.h"
|
#include "cubeslide_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "cubeslideconfig.h"
|
#include "cubeslideconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <kconfiggroup.h>
|
#include <kconfiggroup.h>
|
||||||
|
@ -48,6 +49,7 @@ CubeSlideEffectConfig::CubeSlideEffectConfig(QWidget* parent, const QVariantList
|
||||||
|
|
||||||
layout->addWidget(m_ui);
|
layout->addWidget(m_ui);
|
||||||
|
|
||||||
|
CubeSlideConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(CubeSlideConfig::self(), m_ui);
|
addConfig(CubeSlideConfig::self(), m_ui);
|
||||||
|
|
||||||
load();
|
load();
|
||||||
|
|
|
@ -66,6 +66,7 @@ DesktopGridEffect::DesktopGridEffect()
|
||||||
, m_proxy(0)
|
, m_proxy(0)
|
||||||
, m_activateAction(new QAction(this))
|
, m_activateAction(new QAction(this))
|
||||||
{
|
{
|
||||||
|
initConfig<DesktopGridConfig>();
|
||||||
// Load shortcuts
|
// Load shortcuts
|
||||||
QAction* a = m_activateAction;
|
QAction* a = m_activateAction;
|
||||||
a->setObjectName(QStringLiteral("ShowDesktopGrid"));
|
a->setObjectName(QStringLiteral("ShowDesktopGrid"));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-DesktopGrid">
|
<group name="Effect-DesktopGrid">
|
||||||
<entry name="BorderActivate" type="IntList" />
|
<entry name="BorderActivate" type="IntList" />
|
||||||
<entry name="TouchBorderActivate" type="IntList" />
|
<entry name="TouchBorderActivate" type="IntList" />
|
||||||
|
|
|
@ -22,6 +22,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "desktopgrid_config.h"
|
#include "desktopgrid_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "desktopgridconfig.h"
|
#include "desktopgridconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -83,6 +84,7 @@ DesktopGridEffectConfig::DesktopGridEffectConfig(QWidget* parent, const QVariant
|
||||||
m_ui->desktopNameAlignmentCombo->addItem(i18n("Top-Left"), QVariant(Qt::AlignLeft | Qt::AlignTop));
|
m_ui->desktopNameAlignmentCombo->addItem(i18n("Top-Left"), QVariant(Qt::AlignLeft | Qt::AlignTop));
|
||||||
m_ui->desktopNameAlignmentCombo->addItem(i18n("Center"), QVariant(Qt::AlignCenter));
|
m_ui->desktopNameAlignmentCombo->addItem(i18n("Center"), QVariant(Qt::AlignCenter));
|
||||||
|
|
||||||
|
DesktopGridConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(DesktopGridConfig::self(), m_ui);
|
addConfig(DesktopGridConfig::self(), m_ui);
|
||||||
connect(m_ui->kcfg_LayoutMode, SIGNAL(currentIndexChanged(int)), this, SLOT(layoutSelectionChanged()));
|
connect(m_ui->kcfg_LayoutMode, SIGNAL(currentIndexChanged(int)), this, SLOT(layoutSelectionChanged()));
|
||||||
connect(m_ui->desktopNameAlignmentCombo, SIGNAL(currentIndexChanged(int)), this, SLOT(changed()));
|
connect(m_ui->desktopNameAlignmentCombo, SIGNAL(currentIndexChanged(int)), this, SLOT(changed()));
|
||||||
|
|
|
@ -30,6 +30,7 @@ namespace KWin
|
||||||
|
|
||||||
DimInactiveEffect::DimInactiveEffect()
|
DimInactiveEffect::DimInactiveEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<DimInactiveConfig>();
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
timeline.setDuration(animationTime(250));
|
timeline.setDuration(animationTime(250));
|
||||||
previousActiveTimeline.setDuration(animationTime(250));
|
previousActiveTimeline.setDuration(animationTime(250));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-DimInactive">
|
<group name="Effect-DimInactive">
|
||||||
<entry name="Strength" type="Int">
|
<entry name="Strength" type="Int">
|
||||||
<default>25</default>
|
<default>25</default>
|
||||||
|
|
|
@ -21,6 +21,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "diminactive_config.h"
|
#include "diminactive_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "diminactiveconfig.h"
|
#include "diminactiveconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
|
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
|
@ -53,6 +54,7 @@ DimInactiveEffectConfig::DimInactiveEffectConfig(QWidget* parent, const QVariant
|
||||||
|
|
||||||
layout->addWidget(m_ui);
|
layout->addWidget(m_ui);
|
||||||
|
|
||||||
|
DimInactiveConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(DimInactiveConfig::self(), m_ui);
|
addConfig(DimInactiveConfig::self(), m_ui);
|
||||||
|
|
||||||
load();
|
load();
|
||||||
|
|
|
@ -34,6 +34,7 @@ bool FallApartEffect::supported()
|
||||||
|
|
||||||
FallApartEffect::FallApartEffect()
|
FallApartEffect::FallApartEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<FallApartConfig>();
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*)));
|
||||||
connect(effects, SIGNAL(windowDeleted(KWin::EffectWindow*)), this, SLOT(slotWindowDeleted(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowDeleted(KWin::EffectWindow*)), this, SLOT(slotWindowDeleted(KWin::EffectWindow*)));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-FallApart">
|
<group name="Effect-FallApart">
|
||||||
<entry name="BlockSize" type="Int">
|
<entry name="BlockSize" type="Int">
|
||||||
<default>40</default>
|
<default>40</default>
|
||||||
|
|
|
@ -48,6 +48,7 @@ FlipSwitchEffect::FlipSwitchEffect()
|
||||||
, m_hasKeyboardGrab(false)
|
, m_hasKeyboardGrab(false)
|
||||||
, m_captionFrame(NULL)
|
, m_captionFrame(NULL)
|
||||||
{
|
{
|
||||||
|
initConfig<FlipSwitchConfig>();
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
|
|
||||||
// Caption frame
|
// Caption frame
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-FlipSwitch">
|
<group name="Effect-FlipSwitch">
|
||||||
<entry name="TabBox" type="Bool">
|
<entry name="TabBox" type="Bool">
|
||||||
<default>false</default>
|
<default>false</default>
|
||||||
|
|
|
@ -20,6 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "flipswitch_config.h"
|
#include "flipswitch_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "flipswitchconfig.h"
|
#include "flipswitchconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -69,6 +70,7 @@ FlipSwitchEffectConfig::FlipSwitchEffectConfig(QWidget* parent, const QVariantLi
|
||||||
|
|
||||||
m_ui->shortcutEditor->addCollection(m_actionCollection);
|
m_ui->shortcutEditor->addCollection(m_actionCollection);
|
||||||
|
|
||||||
|
FlipSwitchConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(FlipSwitchConfig::self(), m_ui);
|
addConfig(FlipSwitchConfig::self(), m_ui);
|
||||||
|
|
||||||
load();
|
load();
|
||||||
|
|
|
@ -36,6 +36,7 @@ static const int IsGlideWindow = 0x22A982D4;
|
||||||
GlideEffect::GlideEffect()
|
GlideEffect::GlideEffect()
|
||||||
: Effect()
|
: Effect()
|
||||||
{
|
{
|
||||||
|
initConfig<GlideConfig>();
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
connect(effects, SIGNAL(windowAdded(KWin::EffectWindow*)), this, SLOT(slotWindowAdded(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowAdded(KWin::EffectWindow*)), this, SLOT(slotWindowAdded(KWin::EffectWindow*)));
|
||||||
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*)));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-Glide">
|
<group name="Effect-Glide">
|
||||||
<entry name="Duration" type="UInt">
|
<entry name="Duration" type="UInt">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -21,6 +21,7 @@
|
||||||
#include "glide_config.h"
|
#include "glide_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "glideconfig.h"
|
#include "glideconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
|
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
#include <KAboutData>
|
#include <KAboutData>
|
||||||
|
@ -37,6 +38,7 @@ GlideEffectConfig::GlideEffectConfig(QWidget *parent, const QVariantList &args)
|
||||||
: KCModule(KAboutData::pluginData(QStringLiteral("glide")), parent, args)
|
: KCModule(KAboutData::pluginData(QStringLiteral("glide")), parent, args)
|
||||||
{
|
{
|
||||||
ui.setupUi(this);
|
ui.setupUi(this);
|
||||||
|
GlideConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(GlideConfig::self(), this);
|
addConfig(GlideConfig::self(), this);
|
||||||
load();
|
load();
|
||||||
}
|
}
|
||||||
|
|
|
@ -55,6 +55,7 @@ KscreenEffect::KscreenEffect()
|
||||||
, m_state(StateNormal)
|
, m_state(StateNormal)
|
||||||
, m_atom(effects->announceSupportProperty("_KDE_KWIN_KSCREEN_SUPPORT", this))
|
, m_atom(effects->announceSupportProperty("_KDE_KWIN_KSCREEN_SUPPORT", this))
|
||||||
{
|
{
|
||||||
|
initConfig<KscreenConfig>();
|
||||||
connect(effects, SIGNAL(propertyNotify(KWin::EffectWindow*,long)), SLOT(propertyNotify(KWin::EffectWindow*,long)));
|
connect(effects, SIGNAL(propertyNotify(KWin::EffectWindow*,long)), SLOT(propertyNotify(KWin::EffectWindow*,long)));
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-Kscreen">
|
<group name="Effect-Kscreen">
|
||||||
<entry name="Duration" type="Int">
|
<entry name="Duration" type="Int">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -52,6 +52,7 @@ LookingGlassEffect::LookingGlassEffect()
|
||||||
, m_enabled(false)
|
, m_enabled(false)
|
||||||
, m_valid(false)
|
, m_valid(false)
|
||||||
{
|
{
|
||||||
|
initConfig<LookingGlassConfig>();
|
||||||
QAction* a;
|
QAction* a;
|
||||||
a = KStandardAction::zoomIn(this, SLOT(zoomIn()), this);
|
a = KStandardAction::zoomIn(this, SLOT(zoomIn()), this);
|
||||||
KGlobalAccel::self()->setDefaultShortcut(a, QList<QKeySequence>() << Qt::META + Qt::Key_Equal);
|
KGlobalAccel::self()->setDefaultShortcut(a, QList<QKeySequence>() << Qt::META + Qt::Key_Equal);
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-LookingGlass">
|
<group name="Effect-LookingGlass">
|
||||||
<entry name="Radius" type="UInt">
|
<entry name="Radius" type="UInt">
|
||||||
<default>200</default>
|
<default>200</default>
|
||||||
|
|
|
@ -22,6 +22,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "lookingglassconfig.h"
|
#include "lookingglassconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -58,6 +59,7 @@ LookingGlassEffectConfig::LookingGlassEffectConfig(QWidget* parent, const QVaria
|
||||||
|
|
||||||
layout->addWidget(m_ui);
|
layout->addWidget(m_ui);
|
||||||
|
|
||||||
|
LookingGlassConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(LookingGlassConfig::self(), m_ui);
|
addConfig(LookingGlassConfig::self(), m_ui);
|
||||||
connect(m_ui->editor, SIGNAL(keyChange()), this, SLOT(changed()));
|
connect(m_ui->editor, SIGNAL(keyChange()), this, SLOT(changed()));
|
||||||
|
|
||||||
|
|
|
@ -34,6 +34,7 @@ namespace KWin
|
||||||
|
|
||||||
MagicLampEffect::MagicLampEffect()
|
MagicLampEffect::MagicLampEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<MagicLampConfig>();
|
||||||
mActiveAnimations = 0;
|
mActiveAnimations = 0;
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
connect(effects, SIGNAL(windowDeleted(KWin::EffectWindow*)), this, SLOT(slotWindowDeleted(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowDeleted(KWin::EffectWindow*)), this, SLOT(slotWindowDeleted(KWin::EffectWindow*)));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-MagicLamp">
|
<group name="Effect-MagicLamp">
|
||||||
<entry name="AnimationDuration" type="Int">
|
<entry name="AnimationDuration" type="Int">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -20,6 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "magiclamp_config.h"
|
#include "magiclamp_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "magiclampconfig.h"
|
#include "magiclampconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
|
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
|
@ -50,6 +51,7 @@ MagicLampEffectConfig::MagicLampEffectConfig(QWidget* parent, const QVariantList
|
||||||
|
|
||||||
layout->addWidget(m_ui);
|
layout->addWidget(m_ui);
|
||||||
|
|
||||||
|
MagicLampConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(MagicLampConfig::self(), m_ui);
|
addConfig(MagicLampConfig::self(), m_ui);
|
||||||
|
|
||||||
load();
|
load();
|
||||||
|
|
|
@ -50,6 +50,7 @@ MagnifierEffect::MagnifierEffect()
|
||||||
, m_pixmap(XCB_PIXMAP_NONE)
|
, m_pixmap(XCB_PIXMAP_NONE)
|
||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
|
initConfig<MagnifierConfig>();
|
||||||
QAction* a;
|
QAction* a;
|
||||||
a = KStandardAction::zoomIn(this, SLOT(zoomIn()), this);
|
a = KStandardAction::zoomIn(this, SLOT(zoomIn()), this);
|
||||||
KGlobalAccel::self()->setDefaultShortcut(a, QList<QKeySequence>() << Qt::META + Qt::Key_Equal);
|
KGlobalAccel::self()->setDefaultShortcut(a, QList<QKeySequence>() << Qt::META + Qt::Key_Equal);
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-Magnifier">
|
<group name="Effect-Magnifier">
|
||||||
<entry name="Width" type="UInt">
|
<entry name="Width" type="UInt">
|
||||||
<default>200</default>
|
<default>200</default>
|
||||||
|
|
|
@ -21,6 +21,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "magnifier_config.h"
|
#include "magnifier_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "magnifierconfig.h"
|
#include "magnifierconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -57,6 +58,7 @@ MagnifierEffectConfig::MagnifierEffectConfig(QWidget* parent, const QVariantList
|
||||||
|
|
||||||
layout->addWidget(m_ui);
|
layout->addWidget(m_ui);
|
||||||
|
|
||||||
|
MagnifierConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(MagnifierConfig::self(), m_ui);
|
addConfig(MagnifierConfig::self(), m_ui);
|
||||||
|
|
||||||
connect(m_ui->editor, SIGNAL(keyChange()), this, SLOT(changed()));
|
connect(m_ui->editor, SIGNAL(keyChange()), this, SLOT(changed()));
|
||||||
|
|
|
@ -43,6 +43,7 @@ namespace KWin
|
||||||
|
|
||||||
MouseClickEffect::MouseClickEffect()
|
MouseClickEffect::MouseClickEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<MouseClickConfig>();
|
||||||
m_enabled = false;
|
m_enabled = false;
|
||||||
|
|
||||||
QAction* a = new QAction(this);
|
QAction* a = new QAction(this);
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-MouseClick">
|
<group name="Effect-MouseClick">
|
||||||
<entry name="Color1" type="Color">
|
<entry name="Color1" type="Color">
|
||||||
<default code="true">QColor(Qt::red)</default>
|
<default code="true">QColor(Qt::red)</default>
|
||||||
|
|
|
@ -21,6 +21,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "mouseclick_config.h"
|
#include "mouseclick_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "mouseclickconfig.h"
|
#include "mouseclickconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -67,6 +68,7 @@ MouseClickEffectConfig::MouseClickEffectConfig(QWidget* parent, const QVariantLi
|
||||||
|
|
||||||
m_ui->editor->addCollection(m_actionCollection);
|
m_ui->editor->addCollection(m_actionCollection);
|
||||||
|
|
||||||
|
MouseClickConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(MouseClickConfig::self(), m_ui);
|
addConfig(MouseClickConfig::self(), m_ui);
|
||||||
load();
|
load();
|
||||||
}
|
}
|
||||||
|
|
|
@ -46,6 +46,7 @@ namespace KWin
|
||||||
|
|
||||||
MouseMarkEffect::MouseMarkEffect()
|
MouseMarkEffect::MouseMarkEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<MouseMarkConfig>();
|
||||||
QAction* a = new QAction(this);
|
QAction* a = new QAction(this);
|
||||||
a->setObjectName(QStringLiteral("ClearMouseMarks"));
|
a->setObjectName(QStringLiteral("ClearMouseMarks"));
|
||||||
a->setText(i18n("Clear All Mouse Marks"));
|
a->setText(i18n("Clear All Mouse Marks"));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-MouseMark">
|
<group name="Effect-MouseMark">
|
||||||
<entry name="LineWidth" type="UInt">
|
<entry name="LineWidth" type="UInt">
|
||||||
<default>3</default>
|
<default>3</default>
|
||||||
|
|
|
@ -22,6 +22,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "mousemarkconfig.h"
|
#include "mousemarkconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -58,6 +59,7 @@ MouseMarkEffectConfig::MouseMarkEffectConfig(QWidget* parent, const QVariantList
|
||||||
|
|
||||||
layout->addWidget(m_ui);
|
layout->addWidget(m_ui);
|
||||||
|
|
||||||
|
MouseMarkConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(MouseMarkConfig::self(), m_ui);
|
addConfig(MouseMarkConfig::self(), m_ui);
|
||||||
|
|
||||||
// Shortcut config. The shortcut belongs to the component "kwin"!
|
// Shortcut config. The shortcut belongs to the component "kwin"!
|
||||||
|
|
|
@ -65,6 +65,7 @@ PresentWindowsEffect::PresentWindowsEffect()
|
||||||
, m_exposeAllAction(new QAction(this))
|
, m_exposeAllAction(new QAction(this))
|
||||||
, m_exposeClassAction(new QAction(this))
|
, m_exposeClassAction(new QAction(this))
|
||||||
{
|
{
|
||||||
|
initConfig<PresentWindowsConfig>();
|
||||||
m_atomDesktop = effects->announceSupportProperty("_KDE_PRESENT_WINDOWS_DESKTOP", this);
|
m_atomDesktop = effects->announceSupportProperty("_KDE_PRESENT_WINDOWS_DESKTOP", this);
|
||||||
m_atomWindows = effects->announceSupportProperty("_KDE_PRESENT_WINDOWS_GROUP", this);
|
m_atomWindows = effects->announceSupportProperty("_KDE_PRESENT_WINDOWS_GROUP", this);
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-PresentWindows">
|
<group name="Effect-PresentWindows">
|
||||||
<entry name="LayoutMode" type="Int">
|
<entry name="LayoutMode" type="Int">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -22,6 +22,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "presentwindows_config.h"
|
#include "presentwindows_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "presentwindowsconfig.h"
|
#include "presentwindowsconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
|
||||||
|
@ -84,6 +85,7 @@ PresentWindowsEffectConfig::PresentWindowsEffectConfig(QWidget* parent, const QV
|
||||||
|
|
||||||
connect(m_ui->shortcutEditor, SIGNAL(keyChange()), this, SLOT(changed()));
|
connect(m_ui->shortcutEditor, SIGNAL(keyChange()), this, SLOT(changed()));
|
||||||
|
|
||||||
|
PresentWindowsConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(PresentWindowsConfig::self(), m_ui);
|
addConfig(PresentWindowsConfig::self(), m_ui);
|
||||||
|
|
||||||
load();
|
load();
|
||||||
|
|
|
@ -40,6 +40,7 @@ ResizeEffect::ResizeEffect()
|
||||||
, m_active(false)
|
, m_active(false)
|
||||||
, m_resizeWindow(0)
|
, m_resizeWindow(0)
|
||||||
{
|
{
|
||||||
|
initConfig<ResizeConfig>();
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
connect(effects, SIGNAL(windowStartUserMovedResized(KWin::EffectWindow*)), this, SLOT(slotWindowStartUserMovedResized(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowStartUserMovedResized(KWin::EffectWindow*)), this, SLOT(slotWindowStartUserMovedResized(KWin::EffectWindow*)));
|
||||||
connect(effects, SIGNAL(windowStepUserMovedResized(KWin::EffectWindow*,QRect)), this, SLOT(slotWindowStepUserMovedResized(KWin::EffectWindow*,QRect)));
|
connect(effects, SIGNAL(windowStepUserMovedResized(KWin::EffectWindow*,QRect)), this, SLOT(slotWindowStepUserMovedResized(KWin::EffectWindow*,QRect)));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-Resize">
|
<group name="Effect-Resize">
|
||||||
<entry name="TextureScale" type="Bool">
|
<entry name="TextureScale" type="Bool">
|
||||||
<default>true</default>
|
<default>true</default>
|
||||||
|
|
|
@ -20,6 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "resize_config.h"
|
#include "resize_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "resizeconfig.h"
|
#include "resizeconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <kconfiggroup.h>
|
#include <kconfiggroup.h>
|
||||||
|
@ -49,6 +50,7 @@ ResizeEffectConfig::ResizeEffectConfig(QWidget* parent, const QVariantList& args
|
||||||
|
|
||||||
layout->addWidget(m_ui);
|
layout->addWidget(m_ui);
|
||||||
|
|
||||||
|
ResizeConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(ResizeConfig::self(), m_ui);
|
addConfig(ResizeConfig::self(), m_ui);
|
||||||
|
|
||||||
load();
|
load();
|
||||||
|
|
|
@ -35,6 +35,7 @@ static const int IsSheetWindow = 0x22A982D5;
|
||||||
|
|
||||||
SheetEffect::SheetEffect()
|
SheetEffect::SheetEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<SheetConfig>();
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
connect(effects, SIGNAL(windowAdded(KWin::EffectWindow*)), this, SLOT(slotWindowAdded(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowAdded(KWin::EffectWindow*)), this, SLOT(slotWindowAdded(KWin::EffectWindow*)));
|
||||||
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*)));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-Sheet">
|
<group name="Effect-Sheet">
|
||||||
<entry name="AnimationTime" type="Int">
|
<entry name="AnimationTime" type="Int">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -47,6 +47,7 @@ ShowFpsEffect::ShowFpsEffect()
|
||||||
, frames_pos(0)
|
, frames_pos(0)
|
||||||
, m_noBenchmark(effects->effectFrame(EffectFrameUnstyled, false))
|
, m_noBenchmark(effects->effectFrame(EffectFrameUnstyled, false))
|
||||||
{
|
{
|
||||||
|
initConfig<ShowFpsConfig>();
|
||||||
for (int i = 0;
|
for (int i = 0;
|
||||||
i < NUM_PAINTS;
|
i < NUM_PAINTS;
|
||||||
++i) {
|
++i) {
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-ShowFps">
|
<group name="Effect-ShowFps">
|
||||||
<entry name="TextPosition" type="Int">
|
<entry name="TextPosition" type="Int">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -22,6 +22,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "showfpsconfig.h"
|
#include "showfpsconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <KLocalizedString>
|
#include <KLocalizedString>
|
||||||
|
@ -41,6 +42,7 @@ ShowFpsEffectConfig::ShowFpsEffectConfig(QWidget* parent, const QVariantList& ar
|
||||||
m_ui = new Ui::ShowFpsEffectConfigForm;
|
m_ui = new Ui::ShowFpsEffectConfigForm;
|
||||||
m_ui->setupUi(this);
|
m_ui->setupUi(this);
|
||||||
|
|
||||||
|
ShowFpsConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(ShowFpsConfig::self(), this);
|
addConfig(ShowFpsConfig::self(), this);
|
||||||
|
|
||||||
load();
|
load();
|
||||||
|
|
|
@ -33,6 +33,7 @@ namespace KWin
|
||||||
|
|
||||||
SlidingPopupsEffect::SlidingPopupsEffect()
|
SlidingPopupsEffect::SlidingPopupsEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<SlidingPopupsConfig>();
|
||||||
KWayland::Server::Display *display = effects->waylandDisplay();
|
KWayland::Server::Display *display = effects->waylandDisplay();
|
||||||
if (display) {
|
if (display) {
|
||||||
display->createSlideManager(this)->create();
|
display->createSlideManager(this)->create();
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-SlidingPopups">
|
<group name="Effect-SlidingPopups">
|
||||||
<entry name="SlideInTime" type="Int">
|
<entry name="SlideInTime" type="Int">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -32,6 +32,7 @@ namespace KWin
|
||||||
|
|
||||||
ThumbnailAsideEffect::ThumbnailAsideEffect()
|
ThumbnailAsideEffect::ThumbnailAsideEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<ThumbnailAsideConfig>();
|
||||||
QAction* a = new QAction(this);
|
QAction* a = new QAction(this);
|
||||||
a->setObjectName(QStringLiteral("ToggleCurrentThumbnail"));
|
a->setObjectName(QStringLiteral("ToggleCurrentThumbnail"));
|
||||||
a->setText(i18n("Toggle Thumbnail for Current Window"));
|
a->setText(i18n("Toggle Thumbnail for Current Window"));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-ThumbnailAside">
|
<group name="Effect-ThumbnailAside">
|
||||||
<entry name="MaxWidth" type="Int">
|
<entry name="MaxWidth" type="Int">
|
||||||
<default>200</default>
|
<default>200</default>
|
||||||
|
|
|
@ -21,6 +21,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "thumbnailaside_config.h"
|
#include "thumbnailaside_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "thumbnailasideconfig.h"
|
#include "thumbnailasideconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -58,6 +59,7 @@ ThumbnailAsideEffectConfig::ThumbnailAsideEffectConfig(QWidget* parent, const QV
|
||||||
|
|
||||||
connect(m_ui->editor, SIGNAL(keyChange()), this, SLOT(changed()));
|
connect(m_ui->editor, SIGNAL(keyChange()), this, SLOT(changed()));
|
||||||
|
|
||||||
|
ThumbnailAsideConfig::instance(KWIN_CONFIG);
|
||||||
addConfig(ThumbnailAsideConfig::self(), this);
|
addConfig(ThumbnailAsideConfig::self(), this);
|
||||||
|
|
||||||
// Shortcut config. The shortcut belongs to the component "kwin"!
|
// Shortcut config. The shortcut belongs to the component "kwin"!
|
||||||
|
|
|
@ -45,6 +45,7 @@ TrackMouseEffect::TrackMouseEffect()
|
||||||
: m_active(false)
|
: m_active(false)
|
||||||
, m_angle(0)
|
, m_angle(0)
|
||||||
{
|
{
|
||||||
|
initConfig<TrackMouseConfig>();
|
||||||
m_texture[0] = m_texture[1] = 0;
|
m_texture[0] = m_texture[1] = 0;
|
||||||
#ifdef KWIN_HAVE_XRENDER_COMPOSITING
|
#ifdef KWIN_HAVE_XRENDER_COMPOSITING
|
||||||
m_picture[0] = m_picture[1] = 0;
|
m_picture[0] = m_picture[1] = 0;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-TrackMouse">
|
<group name="Effect-TrackMouse">
|
||||||
<entry name="Meta" type="Bool">
|
<entry name="Meta" type="Bool">
|
||||||
<default>true</default>
|
<default>true</default>
|
||||||
|
|
|
@ -20,6 +20,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*********************************************************************/
|
*********************************************************************/
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <KLocalizedString>
|
#include <KLocalizedString>
|
||||||
|
@ -51,7 +52,7 @@ TrackMouseEffectConfigForm::TrackMouseEffectConfigForm(QWidget* parent) : QWidge
|
||||||
TrackMouseEffectConfig::TrackMouseEffectConfig(QWidget* parent, const QVariantList& args) :
|
TrackMouseEffectConfig::TrackMouseEffectConfig(QWidget* parent, const QVariantList& args) :
|
||||||
KCModule(KAboutData::pluginData(QStringLiteral("trackmouse")), parent, args)
|
KCModule(KAboutData::pluginData(QStringLiteral("trackmouse")), parent, args)
|
||||||
{
|
{
|
||||||
|
TrackMouseConfig::instance(KWIN_CONFIG);
|
||||||
m_ui = new TrackMouseEffectConfigForm(this);
|
m_ui = new TrackMouseEffectConfigForm(this);
|
||||||
QVBoxLayout* layout = new QVBoxLayout(this);
|
QVBoxLayout* layout = new QVBoxLayout(this);
|
||||||
layout->addWidget(m_ui);
|
layout->addWidget(m_ui);
|
||||||
|
|
|
@ -34,6 +34,7 @@ using namespace KWin;
|
||||||
|
|
||||||
WindowGeometry::WindowGeometry()
|
WindowGeometry::WindowGeometry()
|
||||||
{
|
{
|
||||||
|
initConfig<WindowGeometryConfiguration>();
|
||||||
iAmActivated = true;
|
iAmActivated = true;
|
||||||
iAmActive = false;
|
iAmActive = false;
|
||||||
myResizeWindow = 0L;
|
myResizeWindow = 0L;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-WindowGeometry">
|
<group name="Effect-WindowGeometry">
|
||||||
<entry name="Move" type="Bool">
|
<entry name="Move" type="Bool">
|
||||||
<default>true</default>
|
<default>true</default>
|
||||||
|
|
|
@ -21,6 +21,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "windowgeometry_config.h"
|
#include "windowgeometry_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "windowgeometryconfig.h"
|
#include "windowgeometryconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -46,6 +47,7 @@ WindowGeometryConfigForm::WindowGeometryConfigForm(QWidget* parent) : QWidget(pa
|
||||||
WindowGeometryConfig::WindowGeometryConfig(QWidget* parent, const QVariantList& args)
|
WindowGeometryConfig::WindowGeometryConfig(QWidget* parent, const QVariantList& args)
|
||||||
: KCModule(KAboutData::pluginData(QStringLiteral("windowgeometry")), parent, args)
|
: KCModule(KAboutData::pluginData(QStringLiteral("windowgeometry")), parent, args)
|
||||||
{
|
{
|
||||||
|
WindowGeometryConfiguration::instance(KWIN_CONFIG);
|
||||||
QVBoxLayout* layout = new QVBoxLayout(this);
|
QVBoxLayout* layout = new QVBoxLayout(this);
|
||||||
layout->addWidget(myUi = new WindowGeometryConfigForm(this));
|
layout->addWidget(myUi = new WindowGeometryConfigForm(this));
|
||||||
|
|
||||||
|
|
|
@ -146,6 +146,7 @@ static const ParameterSet pset[5] = { set_0, set_1, set_2, set_3, set_4 };
|
||||||
|
|
||||||
WobblyWindowsEffect::WobblyWindowsEffect()
|
WobblyWindowsEffect::WobblyWindowsEffect()
|
||||||
{
|
{
|
||||||
|
initConfig<WobblyWindowsConfig>();
|
||||||
reconfigure(ReconfigureAll);
|
reconfigure(ReconfigureAll);
|
||||||
connect(effects, SIGNAL(windowAdded(KWin::EffectWindow*)), this, SLOT(slotWindowAdded(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowAdded(KWin::EffectWindow*)), this, SLOT(slotWindowAdded(KWin::EffectWindow*)));
|
||||||
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*)));
|
connect(effects, SIGNAL(windowClosed(KWin::EffectWindow*)), this, SLOT(slotWindowClosed(KWin::EffectWindow*)));
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-Wobbly">
|
<group name="Effect-Wobbly">
|
||||||
<entry name="WobblynessLevel" type="UInt">
|
<entry name="WobblynessLevel" type="UInt">
|
||||||
<default>0</default>
|
<default>0</default>
|
||||||
|
|
|
@ -22,6 +22,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "wobblywindows_config.h"
|
#include "wobblywindows_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "wobblywindowsconfig.h"
|
#include "wobblywindowsconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <KLocalizedString>
|
#include <KLocalizedString>
|
||||||
|
@ -82,6 +83,7 @@ ParameterSet pset[5] = { set_0, set_1, set_2, set_3, set_4 };
|
||||||
WobblyWindowsEffectConfig::WobblyWindowsEffectConfig(QWidget* parent, const QVariantList& args) :
|
WobblyWindowsEffectConfig::WobblyWindowsEffectConfig(QWidget* parent, const QVariantList& args) :
|
||||||
KCModule(KAboutData::pluginData(QStringLiteral("wobblywindows")), parent, args)
|
KCModule(KAboutData::pluginData(QStringLiteral("wobblywindows")), parent, args)
|
||||||
{
|
{
|
||||||
|
WobblyWindowsConfig::instance(KWIN_CONFIG);
|
||||||
m_ui.setupUi(this);
|
m_ui.setupUi(this);
|
||||||
|
|
||||||
addConfig(WobblyWindowsConfig::self(), this);
|
addConfig(WobblyWindowsConfig::self(), this);
|
||||||
|
|
|
@ -60,6 +60,7 @@ ZoomEffect::ZoomEffect()
|
||||||
, yMove(0)
|
, yMove(0)
|
||||||
, moveFactor(20.0)
|
, moveFactor(20.0)
|
||||||
{
|
{
|
||||||
|
initConfig<ZoomConfig>();
|
||||||
QAction* a = 0;
|
QAction* a = 0;
|
||||||
a = KStandardAction::zoomIn(this, SLOT(zoomIn()), this);
|
a = KStandardAction::zoomIn(this, SLOT(zoomIn()), this);
|
||||||
KGlobalAccel::self()->setDefaultShortcut(a, QList<QKeySequence>() << Qt::META + Qt::Key_Equal);
|
KGlobalAccel::self()->setDefaultShortcut(a, QList<QKeySequence>() << Qt::META + Qt::Key_Equal);
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0
|
||||||
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" >
|
||||||
<kcfgfile name="kwinrc"/>
|
<kcfgfile arg="true"/>
|
||||||
<group name="Effect-Zoom">
|
<group name="Effect-Zoom">
|
||||||
<entry name="ZoomFactor" type="Double">
|
<entry name="ZoomFactor" type="Double">
|
||||||
<default>1.2</default>
|
<default>1.2</default>
|
||||||
|
|
|
@ -22,6 +22,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include "zoom_config.h"
|
#include "zoom_config.h"
|
||||||
// KConfigSkeleton
|
// KConfigSkeleton
|
||||||
#include "zoomconfig.h"
|
#include "zoomconfig.h"
|
||||||
|
#include <config-kwin.h>
|
||||||
#include <kwineffects_interface.h>
|
#include <kwineffects_interface.h>
|
||||||
|
|
||||||
#include <QAction>
|
#include <QAction>
|
||||||
|
@ -49,6 +50,7 @@ ZoomEffectConfigForm::ZoomEffectConfigForm(QWidget* parent) : QWidget(parent)
|
||||||
ZoomEffectConfig::ZoomEffectConfig(QWidget* parent, const QVariantList& args) :
|
ZoomEffectConfig::ZoomEffectConfig(QWidget* parent, const QVariantList& args) :
|
||||||
KCModule(KAboutData::pluginData(QStringLiteral("zoom")), parent, args)
|
KCModule(KAboutData::pluginData(QStringLiteral("zoom")), parent, args)
|
||||||
{
|
{
|
||||||
|
ZoomConfig::instance(KWIN_CONFIG);
|
||||||
m_ui = new ZoomEffectConfigForm(this);
|
m_ui = new ZoomEffectConfigForm(this);
|
||||||
|
|
||||||
QVBoxLayout* layout = new QVBoxLayout(this);
|
QVBoxLayout* layout = new QVBoxLayout(this);
|
||||||
|
|
|
@ -89,7 +89,7 @@ macro( KWIN4_ADD_GLUTILS_BACKEND name glinclude )
|
||||||
include_directories(${glinclude})
|
include_directories(${glinclude})
|
||||||
add_library(${name} SHARED ${kwin_GLUTILSLIB_SRCS})
|
add_library(${name} SHARED ${kwin_GLUTILSLIB_SRCS})
|
||||||
generate_export_header(${name} BASE_NAME kwinglutils EXPORT_FILE_NAME kwinglutils_export.h)
|
generate_export_header(${name} BASE_NAME kwinglutils EXPORT_FILE_NAME kwinglutils_export.h)
|
||||||
target_link_libraries(${name} PUBLIC XCB::XCB KF5::CoreAddons KF5::WindowSystem)
|
target_link_libraries(${name} PUBLIC XCB::XCB KF5::CoreAddons KF5::ConfigCore KF5::WindowSystem)
|
||||||
set_target_properties(${name} PROPERTIES
|
set_target_properties(${name} PROPERTIES
|
||||||
VERSION ${KWINEFFECTS_VERSION_STRING}
|
VERSION ${KWINEFFECTS_VERSION_STRING}
|
||||||
SOVERSION ${KWINEFFECTS_SOVERSION}
|
SOVERSION ${KWINEFFECTS_SOVERSION}
|
||||||
|
|
|
@ -43,6 +43,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include <QScopedPointer>
|
#include <QScopedPointer>
|
||||||
|
|
||||||
#include <KPluginFactory>
|
#include <KPluginFactory>
|
||||||
|
#include <KSharedConfig>
|
||||||
|
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
#include <limits.h>
|
#include <limits.h>
|
||||||
|
@ -665,6 +666,14 @@ public Q_SLOTS:
|
||||||
protected:
|
protected:
|
||||||
xcb_connection_t *xcbConnection() const;
|
xcb_connection_t *xcbConnection() const;
|
||||||
xcb_window_t x11RootWindow() const;
|
xcb_window_t x11RootWindow() const;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* An implementing class can call this with it's kconfig compiled singleton class.
|
||||||
|
* This method will perform the instance on the class.
|
||||||
|
* @since 5.9
|
||||||
|
**/
|
||||||
|
template <typename T>
|
||||||
|
void initConfig();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -1291,6 +1300,12 @@ public:
|
||||||
**/
|
**/
|
||||||
virtual void hideOnScreenMessage(OnScreenMessageHideFlags flags = OnScreenMessageHideFlags()) = 0;
|
virtual void hideOnScreenMessage(OnScreenMessageHideFlags flags = OnScreenMessageHideFlags()) = 0;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @returns The configuration used by the EffectsHandler.
|
||||||
|
* @since 5.10
|
||||||
|
**/
|
||||||
|
virtual KSharedConfigPtr config() const = 0;
|
||||||
|
|
||||||
Q_SIGNALS:
|
Q_SIGNALS:
|
||||||
/**
|
/**
|
||||||
* Signal emitted when the current desktop changed.
|
* Signal emitted when the current desktop changed.
|
||||||
|
@ -3440,6 +3455,12 @@ int Effect::animationTime(int defaultDuration)
|
||||||
return animationTime(T::duration() != 0 ? T::duration() : defaultDuration);
|
return animationTime(T::duration() != 0 ? T::duration() : defaultDuration);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <typename T>
|
||||||
|
void Effect::initConfig()
|
||||||
|
{
|
||||||
|
T::instance(effects->config());
|
||||||
|
}
|
||||||
|
|
||||||
} // namespace
|
} // namespace
|
||||||
Q_DECLARE_METATYPE(KWin::EffectWindow*)
|
Q_DECLARE_METATYPE(KWin::EffectWindow*)
|
||||||
Q_DECLARE_METATYPE(QList<KWin::EffectWindow*>)
|
Q_DECLARE_METATYPE(QList<KWin::EffectWindow*>)
|
||||||
|
|
Loading…
Reference in New Issue