• 大小: 971.75 KB
    文件类型: .rar
    金币: 2
    下载: 0 次
    发布日期: 2024-08-08
  • 语言: C#
  • 标签: 播放器  

资源简介

用WMP做的四分屏播放器 自娱自乐一下~

资源截图

代码片段和文件信息

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;


namespace player
{
    public partial class player : Form
    {
        enum Change
        {
            player1 player2 player3 player4
        }
        Change cort;
        
        
        
        
        
        Form2 Lrc;
      private  bool Exist = false;
        string[] UrlItem;
        string[] UrlItem2;
        string[] UrlItem3;
        string[] UrlItem4;
        int i = 0;
        public player()
        {
            
            InitializeComponent();
        }
        private void Receive(bool a)
        {
            Exist = a;
        }

        private void 打开ToolStripMenuItem_Click(object sender EventArgs e)
        {   openFileDialog1.Filter=“*.mp3|*.mp3|*.wma|*.wma|*.rmvb|*.rmvb|*.wmv|*.wmv|all|*.*“;
            if (openFileDialog1.ShowDialog() == DialogResult.OK)
            {  UrlItem = openFileDialog1.FileNames;
                axWindowsMediaPlayer1.URL = UrlItem[0];
                label2.Text = axWindowsMediaPlayer1.Ctlcontrols.currentPositionString;
                axWindowsMediaPlayer1.settings.volume = trackBar1.Value;
                label1.Text = axWindowsMediaPlayer1.currentMedia.name;
            }
            if (UrlItem != null)
            {
                //timer1.Enabled = true;
                this.button6.Enabled = true;

                //listBox1.Items.AddRange(UrlItem);

                this.button4.Enabled = true;
                this.button5.Enabled = true;
                label2.Visible = true;
            }
        }

        private void button1_Click(object sender EventArgs e)
        {
            if (cort == Change.player1)
            {
                timer1.Enabled = true;
                timer5.Enabled = true;
                axWindowsMediaPlayer1.Ctlcontrols.play();
            }
            else if (cort == Change.player2)
            {
                timer1.Enabled = true;
                timer2.Enabled = true;
                axWindowsMediaPlayer2.Ctlcontrols.play();
            }
            else if (cort == Change.player3)
            {
                timer1.Enabled = true;
                timer3.Enabled = true;
                axWindowsMediaPlayer3.Ctlcontrols.play();
            }
            else if (cort == Change.player4)
            {
                timer1.Enabled = true;
                timer4.Enabled = true;
                axWindowsMediaPlayer4.Ctlcontrols.play();
            }
        }

        private void button2_Click(object sender EventArgs e)
        {
            if (cort == Change.player1)
            {
                timer1.Enabled = false;
                timer5.Enabled = false;
                axWindowsMediaPlayer1.Ctlcontrols.pause();
            }
            else if (cort == Change.play

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件       1206  2008-09-16 21:47  player.sln

     文件       5612  2008-09-01 21:28  player\Properties\Resources.resx

     文件        249  2008-09-01 21:28  player\Properties\Settings.settings

     文件       1166  2008-09-01 21:28  player\Properties\AssemblyInfo.cs

     文件       2836  2008-09-06 18:25  player\Properties\Resources.Designer.cs

     文件       1104  2008-09-06 18:25  player\Properties\Settings.Designer.cs

     文件      31338  2008-09-21 18:32  player\Form1.Designer.cs

     文件        891  2008-10-06 20:01  player\Form2.cs

     文件      24940  2008-10-06 19:59  player\Form1.cs

     文件       6827  2008-09-16 21:47  player\player.csproj

     文件      14328  2008-10-11 22:22  player\bin\Debug\player.vshost.exe

     文件     246784  2008-10-06 20:01  player\bin\Debug\player.exe

     文件      48640  2008-10-06 20:01  player\bin\Debug\player.pdb

     文件     331776  2008-09-06 18:25  player\bin\Debug\Interop.WMPLib.dll

     文件      61440  2008-09-01 21:36  player\bin\Debug\AxInterop.WMPLib.dll

     文件       4470  2008-10-06 20:01  player\bin\Debug\player.exe.manifest

     文件       1557  2008-10-06 20:01  player\bin\Debug\player.application

     文件       8846  2008-09-16 21:43  player\bin\Debug\app.publish\Application Files\player_1_0_0_0\player.exe.manifest

     文件     246784  2008-09-16 21:42  player\bin\Debug\app.publish\Application Files\player_1_0_0_0\player.exe.deploy

     文件      86016  2008-09-06 18:25  player\bin\Debug\app.publish\Application Files\player_1_0_0_0\Interop.MediaPlayer.dll.deploy

     文件     331776  2008-09-06 18:25  player\bin\Debug\app.publish\Application Files\player_1_0_0_0\Interop.WMPLib.dll.deploy

     文件      61440  2008-09-01 21:36  player\bin\Debug\app.publish\Application Files\player_1_0_0_0\AxInterop.WMPLib.dll.deploy

     文件     475648  2008-09-16 21:43  player\bin\Debug\app.publish\setup.exe

     文件       5364  2008-09-16 21:43  player\bin\Debug\app.publish\player.application

     文件         45  2008-09-16 21:43  player\bin\Debug\app.publish\autorun.inf

     文件       1557  2008-10-06 20:01  player\bin\Debug\player.vshost.application

     文件       4608  2008-09-06 18:25  player\obj\Debug\TempPE\Properties.Resources.Designer.cs.dll

     文件     331776  2008-09-06 18:25  player\obj\Debug\Interop.WMPLib.dll

     文件        905  2008-09-21 18:32  player\obj\Debug\player.csproj.GenerateResource.Cache

     文件      48640  2008-10-06 20:01  player\obj\Debug\player.pdb

............此处省略31个文件信息

评论

共有 条评论