mirror of
https://github.com/YACReader/yacreader
synced 2025-05-28 03:10:27 -04:00
Use a Loader to create the rating menu on demand to improve performance
This commit is contained in:
parent
3b54012d90
commit
44ae4cc2a6
@ -376,16 +376,23 @@ SplitView {
|
|||||||
comicsSelectionHelper.clear();
|
comicsSelectionHelper.clear();
|
||||||
comicsSelectionHelper.selectIndex(index);
|
comicsSelectionHelper.selectIndex(index);
|
||||||
grid.currentIndex = index;
|
grid.currentIndex = index;
|
||||||
ratingConextMenu.popup();
|
ratingLoader.active = true;
|
||||||
|
ratingLoader.item.popup();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loader {
|
||||||
|
id: ratingLoader
|
||||||
|
active: false
|
||||||
|
sourceComponent: ratingConextMenuComponent
|
||||||
|
}
|
||||||
|
|
||||||
|
Component {
|
||||||
|
id: ratingConextMenuComponent
|
||||||
Menu {
|
Menu {
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
implicitWidth: 42
|
implicitWidth: 42
|
||||||
implicitHeight: 100
|
implicitHeight: 100
|
||||||
//border.color: "#222"
|
|
||||||
//color: "#444"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
id: ratingConextMenu
|
id: ratingConextMenu
|
||||||
@ -401,6 +408,7 @@ SplitView {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//comic rating
|
//comic rating
|
||||||
Text {
|
Text {
|
||||||
|
Loading…
Reference in New Issue
Block a user