Changeset 4b660cc for commands.c
- Timestamp:
- Dec 23, 2003, 4:13:43 PM (21 years ago)
- Branches:
- master, barnowl_perlaim, debian, owl, release-1.10, release-1.4, release-1.5, release-1.6, release-1.7, release-1.8, release-1.9
- Children:
- 8b16467
- Parents:
- c65d81e
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
commands.c
rc65d81e r4b660cc 451 451 452 452 OWLCMD_ARGS("zaway", owl_command_zaway, OWL_CTX_INTERACTIVE, 453 " running a command from the shell",453 "Set, enable or disable zephyr away message", 454 454 "zaway [ on | off | toggle ]\n" 455 455 "zaway <message>", 456 "Turn on or off the default zaway message. If a message is\n" 457 "specified turn on zaway with that message\n"), 458 OWLCMD_ALIAS("away", "zaway"), 456 "Turn on or off a zaway message. If 'message' is\n" 457 "specified turn on zaway with that message, otherwise\n" 458 "use the default.\n"), 459 460 OWLCMD_ARGS("aaway", owl_command_aaway, OWL_CTX_INTERACTIVE, 461 "Set, enable or disable AIM away message", 462 "aaway [ on | off | toggle ]\n" 463 "aaway <message>", 464 "Turn on or off the AIM away message. If 'message' is\n" 465 "specified turn on aaway with that message, otherwise\n" 466 "use the default.\n"), 467 468 OWLCMD_ARGS("away", owl_command_away, OWL_CTX_INTERACTIVE, 469 "Set, enable or disable both AIM and zephyr away messages", 470 "away [ on | off | toggle ]\n" 471 "away <message>", 472 "Turn on or off the AIM and zephyr away message. If\n" 473 "'message' is specified turn them on with that message,\n" 474 "otherwise use the default.\n" 475 "\n" 476 "This command really just runs the 'aaway' and 'zaway'\n" 477 "commands together\n" 478 "\n" 479 "SEE ALSO: aaway, zaway"), 459 480 460 481 OWLCMD_ARGS("load-subs", owl_command_loadsubs, OWL_CTX_ANY, … … 1343 1364 } 1344 1365 1366 1367 char *owl_command_aaway(int argc, char **argv, char *buff) 1368 { 1369 if ((argc==1) || 1370 ((argc==2) && !strcmp(argv[1], "on"))) { 1371 owl_global_set_aaway_msg(&g, owl_global_get_aaway_msg_default(&g)); 1372 owl_function_aaway_on(); 1373 return NULL; 1374 } 1375 1376 if (argc==2 && !strcmp(argv[1], "off")) { 1377 owl_function_aaway_off(); 1378 return NULL; 1379 } 1380 1381 if (argc==2 && !strcmp(argv[1], "toggle")) { 1382 owl_function_aaway_toggle(); 1383 return NULL; 1384 } 1385 1386 buff = skiptokens(buff, 1); 1387 owl_global_set_aaway_msg(&g, buff); 1388 owl_function_aaway_on(); 1389 return NULL; 1390 } 1391 1392 1393 char *owl_command_away(int argc, char **argv, char *buff) 1394 { 1395 owl_command_zaway(argc, argv, buff); 1396 owl_command_aaway(argc, argv, buff); 1397 return NULL; 1398 } 1345 1399 1346 1400 char *owl_command_set(int argc, char **argv, char *buff)
Note: See TracChangeset
for help on using the changeset viewer.