summaryrefslogtreecommitdiffstats
path: root/src/c_keys.c
diff options
context:
space:
mode:
authorsalad <fmoenne-@student.le-101.fr>2020-11-02 15:23:19 +0100
committersalad <fmoenne-@student.le-101.fr>2020-11-02 15:23:19 +0100
commit541d187f9fa37f79b5815a5d4d52ac5ad5bf2bab (patch)
tree6098829ac4007b672893e800ea56453071672973 /src/c_keys.c
parentomw to sed-town (diff)
download42-minishell-541d187f9fa37f79b5815a5d4d52ac5ad5bf2bab.tar.gz
42-minishell-541d187f9fa37f79b5815a5d4d52ac5ad5bf2bab.tar.bz2
42-minishell-541d187f9fa37f79b5815a5d4d52ac5ad5bf2bab.tar.xz
42-minishell-541d187f9fa37f79b5815a5d4d52ac5ad5bf2bab.tar.zst
42-minishell-541d187f9fa37f79b5815a5d4d52ac5ad5bf2bab.zip
merge happenned
Diffstat (limited to '')
-rw-r--r--src/c_keys.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/c_keys.c b/src/c_keys.c
index e0f734c..593c6d4 100644
--- a/src/c_keys.c
+++ b/src/c_keys.c
@@ -17,7 +17,7 @@
#include "c_utils.h"
#include "m_prompt.h"
-int16_t
+short
c_ctrl_l(char *line, t_caps *tcaps, t_msh *msh)
{
tputs(tgetstr("cl", NULL), 1, ft_putchar);
@@ -26,11 +26,11 @@ int16_t
return (1);
}
-int16_t
- c_home_key(uint32_t plen, t_caps *tcaps)
+short
+ c_home_key(unsigned int plen, t_caps *tcaps)
{
- uint32_t i;
- int16_t j;
+ unsigned int i;
+ short j;
i = tcaps->cpos;
j = tcaps->lpos;
@@ -53,11 +53,11 @@ int16_t
return (1);
}
-int16_t
- c_end_key(uint16_t size, uint32_t plen, t_caps *tcaps)
+short
+ c_end_key(unsigned short size, unsigned int plen, t_caps *tcaps)
{
- uint16_t i;
- uint16_t j;
+ unsigned short i;
+ unsigned short j;
i = tcaps->cpos;
j = tcaps->lpos;
@@ -82,8 +82,8 @@ int16_t
return (1);
}
-int16_t
- c_key_right(uint32_t len, uint32_t plen, t_caps *tcaps)
+short
+ c_key_right(unsigned int len, unsigned int plen, t_caps *tcaps)
{
if ((((tcaps->cpos + plen + 1) % (tcaps->ws.ws_col)) == 0) &&
tcaps->cpos < len)
@@ -101,10 +101,10 @@ int16_t
return (1);
}
-int16_t
- c_key_left(uint32_t plen, t_caps *tcaps)
+short
+ c_key_left(unsigned int plen, t_caps *tcaps)
{
- int32_t pos;
+ int pos;
pos = -1;
if (((tcaps->cpos + plen) % tcaps->ws.ws_col) == 0 &&