xm
2021-11-24 1802b849f0dadc81644fb0a706d6fb45efdf2a20
Merge remote-tracking branch 'origin/newBranch1' into WJC
25个文件已修改
871 ■■■■■ 已修改文件
.vs/HDL_APP_Project/xs/UserPrefs.xml 44 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_Android/Properties/AndroidManifest.xml 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/AppDelegate.cs 31 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Entitlements.plist 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/HDL-ON_iOS.csproj 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Info.plist 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/ViewController.cs 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Mqtt/MqttClient.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Server/HttpServerRequest.cs 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Server/NewAPI.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Entity/Function/Scene.cs 32 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/MainPage.cs 82 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI0-Public/PublicAssmebly.cs 25 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI1-Login/LoginPage.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs 88 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/PersonalDataPage.cs 70 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs 99 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/Curtain/RollingShutterPage.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/Curtain/RollingShutterPageBLL.cs 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/Light/ColorTureLampPage.cs 131 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/Light/ColorTureLampPageBLL.cs 19 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPage.cs 134 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPageBLL.cs 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/Light/RGBPage.cs 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/Light/RGBPageBLL.cs 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
.vs/HDL_APP_Project/xs/UserPrefs.xml
@@ -1,23 +1,25 @@
<Properties StartupConfiguration="{09712674-2A38-407B-B1E2-560B2C352F9A}|Default">
  <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneSimulatorTarget." />
  <MonoDevelop.Ide.Workbench>
<Properties StartupConfiguration="{D998E133-F0DD-4760-BE3C-461632F54DA4}|Default">
  <MonoDevelop.Ide.ItemProperties.SiriIntentUI>
    <MonoDevelop.MacDev.AppleDevelopmentTeam />
  </MonoDevelop.Ide.ItemProperties.SiriIntentUI>
  <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneDeviceTarget" />
  <MonoDevelop.Ide.Workbench ActiveDocument="HDL_ON/DAL/Server/HttpUtil.cs">
    <Files>
      <File FileName="HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPage.cs" Line="203" Column="17" IsPinned="True" />
      <File FileName="HDL_ON/DAL/Server/HttpUtil.cs" Line="21" Column="79" />
    </Files>
    <Pads>
      <Pad Id="ProjectPad">
        <State name="__root__">
          <Node name="HDL_APP_Project" expanded="True">
            <Node name="HDL_ON" expanded="True">
              <Node name="UI" expanded="True">
                <Node name="UI2" expanded="True">
                  <Node name="3-Intelligence" expanded="True">
                    <Node name="Automation" expanded="True" />
                  </Node>
                </Node>
                <Node name="MainPage.cs" selected="True" />
              </Node>
            </Node>
            <Node name="HDL-ON_Android" expanded="True" />
            <Node name="HDL-ON_iOS" expanded="True" />
            <Node name="HDL-ON_iOS" expanded="True" selected="True" />
          </Node>
        </State>
      </Pad>
      <Pad Id="MonoDevelop.Debugger.WatchPad">
        <State>
          <Value>tempFunction.deviceId</Value>
          <Value>updata2.ToString()</Value>
        </State>
      </Pad>
    </Pads>
@@ -27,13 +29,17 @@
    <String>Shared.IOS.TBL/Shared.IOS.TBL.csproj</String>
    <String>Shared.Droid.TouchID/Shared.Droid.TouchID.csproj</String>
    <String>Shared.IOS/Shared.IOS.csproj</String>
    <String>SiriIntent/SiriIntent.csproj</String>
    <String>SceneKit/SceneKit.csproj</String>
  </DisabledProjects>
  <MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" />
  <MonoDevelop.Ide.ItemProperties.HDL-ON__Android PreferredExecutionTarget="Android.2ffc9a07" />
  <MonoDevelop.Ide.Workspace ActiveConfiguration="Release|iPhone" />
  <MonoDevelop.Ide.ItemProperties.HDL-ON__Android PreferredExecutionTarget="Android.SelectDevice" />
  <MonoDevelop.Ide.DebuggingService.Breakpoints>
    <BreakpointStore>
      <Breakpoint file="/Users/hdl/Desktop/git/HDL_APP_Project/HDL_ON/DAL/Server/HttpServerRequest.cs" relfile="HDL_ON/DAL/Server/HttpServerRequest.cs" line="1415" column="1" />
      <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HdlSiriKit/SkipControl.cs" relfile="HdlSiriKit/SkipControl.cs" line="28" column="1" />
      <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HDL-ON_iOS/Other/SkipControl.cs" relfile="HDL-ON_iOS/Other/SkipControl.cs" line="25" column="1" />
      <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HdlSiriKit/SkipControl.cs" relfile="HdlSiriKit/SkipControl.cs" line="14" column="1" />
    </BreakpointStore>
  </MonoDevelop.Ide.DebuggingService.Breakpoints>
  <MultiItemStartupConfigurations />
</Properties>
</Properties>
HDL-ON_Android/Properties/AndroidManifest.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="202111031" android:versionName="1.3.202111031" package="com.hdl.onpro">
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="202111231" android:versionName="1.3.202111231" package="com.hdl.onpro">
    <uses-sdk android:minSdkVersion="23" android:targetSdkVersion="28" />
    <!-- 乐橙可视对讲需要的权限 -->
    <!--<uses-permission android:name="android.permission.INTERNET" />-->
@@ -82,7 +82,7 @@
    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
    <uses-permission android:name="android.permission.READ_LOGS" />
    <!-- 极光推送结束 -->
    <application android:allowBackup="true" android:icon="@drawable/Icon" android:networkSecurityConfig="@xml/network_security_config" android:largeHeap="true" android:label="ON+">
    <application android:allowBackup="true" android:icon="@drawable/Icon" android:networkSecurityConfig="@xml/network_security_config" android:largeHeap="true" android:label="On Pro">
        <provider android:name="android.support.v4.content.FileProvider" android:authorities="com.hdl.onpro.fileProvider" android:grantUriPermissions="true" android:exported="false">
            <meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/file_paths" />
        </provider>
