[add] PuzzleAppView
This commit is contained in:
@@ -49,7 +49,7 @@ const app = new Project(
|
||||
sources: [
|
||||
'src/haxe',
|
||||
],
|
||||
main: 'ru.m.puzzlez.App',
|
||||
main: 'ru.m.puzzlez.PuzzlezApp',
|
||||
meta: {
|
||||
width: 1024,
|
||||
height: 768,
|
||||
|
||||
49
package-lock.json
generated
49
package-lock.json
generated
@@ -2584,6 +2584,55 @@
|
||||
"vinyl": "^2.1.0"
|
||||
}
|
||||
},
|
||||
"gulp-cli": {
|
||||
"version": "2.2.0",
|
||||
"resolved": "https://registry.npmjs.org/gulp-cli/-/gulp-cli-2.2.0.tgz",
|
||||
"integrity": "sha512-rGs3bVYHdyJpLqR0TUBnlcZ1O5O++Zs4bA0ajm+zr3WFCfiSLjGwoCBqFs18wzN+ZxahT9DkOK5nDf26iDsWjA==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"ansi-colors": "^1.0.1",
|
||||
"archy": "^1.0.0",
|
||||
"array-sort": "^1.0.0",
|
||||
"color-support": "^1.1.3",
|
||||
"concat-stream": "^1.6.0",
|
||||
"copy-props": "^2.0.1",
|
||||
"fancy-log": "^1.3.2",
|
||||
"gulplog": "^1.0.0",
|
||||
"interpret": "^1.1.0",
|
||||
"isobject": "^3.0.1",
|
||||
"liftoff": "^3.1.0",
|
||||
"matchdep": "^2.0.0",
|
||||
"mute-stdout": "^1.0.0",
|
||||
"pretty-hrtime": "^1.0.0",
|
||||
"replace-homedir": "^1.0.0",
|
||||
"semver-greatest-satisfied-range": "^1.1.0",
|
||||
"v8flags": "^3.0.1",
|
||||
"yargs": "^7.1.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"yargs": {
|
||||
"version": "7.1.0",
|
||||
"resolved": "https://registry.npmjs.org/yargs/-/yargs-7.1.0.tgz",
|
||||
"integrity": "sha1-a6MY6xaWFyf10oT46gA+jWFU0Mg=",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"camelcase": "^3.0.0",
|
||||
"cliui": "^3.2.0",
|
||||
"decamelize": "^1.1.1",
|
||||
"get-caller-file": "^1.0.1",
|
||||
"os-locale": "^1.4.0",
|
||||
"read-pkg-up": "^1.0.1",
|
||||
"require-directory": "^2.1.1",
|
||||
"require-main-filename": "^1.0.1",
|
||||
"set-blocking": "^2.0.0",
|
||||
"string-width": "^1.0.2",
|
||||
"which-module": "^1.0.0",
|
||||
"y18n": "^3.2.1",
|
||||
"yargs-parser": "^5.0.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"gulp-debian": {
|
||||
"version": "0.1.9",
|
||||
"resolved": "https://registry.npmjs.org/gulp-debian/-/gulp-debian-0.1.9.tgz",
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
"gulp": "^4.0.0",
|
||||
"gulp-add": "0.0.2",
|
||||
"gulp-clean": "^0.4.0",
|
||||
"gulp-cli": "^2.2.0",
|
||||
"gulp-haxetool": "0.1.3",
|
||||
"yargs": "^13.2.4"
|
||||
},
|
||||
@@ -15,5 +16,6 @@
|
||||
"lime": "7.5.0",
|
||||
"openfl": "8.9.1",
|
||||
"hxcpp": "4.0.52"
|
||||
}
|
||||
},
|
||||
"dependencies": {}
|
||||
}
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
package ru.m.puzzlez;
|
||||
|
||||
class App {
|
||||
public static function main() {
|
||||
trace("ok");
|
||||
}
|
||||
}
|
||||
15
src/haxe/ru/m/puzzlez/PuzzlezApp.hx
Normal file
15
src/haxe/ru/m/puzzlez/PuzzlezApp.hx
Normal file
@@ -0,0 +1,15 @@
|
||||
package ru.m.puzzlez;
|
||||
|
||||
import haxework.App;
|
||||
import haxework.log.TraceLogger;
|
||||
import ru.m.puzzlez.view.PuzzlezAppView;
|
||||
|
||||
class PuzzlezApp extends App {
|
||||
|
||||
public static function main() {
|
||||
L.push(new TraceLogger());
|
||||
var app = new PuzzlezApp(new PuzzlezTheme());
|
||||
app.start(new PuzzlezAppView());
|
||||
L.d("Puzzlez", "started");
|
||||
}
|
||||
}
|
||||
10
src/haxe/ru/m/puzzlez/PuzzlezTheme.hx
Normal file
10
src/haxe/ru/m/puzzlez/PuzzlezTheme.hx
Normal file
@@ -0,0 +1,10 @@
|
||||
package ru.m.puzzlez;
|
||||
|
||||
import haxework.view.theme.Theme;
|
||||
|
||||
class PuzzlezTheme extends Theme {
|
||||
|
||||
public function new() {
|
||||
super({name: 'Georgia'}, {light: 'gray'});
|
||||
}
|
||||
}
|
||||
10
src/haxe/ru/m/puzzlez/view/PuzzlezAppView.hx
Normal file
10
src/haxe/ru/m/puzzlez/view/PuzzlezAppView.hx
Normal file
@@ -0,0 +1,10 @@
|
||||
package ru.m.puzzlez.view;
|
||||
|
||||
import haxework.view.group.VGroupView;
|
||||
|
||||
@:template class PuzzlezAppView extends VGroupView {
|
||||
|
||||
public function new() {
|
||||
super();
|
||||
}
|
||||
}
|
||||
10
src/haxe/ru/m/puzzlez/view/PuzzlezAppView.yaml
Normal file
10
src/haxe/ru/m/puzzlez/view/PuzzlezAppView.yaml
Normal file
@@ -0,0 +1,10 @@
|
||||
style: background
|
||||
layout.hAlign: center
|
||||
layout.vAlign: middle
|
||||
layout.margin: 20
|
||||
views:
|
||||
- $type: haxework.view.form.LabelView
|
||||
text: Puzzle'z
|
||||
font.size: 42
|
||||
- $type: haxework.view.form.ButtonView
|
||||
text: Start
|
||||
Reference in New Issue
Block a user