sforce5
Олл фо ЛулзЪ
- Сообщения
- 160
- Репутация
- 41
Пожалуйста, не судите строго, но я её сделать до конца сам не смогу. И всё таки наработки есть...
Функции помеченные комментарием "NOT WORKING" не могу сделать
Просьба - помочь в доработке
Ссылка на архив: STEAM_UDF.rar (в архиве присутствует графика)
На основе:
http://www.autoitscript.com/forum/index.php?showtopic=95043
Функции помеченные комментарием "NOT WORKING" не могу сделать
Просьба - помочь в доработке
Ссылка на архив: STEAM_UDF.rar (в архиве присутствует графика)
Код:
;Последнее обновление 10 февраля (3:54)
;Добавлено создание ProgressBar
#include <GUIConstants.au3>
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <ProgressConstants.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
$gui = _Steam_GuiCreate("Valve Steam Dialog", 640, 480)
_Steam_GUICtrlCreateGroup("Example Group", 10, 10, 620, 437)
_Steam_GUICtrlCreateButton("Example Button", 520, 412, 100, 20)
_Steam_GUICtrlCreateInput("Example Input", 20, 45, 300, 20)
_Steam_GUICtrlCreateLabel("Example Label", 20, 75, 300, 20)
_Steam_GUICtrlCreateProgress(20, 125, 300, 20)
GUICtrlSetData(-1, 50)
GUISetState(@SW_SHOW)
While 1
Sleep(1000)
WEnd
Func _Steam_GuiCreate($sTitle, $iWidth, $iHeight, $Left = -1, $iTop = -1, $hParent = 0, $aFont = "Tahoma")
Local $SteamGui = GUICreate($sTitle, $iWidth, $iHeight, $Left, $iTop, BitOR($WS_POPUP, $WS_SYSMENU, $WS_BORDER, $WS_MINIMIZEBOX), -1, $hParent)
GUISetFont(8, 400, 0, $aFont)
GUISetBkColor(0x494E49)
GUICtrlCreatePic('hdr.bmp', 0, 0, $iWidth - 16, 20, $SS_NOTIFY, $GUI_WS_EX_PARENTDRAG)
GUICtrlCreatePic('hdr.bmp', $iWidth - 16, 0, 11, 5, $SS_NOTIFY, $GUI_WS_EX_PARENTDRAG)
GUICtrlCreatePic('hdr.bmp', $iWidth - 16, 16, 11, 4, $SS_NOTIFY, $GUI_WS_EX_PARENTDRAG)
GUICtrlCreatePic('hdr.bmp', $iWidth - 5, 0, 5, 20, $SS_NOTIFY, $GUI_WS_EX_PARENTDRAG)
GUICtrlCreateGraphic(0, 20, 1, $iHeight)
GUICtrlSetColor(-1, 0x5A6A50)
GUICtrlCreateGraphic($iWidth - 1, 20, 1, $iHeight)
GUICtrlSetColor(-1, 0x5A6A50)
GUICtrlCreateGraphic(0, $iHeight - 1, $iWidth, 1)
GUICtrlSetColor(-1, 0x5A6A50)
Local $hCloseBtn = GUICtrlCreatePic('cls.bmp', $iWidth - 16, 5, 11, 11, $SS_NOTIFY, $GUI_WS_EX_PARENTDRAG)
Local $hHeader = GUICtrlCreateLabel($sTitle, 6, 0, $iWidth - 22, 20, $SS_CENTERIMAGE)
GUICtrlSetColor(-1, 0xD8DED3)
GUICtrlSetBkColor(-1, 0x5A6A50)
Return $SteamGui
EndFunc
Func _Steam_GUICtrlCreateButton($sText, $iLeft, $iTop, $iWidth, $iHeight, $sFont = "Tahoma")
Local $hButton = GUICtrlCreateLabel($sText, $iLeft + 3, $iTop + 26, $iWidth - 6, $iHeight - 6, $SS_CENTER)
GUICtrlSetBkColor(-1, 0x494E49)
GUICtrlSetFont(-1, 8, 800, 0, $sFont)
GUICtrlSetColor(-1, 0xC4B550)
GUICtrlCreateGraphic($iLeft, $iTop + 23, $iWidth, $iHeight)
GUICtrlSetColor(-1, 0x636763)
Return $hButton
EndFunc
;NOT WORKING
Func _Steam_GUICtrlCreateCheckbox($sText, $iLeft, $iTop, $iWidth, $iHeight, $sFont = "Tahoma")
Local $hButton = GUICtrlCreateCheckbox($sText, $iLeft, $iTop + 23, $iWidth, $iHeight)
GUICtrlSetColor(-1, 0x494E49)
GUICtrlSetFont(-1, 8, 800, 0, $sFont)
Return $hButton
EndFunc
Func _Steam_GuiCtrlCreateGroup($sText, $iLeft, $iTop, $iWidth, $iHeight, $sFont = "Tahoma")
Local $hGroup = GUICtrlCreateLabel($sText, $iLeft + 5, $iTop + 23, $iWidth - 10, 15, $SS_CENTERIMAGE)
GUICtrlSetFont(-1, 8, 800, 0, $sFont)
GUICtrlSetColor(-1, 0xC4B550)
GUICtrlCreateGraphic($iLeft, $iTop + 40, $iWidth, 1)
GUICtrlSetColor(-1, 0x636763)
GUICtrlSetState(-1, $GUI_DISABLE)
GUICtrlCreateGraphic($iLeft, $iTop + 20, $iWidth, $iHeight)
GUICtrlSetColor(-1, 0x686A65)
GUICtrlSetState(-1, $GUI_DISABLE)
Return $hGroup
EndFunc
Func _Steam_GUICtrlCreateInput($sText, $iLeft, $iTop, $iWidth, $iHeight, $sFont = "Tahoma")
Local $hInput = GUICtrlCreateInput($sText, $iLeft + 3, $iTop + 26, $iWidth - 6, $iHeight - 6, -1, $WS_EX_WINDOWEDGE)
GUICtrlSetBkColor(-1, 0x494E49)
GUICtrlSetFont(-1, 8, 800, 0, $sFont)
GUICtrlSetColor(-1, 0xC4B550)
GUICtrlCreateGraphic($iLeft, $iTop + 23, $iWidth, $iHeight)
GUICtrlSetColor(-1, 0x636763)
Return $hInput
EndFunc
Func _Steam_GUICtrlCreateLabel($sText, $iLeft, $iTop, $iWidth, $iHeight, $sFont = "Tahoma")
Local $hLabel = GUICtrlCreateLabel($sText, $iLeft, $iTop + 23, $iWidth, $iHeight)
GUICtrlSetBkColor(-1, 0x494E49)
GUICtrlSetFont(-1, 8, 800, 0, $sFont)
GUICtrlSetColor(-1, 0xC4B550)
Return $hLabel
EndFunc
Func _Steam_GUICtrlCreateProgress($iLeft, $iTop, $iWidth, $iHeight)
Local $hProgress = GUICtrlCreateProgress($iLeft, $iTop + 23, $iWidth, $iHeight)
DllCall("UxTheme.dll", "int", "SetWindowTheme", "hwnd", GUICtrlGetHandle(-1), "wstr", 0, "wstr", 0)
GUICtrlSetStyle($hProgress, BitOr($GUI_SS_DEFAULT_PROGRESS, $PBS_SMOOTH))
GUICtrlSetColor(-1, 0xC4B550)
GUICtrlSetBkColor(-1, 0x636763)
Return $hProgress
EndFunc
;NOT WORKING
Func _Steam_GUICtrlCreateRadio($sText, $iLeft, $iTop, $iWidth, $iHeight, $sFont = "Tahoma")
Local $hLabel = GUICtrlCreateRadio($sText, $iLeft, $iTop + 23, $iWidth, $iHeight)
GUICtrlSetFont(-1, 8, 800, 0, $sFont)
GUICtrlSetColor(-1, 0xC4B550)
Return $hLabel
EndFunc
На основе:
http://www.autoitscript.com/forum/index.php?showtopic=95043