HDL-ON_iOS/AppDelegate.cs
@@ -1,4 +1,4 @@
using System;
using System;
using Foundation;
using HDL_ON;
using Shared;
@@ -9,6 +9,7 @@
using Microsoft.AppCenter.Crashes;
using HDL_ON.UI;
using HDL_ON.DAL.Server;
using Intents;
namespace SharedMethod
{
@@ -275,6 +276,34 @@
            //{
            //    //RemoteInfo.Current.ReadMsgList(true);
            //}
            #region Siri
            // Request access to Siri
            INPreferences.RequestSiriAuthorization((INSiriAuthorizationStatus status) => {
                // Respond to returned status
                switch (status)
                {
                    case INSiriAuthorizationStatus.Authorized:
                        break;
                    case INSiriAuthorizationStatus.Denied:
                        break;
                    case INSiriAuthorizationStatus.NotDetermined:
                        break;
                    case INSiriAuthorizationStatus.Restricted:
                        break;
                }
            });
            var language = INPreferences.SiriLanguageCode;
            // Take action based on language
            if (language == "en-US")
            {
                // Do something...
            }
            #endregion
            //高德key
            GDMapKit.setGDApiKey("f0635ea15c5d579c6e93d9f07a06da69");
            Console.WriteLine("FinishedLaunching");
HDL-ON_iOS/Entitlements.plist
@@ -8,5 +8,7 @@
    <array>
        <string>applinks:china-gateway.hdlcontrol.com</string>
    </array>
    <key>com.apple.developer.siri</key>
    <true/>
</dict>
</plist>
HDL-ON_iOS/HDL-ON_iOS.csproj
@@ -54,7 +54,7 @@
        <MtouchLink>SdkOnly</MtouchLink>
        <MtouchExtraArgs>-gcc_flags="-dead_strip -ObjC"</MtouchExtraArgs>
        <MtouchEnableSGenConc>false</MtouchEnableSGenConc>
<CodesignProvision>On+Dev-20210913-1</CodesignProvision>
<CodesignProvision>OnPro211116-1</CodesignProvision>
<CodesignEntitlements>Entitlements.plist</CodesignEntitlements>
    </PropertyGroup>
    <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhone' ">
@@ -69,7 +69,7 @@
        <MtouchLink>SdkOnly</MtouchLink>
        <MtouchExtraArgs>-gcc_flags="-dead_strip -ObjC"</MtouchExtraArgs>
        <MtouchI18n>cjk</MtouchI18n>
        <CodesignProvision>ComHdlOnProAdHoc20210616-1</CodesignProvision>
        <CodesignProvision>OnPro-Hoc20211117-1</CodesignProvision>
    </PropertyGroup>
    <ItemGroup>
        <Reference Include="System" />
@@ -1401,6 +1401,11 @@
        <Project>{2DDF4C3C-6998-432E-9F43-6786D82F0630}</Project>
        <Name>Blufi</Name>
      </ProjectReference>
      <ProjectReference Include="..\SiriIntentUI\SiriIntentUI.csproj">
        <IsAppExtension>true</IsAppExtension>
        <Project>{B594D3F5-4B93-4988-B45E-150BBFDC8A43}</Project>
        <Name>SiriIntentUI</Name>
      </ProjectReference>
    </ItemGroup>
    <Import Project="..\HDL_ON\HDL_ON.projitems" Label="Shared" Condition="Exists('..\HDL_ON\HDL_ON.projitems')" />
    <Import Project="$(MSBuildExtensionsPath)\Xamarin\iOS\Xamarin.iOS.CSharp.targets" />
HDL-ON_iOS/Info.plist
@@ -92,17 +92,17 @@
    <key>XSLaunchImageAssets</key>
    <string>Assets.xcassets/LaunchImage.launchimage</string>
    <key>CFBundleName</key>
    <string>ON +</string>
    <string>On Pro</string>
    <key>XSAppIconAssets</key>
    <string>Assets.xcassets/AppIcon.appiconset</string>
    <key>CFBundleDisplayName</key>
    <string>ON +</string>
    <string>On Pro</string>
    <key>UIStatusBarStyle</key>
    <string>UIStatusBarStyleLightContent</string>
    <key>CFBundleShortVersionString</key>
    <string>1.2.202110281</string>
    <string>1.3.202111231</string>
    <key>CFBundleVersion</key>
    <string>1.2.10281</string>
    <string>1.3.11231</string>
    <key>NSLocationWhenInUseUsageDescription</key>
    <string>Use geographic location to provide services such as weather</string>
    <key>NSAppleMusicUsageDescription</key>
@@ -133,5 +133,7 @@
    <string>This application uses Bluetooth to communicate with the device, this application does not collect, store or record any data that communicates via Bluetooth.</string>
    <key>NSVoIPUsageDescription</key>
    <string>Make audio/video calls</string>
    <key>NSSiriUsageDescription</key>
    <string>On Pro data will be send to Siri.</string>
</dict>
</plist>
HDL-ON_iOS/ViewController.cs
@@ -24,7 +24,6 @@
        public override void ViewDidLoad()
        {
            Console.WriteLine("qidong 1111");
            base.ViewDidLoad();
            HDL_ON.MainPage.Show();
@@ -97,5 +96,7 @@
            //    MainPage.InternetStatus = 2;
            //}
        }
    }
}
HDL_ON/DAL/Mqtt/MqttClient.cs
@@ -310,7 +310,7 @@
                            try
                            {
                                var topic = e.ApplicationMessage.Topic;
                                MainPage.Log($"收到mqtt主题:{topic}");
                                //MainPage.Log($"收到mqtt主题:{topic}");
                                //一端口主题处理
                                if (DB_ResidenceData.Instance.GatewayType == 0 && !DB_ResidenceData.Instance.CheckWhetherGatewayIdIsNull())
                                {
HDL_ON/DAL/Server/HttpServerRequest.cs
@@ -2556,10 +2556,10 @@
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_EZ_GetChildToken, requestJson);
        }
#endregion
        #endregion
#region ■ 可视对讲_________________________
        #region ■ 可视对讲_________________________
        /// <summary>
        /// 检查住宅是否绑定丰林
        /// </summary>
@@ -2572,9 +2572,9 @@
            var pack = HttpUtil.RequestHttpsPostFroHome( NewAPI.API_POST_FL_Check, requestJson);
            return pack;
        }
#endregion
        #endregion
#region ■ 门锁相关____________________________
        #region ■ 门锁相关____________________________
        /// <summary>
        /// 获取门锁历史记录(按日期降序)
@@ -2643,8 +2643,8 @@
            return listSortLog;
        }
#endregion
#region ■ 音箱语言控制相关_________________________
        #endregion
        #region ■ 音箱语言控制相关_________________________
        /// <summary>
        /// 获取已授权的音箱列表
        /// </summary>
@@ -2708,8 +2708,20 @@
            var requestJson = HttpUtil.GetSignRequestJson(updateSpeakerDeviceListObj);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_Speaker_DeviceList_Update, requestJson);
        }
#endregion
        #endregion
        /// <summary>
        /// 绑定source面板
        /// </summary>
        /// <returns></returns>
        public ResponsePackNew BindSourcePanel(string qrString)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("content", qrString);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_BindSourcePanel, requestJson);
        }
        /// <summary>
        /// 人脸录入
HDL_ON/DAL/Server/NewAPI.cs
@@ -734,6 +734,10 @@
        #region  ■  -- SIP相关接口_______________________________
        #endregion
        /// <summary>
        /// 绑定source面板
        /// </summary>
        public const string Api_Post_BindSourcePanel = "/home-wisdom/source/screen/home/bind";
    }
