寻求得到mp3 tag的代码(50分)

  • 主题发起人 主题发起人 k_q_92
  • 开始时间 开始时间
K

k_q_92

Unregistered / Unconfirmed
GUEST, unregistred user!
//这个代码对于有的歌曲有乱码,不知道为什么,谢谢高手解答
type
TID3Tag = packed record // 128 字节
TAGID: array[0..2] of char; // 3 字节: 必须是TAG
Title: array[0..29] of char; // 30 字节: 歌曲标题
Artist: array[0..29] of char; // 30 字节: 歌曲的艺术家
Album: array[0..29] of char; // 30 字节: 歌曲专辑
Year: array[0..3] of char; // 4 字节: 出版年
Comment: array[0..29] of char; // 30 字节: 评论
Genre: byte; // 1 字节: 种类标识
end;

procedure TForm1.Button1Click(Sender: TObject);


var
id3tag: Tid3tag;
mp3file: Tfilestream;
begin
opendialog1.Filter:='*.MP3|*.MP3';
if opendialog1.Execute then

begin
mp3file:=Tfilestream.create(opendialog1.FileName,fmOpenRead);
try
mp3file.position:=mp3file.size-128; // 跳到id3-tag
mp3file.Read(id3tag,SizeOf(id3tag));
showmessage(' Title: '+id3tag.title+#13+
' Artist: '+id3tag.artist+#13+
' Album: '+id3tag.album+#13+
' Year: '+id3tag.year+#13+
' Comment: '+id3tag.comment+#13+
' Genre-ID: '+inttostr(id3tag.genre)
);
finally
mp3file.free;
end;

end;
end;
 
源码下载:http://www.yckq.com/down/mp3tag.rar
Delphi园地
 
unit Unit1;

interface

uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, SkinControls, Skin, SkinEngine, XPMenu, Menus, SkinButtons,
StdCtrls, ExtCtrls, MPlayer, SkinImageText,ShellApi,
SkinImage, SkinSlider, SkinProgressBar, SkinCheckBox,MMsystem, ImgList;

type
TID3Tag = packed record // 128 趼誹
TAGID: array[0..2] of char; // 3 趼誹: 斛剕岆TAG
Title: array[0..29] of char; // 30 趼誹: 貉Ж梓枙
Artist: array[0..29] of char; // 30 趼誹: 貉Ж腔眙扲模
Album: array[0..29] of char; // 30 趼誹: 貉Ж蚳憮
Year: array[0..3] of char; // 4 趼誹: 堤唳爛
Comment: array[0..29] of char; // 30 趼誹: 丿蹦
Genre: byte; // 1 趼誹: 笱濬梓妎
end;

