From d086dfbe17fa8444b6fd2ab1a97edf866c2091f1 Mon Sep 17 00:00:00 2001 From: dathlin Date: Wed, 25 Oct 2017 21:35:19 +0800 Subject: [PATCH] =?UTF-8?q?wpf=E6=88=91=E7=9A=84=E4=BF=A1=E6=81=AF?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E6=97=B6BUG=E4=BF=AE=E5=A4=8D=EF=BC=8C?= =?UTF-8?q?=E5=8F=B3=E4=BE=A7=E4=BF=A1=E6=81=AF=E6=94=AF=E6=8C=81=E5=B1=8F?= =?UTF-8?q?=E8=94=BD=EF=BC=8Cv1.7.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AccountSupport/FormAccountDetails.cs | 25 ++++++++-------- CommonLibrary/UserSystem.cs | 2 +- 软件系统客户端Wpf/MainWindow.xaml | 10 +++++-- 软件系统客户端Wpf/MainWindow.xaml.cs | 30 ++++++++++++------- 软件系统服务端模版/FormServerWindow.cs | 4 +-- 5 files changed, 41 insertions(+), 30 deletions(-) diff --git a/ClientsLibrary/AccountSupport/FormAccountDetails.cs b/ClientsLibrary/AccountSupport/FormAccountDetails.cs index 6b7b7e6..bd93516 100644 --- a/ClientsLibrary/AccountSupport/FormAccountDetails.cs +++ b/ClientsLibrary/AccountSupport/FormAccountDetails.cs @@ -277,23 +277,22 @@ namespace ClientsLibrary ms ); - if(result.IsSuccess) + if (result.IsSuccess) { - if(IsHandleCreated) Invoke(new Action(() => + try { - // 下载完成 - Bitmap bitmap = new Bitmap(ms); - pictureBox_UserPortrait.Image = bitmap; - - try + if (IsHandleCreated) Invoke(new Action(() => { + // 下载完成 + Bitmap bitmap = new Bitmap(ms); + pictureBox_UserPortrait.Image = bitmap; bitmap.Save(fileName); - } - catch - { - - } - })); + })); + } + catch + { + // 不知道什么原因 + } } else { diff --git a/CommonLibrary/UserSystem.cs b/CommonLibrary/UserSystem.cs index dc1d43e..a9fc767 100644 --- a/CommonLibrary/UserSystem.cs +++ b/CommonLibrary/UserSystem.cs @@ -44,7 +44,7 @@ namespace CommonLibrary **************************************************************************/ - SoftBasic.FrameworkVersion = new SystemVersion("1.7.0"); + SoftBasic.FrameworkVersion = new SystemVersion("1.7.1"); } diff --git a/软件系统客户端Wpf/MainWindow.xaml b/软件系统客户端Wpf/MainWindow.xaml index 0b6e3a5..a5bb6f3 100644 --- a/软件系统客户端Wpf/MainWindow.xaml +++ b/软件系统客户端Wpf/MainWindow.xaml @@ -112,7 +112,11 @@ - + + + + + @@ -192,8 +196,8 @@ - - + + diff --git a/软件系统客户端Wpf/MainWindow.xaml.cs b/软件系统客户端Wpf/MainWindow.xaml.cs index 2484744..8568ffb 100644 --- a/软件系统客户端Wpf/MainWindow.xaml.cs +++ b/软件系统客户端Wpf/MainWindow.xaml.cs @@ -28,9 +28,7 @@ namespace 软件系统客户端Wpf { - - - + /*************************************************************************************** * @@ -414,6 +412,18 @@ namespace 软件系统客户端Wpf } } + private void MenuItem窗口显示_Click(object sender, RoutedEventArgs e) + { + if (MainPageRight.Visibility != Visibility.Collapsed) + { + MainPageRight.Visibility = Visibility.Collapsed; + } + else + { + MainPageRight.Visibility = Visibility.Visible; + } + } + #endregion #region 异步网络块 @@ -448,10 +458,10 @@ namespace 软件系统客户端Wpf if (customer == CommonHeadCode.MultiNetHeadCode.弹窗新消息) { if (IsWindowShow) Dispatcher.Invoke(new Action(() => - { - FormPopup fpp = new FormPopup(data, System.Drawing.Color.DodgerBlue, 10000); - fpp.Show(); - })); + { + FormPopup fpp = new FormPopup(data, System.Drawing.Color.DodgerBlue, 10000); + fpp.Show(); + })); } else if (customer == CommonHeadCode.MultiNetHeadCode.总在线信息) { @@ -504,7 +514,7 @@ namespace 软件系统客户端Wpf TextBlock_ServerTime.Text = UserClient.DateTimeServer.ToString("yyyy-MM-dd HH:mm:ss"); TextBlock_FileCount.Text = json["FileCount"].ToObject().ToString(); UIControls_Chat.AddChatsHistory(sb.ToString()); - + NetAccount[] accounts = JArray.Parse(json["ClientsOnline"].ToString()).ToObject(); foreach (var m in accounts) @@ -545,7 +555,7 @@ namespace 软件系统客户端Wpf Views.Controls.UserClientRenderItem item = null; foreach (Views.Controls.UserClientRenderItem m in ClientsOnline.Children) { - if(m?.UniqueId == data) + if (m?.UniqueId == data) { item = m; } @@ -553,7 +563,7 @@ namespace 软件系统客户端Wpf if (item != null) ClientsOnline.Children.Remove(item); })); } - else if(customer == CommonHeadCode.MultiNetHeadCode.新头像更新) + else if (customer == CommonHeadCode.MultiNetHeadCode.新头像更新) { UserClient.PortraitManager.UpdateSmallPortraitByName(data); if (IsWindowShow) Dispatcher.Invoke(new Action(() => diff --git a/软件系统服务端模版/FormServerWindow.cs b/软件系统服务端模版/FormServerWindow.cs index a30d9be..f57b692 100644 --- a/软件系统服务端模版/FormServerWindow.cs +++ b/软件系统服务端模版/FormServerWindow.cs @@ -42,9 +42,7 @@ using 软件系统服务端模版.BasicSupport; /******************************************************************************************** * * 本项目模版不包含 《软件自动更新.exe》 - * 如需支持部署环境的自动升级 请联系hsl200909@163.com获取 - * 软件自动更新.exe 将绑定IP,端口和软件名称后授权销售,30元人民币一组,永久使用 - * 软件自动更新的部署提供长期的技术支持 + * 该exe程序来自另一个开源项目HslCommunication * ********************************************************************************************/