HDL_ON/Entity/Function/Scene.cs
@@ -223,6 +223,18 @@
                return "SceneData_" + sid;
            }
        }
        /// <summary>
        /// 执行倒计时
        /// </summary>
        int countdownTime = 0;
        /// <summary>
        /// 重置执行倒计时
        /// </summary>
        public void ResetCountdownTime()
        {
            countdownTime = 0;
        }
        /// <summary>
        /// 场景执行\倒计时
        /// </summary>
@@ -232,31 +244,30 @@
            //场景正在倒计时执行中
            if (LastExecutionTime != "" && Convert.ToDouble(LastExecutionTime) + Convert.ToDouble(delay) > Convert.ToDouble(Utlis.GetTimestamp(false)))
            {
                int time = 0;
                int.TryParse(Convert.ToInt32(
                    Convert.ToDouble(LastExecutionTime) + Convert.ToDouble(delay) - Convert.ToDouble(Utlis.GetTimestamp(false))
                    ).ToString(), out time);
                if (time > 0)
                    ).ToString(), out countdownTime);
                if (countdownTime > 0)
                {
                    new System.Threading.Thread(() =>
                    {
                        if (time > 0)
                        if (countdownTime > 0)
                        {
                            while (time > 0)
                            while (countdownTime > 0)
                            {
                                Application.RunOnMainThread(() =>
                                {
                                    if (time > 60)
                                    if (countdownTime > 60)
                                    {
                                        btnShowDelay.Text = (time / 60).ToString() + "min" + time % 60 + "s";
                                        btnShowDelay.Text = (countdownTime / 60).ToString() + "min" + countdownTime % 60 + "s";
                                    }
                                    else
                                    {
                                        btnShowDelay.Text = time.ToString() + "s";
                                        btnShowDelay.Text = countdownTime.ToString() + "s";
                                    }
                                });
                                System.Threading.Thread.Sleep(1000);
                                time--;
                                countdownTime--;
                            }
                            Application.RunOnMainThread(() =>
                            {
@@ -317,6 +328,8 @@
            var revPack = pm.EditScene(this);
            if (revPack.Code == StateCode.SUCCESS)
            {
                //重置执行倒计时
                this.countdownTime = 0;
                if(MainPage.NoLoginMode)
                {
                    var ssd = System.Text.Encoding.UTF8.GetBytes(Newtonsoft.Json.JsonConvert.SerializeObject(this));
@@ -349,6 +362,7 @@
            var revPack = pm.EditScene(this);
            if (revPack.Code == StateCode.SUCCESS)
            {
                this.countdownTime = 0;
                var scenes = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Scene>>(revPack.Data.ToString());
                var tempScene = scenes.Find((obj) => obj.sid == sid);
                if (tempScene != null)
HDL_ON/UI/MainPage.cs
@@ -33,7 +33,7 @@
    //public static string ClientType = APIClientType.HDL_ON_PRO.ToString();
    /// <summary>
    ///
    ///
    /// </summary>
    public static Entity.CityInfo cityInfo = new Entity.CityInfo();
    /// <summary>
@@ -86,8 +86,84 @@
    /// </summary>
    public static bool Increase
    {
      get
      {
        /// <summary>
        /// BaseView
        /// </summary>
        public static FrameLayout BaseView { get; internal set; }
        /// <summary>
        /// BasePageView
        /// </summary>
        public static PageLayout BasePageView { get; set; }
        /// <summary>
        /// 用户控制父容器
        /// </summary>
        public static UserPage UserBasePage;
        /// <summary>
        /// 版本号
        /// </summary>
        public static string VersionString = "1.3.1123";
        ///// <summary>
        ///// 客户端类型
        ///// </summary>
        //public static string ClientType = APIClientType.HDL_ON_PRO.ToString();
        /// <summary>
        ///
        /// </summary>
        public static Entity.CityInfo cityInfo = new Entity.CityInfo();
        /// <summary>
        /// 天气刷新action
        /// </summary>
        public static Action RefreshAir;
        /// <summary>
        /// 回退页面action 没有需要可以不用
        /// </summary>
        public static Action ReturnRefreshAction;
        /// <summary>
        /// 无登录模式
        /// </summary>
        public static bool NoLoginMode = false;
        /// <summary>
        /// 网络连接状态
        /// 0:无网络
        /// </summary>
        public static int InternetStatus = 2;
        /// <summary>
        /// 是否进入后台
        /// </summary>
        public static bool IsEnterBackground = false;
        /// <summary>
        /// 当前分页索引
        /// 0:收藏
        /// 1:分类
        /// 2:智能
        /// 3:个人
        /// </summary>
        public static int CurPageIndex = 9999;
        ///// <summary>
        ///// 公司代码
        ///// 预留第三方定制标记
        ///// 0:HDL
        ///// </summary>
        //public static int Company = 0;
        /// <summary>
        /// 右滑后退提示按钮
        /// </summary>
        public static Button BtnBackIcon;
        /// <summary>
        /// 后退右滑了多少距离,超过一定距离才触发后退事件
        /// </summary>
        public static int StartX = 0;
        /// <summary>
        /// 是否全面屏手机
        /// </summary>
        public static bool Increase
        {
            get
            {
#if __IOS__
                if (Application.PhoneType>10)
                {
HDL_ON/UI/UI0-Public/PublicAssmebly.cs
@@ -412,14 +412,15 @@
            })
            { IsBackground = true }.Start();
        }
        /// <summary>
        /// 加载提示弹窗
        /// </summary>
        /// <param name="titleId"></param>
        /// <param name="msgId"></param>
        public void TipMsg(int titleId, int msgId,Action action = null)
        /// <param name="title"></param>
        /// <param name="msg"></param>
        /// <param name="action"></param>
        public void TipMsg(string title, string msg, Action action = null)
        {
            Dialog dialog = new Dialog()
            {
                BackgroundColor = CSS_Color.DialogTransparentColor1,
@@ -445,7 +446,7 @@
                TextSize = CSS_FontSize.SubheadingFontSize,
                TextAlignment = TextAlignment.Center,
                IsBold = true,
                TextID = titleId,
                Text = title
            };
            contentView.AddChidren(btnTitle);
@@ -458,7 +459,7 @@
                TextAlignment = TextAlignment.Center,
                TextColor = CSS_Color.TextualColor,
                TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                TextID = msgId,
                Text = msg,
                IsMoreLines = true,
            };
            contentView.AddChidren(btnMsg);
@@ -499,6 +500,18 @@
        }
        /// <summary>
        /// 加载提示弹窗
        /// </summary>
        /// <param name="titleId"></param>
        /// <param name="msgId"></param>
        public void TipMsg(int titleId, int msgId, Action action = null)
        {
            TipMsg(Language.StringByID(titleId), Language.StringByID(msgId), action);
        }
        /// <summary>
        /// 加载等待界面
        /// </summary>
HDL_ON/UI/UI1-Login/LoginPage.cs
@@ -225,7 +225,6 @@
                    //etAccount.Text = "13415629083";
                    //etAccount.Text = "13676202754";//巴林服务器
                    //etAccount.Text = "13602944661";//kx
                    etAccount.Text = "551775569@qq.com";//wcf
                    //etAccount.Text = "18666455392";//13375012446//13602944661//tzy 18778381374
                    //etAccount.Text = "15971583093";//高胜
                    //etAccount.Text = "15217626103";//昆明金茂项目
@@ -239,6 +238,7 @@
                    //etAccount.Text = "support5@hdlchina.com.cn";
                    //etAccount.Text = "13375012441";
                    etAccount.Text = "info@smartlife-ks.com";
                    etAccount.Text = "551775569@qq.com";//wcf
                }
                b = !b;
                etPassword.Text = "123456";
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs
@@ -851,55 +851,55 @@
            #endregion
            #region 获取支持
            FrameLayout supView = new FrameLayout()
            {
                Height = Application.GetRealWidth(44),
                BackgroundColor = 0xFFFF0000,
            };
            supportView.AddChidren(supView);
            supView.MouseUpEventHandler = (sender, e) => {
                Dialog dialog = new Dialog();
            //FrameLayout supView = new FrameLayout()
            //{
            //    Height = Application.GetRealWidth(44),
            //    BackgroundColor = 0xFFFF0000,
            //};
            //supportView.AddChidren(supView);
            //supView.MouseUpEventHandler = (sender, e) => {
            //    Dialog dialog = new Dialog();
                var bodyView = new FrameLayout();
                dialog.AddChidren(bodyView);
            //    var bodyView = new FrameLayout();
            //    dialog.AddChidren(bodyView);
                var contentView = new VerticalScrolViewLayout()
                {
                    Height = Application.GetRealHeight(600),
                    BackgroundColor = CSS_Color.MainBackgroundColor,
                };
                bodyView.AddChidren(contentView);
            //    var contentView = new VerticalScrolViewLayout()
            //    {
            //        Height = Application.GetRealHeight(600),
            //        BackgroundColor = CSS_Color.MainBackgroundColor,
            //    };
            //    bodyView.AddChidren(contentView);
                var btnClose = new Button()
                {
                    Y = Application.GetRealHeight(600),
                    Height = Application.GetRealHeight(67),
                    BackgroundColor = CSS_Color.WarningColor,
                    Text = "关 闭",
                    TextAlignment = TextAlignment.CenterLeft,
                    TextSize = CSS_FontSize.SubheadingFontSize,
                };
                btnClose.MouseUpEventHandler = (sender1, e1) => {
                    dialog.Close();
                };
                bodyView.AddChidren(btnClose);
            //    var btnClose = new Button()
            //    {
            //        Y = Application.GetRealHeight(600),
            //        Height = Application.GetRealHeight(67),
            //        BackgroundColor = CSS_Color.WarningColor,
            //        Text = "关 闭",
            //        TextAlignment = TextAlignment.CenterLeft,
            //        TextSize = CSS_FontSize.SubheadingFontSize,
            //    };
            //    btnClose.MouseUpEventHandler = (sender, e) => {
            //        dialog.Close();
            //    };
            //    bodyView.AddChidren(btnClose);
                foreach (var msg in Control.Ins.MsgInfoList)
                {
                    var et = new TextView()
                    {
                        IsMoreLines = true,
                        Height = Application.GetRealHeight(150),
                        Width = Application.GetRealWidth(300),
                        TextColor = CSS_Color.FirstLevelTitleColor,
                        TextSize = CSS_FontSize.TextFontSize,
                        Text = msg,
                    };
                    contentView.AddChidren(et);
                }
            //    foreach (var msg in Control.Ins.MsgInfoList)
            //    {
            //        var et = new TextView()
            //        {
            //            IsMoreLines = true,
            //            Height = Application.GetRealHeight(150),
            //            Width = Application.GetRealWidth(300),
            //            TextColor = CSS_Color.FirstLevelTitleColor,
            //            TextSize = CSS_FontSize.TextFontSize,
            //            Text = msg,
            //        };
            //        contentView.AddChidren(et);
            //    }
                dialog.Show();
            };
            //    dialog.Show();
            //};
            //Button btnSupportIcon = new Button()
            //{
HDL_ON/UI/UI2/4-PersonalCenter/PersonalDataPage.cs
@@ -1,4 +1,5 @@
    using System;
using HDL_ON.DAL.Server;
using HDL_ON.UI;
using HDL_ON.UI.CSS;
using Shared;
@@ -553,7 +554,7 @@
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.FirstLevelTitleColor,
                TextSize = CSS_FontSize.SubheadingFontSize,
                TextID = StringId.AddResidence,
                TextID = StringId.ScanQRCoden,
            };
            addResidenceView.AddChidren(btnAddResidenceText);
@@ -561,17 +562,78 @@
            {
                Scan.OpenScan((scanString) =>
                {
                    //执行绑定住宅
                    new BindingResidencePage().DoBindResidence(scanString);
                    if (scanString.StartsWith("source://bind/"))
                    {
                                var waitPage = new Loading();
                        new System.Threading.Thread(() =>
                        {
                            try
                            {
                                Application.RunOnMainThread(() =>
                                {
                                    waitPage.Start("Plaese wait...");
                                });
                                var sendString = scanString.Replace("source://bind/", "");
                                MainPage.Log($"绑定source屏:{sendString}");
                                //绑定source屏
                                var pack = new HttpServerRequest().BindSourcePanel(sendString);
                                Application.RunOnMainThread(() =>
                                {
                                    var title = Language.StringByID(StringId.Tip);
                                    var msg = "";
                                   if(pack.Code == StateCode.SUCCESS)
                                    {
                                        if(Language.CurrentLanguage=="Chinese")
                                        {
                                            msg = "Source屏绑定成功.";
                                        }
                                        else
                                        {
                                            msg = "Source Hub binding succeeded";
                                        }
                                        new HDL_ON.UI.PublicAssmebly().TipMsg(title, msg);
                                    }
                                    else
                                    {
                                        if (Language.CurrentLanguage == "Chinese")
                                        {
                                            msg = $"Source屏绑定失败.({pack.Code})";
                                        }
                                        else
                                        {
                                            msg = "Source Hub binding failed";
                                        }
                                        new HDL_ON.UI.PublicAssmebly().TipMsg(title, msg);
                                    }
                                });
                            }
                            catch(Exception ex)
                            { }
                            finally
                            {
                                Application.RunOnMainThread(() =>
                                {
                                    waitPage.Hide();
                                });
                            }
                        })
                        { IsBackground = true }.Start();
                    }
                    else
                    {
                        //执行绑定住宅
                        new BindingResidencePage().DoBindResidence(scanString);
                    }
                });
            };
            optionListView.AddChidren(new Button() { X = Application.GetRealWidth(16), Height = Application.GetRealHeight(1), Width = Application.GetRealWidth(343), BackgroundColor = CSS_Color.DividingLineColor });
            #endregion
            if (Entity.DB_ResidenceData.Instance.SupportFacePass)
            {
                #region 个人选项-人脸通行管理
                optionListView.AddChidren(new Button() { X = Application.GetRealWidth(16), Height = Application.GetRealHeight(1), Width = Application.GetRealWidth(343), BackgroundColor = CSS_Color.DividingLineColor });
                faceManagementView = new FrameLayout()
                {
                    Height = Application.GetRealHeight(50),
HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs
@@ -52,9 +52,13 @@
        AC acFunction = new AC();
        /// <summary>
        /// app自己控制的温度数值记录
        /// 控制时间
        /// </summary>
        List<string> seltControlTemp = new List<string>();
        DateTime controlTime = DateTime.MinValue.AddDays(10);
        /// <summary>
        /// 控制温度
        /// </summary>
        int temp = 16;
        #endregion
@@ -92,7 +96,19 @@
            //读取状态
            new System.Threading.Thread(() =>
            {
                Control.Ins.SendReadCommand(device);
                while (true)
                {
                    if(controlTime == DateTime.MinValue)
                    {
                    }
                    else if (controlTime.AddSeconds(2)<DateTime.Now)
                    {
                        Control.Ins.SendReadCommand(device);
                        controlTime = DateTime.MinValue;
                    }
                    System.Threading.Thread.Sleep(1000);
                }
            })
            { IsBackground = true }.Start();
        }
@@ -102,7 +118,7 @@
        /// </summary>
        private void InitFrameWhiteContent1()
        {
            temp = (int)Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp));
            arcBar = new DiyArcSeekBar()
            {
                Gravity = Gravity.CenterHorizontal,
@@ -829,13 +845,14 @@
                {
                    return;
                }
                var temp = (int)Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp));
                if (temp <= device.GetAttribute(FunctionAttributeKey.SetTemp).min)
                {
                    return;
                }
                temp--;
                seltControlTemp.Add(temp.ToString());
                --temp;
                Console.WriteLine($"temp == {temp}");
                controlTime = DateTime.Now;
                arcBar.Progress = temp;
                btnTemp.Text = temp.ToString();
                device.SetAttrState(FunctionAttributeKey.SetTemp, temp.ToString());
@@ -849,13 +866,12 @@
                {
                    return;
                }
                var temp = (int)Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp));
                if (temp >= device.GetAttribute(FunctionAttributeKey.SetTemp).max)
                {
                    return;
                }
                temp++;
                seltControlTemp.Add(temp.ToString());
                ++temp;
                controlTime = DateTime.Now;
                arcBar.Progress = temp;
                btnTemp.Text = temp.ToString();
                device.SetAttrState(FunctionAttributeKey.SetTemp, temp.ToString());
@@ -951,48 +967,49 @@
        {
            Application.RunOnMainThread(() =>
            {
                btnTemp.Text = Convert.ToDouble( device.GetAttrState(FunctionAttributeKey.SetTemp)).ToString();
                btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.RoomTemp))) + "°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);
                 var updataTemp = Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp)));
                //app自己控制的不用更新,会造成跳动
                if (seltControlTemp.Contains(updataTemp.ToString()))
                if (controlTime.AddSeconds(2) > DateTime.Now)
                {
                    seltControlTemp.Remove(updataTemp.ToString());
                    return;
                }
                else
                {
                    arcBar.Progress = updataTemp;
                }
                    btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.RoomTemp))) + "°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)));
                if (device.trait_on_off.curValue.ToString() == "on")
                {
                    btnMode.IsSelected = btnSwing.IsSelected = btnWindSpeed.IsSelected = true;
                    arcBar.IsOffline = false;
                    btnSwitch.IsSelected = true;
                    arcBar.ThumbImagePath = "FunctionIcon/AC/DiyThumbIconOn.png";
                    if (device.GetAttrState(FunctionAttributeKey.Mode) == "fan")
                    arcBar.Progress = temp;
                    btnTemp.Text = temp.ToString() ;
                    if (device.trait_on_off.curValue.ToString() == "on")
                    {
                        arcBar.IsClickable = false;
                        btnMode.IsSelected = btnSwing.IsSelected = btnWindSpeed.IsSelected = true;
                        arcBar.IsOffline = false;
                        btnSwitch.IsSelected = true;
                        arcBar.ThumbImagePath = "FunctionIcon/AC/DiyThumbIconOn.png";
                        if (device.GetAttrState(FunctionAttributeKey.Mode) == "fan")
                        {
                            arcBar.IsClickable = false;
                        }
                        else
                        {
                            arcBar.IsClickable = true;
                        }
                    }
                    else
                    {
                        arcBar.IsClickable = true;
                        btnMode.IsSelected = btnSwing.IsSelected = btnWindSpeed.IsSelected = false;
                        arcBar.IsOffline = true;
                        btnSwitch.IsSelected = false;
                        arcBar.IsClickable = false;
                        arcBar.ThumbImagePath = "FunctionIcon/AC/DiyThumbIcon.png";
                    }
                }
                else
                {
                    btnMode.IsSelected = btnSwing.IsSelected = btnWindSpeed.IsSelected = false;
                    arcBar.IsOffline = true;
                    btnSwitch.IsSelected = false;
                    arcBar.IsClickable = false;
                    arcBar.ThumbImagePath = "FunctionIcon/AC/DiyThumbIcon.png";
                }
            });
