From e080f21757729b0d3844dba94d4f5a5267a5220e Mon Sep 17 00:00:00 2001 From: "Sergey Semyonov (Serge)" Date: Mon, 2 Jun 2008 06:59:22 +0000 Subject: [PATCH] fixed make_button git-svn-id: svn://kolibrios.org@801 a494cfbc-eb01-0410-851d-a64ba20cac60 --- programs/media/ac97snd/ac97snd/ac97wav.c | 30 ---------------- programs/media/ac97snd/ac97snd/k_lib.asm | 44 ++++++++++++------------ 2 files changed, 22 insertions(+), 52 deletions(-) diff --git a/programs/media/ac97snd/ac97snd/ac97wav.c b/programs/media/ac97snd/ac97snd/ac97wav.c index 57dd6b3254..5223e74799 100644 --- a/programs/media/ac97snd/ac97snd/ac97wav.c +++ b/programs/media/ac97snd/ac97snd/ac97wav.c @@ -668,33 +668,3 @@ int __cdecl _stricmp (const char * dst, const char * src) } - -// debug_out_str(formats[fmt]); -// debug_out_str("\x0D\x0A\x00"); - -// debug_out_str("pci cmd: "); -// debug_out_hex(info.pci_cmd); -// debug_out_str("\x0D\x0A\x00"); - -// debug_out_str("irq line: "); -// debug_out_hex(info.irq); -// debug_out_str("\x0D\x0A\x00"); - -// debug_out_str("global control: "); -// debug_out_hex(info.glob_cntrl); -// debug_out_str("\x0D\x0A\x00"); - -// debug_out_str("global status: "); -// debug_out_hex(info.glob_sta); -// debug_out_str("\x0D\x0A\x00"); - - - // call _print_volume - -// debug_out_hex(whdr.nChannels); -// debug_out_str("\x0D\x0A\x00"); -// debug_out_hex(whdr.nSamplesPerSec); -// debug_out_str("\x0D\x0A\x00"); - -// debug_out_hex(fmt); -// debug_out_str("\x0D\x0A\x00"); diff --git a/programs/media/ac97snd/ac97snd/k_lib.asm b/programs/media/ac97snd/ac97snd/k_lib.asm index 3f048da198..b34502aecb 100644 --- a/programs/media/ac97snd/ac97snd/k_lib.asm +++ b/programs/media/ac97snd/ac97snd/k_lib.asm @@ -389,29 +389,29 @@ proc _DrawWindow@36 stdcall, x:dword, y:dword, sx:dword, sy:dword,\ endp align 4 -_make_button@24: -;arg1 - x -;arg2 - y -;arg3 - xsize -;arg4 - ysize -;arg5 - id -;arg6 - color +proc _make_button@24 stdcall,x:dword, y:dword, \ + xsize:dword, ysize:dword, \ + id:dword, color:dword - push ebx - push ecx - push esi - mov ebx,[esp+12] - shl ebx,16 - mov bx,[esp+20] - mov ecx,[esp+16] - shl ecx,16 - mov cx,[esp+24] - mov edx,[esp+28] - mov esi,[esp+32] - mov eax,8 - int 0x40 - pop esi ecx ebx - ret 24 + push ebx + push esi + + mov ebx,[x] + mov ecx,[y] + shl ebx,16 + shl ecx,16 + mov bx, word [xsize] + mov cx, word [ysize] + + mov edx,[id] + mov esi,[color] + + mov eax,8 + int 0x40 + pop esi + pop ebx + ret +endp align 4 _draw_bar@20: