[LinksOS CVS Commit]kernel/hw/mouse mouse.cpp,1.5,1.6
Status: Inactive
Brought to you by:
terencevs
|
From: <ke...@to...> - 2003-01-17 20:13:54
|
Update of /cvsroot/linksos/kernel/hw/mouse In directory rix.tossell.net:/tmp/cvs-serv29860 Modified Files: mouse.cpp Log Message: Title: ASM Syntax and Scope Changes: Moved const int MAX_X and MAX_Y to global scope for the translation unit. Added $ to operands in int asm-calls. Effects: Code compiles and looks like it's ready to link in. a=kennyt Index: mouse.cpp =================================================================== RCS file: /cvsroot/linksos/kernel/hw/mouse/mouse.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** mouse.cpp 17 Jan 2003 02:58:01 -0000 1.5 --- mouse.cpp 17 Jan 2003 20:13:40 -0000 1.6 *************** *** 1,10 **** void show_mouse(void); // replace (void) with bipmap ! int main() ! { ! const int MAX_Y = 480; ! const int MAX_X = 640; asm volatile ( "mov %ax, 1\n" // Set ax to show the mouse ! "int 0x33\n" // Call the mouse interrupt // Constrain mouse horizontal movement --- 1,11 ---- void show_mouse(void); // replace (void) with bipmap ! ! const int MAX_Y = 480; ! const int MAX_X = 640; ! ! int main() { asm volatile ( "mov %ax, 1\n" // Set ax to show the mouse ! "int $0x33\n" // Call the mouse interrupt // Constrain mouse horizontal movement *************** *** 13,17 **** "mov %dx, MAX_X-2\n" // Max range ! "int 0x33\n" // Call the mouse interrupt // Constrain mouse vertical movement --- 14,18 ---- "mov %dx, MAX_X-2\n" // Max range ! "int $0x33\n" // Call the mouse interrupt // Constrain mouse vertical movement *************** *** 20,24 **** "mov %dx, MAX_Y-2\n" // Max range ! "int 0x33\n" // Call the mouse interrupt ); } --- 21,25 ---- "mov %dx, MAX_Y-2\n" // Max range ! "int $0x33\n" // Call the mouse interrupt ); } |