HDL_ON/UI/UI2/FuntionControlView/Curtain/RollingShutterPage.cs
@@ -145,7 +145,7 @@
                Height = Application.GetRealHeight(50),
                TextSize = CSS_FontSize.TextFontSize,
                TextColor = CSS_Color.PromptingColor1,
                Text = curtainTemp.GetPercent(function).ToString() + "%",
                Text =  curtainTemp.GetPercent(function).ToString() + "%",
            };
            controlView.AddChidren(btnProgress);
@@ -157,7 +157,7 @@
                Height = Application.GetRealWidth(210),
                Progress = curtainTemp.GetPercent(function),
                //IsInvertedProgress = true,
                ProgressTextColor = 0x00000000,
                ProgressTextColor = CSS_Color.WarningColor,// 0x00000000,
            };
            controlView.AddChidren(curtainSeekBar);
HDL_ON/UI/UI2/FuntionControlView/Curtain/RollingShutterPageBLL.cs
@@ -26,10 +26,14 @@
                    //bodyView.btnCurtainClose.IsSelected = percent == 0;
                    try
                    {
                        if (!bodyView.onCurtainAnimation)
                        {
                            bodyView.CurtainAnimation(Convert.ToInt32(updateTemp.GetAttrState(FunctionAttributeKey.Percent)));
                        }
                        var progress = Convert.ToInt32(updateTemp.GetAttrState(FunctionAttributeKey.Percent));
                        bodyView.curtainSeekBar.Progress = progress;
                        bodyView.btnProgress.Text =  progress + "%";
                        //if (!bodyView.onCurtainAnimation)
                        //{
                        //    bodyView.CurtainAnimation(Convert.ToInt32(updateTemp.GetAttrState(FunctionAttributeKey.Percent)));
                        //}
                    }
                    catch { }
                }
