|
@@ -1,10 +1,8 @@
|
|
|
-import 'dart:math' as math;
|
|
|
import 'package:fis_measure/interfaces/date_types/int_size.dart';
|
|
|
import 'package:fis_measure/interfaces/process/player/play_controller.dart';
|
|
|
import 'package:fis_measure/interfaces/process/workspace/application.dart';
|
|
|
import 'package:fis_measure/values/colors.dart';
|
|
|
-import 'package:fis_measure/view/player/enums.dart';
|
|
|
-import 'package:fis_vid/data_host/data_host.dart';
|
|
|
+import 'package:fis_measure/view/player/control_board/control_board.dart';
|
|
|
import 'package:flutter/material.dart';
|
|
|
import 'package:get/get.dart';
|
|
|
|
|
@@ -12,7 +10,6 @@ import '../canvas/active_canvas.dart';
|
|
|
import '../canvas/records_canvas.dart';
|
|
|
import '../gesture/mouse_gesture.dart';
|
|
|
import '../player/controller.dart';
|
|
|
-import '../player/events.dart';
|
|
|
import '../player/player.dart';
|
|
|
import '../result/results_panel.dart';
|
|
|
|
|
@@ -62,42 +59,68 @@ class _MeasureMainViewState extends State<MeasureMainView> {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ Widget vidPlayerBoard() {
|
|
|
+ if ((playerController as VidPlayerController).totalFramesCount > 1) {
|
|
|
+ return Container(
|
|
|
+ margin: const EdgeInsets.symmetric(
|
|
|
+ horizontal: 160,
|
|
|
+ ),
|
|
|
+ key: UniqueKey(),
|
|
|
+ height: 100,
|
|
|
+ child: VidPlayerControlBoard(
|
|
|
+ playerController as VidPlayerController,
|
|
|
+ ),
|
|
|
+ );
|
|
|
+ } else {
|
|
|
+ return Container();
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
@override
|
|
|
Widget build(BuildContext context) {
|
|
|
- return Container(
|
|
|
- color: MeasureColors.Background,
|
|
|
- child: CustomMultiChildLayout(
|
|
|
- delegate: _LayerLayoutDelegate(imageSize: frameSize),
|
|
|
- children: [
|
|
|
- LayoutId(
|
|
|
- id: _LayerLayoutIds.player,
|
|
|
- child: Container(
|
|
|
- // decoration: BoxDecoration(
|
|
|
- // border: Border.all(color: Colors.white),
|
|
|
- // ),
|
|
|
- child: VidPlayer(playerController as VidPlayerController),
|
|
|
- ),
|
|
|
+ return Stack(
|
|
|
+ children: [
|
|
|
+ Container(
|
|
|
+ color: MeasureColors.Background,
|
|
|
+ child: CustomMultiChildLayout(
|
|
|
+ delegate: _LayerLayoutDelegate(imageSize: frameSize),
|
|
|
+ children: [
|
|
|
+ LayoutId(
|
|
|
+ id: _LayerLayoutIds.player,
|
|
|
+ child: Container(
|
|
|
+ child: VidPlayer(playerController as VidPlayerController),
|
|
|
+ ),
|
|
|
+ ),
|
|
|
+ if (canMeasure) ...[
|
|
|
+ LayoutId(
|
|
|
+ id: _LayerLayoutIds.recordsCanvas,
|
|
|
+ child: const MeasureRecordsCanvasPanel(),
|
|
|
+ ),
|
|
|
+ LayoutId(
|
|
|
+ id: _LayerLayoutIds.activeCanvas,
|
|
|
+ child: const MeasureActiveCanvasPanel(),
|
|
|
+ ),
|
|
|
+ LayoutId(
|
|
|
+ id: _LayerLayoutIds.gesture,
|
|
|
+ child: const MeasureMouseGesturePanel(),
|
|
|
+ ),
|
|
|
+ LayoutId(
|
|
|
+ id: _LayerLayoutIds.result,
|
|
|
+ child: const MeasureResultPanel(),
|
|
|
+ ),
|
|
|
+ ],
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ ),
|
|
|
+ Align(
|
|
|
+ alignment: Alignment.bottomCenter,
|
|
|
+ child: Positioned(
|
|
|
+ height: 100,
|
|
|
+ bottom: 50,
|
|
|
+ child: vidPlayerBoard(),
|
|
|
),
|
|
|
- if (canMeasure) ...[
|
|
|
- LayoutId(
|
|
|
- id: _LayerLayoutIds.recordsCanvas,
|
|
|
- child: const MeasureRecordsCanvasPanel(),
|
|
|
- ),
|
|
|
- LayoutId(
|
|
|
- id: _LayerLayoutIds.activeCanvas,
|
|
|
- child: const MeasureActiveCanvasPanel(),
|
|
|
- ),
|
|
|
- LayoutId(
|
|
|
- id: _LayerLayoutIds.gesture,
|
|
|
- child: const MeasureMouseGesturePanel(),
|
|
|
- ),
|
|
|
- LayoutId(
|
|
|
- id: _LayerLayoutIds.result,
|
|
|
- child: const MeasureResultPanel(),
|
|
|
- ),
|
|
|
- ],
|
|
|
- ],
|
|
|
- ),
|
|
|
+ ),
|
|
|
+ ],
|
|
|
);
|
|
|
}
|
|
|
}
|