mirror of
https://github.com/KDE/latte-dock.git
synced 2024-12-26 23:21:37 +03:00
improve Communicator::version
--provide also a way for applets to identify versions and make versions through bridge.actions.version function
This commit is contained in:
parent
5265822fb1
commit
9a7788ab58
@ -19,6 +19,8 @@
|
||||
|
||||
import QtQuick 2.7
|
||||
|
||||
import org.kde.latte 0.2 as Latte
|
||||
|
||||
Item{
|
||||
// NAME: latteSideColoringEnabled
|
||||
// TYPE: bool
|
||||
@ -57,6 +59,14 @@ Item{
|
||||
// and can not be zoomed.
|
||||
// @since: 0.9
|
||||
|
||||
// NAME: windowsTrackingEnabled
|
||||
// TYPE: bool
|
||||
// USAGE: writable through actions.setProperty
|
||||
// EXPLANATION: when is TRUE, Latte is informed that this applet requests
|
||||
// windows tracking. For FALSE, this applet is not requesting
|
||||
// windows tracking.
|
||||
// @since: 0.9
|
||||
|
||||
function setProperty(appletId, parameter, value) {
|
||||
if (parameter === "latteSideColoringEnabled") {
|
||||
mainCommunicator.latteSideColoringEnabled = value;
|
||||
@ -95,4 +105,7 @@ Item{
|
||||
root.broadcastedToApplet(pluginName, action, value);
|
||||
}
|
||||
|
||||
function version(major, minor, patch) {
|
||||
return Latte.WindowSystem.makeVersion(major, minor, patch)
|
||||
}
|
||||
}
|
||||
|
@ -37,7 +37,7 @@ Item{
|
||||
// EXPLANATION: Latte communication version in order for the applet to use only properties
|
||||
// and parameters that are valid
|
||||
// @since: 0.9
|
||||
readonly property int version: 9
|
||||
readonly property int version: root.version
|
||||
|
||||
// NAME: inEditMode
|
||||
// USAGE: read-only
|
||||
|
@ -66,6 +66,8 @@ Item {
|
||||
property bool debugModeWindow: Qt.application.arguments.indexOf("--with-window")>=0
|
||||
property bool debugModeOverloadedIcons: Qt.application.arguments.indexOf("--overloaded-icons")>=0
|
||||
|
||||
readonly property int version: Latte.WindowSystem.makeVersion(0,9,0)
|
||||
|
||||
property bool globalDirectRender: false //it is used as a globalDirectRender for all elements in the dock
|
||||
property int directRenderAnimationTime: 0
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user