mirror of
				https://github.com/tmux/tmux.git
				synced 2025-11-04 00:56:10 +00:00 
			
		
		
		
	Unbreak prefix as binding.
This commit is contained in:
		
							
								
								
									
										25
									
								
								server.c
									
									
									
									
									
								
							
							
						
						
									
										25
									
								
								server.c
									
									
									
									
									
								
							@@ -1,4 +1,4 @@
 | 
			
		||||
/* $Id: server.c,v 1.101 2009-01-14 22:13:30 nicm Exp $ */
 | 
			
		||||
/* $Id: server.c,v 1.102 2009-01-14 22:29:28 nicm Exp $ */
 | 
			
		||||
 | 
			
		||||
/*
 | 
			
		||||
 * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
 | 
			
		||||
@@ -598,15 +598,12 @@ server_handle_client(struct client *c)
 | 
			
		||||
			continue;
 | 
			
		||||
		wp = wl->window->active;	/* could die - do each loop */
 | 
			
		||||
		
 | 
			
		||||
		/* Prefix key pressed. */
 | 
			
		||||
		if (key == prefix) {
 | 
			
		||||
			c->flags |= CLIENT_PREFIX;
 | 
			
		||||
			continue;
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		/* Other key and no previous prefix key. */
 | 
			
		||||
		/* No previous prefix key. */
 | 
			
		||||
		if (!(c->flags & CLIENT_PREFIX)) {
 | 
			
		||||
			window_pane_key(wp, c, key);
 | 
			
		||||
			if (key == prefix)
 | 
			
		||||
				c->flags |= CLIENT_PREFIX;
 | 
			
		||||
			else
 | 
			
		||||
				window_pane_key(wp, c, key);
 | 
			
		||||
			continue;
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
@@ -616,7 +613,10 @@ server_handle_client(struct client *c)
 | 
			
		||||
			/* If repeating, treat this as a key, else ignore. */
 | 
			
		||||
			if (c->flags & CLIENT_REPEAT) {
 | 
			
		||||
				c->flags &= ~CLIENT_REPEAT;
 | 
			
		||||
				window_pane_key(wp, c, key);
 | 
			
		||||
				if (key == prefix)
 | 
			
		||||
					c->flags |= CLIENT_PREFIX;
 | 
			
		||||
				else
 | 
			
		||||
					window_pane_key(wp, c, key);
 | 
			
		||||
			}
 | 
			
		||||
			continue;
 | 
			
		||||
		}
 | 
			
		||||
@@ -625,7 +625,10 @@ server_handle_client(struct client *c)
 | 
			
		||||
		/* If already repeating, but this key can't repeat, skip it. */
 | 
			
		||||
		if (c->flags & CLIENT_REPEAT && !(flags & CMD_CANREPEAT)) {
 | 
			
		||||
			c->flags &= ~CLIENT_REPEAT;
 | 
			
		||||
			window_pane_key(wp, c, key);
 | 
			
		||||
			if (key == prefix)
 | 
			
		||||
				c->flags |= CLIENT_PREFIX;
 | 
			
		||||
			else
 | 
			
		||||
				window_pane_key(wp, c, key);
 | 
			
		||||
			continue;
 | 
			
		||||
		}
 | 
			
		||||
		
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user