fn draw_after_keypress(&mut self)
	{
		if self.run_low == false
		{
			self.draw_optimized();
			return;
		}
		let mut draw = true;
		match self.last_draw.elapsed()
		{
			Ok(v) => {
				if v.subsec_nanos() < FRAME_LIMIT
				{
					self.skipped_draw = true;
					draw = false;
				}
			},
			Err(_) => {}
		};
		if draw == false
		{
			return;
		}
		self.last_draw = SystemTime::now();
		self.draw_optimized();
		
	}
//check the time elapsed and limit redraws to 4 per second
check the time elapsed and limit redraws to 4 per second
check the time elapsed and limit redraws to 4 per second
fn draw_after_keypress(&mut self)
	{
		if self.run_low == false
		{
			self.draw_optimized();
			return;
		}
		let mut draw = true;
		match self.last_draw.elapsed()
		{
			Ok(v) => {
				if v.subsec_nanos() < FRAME_LIMIT
				{
					self.skipped_draw = true;
					draw = false;
				}
			},
			Err(_) => {}
		};
		if draw == false
		{
			return;
		}
		self.last_draw = SystemTime::now();
		self.draw_optimized();
	}
fn draw_after_keypress ( & mut self ) { if self . run_low == false { self . draw_optimized ( ) ; return ; } let mut draw = true ; match self . last_draw . elapsed ( ) { Ok ( v ) => { if v . subsec_nanos ( ) < FRAME_LIMIT { self . skipped_draw = true ; draw = false ; } } , Err ( _ ) => { } } ; if draw == false { return ; } self . last_draw = SystemTime :: now ( ) ; self . draw_optimized ( ) ; }
check the time elapsed and limit redraws to 4 per second
check the time elapsed and limit redraws to 4 per second
&mut self
&mut self