From 455c22e3681020e0af984faadf72737d300555a8 Mon Sep 17 00:00:00 2001 From: wxr <464027401@qq.com> Date: 星期三, 24 四月 2024 10:08:16 +0800 Subject: [PATCH] Update RoomPage.cs --- HDL_ON/UI/UI2/2-Classification/RoomPage.cs | 59 ++++++++++++++++++++++++++++++----------------------------- 1 files changed, 30 insertions(+), 29 deletions(-) diff --git a/HDL_ON/UI/UI2/2-Classification/RoomPage.cs b/HDL_ON/UI/UI2/2-Classification/RoomPage.cs index 7bbf394..dc72687 100644 --- a/HDL_ON/UI/UI2/2-Classification/RoomPage.cs +++ b/HDL_ON/UI/UI2/2-Classification/RoomPage.cs @@ -95,9 +95,36 @@ }; bodyView.AddChidren(functionListView); + try + { + foreach (var scene in room.GetRoomScenes(false)) + { + if (scene == null) + { + continue; + } + functionListView.AddChidren(new Button() { Height = Application.GetRealHeight(12) }); + var sceneRow = new FrameLayout() + { + Gravity = Gravity.CenterHorizontal, + Width = Application.GetRealWidth(343), + Height = Application.GetRealHeight(116), + Radius = (uint)Application.GetMinRealAverage(12), + BorderColor = 0x00FFFFFF, + BorderWidth = 1, + BackgroundColor = CSS_Color.MainBackgroundColor, + Tag = "Scene-" + scene.sid + }; + functionListView.AddChidren(sceneRow); + LoadSceneRow(sceneRow, scene); + } + } + catch (Exception ex) + { + MainPage.Log($"RoomPage LoadPage Error:{ex.Message}"); + } + var list = room.GetRoomFunctions(false); - - foreach (var function in list) { if (MainPage.RoomNotSupportFunctionList.Contains(function.spk)) @@ -147,33 +174,7 @@ functionListView.AddChidren(functionDiv); } } - try - { - foreach (var scene in room.GetRoomScenes(false)) - { - if (scene == null) - { - continue; - } - functionListView.AddChidren(new Button() { Height = Application.GetRealHeight(12) }); - var sceneRow = new FrameLayout() - { - Gravity = Gravity.CenterHorizontal, - Width = Application.GetRealWidth(343), - Height = Application.GetRealHeight(116), - Radius = (uint)Application.GetMinRealAverage(12), - BorderColor = 0x00FFFFFF, - BorderWidth = 1, - BackgroundColor = CSS_Color.MainBackgroundColor, - Tag = "Scene-" + scene.sid - }; - functionListView.AddChidren(sceneRow); - LoadSceneRow(sceneRow, scene); - } - }catch (Exception ex) - { - MainPage.Log($"RoomPage LoadPage Error:{ex.Message}"); - } + } -- Gitblit v1.8.0