23 package com.realtime.crossfire.jxclient.commands;
30 import org.jetbrains.annotations.NotNull;
31 import org.jetbrains.annotations.Nullable;
63 public void execute(@NotNull
final String args) {
66 }
else if (args.startsWith(
"-d ")) {
79 final String text = shortcut ==
null ?
"(empty)" : shortcut.
getCommand();
90 if (shortcutSlot !=
null) {
100 final String[] tmp = args.split(
" ", 2);
102 if (shortcutSlot !=
null) {
111 final StringBuilder sb =
new StringBuilder();
112 sb.append(
"Updates the shortcut bar\n");
114 sb.append(
"Usage: shortcut\n");
115 sb.append(
"Usage: shortcut <key> <command>\n");
116 sb.append(
"Usage: shortcut -d <key>\n");
118 sb.append(
"Without argument shows the contents of the shortcut bar. ");
119 sb.append(
"Otherwise replaces the slot for <key> with <command>. ");
120 sb.append(
"<key> may be F1, F2, ..., F12. Other keys are not supported.\n");
121 sb.append(
"-d removes the command from the given slot.\n");
122 return sb.toString();
134 }
catch (
final IllegalArgumentException ignored) {