X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2FWebInterface.java;h=dfc0b25ad8d781c922f5eb3422b29c7acd3f870b;hp=a30508edd31e7c3b7e02c660365d636704e21b2b;hb=06c97e457ce62ff258d85e6cfb9b4d94f9e9147f;hpb=f29f2dc508c4553c12f1329df213910432612b2a diff --git a/src/main/java/net/pterodactylus/sone/web/WebInterface.java b/src/main/java/net/pterodactylus/sone/web/WebInterface.java index a30508e..dfc0b25 100644 --- a/src/main/java/net/pterodactylus/sone/web/WebInterface.java +++ b/src/main/java/net/pterodactylus/sone/web/WebInterface.java @@ -37,6 +37,7 @@ import java.util.logging.Logger; import net.pterodactylus.sone.core.Core; import net.pterodactylus.sone.core.CoreListener; +import net.pterodactylus.sone.core.event.ImageInsertAbortedEvent; import net.pterodactylus.sone.core.event.ImageInsertStartedEvent; import net.pterodactylus.sone.core.event.MarkPostKnownEvent; import net.pterodactylus.sone.core.event.MarkPostReplyKnownEvent; @@ -1049,18 +1050,21 @@ public class WebInterface implements CoreListener { notificationManager.addNotification(insertingImagesNotification); } - // - // CORELISTENER METHODS - // - /** - * {@inheritDoc} + * Notifies the web interface that an {@link Image} insert was aborted. + * + * @param imageInsertAbortedEvent + * The event */ - @Override - public void imageInsertAborted(Image image) { - insertingImagesNotification.remove(image); + @Subscribe + public void imageInsertAborted(ImageInsertAbortedEvent imageInsertAbortedEvent) { + insertingImagesNotification.remove(imageInsertAbortedEvent.image()); } + // + // CORELISTENER METHODS + // + /** * {@inheritDoc} */