mirror of
https://github.com/moonlight-stream/moonlight-qt.git
synced 2026-10-26 05:50:49 +00:00
Keep a singleton ComputerManager outside of the Models
This commit is contained in:
1 parent
0d26ef7e5c
commit
1b1ad86271
9 files changed
+72
-24
No files matched your search
+4
-2
@@ -3,6 +3,8 @@ import QtQuick.Controls 2.2
|
||||
|
||||
import AppModel 1.0
|
||||
|
||||
import ComputerManager 1.0
|
||||
|
||||
GridView {
|
||||
property int computerIndex
|
||||
|
||||
@@ -16,8 +18,8 @@ GridView {
|
||||
|
||||
function createModel()
|
||||
{
|
||||
var model = Qt.createQmlObject('import AppModel 1.0; AppModel {}', parent, "")
|
||||
model.initialize(computerIndex)
|
||||
var model = Qt.createQmlObject('import AppModel 1.0; AppModel {}', parent, '')
|
||||
model.initialize(ComputerManager, computerIndex)
|
||||
return model
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user