// === CONSTANTS ===\r
#define FLAG_LFB 0x1\r
#define VESA_DEFAULT_FRAMEBUFFER (KERNEL_BASE|0xA0000)\r
+#define VESA_CURSOR_PERIOD 1000\r
\r
// === PROTOTYPES ===\r
int Vesa_Install(char **Arguments);\r
}\r
else {\r
if(giVesaCursorTimer == -1)\r
- giVesaCursorTimer = Time_CreateTimer(500, Vesa_FlipCursor, Node);\r
+ giVesaCursorTimer = Time_CreateTimer(VESA_CURSOR_PERIOD, Vesa_FlipCursor, Node);\r
}\r
- \r
- Log_Debug("VESA", "Cursor at (%i,%i), timer %i",\r
- giVesaCursorX, giVesaCursorY, giVesaCursorTimer);\r
return 0;\r
\r
case VIDEO_IOCTL_REQLFB: // Request Linear Framebuffer\r
// Check for fast return\r
if(mode == giVesaCurrentMode) return 1;\r
\r
+ Time_RemoveTimer(giVesaCursorTimer);\r
+ \r
LOCK( &glVesa_Lock );\r
\r
gpVesa_BiosState->AX = 0x4F02;\r
*/\r
void Vesa_FlipCursor(void *Arg)\r
{\r
- int pitch = gVesa_Modes[giVesaCurrentMode].pitch;\r
+ int pitch = gVesa_Modes[giVesaCurrentMode].pitch/4;\r
int x = giVesaCursorX*giVT_CharWidth;\r
int y = giVesaCursorY*giVT_CharHeight;\r
int i;\r
\r
if(giVesaCursorX < 0 || giVesaCursorY < 0) return;\r
\r
- for( i = 0; i < giVT_CharHeight; i++ )\r
- fb[(y+i)*pitch+x] = fb[(y+i)*pitch+x];\r
+ for( i = 1; i < giVT_CharHeight-1; i++ )\r
+ fb[(y+i)*pitch+x] = ~fb[(y+i)*pitch+x];\r
\r
- giVesaCursorTimer = Time_CreateTimer(500, Vesa_FlipCursor, Arg);\r
+ giVesaCursorTimer = Time_CreateTimer(VESA_CURSOR_PERIOD, Vesa_FlipCursor, Arg);\r
}\r
\r
// ------------------------\r