fix PRINT/DRAW _TIMEOUT and fix redrawing bug.
This commit is contained in:
		
							parent
							
								
									896310e592
								
							
						
					
					
						commit
						df54ab0405
					
				
							
								
								
									
										4
									
								
								st.c
									
									
									
									
									
								
							
							
						
						
									
										4
									
								
								st.c
									
									
									
									
									
								
							| @ -1888,7 +1888,7 @@ expose(XEvent *ev) { | |||||||
| 	if(xw.state & WIN_REDRAW) { | 	if(xw.state & WIN_REDRAW) { | ||||||
| 		if(!e->count) { | 		if(!e->count) { | ||||||
| 			xw.state &= ~WIN_REDRAW; | 			xw.state &= ~WIN_REDRAW; | ||||||
| 			draw(); | 			xcopy(0, 0, term.col, term.row); | ||||||
| 		} | 		} | ||||||
| 	} else | 	} else | ||||||
| 		XCopyArea(xw.dpy, xw.buf, xw.win, dc.gc, e->x-BORDER, e->y-BORDER, | 		XCopyArea(xw.dpy, xw.buf, xw.win, dc.gc, e->x-BORDER, e->y-BORDER, | ||||||
| @ -2028,7 +2028,7 @@ int | |||||||
| last_draw_too_old(void) { | last_draw_too_old(void) { | ||||||
| 	struct timeval now; | 	struct timeval now; | ||||||
| 	gettimeofday(&now, NULL); | 	gettimeofday(&now, NULL); | ||||||
| 	return TIMEDIFF(now, xw.lastdraw) >= PRINT_TIMEOUT/1000; | 	return TIMEDIFF(now, xw.lastdraw) >= DRAW_TIMEOUT/1000; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void | void | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Aurélien Aptel
						Aurélien Aptel