Add notifications for locking and unlocking Sones.
[Sone.git] / src / main / java / net / pterodactylus / sone / web / WebInterface.java
index 95978ce..a5376af 100644 (file)
@@ -585,6 +585,8 @@ public class WebInterface implements CoreListener {
                newPostNotification.add(post);
                if (!hasFirstStartNotification()) {
                        notificationManager.addNotification(newPostNotification);
+               } else {
+                       getCore().markPostKnown(post);
                }
        }
 
@@ -599,6 +601,8 @@ public class WebInterface implements CoreListener {
                newReplyNotification.add(reply);
                if (!hasFirstStartNotification()) {
                        notificationManager.addNotification(newReplyNotification);
+               } else {
+                       getCore().markReplyKnown(reply);
                }
        }
 
@@ -643,6 +647,22 @@ public class WebInterface implements CoreListener {
        }
 
        /**
+        * {@inheritDoc}
+        */
+       @Override
+       public void soneLocked(Sone sone) {
+               /* TODO */
+       }
+
+       /**
+        * {@inheritDoc}
+        */
+       @Override
+       public void soneUnlocked(Sone sone) {
+               /* TODO */
+       }
+
+       /**
         * Template provider implementation that uses
         * {@link WebInterface#createReader(String)} to load templates for
         * inclusion.