ui: remove unnecessary reverse

Signed-off-by: kernelkind <kernelkind@gmail.com>
This commit is contained in:
kernelkind
2025-08-25 10:11:32 -04:00
parent 78504a6673
commit 0b584a773f
3 changed files with 0 additions and 17 deletions

View File

@@ -114,7 +114,6 @@ impl<'a, 'd> ProfileView<'a, 'd> {
if let Some(note_action) = TimelineTabView::new( if let Some(note_action) = TimelineTabView::new(
profile_timeline.current_view(), profile_timeline.current_view(),
reversed,
self.note_options, self.note_options,
&txn, &txn,
self.note_context, self.note_context,

View File

@@ -156,10 +156,8 @@ impl<'a, 'd> SearchView<'a, 'd> {
egui::ScrollArea::vertical() egui::ScrollArea::vertical()
.id_salt(SearchView::scroll_id()) .id_salt(SearchView::scroll_id())
.show(ui, |ui| { .show(ui, |ui| {
let reversed = false;
TimelineTabView::new( TimelineTabView::new(
&self.query.notes, &self.query.notes,
reversed,
self.note_options, self.note_options,
self.txn, self.txn,
self.note_context, self.note_context,

View File

@@ -26,7 +26,6 @@ pub struct TimelineView<'a, 'd> {
timeline_id: &'a TimelineKind, timeline_id: &'a TimelineKind,
timeline_cache: &'a mut TimelineCache, timeline_cache: &'a mut TimelineCache,
note_options: NoteOptions, note_options: NoteOptions,
reverse: bool,
note_context: &'a mut NoteContext<'d>, note_context: &'a mut NoteContext<'d>,
jobs: &'a mut JobsCache, jobs: &'a mut JobsCache,
col: usize, col: usize,
@@ -43,13 +42,11 @@ impl<'a, 'd> TimelineView<'a, 'd> {
jobs: &'a mut JobsCache, jobs: &'a mut JobsCache,
col: usize, col: usize,
) -> Self { ) -> Self {
let reverse = false;
let scroll_to_top = false; let scroll_to_top = false;
TimelineView { TimelineView {
timeline_id, timeline_id,
timeline_cache, timeline_cache,
note_options, note_options,
reverse,
note_context, note_context,
jobs, jobs,
col, col,
@@ -62,7 +59,6 @@ impl<'a, 'd> TimelineView<'a, 'd> {
ui, ui,
self.timeline_id, self.timeline_id,
self.timeline_cache, self.timeline_cache,
self.reverse,
self.note_options, self.note_options,
self.note_context, self.note_context,
self.jobs, self.jobs,
@@ -76,11 +72,6 @@ impl<'a, 'd> TimelineView<'a, 'd> {
self self
} }
pub fn reversed(mut self) -> Self {
self.reverse = true;
self
}
pub fn scroll_id( pub fn scroll_id(
timeline_cache: &TimelineCache, timeline_cache: &TimelineCache,
timeline_id: &TimelineKind, timeline_id: &TimelineKind,
@@ -96,7 +87,6 @@ fn timeline_ui(
ui: &mut egui::Ui, ui: &mut egui::Ui,
timeline_id: &TimelineKind, timeline_id: &TimelineKind,
timeline_cache: &mut TimelineCache, timeline_cache: &mut TimelineCache,
reversed: bool,
note_options: NoteOptions, note_options: NoteOptions,
note_context: &mut NoteContext, note_context: &mut NoteContext,
jobs: &mut JobsCache, jobs: &mut JobsCache,
@@ -192,7 +182,6 @@ fn timeline_ui(
TimelineTabView::new( TimelineTabView::new(
timeline.current_view(), timeline.current_view(),
reversed,
note_options, note_options,
&txn, &txn,
note_context, note_context,
@@ -386,7 +375,6 @@ fn shrink_range_to_width(range: egui::Rangef, width: f32) -> egui::Rangef {
pub struct TimelineTabView<'a, 'd> { pub struct TimelineTabView<'a, 'd> {
tab: &'a TimelineTab, tab: &'a TimelineTab,
reversed: bool,
note_options: NoteOptions, note_options: NoteOptions,
txn: &'a Transaction, txn: &'a Transaction,
note_context: &'a mut NoteContext<'d>, note_context: &'a mut NoteContext<'d>,
@@ -397,7 +385,6 @@ impl<'a, 'd> TimelineTabView<'a, 'd> {
#[allow(clippy::too_many_arguments)] #[allow(clippy::too_many_arguments)]
pub fn new( pub fn new(
tab: &'a TimelineTab, tab: &'a TimelineTab,
reversed: bool,
note_options: NoteOptions, note_options: NoteOptions,
txn: &'a Transaction, txn: &'a Transaction,
note_context: &'a mut NoteContext<'d>, note_context: &'a mut NoteContext<'d>,
@@ -405,7 +392,6 @@ impl<'a, 'd> TimelineTabView<'a, 'd> {
) -> Self { ) -> Self {
Self { Self {
tab, tab,
reversed,
note_options, note_options,
txn, txn,
note_context, note_context,