diff --git a/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/AbstractCommandExecutor.java b/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/AbstractCommandExecutor.java index 122e74d..26ff8a2 100644 --- a/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/AbstractCommandExecutor.java +++ b/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/AbstractCommandExecutor.java @@ -49,7 +49,7 @@ public abstract class AbstractCommandExecutor implements CommandExecutor, TabCom * @param allProposal * @return */ - public List getTabProposalFromToken(String token, List allProposal) { + public static List getTabProposalFromToken(String token, List allProposal) { List ret = new ArrayList(); for (String s : allProposal) diff --git a/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/PandacraftUtilsCommandsManager.java b/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/PandacraftUtilsCommandsManager.java index 7e28c08..ea82180 100644 --- a/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/PandacraftUtilsCommandsManager.java +++ b/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/PandacraftUtilsCommandsManager.java @@ -2,6 +2,8 @@ package net.mc_pandacraft.java.plugin.pandacraftutils.commands; import java.util.HashMap; +import net.mc_pandacraft.java.plugin.pandacraftutils.PandacraftUtils; + /** * Initialise et stoque toutes les instances des classes exécutant les commandes Minecraft, géré par le plugin */ @@ -61,6 +63,9 @@ public class PandacraftUtilsCommandsManager { add(new CommandMail()); add(new CommandReply()); + // complétion des commandes des autres plugins + PandacraftUtils.getInstance().getServer().getPluginCommand("region").setTabCompleter(new TabCompleterWorldGuardRegion()); + } diff --git a/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/TabCompleterWorldGuardRegion.java b/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/TabCompleterWorldGuardRegion.java new file mode 100644 index 0000000..08a9e81 --- /dev/null +++ b/src/net/mc_pandacraft/java/plugin/pandacraftutils/commands/TabCompleterWorldGuardRegion.java @@ -0,0 +1,19 @@ +package net.mc_pandacraft.java.plugin.pandacraftutils.commands; + +import java.util.List; + +import org.bukkit.command.Command; +import org.bukkit.command.CommandSender; +import org.bukkit.command.TabCompleter; + +public class TabCompleterWorldGuardRegion implements TabCompleter { + + @Override + public List onTabComplete(CommandSender paramCommandSender, + Command paramCommand, String paramString, + String[] paramArrayOfString) { + // TODO Auto-generated method stub + return null; + } + +}