type
TForm_main = class(TForm)
SkinEngine1: TSkinEngine;
PopupMenu1: TPopupMenu;
N2: TMenuItem;
N3: TMenuItem;
N4: TMenuItem;
N5: TMenuItem;
N6: TMenuItem;
N7: TMenuItem;
N8: TMenuItem;
N9: TMenuItem;
N10: TMenuItem;
N11: TMenuItem;
N12: TMenuItem;
N13: TMenuItem;
N14: TMenuItem;
N15: TMenuItem;
N16: TMenuItem;
N17: TMenuItem;
N18: TMenuItem;
N19: TMenuItem;
N20: TMenuItem;
N21: TMenuItem;
N22: TMenuItem;
N23: TMenuItem;
N24: TMenuItem;
N25: TMenuItem;
Button_next: TSkinButton;
Button_Pev: TSkinButton;
Button_stop: TSkinButton;
Button_puase: TSkinButton;
Button_play: TSkinButton;
messages_window: TPanel;
OpenFile: TOpenDialog;
MediaPlayer: TMediaPlayer;
show_zt: TTimer;
message_word: TLabel;
Label1: TLabel;
Label2: TLabel;
vol: TSkinSlider;
checkvol: TSkinCheckBox;
skinform: TSkinForm;
XPMenu1: TXPMenu;
filebar: TSkinSlider;
ImageList1: TImageList;
show_time: TSkinImageText;
Botton_min: TSkinButton;
Botton_exit: TSkinButton;
view_zt: TSkinImageText;
Btn_list: TSkinButton;
Openfile_M: TSkinButton;
Botton_CH: TSkinCheckBox;
Botton_Rad: TSkinCheckBox;
other: TSkinButton;
N26: TMenuItem;
ImageList2: TImageList;
N27: TMenuItem;
N28: TMenuItem;
N29: TMenuItem;
aboutinfo: TSkinButton;
N1: TMenuItem;
N30: TMenuItem;
SkinEngine2: TSkinEngine;
N31: TMenuItem;
SkinEngine3: TSkinEngine;
N32: TMenuItem;
SkinEngine4: TSkinEngine;
N33: TMenuItem;
Timer1: TTimer;
procedure N18Click(Sender: TObject);
procedure N23Click(Sender: TObject);
procedure N22Click(Sender: TObject);
procedure openplayfile(Sender: TObject);
procedure show_ztTimer(Sender: TObject);
procedure Button_puaseClick(Sender: TObject);
procedure N8Click(Sender: TObject);
procedure N9Click(Sender: TObject);
procedure N6Click(Sender: TObject);
procedure N5Click(Sender: TObject);
procedure checkvolClick(Sender: TObject);
procedure N13Click(Sender: TObject);
procedure volMouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
procedure volMouseUp(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
procedure FormCreate(Sender: TObject);
procedure N15Click(Sender: TObject);
procedure N16Click(Sender: TObject);
procedure N2Click(Sender: TObject);
procedure N11Click(Sender: TObject);
procedure N12Click(Sender: TObject);
procedure volChange(Sender: TObject);
procedure N20Click(Sender: TObject);
procedure filebarMouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
procedure filebarMouseUp(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
procedure filebarMouseMove(Sender: TObject; Shift: TShiftState; X,
Y: Integer);
procedure Botton_CHClick(Sender: TObject);
procedure Botton_RadClick(Sender: TObject);
procedure N25Click(Sender: TObject);
procedure messages_timeTimer(Sender: TObject);
procedure N26Click(Sender: TObject);
procedure window_none(Sender: Tobject);
procedure window_min(Sender: Tobject);
procedure N28Click(Sender: TObject);
procedure N29Click(Sender: TObject);
procedure N30Click(Sender: TObject);
procedure N31Click(Sender: TObject);
procedure N32Click(Sender: TObject);
procedure N33Click(Sender: TObject);
procedure DragFileProc(var Message: TMessage);
procedure Timer1Timer(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
function Mp3Info(FileName:string):TID3Tag;
function cal_length(songlength:integer):string;
end;

var
Form_main: TForm_main;
s:string;
move:boolean;
OLDWndProc: TWndMethod;
implementation

uses Unit2;

{$R *.dfm}

procedure TForm_main.DragFileProc(var Message: TMessage);
var
FileNum: Word;
p: array[0..254] of char;
fileinfo:tid3tag;
begin
if Message.Msg = WM_DropFiles then
begin
FileNum := DragQueryFile(Message.WParam,$FFFFFFFF,nil,0);
for FileNum := 0 to FileNum - 1 do
begin
DragQueryFile(Message.WParam, FileNum , p ,255);
Form_list.listbox_hide.Items.Add(strpas(p));
fileinfo:=mp3info(strpas(p));
if (fileinfo.Artist='') or (strlen(fileinfo.Artist)>15) or (strlen(fileinfo.title)>20) then
begin
Form_list.ListBox_show.Items.Add(trim(inttostr(form_list.ListBox_show.Items.count+1)+'. '+copy(ExtractFileName(strpas(p)),1,strlen(pchar(ExtractFileName(strpas(p))))-4)));
end
else
begin
Form_list.ListBox_show.Items.Add(trim(inttostr(form_list.ListBox_show.Items.count+1)+'. '+fileinfo.Artist+' - '+fileinfo.Title));
end;
end;
form_list.listbox_show.ItemIndex:=form_list.ListBox_hide.ItemIndex;
end
else
begin
OLDWndProc(Message);
end;
end;

function TForm_main.cal_length(songlength:integer):string;
var
s:string;
minutes,seconds:integer;
begin
songlength:=songlength div 1000;
seconds:= songlength mod 60;
songlength:=songlength div 60;
minutes:=songlength mod 60;
// hours:=songlength div 60;
// if strlen(pchar(inttostr(hours)))=1 then
// s:='0'+inttostr(hours)
// else
// s:=inttostr(hours);
// s:=s+':';
if strlen(pchar(inttostr(minutes)))=1 then
s:=s+'0'+inttostr(minutes)
else
s:=s+inttostr(minutes);
s:=s+':';
if strlen(pchar(inttostr(seconds)))=1 then
s:=s+'0'+inttostr(seconds)
else
s:=s+inttostr(seconds);
cal_length:=s;
end;

Function TForm_main.Mp3Info(FileName:String) : TID3Tag;
Var
Id3tag:Tid3tag;
Mp3File:TFilestream;
begin
Mp3File:=Tfilestream.create(FileName,fmOpenRead);
Try
Mp3File.Position:=Mp3File.size-128;
Mp3File.Read(id3tag,SizeOf(id3tag));
finally
mp3file.free;
Mp3Info:= id3tag;
end;
end;

procedure TForm_main.N18Click(Sender: TObject);
begin
Form_list.show;
Form_list.listClick(sender);
end;

procedure TForm_main.N23Click(Sender: TObject);
begin
mediaplayer.Close;
Application.Terminate;
end;

procedure TForm_main.N22Click(Sender: TObject);
begin
Application.Minimize;
end;

procedure TForm_main.openplayfile(Sender: TObject);
var
fileinfo:tid3tag;
begin
openfile.Options:=[ofHideReadOnly,ofEnableSizing];
openfile.Title:='湖羲畦溫恅璃';
if openfile.Execute then
begin
Form_list.ListBox_hide.Items.Add(openfile.FileName);
fileinfo:=mp3info(openfile.FileName);
if (fileinfo.Artist='') or (strlen(fileinfo.Artist)>15) or (strlen(fileinfo.title)>20) then
begin
Form_list.ListBox_show.Items.Add(trim(inttostr(form_list.ListBox_show.Items.count+1)+'. '+copy(ExtractFileName(openfile.FileName),1,strlen(pchar(ExtractFileName(openfile.FileName)))-4)));
end
else
begin
Form_list.ListBox_show.Items.Add(trim(inttostr(form_list.ListBox_show.Items.count+1)+'. '+fileinfo.Artist+' - '+fileinfo.Title));
end;
form_list.ListBox_hide.ItemIndex:=form_list.ListBox_hide.Items.Count-1;
form_list.listbox_show.ItemIndex:=form_list.ListBox_hide.ItemIndex;
message_word.Caption:=form_list.ListBox_show.Items.Strings[form_list.ListBox_hide.ItemIndex];
mediaplayer.FileName:=openfile.FileName;
mediaplayer.Open;
mediaplayer.Play;
end;
end;

procedure TForm_main.show_ztTimer(Sender: TObject);
begin
case mediaplayer.Mode of
mpStopped:
begin
view_zt.Text:='3';
show_time.Text:='00:00';
filebar.Position:=0;
if Form_list.ListBox_hide.Items.Count=0 then
begin
message_word.Caption:='羶衄貉珋淏婓畦溫...';
application.Title:=message_word.Caption;
exit;
end;
if n9.Checked=True then
begin
Form_list.listbox_hide.itemindex:=random(Form_list.listbox_hide.Items.Count);
end;
if Form_list.ListBox_hide.ItemIndex=Form_list.ListBox_hide.Items.Count-1 then
begin
if n8.Checked=True then
begin
Form_list.listbox_hide.itemindex:=-1;
end
else
begin
message_word.Caption:='羶衄貉珋淏婓畦溫...';
application.Title:=message_word.Caption;
exit;
end;
end;
Form_list.listbox_hide.itemindex:=Form_list.listbox_hide.itemindex+1;
Form_list.listbox_show.itemindex:=Form_list.listbox_hide.itemindex;
mediaplayer.FileName:=Form_list.ListBox_hide.Items.Strings[Form_list.ListBox_hide.itemindex];
message_word.Caption:=Form_list.listbox_show.Items.strings[Form_list.ListBox_hide.itemindex];
application.Title:=message_word.Caption;
mediaplayer.Open;
mediaplayer.Play;
end;
mpPaused:
begin
view_zt.text:='2';
end;
mpPlaying:
begin
view_zt.Text:='1';
filebar.Position:=Trunc(mediaplayer.Position / mediaplayer.Length*1000);
if move=True then
begin
exit;
end
else
begin
show_time.Text:=cal_length(mediaplayer.Position);
end;
end;
end;
end;

procedure TForm_main.Button_puaseClick(Sender: TObject);
begin
if Form_list.listbox_show.items.Count=0 then
begin
exit;
end;
mediaplayer.Pause;
end;

procedure TForm_main.N8Click(Sender: TObject);
begin
if n8.Checked=False then
begin
Botton_ch.Checked:=True;
n8.Checked:=True;
end
else
begin
botton_ch.Checked:=False;
n8.Checked:=False;
end;
end;

procedure TForm_main.N9Click(Sender: TObject);
begin
if n9.Checked=False then
begin
n9.Checked:=True;
Botton_Rad.checked:=True;
end
else
begin
n9.Checked:=False;
Botton_Rad.checked:=False;
end;
end;

procedure TForm_main.N6Click(Sender: TObject);
begin
if Form_list.listbox_hide.items.Count=0 then
begin
exit;
end;
if n9.Checked=True then
begin
Form_list.listbox_hide.itemindex:=random(Form_list.listbox_hide.Items.Count);
end;
if Form_list.ListBox_hide.ItemIndex=Form_list.ListBox_hide.Items.Count-1 then
begin
mediaplayer.close;
Form_list.ListBox_hide.ItemIndex:=0;
Form_list.ListBox_show.ItemIndex:=0;
mediaplayer.FileName:=Form_list.ListBox_hide.Items.Strings[Form_list.ListBox_hide.ItemIndex];
form_list.ListBox_show.ItemIndex:=Form_list.ListBox_hide.ItemIndex;
message_word.Caption:=Form_list.ListBox_show.Items.strings[Form_list.ListBox_hide.ItemIndex];
application.Title:=message_word.Caption;
mediaplayer.Open;
mediaplayer.Play;
end
else
begin
mediaplayer.close;
Form_list.ListBox_hide.ItemIndex:=Form_list.ListBox_hide.ItemIndex+1;
Form_list.listbox_show.ItemIndex:=Form_list.ListBox_hide.ItemIndex;
mediaplayer.FileName:=Form_list.ListBox_hide.Items.Strings[Form_list.ListBox_hide.ItemIndex];
message_word.Caption:=Form_list.ListBox_show.Items.strings[Form_list.ListBox_hide.ItemIndex];
application.Title:=message_word.Caption;
mediaplayer.Open;
mediaplayer.Play;
end;
end;

procedure TForm_main.N5Click(Sender: TObject);
begin
if Form_list.listbox_hide.items.Count=0 then
begin
exit;
end;
if n9.Checked=True then
begin
Form_list.listbox_hide.itemindex:=random(Form_list.listbox_hide.Items.Count);
end;
if Form_list.ListBox_hide.ItemIndex=0 then
begin
mediaplayer.Close;
Form_list.ListBox_hide.ItemIndex:=Form_list.ListBox_hide.Items.Count-1;
Form_list.ListBox_show.ItemIndex:=Form_list.ListBox_hide.ItemIndex;
mediaplayer.FileName:=Form_list.ListBox_hide.Items.Strings[Form_list.ListBox_hide.ItemIndex];
message_word.Caption:=Form_list.ListBox_show.Items.strings[Form_list.ListBox_hide.ItemIndex];
application.Title:=message_word.Caption;
mediaplayer.Open;
mediaplayer.Play;
end
else
begin
mediaplayer.Close;
Form_list.ListBox_hide.ItemIndex:=Form_list.ListBox_hide.ItemIndex-1;
Form_list.ListBox_show.ItemIndex:=Form_list.listbox_hide.ItemIndex;
mediaplayer.FileName:=Form_list.ListBox_hide.Items.Strings[Form_list.ListBox_hide.ItemIndex];
message_word.Caption:=Form_list.ListBox_show.Items.strings[Form_list.ListBox_hide.ItemIndex];
application.Title:=message_word.Caption;
mediaplayer.Open;
mediaplayer.Play;
end;
end;

procedure TForm_main.checkvolClick(Sender: TObject);
begin
if checkvol.Checked=false then
begin
waveoutsetvolume(0,(vol.Position shl 8) or (vol.Position shl 24));
n13.Checked:=False;
end
else
begin
waveoutsetvolume(0,0);
n13.Checked:=True;
end;
end;

procedure TForm_main.N13Click(Sender: TObject);
begin
if n13.Checked=True then
begin
n13.Checked:=False;
waveoutsetvolume(0,(vol.Position shl 8) or (vol.Position shl 24));
checkvol.Checked:=False;
end
else
begin
n13.Checked:=True;
waveoutsetvolume(0,0);
checkvol.Checked:=True;
end;
end;

procedure TForm_main.volMouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
begin
s:=show_time.Text;
move:=true;
end;

procedure TForm_main.volMouseUp(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
begin
show_time.Text:=s;
// show_time.Text:=cal_length(mediaplayer.Position);
move:=false;
end;

procedure TForm_main.FormCreate(Sender: TObject);
begin
vol.Position:=70;
waveoutsetvolume(0,(vol.Position shl 8) or (vol.Position shl 24));
show_time.Text:='00:00';
window_none(sender);
//扢离最唗羲宎奀賜醱峈湮耀宒
skinform.GraphicName:='maincopy.bmp';
//扢离最唗羲宎奀芞梓源偶峈蘇'
n28.Checked:=True;
//扢离最唗羲宎奀賜醱源偶峈蘇'
n30.Checked:=True;
n31.Checked:=False;
n32.Checked:=False;
n33.Checked:=false;
dragacceptfiles(form_main.Handle,True);
OLDWndProc := form_main.WindowProc;
form_main.WindowProc:= DragFileProc;
end;

procedure TForm_main.N15Click(Sender: TObject);
begin
if Form_list.listbox_show.items.Count=0 then
begin
Form_main.openplayfile(sender);
exit;
end;
mediaplayer.FileName:=Form_list.ListBox_hide.Items.Strings[Form_list.ListBox_show.Itemindex];
message_word.Caption:=Form_list.listbox_show.Items.strings[Form_list.ListBox_show.itemindex];
application.Title:=message_word.Caption;
mediaplayer.Open;
mediaplayer.Play;
show_zt.Enabled:=True;
end;

procedure TForm_main.N16Click(Sender: TObject);
begin
show_zt.Enabled:=False;
mediaplayer.Close;
view_zt.Text:='3';
show_time.Text:='00:00';
message_word.Caption:='羶衄貉Ж淏婓畦溫..';
application.Title:=message_word.Caption;
end;

procedure TForm_main.N2Click(Sender: TObject);
var
fileinfo:tid3tag;
i:integer;
begin
openfile.Options:=[ofHideReadOnly,ofEnableSizing,ofallowmultiselect];
openfile.Title:='湖羲嗣跺恅璃';
if openfile.Execute then
begin
Form_list.listbox_hide.Items.AddStrings(openfile.Files);
for i:=0 to openfile.Files.Count-1 do
begin
fileinfo:=mp3info(openfile.Files.Strings);
if (fileinfo.Artist='') or (strlen(fileinfo.Artist)>15) or (strlen(fileinfo.title)>20) then
begin
Form_list.ListBox_show.Items.Add(trim(inttostr(form_list.ListBox_show.Items.count+1)+'. '+copy(ExtractFileName(openfile.Files.Strings),1,strlen(pchar(ExtractFileName(openfile.Files.Strings)))-4)));
end
else
begin
Form_list.ListBox_show.Items.Add(trim(inttostr(form_list.ListBox_show.Items.count+1)+'. '+fileinfo.Artist+' - '+fileinfo.Title));
end;
end;
form_list.ListBox_hide.ItemIndex:=form_list.ListBox_hide.Items.Count-openfile.Files.Count;
form_list.listbox_show.ItemIndex:=form_list.ListBox_hide.ItemIndex;
end;
end;

procedure TForm_main.N11Click(Sender: TObject);
begin
s:=message_word.Caption;
if vol.Position<100 then
begin
vol.Position:=vol.Position+5;
end
else
begin
exit;
end;
waveoutsetvolume(0,(vol.Position shl 8) or (vol.Position shl 24));
message_word.Caption:=s;
end;

procedure TForm_main.N12Click(Sender: TObject);
begin
s:=message_word.Caption;
if vol.Position>0 then
begin
vol.Position:=vol.Position-5;
end
else
begin
exit;
end;
waveoutsetvolume(0,(vol.Position shl 8) or (vol.Position shl 24));
message_word.Caption:=s;
end;

procedure TForm_main.volChange(Sender: TObject);
begin
waveoutsetvolume(0,(vol.Position shl 8) or (vol.Position shl 24));
show_time.Text:=inttostr(vol.Position);
end;

procedure TForm_main.N20Click(Sender: TObject);
begin
if n20.Checked=False then
begin
n20.Checked:=True;
SetWindowPos(Form_main.handle, HWND_TOPMOST, 0, 0, 0, 0, swp_nomove or swp_nosize);
end
else
begin
n20.checked:=False;
SetWindowPos(Form_main.handle, HWND_NOTOPMOST, 0, 0, 0, 0, swp_nomove or swp_nosize);
end;
end;

procedure TForm_main.filebarMouseDown(Sender: TObject;
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
begin
if Form_list.listbox_show.items.Count=0 then
begin
exit;
end;
mediaplayer.Stop;
show_zt.Enabled:=False;
move:=True;
end;

procedure TForm_main.filebarMouseUp(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
begin
if Form_list.listbox_show.items.Count=0 then
begin
exit;
end;
mediaplayer.Position:=trunc(filebar.Position/1000*mediaplayer.Length);
show_time.Text:=cal_length(mediaplayer.Position);
move:=False;
mediaplayer.Play;
show_zt.Enabled:=True;
end;

procedure TForm_main.filebarMouseMove(Sender: TObject; Shift: TShiftState;
X, Y: Integer);
begin
if move=True then
begin
mediaplayer.Position:=trunc(filebar.Position/1000*mediaplayer.Length);
show_time.Text:=cal_length(mediaplayer.Position);
end;
end;

procedure TForm_main.Botton_CHClick(Sender: TObject);
begin
if botton_ch.Checked=False then
begin
n8.Checked:=False;
end
else
begin
n8.Checked:=True;
end;
end;

procedure TForm_main.Botton_RadClick(Sender: TObject);
begin
if botton_Rad.Checked=False then
begin
n9.Checked:=False;
end
else
begin
n9.Checked:=True;
end;
end;

procedure TForm_main.N25Click(Sender: TObject);
begin
Form_list.Show;
Form_list.aboutClick(Sender);
end;

procedure TForm_main.messages_timeTimer(Sender: TObject);
begin
message_word.Left:=message_word.Left-2;
if message_word.Left<-message_word.Width then message_word.Left:=messages_window.Width;
end;

procedure TForm_main.N26Click(Sender: TObject);
begin
if skinform.GraphicName='maincopy.bmp' then
begin
skinform.GraphicName:='maincopyMin.bmp';
message_word.Left:=0;
window_Min(Sender);
end
else
begin
skinform.GraphicName:='maincopy.bmp';
message_word.Left:=0;
window_none(Sender);
end;
end;

procedure TForm_main.window_none(Sender: Tobject);
begin
button_pev.Left:=4;
button_pev.Top:=34;
button_play.Left:=25;
button_play.Top:=32;
button_puase.Left:=45;
button_puase.Top:=32;
button_stop.Left:=65;
button_stop.Top:=33;
button_next.Left:=85;
button_next.Top:=35;
checkvol.Left:=105;
checkvol.Top:=38;
vol.Left:=145;
vol.Top:=49;
filebar.Left:=219;
filebar.Top:=49;
view_zt.Left:=214;
view_zt.top:=13;
show_time.Left:=226;
show_time.top:=11;
botton_ch.Left:=276;
botton_ch.Top:=11;
botton_rad.Left:=286;
botton_rad.Top:=11;
Btn_list.left:=300;
Btn_list.Top:=12;
aboutinfo.Left:=313;
aboutinfo.Top:=12;
openfile_M.Left:=326;
openfile_M.Top:=12;
other.Left:=339;
other.Top:=12;
botton_min.Left:=349;
botton_min.Top:=12;
botton_exit.left:=359;
botton_exit.Top:=12;
messages_window.Left:=142;
messages_window.Top:=32;
messages_window.Width:=229;
end;

procedure TForm_main.window_min(Sender: Tobject);
begin
button_pev.Left:=3;
button_pev.Top:=7;
button_play.Left:=24;
button_play.Top:=5;
button_puase.Left:=44;
button_puase.Top:=5;
button_stop.Left:=64;
button_stop.Top:=5;
button_next.Left:=84;
button_next.Top:=7;
checkvol.Left:=105;
checkvol.Top:=10;
vol.Left:=146;
vol.Top:=21;
filebar.Left:=220;
filebar.Top:=21;
view_zt.Left:=212;
view_zt.top:=7;
show_time.Left:=224;
show_time.top:=5;
botton_ch.Left:=274;
botton_ch.Top:=10;
botton_rad.Left:=286;
botton_rad.Top:=10;
Btn_list.left:=300;
Btn_list.Top:=8;
aboutinfo.Left:=313;
aboutinfo.Top:=8;
openfile_M.Left:=326;
openfile_M.Top:=8;
other.Left:=339;
other.Top:=8;
botton_min.Left:=349;
botton_min.Top:=8;
botton_exit.left:=359;
botton_exit.Top:=8;
messages_window.Left:=143;
messages_window.Top:=6;
messages_window.Width:=66;
end;

procedure TForm_main.N28Click(Sender: TObject);
begin
popupMenu1.Images:=imagelist1;
Form_list.PopupMenu1.Images:=Form_main.ImageList1;
n28.Checked:=True;
n29.Checked:=False;
end;

procedure TForm_main.N29Click(Sender: TObject);
begin
popupMenu1.Images:=imagelist2;
Form_list.PopupMenu1.Images:=Form_main.ImageList2;
n28.checked:=False;
n29.checked:=True;
end;

procedure TForm_main.N30Click(Sender: TObject);
begin
skinform.Engine:=skinengine1;
Form_list.SkinForm1.Engine:=skinengine1;
n30.Checked:=True;
n31.Checked:=False;
n32.Checked:=False;
n33.Checked:=false;
end;

procedure TForm_main.N31Click(Sender: TObject);
begin
skinform.Engine:=skinengine2;
Form_list.SkinForm1.Engine:=skinengine2;
n30.Checked:=False;
n31.Checked:=True;
n32.Checked:=False;
n33.Checked:=false;
end;

procedure TForm_main.N32Click(Sender: TObject);
begin
skinform.Engine:=skinengine3;
Form_list.SkinForm1.Engine:=skinengine3;
n30.Checked:=False;
n31.Checked:=false;
n32.Checked:=true;
n33.Checked:=false;
end;

procedure TForm_main.N33Click(Sender: TObject);
begin
skinform.Engine:=skinengine4;
Form_list.SkinForm1.Engine:=skinengine4;
n30.Checked:=False;
n31.Checked:=false;
n32.Checked:=false;
n33.Checked:=True;
end;

procedure TForm_main.Timer1Timer(Sender: TObject);
begin
message_word.Left:=message_word.Left-1;
if message_word.Left<-message_word.Width then message_word.Left:=messages_window.Width;
end;

end.
 
谢谢,发分
 

Similar threads

后退
顶部