mirror of
https://github.com/reactos/reactos.git
synced 2024-12-27 09:34:43 +00:00
[NTUSER] Fix issue when cursor/caret is static
Also remove the check that Windows doesn't do. CORE-17929
This commit is contained in:
parent
c0eb407130
commit
9701bbcf6d
1 changed files with 10 additions and 14 deletions
|
@ -10,11 +10,6 @@
|
|||
#include <win32k.h>
|
||||
DBG_DEFAULT_CHANNEL(UserCaret);
|
||||
|
||||
/* DEFINES *****************************************************************/
|
||||
|
||||
#define MIN_CARETBLINKRATE 100
|
||||
#define MAX_CARETBLINKRATE 10000
|
||||
|
||||
/* FUNCTIONS *****************************************************************/
|
||||
|
||||
VOID FASTCALL
|
||||
|
@ -189,13 +184,6 @@ IntSetCaretBlinkTime(UINT uMSeconds)
|
|||
{
|
||||
/* Don't save the new value to the registry! */
|
||||
|
||||
/* Windows doesn't do this check */
|
||||
if((uMSeconds < MIN_CARETBLINKRATE) || (uMSeconds > MAX_CARETBLINKRATE))
|
||||
{
|
||||
EngSetLastError(ERROR_INVALID_PARAMETER);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
gpsi->dtCaretBlink = uMSeconds;
|
||||
|
||||
return TRUE;
|
||||
|
@ -300,7 +288,15 @@ BOOL FASTCALL co_UserShowCaret(PWND Window OPTIONAL)
|
|||
{
|
||||
IntNotifyWinEvent(EVENT_OBJECT_SHOW, pWnd, OBJID_CARET, OBJID_CARET, 0);
|
||||
}
|
||||
IntSetTimer(pWnd, IDCARETTIMER, gpsi->dtCaretBlink, CaretSystemTimerProc, TMRF_SYSTEM);
|
||||
if ((INT)gpsi->dtCaretBlink > 0)
|
||||
{
|
||||
IntSetTimer(pWnd, IDCARETTIMER, gpsi->dtCaretBlink, CaretSystemTimerProc, TMRF_SYSTEM);
|
||||
}
|
||||
else if (ThreadQueue->CaretInfo.Visible)
|
||||
{
|
||||
ThreadQueue->CaretInfo.Showing = 1;
|
||||
co_IntDrawCaret(pWnd, &ThreadQueue->CaretInfo);
|
||||
}
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
@ -366,7 +362,7 @@ NtUserCreateCaret(
|
|||
ThreadQueue->CaretInfo.Visible = 0;
|
||||
ThreadQueue->CaretInfo.Showing = 0;
|
||||
|
||||
IntSetTimer( Window, IDCARETTIMER, gpsi->dtCaretBlink, CaretSystemTimerProc, TMRF_SYSTEM );
|
||||
IntSetTimer(Window, IDCARETTIMER, gpsi->dtCaretBlink, CaretSystemTimerProc, TMRF_SYSTEM);
|
||||
|
||||
IntNotifyWinEvent(EVENT_OBJECT_CREATE, Window, OBJID_CARET, CHILDID_SELF, 0);
|
||||
|
||||
|
|
Loading…
Reference in a new issue