From 682eaa677cedada88aa7a1768903b79e6c56c85b Mon Sep 17 00:00:00 2001 From: shmyga Date: Mon, 27 May 2024 11:31:35 +0300 Subject: [PATCH] refactor: update to haxework 2.1.0 --- package.json | 2 +- src/client/haxe/ru/m/control/ControlBus.hx | 2 +- src/client/haxe/ru/m/control/IControlBus.hx | 2 +- .../haxe/ru/m/control/IControlDevice.hx | 2 +- .../haxe/ru/m/control/JoystickDevice.hx | 2 +- .../haxe/ru/m/control/KeyboardDevice.hx | 2 +- src/client/haxe/ru/m/skin/ButtonSVGSkin.hx | 8 +-- src/client/haxe/ru/m/tankz/AppTheme.hx | 22 ++++---- src/client/haxe/ru/m/tankz/Client.hx | 17 +++--- src/client/haxe/ru/m/tankz/Init.hx | 10 ++-- src/client/haxe/ru/m/tankz/Preloader.hx | 2 +- .../haxe/ru/m/tankz/network/NetworkManager.hx | 2 +- src/client/haxe/ru/m/tankz/render/IRender.hx | 2 +- src/client/haxe/ru/m/tankz/render/Render.hx | 4 +- .../m/tankz/render/item/BulletRenderItem.hx | 4 +- .../ru/m/tankz/render/item/EagleRenderItem.hx | 4 +- .../ru/m/tankz/render/item/TankRenderItem.hx | 8 +-- .../haxe/ru/m/tankz/storage/GameStorage.hx | 2 +- .../haxe/ru/m/tankz/storage/NetworkStorage.hx | 2 +- .../haxe/ru/m/tankz/storage/RecordStorage.hx | 2 +- .../ru/m/tankz/storage/SettingsStorage.hx | 6 +-- src/client/haxe/ru/m/tankz/view/ClientView.hx | 6 +-- .../haxe/ru/m/tankz/view/ClientView.yaml | 2 +- src/client/haxe/ru/m/tankz/view/GameFrame.hx | 8 +-- .../haxe/ru/m/tankz/view/GameFrame.yaml | 2 +- src/client/haxe/ru/m/tankz/view/LevelFrame.hx | 10 ++-- .../haxe/ru/m/tankz/view/LevelFrame.yaml | 14 ++--- src/client/haxe/ru/m/tankz/view/MenuFrame.hx | 8 +-- .../haxe/ru/m/tankz/view/MenuFrame.yaml | 26 +++++----- .../haxe/ru/m/tankz/view/RecordFrame.hx | 6 +-- .../haxe/ru/m/tankz/view/RecordFrame.yaml | 14 ++--- .../haxe/ru/m/tankz/view/ResultFrame.hx | 10 ++-- .../haxe/ru/m/tankz/view/ResultFrame.yaml | 20 +++---- .../haxe/ru/m/tankz/view/SettingsFrame.hx | 6 +-- .../haxe/ru/m/tankz/view/SettingsFrame.yaml | 24 ++++----- src/client/haxe/ru/m/tankz/view/StartFrame.hx | 10 ++-- .../haxe/ru/m/tankz/view/StartFrame.yaml | 20 +++---- .../m/tankz/view/common/NetworkStateView.hx | 10 ++-- .../m/tankz/view/common/NetworkStateView.yaml | 12 ++--- .../haxe/ru/m/tankz/view/common/PackView.hx | 4 +- .../haxe/ru/m/tankz/view/common/PackView.yaml | 4 +- .../haxe/ru/m/tankz/view/common/RecordView.hx | 8 +-- .../ru/m/tankz/view/common/RecordView.yaml | 12 ++--- .../haxe/ru/m/tankz/view/common/SlotView.hx | 10 ++-- .../haxe/ru/m/tankz/view/common/SlotView.yaml | 6 +-- .../haxe/ru/m/tankz/view/common/TankView.hx | 2 +- .../haxe/ru/m/tankz/view/game/GameViewA.hx | 6 +-- .../haxe/ru/m/tankz/view/game/GameViewA.yaml | 10 ++-- .../haxe/ru/m/tankz/view/game/GameViewB.hx | 6 +-- .../haxe/ru/m/tankz/view/game/GameViewB.yaml | 10 ++-- .../ru/m/tankz/view/game/GameViewContainer.hx | 6 +-- .../haxe/ru/m/tankz/view/game/IGameView.hx | 6 +-- .../haxe/ru/m/tankz/view/game/PlayerView.hx | 4 +- .../haxe/ru/m/tankz/view/game/PlayerView.yaml | 8 +-- .../haxe/ru/m/tankz/view/game/TeamView.hx | 2 +- .../ru/m/tankz/view/gamepad/GamepadSkin.hx | 4 +- .../ru/m/tankz/view/gamepad/GamepadView.hx | 4 +- .../view/gamepad/SmartActionAreaBuilder.hx | 2 +- .../haxe/ru/m/tankz/view/network/RoomFrame.hx | 10 ++-- .../ru/m/tankz/view/network/RoomFrame.yaml | 18 +++---- .../ru/m/tankz/view/network/RoomItemView.hx | 8 +-- .../ru/m/tankz/view/network/RoomItemView.yaml | 8 +-- .../ru/m/tankz/view/network/RoomListFrame.hx | 6 +-- .../m/tankz/view/network/RoomListFrame.yaml | 10 ++-- .../ru/m/tankz/view/network/SlotItemView.hx | 8 +-- .../ru/m/tankz/view/network/SlotItemView.yaml | 8 +-- .../ru/m/tankz/view/popup/CreateGamePopup.hx | 6 +-- .../m/tankz/view/popup/CreateGamePopup.yaml | 26 +++++----- .../haxe/ru/m/tankz/view/popup/LoginPopup.hx | 8 +-- .../ru/m/tankz/view/popup/LoginPopup.yaml | 24 ++++----- .../haxe/ru/m/tankz/view/popup/PausePopup.hx | 2 +- .../ru/m/tankz/view/popup/PausePopup.yaml | 14 ++--- .../haxe/ru/m/tankz/view/result/FragView.hx | 4 +- .../haxe/ru/m/tankz/view/result/FragView.yaml | 6 +-- .../m/tankz/view/result/ResultPlayerView.hx | 8 +-- .../m/tankz/view/result/ResultPlayerView.yaml | 12 ++--- .../ru/m/tankz/view/settings/ActionView.hx | 6 +-- .../ru/m/tankz/view/settings/ActionView.yaml | 4 +- .../m/tankz/view/settings/SettingsEditor.hx | 8 +-- .../m/tankz/view/settings/SettingsEditor.yaml | 16 +++--- src/client/haxe/ru/m/update/Updater.hx | 2 +- src/common/haxe/ru/m/Timer.hx | 2 +- .../haxe/ru/m/connect/BaseConnection.hx | 2 +- src/common/haxe/ru/m/connect/IConnection.hx | 2 +- src/common/haxe/ru/m/tankz/Type.hx | 2 +- .../ru/m/tankz/bundle/CachedLevelBundle.hx | 2 +- src/common/haxe/ru/m/tankz/config/Config.hx | 2 +- .../haxe/ru/m/tankz/control/PlayerControl.hx | 2 +- src/common/haxe/ru/m/tankz/core/Bullet.hx | 2 +- src/common/haxe/ru/m/tankz/core/Eagle.hx | 2 +- src/common/haxe/ru/m/tankz/core/Tank.hx | 2 +- src/common/haxe/ru/m/tankz/engine/IEngine.hx | 2 +- .../haxe/ru/m/tankz/game/EntityBuilder.hx | 2 +- src/common/haxe/ru/m/tankz/game/GameEvent.hx | 2 +- src/common/haxe/ru/m/tankz/game/GameState.hx | 2 +- src/common/haxe/ru/m/tankz/game/IGame.hx | 2 +- .../haxe/ru/m/tankz/editor/ColorView.hx | 6 +-- src/editor/haxe/ru/m/tankz/editor/Editor.hx | 18 +++---- .../haxe/ru/m/tankz/editor/EditorStorage.hx | 2 +- .../haxe/ru/m/tankz/editor/view/EditorView.hx | 4 +- .../ru/m/tankz/editor/view/EditorView.yaml | 2 +- .../haxe/ru/m/tankz/editor/view/PackFrame.hx | 12 ++--- .../ru/m/tankz/editor/view/PackFrame.yaml | 52 +++++++++---------- .../ru/m/tankz/editor/view/PackListFrame.hx | 6 +-- .../ru/m/tankz/editor/view/PackListFrame.yaml | 16 +++--- .../haxe/ru/m/tankz/editor/view/PackView.hx | 10 ++-- .../haxe/ru/m/tankz/editor/view/PackView.yaml | 6 +-- .../haxe/ru/m/tankz/editor/view/TankFrame.hx | 8 +-- .../ru/m/tankz/editor/view/TankFrame.yaml | 8 +-- .../ru/m/tankz/editor/view/map/BrushView.hx | 4 +- .../m/tankz/editor/view/map/SpawnPointView.hx | 2 +- .../ru/m/tankz/editor/view/popup/PackPopup.hx | 6 +-- .../m/tankz/editor/view/popup/PackPopup.yaml | 22 ++++---- .../ru/m/tankz/editor/view/tank/TankView.hx | 6 +-- src/server/haxe/ru/m/tankz/server/Server.hx | 4 +- .../ru/m/tankz/server/game/IGameManager.hx | 2 +- .../ru/m/tankz/server/session/GameSession.hx | 2 +- 117 files changed, 440 insertions(+), 439 deletions(-) diff --git a/package.json b/package.json index 62ac6f3..9b41e5d 100755 --- a/package.json +++ b/package.json @@ -11,7 +11,7 @@ "yargs": "^13.2.4" }, "haxeDependencies": { - "haxework": "1.3.0", + "haxework": "2.1.0", "lime": "8.0.0", "openfl": "9.2.0", "hxcpp": "4.2.1", diff --git a/src/client/haxe/ru/m/control/ControlBus.hx b/src/client/haxe/ru/m/control/ControlBus.hx index 2fc32d3..4a7886b 100644 --- a/src/client/haxe/ru/m/control/ControlBus.hx +++ b/src/client/haxe/ru/m/control/ControlBus.hx @@ -1,6 +1,6 @@ package ru.m.control; -import haxework.signal.Signal; +import hw.signal.Signal; import ru.m.control.IControlBus; class ControlBus implements IControlBus { diff --git a/src/client/haxe/ru/m/control/IControlBus.hx b/src/client/haxe/ru/m/control/IControlBus.hx index dee18bb..a9e337c 100644 --- a/src/client/haxe/ru/m/control/IControlBus.hx +++ b/src/client/haxe/ru/m/control/IControlBus.hx @@ -1,6 +1,6 @@ package ru.m.control; -import haxework.signal.Signal; +import hw.signal.Signal; interface IControlBus { public var devices(default, null):Array; diff --git a/src/client/haxe/ru/m/control/IControlDevice.hx b/src/client/haxe/ru/m/control/IControlDevice.hx index a870c45..70b7121 100644 --- a/src/client/haxe/ru/m/control/IControlDevice.hx +++ b/src/client/haxe/ru/m/control/IControlDevice.hx @@ -1,6 +1,6 @@ package ru.m.control; -import haxework.signal.Signal; +import hw.signal.Signal; interface IControlDevice { public var type(default, null):DeviceType; diff --git a/src/client/haxe/ru/m/control/JoystickDevice.hx b/src/client/haxe/ru/m/control/JoystickDevice.hx index 8da1d42..2a177b0 100644 --- a/src/client/haxe/ru/m/control/JoystickDevice.hx +++ b/src/client/haxe/ru/m/control/JoystickDevice.hx @@ -1,6 +1,6 @@ package ru.m.control; -import haxework.signal.Signal; +import hw.signal.Signal; import lime.ui.Joystick; import ru.m.control.DeviceAction; import ru.m.control.DeviceType; diff --git a/src/client/haxe/ru/m/control/KeyboardDevice.hx b/src/client/haxe/ru/m/control/KeyboardDevice.hx index fbdd6f1..a968c87 100644 --- a/src/client/haxe/ru/m/control/KeyboardDevice.hx +++ b/src/client/haxe/ru/m/control/KeyboardDevice.hx @@ -2,7 +2,7 @@ package ru.m.control; import flash.display.Stage; import flash.events.KeyboardEvent; -import haxework.signal.Signal; +import hw.signal.Signal; import ru.m.control.DeviceAction; class KeyboardDevice implements IControlDevice { diff --git a/src/client/haxe/ru/m/skin/ButtonSVGSkin.hx b/src/client/haxe/ru/m/skin/ButtonSVGSkin.hx index a66fa58..ee87121 100644 --- a/src/client/haxe/ru/m/skin/ButtonSVGSkin.hx +++ b/src/client/haxe/ru/m/skin/ButtonSVGSkin.hx @@ -1,12 +1,12 @@ package ru.m.skin; import format.SVG; -import haxework.color.Color; -import haxework.view.form.ButtonView; -import haxework.view.skin.ISkin; +import hw.color.Color; +import hw.view.form.ButtonView; +import hw.view.skin.ISkin; using StringTools; -using haxework.color.ColorUtil; +using hw.color.ColorUtil; @:style class ButtonSVGSkin implements ISkin { diff --git a/src/client/haxe/ru/m/tankz/AppTheme.hx b/src/client/haxe/ru/m/tankz/AppTheme.hx index bb039bb..8f4ce35 100644 --- a/src/client/haxe/ru/m/tankz/AppTheme.hx +++ b/src/client/haxe/ru/m/tankz/AppTheme.hx @@ -1,18 +1,18 @@ package ru.m.tankz; import flash.text.TextFormatAlign; -import haxework.color.Color; -import haxework.view.geometry.Box; -import haxework.view.geometry.HAlign; -import haxework.view.geometry.SizeValue; -import haxework.view.geometry.VAlign; -import haxework.view.theme.ITheme; -import haxework.view.theme.Theme; -import haxework.view.utils.DrawUtil; +import hw.color.Color; +import hw.view.geometry.Box; +import hw.view.geometry.HAlign; +import hw.view.geometry.SizeValue; +import hw.view.geometry.VAlign; +import hw.view.theme.ITheme; +import hw.view.theme.Theme; +import hw.view.utils.DrawUtil; import openfl.Assets; import ru.m.skin.ButtonSVGSkin; -using haxework.color.ColorUtil; +using hw.color.ColorUtil; class AppTheme extends Theme { @@ -24,7 +24,7 @@ class AppTheme extends Theme { } public function new() { - super({embed: true}, COLORS); + super({embed: true}, COLORS, {base: "4h"}); } override private function reload():Void { @@ -59,7 +59,7 @@ class AppTheme extends Theme { ], ["button"])); register(new Style("button.small", [ - "font.size" => 14, + "font.size" => SizeValue.fromString("3h"), "geometry.padding" => Box.fromArray([8, 2]), "skin.round" => 5, ], ["button"])); diff --git a/src/client/haxe/ru/m/tankz/Client.hx b/src/client/haxe/ru/m/tankz/Client.hx index 414a19e..6182fc5 100755 --- a/src/client/haxe/ru/m/tankz/Client.hx +++ b/src/client/haxe/ru/m/tankz/Client.hx @@ -2,11 +2,11 @@ package ru.m.tankz; import ru.m.animate.AnimateManager; import flash.Lib; -import haxework.animate.Animate; -import haxework.log.TraceLogger; -import haxework.net.manage.LoaderManager; -import haxework.view.Root; -import haxework.view.popup.PopupManager; +import hw.animate.Animate; +import hw.log.TraceLogger; +import hw.net.manage.LoaderManager; +import hw.view.Root; +import hw.view.popup.PopupManager; import ru.m.tankz.storage.GameStorage; import ru.m.tankz.storage.SettingsStorage; import ru.m.tankz.view.ClientView; @@ -19,10 +19,10 @@ class Client { public static function main() { L.push(new TraceLogger()); #if flash - L.push(new haxework.log.JSLogger()); + L.push(new hw.log.JSLogger()); #end #if debug - //L.push(new haxework.log.SocketLogger()); + //L.push(new hw.log.SocketLogger()); #end // ToDo: fix @:provide macro PopupManager; @@ -32,7 +32,8 @@ class Client { // Const.init(); Init.init(); - Animate.bind(Lib.current.stage); + // TODO: + // Animate.bind(Lib.current.stage); L.d(TAG, 'Debug: ${Const.DEBUG}'); L.i(TAG, 'Version: ${Const.VERSION}'); L.i(TAG, 'Build: ${Const.BUILD}'); diff --git a/src/client/haxe/ru/m/tankz/Init.hx b/src/client/haxe/ru/m/tankz/Init.hx index 546643d..1c7d2ec 100644 --- a/src/client/haxe/ru/m/tankz/Init.hx +++ b/src/client/haxe/ru/m/tankz/Init.hx @@ -1,11 +1,11 @@ package ru.m.tankz; import flash.Lib; -import haxework.animate.FadeAnimate; -import haxework.animate.UnFadeAnimate; -import haxework.storage.SharedObjectStorage; -import haxework.view.popup.PopupManager; -import haxework.view.theme.ITheme; +import hw.animate.FadeAnimate; +import hw.animate.UnFadeAnimate; +import hw.storage.SharedObjectStorage; +import hw.view.popup.PopupManager; +import hw.view.theme.ITheme; import lime.ui.Gamepad; import lime.ui.Joystick; import ru.m.connect.IConnection; diff --git a/src/client/haxe/ru/m/tankz/Preloader.hx b/src/client/haxe/ru/m/tankz/Preloader.hx index fd4d5df..029ac8e 100644 --- a/src/client/haxe/ru/m/tankz/Preloader.hx +++ b/src/client/haxe/ru/m/tankz/Preloader.hx @@ -5,7 +5,7 @@ import flash.display.Sprite; import flash.events.Event; import flash.events.ProgressEvent; import flash.Lib; -import haxework.view.geometry.Size; +import hw.view.geometry.Size; import ru.m.tankz.AppTheme; class Progress extends Sprite { diff --git a/src/client/haxe/ru/m/tankz/network/NetworkManager.hx b/src/client/haxe/ru/m/tankz/network/NetworkManager.hx index dbc88c8..be7ef5e 100644 --- a/src/client/haxe/ru/m/tankz/network/NetworkManager.hx +++ b/src/client/haxe/ru/m/tankz/network/NetworkManager.hx @@ -1,7 +1,7 @@ package ru.m.tankz.network; import haxe.Serializer; -import haxework.signal.Signal; +import hw.signal.Signal; import ru.m.connect.IConnection; import ru.m.tankz.control.Control; import ru.m.tankz.game.GameEvent; diff --git a/src/client/haxe/ru/m/tankz/render/IRender.hx b/src/client/haxe/ru/m/tankz/render/IRender.hx index f0464a1..42380be 100644 --- a/src/client/haxe/ru/m/tankz/render/IRender.hx +++ b/src/client/haxe/ru/m/tankz/render/IRender.hx @@ -1,6 +1,6 @@ package ru.m.tankz.render; -import haxework.view.IView; +import hw.view.IView; import ru.m.tankz.config.Config; import ru.m.tankz.game.IGame; diff --git a/src/client/haxe/ru/m/tankz/render/Render.hx b/src/client/haxe/ru/m/tankz/render/Render.hx index 14120e5..b07ab0e 100755 --- a/src/client/haxe/ru/m/tankz/render/Render.hx +++ b/src/client/haxe/ru/m/tankz/render/Render.hx @@ -5,8 +5,8 @@ import flash.display.Graphics; import flash.display.Sprite; import flash.events.Event; import haxe.Timer; -import haxework.view.form.LabelView; -import haxework.view.SpriteView; +import hw.view.form.LabelView; +import hw.view.SpriteView; import promhx.Promise; import ru.m.animate.Animate; import ru.m.animate.AnimateManager; diff --git a/src/client/haxe/ru/m/tankz/render/item/BulletRenderItem.hx b/src/client/haxe/ru/m/tankz/render/item/BulletRenderItem.hx index ebd6048..9d09fb9 100644 --- a/src/client/haxe/ru/m/tankz/render/item/BulletRenderItem.hx +++ b/src/client/haxe/ru/m/tankz/render/item/BulletRenderItem.hx @@ -1,7 +1,7 @@ package ru.m.tankz.render.item; -import haxework.color.Color; -import haxework.view.utils.BitmapUtil; +import hw.color.Color; +import hw.view.utils.BitmapUtil; import ru.m.geom.Rectangle; class BulletRenderItem extends BitmapRenderItem { diff --git a/src/client/haxe/ru/m/tankz/render/item/EagleRenderItem.hx b/src/client/haxe/ru/m/tankz/render/item/EagleRenderItem.hx index 5e6cdf7..2062a23 100644 --- a/src/client/haxe/ru/m/tankz/render/item/EagleRenderItem.hx +++ b/src/client/haxe/ru/m/tankz/render/item/EagleRenderItem.hx @@ -2,8 +2,8 @@ package ru.m.tankz.render.item; import flash.display.DisplayObject; import flash.display.Sprite; -import haxework.color.Color; -import haxework.view.utils.BitmapUtil; +import hw.color.Color; +import hw.view.utils.BitmapUtil; import ru.m.animate.Animate; import ru.m.geom.Rectangle; diff --git a/src/client/haxe/ru/m/tankz/render/item/TankRenderItem.hx b/src/client/haxe/ru/m/tankz/render/item/TankRenderItem.hx index b19888c..5f0b439 100644 --- a/src/client/haxe/ru/m/tankz/render/item/TankRenderItem.hx +++ b/src/client/haxe/ru/m/tankz/render/item/TankRenderItem.hx @@ -7,10 +7,10 @@ import flash.display.Sprite; import flash.text.TextField; import flash.text.TextFieldAutoSize; import flash.text.TextFormat; -import haxework.color.Color; -import haxework.text.BitmapTextField; -import haxework.view.theme.ITheme; -import haxework.view.utils.BitmapUtil; +import hw.color.Color; +import hw.text.BitmapTextField; +import hw.view.theme.ITheme; +import hw.view.utils.BitmapUtil; import ru.m.animate.Animate; import ru.m.geom.Rectangle; diff --git a/src/client/haxe/ru/m/tankz/storage/GameStorage.hx b/src/client/haxe/ru/m/tankz/storage/GameStorage.hx index 4d282ba..08992d8 100644 --- a/src/client/haxe/ru/m/tankz/storage/GameStorage.hx +++ b/src/client/haxe/ru/m/tankz/storage/GameStorage.hx @@ -1,6 +1,6 @@ package ru.m.tankz.storage; -import haxework.storage.SharedObjectStorage; +import hw.storage.SharedObjectStorage; import ru.m.tankz.game.PackProgress; import ru.m.tankz.Type; diff --git a/src/client/haxe/ru/m/tankz/storage/NetworkStorage.hx b/src/client/haxe/ru/m/tankz/storage/NetworkStorage.hx index 8c3c4e4..9edd8ba 100644 --- a/src/client/haxe/ru/m/tankz/storage/NetworkStorage.hx +++ b/src/client/haxe/ru/m/tankz/storage/NetworkStorage.hx @@ -1,6 +1,6 @@ package ru.m.tankz.storage; -import haxework.storage.SharedObjectStorage; +import hw.storage.SharedObjectStorage; @:provide class NetworkStorage extends SharedObjectStorage { diff --git a/src/client/haxe/ru/m/tankz/storage/RecordStorage.hx b/src/client/haxe/ru/m/tankz/storage/RecordStorage.hx index 7f803fb..3517a4a 100644 --- a/src/client/haxe/ru/m/tankz/storage/RecordStorage.hx +++ b/src/client/haxe/ru/m/tankz/storage/RecordStorage.hx @@ -1,7 +1,7 @@ package ru.m.tankz.storage; import haxe.DynamicAccess; -import haxework.storage.SharedObjectStorage; +import hw.storage.SharedObjectStorage; import ru.m.tankz.game.record.GameRecord; @:provide class RecordStorage extends SharedObjectStorage { diff --git a/src/client/haxe/ru/m/tankz/storage/SettingsStorage.hx b/src/client/haxe/ru/m/tankz/storage/SettingsStorage.hx index 8921bd6..d484492 100644 --- a/src/client/haxe/ru/m/tankz/storage/SettingsStorage.hx +++ b/src/client/haxe/ru/m/tankz/storage/SettingsStorage.hx @@ -1,9 +1,9 @@ package ru.m.tankz.storage; import flash.ui.Keyboard; -import haxework.signal.Signal; -import haxework.storage.SharedObjectStorage; -import haxework.utils.ObjectUtil; +import hw.signal.Signal; +import hw.storage.SharedObjectStorage; +import hw.utils.ObjectUtil; import ru.m.control.DeviceAction; import ru.m.control.DeviceType; import ru.m.geom.Direction; diff --git a/src/client/haxe/ru/m/tankz/view/ClientView.hx b/src/client/haxe/ru/m/tankz/view/ClientView.hx index 6383b62..971f13b 100644 --- a/src/client/haxe/ru/m/tankz/view/ClientView.hx +++ b/src/client/haxe/ru/m/tankz/view/ClientView.hx @@ -1,9 +1,9 @@ package ru.m.tankz.view; import flash.ui.Keyboard; -import haxework.resources.IResources; -import haxework.view.frame.FrameSwitcher; -import haxework.view.group.VGroupView; +import hw.resources.IResources; +import hw.view.frame.FrameSwitcher; +import hw.view.group.VGroupView; import ru.m.control.DeviceAction; import ru.m.control.DeviceType; import ru.m.control.IControlBus; diff --git a/src/client/haxe/ru/m/tankz/view/ClientView.yaml b/src/client/haxe/ru/m/tankz/view/ClientView.yaml index 518988a..8e1c95a 100755 --- a/src/client/haxe/ru/m/tankz/view/ClientView.yaml +++ b/src/client/haxe/ru/m/tankz/view/ClientView.yaml @@ -1,6 +1,6 @@ --- views: - - $type: haxework.view.frame.FrameSwitcher + - $type: hw.view.frame.FrameSwitcher id: switcher geometry.stretch: true style: dark diff --git a/src/client/haxe/ru/m/tankz/view/GameFrame.hx b/src/client/haxe/ru/m/tankz/view/GameFrame.hx index 3013777..ee8eafa 100644 --- a/src/client/haxe/ru/m/tankz/view/GameFrame.hx +++ b/src/client/haxe/ru/m/tankz/view/GameFrame.hx @@ -3,10 +3,10 @@ package ru.m.tankz.view; import ru.m.tankz.view.popup.PausePopup; import flash.ui.Keyboard; import ru.m.control.DeviceAction; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; -import haxework.view.group.GroupView; -import haxework.view.layout.DefaultLayout; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; +import hw.view.group.GroupView; +import hw.view.layout.DefaultLayout; import ru.m.control.DeviceType; import ru.m.control.IControlBus; import ru.m.tankz.control.HumanControl; diff --git a/src/client/haxe/ru/m/tankz/view/GameFrame.yaml b/src/client/haxe/ru/m/tankz/view/GameFrame.yaml index 6709dd8..d89e17b 100644 --- a/src/client/haxe/ru/m/tankz/view/GameFrame.yaml +++ b/src/client/haxe/ru/m/tankz/view/GameFrame.yaml @@ -12,7 +12,7 @@ views: geometry.position: absolute geometry.stretch: true visible: false - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.bars geometry.position: absolute geometry.hAlign: left diff --git a/src/client/haxe/ru/m/tankz/view/LevelFrame.hx b/src/client/haxe/ru/m/tankz/view/LevelFrame.hx index 5c8993a..25f564d 100644 --- a/src/client/haxe/ru/m/tankz/view/LevelFrame.hx +++ b/src/client/haxe/ru/m/tankz/view/LevelFrame.hx @@ -1,10 +1,10 @@ package ru.m.tankz.view; -import haxework.view.data.DataView; -import haxework.view.form.ButtonView; -import haxework.view.form.LabelView; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; +import hw.view.data.DataView; +import hw.view.form.ButtonView; +import hw.view.form.LabelView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; import ru.m.tankz.bundle.IConfigBundle; import ru.m.tankz.bundle.ILevelBundle; import ru.m.tankz.config.Config; diff --git a/src/client/haxe/ru/m/tankz/view/LevelFrame.yaml b/src/client/haxe/ru/m/tankz/view/LevelFrame.yaml index 103019b..22c458b 100644 --- a/src/client/haxe/ru/m/tankz/view/LevelFrame.yaml +++ b/src/client/haxe/ru/m/tankz/view/LevelFrame.yaml @@ -1,29 +1,29 @@ --- views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView style: container views: - id: header - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.header - id: levels - $type: haxework.view.data.DataView + $type: hw.view.data.DataView geometry.width: 100% geometry.height: 100% overflow.y: scroll layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout rowSize: 10 margin: 5 factory: ~levelViewFactory +onItemSelect: ~onLevelSelect geometry.padding: 10 - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView style: panel layout.margin: 10 views: - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 100% - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.prev +onPress: ~switcher.change("menu") diff --git a/src/client/haxe/ru/m/tankz/view/MenuFrame.hx b/src/client/haxe/ru/m/tankz/view/MenuFrame.hx index e20b9d4..1a065a8 100644 --- a/src/client/haxe/ru/m/tankz/view/MenuFrame.hx +++ b/src/client/haxe/ru/m/tankz/view/MenuFrame.hx @@ -1,9 +1,9 @@ package ru.m.tankz.view; -import haxework.view.data.DataView; -import haxework.view.form.ButtonView; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; +import hw.view.data.DataView; +import hw.view.form.ButtonView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; import ru.m.tankz.bundle.ILevelBundle; import ru.m.tankz.game.GameInit; import ru.m.tankz.game.GameState; diff --git a/src/client/haxe/ru/m/tankz/view/MenuFrame.yaml b/src/client/haxe/ru/m/tankz/view/MenuFrame.yaml index cced200..607f2eb 100644 --- a/src/client/haxe/ru/m/tankz/view/MenuFrame.yaml +++ b/src/client/haxe/ru/m/tankz/view/MenuFrame.yaml @@ -1,62 +1,62 @@ --- views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView style: container overflow.y: scroll views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView geometry.width: 100% layout.margin: 10 layout.hAlign: center views: - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView text: $r:text:name style: font font.size: 100 geometry.margin.bottom: 30 - id: packs - $type: haxework.view.data.DataView + $type: hw.view.data.DataView geometry.width: 100% layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout rowSize: 2 margin: 10 factory: ~ru.m.tankz.view.common.PackView.factory +onDataSelect: ~startGame - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView style: line geometry.width: 250 geometry.margin: [0, 10] visible: false - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.menu +onPress: ~switcher.change('record') text: Records visible: false - id: network - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView +onPress: ~startNetwork() text: Network (alpha) visible: false - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView geometry.hAlign: right geometry.vAlign: top geometry.position: absolute geometry.margin: [0, 20, 20, 0] style: text.box text: $r:text:version - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView style: panel layout.margin: 10 views: - id: settings - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView style: button.settings +onPress: ~switcher.change('settings') - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 100% - id: update - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView style: button.active +onPress: ~appUpdate() visible: false diff --git a/src/client/haxe/ru/m/tankz/view/RecordFrame.hx b/src/client/haxe/ru/m/tankz/view/RecordFrame.hx index 7b0d132..b319314 100644 --- a/src/client/haxe/ru/m/tankz/view/RecordFrame.hx +++ b/src/client/haxe/ru/m/tankz/view/RecordFrame.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; -import haxework.view.list.VListView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; +import hw.view.list.VListView; import ru.m.tankz.game.record.GameRecord; import ru.m.tankz.storage.RecordStorage; diff --git a/src/client/haxe/ru/m/tankz/view/RecordFrame.yaml b/src/client/haxe/ru/m/tankz/view/RecordFrame.yaml index 637cd55..decea69 100644 --- a/src/client/haxe/ru/m/tankz/view/RecordFrame.yaml +++ b/src/client/haxe/ru/m/tankz/view/RecordFrame.yaml @@ -1,24 +1,24 @@ --- views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView style: container views: - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView style: text.header text: Records - id: data - $type: haxework.view.list.VListView + $type: hw.view.list.VListView factory: ~function() return new ru.m.tankz.view.common.RecordView() geometry.margin.top: 20 geometry.stretch: true scroll: - $type: haxework.view.list.VScrollBarView - - $type: haxework.view.group.HGroupView + $type: hw.view.list.VScrollBarView + - $type: hw.view.group.HGroupView style: panel layout.margin: 10 views: - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 100% - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.prev +onPress: ~switcher.change("menu") diff --git a/src/client/haxe/ru/m/tankz/view/ResultFrame.hx b/src/client/haxe/ru/m/tankz/view/ResultFrame.hx index 3b8e078..d885b73 100644 --- a/src/client/haxe/ru/m/tankz/view/ResultFrame.hx +++ b/src/client/haxe/ru/m/tankz/view/ResultFrame.hx @@ -1,10 +1,10 @@ package ru.m.tankz.view; -import haxework.view.data.DataView; -import haxework.view.form.ButtonView; -import haxework.view.form.LabelView; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; +import hw.view.data.DataView; +import hw.view.form.ButtonView; +import hw.view.form.LabelView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; import ru.m.tankz.bundle.ILevelBundle; import ru.m.tankz.game.GameEvent; import ru.m.tankz.game.GameInit; diff --git a/src/client/haxe/ru/m/tankz/view/ResultFrame.yaml b/src/client/haxe/ru/m/tankz/view/ResultFrame.yaml index 43650b5..db629c6 100644 --- a/src/client/haxe/ru/m/tankz/view/ResultFrame.yaml +++ b/src/client/haxe/ru/m/tankz/view/ResultFrame.yaml @@ -1,16 +1,16 @@ --- views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView style: container views: - id: level - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.header font.align: center - id: result - $type: haxework.view.data.DataView + $type: hw.view.data.DataView layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout factory: ~ru.m.tankz.view.result.ResultPlayerView.factory geometry.width: 100% geometry.height: 100% @@ -18,23 +18,23 @@ views: geometry.margin.top: 20 layout.margin: 5 layout.hAlign: center - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView style: panel layout.margin: 10 views: - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 50% - id: levels - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView text: Levels +onPress: ~levels() - id: restart - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView text: Restart +onPress: ~restart() - id: next - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView text: Next +onPress: ~next() - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 50% diff --git a/src/client/haxe/ru/m/tankz/view/SettingsFrame.hx b/src/client/haxe/ru/m/tankz/view/SettingsFrame.hx index a7b3252..7b57b07 100644 --- a/src/client/haxe/ru/m/tankz/view/SettingsFrame.hx +++ b/src/client/haxe/ru/m/tankz/view/SettingsFrame.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view; -import haxework.view.form.ToggleButtonView; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; +import hw.view.form.ToggleButtonView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; import ru.m.tankz.storage.SettingsStorage; @:template class SettingsFrame extends FrameView { diff --git a/src/client/haxe/ru/m/tankz/view/SettingsFrame.yaml b/src/client/haxe/ru/m/tankz/view/SettingsFrame.yaml index 3ef2495..360007f 100644 --- a/src/client/haxe/ru/m/tankz/view/SettingsFrame.yaml +++ b/src/client/haxe/ru/m/tankz/view/SettingsFrame.yaml @@ -1,20 +1,20 @@ --- views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView style: container views: - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView style: text.header text: Settings - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView geometry.stretch: true layout.hAlign: center overflow.y: scroll views: - - $type: haxework.view.group.GroupView + - $type: hw.view.group.GroupView geometry.width: 100% layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout vAlign: top margin: 20 views: @@ -24,29 +24,29 @@ views: - id: settings1 $type: ru.m.tankz.view.settings.SettingsEditor controlIndex: 1 - - $type: haxework.view.group.GroupView + - $type: hw.view.group.GroupView geometry.width: 100% geometry.margin.top: 20 layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout hAlign: center margin: 20 views: - id: fps - $type: haxework.view.form.ToggleButtonView + $type: hw.view.form.ToggleButtonView text: Display FPS +onPress: ~function(button) settings.displayFPS = !cast(button,ToggleButtonView).on - id: network - $type: haxework.view.form.ToggleButtonView + $type: hw.view.form.ToggleButtonView geometry.margin.top: 20 text: Enable Network +onPress: ~function(button) settings.enableNetwork = !cast(button,ToggleButtonView).on - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView style: panel layout.margin: 10 views: - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 100% - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.prev +onPress: ~switcher.change("menu") diff --git a/src/client/haxe/ru/m/tankz/view/StartFrame.hx b/src/client/haxe/ru/m/tankz/view/StartFrame.hx index d202a54..c59deab 100644 --- a/src/client/haxe/ru/m/tankz/view/StartFrame.hx +++ b/src/client/haxe/ru/m/tankz/view/StartFrame.hx @@ -1,10 +1,10 @@ package ru.m.tankz.view; -import haxework.view.data.DataView; -import haxework.view.form.ButtonView; -import haxework.view.form.LabelView; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; +import hw.view.data.DataView; +import hw.view.form.ButtonView; +import hw.view.form.LabelView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; import ru.m.tankz.config.Config; import ru.m.tankz.control.Controller; import ru.m.tankz.control.PlayerControl; diff --git a/src/client/haxe/ru/m/tankz/view/StartFrame.yaml b/src/client/haxe/ru/m/tankz/view/StartFrame.yaml index a62e7eb..0d88154 100644 --- a/src/client/haxe/ru/m/tankz/view/StartFrame.yaml +++ b/src/client/haxe/ru/m/tankz/view/StartFrame.yaml @@ -1,13 +1,13 @@ --- views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView style: container views: - id: header - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.header - id: teams - $type: haxework.view.data.DataView + $type: hw.view.data.DataView geometry.padding: 10 geometry.width: 100% geometry.height: 100% @@ -15,25 +15,25 @@ views: overflow.y: scroll factory: ~teamViewFactory layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout margin: 5 rowSize: 2 - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView style: panel layout.margin: 10 views: - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 50% - id: presets - $type: haxework.view.data.DataView + $type: hw.view.data.DataView factory: ~presetViewFactory +onDataSelect: ~onPresetSelect layout: - $type: haxework.view.layout.HorizontalLayout + $type: hw.view.layout.HorizontalLayout hAlign: center margin: 5 - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 50% - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.prev +onPress: ~switcher.change("level", start.level.packId) diff --git a/src/client/haxe/ru/m/tankz/view/common/NetworkStateView.hx b/src/client/haxe/ru/m/tankz/view/common/NetworkStateView.hx index bf25ba8..a0c720f 100644 --- a/src/client/haxe/ru/m/tankz/view/common/NetworkStateView.hx +++ b/src/client/haxe/ru/m/tankz/view/common/NetworkStateView.hx @@ -1,10 +1,10 @@ package ru.m.tankz.view.common; -import haxework.view.form.ButtonView; -import haxework.view.form.LabelView; -import haxework.view.group.HGroupView; -import haxework.view.skin.SpriteSkin; -import haxework.view.SpriteView; +import hw.view.form.ButtonView; +import hw.view.form.LabelView; +import hw.view.group.HGroupView; +import hw.view.skin.SpriteSkin; +import hw.view.SpriteView; import ru.m.tankz.network.NetworkManager; import ru.m.tankz.view.popup.LoginPopup; diff --git a/src/client/haxe/ru/m/tankz/view/common/NetworkStateView.yaml b/src/client/haxe/ru/m/tankz/view/common/NetworkStateView.yaml index e68c42a..ce2a670 100644 --- a/src/client/haxe/ru/m/tankz/view/common/NetworkStateView.yaml +++ b/src/client/haxe/ru/m/tankz/view/common/NetworkStateView.yaml @@ -3,31 +3,31 @@ geometry.padding: [5, 2] layout.vAlign: middle visible: false skin: - $type: haxework.view.skin.SpriteSkin + $type: hw.view.skin.SpriteSkin border.color: 0x95937D round: 10 views: - id: state - $type: haxework.view.SpriteView + $type: hw.view.SpriteView geometry.width: 20 geometry.height: 20 visible: false skin: - $type: haxework.view.skin.SpriteSkin + $type: hw.view.skin.SpriteSkin background.color: black border.color: 0xE7E0BB round: 20 - id: user - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView font.size: 14 - id: login - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView style: button.small text: login +onPress: ~login() visible: false - id: logout - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView style: button.small text: logout +onPress: ~logout() diff --git a/src/client/haxe/ru/m/tankz/view/common/PackView.hx b/src/client/haxe/ru/m/tankz/view/common/PackView.hx index 57791d7..c3897ce 100644 --- a/src/client/haxe/ru/m/tankz/view/common/PackView.hx +++ b/src/client/haxe/ru/m/tankz/view/common/PackView.hx @@ -1,7 +1,7 @@ package ru.m.tankz.view.common; -import haxework.view.form.LabelView; -import haxework.view.group.VGroupView; +import hw.view.form.LabelView; +import hw.view.group.VGroupView; import ru.m.tankz.bundle.ILevelBundle; import ru.m.tankz.storage.GameStorage; import ru.m.tankz.Type; diff --git a/src/client/haxe/ru/m/tankz/view/common/PackView.yaml b/src/client/haxe/ru/m/tankz/view/common/PackView.yaml index ef2bab5..feb206e 100644 --- a/src/client/haxe/ru/m/tankz/view/common/PackView.yaml +++ b/src/client/haxe/ru/m/tankz/view/common/PackView.yaml @@ -9,7 +9,7 @@ content.buttonMode: true content.mouseChildren: false views: - id: label - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView font.size: 22 - id: state - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView diff --git a/src/client/haxe/ru/m/tankz/view/common/RecordView.hx b/src/client/haxe/ru/m/tankz/view/common/RecordView.hx index 3860b2a..3c2441a 100644 --- a/src/client/haxe/ru/m/tankz/view/common/RecordView.hx +++ b/src/client/haxe/ru/m/tankz/view/common/RecordView.hx @@ -1,9 +1,9 @@ package ru.m.tankz.view.common; -import haxework.view.frame.FrameSwitcher; -import haxework.view.group.HGroupView; -import haxework.view.form.LabelView; -import haxework.view.list.ListView; +import hw.view.frame.FrameSwitcher; +import hw.view.group.HGroupView; +import hw.view.form.LabelView; +import hw.view.list.ListView; import ru.m.tankz.game.GameInit; import ru.m.tankz.game.record.GameRecord; import ru.m.tankz.storage.RecordStorage; diff --git a/src/client/haxe/ru/m/tankz/view/common/RecordView.yaml b/src/client/haxe/ru/m/tankz/view/common/RecordView.yaml index 02cc8cb..25d7bde 100644 --- a/src/client/haxe/ru/m/tankz/view/common/RecordView.yaml +++ b/src/client/haxe/ru/m/tankz/view/common/RecordView.yaml @@ -4,26 +4,26 @@ layout.margin: 5 layout.vAlign: middle views: - id: play - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView style: button.start.small +onPress: ~play() - id: date - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 200 - id: type - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 200 - id: level - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 100 - id: preset - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 100 - id: delete - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView style: button.close.small +onPress: ~delete() diff --git a/src/client/haxe/ru/m/tankz/view/common/SlotView.hx b/src/client/haxe/ru/m/tankz/view/common/SlotView.hx index a8cf3e0..52c992e 100644 --- a/src/client/haxe/ru/m/tankz/view/common/SlotView.hx +++ b/src/client/haxe/ru/m/tankz/view/common/SlotView.hx @@ -1,11 +1,11 @@ package ru.m.tankz.view.common; import openfl.Assets; -import haxework.view.ImageView; -import haxework.view.form.LabelView; -import haxework.view.form.SelectView; -import haxework.view.group.HGroupView; -import haxework.view.skin.SpriteSkin; +import hw.view.ImageView; +import hw.view.form.LabelView; +import hw.view.form.SelectView; +import hw.view.group.HGroupView; +import hw.view.skin.SpriteSkin; import ru.m.tankz.control.Controller; import ru.m.tankz.control.PlayerControl; diff --git a/src/client/haxe/ru/m/tankz/view/common/SlotView.yaml b/src/client/haxe/ru/m/tankz/view/common/SlotView.yaml index 2e0ba77..14bd978 100644 --- a/src/client/haxe/ru/m/tankz/view/common/SlotView.yaml +++ b/src/client/haxe/ru/m/tankz/view/common/SlotView.yaml @@ -4,14 +4,14 @@ layout.margin: 10 layout.vAlign: middle views: - id: tank - $type: haxework.view.ImageView + $type: hw.view.ImageView style: icon.tank - id: slot - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 150 - id: select - $type: haxework.view.form.SelectView + $type: hw.view.form.SelectView geometry.width: 150 labelBuilder: | ~function(controller) { diff --git a/src/client/haxe/ru/m/tankz/view/common/TankView.hx b/src/client/haxe/ru/m/tankz/view/common/TankView.hx index 9315041..249cba5 100644 --- a/src/client/haxe/ru/m/tankz/view/common/TankView.hx +++ b/src/client/haxe/ru/m/tankz/view/common/TankView.hx @@ -1,6 +1,6 @@ package ru.m.tankz.view.common; -import haxework.view.ImageView; +import hw.view.ImageView; import ru.m.tankz.render.RenderUtil; import ru.m.tankz.Type.TankInfo; diff --git a/src/client/haxe/ru/m/tankz/view/game/GameViewA.hx b/src/client/haxe/ru/m/tankz/view/game/GameViewA.hx index a422d73..9cffb94 100644 --- a/src/client/haxe/ru/m/tankz/view/game/GameViewA.hx +++ b/src/client/haxe/ru/m/tankz/view/game/GameViewA.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view.game; -import haxework.view.data.DataView; -import haxework.view.form.LabelView; -import haxework.view.group.HGroupView; +import hw.view.data.DataView; +import hw.view.form.LabelView; +import hw.view.group.HGroupView; import ru.m.tankz.config.Config; import ru.m.tankz.game.GameEvent; import ru.m.tankz.game.GameState; diff --git a/src/client/haxe/ru/m/tankz/view/game/GameViewA.yaml b/src/client/haxe/ru/m/tankz/view/game/GameViewA.yaml index 5762a78..64549b9 100644 --- a/src/client/haxe/ru/m/tankz/view/game/GameViewA.yaml +++ b/src/client/haxe/ru/m/tankz/view/game/GameViewA.yaml @@ -1,14 +1,14 @@ --- views: - id: left - $type: haxework.view.group.GroupView + $type: hw.view.group.GroupView layout.vAlign: middle geometry.height: 100% geometry.width: 50% - id: render $type: ru.m.tankz.render.Render - id: right - $type: haxework.view.group.VGroupView + $type: hw.view.group.VGroupView geometry.height: 100% geometry.width: 50% geometry.padding: 5 @@ -16,12 +16,12 @@ views: layout.margin: 5 views: - id: level - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 100% - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.height: 30% - id: teams - $type: haxework.view.data.DataView + $type: hw.view.data.DataView layout.margin: 3 factory: ~TeamView.viewFactory diff --git a/src/client/haxe/ru/m/tankz/view/game/GameViewB.hx b/src/client/haxe/ru/m/tankz/view/game/GameViewB.hx index 9391c96..c54edc5 100644 --- a/src/client/haxe/ru/m/tankz/view/game/GameViewB.hx +++ b/src/client/haxe/ru/m/tankz/view/game/GameViewB.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view.game; -import haxework.view.data.DataView; -import haxework.view.form.LabelView; -import haxework.view.group.VGroupView; +import hw.view.data.DataView; +import hw.view.form.LabelView; +import hw.view.group.VGroupView; import ru.m.tankz.config.Config; import ru.m.tankz.game.GameEvent; import ru.m.tankz.game.GameState; diff --git a/src/client/haxe/ru/m/tankz/view/game/GameViewB.yaml b/src/client/haxe/ru/m/tankz/view/game/GameViewB.yaml index 884c32c..b04c0c6 100644 --- a/src/client/haxe/ru/m/tankz/view/game/GameViewB.yaml +++ b/src/client/haxe/ru/m/tankz/view/game/GameViewB.yaml @@ -1,19 +1,19 @@ --- views: - id: top - $type: haxework.view.group.HGroupView + $type: hw.view.group.HGroupView layout.vAlign: middle geometry.width: 100% views: - id: level - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 100% - id: teams - $type: haxework.view.data.DataView + $type: hw.view.data.DataView layout: - $type: haxework.view.layout.HorizontalLayout + $type: hw.view.layout.HorizontalLayout margin: 5 factory: ~TeamView.viewFactory - id: render diff --git a/src/client/haxe/ru/m/tankz/view/game/GameViewContainer.hx b/src/client/haxe/ru/m/tankz/view/game/GameViewContainer.hx index a3226d9..17e22a3 100644 --- a/src/client/haxe/ru/m/tankz/view/game/GameViewContainer.hx +++ b/src/client/haxe/ru/m/tankz/view/game/GameViewContainer.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view.game; -import haxework.view.geometry.HAlign; -import haxework.view.geometry.VAlign; -import haxework.view.group.GroupView; +import hw.view.geometry.HAlign; +import hw.view.geometry.VAlign; +import hw.view.group.GroupView; class GameViewContainer extends GroupView { diff --git a/src/client/haxe/ru/m/tankz/view/game/IGameView.hx b/src/client/haxe/ru/m/tankz/view/game/IGameView.hx index c2d1cef..998ddc9 100644 --- a/src/client/haxe/ru/m/tankz/view/game/IGameView.hx +++ b/src/client/haxe/ru/m/tankz/view/game/IGameView.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view.game; -import haxework.view.data.DataView; -import haxework.view.form.LabelView; -import haxework.view.IView; +import hw.view.data.DataView; +import hw.view.form.LabelView; +import hw.view.IView; import ru.m.tankz.game.GameState; import ru.m.tankz.game.IGame; import ru.m.tankz.render.IRender; diff --git a/src/client/haxe/ru/m/tankz/view/game/PlayerView.hx b/src/client/haxe/ru/m/tankz/view/game/PlayerView.hx index 31a5d2b..e08edce 100644 --- a/src/client/haxe/ru/m/tankz/view/game/PlayerView.hx +++ b/src/client/haxe/ru/m/tankz/view/game/PlayerView.hx @@ -1,7 +1,7 @@ package ru.m.tankz.view.game; -import haxework.view.form.LabelView; -import haxework.view.group.VGroupView; +import hw.view.form.LabelView; +import hw.view.group.VGroupView; import ru.m.tankz.game.GameState; import ru.m.tankz.Type; import ru.m.tankz.view.common.TankView; diff --git a/src/client/haxe/ru/m/tankz/view/game/PlayerView.yaml b/src/client/haxe/ru/m/tankz/view/game/PlayerView.yaml index 1b00f62..a75c429 100644 --- a/src/client/haxe/ru/m/tankz/view/game/PlayerView.yaml +++ b/src/client/haxe/ru/m/tankz/view/game/PlayerView.yaml @@ -1,19 +1,19 @@ --- views: - id: title - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView visible: false - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView layout.margin: 5 layout.vAlign: middle views: - id: tank $type: ru.m.tankz.view.common.TankView - id: life - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 55 - id: score - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 100 diff --git a/src/client/haxe/ru/m/tankz/view/game/TeamView.hx b/src/client/haxe/ru/m/tankz/view/game/TeamView.hx index 372dbce..92a0d1f 100644 --- a/src/client/haxe/ru/m/tankz/view/game/TeamView.hx +++ b/src/client/haxe/ru/m/tankz/view/game/TeamView.hx @@ -1,6 +1,6 @@ package ru.m.tankz.view.game; -import haxework.view.data.DataView; +import hw.view.data.DataView; import ru.m.tankz.game.GameState; import ru.m.tankz.Type; diff --git a/src/client/haxe/ru/m/tankz/view/gamepad/GamepadSkin.hx b/src/client/haxe/ru/m/tankz/view/gamepad/GamepadSkin.hx index d7b2989..65e908c 100644 --- a/src/client/haxe/ru/m/tankz/view/gamepad/GamepadSkin.hx +++ b/src/client/haxe/ru/m/tankz/view/gamepad/GamepadSkin.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view.gamepad; import flash.display.Graphics; -import haxework.color.Color; -import haxework.view.skin.ISkin; +import hw.color.Color; +import hw.view.skin.ISkin; import ru.m.control.DeviceAction; @:style class GamepadSkin implements ISkin { diff --git a/src/client/haxe/ru/m/tankz/view/gamepad/GamepadView.hx b/src/client/haxe/ru/m/tankz/view/gamepad/GamepadView.hx index ca45388..0c79023 100644 --- a/src/client/haxe/ru/m/tankz/view/gamepad/GamepadView.hx +++ b/src/client/haxe/ru/m/tankz/view/gamepad/GamepadView.hx @@ -3,8 +3,8 @@ package ru.m.tankz.view.gamepad; import flash.display.Sprite; import flash.events.MouseEvent; import flash.events.TouchEvent; -import haxework.signal.Signal; -import haxework.view.SpriteView; +import hw.signal.Signal; +import hw.view.SpriteView; import ru.m.control.DeviceAction; import ru.m.control.DeviceType; import ru.m.control.IControlDevice; diff --git a/src/client/haxe/ru/m/tankz/view/gamepad/SmartActionAreaBuilder.hx b/src/client/haxe/ru/m/tankz/view/gamepad/SmartActionAreaBuilder.hx index e016377..8d44a71 100644 --- a/src/client/haxe/ru/m/tankz/view/gamepad/SmartActionAreaBuilder.hx +++ b/src/client/haxe/ru/m/tankz/view/gamepad/SmartActionAreaBuilder.hx @@ -1,6 +1,6 @@ package ru.m.tankz.view.gamepad; -import haxework.view.geometry.Box; +import hw.view.geometry.Box; import ru.m.control.DeviceAction; import ru.m.geom.Circle; import ru.m.geom.Direction; diff --git a/src/client/haxe/ru/m/tankz/view/network/RoomFrame.hx b/src/client/haxe/ru/m/tankz/view/network/RoomFrame.hx index 90608be..f8ed938 100644 --- a/src/client/haxe/ru/m/tankz/view/network/RoomFrame.hx +++ b/src/client/haxe/ru/m/tankz/view/network/RoomFrame.hx @@ -1,10 +1,10 @@ package ru.m.tankz.view.network; -import haxework.view.data.DataView; -import haxework.view.form.ButtonView; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; -import haxework.view.text.TextView; +import hw.view.data.DataView; +import hw.view.form.ButtonView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; +import hw.view.text.TextView; import ru.m.tankz.game.GameInit; import ru.m.tankz.network.NetworkManager; import ru.m.tankz.proto.room.RoomProto; diff --git a/src/client/haxe/ru/m/tankz/view/network/RoomFrame.yaml b/src/client/haxe/ru/m/tankz/view/network/RoomFrame.yaml index 34b3190..fc3ba16 100644 --- a/src/client/haxe/ru/m/tankz/view/network/RoomFrame.yaml +++ b/src/client/haxe/ru/m/tankz/view/network/RoomFrame.yaml @@ -1,40 +1,40 @@ --- geometry.stretch: true layout: - $type: haxework.view.layout.VerticalLayout + $type: hw.view.layout.VerticalLayout views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView style: container geometry.padding: 20 layout.margin: 10 views: - id: header - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.margin.bottom: 20 style: text.header text: Game Room - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView layout.margin: 10 views: - id: info - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.padding: [30, 10] style: text.box - id: start - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView text: Start +onPress: ~network.startGame() visible: false - id: leave - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView text: Leave +onPress: ~network.leaveGame() - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 100% geometry.height: 3 style: line - id: slots - $type: haxework.view.data.DataView + $type: hw.view.data.DataView layout.hAlign: center geometry.stretch: true overflow.y: scroll diff --git a/src/client/haxe/ru/m/tankz/view/network/RoomItemView.hx b/src/client/haxe/ru/m/tankz/view/network/RoomItemView.hx index 0c8ffa9..3bef406 100644 --- a/src/client/haxe/ru/m/tankz/view/network/RoomItemView.hx +++ b/src/client/haxe/ru/m/tankz/view/network/RoomItemView.hx @@ -2,10 +2,10 @@ package ru.m.tankz.view.network; import ru.m.tankz.network.NetworkManager; import ru.m.tankz.proto.room.RoomSlotProto; -import haxework.view.form.ButtonView; -import haxework.view.group.HGroupView; -import haxework.view.form.LabelView; -import haxework.view.list.ListView; +import hw.view.form.ButtonView; +import hw.view.group.HGroupView; +import hw.view.form.LabelView; +import hw.view.list.ListView; import ru.m.tankz.proto.room.RoomProto; @:template class RoomItemView extends HGroupView implements IListItemView { diff --git a/src/client/haxe/ru/m/tankz/view/network/RoomItemView.yaml b/src/client/haxe/ru/m/tankz/view/network/RoomItemView.yaml index 863de9e..8b75f38 100644 --- a/src/client/haxe/ru/m/tankz/view/network/RoomItemView.yaml +++ b/src/client/haxe/ru/m/tankz/view/network/RoomItemView.yaml @@ -3,18 +3,18 @@ layout.margin: 10 layout.hAlign: center views: - id: creator - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.width: 200 style: text.box - id: type - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.width: 200 style: text.box - id: users - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.width: 150 style: text.box - id: join - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView text: Join +onPress: ~join() diff --git a/src/client/haxe/ru/m/tankz/view/network/RoomListFrame.hx b/src/client/haxe/ru/m/tankz/view/network/RoomListFrame.hx index 0d39009..dadf4e6 100644 --- a/src/client/haxe/ru/m/tankz/view/network/RoomListFrame.hx +++ b/src/client/haxe/ru/m/tankz/view/network/RoomListFrame.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view.network; -import haxework.view.data.DataView; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; +import hw.view.data.DataView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; import ru.m.tankz.network.NetworkManager; import ru.m.tankz.proto.room.RoomProto; import ru.m.tankz.view.popup.CreateGamePopup; diff --git a/src/client/haxe/ru/m/tankz/view/network/RoomListFrame.yaml b/src/client/haxe/ru/m/tankz/view/network/RoomListFrame.yaml index b226164..c977caa 100644 --- a/src/client/haxe/ru/m/tankz/view/network/RoomListFrame.yaml +++ b/src/client/haxe/ru/m/tankz/view/network/RoomListFrame.yaml @@ -1,22 +1,22 @@ --- geometry.stretch: true layout: - $type: haxework.view.layout.VerticalLayout + $type: hw.view.layout.VerticalLayout views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView style: container geometry.padding: 20 views: - id: header - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.margin.bottom: 20 style: text.header text: Games List - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView text: Create +onPress: ~create() - id: games - $type: haxework.view.data.DataView + $type: hw.view.data.DataView geometry.stretch: true factory: ~ru.m.tankz.view.network.RoomItemView.factory geometry.margin: 10 diff --git a/src/client/haxe/ru/m/tankz/view/network/SlotItemView.hx b/src/client/haxe/ru/m/tankz/view/network/SlotItemView.hx index 188553c..d6c27e7 100644 --- a/src/client/haxe/ru/m/tankz/view/network/SlotItemView.hx +++ b/src/client/haxe/ru/m/tankz/view/network/SlotItemView.hx @@ -1,9 +1,9 @@ package ru.m.tankz.view.network; -import haxework.view.form.ButtonView; -import haxework.view.group.HGroupView; -import haxework.view.form.LabelView; -import haxework.view.list.ListView; +import hw.view.form.ButtonView; +import hw.view.group.HGroupView; +import hw.view.form.LabelView; +import hw.view.list.ListView; import ru.m.tankz.bundle.IConfigBundle; import ru.m.tankz.network.NetworkManager; import ru.m.tankz.proto.room.RoomSlotProto; diff --git a/src/client/haxe/ru/m/tankz/view/network/SlotItemView.yaml b/src/client/haxe/ru/m/tankz/view/network/SlotItemView.yaml index 2814233..c6dd70a 100644 --- a/src/client/haxe/ru/m/tankz/view/network/SlotItemView.yaml +++ b/src/client/haxe/ru/m/tankz/view/network/SlotItemView.yaml @@ -3,19 +3,19 @@ geometry.padding: 2 layout.margin: 10 views: - id: type - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 150 - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView layout.hAlign: center layout.vAlign: middle geometry.width: 300 views: - id: user - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.stretch: true style: text.box - id: select - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView text: Select +onPress: ~select() diff --git a/src/client/haxe/ru/m/tankz/view/popup/CreateGamePopup.hx b/src/client/haxe/ru/m/tankz/view/popup/CreateGamePopup.hx index 1583ac7..873557e 100644 --- a/src/client/haxe/ru/m/tankz/view/popup/CreateGamePopup.hx +++ b/src/client/haxe/ru/m/tankz/view/popup/CreateGamePopup.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view.popup; -import haxework.view.data.DataView; -import haxework.view.popup.PopupView; -import haxework.view.form.ToggleButtonView; +import hw.view.data.DataView; +import hw.view.popup.PopupView; +import hw.view.form.ToggleButtonView; import ru.m.tankz.bundle.IConfigBundle; import ru.m.tankz.bundle.ILevelBundle; import ru.m.tankz.config.Config; diff --git a/src/client/haxe/ru/m/tankz/view/popup/CreateGamePopup.yaml b/src/client/haxe/ru/m/tankz/view/popup/CreateGamePopup.yaml index 8d0dae7..ea39d65 100644 --- a/src/client/haxe/ru/m/tankz/view/popup/CreateGamePopup.yaml +++ b/src/client/haxe/ru/m/tankz/view/popup/CreateGamePopup.yaml @@ -2,42 +2,42 @@ layout.hAlign: center layout.vAlign: middle view: - $type: haxework.view.group.VGroupView + $type: hw.view.group.VGroupView layout.hAlign: center geometry.stretch: true geometry.margin: 10 style: window views: - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView geometry.width: 100% geometry.padding: 10 layout.vAlign: middle views: - id: name - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.width: 100% geometry.margin.left: 10 layout.hAlign: left style: text text: New game - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: window.close +onPress: ~reject('close') - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView geometry.stretch: true geometry.padding: [5, 20] layout.margin: 5 layout.hAlign: center views: - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView geometry.width: 100% style: text text: Type - id: type - $type: haxework.view.data.DataView + $type: hw.view.data.DataView geometry.width: 100% layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout margin: 10 factory: ~gameTypeViewFactory +onItemSelect: ~onGameTypeSelect @@ -45,27 +45,27 @@ view: - "classic" - "dota" - "death" - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView geometry.width: 100% style: text text: Level - id: level - $type: haxework.view.data.DataView + $type: hw.view.data.DataView geometry.width: 100% geometry.height: 100% overflow.y: scroll layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout rowSize: 10 margin: 5 factory: ~levelViewFactory +onItemSelect: ~onLevelSelect geometry.padding: 10 - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView layout.hAlign: center layout.margin: 5 style: panel views: - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView text: Create +onPress: ~submit() diff --git a/src/client/haxe/ru/m/tankz/view/popup/LoginPopup.hx b/src/client/haxe/ru/m/tankz/view/popup/LoginPopup.hx index d840aa0..0db094a 100644 --- a/src/client/haxe/ru/m/tankz/view/popup/LoginPopup.hx +++ b/src/client/haxe/ru/m/tankz/view/popup/LoginPopup.hx @@ -1,9 +1,9 @@ package ru.m.tankz.view.popup; -import haxework.log.BaseLogger.LoggerUtil; -import haxework.view.form.InputView; -import haxework.view.popup.PopupView; -import haxework.view.text.TextView; +import hw.log.BaseLogger.LoggerUtil; +import hw.view.form.InputView; +import hw.view.popup.PopupView; +import hw.view.text.TextView; import ru.m.tankz.network.NetworkManager; @:singleton @:template class LoginPopup extends PopupView { diff --git a/src/client/haxe/ru/m/tankz/view/popup/LoginPopup.yaml b/src/client/haxe/ru/m/tankz/view/popup/LoginPopup.yaml index 00a79a0..09a4ff5 100644 --- a/src/client/haxe/ru/m/tankz/view/popup/LoginPopup.yaml +++ b/src/client/haxe/ru/m/tankz/view/popup/LoginPopup.yaml @@ -2,62 +2,62 @@ layout.hAlign: center layout.vAlign: middle view: - $type: haxework.view.group.VGroupView + $type: hw.view.group.VGroupView layout.hAlign: center geometry.width: 400 # geometry.height: 400 style: window views: - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView geometry.width: 100% geometry.padding: 10 layout.vAlign: middle views: - id: name - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.width: 100% geometry.margin.left: 10 layout.hAlign: left style: text text: Login - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: window.close +onPress: ~reject('close') - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView geometry.width: 100% # geometry.stretch: true geometry.padding: 20 layout.margin: 5 views: - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView geometry.width: 100% style: text text: Username - id: username - $type: haxework.view.form.InputView + $type: hw.view.form.InputView geometry.width: 100% style: text.box - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView geometry.width: 100% style: text text: Password visible: false - id: password - $type: haxework.view.form.InputView + $type: hw.view.form.InputView textField.displayAsPassword: true geometry.width: 100% style: text.box visible: false - id: error - $type: haxework.view.text.TextView + $type: hw.view.text.TextView geometry.width: 100% style: text fill: false - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView layout.hAlign: center layout.margin: 5 style: panel views: - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView text: Submit +onPress: ~submit() diff --git a/src/client/haxe/ru/m/tankz/view/popup/PausePopup.hx b/src/client/haxe/ru/m/tankz/view/popup/PausePopup.hx index ec56742..d08d7a0 100644 --- a/src/client/haxe/ru/m/tankz/view/popup/PausePopup.hx +++ b/src/client/haxe/ru/m/tankz/view/popup/PausePopup.hx @@ -1,6 +1,6 @@ package ru.m.tankz.view.popup; -import haxework.view.popup.PopupView; +import hw.view.popup.PopupView; enum Action { RESUME; diff --git a/src/client/haxe/ru/m/tankz/view/popup/PausePopup.yaml b/src/client/haxe/ru/m/tankz/view/popup/PausePopup.yaml index c694645..6731829 100644 --- a/src/client/haxe/ru/m/tankz/view/popup/PausePopup.yaml +++ b/src/client/haxe/ru/m/tankz/view/popup/PausePopup.yaml @@ -2,38 +2,38 @@ layout.hAlign: center layout.vAlign: middle view: - $type: haxework.view.group.VGroupView + $type: hw.view.group.VGroupView layout.hAlign: center geometry.width: 400 # geometry.height: 400 style: window views: - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView geometry.width: 100% geometry.padding: 10 layout.vAlign: middle views: - id: name - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.width: 100% geometry.margin.left: 10 layout.hAlign: left style: text text: Pause - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: window.close +onPress: ~reject('close') - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView geometry.width: 100% # geometry.stretch: true geometry.padding: 20 layout.margin: 5 views: - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView geometry.width: 100% text: Resume +onPress: ~close(RESUME) - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView geometry.width: 100% text: Exit +onPress: ~close(EXIT) diff --git a/src/client/haxe/ru/m/tankz/view/result/FragView.hx b/src/client/haxe/ru/m/tankz/view/result/FragView.hx index a7546ed..00a4b58 100644 --- a/src/client/haxe/ru/m/tankz/view/result/FragView.hx +++ b/src/client/haxe/ru/m/tankz/view/result/FragView.hx @@ -1,7 +1,7 @@ package ru.m.tankz.view.result; -import haxework.view.form.LabelView; -import haxework.view.group.HGroupView; +import hw.view.form.LabelView; +import hw.view.group.HGroupView; import ru.m.tankz.game.GameState; import ru.m.tankz.render.RenderUtil; import ru.m.tankz.view.common.TankView; diff --git a/src/client/haxe/ru/m/tankz/view/result/FragView.yaml b/src/client/haxe/ru/m/tankz/view/result/FragView.yaml index 58556d8..4fc8426 100644 --- a/src/client/haxe/ru/m/tankz/view/result/FragView.yaml +++ b/src/client/haxe/ru/m/tankz/view/result/FragView.yaml @@ -5,10 +5,10 @@ views: - id: tank $type: ru.m.tankz.view.common.TankView - id: title - $type: haxework.view.form.LabelView - - $type: haxework.view.SpriteView + $type: hw.view.form.LabelView + - $type: hw.view.SpriteView geometry.width: 100% - id: score - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 100 diff --git a/src/client/haxe/ru/m/tankz/view/result/ResultPlayerView.hx b/src/client/haxe/ru/m/tankz/view/result/ResultPlayerView.hx index 37f2501..f4bd8a2 100644 --- a/src/client/haxe/ru/m/tankz/view/result/ResultPlayerView.hx +++ b/src/client/haxe/ru/m/tankz/view/result/ResultPlayerView.hx @@ -1,9 +1,9 @@ package ru.m.tankz.view.result; -import haxework.view.data.DataView; -import haxework.view.form.LabelView; -import haxework.view.group.HGroupView; -import haxework.view.group.VGroupView; +import hw.view.data.DataView; +import hw.view.form.LabelView; +import hw.view.group.HGroupView; +import hw.view.group.VGroupView; import ru.m.tankz.game.GameState; import ru.m.tankz.view.common.TankView; diff --git a/src/client/haxe/ru/m/tankz/view/result/ResultPlayerView.yaml b/src/client/haxe/ru/m/tankz/view/result/ResultPlayerView.yaml index 2ec2657..719f5ba 100644 --- a/src/client/haxe/ru/m/tankz/view/result/ResultPlayerView.yaml +++ b/src/client/haxe/ru/m/tankz/view/result/ResultPlayerView.yaml @@ -7,24 +7,24 @@ geometry.height: 100% layout.hAlign: center views: - id: player - $type: haxework.view.group.HGroupView + $type: hw.view.group.HGroupView geometry.width: 100% layout.vAlign: middle views: - id: tank $type: ru.m.tankz.view.common.TankView - id: title - $type: haxework.view.form.LabelView - - $type: haxework.view.SpriteView + $type: hw.view.form.LabelView + - $type: hw.view.SpriteView geometry.width: 100% - id: score - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text.box geometry.width: 100 - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView style: line - id: frags - $type: haxework.view.data.DataView + $type: hw.view.data.DataView factory: ~ru.m.tankz.view.result.FragView.factory geometry.stretch: true overflow.y: scroll diff --git a/src/client/haxe/ru/m/tankz/view/settings/ActionView.hx b/src/client/haxe/ru/m/tankz/view/settings/ActionView.hx index f4c4fc1..b3c4c08 100755 --- a/src/client/haxe/ru/m/tankz/view/settings/ActionView.hx +++ b/src/client/haxe/ru/m/tankz/view/settings/ActionView.hx @@ -1,8 +1,8 @@ package ru.m.tankz.view.settings; -import haxework.view.form.LabelView; -import haxework.view.group.HGroupView; -import haxework.view.list.ListView; +import hw.view.form.LabelView; +import hw.view.group.HGroupView; +import hw.view.list.ListView; import ru.m.tankz.control.Binding; import ru.m.tankz.control.Control; diff --git a/src/client/haxe/ru/m/tankz/view/settings/ActionView.yaml b/src/client/haxe/ru/m/tankz/view/settings/ActionView.yaml index ddfe9d5..0bd706b 100644 --- a/src/client/haxe/ru/m/tankz/view/settings/ActionView.yaml +++ b/src/client/haxe/ru/m/tankz/view/settings/ActionView.yaml @@ -2,10 +2,10 @@ layout.margin: 5 views: - id: action - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.width: 180 style: text.box - id: key - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView geometry.width: 250 style: text.box diff --git a/src/client/haxe/ru/m/tankz/view/settings/SettingsEditor.hx b/src/client/haxe/ru/m/tankz/view/settings/SettingsEditor.hx index b600f6d..0a848a1 100644 --- a/src/client/haxe/ru/m/tankz/view/settings/SettingsEditor.hx +++ b/src/client/haxe/ru/m/tankz/view/settings/SettingsEditor.hx @@ -1,9 +1,9 @@ package ru.m.tankz.view.settings; -import haxework.view.data.DataView; -import haxework.view.form.LabelView; -import haxework.view.group.GroupView; -import haxework.view.group.VGroupView; +import hw.view.data.DataView; +import hw.view.form.LabelView; +import hw.view.group.GroupView; +import hw.view.group.VGroupView; import promhx.Deferred; import promhx.Promise; import ru.m.control.DeviceAction; diff --git a/src/client/haxe/ru/m/tankz/view/settings/SettingsEditor.yaml b/src/client/haxe/ru/m/tankz/view/settings/SettingsEditor.yaml index 941e8d5..433b125 100644 --- a/src/client/haxe/ru/m/tankz/view/settings/SettingsEditor.yaml +++ b/src/client/haxe/ru/m/tankz/view/settings/SettingsEditor.yaml @@ -3,28 +3,28 @@ layout.hAlign: center geometry.width: 400 views: - id: label - $type: haxework.view.form.LabelView + $type: hw.view.form.LabelView style: text - id: panel - $type: haxework.view.group.GroupView + $type: hw.view.group.GroupView layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout margin: 10 geometry.width: 100% views: - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView +onPress: ~screen() text: Screen - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView +onPress: ~change() text: Change - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView +onPress: ~default_() text: Default - id: list - $type: haxework.view.data.DataView + $type: hw.view.data.DataView layout: - $type: haxework.view.layout.VerticalLayout + $type: hw.view.layout.VerticalLayout margin: 5 factory: ~viewFactory +onItemSelect: ~onItemSelect diff --git a/src/client/haxe/ru/m/update/Updater.hx b/src/client/haxe/ru/m/update/Updater.hx index 4753101..2a37f87 100644 --- a/src/client/haxe/ru/m/update/Updater.hx +++ b/src/client/haxe/ru/m/update/Updater.hx @@ -1,6 +1,6 @@ package ru.m.update; -import haxework.net.JsonLoader; +import hw.net.JsonLoader; import openfl.Lib; import openfl.net.URLRequest; import promhx.Promise; diff --git a/src/common/haxe/ru/m/Timer.hx b/src/common/haxe/ru/m/Timer.hx index c14cf13..7c58c38 100644 --- a/src/common/haxe/ru/m/Timer.hx +++ b/src/common/haxe/ru/m/Timer.hx @@ -20,7 +20,7 @@ class Timer { try { run(); } catch (error:Dynamic) { - trace(haxework.log.BaseLogger.LoggerUtil.printError(error)); + trace(hw.log.BaseLogger.LoggerUtil.printError(error)); } } }); diff --git a/src/common/haxe/ru/m/connect/BaseConnection.hx b/src/common/haxe/ru/m/connect/BaseConnection.hx index 0990ec1..f0280ba 100755 --- a/src/common/haxe/ru/m/connect/BaseConnection.hx +++ b/src/common/haxe/ru/m/connect/BaseConnection.hx @@ -1,6 +1,6 @@ package ru.m.connect; -import haxework.signal.Signal; +import hw.signal.Signal; import haxe.io.Bytes; import promhx.Deferred; import promhx.Promise; diff --git a/src/common/haxe/ru/m/connect/IConnection.hx b/src/common/haxe/ru/m/connect/IConnection.hx index 1ccfe21..8f77ff2 100755 --- a/src/common/haxe/ru/m/connect/IConnection.hx +++ b/src/common/haxe/ru/m/connect/IConnection.hx @@ -1,6 +1,6 @@ package ru.m.connect; -import haxework.signal.Signal; +import hw.signal.Signal; import haxe.io.Bytes; import promhx.Promise; import protohx.Message; diff --git a/src/common/haxe/ru/m/tankz/Type.hx b/src/common/haxe/ru/m/tankz/Type.hx index 1bdae1f..8146605 100644 --- a/src/common/haxe/ru/m/tankz/Type.hx +++ b/src/common/haxe/ru/m/tankz/Type.hx @@ -1,6 +1,6 @@ package ru.m.tankz; -import haxework.color.Color; +import hw.color.Color; typedef GameType = String; diff --git a/src/common/haxe/ru/m/tankz/bundle/CachedLevelBundle.hx b/src/common/haxe/ru/m/tankz/bundle/CachedLevelBundle.hx index d470b26..daeddc2 100644 --- a/src/common/haxe/ru/m/tankz/bundle/CachedLevelBundle.hx +++ b/src/common/haxe/ru/m/tankz/bundle/CachedLevelBundle.hx @@ -1,6 +1,6 @@ package ru.m.tankz.bundle; -import haxework.storage.IStorage; +import hw.storage.IStorage; import ru.m.tankz.bundle.ILevelBundle; import ru.m.tankz.config.Config; import ru.m.tankz.Type; diff --git a/src/common/haxe/ru/m/tankz/config/Config.hx b/src/common/haxe/ru/m/tankz/config/Config.hx index 21e6160..e7e71a3 100644 --- a/src/common/haxe/ru/m/tankz/config/Config.hx +++ b/src/common/haxe/ru/m/tankz/config/Config.hx @@ -1,6 +1,6 @@ package ru.m.tankz.config; -import haxework.color.Color; +import hw.color.Color; import ru.m.tankz.control.Controller; import ru.m.tankz.Type; diff --git a/src/common/haxe/ru/m/tankz/control/PlayerControl.hx b/src/common/haxe/ru/m/tankz/control/PlayerControl.hx index 5d699dd..f8d8654 100644 --- a/src/common/haxe/ru/m/tankz/control/PlayerControl.hx +++ b/src/common/haxe/ru/m/tankz/control/PlayerControl.hx @@ -1,6 +1,6 @@ package ru.m.tankz.control; -import haxework.color.Color; +import hw.color.Color; import ru.m.tankz.Type; typedef PlayerControl = { diff --git a/src/common/haxe/ru/m/tankz/core/Bullet.hx b/src/common/haxe/ru/m/tankz/core/Bullet.hx index 626202a..f68b7d4 100644 --- a/src/common/haxe/ru/m/tankz/core/Bullet.hx +++ b/src/common/haxe/ru/m/tankz/core/Bullet.hx @@ -1,6 +1,6 @@ package ru.m.tankz.core; -import haxework.color.Color; +import hw.color.Color; import ru.m.geom.Direction; import ru.m.geom.Rectangle; import ru.m.tankz.config.Config; diff --git a/src/common/haxe/ru/m/tankz/core/Eagle.hx b/src/common/haxe/ru/m/tankz/core/Eagle.hx index 9b8f6ef..b63d7be 100644 --- a/src/common/haxe/ru/m/tankz/core/Eagle.hx +++ b/src/common/haxe/ru/m/tankz/core/Eagle.hx @@ -1,6 +1,6 @@ package ru.m.tankz.core; -import haxework.color.Color; +import hw.color.Color; import ru.m.geom.Rectangle; import ru.m.tankz.config.Config; import ru.m.tankz.Type; diff --git a/src/common/haxe/ru/m/tankz/core/Tank.hx b/src/common/haxe/ru/m/tankz/core/Tank.hx index 67ab59b..ba9f2b6 100755 --- a/src/common/haxe/ru/m/tankz/core/Tank.hx +++ b/src/common/haxe/ru/m/tankz/core/Tank.hx @@ -1,6 +1,6 @@ package ru.m.tankz.core; -import haxework.color.Color; +import hw.color.Color; import ru.m.geom.Direction; import ru.m.geom.Rectangle; import ru.m.tankz.config.Config; diff --git a/src/common/haxe/ru/m/tankz/engine/IEngine.hx b/src/common/haxe/ru/m/tankz/engine/IEngine.hx index b5ef596..14b4214 100644 --- a/src/common/haxe/ru/m/tankz/engine/IEngine.hx +++ b/src/common/haxe/ru/m/tankz/engine/IEngine.hx @@ -1,6 +1,6 @@ package ru.m.tankz.engine; -import haxework.signal.Signal; +import hw.signal.Signal; import ru.m.geom.Direction; import ru.m.tankz.config.Config; import ru.m.tankz.core.Entity; diff --git a/src/common/haxe/ru/m/tankz/game/EntityBuilder.hx b/src/common/haxe/ru/m/tankz/game/EntityBuilder.hx index 990ddce..b4068a9 100644 --- a/src/common/haxe/ru/m/tankz/game/EntityBuilder.hx +++ b/src/common/haxe/ru/m/tankz/game/EntityBuilder.hx @@ -1,6 +1,6 @@ package ru.m.tankz.game; -import haxework.color.Color; +import hw.color.Color; import ru.m.geom.Direction; import ru.m.geom.Point; import ru.m.geom.Rectangle; diff --git a/src/common/haxe/ru/m/tankz/game/GameEvent.hx b/src/common/haxe/ru/m/tankz/game/GameEvent.hx index cd3150f..676cc31 100644 --- a/src/common/haxe/ru/m/tankz/game/GameEvent.hx +++ b/src/common/haxe/ru/m/tankz/game/GameEvent.hx @@ -1,6 +1,6 @@ package ru.m.tankz.game; -import haxework.color.Color; +import hw.color.Color; import ru.m.geom.Position; import ru.m.geom.Rectangle; import ru.m.tankz.config.Config; diff --git a/src/common/haxe/ru/m/tankz/game/GameState.hx b/src/common/haxe/ru/m/tankz/game/GameState.hx index dadcad2..9d63279 100644 --- a/src/common/haxe/ru/m/tankz/game/GameState.hx +++ b/src/common/haxe/ru/m/tankz/game/GameState.hx @@ -1,6 +1,6 @@ package ru.m.tankz.game; -import haxework.color.Color; +import hw.color.Color; import ru.m.tankz.bundle.IConfigBundle; import ru.m.tankz.config.Config; import ru.m.tankz.control.Controller; diff --git a/src/common/haxe/ru/m/tankz/game/IGame.hx b/src/common/haxe/ru/m/tankz/game/IGame.hx index 3e9f076..49387af 100644 --- a/src/common/haxe/ru/m/tankz/game/IGame.hx +++ b/src/common/haxe/ru/m/tankz/game/IGame.hx @@ -1,7 +1,7 @@ package ru.m.tankz.game; import ru.m.tankz.engine.ITicker; -import haxework.signal.Signal; +import hw.signal.Signal; import ru.m.tankz.config.Config; import ru.m.tankz.control.Control; import ru.m.tankz.control.IControlFactory; diff --git a/src/editor/haxe/ru/m/tankz/editor/ColorView.hx b/src/editor/haxe/ru/m/tankz/editor/ColorView.hx index 7a5b863..cfcc9fd 100644 --- a/src/editor/haxe/ru/m/tankz/editor/ColorView.hx +++ b/src/editor/haxe/ru/m/tankz/editor/ColorView.hx @@ -1,9 +1,9 @@ package ru.m.tankz.editor; import flash.events.MouseEvent; -import haxework.color.Color; -import haxework.view.ImageView; -import haxework.signal.Signal; +import hw.color.Color; +import hw.view.ImageView; +import hw.signal.Signal; import openfl.Assets; class ColorView extends ImageView { diff --git a/src/editor/haxe/ru/m/tankz/editor/Editor.hx b/src/editor/haxe/ru/m/tankz/editor/Editor.hx index d1310db..ab8d6d1 100644 --- a/src/editor/haxe/ru/m/tankz/editor/Editor.hx +++ b/src/editor/haxe/ru/m/tankz/editor/Editor.hx @@ -1,11 +1,11 @@ package ru.m.tankz.editor; -import haxework.net.manage.LoaderManager; -import haxework.resources.IResources; -import haxework.view.Root; -import haxework.view.frame.FrameSwitcher; -import haxework.view.popup.PopupManager; -import haxework.view.theme.ITheme; +import hw.net.manage.LoaderManager; +import hw.resources.IResources; +import hw.view.Root; +import hw.view.frame.FrameSwitcher; +import hw.view.popup.PopupManager; +import hw.view.theme.ITheme; import ru.m.animate.AnimateManager; import ru.m.tankz.bundle.CachedLevelBundle; import ru.m.tankz.bundle.ClientLevelSource; @@ -26,12 +26,12 @@ class Editor { @:provide static var levelBundle:ILevelBundle; public static function main() { - L.push(new haxework.log.TraceLogger()); + L.push(new hw.log.TraceLogger()); #if flash - L.push(new haxework.log.JSLogger()); + L.push(new hw.log.JSLogger()); #end #if debug - //L.push(new haxework.log.SocketLogger()); + //L.push(new hw.log.SocketLogger()); #end // ToDo: fix @:provide macro PopupManager; diff --git a/src/editor/haxe/ru/m/tankz/editor/EditorStorage.hx b/src/editor/haxe/ru/m/tankz/editor/EditorStorage.hx index 28b3f58..9924b0c 100644 --- a/src/editor/haxe/ru/m/tankz/editor/EditorStorage.hx +++ b/src/editor/haxe/ru/m/tankz/editor/EditorStorage.hx @@ -1,7 +1,7 @@ package ru.m.tankz.editor; import haxe.DynamicAccess; -import haxework.storage.SharedObjectStorage; +import hw.storage.SharedObjectStorage; import ru.m.tankz.config.Config; @:provide class EditorStorage extends SharedObjectStorage { diff --git a/src/editor/haxe/ru/m/tankz/editor/view/EditorView.hx b/src/editor/haxe/ru/m/tankz/editor/view/EditorView.hx index acaf576..46f4c53 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/EditorView.hx +++ b/src/editor/haxe/ru/m/tankz/editor/view/EditorView.hx @@ -1,7 +1,7 @@ package ru.m.tankz.editor.view; -import haxework.view.frame.FrameSwitcher; -import haxework.view.group.VGroupView; +import hw.view.frame.FrameSwitcher; +import hw.view.group.VGroupView; @:template class EditorView extends VGroupView { @:view public var switcher(default, null):FrameSwitcher; diff --git a/src/editor/haxe/ru/m/tankz/editor/view/EditorView.yaml b/src/editor/haxe/ru/m/tankz/editor/view/EditorView.yaml index 79b4b6f..757151d 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/EditorView.yaml +++ b/src/editor/haxe/ru/m/tankz/editor/view/EditorView.yaml @@ -1,6 +1,6 @@ --- views: - - $type: haxework.view.frame.FrameSwitcher + - $type: hw.view.frame.FrameSwitcher id: switcher geometry.stretch: true style: dark diff --git a/src/editor/haxe/ru/m/tankz/editor/view/PackFrame.hx b/src/editor/haxe/ru/m/tankz/editor/view/PackFrame.hx index 99952da..09ef098 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/PackFrame.hx +++ b/src/editor/haxe/ru/m/tankz/editor/view/PackFrame.hx @@ -1,12 +1,12 @@ package ru.m.tankz.editor.view; import ru.m.tankz.util.LevelUtil; -import haxework.view.data.DataView; -import haxework.view.form.InputView; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; -import haxework.view.list.LabelListItem; -import haxework.view.list.ListView; +import hw.view.data.DataView; +import hw.view.form.InputView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; +import hw.view.list.LabelListItem; +import hw.view.list.ListView; import ru.m.tankz.bundle.IConfigBundle; import ru.m.tankz.config.Config; import ru.m.tankz.editor.view.map.BrickView; diff --git a/src/editor/haxe/ru/m/tankz/editor/view/PackFrame.yaml b/src/editor/haxe/ru/m/tankz/editor/view/PackFrame.yaml index 4530aa3..86f4dbe 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/PackFrame.yaml +++ b/src/editor/haxe/ru/m/tankz/editor/view/PackFrame.yaml @@ -1,77 +1,77 @@ --- views: - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView geometry.stretch: true views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView geometry.height: 100% views: - id: levels - $type: haxework.view.list.VListView + $type: hw.view.list.VListView geometry.width: 200 geometry.height: 100% factory: ~levelViewFactory +onItemSelect: ~onLevelSelect scroll: - $type: haxework.view.list.VScrollBarView - - $type: haxework.view.group.VGroupView + $type: hw.view.list.VScrollBarView + - $type: hw.view.group.VGroupView geometry.stretch: true views: - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView style: panel views: - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView text: "Name:" - id: levelName - $type: haxework.view.form.InputView + $type: hw.view.form.InputView geometry.width: 300 geometry.height: 26 text: "" - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView text: "Size:" geometry.margin.left: 20 - id: width - $type: haxework.view.form.InputView + $type: hw.view.form.InputView geometry.width: 50 geometry.height: 26 - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView text: "x" - id: height - $type: haxework.view.form.InputView + $type: hw.view.form.InputView geometry.width: 50 geometry.height: 26 - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.start.small +onPress: ~applySize() - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.close.small +onPress: ~resetSize() - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView geometry.stretch: true geometry.margin.top: 10 layout.margin: 5 views: - id: spawnPointList - $type: haxework.view.data.DataView + $type: hw.view.data.DataView style: light geometry.padding: 3 layout: - $type: haxework.view.layout.VerticalLayout + $type: hw.view.layout.VerticalLayout hAlign: center margin: 5 factory: ~ru.m.tankz.editor.view.map.SpawnPointView.factory +onDataSelect: ~selectSpawnPoint - id: brickList - $type: haxework.view.data.DataView + $type: hw.view.data.DataView style: light geometry.padding: 3 layout: - $type: haxework.view.layout.VerticalLayout + $type: hw.view.layout.VerticalLayout hAlign: center margin: 5 factory: ~ru.m.tankz.editor.view.map.BrickView.factory +onDataSelect: ~selectBrick - - $type: haxework.view.group.GroupView + - $type: hw.view.group.GroupView geometry.stretch: true overflow.x: crop overflow.y: crop @@ -80,21 +80,21 @@ views: views: - id: mapView $type: ru.m.tankz.editor.view.map.MapEditView - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView style: panel layout.margin: 10 views: - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView text: Add +onPress: ~addLevel() - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView text: Remove +onPress: ~removeLevel() - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 100% - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView text: Save +onPress: ~save() - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.prev +onPress: ~switcher.change("pack_list") diff --git a/src/editor/haxe/ru/m/tankz/editor/view/PackListFrame.hx b/src/editor/haxe/ru/m/tankz/editor/view/PackListFrame.hx index 978af77..87c2ddd 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/PackListFrame.hx +++ b/src/editor/haxe/ru/m/tankz/editor/view/PackListFrame.hx @@ -1,8 +1,8 @@ package ru.m.tankz.editor.view; -import haxework.view.data.DataView; -import haxework.view.frame.FrameSwitcher; -import haxework.view.frame.FrameView; +import hw.view.data.DataView; +import hw.view.frame.FrameSwitcher; +import hw.view.frame.FrameView; import ru.m.tankz.bundle.ILevelBundle; import ru.m.tankz.config.Config; import ru.m.tankz.editor.FileUtil; diff --git a/src/editor/haxe/ru/m/tankz/editor/view/PackListFrame.yaml b/src/editor/haxe/ru/m/tankz/editor/view/PackListFrame.yaml index 40cdc47..2a3f144 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/PackListFrame.yaml +++ b/src/editor/haxe/ru/m/tankz/editor/view/PackListFrame.yaml @@ -1,28 +1,28 @@ --- views: - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView style: container layout.margin: 10 views: - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView text: New +onPress: ~create() - id: packs - $type: haxework.view.data.ActionDataView + $type: hw.view.data.ActionDataView layout: - $type: haxework.view.layout.VerticalLayout + $type: hw.view.layout.VerticalLayout margin: 5 factory: ~ru.m.tankz.editor.view.PackView.factory +onDataAction: ~onPackAction - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView text: Open +onPress: ~open() - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView style: panel layout.margin: 10 views: - - $type: haxework.view.SpriteView + - $type: hw.view.SpriteView geometry.width: 100% - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.prev +onPress: ~switcher.change("pack_list") diff --git a/src/editor/haxe/ru/m/tankz/editor/view/PackView.hx b/src/editor/haxe/ru/m/tankz/editor/view/PackView.hx index 2b37834..ae2bb55 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/PackView.hx +++ b/src/editor/haxe/ru/m/tankz/editor/view/PackView.hx @@ -1,10 +1,10 @@ package ru.m.tankz.editor.view; -import haxework.signal.Signal; -import haxework.view.data.DataView; -import haxework.view.form.ButtonView; -import haxework.view.group.HGroupView; -import haxework.view.list.ListView; +import hw.signal.Signal; +import hw.view.data.DataView; +import hw.view.form.ButtonView; +import hw.view.group.HGroupView; +import hw.view.list.ListView; import ru.m.tankz.config.Config; using ru.m.tankz.view.ViewUtil; diff --git a/src/editor/haxe/ru/m/tankz/editor/view/PackView.yaml b/src/editor/haxe/ru/m/tankz/editor/view/PackView.yaml index 54c52e3..2174a84 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/PackView.yaml +++ b/src/editor/haxe/ru/m/tankz/editor/view/PackView.yaml @@ -1,14 +1,14 @@ --- layout.margin: 5 views: - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.prev +onPress: ~export() - id: label - $type: haxework.view.form.ButtonView + $type: hw.view.form.ButtonView geometry.width: 250 +onPress: ~edit() - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: button.close +onPress: ~delete() diff --git a/src/editor/haxe/ru/m/tankz/editor/view/TankFrame.hx b/src/editor/haxe/ru/m/tankz/editor/view/TankFrame.hx index f5d84fd..c2dc5e6 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/TankFrame.hx +++ b/src/editor/haxe/ru/m/tankz/editor/view/TankFrame.hx @@ -1,9 +1,9 @@ package ru.m.tankz.editor.view; -import haxework.color.Color; -import haxework.view.form.InputView; -import haxework.view.frame.FrameView; -import haxework.view.group.IGroupView; +import hw.color.Color; +import hw.view.form.InputView; +import hw.view.frame.FrameView; +import hw.view.group.IGroupView; import ru.m.tankz.editor.view.tank.TankView; @:template class TankFrame extends FrameView { diff --git a/src/editor/haxe/ru/m/tankz/editor/view/TankFrame.yaml b/src/editor/haxe/ru/m/tankz/editor/view/TankFrame.yaml index e4850e1..8b9e1bc 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/TankFrame.yaml +++ b/src/editor/haxe/ru/m/tankz/editor/view/TankFrame.yaml @@ -2,15 +2,15 @@ geometry.stretch: true geometry.padding: 10 layout: - $type: haxework.view.layout.VerticalLayout + $type: hw.view.layout.VerticalLayout hAlign: center margin: 10 views: - id: tanks - $type: haxework.view.group.GroupView + $type: hw.view.group.GroupView geometry.width: 100% layout: - $type: haxework.view.layout.TailLayout + $type: hw.view.layout.TailLayout rowSize: 4 margin: 20 views: @@ -31,7 +31,7 @@ views: - $type: ru.m.tankz.editor.view.tank.TankView image: "$asset:image:resources/image/tank/bd-0.png" - id: color - $type: haxework.view.form.InputView + $type: hw.view.form.InputView +onChange: ~function(value) color = value geometry.width: 120 layout.hAlign: right diff --git a/src/editor/haxe/ru/m/tankz/editor/view/map/BrushView.hx b/src/editor/haxe/ru/m/tankz/editor/view/map/BrushView.hx index fdf14c5..5ef05ff 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/map/BrushView.hx +++ b/src/editor/haxe/ru/m/tankz/editor/view/map/BrushView.hx @@ -2,8 +2,8 @@ package ru.m.tankz.editor.view.map; import flash.display.BitmapData; import flash.display.Shape; -import haxework.color.Color; -import haxework.view.ImageView; +import hw.color.Color; +import hw.view.ImageView; class BrushView extends ImageView { diff --git a/src/editor/haxe/ru/m/tankz/editor/view/map/SpawnPointView.hx b/src/editor/haxe/ru/m/tankz/editor/view/map/SpawnPointView.hx index f6533a3..d777b09 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/map/SpawnPointView.hx +++ b/src/editor/haxe/ru/m/tankz/editor/view/map/SpawnPointView.hx @@ -1,7 +1,7 @@ package ru.m.tankz.editor.view.map; import flash.display.BitmapData; -import haxework.color.Color; +import hw.color.Color; import ru.m.tankz.config.Config; import ru.m.tankz.render.RenderUtil; import ru.m.tankz.Type.PlayerId; diff --git a/src/editor/haxe/ru/m/tankz/editor/view/popup/PackPopup.hx b/src/editor/haxe/ru/m/tankz/editor/view/popup/PackPopup.hx index e84453e..187d3df 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/popup/PackPopup.hx +++ b/src/editor/haxe/ru/m/tankz/editor/view/popup/PackPopup.hx @@ -1,8 +1,8 @@ package ru.m.tankz.editor.view.popup; -import haxework.view.form.InputView; -import haxework.view.form.SelectView; -import haxework.view.popup.PopupView; +import hw.view.form.InputView; +import hw.view.form.SelectView; +import hw.view.popup.PopupView; import ru.m.tankz.Type; @:template class PackPopup extends PopupView { diff --git a/src/editor/haxe/ru/m/tankz/editor/view/popup/PackPopup.yaml b/src/editor/haxe/ru/m/tankz/editor/view/popup/PackPopup.yaml index 22b653a..0525f55 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/popup/PackPopup.yaml +++ b/src/editor/haxe/ru/m/tankz/editor/view/popup/PackPopup.yaml @@ -2,56 +2,56 @@ layout.hAlign: center layout.vAlign: middle view: - $type: haxework.view.group.VGroupView + $type: hw.view.group.VGroupView layout.hAlign: center geometry.width: 400 #geometry.stretch: true #geometry.margin: 10 style: window views: - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView geometry.width: 100% geometry.padding: 10 layout.vAlign: middle views: - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView geometry.width: 100% geometry.margin.left: 10 layout.hAlign: left style: text text: New pack - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView style: window.close +onPress: ~reject('close') - - $type: haxework.view.group.VGroupView + - $type: hw.view.group.VGroupView geometry.width: 100% geometry.padding: 20 layout.margin: 5 layout.hAlign: left views: - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView style: text text: Type - id: type - $type: haxework.view.form.SelectView + $type: hw.view.form.SelectView geometry.width: 100% selected: classic data: - classic - dota - death - - $type: haxework.view.form.LabelView + - $type: hw.view.form.LabelView style: text text: Name - id: name - $type: haxework.view.form.InputView + $type: hw.view.form.InputView geometry.width: 100% text: new - - $type: haxework.view.group.HGroupView + - $type: hw.view.group.HGroupView layout.hAlign: center layout.margin: 5 style: panel views: - - $type: haxework.view.form.ButtonView + - $type: hw.view.form.ButtonView text: Create +onPress: ~submit() diff --git a/src/editor/haxe/ru/m/tankz/editor/view/tank/TankView.hx b/src/editor/haxe/ru/m/tankz/editor/view/tank/TankView.hx index a089dd6..bb032ae 100644 --- a/src/editor/haxe/ru/m/tankz/editor/view/tank/TankView.hx +++ b/src/editor/haxe/ru/m/tankz/editor/view/tank/TankView.hx @@ -2,9 +2,9 @@ package ru.m.tankz.editor.view.tank; import flash.display.Bitmap; import flash.display.BitmapData; -import haxework.color.Color; -import haxework.view.utils.BitmapUtil; -import haxework.view.View; +import hw.color.Color; +import hw.view.utils.BitmapUtil; +import hw.view.View; class TankView extends View { diff --git a/src/server/haxe/ru/m/tankz/server/Server.hx b/src/server/haxe/ru/m/tankz/server/Server.hx index bb67926..af93bb6 100755 --- a/src/server/haxe/ru/m/tankz/server/Server.hx +++ b/src/server/haxe/ru/m/tankz/server/Server.hx @@ -1,7 +1,7 @@ package ru.m.tankz.server; import haxe.io.Bytes; -import haxework.log.TraceLogger; +import hw.log.TraceLogger; import cpp.net.ThreadServer; import ru.m.tankz.bundle.CachedLevelBundle; import ru.m.tankz.bundle.IConfigBundle; @@ -44,7 +44,7 @@ class Server extends ThreadServer { public static function main() { L.push(new TraceLogger()); #if debug - L.push(new haxework.log.SocketLogger()); + L.push(new hw.log.SocketLogger()); #end L.d(TAG, 'Running'); L.i(TAG, 'Build: ${CompilationOption.get("build")}'); diff --git a/src/server/haxe/ru/m/tankz/server/game/IGameManager.hx b/src/server/haxe/ru/m/tankz/server/game/IGameManager.hx index 891c99f..5919ca7 100644 --- a/src/server/haxe/ru/m/tankz/server/game/IGameManager.hx +++ b/src/server/haxe/ru/m/tankz/server/game/IGameManager.hx @@ -1,6 +1,6 @@ package ru.m.tankz.server.game; -import haxework.signal.Signal; +import hw.signal.Signal; import ru.m.tankz.game.GameEvent; import ru.m.tankz.proto.core.UserProto; import ru.m.tankz.proto.room.SlotProto; diff --git a/src/server/haxe/ru/m/tankz/server/session/GameSession.hx b/src/server/haxe/ru/m/tankz/server/session/GameSession.hx index 387eacc..ce29bee 100644 --- a/src/server/haxe/ru/m/tankz/server/session/GameSession.hx +++ b/src/server/haxe/ru/m/tankz/server/session/GameSession.hx @@ -5,7 +5,7 @@ import com.hurlant.crypto.extra.UUID; import com.hurlant.crypto.prng.Random; import haxe.Serializer; import haxe.Unserializer; -import haxework.log.BaseLogger.LoggerUtil; +import hw.log.BaseLogger.LoggerUtil; import ru.m.tankz.game.GameEvent; import ru.m.tankz.proto.core.UserProto; import ru.m.tankz.proto.pack.ErrorResponse;