From 7fa61a2e8415f8dd862aad5541d323c9c51c45c5 Mon Sep 17 00:00:00 2001
From: gxc <guoxuecheng@guoxuechengdeMacBook-Pro.local>
Date: 星期二, 29 十月 2019 13:10:29 +0800
Subject: [PATCH] 2019.10.29
---
ZigbeeApp/Shared/Phone/Device/Logic/AddScenePage.cs | 40 ++++++++++++++++++++++++++++++++--------
1 files changed, 32 insertions(+), 8 deletions(-)
diff --git a/ZigbeeApp/Shared/Phone/Device/Logic/AddScenePage.cs b/ZigbeeApp/Shared/Phone/Device/Logic/AddScenePage.cs
index fe73fd3..5f7b17b 100755
--- a/ZigbeeApp/Shared/Phone/Device/Logic/AddScenePage.cs
+++ b/ZigbeeApp/Shared/Phone/Device/Logic/AddScenePage.cs
@@ -86,7 +86,8 @@
Width = Application.GetRealWidth(400),
Height = Application.GetRealHeight(69),
Y = Application.GetRealHeight(92),
- TextID = MyInternationalizationString.customroom,
+ //TextID = MyInternationalizationString.customroom,
+ Text = Config.Instance.Home.GetCurrentFloorName,
};
topRowLayout.AddChidren(foolrname);
var dropdown = new Button
@@ -189,9 +190,8 @@
};
flMain.AddChidren(foolrbj);
///榛樿璋冭瘯
- List<string> foolrlist = new List<string> { "涓�妤�", "浜屾ゼ", "涓夋ゼ" };
- foreach (var foolr in foolrlist)
+ foreach (var foolr in Config.Instance.Home.FloorDics)
{
var foolrRowLayout = new FrameLayout
{
@@ -203,10 +203,10 @@
{
Width = Application.GetRealWidth(250),
Height = Application.GetRealHeight(160),
- Text = foolr,
+ Text = foolr.Value,
TextAlignment = TextAlignment.Center,
TextColor = ZigbeeColor.Current.LogicTextBlackColor,
- //SelectedTextColor=0xfffc744b,
+ Tag = foolr.Key,
};
foolrRowLayout.AddChidren(btnfoolrname);
@@ -215,9 +215,10 @@
{
roomhorizontalScrol.RemoveAll();
foolrname.Text = btnfoolrname.Text;
+ middle.RemoveAll();
flMain.RemoveFromParent();
- ///澶囨敞锛氭樉绀洪�変腑妤煎眰鐨勬墍鏈夋埧闂�
- AllRoomView(Common.Room.Lists);
+ var list = Send.GetRoomList(btnfoolrname.Tag.ToString());
+ AllRoomView(list);
};
foolrRowLayout.MouseUpEventHandler += foolrclick;
btnfoolrname.MouseUpEventHandler += foolrclick;
@@ -227,7 +228,30 @@
};
///绗竴娆¤繘鏉�
- AllRoomView(Common.Room.Lists);
+ var roomlists = new List<Common.Room>();
+ roomlists.Clear();
+ if (Config.Instance.Home.FloorDics.Count < 2)
+ {
+ foolrname.Visible = false;
+ dropdown.Visible = false;
+ if (Config.Instance.Home.FloorDics.Count == 0)
+ {
+ roomlists.AddRange(Common.Room.Lists);
+ }
+ else
+ {
+ roomlists = Send.GetRoomList(Config.Instance.Home.CurrentFloorId);
+ }
+ }
+ else
+ {
+ roomlists = Send.GetRoomList(Config.Instance.Home.CurrentFloorId);
+
+ }
+
+
+ ///绗竴娆¤繘鏉�
+ AllRoomView(roomlists);
}
/// <summary>
--
Gitblit v1.8.0