Change setModifed so it can't change modified back to false (#1805)

This commit is contained in:
Lucwousin
2019-10-17 23:46:24 +02:00
committed by Ganom
parent bca49d2f7d
commit 220b90c0a6
13 changed files with 29 additions and 18 deletions

View File

@@ -24,7 +24,7 @@
*/
package net.runelite.api.events;
import lombok.Setter;
import lombok.Getter;
import net.runelite.api.MenuEntry;
/**
@@ -44,11 +44,11 @@ public class MenuEntryAdded extends MenuEntry implements Event
* Checks if count is the same, but doesn't check if there's
* been multiple changes
*/
@Setter
@Getter
private boolean modified;
public boolean hasBeenModified()
public void setModified()
{
return modified;
this.modified = true;
}
}

View File

@@ -24,6 +24,8 @@
*/
package net.runelite.api.events;
import lombok.AccessLevel;
import lombok.Setter;
import net.runelite.api.MenuEntry;
import lombok.Data;
@@ -38,6 +40,7 @@ public class MenuOpened implements Event
* in menuEntries is changed, so the changes can be
* propagated through to the client.
*/
@Setter(AccessLevel.NONE)
private boolean modified;
/**
@@ -62,4 +65,9 @@ public class MenuOpened implements Event
return null;
}
public void setModified()
{
this.modified = true;
}
}