summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorementalo <ementalodev@gmx.co.uk>2012-08-04 09:25:54 +0100
committerementalo <ementalodev@gmx.co.uk>2012-08-04 09:25:54 +0100
commitaf73c11638fda0c65fa68506d301b2a68b780bf6 (patch)
tree52e4cf55b5480742ff6830c76e82b9b0c92d8bdc
parent1a07815f4b535cc80c32579b010294eb4b49ecfc (diff)
downloadEssentials-af73c11638fda0c65fa68506d301b2a68b780bf6.tar
Essentials-af73c11638fda0c65fa68506d301b2a68b780bf6.tar.gz
Essentials-af73c11638fda0c65fa68506d301b2a68b780bf6.tar.lz
Essentials-af73c11638fda0c65fa68506d301b2a68b780bf6.tar.xz
Essentials-af73c11638fda0c65fa68506d301b2a68b780bf6.zip
CB #2289 Bukkit #1512
Change PlayerChatEvent to AsyncPlayerChatEvent
-rw-r--r--Essentials/src/com/earth2me/essentials/Essentials.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java2
-rw-r--r--EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java4
-rw-r--r--EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayer.java20
-rw-r--r--EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerHighest.java6
-rw-r--r--EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerLowest.java6
-rw-r--r--EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerNormal.java6
-rw-r--r--EssentialsChat/src/com/earth2me/essentials/chat/IEssentialsChatListener.java6
-rw-r--r--EssentialsUpdate/src/com/earth2me/essentials/update/EssentialsHelp.java4
-rw-r--r--EssentialsUpdate/src/com/earth2me/essentials/update/UpdateProcess.java4
-rw-r--r--EssentialsXMPP/src/com/earth2me/essentials/xmpp/EssentialsXMPPPlayerListener.java4
-rw-r--r--lib/bukkit.jarbin4727963 -> 4731015 bytes
-rw-r--r--lib/craftbukkit.jarbin11672027 -> 11679707 bytes
13 files changed, 32 insertions, 32 deletions
diff --git a/Essentials/src/com/earth2me/essentials/Essentials.java b/Essentials/src/com/earth2me/essentials/Essentials.java
index 3b2549307..1ac09bef8 100644
--- a/Essentials/src/com/earth2me/essentials/Essentials.java
+++ b/Essentials/src/com/earth2me/essentials/Essentials.java
@@ -67,7 +67,7 @@ import org.yaml.snakeyaml.error.YAMLException;
public class Essentials extends JavaPlugin implements IEssentials
{
- public static final int BUKKIT_VERSION = 2267;
+ public static final int BUKKIT_VERSION = 2289;
private static final Logger LOGGER = Logger.getLogger("Minecraft");
private transient ISettings settings;
private final transient TNTExplodeListener tntListener = new TNTExplodeListener(this);
diff --git a/Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java b/Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java
index 8dbde99dc..2fe03ebce 100644
--- a/Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java
+++ b/Essentials/src/com/earth2me/essentials/EssentialsPlayerListener.java
@@ -50,7 +50,7 @@ public class EssentialsPlayerListener implements Listener
}
@EventHandler(priority = EventPriority.LOWEST)
- public void onPlayerChat(final PlayerChatEvent event)
+ public void onPlayerChat(final AsyncPlayerChatEvent event)
{
final User user = ess.getUser(event.getPlayer());
if (user.isMuted())
diff --git a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java
index 3148fe0ff..f16579a4d 100644
--- a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java
+++ b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChat.java
@@ -8,7 +8,7 @@ import java.util.Map;
import java.util.concurrent.ConcurrentSkipListMap;
import java.util.logging.Level;
import java.util.logging.Logger;
-import org.bukkit.event.player.PlayerChatEvent;
+import org.bukkit.event.player.AsyncPlayerChatEvent;
import org.bukkit.plugin.PluginManager;
import org.bukkit.plugin.java.JavaPlugin;
@@ -34,7 +34,7 @@ public class EssentialsChat extends JavaPlugin
}
chatListener = new ConcurrentSkipListMap<String, IEssentialsChatListener>();
- final Map<PlayerChatEvent, ChatStore> chatStore = Collections.synchronizedMap(new HashMap<PlayerChatEvent, ChatStore>());
+ final Map<AsyncPlayerChatEvent, ChatStore> chatStore = Collections.synchronizedMap(new HashMap<AsyncPlayerChatEvent, ChatStore>());
final EssentialsChatPlayerListenerLowest playerListenerLowest = new EssentialsChatPlayerListenerLowest(getServer(), ess, chatListener, chatStore);
diff --git a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayer.java b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayer.java
index 052479aed..8ca16fbbb 100644
--- a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayer.java
+++ b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayer.java
@@ -12,7 +12,7 @@ import org.bukkit.Server;
import org.bukkit.World;
import org.bukkit.entity.Player;
import org.bukkit.event.Listener;
-import org.bukkit.event.player.PlayerChatEvent;
+import org.bukkit.event.player.AsyncPlayerChatEvent;
//TODO: Translate the local/spy tags
public abstract class EssentialsChatPlayer implements Listener
@@ -21,12 +21,12 @@ public abstract class EssentialsChatPlayer implements Listener
protected final static Logger logger = Logger.getLogger("Minecraft");
protected final transient Map<String, IEssentialsChatListener> listeners;
protected final transient Server server;
- protected final transient Map<PlayerChatEvent, ChatStore> chatStorage;
+ protected final transient Map<AsyncPlayerChatEvent, ChatStore> chatStorage;
public EssentialsChatPlayer(final Server server,
final IEssentials ess,
final Map<String, IEssentialsChatListener> listeners,
- final Map<PlayerChatEvent, ChatStore> chatStorage)
+ final Map<AsyncPlayerChatEvent, ChatStore> chatStorage)
{
this.ess = ess;
this.listeners = listeners;
@@ -34,11 +34,11 @@ public abstract class EssentialsChatPlayer implements Listener
this.chatStorage = chatStorage;
}
- public void onPlayerChat(final PlayerChatEvent event)
+ public void onPlayerChat(final AsyncPlayerChatEvent event)
{
}
- public boolean isAborted(final PlayerChatEvent event)
+ public boolean isAborted(final AsyncPlayerChatEvent event)
{
if (event.isCancelled())
{
@@ -69,17 +69,17 @@ public abstract class EssentialsChatPlayer implements Listener
}
}
- public ChatStore getChatStore(final PlayerChatEvent event)
+ public ChatStore getChatStore(final AsyncPlayerChatEvent event)
{
return chatStorage.get(event);
}
- public void setChatStore(final PlayerChatEvent event, final ChatStore chatStore)
+ public void setChatStore(final AsyncPlayerChatEvent event, final ChatStore chatStore)
{
chatStorage.put(event, chatStore);
}
- public ChatStore delChatStore(final PlayerChatEvent event)
+ public ChatStore delChatStore(final AsyncPlayerChatEvent event)
{
return chatStorage.remove(event);
}
@@ -89,7 +89,7 @@ public abstract class EssentialsChatPlayer implements Listener
charge.charge(user);
}
- protected boolean charge(final PlayerChatEvent event, final ChatStore chatStore)
+ protected boolean charge(final AsyncPlayerChatEvent event, final ChatStore chatStore)
{
try
{
@@ -104,7 +104,7 @@ public abstract class EssentialsChatPlayer implements Listener
return true;
}
- protected void sendLocalChat(final PlayerChatEvent event, final ChatStore chatStore)
+ protected void sendLocalChat(final AsyncPlayerChatEvent event, final ChatStore chatStore)
{
event.setCancelled(true);
final User sender = chatStore.getUser();
diff --git a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerHighest.java b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerHighest.java
index e8f785228..db728bd09 100644
--- a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerHighest.java
+++ b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerHighest.java
@@ -5,7 +5,7 @@ import java.util.Map;
import org.bukkit.Server;
import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority;
-import org.bukkit.event.player.PlayerChatEvent;
+import org.bukkit.event.player.AsyncPlayerChatEvent;
public class EssentialsChatPlayerListenerHighest extends EssentialsChatPlayer
@@ -13,14 +13,14 @@ public class EssentialsChatPlayerListenerHighest extends EssentialsChatPlayer
public EssentialsChatPlayerListenerHighest(final Server server,
final IEssentials ess,
final Map<String, IEssentialsChatListener> listeners,
- final Map<PlayerChatEvent, ChatStore> chatStorage)
+ final Map<AsyncPlayerChatEvent, ChatStore> chatStorage)
{
super(server, ess, listeners, chatStorage);
}
@EventHandler(priority = EventPriority.HIGHEST)
@Override
- public void onPlayerChat(final PlayerChatEvent event)
+ public void onPlayerChat(final AsyncPlayerChatEvent event)
{
final ChatStore chatStore = delChatStore(event);
if (isAborted(event))
diff --git a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerLowest.java b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerLowest.java
index 79ff4994a..410dc3b3b 100644
--- a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerLowest.java
+++ b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerLowest.java
@@ -9,7 +9,7 @@ import java.util.Map;
import org.bukkit.Server;
import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority;
-import org.bukkit.event.player.PlayerChatEvent;
+import org.bukkit.event.player.AsyncPlayerChatEvent;
public class EssentialsChatPlayerListenerLowest extends EssentialsChatPlayer
@@ -17,14 +17,14 @@ public class EssentialsChatPlayerListenerLowest extends EssentialsChatPlayer
public EssentialsChatPlayerListenerLowest(final Server server,
final IEssentials ess,
final Map<String, IEssentialsChatListener> listeners,
- final Map<PlayerChatEvent, ChatStore> chatStorage)
+ final Map<AsyncPlayerChatEvent, ChatStore> chatStorage)
{
super(server, ess, listeners, chatStorage);
}
@EventHandler(priority = EventPriority.LOWEST)
@Override
- public void onPlayerChat(final PlayerChatEvent event)
+ public void onPlayerChat(final AsyncPlayerChatEvent event)
{
if (isAborted(event))
{
diff --git a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerNormal.java b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerNormal.java
index fdaccdc8d..910518302 100644
--- a/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerNormal.java
+++ b/EssentialsChat/src/com/earth2me/essentials/chat/EssentialsChatPlayerListenerNormal.java
@@ -8,7 +8,7 @@ import java.util.Map;
import org.bukkit.Server;
import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority;
-import org.bukkit.event.player.PlayerChatEvent;
+import org.bukkit.event.player.AsyncPlayerChatEvent;
public class EssentialsChatPlayerListenerNormal extends EssentialsChatPlayer
@@ -16,14 +16,14 @@ public class EssentialsChatPlayerListenerNormal extends EssentialsChatPlayer
public EssentialsChatPlayerListenerNormal(final Server server,
final IEssentials ess,
final Map<String, IEssentialsChatListener> listeners,
- final Map<PlayerChatEvent, ChatStore> chatStorage)
+ final Map<AsyncPlayerChatEvent, ChatStore> chatStorage)
{
super(server, ess, listeners, chatStorage);
}
@EventHandler(priority = EventPriority.NORMAL)
@Override
- public void onPlayerChat(final PlayerChatEvent event)
+ public void onPlayerChat(final AsyncPlayerChatEvent event)
{
if (isAborted(event))
{
diff --git a/EssentialsChat/src/com/earth2me/essentials/chat/IEssentialsChatListener.java b/EssentialsChat/src/com/earth2me/essentials/chat/IEssentialsChatListener.java
index 5c9c5c219..abf5893ea 100644
--- a/EssentialsChat/src/com/earth2me/essentials/chat/IEssentialsChatListener.java
+++ b/EssentialsChat/src/com/earth2me/essentials/chat/IEssentialsChatListener.java
@@ -1,12 +1,12 @@
package com.earth2me.essentials.chat;
import org.bukkit.entity.Player;
-import org.bukkit.event.player.PlayerChatEvent;
+import org.bukkit.event.player.AsyncPlayerChatEvent;
public interface IEssentialsChatListener
{
- boolean shouldHandleThisChat(PlayerChatEvent event);
+ boolean shouldHandleThisChat(AsyncPlayerChatEvent event);
- String modifyMessage(PlayerChatEvent event, Player target, String message);
+ String modifyMessage(AsyncPlayerChatEvent event, Player target, String message);
}
diff --git a/EssentialsUpdate/src/com/earth2me/essentials/update/EssentialsHelp.java b/EssentialsUpdate/src/com/earth2me/essentials/update/EssentialsHelp.java
index 7dd46451a..63cdc094a 100644
--- a/EssentialsUpdate/src/com/earth2me/essentials/update/EssentialsHelp.java
+++ b/EssentialsUpdate/src/com/earth2me/essentials/update/EssentialsHelp.java
@@ -9,7 +9,7 @@ import org.bukkit.command.CommandSender;
import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
-import org.bukkit.event.player.PlayerChatEvent;
+import org.bukkit.event.player.AsyncPlayerChatEvent;
import org.bukkit.event.player.PlayerQuitEvent;
import org.bukkit.plugin.Plugin;
import org.bukkit.plugin.PluginManager;
@@ -154,7 +154,7 @@ public class EssentialsHelp implements Listener
}
@EventHandler
- public void onPlayerChat(final PlayerChatEvent event)
+ public void onPlayerChat(final AsyncPlayerChatEvent event)
{
if (event.getPlayer() == chatUser)
{
diff --git a/EssentialsUpdate/src/com/earth2me/essentials/update/UpdateProcess.java b/EssentialsUpdate/src/com/earth2me/essentials/update/UpdateProcess.java
index 9fa587f8f..29c227794 100644
--- a/EssentialsUpdate/src/com/earth2me/essentials/update/UpdateProcess.java
+++ b/EssentialsUpdate/src/com/earth2me/essentials/update/UpdateProcess.java
@@ -10,7 +10,7 @@ import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority;
import org.bukkit.event.Listener;
-import org.bukkit.event.player.PlayerChatEvent;
+import org.bukkit.event.player.AsyncPlayerChatEvent;
import org.bukkit.event.player.PlayerJoinEvent;
import org.bukkit.plugin.Plugin;
@@ -100,7 +100,7 @@ public class UpdateProcess implements Listener
}
@EventHandler(priority = EventPriority.LOWEST)
- public void onPlayerChat(final PlayerChatEvent event)
+ public void onPlayerChat(final AsyncPlayerChatEvent event)
{
if (event.getPlayer() == currentPlayer)
{
diff --git a/EssentialsXMPP/src/com/earth2me/essentials/xmpp/EssentialsXMPPPlayerListener.java b/EssentialsXMPP/src/com/earth2me/essentials/xmpp/EssentialsXMPPPlayerListener.java
index 1fa5a243c..468a7ec4e 100644
--- a/EssentialsXMPP/src/com/earth2me/essentials/xmpp/EssentialsXMPPPlayerListener.java
+++ b/EssentialsXMPP/src/com/earth2me/essentials/xmpp/EssentialsXMPPPlayerListener.java
@@ -5,7 +5,7 @@ import com.earth2me.essentials.User;
import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority;
import org.bukkit.event.Listener;
-import org.bukkit.event.player.PlayerChatEvent;
+import org.bukkit.event.player.AsyncPlayerChatEvent;
import org.bukkit.event.player.PlayerJoinEvent;
import org.bukkit.event.player.PlayerQuitEvent;
@@ -28,7 +28,7 @@ class EssentialsXMPPPlayerListener implements Listener
}
@EventHandler(priority= EventPriority.MONITOR)
- public void onPlayerChat(final PlayerChatEvent event)
+ public void onPlayerChat(final AsyncPlayerChatEvent event)
{
final User user = ess.getUser(event.getPlayer());
sendMessageToSpyUsers(String.format(event.getFormat(), user.getDisplayName(), event.getMessage()));
diff --git a/lib/bukkit.jar b/lib/bukkit.jar
index c3f110e8f..4c865d0ed 100644
--- a/lib/bukkit.jar
+++ b/lib/bukkit.jar
Binary files differ
diff --git a/lib/craftbukkit.jar b/lib/craftbukkit.jar
index 672f55080..bc20058c5 100644
--- a/lib/craftbukkit.jar
+++ b/lib/craftbukkit.jar
Binary files differ