comparison mcabber/src/main.c @ 156:439b750d99fa

[/trunk] Changeset 168 by mikael * Reset refresh when a key is pressed.
author mikael
date Sun, 01 May 2005 14:49:51 +0000
parents 05f606cfb9e4
children 44c6410b4845
comparison
equal deleted inserted replaced
155:8a54d46e889a 156:439b750d99fa
199 key = scr_Getch(); 199 key = scr_Getch();
200 200
201 // The refresh is really an ugly hack, but we need to call doupdate() 201 // The refresh is really an ugly hack, but we need to call doupdate()
202 // from time to time to catch the RESIZE events, because getch keep 202 // from time to time to catch the RESIZE events, because getch keep
203 // returning ERR until a real key is pressed :-( 203 // returning ERR until a real key is pressed :-(
204 if (key != ERR) 204 if (key != ERR) {
205 ret = process_key(key); 205 ret = process_key(key);
206 else if (refresh++ > 1) { 206 refresh = 0;
207 } else if (refresh++ > 1) {
207 doupdate(); 208 doupdate();
208 refresh = 0; 209 refresh = 0;
209 } 210 }
210 211
211 if (key != KEY_RESIZE) 212 if (key != KEY_RESIZE)