@@ -148,7 +152,7 @@
                System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
                d.Add(FunctionAttributeKey.OnOff, function.trait_on_off.curValue.ToString());
                DriverLayer.Control.Ins.SendWriteCommand(function, d);
                CurtainAnimation(0);
                //CurtainAnimation(100);
            };
            btnCurtainStop.MouseUpEventHandler = (sender, e) =>
@@ -183,7 +187,7 @@
                System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
                d.Add(FunctionAttributeKey.OnOff, function.trait_on_off.curValue.ToString());
                DriverLayer.Control.Ins.SendWriteCommand(function, d);
                CurtainAnimation(100);
                //CurtainAnimation(0);
            };
            //btnMinusSignIcon.MouseUpEventHandler = (sender, e) =>
HDL_ON/UI/UI2/FuntionControlView/Light/ColorTureLampPage.cs
@@ -37,7 +37,7 @@
        /// <summary>
        /// 渐变时间修改
        /// </summary>
        //DiyImageSeekBar barFadeTime;
        DiyImageSeekBar barFadeTime;
        /// <summary>
        /// 色温的滑动控件
        /// </summary>
@@ -170,7 +170,72 @@
                TextSize = CSS_FontSize.PromptFontSize_SecondaryLevel,
                Text = Convert.ToInt32(function.GetAttrState(FunctionAttributeKey.Brightness)) + "%",
            };
            controlView.AddChidren(btnBrightnessText);
            controlView.AddChidren(btnBrightnessText);
            #region 渐变时间调节
            if (function.GetAttribute(FunctionAttributeKey.FadeTime) != null)
            {
                var btnGradualChangeText = new Button()
                {
                    X = Application.GetRealWidth(35),
                    Y = Application.GetRealHeight(306 + 40),
                    Width = Application.GetRealWidth(224),
                    Height = Application.GetRealHeight(21),
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.FirstLevelTitleColor,
                    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                    TextID = StringId.SpeedOfChange,
                };
                controlView.AddChidren(btnGradualChangeText);
                var btnGradualChangeMinValuesText = new Button()
                {
                    X = Application.GetRealWidth(35),
                    Y = btnGradualChangeText.Bottom + Application.GetRealHeight(5),
                    Width = Application.GetRealWidth(22),
                    Height = Application.GetRealHeight(21),
                    Text = "0s",
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.PromptingColor1,
                    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                };
                controlView.AddChidren(btnGradualChangeMinValuesText);
                barFadeTime = new DiyImageSeekBar()
                {
                    X = btnGradualChangeMinValuesText.Right,
                    Y = Application.GetRealHeight(360),
                    Width = Application.GetRealWidth(210),
                    Height = Application.GetRealHeight(54),
                    SeekBarViewHeight = Application.GetRealHeight(8),
                    ThumbImagePath = "Public/ThumbImage.png",
                    ThumbImageHeight = Application.GetRealHeight(54),
                    ProgressBarColor = CSS_Color.MainColor,
                    ProgressTextColor = CSS_Color.FirstLevelTitleColor,
                    ProgressTextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                    ProgressBarUnitSring = "s",
                    MaxValue = 10,
                    Progress = Convert.ToInt32(function.GetAttrState(FunctionAttributeKey.FadeTime)),
                    SeekBarPadding = Application.GetRealWidth(20),
                };
                controlView.AddChidren(barFadeTime);
                var btnGradualChangeMaxValuesText = new Button()
                {
                    X = barFadeTime.Right,
                    Y = btnGradualChangeText.Bottom + Application.GetRealHeight(5),
                    Width = Application.GetRealWidth(35),
                    Height = Application.GetRealHeight(21),
                    Text = "10s",
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.PromptingColor1,
                    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                };
                controlView.AddChidren(btnGradualChangeMaxValuesText);
            }
            #endregion
            #region 色温
            var cctAttr = function.GetAttribute(FunctionAttributeKey.CCT);
