mirror of
https://github.com/YACReader/yacreader
synced 2025-07-18 04:54:29 -04:00
Fix QML in Qt6
This means having two versions of everything, the idea is to migrate to Qt6, test that everything works fine and drop Qt5 as soon as possible.
This commit is contained in:
32
YACReaderLibrary/qml/InfoFavorites6.qml
Normal file
32
YACReaderLibrary/qml/InfoFavorites6.qml
Normal file
@ -0,0 +1,32 @@
|
||||
import QtQuick 2.15
|
||||
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
Item {
|
||||
width: 20
|
||||
height: 20
|
||||
|
||||
property bool active
|
||||
|
||||
signal activeChangedByUser(bool active)
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: favorites_button_compact
|
||||
onClicked: {
|
||||
activeChangedByUser(!active);
|
||||
}
|
||||
}
|
||||
|
||||
Image {
|
||||
anchors.centerIn: parent
|
||||
id: favorites_button_compact
|
||||
source: "info-favorites.png"
|
||||
}
|
||||
|
||||
ColorOverlay {
|
||||
anchors.fill: favorites_button_compact
|
||||
source: favorites_button_compact
|
||||
color: active ? favCheckedColor : favUncheckedColor
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user