Browse Source

1、白板业务组件修改为F组件

bakamaka.guan 2 years ago
parent
commit
c9ae29a19c
2 changed files with 6 additions and 5 deletions
  1. 5 4
      lib/components/white_board/white_board.dart
  2. 1 1
      lib/main.dart

+ 5 - 4
lib/components/white_board/white_board.dart

@@ -4,10 +4,11 @@ import 'package:fis_common/event/event_type.dart';
 import 'package:fis_lib_business_components/components/white_board/utils.dart';
 import 'package:fis_lib_business_components/components/white_board/structure.dart';
 import 'package:fis_lib_business_components/components/white_board/white_board_painter.dart';
+import 'package:fis_ui/index.dart';
 import 'package:flutter/material.dart';
 
-class WhiteBoard extends StatefulWidget {
-  const WhiteBoard({
+class FWhiteBoard extends StatefulWidget implements FWidget {
+  const FWhiteBoard({
     key,
     required this.initData,
     required this.userId,
@@ -36,10 +37,10 @@ class WhiteBoard extends StatefulWidget {
   final FEventHandler<String> onClearCanavs;
 
   @override
-  State<WhiteBoard> createState() => _WhiteBoardState();
+  State<FWhiteBoard> createState() => _FWhiteBoardState();
 }
 
-class _WhiteBoardState extends State<WhiteBoard> {
+class _FWhiteBoardState extends State<FWhiteBoard> {
   /// 画布尺寸
   late double canvasWidth = 0.0;
   late double canvasHeight = 0.0;

+ 1 - 1
lib/main.dart

@@ -51,7 +51,7 @@ class _WhiteBoardContainerState extends State<WhiteBoardContainer> {
           children: [
             /// 白板组件入口
             Expanded(
-              child: WhiteBoard(
+              child: FWhiteBoard(
                 initData: MockData.mockCanavsCopy,
                 // initData: [],
                 userId: currUserId,