mirror of
https://github.com/status-im/status-desktop.git
synced 2025-02-21 11:08:55 +00:00
Introduced Style.svg() Style.png() Style.emoji() and Style.icon() in Style.qml. Those should be used to set the source in Images instead of using relative paths. Usage: Image { source: Style.svg("check) .... Also moved all Singletons inside a new "utils" folder and made it a QML module, to use import utils 1.0 instead of relative paths Closes #3678
30 lines
562 B
QML
30 lines
562 B
QML
import QtQuick 2.13
|
|
|
|
import utils 1.0
|
|
|
|
Rectangle {
|
|
signal released()
|
|
signal pressed()
|
|
|
|
id: root
|
|
width: 25
|
|
height: 25
|
|
border.width: 2
|
|
border.color: Style.current.orange
|
|
color: Utils.setColorAlpha(Style.current.orange, 0.5)
|
|
|
|
Drag.active: dragArea.drag.active
|
|
|
|
MouseArea {
|
|
id: dragArea
|
|
property int oldX
|
|
property int oldY
|
|
|
|
anchors.fill: parent
|
|
drag.target: parent
|
|
cursorShape: Qt.PointingHandCursor
|
|
onReleased: root.released()
|
|
onPressed: root.pressed()
|
|
}
|
|
}
|