@@ -186,7 +251,7 @@
            //色温
            var btnTempClolor = new Button();
            btnTempClolor.X = Application.GetRealWidth(35);
            btnTempClolor.Y = Application.GetRealHeight(306 + 60);
            btnTempClolor.Y = Application.GetRealHeight(395);
            btnTempClolor.Width = Application.GetRealWidth(224);
            btnTempClolor.Height = Application.GetRealHeight(21);
            btnTempClolor.TextAlignment = TextAlignment.CenterLeft;
@@ -249,66 +314,6 @@
            btnTempClolorMax.TextSize = CSS_FontSize.PromptFontSize_FirstLevel;
            controlView.AddChidren(btnTempClolorMax);
            #endregion
            #region 渐变时间调节
            //var btnGradualChangeText = new Button()
            //{
            //    X = Application.GetRealWidth(35),
            //    Y = Application.GetRealHeight(385),
            //    Width = Application.GetRealWidth(224),
            //    Height = Application.GetRealHeight(21),
            //    TextAlignment = TextAlignment.CenterLeft,
            //    TextColor = CSS_Color.FirstLevelTitleColor,
            //    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
            //    TextID = StringId.SpeedOfChange,
            //};
            //controlView.AddChidren(btnGradualChangeText);
            //var btnGradualChangeMinValuesText = new Button()
            //{
            //    X = Application.GetRealWidth(35),
            //    Y = btnGradualChangeText.Bottom + Application.GetRealHeight(8),
            //    Width = Application.GetRealWidth(22),
            //    Height = Application.GetRealHeight(21),
            //    Text = "0s",
            //    TextAlignment = TextAlignment.CenterLeft,
            //    TextColor = CSS_Color.PromptingColor1,
            //    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
            //};
            //controlView.AddChidren(btnGradualChangeMinValuesText);
            //barFadeTime = new DiyImageSeekBar()
            //{
            //    X = btnGradualChangeMinValuesText.Right,
            //    Y = Application.GetRealHeight(412 - 21) + Application.GetRealHeight(8),
            //    Width = Application.GetRealWidth(210),
            //    Height = Application.GetRealHeight(54),
            //    SeekBarViewHeight = Application.GetRealHeight(8),
            //    ThumbImagePath = "Public/ThumbImage.png",
            //    ThumbImageHeight = Application.GetRealHeight(54),
            //    ProgressBarColor = CSS_Color.MainColor,
            //    ProgressTextColor = CSS_Color.FirstLevelTitleColor,
            //    ProgressTextSize = CSS_FontSize.PromptFontSize_FirstLevel,
            //    ProgressBarUnitSring = "s",
            //    MaxValue = 10,
            //    Progress = function.fadeTime,
            //    SeekBarPadding = Application.GetRealWidth(20),
            //};
            //controlView.AddChidren(barFadeTime);
            //var btnGradualChangeMaxValuesText = new Button()
            //{
            //    X = barFadeTime.Right,
            //    Y = btnGradualChangeText.Bottom + Application.GetRealHeight(8),
            //    Width = Application.GetRealWidth(35),
            //    Height = Application.GetRealHeight(21),
            //    Text = "10s",
            //    TextAlignment = TextAlignment.CenterLeft,
            //    TextColor = CSS_Color.PromptingColor1,
            //    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
            //};
            //controlView.AddChidren(btnGradualChangeMaxValuesText);
            #endregion
            btnSwitch = new Button()
