19972e09b8
5a0150f586ed3eb15fe6f1f596d1a5a7d806f0f9 Fix ITEM_BREAK e6a3911057bd94d8bd7021cbb4923fb84fb106d1 Upstream merge d1cdcf8d4c3639f956474f02ed662517cffbe23e Remove old patch 068df64aeee368377e1673667bffc7a6dcf90554 Rebuild all patches
85 lines
3.1 KiB
Diff
85 lines
3.1 KiB
Diff
From b21c6424ec427aad72d53accf9236ffe7eb812f5 Mon Sep 17 00:00:00 2001
|
|
From: md_5 <git@md-5.net>
|
|
Date: Tue, 24 Dec 2013 10:14:25 +1100
|
|
Subject: [PATCH] Fix Tab Completion for Some Commands
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/command/defaults/PluginsCommand.java b/src/main/java/org/bukkit/command/defaults/PluginsCommand.java
|
|
index b888da1..e21d167 100644
|
|
--- a/src/main/java/org/bukkit/command/defaults/PluginsCommand.java
|
|
+++ b/src/main/java/org/bukkit/command/defaults/PluginsCommand.java
|
|
@@ -40,4 +40,12 @@ public class PluginsCommand extends BukkitCommand {
|
|
|
|
return "(" + plugins.length + "): " + pluginList.toString();
|
|
}
|
|
+
|
|
+ // Spigot Start
|
|
+ @Override
|
|
+ public java.util.List<String> tabComplete(CommandSender sender, String alias, String[] args) throws IllegalArgumentException
|
|
+ {
|
|
+ return java.util.Collections.emptyList();
|
|
+ }
|
|
+ // Spigot End
|
|
}
|
|
diff --git a/src/main/java/org/bukkit/command/defaults/ReloadCommand.java b/src/main/java/org/bukkit/command/defaults/ReloadCommand.java
|
|
index fb3c90f..a08ae80 100644
|
|
--- a/src/main/java/org/bukkit/command/defaults/ReloadCommand.java
|
|
+++ b/src/main/java/org/bukkit/command/defaults/ReloadCommand.java
|
|
@@ -25,4 +25,12 @@ public class ReloadCommand extends BukkitCommand {
|
|
|
|
return true;
|
|
}
|
|
+
|
|
+ // Spigot Start
|
|
+ @Override
|
|
+ public java.util.List<String> tabComplete(CommandSender sender, String alias, String[] args) throws IllegalArgumentException
|
|
+ {
|
|
+ return java.util.Collections.emptyList();
|
|
+ }
|
|
+ // Spigot End
|
|
}
|
|
diff --git a/src/main/java/org/bukkit/command/defaults/TellCommand.java b/src/main/java/org/bukkit/command/defaults/TellCommand.java
|
|
index 287f49f..fc49207 100644
|
|
--- a/src/main/java/org/bukkit/command/defaults/TellCommand.java
|
|
+++ b/src/main/java/org/bukkit/command/defaults/TellCommand.java
|
|
@@ -45,4 +45,16 @@ public class TellCommand extends VanillaCommand {
|
|
|
|
return true;
|
|
}
|
|
+
|
|
+ // Spigot Start
|
|
+ @Override
|
|
+ public java.util.List<String> tabComplete(CommandSender sender, String alias, String[] args) throws IllegalArgumentException
|
|
+ {
|
|
+ if ( args.length == 0 )
|
|
+ {
|
|
+ return super.tabComplete( sender, alias, args );
|
|
+ }
|
|
+ return java.util.Collections.emptyList();
|
|
+ }
|
|
+ // Spigot End
|
|
}
|
|
diff --git a/src/main/java/org/bukkit/command/defaults/TestForCommand.java b/src/main/java/org/bukkit/command/defaults/TestForCommand.java
|
|
index c9ac1ce..a687fef 100644
|
|
--- a/src/main/java/org/bukkit/command/defaults/TestForCommand.java
|
|
+++ b/src/main/java/org/bukkit/command/defaults/TestForCommand.java
|
|
@@ -23,4 +23,16 @@ public class TestForCommand extends VanillaCommand {
|
|
sender.sendMessage(ChatColor.RED + "/testfor is only usable by commandblocks with analog output.");
|
|
return true;
|
|
}
|
|
+
|
|
+ // Spigot Start
|
|
+ @Override
|
|
+ public java.util.List<String> tabComplete(CommandSender sender, String alias, String[] args) throws IllegalArgumentException
|
|
+ {
|
|
+ if ( args.length == 0 )
|
|
+ {
|
|
+ return super.tabComplete( sender, alias, args );
|
|
+ }
|
|
+ return java.util.Collections.emptyList();
|
|
+ }
|
|
+ // Spigot End
|
|
}
|
|
--
|
|
2.1.0
|
|
|