comparison mcabber/src/screen.c @ 445:7bf6c0c6a714

Fix command completion (2nd argument)
author Mikael Berthe <mikael@lilotux.net>
date Sun, 25 Sep 2005 00:40:25 +0200
parents 5927c3bfba13
children 03bb57383cea
comparison
equal deleted inserted replaced
444:5927c3bfba13 445:7bf6c0c6a714
1343 1343
1344 nrow = which_row(&row); 1344 nrow = which_row(&row);
1345 1345
1346 // a) No completion if no leading slash ('cause not a command) 1346 // a) No completion if no leading slash ('cause not a command)
1347 // b) We can't have more than 2 parameters (we use 2 flags) 1347 // b) We can't have more than 2 parameters (we use 2 flags)
1348 if (nrow < 0 || nrow > 2) return; 1348 if (nrow < 0 || (nrow == 3 && !completion_started) || nrow > 3) return;
1349 1349
1350 if (nrow == 0) { // Command completion 1350 if (nrow == 0) { // Command completion
1351 row = &inputLine[1]; 1351 row = &inputLine[1];
1352 compl_categ = COMPL_CMD; 1352 compl_categ = COMPL_CMD;
1353 } else { // Other completion, depending on the command 1353 } else { // Other completion, depending on the command