command manager: post events to immediate eventbus
The ChatboxInput event has state which is returned back which the manager uses to conditionally block input
This commit is contained in:
@@ -29,6 +29,7 @@ import com.google.common.eventbus.EventBus;
|
|||||||
import com.google.common.eventbus.Subscribe;
|
import com.google.common.eventbus.Subscribe;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import javax.inject.Inject;
|
import javax.inject.Inject;
|
||||||
|
import javax.inject.Named;
|
||||||
import javax.inject.Provider;
|
import javax.inject.Provider;
|
||||||
import javax.inject.Singleton;
|
import javax.inject.Singleton;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
@@ -53,7 +54,7 @@ public class CommandManager
|
|||||||
private boolean sending;
|
private boolean sending;
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
public CommandManager(Provider<Client> clientProvider, EventBus eventBus, Provider<ClientThread> clientThreadProvider)
|
public CommandManager(Provider<Client> clientProvider, @Named("Immediate EventBus") EventBus eventBus, Provider<ClientThread> clientThreadProvider)
|
||||||
{
|
{
|
||||||
this.clientProvider = clientProvider;
|
this.clientProvider = clientProvider;
|
||||||
this.eventBus = eventBus;
|
this.eventBus = eventBus;
|
||||||
|
|||||||
Reference in New Issue
Block a user