… | |
… | |
2 | * File: keyboard.C |
2 | * File: keyboard.C |
3 | *----------------------------------------------------------------------* |
3 | *----------------------------------------------------------------------* |
4 | * |
4 | * |
5 | * All portions of code are copyright by their respective author/s. |
5 | * All portions of code are copyright by their respective author/s. |
6 | * Copyright (c) 2005 WU Fengguang |
6 | * Copyright (c) 2005 WU Fengguang |
7 | * Copyright (c) 2005-2006 Marc Lehmann <pcg@goof.com> |
7 | * Copyright (c) 2005-2006 Marc Lehmann <schmorp@schmorp.de> |
8 | * |
8 | * |
9 | * This program is free software; you can redistribute it and/or modify |
9 | * This program is free software; you can redistribute it and/or modify |
10 | * it under the terms of the GNU General Public License as published by |
10 | * it under the terms of the GNU General Public License as published by |
11 | * the Free Software Foundation; either version 2 of the License, or |
11 | * the Free Software Foundation; either version 2 of the License, or |
12 | * (at your option) any later version. |
12 | * (at your option) any later version. |
… | |
… | |
66 | |
66 | |
67 | static void |
67 | static void |
68 | output_string (rxvt_term *rt, const char *str) |
68 | output_string (rxvt_term *rt, const char *str) |
69 | { |
69 | { |
70 | if (strncmp (str, "command:", 8) == 0) |
70 | if (strncmp (str, "command:", 8) == 0) |
71 | rt->cmd_write (str + 8, strlen (str) - 8); |
71 | rt->cmdbuf_append (str + 8, strlen (str) - 8); |
72 | else if (strncmp (str, "perl:", 5) == 0) |
72 | else if (strncmp (str, "perl:", 5) == 0) |
73 | HOOK_INVOKE((rt, HOOK_USER_COMMAND, DT_STR, str + 5, DT_END)); |
73 | HOOK_INVOKE((rt, HOOK_USER_COMMAND, DT_STR, str + 5, DT_END)); |
74 | else |
74 | else |
75 | rt->tt_write (str, strlen (str)); |
75 | rt->tt_write (str, strlen (str)); |
76 | } |
76 | } |