From c396e4cf45e7601e5facf971ca85e5e491b779c5 Mon Sep 17 00:00:00 2001
From: vincentlu <t1341870251@gmail.com>
Date: 星期二, 18 三月 2025 14:11:28 +0800
Subject: [PATCH] #

---
 zy-acs-flow/src/map/MapPage.jsx |   31 +++++++++++++++++++------------
 1 files changed, 19 insertions(+), 12 deletions(-)

diff --git a/zy-acs-flow/src/map/MapPage.jsx b/zy-acs-flow/src/map/MapPage.jsx
index b777f45..cc606e9 100644
--- a/zy-acs-flow/src/map/MapPage.jsx
+++ b/zy-acs-flow/src/map/MapPage.jsx
@@ -19,11 +19,12 @@
 import * as Http from './http';
 import WebSocketClient from './websocket'
 import ConfirmButton from "../page/components/ConfirmButton";
-import { FitScreen, AltRoute, RotateRight } from '@mui/icons-material';
+import { FitScreen, RotateRight, Flip } from '@mui/icons-material';
 import MapSearch from "./header/MapSearch";
 import { startupOrShutdown } from "./http";
 import PulseSignal from "../page/components/PulseSignal";
 import FakeFab from "./header/FakeFab";
+import RouteFab from "./header/RouteFab";
 
 let player;
 let websocket;
@@ -409,17 +410,12 @@
                 >
                     {mode !== MAP_MODE.MOVABLE_MODE && (
                         <>
-                            <Fab
-                                variant="extended"
-                                color={showRoutes ? 'primary' : 'default'}
-                                size="small"
-                                onClick={() => {
-                                    showRoutes ? Tool.hideRoutes(curZone, setShowRoutes) : Tool.showRoutes(curZone, setShowRoutes)
-                                }}
-                            >
-                                <AltRoute />
-                                &nbsp;{translate('page.map.action.route')}&nbsp;
-                            </Fab>
+                            <RouteFab
+                                curZone={curZone}
+                                showRoutes={showRoutes}
+                                setShowRoutes={setShowRoutes}
+                                notify={notify}
+                            />
                             <FakeFab />
                         </>
                     )}
@@ -428,6 +424,17 @@
                         color="primary"
                         size="small"
                         onClick={() => {
+                            player.flipMapHorizontally();
+                        }}
+                    >
+                        <Flip />
+                        &nbsp;{translate('page.map.action.flip')}&nbsp;
+                    </Fab>
+                    <Fab
+                        variant="extended"
+                        color="primary"
+                        size="small"
+                        onClick={() => {
                             player.rotateMap(Math.PI / 2);
                         }}
                     >

--
Gitblit v1.9.1