'    FILE:          CreateINI.vbs
'    DESCRIPTION:   自定义软件界面LOGO(注意位图尺寸)
'    FOR:           QQ登录助手新内核正式版V3.1B2以上版本
'    USAGE:         QQ登录助手目录中运行此脚本生成目录结构
'    NOTICE:        此文件务必从燕过留痕工作室下载
'    AUTHOR:        ZhangXin 08/08/2008 BeiJing
'                   Http://yanstudio.cccpan.com
'    MODIFIED:      ZhangXin 10/01/2008 BeiJing
'                   ZhangXin 10/10/2008 BeiJing
'                   ZhangXin 11/08/2008 BeiJing
'                   ZhangXin 09/25/2009 ShangHai
'                   ZhangXin 10/01/2009 BeiJing
'                   ZhangXin 03/30/2011 ZhuHai

On Error Resume Next
if (vbYes=MsgBox("脚本将自动生成Skin目录结构,继续吗?",vbyesno+vbquestion,"提示")) then
	Set fso = CreateObject("Scripting.FileSystemObject")
	if not fso.FolderExists("Skin") then
		set folder = fso.CreateFolder("Skin")
		folder.Close
	end if
	skinname = InputBox("请输入软件皮肤的名称:")
	if skinname = "" then
		MsgBox "需要指定软件皮肤的名称,请重新执行脚本!",vbok,"提示"
		WScript.Quit
	end if
	Set fso = CreateObject("Scripting.FileSystemObject")
	skinname = "Skin\" & skinname
	if not fso.FolderExists(skinname) then
		set folder = fso.CreateFolder(skinname)
		folder.Close
	end if
	msg = "===============位图尺寸说明===============" & chr(13) & chr(10) & chr(13) & chr(10)
	msg = msg & "1.登录助手界面LOGO位图的尺寸为:320(宽)*57(高)。" & chr(13) & chr(10)
	msg = msg & "2.添加账号界面LOGO位图的尺寸为:57(宽)*231(高)。" & chr(13) & chr(10)
	msg = msg & "3.软件登录界面LOGO位图的尺寸为:320(宽)*60(高)。" & chr(13) & chr(10)
	msg = msg & "4.用户注册界面LOGO位图的尺寸为:281(宽)*50(高)。" & chr(13) & chr(10)
	msg = msg & "5.信息修改界面LOGO位图的尺寸为:281(宽)*50(高)。" & chr(13) & chr(10) & chr(13) & chr(10)
	msg = msg & "请将LOGO位图文件拷贝到" & skinname & "目录下,准备好后点击确定按钮!"
	MsgBox msg,vbokonly+vbinformation,"提示"
	if fso.FileExists(skinname & "\Default.ini") then
		fso.DeleteFile skinname & "\Default.ini",true 
	end if
	set file = fso.CreateTextFile(skinname & "\Default.ini")
	file.WriteLine(";****************************************")
	file.WriteLine(";QQ登录助手新内核正式版LOGO配置文件")
	file.WriteLine(";此目录结构由CreateIni自动生成")
	file.WriteLine(";请将LOGO位图文件拷贝到Skin目录")
	file.WriteLine(";Bitmap1代表登录助手界面LOGO位图的名称")
	file.WriteLine(";Bitmap2代表添加账号界面LOGO位图的名称")
	file.WriteLine(";Bitmap3代表软件登录界面LOGO位图的名称")
	file.WriteLine(";Bitmap4代表用户注册界面LOGO位图的名称")
	file.WriteLine(";Bitmap5代表信息修改界面LOGO位图的名称")
	file.WriteLine(";Bitmap1的位图大小为:320(宽)*57(高)")
	file.WriteLine(";Bitmap2的位图大小为:57(宽)*231(高)")
	file.WriteLine(";Bitmap3的位图大小为:320(宽)*60(高)")
	file.WriteLine(";Bitmap4的位图大小为:281(宽)*50(高)")
	file.WriteLine(";Bitmap5的位图大小为:281(宽)*50(高)")
	file.WriteLine(";****************************************")
	file.WriteLine("")
	file.WriteLine("[LOGO]")
	bmpname1 = InputBox("输入登录助手界面LOGO位图名称(带扩展名):" & chr(13) & chr(10) & chr(13) & chr(10) & "(允许为空,输入NULL则不显示LOGO)","文件名称")
	file.WriteLine("Bitmap1=" & bmpname1)
	bmpname2 = InputBox("输入添加账号界面LOGO位图名称(带扩展名):" & chr(13) & chr(10) & chr(13) & chr(10) & "(允许为空,暂不支持隐藏LOGO)","文件名称")
	file.WriteLine("Bitmap2=" & bmpname2)
	bmpname3 = InputBox("输入软件登录界面LOGO位图名称(带扩展名):" & chr(13) & chr(10) & chr(13) & chr(10) & "(允许为空,暂不支持隐藏LOGO)","文件名称")
	file.WriteLine("Bitmap3=" & bmpname3)
	bmpname4 = InputBox("输入用户注册界面LOGO位图名称(带扩展名):" & chr(13) & chr(10) & chr(13) & chr(10) & "(允许为空,暂不支持隐藏LOGO)","文件名称")
	file.WriteLine("Bitmap4=" & bmpname4)
	bmpname5 = InputBox("输入信息修改界面LOGO位图名称(带扩展名):" & chr(13) & chr(10) & chr(13) & chr(10) & "(允许为空,暂不支持隐藏LOGO)","文件名称")
	file.WriteLine("Bitmap5=" & bmpname5)
	file.WriteLine("")
	file.WriteLine(";****************************************")
	file.WriteLine(";Name代表登录助手皮肤作者名称")
	file.WriteLine(";Mail代表登录助手皮肤作者邮箱")
	file.WriteLine(";HomePage代表登录助手皮肤作者主页")
	file.WriteLine(";****************************************")
	file.WriteLine("")	
	file.WriteLine("[AUTHOR]")
	authorname = InputBox("请输入软件皮肤作者:")
	file.WriteLine("Name=" & authorname)
	authoremail = InputBox("请输入作者Email:")
	file.WriteLine("Mail=" & authoremail)	
	authorhomepage = InputBox("请输入作者主页:")
	file.WriteLine("HomePage=" & authorhomepage)
	file.Close
	set fso = nothing
	MsgBox "Skin目录结构已经生成,如有问题请重新执行脚本或手动维护Default.ini.",vbokonly+vbinformation,"提示"
end if
