吾爱破解 - 52pojie.cn

 找回密码
 注册[Register]

QQ登录

只需一步,快速开始

查看: 5583|回复: 0
收起左侧

[其他转载] ShockWaveFlash应用实例-简易SWF播放器

[复制链接]
codebutcher 发表于 2013-3-31 17:46
//编写工具:Delphi XE3 With Update2
unit Unit1;
interface
uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, StdCtrls, Buttons, OleCtrls, ShockwaveFlashObjects_TLB,
  Vcl.ExtCtrls;
type
  TForm1 = class(TForm)
    ShockwaveFlash1: TShockwaveFlash;
    BitBtn1: TBitBtn;
    BitBtn2: TBitBtn;
    OpenDialog1: TOpenDialog;
    procedure BitBtn1Click(Sender: TObject);
    procedure BitBtn2Click(Sender: TObject);
  private
    procedure ShutDownMouse(var Msg: TMsg; var Handled: Boolean);
  public
  end;
var
  Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.BitBtn1Click(Sender: TObject);
var
OpenName:String;
begin
OpenDialog1.Filter:= 'Flash文件(*.swf)';
if OpenDialog1.execute then
  ShockwaveFlash1.Movie:=OpenDialog1.FileName;
  ShockwaveFlash1.Play;
end;
procedure TForm1.BitBtn2Click(Sender: TObject);
begin
  ShockwaveFlash1.StopPlay;
end;
procedure TForm1.ShutDownMouse(var Msg: TMsg; var Handled: Boolean);
begin
  if (Msg.message = WM_RBUTTONDOWN) and (msg.hwnd = ShockwaveFlash1.Handle) then
    Handled:= true;
end;
end.

发帖前要善用论坛搜索功能,那里可能会有你要找的答案或者已经有人发布过相同内容了,请勿重复发帖。

您需要登录后才可以回帖 登录 | 注册[Register]

本版积分规则

返回列表

RSS订阅|小黑屋|处罚记录|联系我们|吾爱破解 - LCG - LSG ( 京ICP备16042023号 | 京公网安备 11010502030087号 )

GMT+8, 2024-11-16 12:49

Powered by Discuz!

Copyright © 2001-2020, Tencent Cloud.

快速回复 返回顶部 返回列表