HDL_ON/UI/UI2/FuntionControlView/Light/ColorTureLampPageBLL.cs
@@ -25,7 +25,7 @@
                            bodyView.dimmerBar.SetProgressBarColors(CSS_Color.AuxiliaryColor1, CSS_Color.AuxiliaryColor1);
                            if (!bodyView.onDimmerBar)
                            {
                                bodyView.dimmerBar.Progress = Convert.ToInt32( updataTemp.GetAttrState(FunctionAttributeKey.Brightness));
                                bodyView.dimmerBar.Progress = Convert.ToInt32(updataTemp.GetAttrState(FunctionAttributeKey.Brightness));
                            }
                            bodyView.btnBrightnessText.Text = updataTemp.GetAttrState(FunctionAttributeKey.Brightness) + "%";
                            bodyView.btnBrightnessText.Y = ((100 - Convert.ToInt32(updataTemp.GetAttrState(FunctionAttributeKey.Brightness))) * Application.GetRealHeight(222 - 16) / 100) + Application.GetRealWidth(80);
@@ -59,7 +59,8 @@
            LoadEvet_ChangeFadeTime();
            LoadEvet_ChangeColorTemplatrue();
            //回退刷新信息事件
            actionRefresh = () => {
            actionRefresh = () =>
            {
                btnFunctionName.Text = btnFunctionName_Out.Text = function.name;
                btnFromFloor_Out.Text = btnFromFoorAndRoom.Text = function.GetRoomListName();
                //function.SaveFunctionData(true);
@@ -70,11 +71,14 @@
        /// </summary>
        void LoadEvet_ChangeFadeTime()
        {
            //barFadeTime.OnStopTrackingTouchEvent = (sender, e) =>
            //{
            //    function.fadeTime = e;
            //    function.SaveFunctionData(true);
            //};
            if (function.GetAttribute(FunctionAttributeKey.FadeTime) != null)
            {
                barFadeTime.OnStopTrackingTouchEvent = (sender, e) =>
                {
                    function.SetAttrState(FunctionAttributeKey.FadeTime, e.ToString());
                    function.SaveFunctionFile();
                };
            }
        }
        /// <summary>
@@ -205,7 +209,6 @@
                    function.trait_on_off.curValue = btnSwitch.IsSelected ? "on" : "off";
                    System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
                    d.Add(FunctionAttributeKey.OnOff, function.trait_on_off.curValue.ToString());
                    d.Add(FunctionAttributeKey.FadeTime, function.GetAttrState(FunctionAttributeKey.FadeTime));
                    if (btnSwitch.IsSelected)
                    {
                        d.Add(FunctionAttributeKey.Brightness, function.lastBrightness.ToString());
HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPage.cs
@@ -166,74 +166,82 @@
            };
            controlView.AddChidren(btnBrightnessText);
            #region 渐变时间调节
            var btnGradualChangeText = new Button()
            if (function.GetAttribute(FunctionAttributeKey.FadeTime) != null)
            {
                X = Application.GetRealWidth(35),
                Y = Application.GetRealHeight(385),
                Width = Application.GetRealWidth(224),
                Height = Application.GetRealHeight(21),
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.FirstLevelTitleColor,
                TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                TextID = StringId.SpeedOfChange,
                Visible = function.GetAttribute(FunctionAttributeKey.FadeTime)!= null,
                Enable = function.GetAttribute(FunctionAttributeKey.FadeTime)!= null,
            };
            controlView.AddChidren(btnGradualChangeText);
                #region 渐变时间调节
            var btnGradualChangeMinValuesText = new Button()
            {
                X = Application.GetRealWidth(35),
                Y = btnGradualChangeText.Bottom+ Application.GetRealHeight(8),
                Width = Application.GetRealWidth(22),
                Height = Application.GetRealHeight(21),
                Text = "0s",
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.PromptingColor1,
                TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                Visible = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                Enable = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
            };
            controlView.AddChidren(btnGradualChangeMinValuesText);
                var btnGradualChangeText = new Button()
                {
                    X = Application.GetRealWidth(35),
                    Y = Application.GetRealHeight(385),
                    Width = Application.GetRealWidth(224),
                    Height = Application.GetRealHeight(21),
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.FirstLevelTitleColor,
                    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                    TextID = StringId.SpeedOfChange,
                    Visible = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                    Enable = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                };
                controlView.AddChidren(btnGradualChangeText);
            barFadeTime = new DiyImageSeekBar()
            {
                X = btnGradualChangeMinValuesText.Right,
                Y = Application.GetRealHeight(412 - 21) + Application.GetRealHeight(8),
                Width = Application.GetRealWidth(210),
                Height = Application.GetRealHeight(54),
                SeekBarViewHeight = Application.GetRealHeight(8),
                ThumbImagePath = "Public/ThumbImage.png",
                ThumbImageHeight = Application.GetRealHeight(54),
                ProgressBarColor = CSS_Color.MainColor,
                ProgressTextColor = CSS_Color.FirstLevelTitleColor,
                ProgressTextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                ProgressBarUnitSring = "s",
                MaxValue = 10,
                Progress = Convert.ToInt32(function.GetAttrState(FunctionAttributeKey.FadeTime)),
                SeekBarPadding = Application.GetRealWidth(20),
                Visible = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                Enable = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
            };
            controlView.AddChidren(barFadeTime);
                var btnGradualChangeMinValuesText = new Button()
                {
                    X = Application.GetRealWidth(35),
                    Y = btnGradualChangeText.Bottom + Application.GetRealHeight(8),
                    Width = Application.GetRealWidth(22),
                    Height = Application.GetRealHeight(21),
                    Text = "0s",
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.PromptingColor1,
                    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                    Visible = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                    Enable = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                };
                controlView.AddChidren(btnGradualChangeMinValuesText);
            var btnGradualChangeMaxValuesText = new Button()
            {
                X = barFadeTime.Right,
                Y = btnGradualChangeText.Bottom + Application.GetRealHeight(8),
                Width = Application.GetRealWidth(35),
                Height = Application.GetRealHeight(21),
                Text = "10s",
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.PromptingColor1,
                TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                Visible = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                Enable = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
            };
            controlView.AddChidren(btnGradualChangeMaxValuesText);
            #endregion
                barFadeTime = new DiyImageSeekBar()
                {
                    X = btnGradualChangeMinValuesText.Right,
                    Y = Application.GetRealHeight(412 - 21) + Application.GetRealHeight(8),
                    Width = Application.GetRealWidth(210),
                    Height = Application.GetRealHeight(54),
                    SeekBarViewHeight = Application.GetRealHeight(8),
                    ThumbImagePath = "Public/ThumbImage.png",
                    ThumbImageHeight = Application.GetRealHeight(54),
                    ProgressBarColor = CSS_Color.MainColor,
                    ProgressTextColor = CSS_Color.FirstLevelTitleColor,
                    ProgressTextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                    ProgressBarUnitSring = "s",
                    MaxValue = 10,
                    Progress = Convert.ToInt32(function.GetAttrState(FunctionAttributeKey.FadeTime)),
                    SeekBarPadding = Application.GetRealWidth(20),
                    Visible = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                    Enable = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                };
                controlView.AddChidren(barFadeTime);
                barFadeTime.OnStopTrackingTouchEvent = (sender, e) =>
                {
                    function.SetAttrState(FunctionAttributeKey.FadeTime, e.ToString());
                    function.UpdataFuncitonInfo();
                };
                var btnGradualChangeMaxValuesText = new Button()
                {
                    X = barFadeTime.Right,
                    Y = btnGradualChangeText.Bottom + Application.GetRealHeight(8),
                    Width = Application.GetRealWidth(35),
                    Height = Application.GetRealHeight(21),
                    Text = "10s",
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.PromptingColor1,
                    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                    Visible = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                    Enable = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                };
                controlView.AddChidren(btnGradualChangeMaxValuesText);
                #endregion
            }
            btnSwitch = new Button()
            {
                Gravity = Gravity.CenterHorizontal,
HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPageBLL.cs
@@ -62,11 +62,14 @@
        /// </summary>
        void LoadEvet_ChangeFadeTime()
        {
            barFadeTime.OnStopTrackingTouchEvent = (sender, e) =>
            if (function.GetAttribute(FunctionAttributeKey.FadeTime) != null)
            {
                function.SetAttrState(FunctionAttributeKey.FadeTime, e.ToString());
                function.UpdataFuncitonInfo();
            };
                barFadeTime.OnStopTrackingTouchEvent = (sender, e) =>
                {
                    function.SetAttrState(FunctionAttributeKey.FadeTime, e.ToString());
                    function.SaveFunctionFile();
                };
            }
        }
        /// <summary>
@@ -91,7 +94,6 @@
            dimmerBar.OnStopTrackingTouchEvent = (sender, e) => {
                onDimmerBar = false;
                function.SetAttrState(FunctionAttributeKey.Brightness, dimmerBar.Progress);
                function.SetAttrState(FunctionAttributeKey.FadeTime, barFadeTime.Progress);
                System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
                d.Add(FunctionAttributeKey.Brightness, dimmerBar.Progress.ToString());
                Control.Ins.SendWriteCommand(function, d);
@@ -142,7 +144,6 @@
        {
            btnSwitch.MouseUpEventHandler += (sender, e) =>
            {
                function.SetAttrState(FunctionAttributeKey.FadeTime, barFadeTime.Progress);
                btnSwitch.IsSelected = !btnSwitch.IsSelected;
                if (btnSwitch.IsSelected)
                {
@@ -157,7 +158,6 @@
                    function.trait_on_off.curValue = btnSwitch.IsSelected ? "on" : "off";
                    System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
                    d.Add(FunctionAttributeKey.OnOff, function.trait_on_off.curValue.ToString());
                    d.Add(FunctionAttributeKey.FadeTime, function.GetAttrState(FunctionAttributeKey.FadeTime));
                    if (btnSwitch.IsSelected)
                    {
                        if(function.lastBrightness == 0)
HDL_ON/UI/UI2/FuntionControlView/Light/RGBPage.cs
@@ -242,6 +242,8 @@
            controlView.AddChidren(btnMaxValuesText);
            #endregion
            if (function.GetAttribute(FunctionAttributeKey.FadeTime) != null)
            {
                #region 渐变时间调节
                var btnGradualChangeText = new Button()
                {
@@ -294,6 +296,11 @@
                    Enable = function.GetAttribute(FunctionAttributeKey.FadeTime) != null,
                };
                controlView.AddChidren(barFadeTime);
                barFadeTime.OnStopTrackingTouchEvent = (sender, e) =>
                {
                    function.SetAttrState(FunctionAttributeKey.FadeTime, barFadeTime.Progress);
                    function.UpdataFuncitonInfo();
                };
                var btnGradualChangeMaxValuesText = new Button()
                {
@@ -311,6 +318,7 @@
                controlView.AddChidren(btnGradualChangeMaxValuesText);
                #endregion
            }
            btnRestoredPoint = new Button()
            {
                X = Application.GetRealWidth(116),
HDL_ON/UI/UI2/FuntionControlView/Light/RGBPageBLL.cs
@@ -260,11 +260,14 @@
        /// </summary>
        void LoadEvet_ChangeFadeTime()
        {
            barFadeTime.OnStopTrackingTouchEvent = (sender, e) =>
            if (function.GetAttribute(FunctionAttributeKey.FadeTime) != null)
            {
                function.SetAttrState(FunctionAttributeKey.FadeTime, barFadeTime.Progress);
                function.UpdataFuncitonInfo();
            };
                barFadeTime.OnStopTrackingTouchEvent = (sender, e) =>
                {
                    function.SetAttrState(FunctionAttributeKey.FadeTime, e.ToString());
                    function.SaveFunctionFile();
                };
            }
        }
        /// <summary>
        /// 加载开关事件
@@ -281,7 +284,6 @@
                    function.trait_on_off.curValue = btnSwitch.IsSelected ? "on" : "off";
                    System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
                    d.Add(FunctionAttributeKey.OnOff, function.trait_on_off.curValue.ToString());
                    d.Add(FunctionAttributeKey.FadeTime, function.GetAttrState(FunctionAttributeKey.FadeTime));
                    if (btnSwitch.IsSelected)
                    {
                        if(function.lastBrightness == 0)