mirror of
https://github.com/QuasarApp/Snake.git
synced 2025-04-26 17:54:42 +00:00
34 lines
631 B
QML
34 lines
631 B
QML
import QtQuick 2.12
|
|
import QtQuick.Window 2.12
|
|
import QtQuick.Controls 2.12
|
|
|
|
ApplicationWindow {
|
|
id: mainWindow;
|
|
visible: true;
|
|
width: 1140;
|
|
height: 540;
|
|
title: qsTr("SnakeOnTheRoad");
|
|
|
|
readonly property int pointCount: 100;
|
|
|
|
property real point: (width < height) ? width/pointCount : height/pointCount;
|
|
|
|
Scene {
|
|
id: scane;
|
|
model: contr;
|
|
anchors.fill: parent;
|
|
}
|
|
|
|
MainMenu {
|
|
|
|
model: (contr)? contr.mainMenuModel: null;
|
|
anchors.fill: parent;
|
|
visible: scane.showMenu;
|
|
|
|
onPlayGame: {
|
|
scane.showMenu = false;
|
|
}
|
|
|
|
}
|
|
}
|