Corrections shell/console/atom
This commit is contained in:
		
							parent
							
								
									46731e79d8
								
							
						
					
					
						commit
						2177ea9449
					
				
					 1 changed files with 9 additions and 13 deletions
				
			
		|  | @ -56,11 +56,8 @@ func (in *input) restart() { | |||
| 			n := in.readRune() | ||||
| 			next <- n | ||||
| 
 | ||||
| 			needClose := !n.IsOk() | ||||
| 			if !needClose { | ||||
| 			r, ok := n.Ok() | ||||
| 				needClose = ok && (r == Lf || r == Cr || r == C_C || r == C_D) | ||||
| 			} | ||||
| 			needClose := !ok || r == Lf || r == Cr || r == C_C || r == C_D | ||||
| 
 | ||||
| 			if needClose { | ||||
| 				close(next) | ||||
|  | @ -317,22 +314,21 @@ func (in *input) nextChar() (key nkey) { | |||
| 		return | ||||
| 	} | ||||
| 
 | ||||
| 	var s Sequence | ||||
| 	switch r { | ||||
| 	case Bs: | ||||
| 		s = A_Bs | ||||
| 		key = nk(keyS(A_Bs)) | ||||
| 	case 'O': | ||||
| 		return in.escO() | ||||
| 		key = in.escO() | ||||
| 	case '[': | ||||
| 		return in.escBracket() | ||||
| 		key = in.escBracket() | ||||
| 	case 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', | ||||
| 		'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z': | ||||
| 		s = Sequence(r << 16) | ||||
| 	default: | ||||
| 		return | ||||
| 		key = nk(keyS(Sequence(r << 16))) | ||||
| 		//default: | ||||
| 		//	return | ||||
| 	} | ||||
| 
 | ||||
| 	in.clear() | ||||
| 
 | ||||
| 	return nk(keyS(s)) | ||||
| 	return | ||||
| } | ||||
|  |  | |||
		Loading…
	
	Add table
		
		Reference in a new issue
	
	 Benjamin VAUDOUR
						Benjamin VAUDOUR