wxr
2021-12-13 b5f1a194d354ba9b2587c59ae17cf38d0f7f9bac
二维码闪退问题
3个文件已修改
167 ■■■■ 已修改文件
.vs/HDL_APP_Project/xs/UserPrefs.xml 42 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Scan.cs 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/PersonalDataPage.cs 120 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
.vs/HDL_APP_Project/xs/UserPrefs.xml
@@ -1,44 +1,31 @@
<Properties StartupConfiguration="{D998E133-F0DD-4760-BE3C-461632F54DA4}|Default">
<Properties StartupConfiguration="{09712674-2A38-407B-B1E2-560B2C352F9A}|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/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs">
    <Files>
      <File FileName="HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs" Line="296" Column="63" />
      <File FileName="HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalSensorPage.cs" />
      <File FileName="HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalPage.cs" />
      <File FileName="HDL_ON/Entity/Function/Function.cs" />
      <File FileName="HDL_ON/DAL/Server/HttpServerRequest.cs" />
      <File FileName="HDL_ON/UI/UI2/1-HomePage/HomePage.cs" />
      <File FileName="HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs" />
      <File FileName="HDL_ON/DAL/DriverLayer/Control.cs" />
      <File FileName="HDL_ON/Entity/FunctionList.cs" />
      <File FileName="HDL_ON/DAL/Mqtt/MqttClient.cs" />
      <File FileName="HDL_ON/UI/UI2/3-Intelligence/IntelligencePage.cs" />
      <File FileName="HDL_ON/Common/FileUtlis.cs" />
      <File FileName="HDL_ON/Common/ApiUtlis.cs" />
      <File FileName="HDL_ON/UI/UI2/UserPage.cs" />
      <File FileName="HDL-ON_iOS/Info.plist" />
    </Files>
  <MonoDevelop.Ide.Workbench>
    <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="BindingResidence" expanded="True" />
                <Node name="UI2" expanded="True">
                  <Node name="4-PersonalCenter" expanded="True">
                    <Node name="PersonalCenterPage.cs" selected="True" />
                    <Node name="MemberManagement" expanded="True" />
                  </Node>
                </Node>
              </Node>
            </Node>
            <Node name="HDL-ON_iOS" expanded="True" />
            <Node name="HDL-ON_Android" expanded="True">
              <Node name="Resources" expanded="True">
                <Node name="layout" expanded="True" />
              </Node>
              <Node name="Scan.cs" selected="True" />
            </Node>
            <Node name="SiriIntents" expanded="True">
              <Node name="Server" expanded="True" />
            </Node>
            <Node name="SiriIntentsUI" expanded="True" />
          </Node>
        </State>
      </Pad>
@@ -58,14 +45,13 @@
    <String>HDLSiriIntentsUI/HDLSiriIntentsUI.csproj</String>
    <String>HDLSiriKit/HDLSiriKit.csproj</String>
    <String>SiriBinding/SiriBinding.csproj</String>
    <String>HDL-ON_iOS/HDL-ON_iOS.csproj</String>
  </DisabledProjects>
  <MonoDevelop.Ide.Workspace ActiveConfiguration="Release|iPhone" />
  <MonoDevelop.Ide.ItemProperties.HDL-ON__Android PreferredExecutionTarget="Android.SelectDevice" />
  <MonoDevelop.Ide.Workspace ActiveConfiguration="Debug|iPhone" />
  <MonoDevelop.Ide.ItemProperties.HDL-ON__Android PreferredExecutionTarget="Android.364c4b3158493098" />
  <MonoDevelop.Ide.DebuggingService.Breakpoints>
    <BreakpointStore>
      <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/HdlSiriKit/SkipControl.cs" relfile="HdlSiriKit/SkipControl.cs" line="14" column="1" />
      <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddOutputPage.cs" relfile="HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddOutputPage.cs" line="333" column="1" />
      <Breakpoint file="/Users/nigemacpc/Desktop/On+/HDL-ON_iOS/ZXingOverlayView.cs" relfile="HDL-ON_iOS/ZXingOverlayView.cs" line="53" column="1" />
    </BreakpointStore>
  </MonoDevelop.Ide.DebuggingService.Breakpoints>
  <MultiItemStartupConfigurations />
HDL-ON_iOS/Scan.cs
@@ -49,9 +49,14 @@
            var result = await scanner.Scan();
            if (result != null)
            {
                action?.Invoke(result.Text);
            }
            else
            {
                action?.Invoke(null);
                Console.WriteLine("二维码返回值为null");
            }
        }
        public static byte[] BytesFromText(string text, int width = 300, int height = 300)
HDL_ON/UI/UI2/4-PersonalCenter/PersonalDataPage.cs
@@ -562,67 +562,73 @@
            {
                Scan.OpenScan((scanString) =>
                {
                    if (scanString.StartsWith("source://bind/"))
                    if (string.IsNullOrEmpty(scanString))
                    {
                                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);
                        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);
                        }
                    }
                });
            };