diff --git a/Music/App.config b/Music/App.config index c54433c..424f674 100644 --- a/Music/App.config +++ b/Music/App.config @@ -2,7 +2,7 @@ - +
diff --git a/Music/Music.csproj b/Music/Music.csproj index 54380b7..a27e169 100644 --- a/Music/Music.csproj +++ b/Music/Music.csproj @@ -60,7 +60,7 @@ - ..\..\..\UI for Visual Studio 2017\Bunifu_UI_v1.52.dll + ..\packages\Bunifu_UI_v1.52.dll ..\packages\Fizzler.1.1.0\lib\net35\Fizzler.dll @@ -71,8 +71,8 @@ ..\packages\HtmlAgilityPack.1.8.4\lib\Net45\HtmlAgilityPack.dll - - ..\..\..\UI for Visual Studio 2017\MaterialSkin.0.2.1\lib\MaterialSkin.dll + + ..\packages\MaterialSkin.0.2.1\lib\MaterialSkin.dll ..\packages\MetroModernUI.1.4.0.0\lib\net\MetroFramework.dll @@ -103,6 +103,9 @@ + + Component + UserControl diff --git a/Music/SongInfo.cs b/Music/SongInfo.cs index 5d6ded9..369cbcf 100644 --- a/Music/SongInfo.cs +++ b/Music/SongInfo.cs @@ -109,7 +109,13 @@ internal void SetPath(string filePath) { if (file != null) file.Dispose(); - this.file = TagLib.File.Create(filePath); + try + { + this.file = TagLib.File.Create(filePath); + }catch + { + + } } #endregion diff --git a/Music/TFlowLayoutPanel.cs b/Music/TFlowLayoutPanel.cs new file mode 100644 index 0000000..806abe1 --- /dev/null +++ b/Music/TFlowLayoutPanel.cs @@ -0,0 +1,36 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace Music +{ + class TFlowLayoutPanel : FlowLayoutPanel + { + public TFlowLayoutPanel() : base() + { + this.DoubleBuffered = true; + this.SetStyle(ControlStyles.UserPaint, true); + this.SetStyle(ControlStyles.AllPaintingInWmPaint, true); + this.SetStyle(ControlStyles.OptimizedDoubleBuffer, true); + } + + protected override void OnScroll(ScrollEventArgs se) + { + this.Invalidate(); + base.OnScroll(se); + } + + protected override CreateParams CreateParams + { + get + { + CreateParams cp = base.CreateParams; + cp.ExStyle |= 0x02000000; // WS_CLIPCHILDREN + return cp; + } + } + } +} diff --git a/Music/packages.config b/Music/packages.config index 7f685e0..7d1e94e 100644 --- a/Music/packages.config +++ b/Music/packages.config @@ -3,6 +3,7 @@ + \ No newline at end of file diff --git a/Music/uMyMusic.Designer.cs b/Music/uMyMusic.Designer.cs index 1c5cac0..e9a73cb 100644 --- a/Music/uMyMusic.Designer.cs +++ b/Music/uMyMusic.Designer.cs @@ -33,7 +33,7 @@ private void InitializeComponent() System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(uMyMusic)); this.metroTabControl1 = new MetroFramework.Controls.MetroTabControl(); this.Songs = new System.Windows.Forms.TabPage(); - this.panelSongs = new System.Windows.Forms.FlowLayoutPanel(); + this.panelSongs = new TFlowLayoutPanel(); this.panel1 = new System.Windows.Forms.Panel(); this.btnShuffleAllSongs = new Bunifu.Framework.UI.BunifuFlatButton(); this.comboBoxSortBySongs = new System.Windows.Forms.ComboBox(); @@ -391,7 +391,7 @@ private void InitializeComponent() private System.Windows.Forms.Panel panel2; private Bunifu.Framework.UI.BunifuFlatButton btnShuufleAllArtists; private System.Windows.Forms.Label label4; - private System.Windows.Forms.FlowLayoutPanel panelSongs; + private TFlowLayoutPanel panelSongs; private System.Windows.Forms.Panel panel1; private Bunifu.Framework.UI.BunifuFlatButton btnShuffleAllSongs; private System.Windows.Forms.Label label1; diff --git a/Music/uNowPlaying.Designer.cs b/Music/uNowPlaying.Designer.cs index b18671c..d357cba 100644 --- a/Music/uNowPlaying.Designer.cs +++ b/Music/uNowPlaying.Designer.cs @@ -28,7 +28,7 @@ protected override void Dispose(bool disposing) /// private void InitializeComponent() { - this.panelSongs = new System.Windows.Forms.FlowLayoutPanel(); + this.panelSongs = new TFlowLayoutPanel(); this.SuspendLayout(); // // panelSongs @@ -56,6 +56,6 @@ private void InitializeComponent() #endregion - private System.Windows.Forms.FlowLayoutPanel panelSongs; + private TFlowLayoutPanel panelSongs; } } diff --git a/Music/uPlaylist.Designer.cs b/Music/uPlaylist.Designer.cs index 5fab915..d12606b 100644 --- a/Music/uPlaylist.Designer.cs +++ b/Music/uPlaylist.Designer.cs @@ -33,7 +33,7 @@ private void InitializeComponent() this.btnNewPlaylist = new Bunifu.Framework.UI.BunifuFlatButton(); this.comboBoxSortBySongs = new System.Windows.Forms.ComboBox(); this.label1 = new System.Windows.Forms.Label(); - this.panelSongs = new System.Windows.Forms.FlowLayoutPanel(); + this.panelSongs = new TFlowLayoutPanel(); this.panel1.SuspendLayout(); this.SuspendLayout(); // @@ -136,6 +136,6 @@ private void InitializeComponent() private Bunifu.Framework.UI.BunifuFlatButton btnNewPlaylist; private System.Windows.Forms.ComboBox comboBoxSortBySongs; private System.Windows.Forms.Label label1; - private System.Windows.Forms.FlowLayoutPanel panelSongs; + private TFlowLayoutPanel panelSongs; } } diff --git a/Music/uPlaylistDetail.Designer.cs b/Music/uPlaylistDetail.Designer.cs index 9e5f9e1..59aad4c 100644 --- a/Music/uPlaylistDetail.Designer.cs +++ b/Music/uPlaylistDetail.Designer.cs @@ -39,7 +39,7 @@ private void InitializeComponent() this.lblPlaylistName = new System.Windows.Forms.Label(); this.image = new System.Windows.Forms.PictureBox(); this.label1 = new System.Windows.Forms.Label(); - this.panelSongs = new System.Windows.Forms.FlowLayoutPanel(); + this.panelSongs = new TFlowLayoutPanel(); this.bunifuFlatButton1 = new Bunifu.Framework.UI.BunifuFlatButton(); this.panelHead.SuspendLayout(); this.background.SuspendLayout(); @@ -308,7 +308,7 @@ private void InitializeComponent() private System.Windows.Forms.Panel panelHead; private System.Windows.Forms.PictureBox image; - private System.Windows.Forms.FlowLayoutPanel panelSongs; + private TFlowLayoutPanel panelSongs; private System.Windows.Forms.Label label1; private System.Windows.Forms.Panel background; private Bunifu.Framework.UI.BunifuFlatButton btnDelete; diff --git a/Music/uResults.Designer.cs b/Music/uResults.Designer.cs index 6cbe76f..e1fd6e1 100644 --- a/Music/uResults.Designer.cs +++ b/Music/uResults.Designer.cs @@ -28,7 +28,7 @@ protected override void Dispose(bool disposing) /// private void InitializeComponent() { - this.panelSongs = new System.Windows.Forms.FlowLayoutPanel(); + this.panelSongs = new TFlowLayoutPanel(); this.panel2 = new System.Windows.Forms.Panel(); this.bunifuSeparator1 = new Bunifu.Framework.UI.BunifuSeparator(); this.lblResults = new System.Windows.Forms.Label(); @@ -97,7 +97,7 @@ private void InitializeComponent() #endregion - private System.Windows.Forms.FlowLayoutPanel panelSongs; + private TFlowLayoutPanel panelSongs; private System.Windows.Forms.Panel panel2; private Bunifu.Framework.UI.BunifuSeparator bunifuSeparator1; private System.Windows.Forms.Label lblResults; diff --git a/packages/Bunifu_UI_v1.52.dll b/packages/Bunifu_UI_v1.52.dll new file mode 100644 index 0000000..431cd7d Binary files /dev/null and b/packages/Bunifu_UI_v1.52.dll differ