From 52e317b95d830f8cd1156b403ff5a34fb8f9bccb Mon Sep 17 00:00:00 2001
From: 陈嘉乐 <cjl@hdlchina.com.cn>
Date: 星期五, 31 七月 2020 17:43:42 +0800
Subject: [PATCH] 2020-7-31-2

---
 HDL_ON/UI/UI2/FuntionControlView/Music/View/DialogView.cs |   36 +++++++++++++++++++++---------------
 1 files changed, 21 insertions(+), 15 deletions(-)

diff --git a/HDL_ON/UI/UI2/FuntionControlView/Music/View/DialogView.cs b/HDL_ON/UI/UI2/FuntionControlView/Music/View/DialogView.cs
index 253b383..fe5d085 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/Music/View/DialogView.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/Music/View/DialogView.cs
@@ -216,6 +216,7 @@
                     string msg = Language.StringByID(StringId.addMusicList) + list.ListName;
                     new PublicAssmebly().TipMsgAutoClose(msg, false);
                 };
+                fileIconBtn.MouseUpEventHandler += click;
                 fileNameBtn.MouseUpEventHandler += click;
                 addFlieRow.MouseUpEventHandler += click;
             }
@@ -225,7 +226,7 @@
         /// <summary>
         /// 閫変腑缁勫悎鐨勬挱鏀惧櫒鐨勭晫闈�
         /// </summary>
-        public void PlayMergence()
+        public void PlayMergence(A31MusicModel a31MusicModel)
         {
 
             #region
@@ -357,6 +358,7 @@
                     SelectedImagePath = "MusicIcon/selectedIcon.png",
                 };
                 PlayRow.AddChidren(selectedIconBtn);
+               
 
                 ///鍔犲ぇ鍑犵偣鑼冨洿
                 Button clickBtn = new Button
@@ -364,7 +366,11 @@
                     Height = Application.GetRealHeight(50),
                 };
                 PlayRow.AddChidren(clickBtn);
-
+                if (a31MusicModel.UniqueDeviceName == player.UniqueDeviceName)
+                {
+                    clickBtn.IsSelected = selectedIconBtn.IsSelected = true;
+                    playList1.Add(a31MusicModel);
+                }
                 clickBtn.MouseUpEventHandler += (sender, e) =>
                 {
                     clickBtn.IsSelected = !clickBtn.IsSelected;
@@ -575,20 +581,20 @@
                     addFlieRow.AddChidren(songNameBtn);
 
                     var wText = songNameBtn.GetTextWidth();//鑾峰彇鏂囨湰瀹藉害
-                    if (wText > 280)
+                    if (wText >Application.GetRealWidth(220))
                     {
-                        songNameBtn.Width = Application.GetRealWidth(280);
+                        songNameBtn.Width = Application.GetRealWidth(220);
                     }
                     else
                     {
-                        songNameBtn.Width = wText + 5;
+                        songNameBtn.Width = wText + Application.GetRealWidth(15);
                     }
                     //姝屾墜鎺т欢
                     Button singerBtn = new Button
                     {
                         X = songNameBtn.Right,
                         Y = Application.GetRealHeight(15),
-                        Width = Application.GetRealWidth(280 - songNameBtn.Width),
+                        Width = Application.GetRealWidth(220)- wText,
                         Height = Application.GetRealHeight(20),
                         TextColor = Color.MusicNoTxetColor,
                         TextSize = TextSize.Text12,
@@ -596,11 +602,6 @@
                         Text = "-" + player.A31PlayStatus.Artist.Trim(),
                     };
                     addFlieRow.AddChidren(singerBtn);
-                    if (wText > 280)
-                    {
-                        ///姝屽悕闀垮害灏忎簬250鎵嶅彲浠ユ樉绀烘瓕鎵嬪嚭鏉�
-                        singerBtn.Width = Application.GetRealWidth(0);
-                    }
                 }
                 else
                 {
@@ -1337,7 +1338,7 @@
                 {
                     X = Application.GetRealWidth(289),
                     Y = Application.GetRealHeight(31),
-                    Width = Application.GetRealWidth(26),
+                    Width = Application.GetRealWidth(26+15),
                     Height = Application.GetRealHeight(17),
                     TextColor = Color.MusicNoTxetColor,
                     TextSize = TextSize.Text12,
@@ -1345,7 +1346,6 @@
                     Text = player.A31PlayStatus.vol + "%",
                 };
                 volumeFra.AddChidren(valueBtn);
-
 
                 ///闊抽噺杩涘害鏉$偣鍑讳簨浠�
                 EventHandler<int> progressClick = (sender, e) =>
@@ -1359,7 +1359,6 @@
                     if (player.ServerClientType == -1)
                     {
                         valueBtn.Text = volSeekBar.Progress + "%";
-                        //SendMethod.ControlVolume(volSeekBar.Progress, player);
                     }
                     else if (player.ServerClientType == 1)
                     {
@@ -1371,7 +1370,6 @@
                             var button = (Button)frameLayout.GetChildren(2);
                             diyImageSeekBar.Progress = volSeekBar.Progress;
                             button.Text = volSeekBar.Progress + "%";
-                            //SendMethod.ControlVolume(volSeekBar.Progress, music);
                         }
                     }
                 };
@@ -1415,9 +1413,17 @@
                         }
                         else if (currVolumePlay.ServerClientType == 1)
                         {
+                            //鍏堝彂涓绘挱鏀惧櫒闊抽噺鍛戒护
+                            SendMethod.ControlVolume(endVolume, currVolumePlay);
                             for (int j = 0; j < volumePlayList.Count; j++)
                             {
                                 var music = volumePlayList[j];
+                                if (music.ServerClientType == 1)
+                                {
+                                    continue;
+                                }
+                                System.Threading.Thread.Sleep(500);
+                                //姣忎釜500姣鍙戜粠鎾斁鍣ㄩ煶閲忓懡浠�
                                 SendMethod.ControlVolume(endVolume, music);
                             }
                         }

--
Gitblit v1.8.0