History bug

regarding bug #2073
Could you remove `compare()` method here since it's testing only the filename and not the selection and above, in deleteLocation(), compare the filenames instead of comparing the `NavigationLocation`.