| | |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\EnvironmentalScience\HistoryOpionBg2.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\EnvironmentalScience\HistoryOpionBg3.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\EnvironmentalScience\HistoryOpionBg4.png" /> |
| | | <AndroidAsset Include="Assets\Phone\Collection\FunctionOfflineBg.png" /> |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | | <AndroidResource Include="Resources\values\colors.xml" /> |
| | |
| | | { |
| | | //只触发一次 |
| | | //Shared.Application.LocationAction = null; |
| | | new HDL_ON.DAL.Server.HttpServerRequest().GetCityWeatherInfo(lon.ToString(), lat.ToString()); |
| | | new HDL_ON.DAL.Server.HttpServerRequest().GetCityWeatherInfo(lon.ToString().Replace(",", "."), lat.ToString().Replace(",", ".")); |
| | | } |
| | | isfirst = false; |
| | | ///监听经纬度 |
| | |
| | | { |
| | | Language.CurrentLanguage = "Czech"; |
| | | } |
| | | else if (NSLocale.PreferredLanguages[0].Contains("ru-")) |
| | | { |
| | | Language.CurrentLanguage = "russian"; |
| | | } |
| | | //else if (NSLocale.PreferredLanguages[0].Contains("ru-")) |
| | | //{ |
| | | // Language.CurrentLanguage = "russian"; |
| | | //} |
| | | else |
| | | { |
| | | Language.CurrentLanguage = "English"; |
| | |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\EnvironmentalScience\HistoryOpionBg2.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\EnvironmentalScience\HistoryOpionBg3.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\EnvironmentalScience\HistoryOpionBg4.png" /> |
| | | <BundleResource Include="Resources\Phone\Collection\FunctionOfflineBg.png" /> |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | | <ITunesArtwork Include="iTunesArtwork" /> |
| | |
| | | <key>UIStatusBarStyle</key> |
| | | <string>UIStatusBarStyleLightContent</string> |
| | | <key>CFBundleShortVersionString</key> |
| | | <string>1.5.402203011</string> |
| | | <string>1.5.502203081</string> |
| | | <key>CFBundleVersion</key> |
| | | <string>1.5.403011</string> |
| | | <string>1.5.503081</string> |
| | | <key>NSLocationWhenInUseUsageDescription</key> |
| | | <string>Use geographic location to provide services such as weather</string> |
| | | <key>NSAppleMusicUsageDescription</key> |
| | |
| | | try |
| | | { |
| | | Shared.Application.LocationAction = null; |
| | | new HttpServerRequest().GetCityWeatherInfo(lon.ToString(), lat.ToString()); |
| | | new HttpServerRequest().GetCityWeatherInfo(lon.ToString().Replace(",", "."), lat.ToString().Replace(",", ".")); |
| | | } |
| | | catch(Exception ex) |
| | | { |
| | |
| | | 526=Cancel account |
| | | 527=Homekit support notes |
| | | 528=Firmware update |
| | | |
| | | 529= |
| | | 530=In order to prevent the wrong touch and click of opening and closing the door and ensure family safety, please enter your door lock password. |
| | | |
| | | 1000=Room Humidity |
| | | 1001=V-chip |
| | | 1002=Anion |
| | |
| | | 526=注销账号 |
| | | 527=支持HomeKit说明 |
| | | 528=固件更新 |
| | | 529= |
| | | 530=为防止开关门的误触点击,保证家庭安全,请输入您的门锁开门密码。 |
| | | 531=五分钟内免密码开锁 |
| | | |
| | | 1000=室内湿度 |
| | | 1001=童锁 |
| | |
| | | 526=аннулировать счёт |
| | | 527=инструкция по поддержке набора инструментальных средств для семей |
| | | 528=обновление прошивки |
| | | 529= |
| | | 530=In order to prevent the wrong touch and click of opening and closing the door and ensure family safety, please enter your door lock password. |
| | | |
| | | 1000=Влажность в Помещении |
| | | 1001=V-образный чип |
| | |
| | | public static class StringId |
| | | { |
| | | /// <summary> |
| | | /// 五分钟内免密码开锁 |
| | | /// </summary> |
| | | public const int DoorLock5minTip = 531; |
| | | /// <summary> |
| | | /// 为防止开关门的误触点击,保证家庭安全,请输入您的门锁开门密码。 |
| | | /// </summary> |
| | | public const int DoorLockEntryPasswordTip = 530; |
| | | /// <summary> |
| | | /// 密码输入 |
| | | /// </summary> |
| | | public const int EntryPassword = 529; |
| | | /// <summary> |
| | | /// 固件更新 |
| | | /// </summary> |
| | | public const int FirmwareUpdate = 528; |
| | |
| | | } |
| | | } |
| | | |
| | | [Newtonsoft.Json.JsonIgnore] |
| | | public DateTime LastTimeOpenDoor = DateTime.MinValue; |
| | | public bool VerOpenDoorPw |
| | | { |
| | | get |
| | | { |
| | | return (DateTime.Now - LastTime).TotalMinutes > 5; |
| | | } |
| | | } |
| | | [Newtonsoft.Json.JsonIgnore] |
| | | public string doorPasswordString; |
| | | |
| | | #endregion |
| | | |
| | | /// <summary> |
| | |
| | | /// 固定域名,正式环境 |
| | | /// 公共域名就近解析 |
| | | /// </summary> |
| | | public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com"; |
| | | //public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";//mmmm |
| | | //public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com"; |
| | | public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";//mmmm |
| | | /// <summary> |
| | | /// RegionMark |
| | | /// </summary> |
| | |
| | | sendDataObj.time_stamp = Utlis.GetTimestamp(); |
| | | var acd = new AlinkDoorlockStatus(); |
| | | acd.sid = sid; |
| | | acd.user_id = userId; |
| | | acd.user_id = extStr; |
| | | acd.ext_str = extStr; |
| | | #if DEBUG |
| | | acd.user_id = "013"; |
| | | acd.ext_str = "999999"; |
| | | #endif |
| | | sendDataObj.objects.Add(acd); |
| | | return sendDataObj; |
| | | } |
| | |
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\Music\MusicProperty.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\AboutOn\SupportHomeKitNotesPage.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\AboutOn\FirmwareUpdateView.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\DoorLock\DoorLockUnlockPage.cs" />
|
| | | </ItemGroup>
|
| | | <ItemGroup>
|
| | | <Folder Include="$(MSBuildThisFileDirectory)Entity\Device\" />
|
| | |
| | | btnIcon.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | |
| | | |
| | | //ESOnVideo.Current.Test(false); |
| | | |
| | | //return; |
| | |
| | | //etAccount.Text = "info@smartlife-ks.com"; |
| | | //etAccount.Text = "551775569@qq.com";//wcf |
| | | etAccount.Text = "15626203746"; |
| | | etAccount.Text = "zhangquansongjava@163.com"; |
| | | etAccount.Text = "s.savinov@hdlautomation.ru"; |
| | | //etAccount.Text = "zhangquansongjava@163.com"; |
| | | //etAccount.Text = "s.savinov@hdlautomation.ru"; |
| | | } |
| | | b = !b; |
| | | etPassword.Text = "123456"; |
| | |
| | | #if DEBUG |
| | | btnResidenceName.MouseUpEventHandler = (sender, e) => |
| | | { |
| | | |
| | | if (UserInfo.Current.VerOpenDoorPw || string.IsNullOrEmpty(UserInfo.Current.doorPasswordString)) |
| | | { |
| | | var page = new DoorLockUnlockPage(new Function()); |
| | | MainPage.BasePageView.AddChidren(page); |
| | | page.LoadView(); |
| | | MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | } |
| | | else |
| | | { |
| | | Control.Ins.OneKeyUnlocking(new Function(), UserInfo.Current.doorPasswordString); |
| | | } |
| | | |
| | | }; |
| | | #endif |
| | | |
| | |
| | | functionViews.Add(functionView); |
| | | LoadDeviceFunctionDiv(functionView, function); |
| | | index++; |
| | | |
| | | |
| | | if (!function.online) |
| | | { |
| | | btnbg.UnSelectedImagePath = "Collection/FunctionOfflineBg.png"; |
| | | } |
| | | } |
| | | |
| | | if (index == 0) |
| | |
| | | { |
| | | UpdataFunctionStates(function); |
| | | } |
| | | |
| | | |
| | | if (!function.online) |
| | | { |
| | | var btnOffline = new Button() |
| | | { |
| | | X = btnIcon.Right, |
| | | Y = Application.GetRealWidth(16), |
| | | Height = Application.GetMinRealAverage(32), |
| | | TextID = StringId.DeviceOffline, |
| | | TextColor = CSS_Color.WarningColor, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | TextAlignment = TextAlignment.CenterLeft |
| | | }; |
| | | view.AddChidren(btnOffline); |
| | | |
| | | } |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | |
| | | { |
| | | if (view.Tag.ToString() == function.sid) |
| | | { |
| | | //if (!function.online) |
| | | //{ |
| | | // view.UnSelectedImagePath = "Collection/FunctionOfflineBg.png"; |
| | | //} |
| | | |
| | | var state = false; |
| | | if (function.spk == SPK.CurtainRoller || function.spk == SPK.CurtainShades || function.spk == SPK.CurtainTrietex || |
| | | function.spk == SPK.CurtainSwitch)//窗帘设备根据百分比判断开关状态 |
| | |
| | | |
| | | LoadEvent_DivSkipEvent(); |
| | | LoadEvent_FunctionCollection(); |
| | | |
| | | |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | { |
| | | bodyDiv.AddChidren(btnCollectionIcon); |
| | | } |
| | | |
| | | if (!function.online) |
| | | { |
| | | bodyDiv.BackgroundColor = CSS_Color.PromptingColor2; |
| | | var btnOffline = new Button() |
| | | { |
| | | X = Application.GetRealWidth(8 + 10 + 32), |
| | | Y = Application.GetRealHeight(28 + 24), |
| | | Height = Application.GetRealHeight(30), |
| | | TextID = StringId.DeviceOffline, |
| | | TextColor = CSS_Color.WarningColor, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | TextAlignment = TextAlignment.CenterLeft |
| | | }; |
| | | bodyDiv.AddChidren(btnOffline); |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | continue; |
| | | } |
| | | //自动化配置输入条件纬度 |
| | | double lat = Convert.ToDouble(logicDate.geo_fence.latitude); |
| | | double lat = Convert.ToDouble(logicDate.geo_fence.latitude.Replace(",", ".")); |
| | | //自动化配置输入条件经度 |
| | | double lon = Convert.ToDouble(logicDate.geo_fence.longitude); |
| | | double lon = Convert.ToDouble(logicDate.geo_fence.longitude.Replace(",", ".")); |
| | | //自动化配置输入条件<地理围栏半径><单位,公里、千米.米> |
| | | int radius = int.Parse(logicDate.geo_fence.radius); |
| | | //计算2个经纬度之间的距离 |
| | |
| | | /// </summary> |
| | | private void InitFrameWhiteContent1() |
| | | { |
| | | temp = (int)Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp)); |
| | | temp = (int)Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")); |
| | | arcBar = new DiyArcSeekBar() |
| | | { |
| | | Gravity = Gravity.CenterHorizontal, |
| | |
| | | arcBar.IsOffline = device.GetAttrState(FunctionAttributeKey.OnOff) == "off"; |
| | | arcBar.MinValue = device.GetAttribute(FunctionAttributeKey.SetTemp).min; |
| | | arcBar.MaxValue = device.GetAttribute(FunctionAttributeKey.SetTemp).max; |
| | | arcBar.Progress = (int)Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp)); |
| | | arcBar.Progress = (int)Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")); |
| | | |
| | | btnTemp = new Button() |
| | | { |
| | |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = 50, |
| | | IsBold = true, |
| | | Text = Convert.ToDouble( device.GetAttrState(FunctionAttributeKey.SetTemp)).ToString(), |
| | | Text = Convert.ToDouble( device.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")).ToString(), |
| | | TextAlignment = TextAlignment.Center, |
| | | }; |
| | | FrameWhiteCentet1.AddChidren(btnTemp); |
| | |
| | | } |
| | | else |
| | | { |
| | | btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.RoomTemp))) + "°C"; |
| | | btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.RoomTemp).Replace(",", "."))) + "°C"; |
| | | btnMode.SelectedImagePath = acFunction.GetModeIconPath(device.GetAttrState(FunctionAttributeKey.Mode)); |
| | | btnSwing.SelectedImagePath = acFunction.GetSwingIconPath(device.GetAttrState(FunctionAttributeKey.Swing)); |
| | | btnWindSpeed.SelectedImagePath = acFunction.GetFanIconPath(device.GetAttrState(FunctionAttributeKey.FanSpeed)); |
| | | btnMode.UnSelectedImagePath = acFunction.GetModeIconPath(device.GetAttrState(FunctionAttributeKey.Mode), false); |
| | | btnSwing.UnSelectedImagePath = acFunction.GetSwingIconPath(device.GetAttrState(FunctionAttributeKey.Swing), false); |
| | | btnWindSpeed.UnSelectedImagePath = acFunction.GetFanIconPath(device.GetAttrState(FunctionAttributeKey.FanSpeed), false); |
| | | temp = Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp))); |
| | | temp = Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", "."))); |
| | | |
| | | |
| | | arcBar.Progress = temp; |
| | |
| | | Application.RunOnMainThread(() => |
| | | { |
| | | btnTemp.Text = device.GetAttrState(FunctionAttributeKey.SetTemp); |
| | | btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.RoomTemp))) + "°C"; |
| | | btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.RoomTemp).Replace(",", "."))) + "°C"; |
| | | btnMode.UnSelectedImagePath = fhTemp.GetModeIconPath(device.GetAttrState(FunctionAttributeKey.Mode)); |
| | | arcBar.Progress = Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp))); |
| | | arcBar.Progress = Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", "."))); |
| | | if (device.trait_on_off.curValue.ToString() == "on") |
| | | { |
| | | arcBar.IsOffline = false; |
| | |
| | | MaxValue = function.GetAttribute(FunctionAttributeKey.SetTemp).max, |
| | | //IsClickable = function.trait_on_off.curValue.ToString() == "on", |
| | | ArcColor = CSS_Color.BackgroundColor, |
| | | Progress = (int)Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp)), |
| | | Progress = (int)Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",",".")), |
| | | #if __IOS__ |
| | | Y = Application.GetRealHeight(120 + 25), |
| | | Width = Application.GetRealWidth(260 - 40), |
| | |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = 50, |
| | | IsBold = true, |
| | | Text = Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp)).ToString(), |
| | | Text = Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")).ToString(), |
| | | TextAlignment = TextAlignment.Center, |
| | | }; |
| | | controlView.AddChidren(btnTemp); |
| | |
| | | } |
| | | AC temp = new AC(); |
| | | updataTime = DateTime.Now; |
| | | bodyView.btnTemp.Text = Convert.ToDouble( updateTemp.GetAttrState(FunctionAttributeKey.SetTemp)).ToString(); |
| | | bodyView.btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState((string)FunctionAttributeKey.RoomTemp))) + "°C"; |
| | | bodyView.btnTemp.Text = Convert.ToDouble( updateTemp.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")).ToString(); |
| | | bodyView.btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.RoomTemp).Replace(",", "."))) + "°C"; |
| | | bodyView.btnMode.UnSelectedImagePath = temp.GetModeIconPath(updateTemp.GetAttrState(FunctionAttributeKey.Mode)); |
| | | bodyView.btnWindSpeed.UnSelectedImagePath = temp.GetFanIconPath(updateTemp.GetAttrState(FunctionAttributeKey.FanSpeed)); |
| | | bodyView.arcBar.Progress = Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.SetTemp))); |
| | | bodyView.arcBar.Progress = Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", "."))); |
| | | if (updateTemp.trait_on_off.curValue.ToString() == "on") |
| | | { |
| | | bodyView.arcBar.IsOffline = false; |
| | |
| | | { |
| | | return; |
| | | } |
| | | var temp = (int)Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp)); |
| | | var temp = (int)Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")); |
| | | if (temp <= function.GetAttribute(FunctionAttributeKey.Mode).min) |
| | | { |
| | | return; |
| | |
| | | { |
| | | return; |
| | | } |
| | | var temp = (int)Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp)); |
| | | var temp = (int)Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")); |
| | | if (temp >= function.GetAttribute(FunctionAttributeKey.SetTemp).max) |
| | | { |
| | | return; |
| | |
| | | HdlMessageLogic.Current.ShowMassage(ShowMsgType.TipRemind, Language.StringByID(StringId.DeviceNotOnline), null, null, null, 2); |
| | | return; |
| | | } |
| | | Control.Ins.OneKeyUnlocking(this.device, this.device.GetAttrState("key")); |
| | | if (UserInfo.Current.VerOpenDoorPw || string.IsNullOrEmpty(UserInfo.Current.doorPasswordString)) |
| | | { |
| | | var page = new DoorLockUnlockPage(this.device); |
| | | MainPage.BasePageView.AddChidren(page); |
| | | page.LoadView(); |
| | | MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | } |
| | | else |
| | | { |
| | | Control.Ins.OneKeyUnlocking(this.device, UserInfo.Current.doorPasswordString); |
| | | } |
| | | //第一次使用,请先绑定门锁密码 |
| | | //HdlMessageLogic.Current.ShowMassage(ShowMsgType.Confirm, Language.StringByID(StringId.PleaseBindTheDoorPswFirst), () => |
| | | //{ |
New file |
| | |
| | | using System; |
| | | using HDL_ON.DriverLayer; |
| | | using HDL_ON.Entity; |
| | | using HDL_ON.Stan; |
| | | using HDL_ON.UI.CSS; |
| | | using Shared; |
| | | namespace HDL_ON.UI |
| | | { |
| | | public class DoorLockUnlockPage : FrameLayout |
| | | { |
| | | /// <summary> |
| | | /// 当前界面 |
| | | /// </summary> |
| | | FrameLayout bodyView; |
| | | |
| | | Function device; |
| | | |
| | | public DoorLockUnlockPage(Function function) |
| | | { |
| | | bodyView = this; |
| | | device = function; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 加载视图 |
| | | /// </summary> |
| | | public void LoadView() |
| | | { |
| | | |
| | | new TopViewDiv(bodyView, Language.StringByID(StringId.PlsEntryPassword)).LoadTopView(); |
| | | bodyView.BackgroundColor = CSS_Color.MainBackgroundColor; |
| | | |
| | | |
| | | var btnMsg = new Button() |
| | | { |
| | | Gravity = Gravity.CenterHorizontal, |
| | | Y = Application.GetRealHeight(100), |
| | | Width = Application.GetRealWidth(300), |
| | | Height = Application.GetRealHeight(100), |
| | | TextAlignment = TextAlignment.TopCenter, |
| | | TextColor = CSS_Color.TextualColor, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | TextID = StringId.DoorLockEntryPasswordTip, |
| | | IsMoreLines = true, |
| | | }; |
| | | bodyView.AddChidren(btnMsg); |
| | | |
| | | #region 密码填写 |
| | | var passwordView = new FrameLayout() |
| | | { |
| | | X = Application.GetRealWidth(28), |
| | | Y = Application.GetRealHeight(200), |
| | | Width = Application.GetRealWidth(319), |
| | | Height = Application.GetRealHeight(44), |
| | | }; |
| | | bodyView.AddChidren(passwordView); |
| | | |
| | | |
| | | var etPassword = new EditText() |
| | | { |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | PlaceholderTextColor = CSS_Color.PromptingColor1, |
| | | PlaceholderText = Language.StringByID(StringId.PlsEntryPassword), |
| | | SecureTextEntry = true, |
| | | TextAlignment = TextAlignment.Center, |
| | | BackgroundColor = CSS_Color.BackgroundColor, |
| | | IsNumberKeyboardType = true |
| | | }; |
| | | passwordView.AddChidren(etPassword); |
| | | |
| | | //var btnVisiblePassword = new Button() |
| | | //{ |
| | | // X = Application.GetRealWidth(273), |
| | | // Gravity = Gravity.CenterVertical, |
| | | // Width = Application.GetMinRealAverage(20), |
| | | // Height = Application.GetMinRealAverage(20), |
| | | // UnSelectedImagePath = "LoginIcon/HidePasswordIcon.png", |
| | | // SelectedImagePath = "LoginIcon/ShowPasswordIcon.png", |
| | | //}; |
| | | //passwordView.AddChidren(btnVisiblePassword); |
| | | |
| | | #endregion |
| | | |
| | | |
| | | |
| | | var frameRow = new FrameLayout() |
| | | { |
| | | Height = Application.GetRealHeight(28), |
| | | Y = Application.GetRealHeight(258),//375 // 667 |
| | | }; |
| | | bodyView.AddChidren(frameRow); |
| | | |
| | | //同意按钮背景 |
| | | var agreeView = new FrameLayout() |
| | | { |
| | | Height = Application.GetRealHeight(28), |
| | | Width = Application.GetRealWidth(28), |
| | | X = Application.GetRealWidth(22), |
| | | }; |
| | | frameRow.AddChidren(agreeView); |
| | | |
| | | //同意图标按钮 |
| | | var agreeBtn = new Button() |
| | | { |
| | | Width = Application.GetMinRealAverage(28), |
| | | Height = Application.GetMinRealAverage(28), |
| | | UnSelectedImagePath = "Public/ChooseIcon.png", |
| | | SelectedImagePath = "Public/ChooseOnIcon.png", |
| | | IsSelected = OnAppConfig.Instance.isAgreePrivacyPolicy, |
| | | Gravity = Gravity.Center |
| | | }; |
| | | agreeView.AddChidren(agreeBtn); |
| | | |
| | | var agreeTextBtn = new TextButton() |
| | | { |
| | | X = agreeView.Right, |
| | | Width = Application.GetRealWidth(28), |
| | | Height = Application.GetRealHeight(28), |
| | | TextColor = CSS_Color.TextualColor, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | TextID = StringId.DoorLock5minTip |
| | | }; |
| | | frameRow.AddChidren(agreeTextBtn); |
| | | agreeTextBtn.Width = Utlis.GetRealWidthByTextButton(agreeTextBtn); |
| | | |
| | | EventHandler<MouseEventArgs> eventHandler = (sender, e) => |
| | | { |
| | | agreeBtn.IsSelected = !agreeBtn.IsSelected; |
| | | }; |
| | | |
| | | agreeBtn.MouseUpEventHandler = eventHandler; |
| | | agreeView.MouseUpEventHandler = eventHandler; |
| | | agreeTextBtn.MouseUpEventHandler = eventHandler; |
| | | |
| | | |
| | | Button btnLine = new Button() |
| | | { |
| | | Y = Application.GetRealHeight(607), |
| | | Height = Application.GetRealHeight(1), |
| | | BackgroundColor = CSS.CSS_Color.DividingLineColor, |
| | | }; |
| | | bodyView.AddChidren(btnLine); |
| | | |
| | | Button btnCancel = new Button() |
| | | { |
| | | Y = btnLine.Bottom, |
| | | Width = Application.GetRealWidth(374/2), |
| | | Height = Application.GetRealHeight(60), |
| | | TextAlignment = TextAlignment.Center, |
| | | TextColor = CSS_Color.TextualColor, |
| | | TextSize = CSS_FontSize.SubheadingFontSize, |
| | | TextID = StringId.Cancel, |
| | | }; |
| | | bodyView.AddChidren(btnCancel); |
| | | btnCancel.MouseUpEventHandler = (sender, e) => { |
| | | this.RemoveFromParent(); |
| | | }; |
| | | |
| | | Button btnConfirm = new Button() |
| | | { |
| | | X = btnCancel.Right, |
| | | Y = btnLine.Y, |
| | | Width = Application.GetRealWidth(376 / 2), |
| | | Height = Application.GetRealHeight(60), |
| | | TextAlignment = TextAlignment.Center, |
| | | //TextColor = CSS_Color.TextualColor, |
| | | TextSize = CSS_FontSize.SubheadingFontSize, |
| | | TextColor = CSS_Color.MainBackgroundColor, |
| | | BackgroundColor = CSS_Color.MainColor, |
| | | TextID = StringId.Confirm, |
| | | }; |
| | | bodyView.AddChidren(btnConfirm); |
| | | btnConfirm.MouseUpEventHandler = (sender, e) => { |
| | | var password = etPassword.Text.Trim(); |
| | | if (password.Length == 0) |
| | | { |
| | | //设备不在线 |
| | | HdlMessageLogic.Current.ShowMassage(ShowMsgType.TipRemind, Language.StringByID(StringId.PlsEntryPassword), null, null, null, 2); |
| | | return; |
| | | } |
| | | if (agreeBtn.IsSelected) |
| | | { |
| | | UserInfo.Current.doorPasswordString = password; |
| | | } |
| | | Control.Ins.OneKeyUnlocking(this.device, etPassword.Text.Trim()); |
| | | this.RemoveFromParent(); |
| | | }; |
| | | |
| | | } |
| | | |
| | | } |
| | | } |
| | |
| | | sensorSPK = showList[0].spk; |
| | | foreach (var s in showList) |
| | | { |
| | | assembleValues += Convert.ToDouble(s.GetAttrState("value")); |
| | | assembleValues += Convert.ToDouble(s.GetAttrState("value").Replace(",", ".")); |
| | | } |
| | | |
| | | |
| | |
| | | assembleValues = 0; |
| | | foreach (var s in sensorList) |
| | | { |
| | | assembleValues += Convert.ToDouble(s.GetAttrState("value")); |
| | | assembleValues += Convert.ToDouble(s.GetAttrState("value").Replace(",", ".")); |
| | | } |
| | | } |
| | | |
| | |
| | | { |
| | | return; |
| | | } |
| | | var outinTemp = Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.SetTemp))); |
| | | var outinTemp = Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", "."))); |
| | | bodyView.btnTemp.Text = outinTemp.ToString(); |
| | | bodyView.btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.RoomTemp))) + "°C"; |
| | | bodyView.btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.RoomTemp).Replace(",", "."))) + "°C"; |
| | | bodyView.btnMode.SelectedImagePath = bodyView.fhTemp.GetModeIconPath(updateTemp.GetAttrState(FunctionAttributeKey.Mode)); |
| | | bodyView.btnMode.UnSelectedImagePath = bodyView.fhTemp.GetModeIconPath(updateTemp.GetAttrState(FunctionAttributeKey.Mode),false); |
| | | bodyView.arcBar.Progress = outinTemp; |
| | |
| | | return; |
| | | } |
| | | |
| | | var temp = (int)Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp)); |
| | | var temp = (int)Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")); |
| | | if (temp <= Convert.ToInt32(function.GetAttribute(FunctionAttributeKey.SetTemp).min)) |
| | | { |
| | | return; |
| | |
| | | { |
| | | return; |
| | | } |
| | | var temp =(int) Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp)); |
| | | var temp =(int) Convert.ToDouble(function.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")); |
| | | if (temp >= Convert.ToDouble(function.GetAttribute(FunctionAttributeKey.SetTemp).max)) |
| | | { |
| | | return; |
| | |
| | | arcBar.OnProgressChangedEvent = (sender, e) => |
| | | { |
| | | function.SetAttrState(FunctionAttributeKey.SetTemp, e); |
| | | btnTemp.Text = Convert.ToDouble( function.GetAttrState(FunctionAttributeKey.SetTemp)).ToString(); |
| | | btnTemp.Text = Convert.ToDouble( function.GetAttrState(FunctionAttributeKey.SetTemp).Replace(",", ".")).ToString(); |
| | | }; |
| | | } |
| | | /// <summary> |
| | |
| | | /// 固定域名,正式环境 |
| | | /// 公共域名就近解析 |
| | | /// </summary> |
| | | public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com"; |
| | | //public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";//mmmm |
| | | //public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com"; |
| | | public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";//mmmm |
| | | /// <summary> |
| | | /// RegionMark |
| | | /// </summary> |