rename event enums/classes to specify that they are Timeline related

This commit is contained in:
millmanorama 2018-11-13 12:22:00 +01:00
parent d2abd39e38
commit 11b9c72828
3 changed files with 21 additions and 18 deletions

View File

@ -109,7 +109,7 @@ import org.sleuthkit.autopsy.progress.LoggingProgressIndicator;
import org.sleuthkit.autopsy.progress.ModalDialogProgressIndicator;
import org.sleuthkit.autopsy.progress.ProgressIndicator;
import org.sleuthkit.autopsy.timeline.OpenTimelineAction;
import org.sleuthkit.autopsy.timeline.events.EventAddedEvent;
import org.sleuthkit.autopsy.timeline.events.TimelineEventAddedEvent;
import org.sleuthkit.datamodel.Blackboard;
import org.sleuthkit.datamodel.BlackboardArtifact;
import org.sleuthkit.datamodel.BlackboardArtifactTag;
@ -382,23 +382,24 @@ public class Case {
*/
TAG_DEFINITION_CHANGED,
/**
* An event, such mac time or web activity was added to the current
* case. The old value is null and the new value is the SingleEvent that
* was added.
*/ EVENT_ADDED,
/* An item in the central repository has had its comment modified. The
* old value is null, the new value is string for current comment.
* An timeline event, such mac time or web activity was added to the current
* case. The old value is null and the new value is the TimelineEvent
* that was added.
*/
TIMELINE_EVENT_ADDED,
/* An item in the central repository has had its comment
* modified. The old value is null, the new value is string for current
* comment.
*/
CR_COMMENT_CHANGED;
};
private final class TSKCaseRepublisher {
@Subscribe
public void rebroadcastTimelineEventCreated(TimelineManager.EventAddedEvent event) {
eventPublisher.publish(new EventAddedEvent(event));
eventPublisher.publish(new TimelineEventAddedEvent(event));
}
@Subscribe
@ -1576,11 +1577,13 @@ public class Case {
}
/**
* Notifies case event subscribers that a central repository comment has been changed.
*
* Notifies case event subscribers that a central repository comment has
* been changed.
*
* This should not be called from the event dispatch thread (EDT)
*
* @param contentId the objectId for the Content which has had its central repo comment changed
*
* @param contentId the objectId for the Content which has had its central
* repo comment changed
* @param newComment the new value of the comment
*/
public void notifyCentralRepoCommentChanged(long contentId, String newComment) {

View File

@ -775,7 +775,7 @@ public class TimeLineController {
//close timeline on case changes.
SwingUtilities.invokeLater(TimeLineController.this::shutDownTimeLine);
break;
case EVENT_ADDED:
case TIMELINE_EVENT_ADDED:
executor.submit(filteredEvents::invalidateAllCaches);
break;
}

View File

@ -24,9 +24,9 @@ import org.sleuthkit.autopsy.events.AutopsyEvent;
/**
*
*/
public class EventAddedEvent extends AutopsyEvent {
public class TimelineEventAddedEvent extends AutopsyEvent {
public EventAddedEvent(org.sleuthkit.datamodel.TimelineManager.EventAddedEvent event) {
super(Case.Events.EVENT_ADDED.name(), null, event.getEvent());
public TimelineEventAddedEvent(org.sleuthkit.datamodel.TimelineManager.EventAddedEvent event) {
super(Case.Events.TIMELINE_EVENT_ADDED.name(), null, event.getAddedEvent());
}
}