Hi!
I'm trying to make my text slide down slowly while key is pressed down.
As You can see, I'm using *pause* to stop text from immidiate scrolling from top to the very bottom, but it still just freezes whole screen for a sec. and then all I see is bottom of the text. Probably I need some original solution, because as I know from GledDocs *pause* function works a bit differently from what I need, so I'm really looking forward for help!
I'm trying to make my text slide down slowly while key is pressed down.
- Code:
HRESULT InitialApplication::onKeyDown(DWORD dwKey, KeyList& keylist)
{
while ((textpos > textposd) && (keylist.vkDown == dwKey))
{
textupanddown = textupanddown - 15;
textpos = textpos - 1;
pause(150);
}
while ((textpos < 0) && (keylist.vkUp == dwKey))
{
textupanddown = textupanddown + 15;
textpos = textpos + 1;
pause(150);
}
return ReturnCode::OK;
}
As You can see, I'm using *pause* to stop text from immidiate scrolling from top to the very bottom, but it still just freezes whole screen for a sec. and then all I see is bottom of the text. Probably I need some original solution, because as I know from GledDocs *pause* function works a bit differently from what I need, so I'm really looking forward for help!
