Changeset View
Changeset View
Standalone View
Standalone View
scripting/scriptedeffect.h
Show First 20 Lines • Show All 64 Lines • ▼ Show 20 Line(s) | 41 | public: | |||
---|---|---|---|---|---|
65 | } | 65 | } | ||
66 | QString activeConfig() const; | 66 | QString activeConfig() const; | ||
67 | void setActiveConfig(const QString &name); | 67 | void setActiveConfig(const QString &name); | ||
68 | static ScriptedEffect *create(const QString &effectName, const QString &pathToScript, int chainPosition); | 68 | static ScriptedEffect *create(const QString &effectName, const QString &pathToScript, int chainPosition); | ||
69 | static ScriptedEffect *create(const KPluginMetaData &effect); | 69 | static ScriptedEffect *create(const KPluginMetaData &effect); | ||
70 | static bool supported(); | 70 | static bool supported(); | ||
71 | virtual ~ScriptedEffect(); | 71 | virtual ~ScriptedEffect(); | ||
72 | /** | 72 | /** | ||
73 | * Whether another effect has grabbed the @p w with the given @p grabRole. | | |||
74 | * @param w The window to check | | |||
75 | * @param grabRole The grab role to check | | |||
76 | * @returns @c true if another window has grabbed the effect, @c false otherwise | | |||
77 | **/ | | |||
78 | Q_SCRIPTABLE bool isGrabbed(KWin::EffectWindow *w, DataRole grabRole); | | |||
79 | /** | | |||
80 | * Reads the value from the configuration data for the given key. | 73 | * Reads the value from the configuration data for the given key. | ||
81 | * @param key The key to search for | 74 | * @param key The key to search for | ||
82 | * @param defaultValue The value to return if the key is not found | 75 | * @param defaultValue The value to return if the key is not found | ||
83 | * @returns The config value if present | 76 | * @returns The config value if present | ||
84 | **/ | 77 | **/ | ||
85 | Q_SCRIPTABLE QVariant readConfig(const QString &key, const QVariant defaultValue = QVariant()); | 78 | Q_SCRIPTABLE QVariant readConfig(const QString &key, const QVariant defaultValue = QVariant()); | ||
86 | void registerShortcut(QAction *a, QScriptValue callback); | 79 | void registerShortcut(QAction *a, QScriptValue callback); | ||
87 | const QHash<QAction*, QScriptValue> &shortcutCallbacks() const { | 80 | const QHash<QAction*, QScriptValue> &shortcutCallbacks() const { | ||
▲ Show 20 Lines • Show All 45 Lines • Show Last 20 Lines |