notedeck

One damus client to rule them all
git clone git://jb55.com/notedeck
Log | Files | Refs | README | LICENSE

commit 2e991a9aa55f26aeeb8351fa8e885729f048f44e
parent 8467de2b5d8772ba291bc1526752402dccfdd106
Author: William Casarin <jb55@jb55.com>
Date:   Tue, 11 Mar 2025 10:55:15 -0700

fix a few compile issues after rebase

Signed-off-by: William Casarin <jb55@jb55.com>

Diffstat:
Mcrates/notedeck_columns/src/ui/note/mod.rs | 27+++++++++++++++------------
Mcrates/notedeck_columns/src/ui/note/post.rs | 2+-
Mcrates/notedeck_columns/src/ui/note/reply.rs | 2+-
Mcrates/notedeck_columns/src/ui/search/mod.rs | 4++--
4 files changed, 19 insertions(+), 16 deletions(-)

diff --git a/crates/notedeck_columns/src/ui/note/mod.rs b/crates/notedeck_columns/src/ui/note/mod.rs @@ -250,7 +250,7 @@ impl<'a, 'd> NoteView<'a, 'd> { None => { // This has to match the expand size from the above case to // prevent bounciness - let size = pfp_size + ui::NoteView::expand_size(); + let size = (pfp_size + ui::NoteView::expand_size()) as f32; let (rect, _response) = ui.allocate_exact_size(egui::vec2(size, size), sense); ui.put( @@ -355,17 +355,20 @@ impl<'a, 'd> NoteView<'a, 'd> { let size = ui.available_size(); ui.vertical(|ui| { - ui.add_sized([size.x, self.options().pfp_size() as f32], |ui: &mut egui::Ui| { - ui.horizontal_centered(|ui| { - NoteView::note_header( - ui, - self.note_context.note_cache, - self.note, - &profile, - ); - }) - .response - }); + ui.add_sized( + [size.x, self.options().pfp_size() as f32], + |ui: &mut egui::Ui| { + ui.horizontal_centered(|ui| { + NoteView::note_header( + ui, + self.note_context.note_cache, + self.note, + &profile, + ); + }) + .response + }, + ); let note_reply = self .note_context diff --git a/crates/notedeck_columns/src/ui/note/post.rs b/crates/notedeck_columns/src/ui/note/post.rs @@ -324,7 +324,7 @@ impl<'a, 'd> PostView<'a, 'd> { if let PostType::Quote(id) = self.post_type { let avail_size = ui.available_size_before_wrap(); ui.with_layout(Layout::left_to_right(egui::Align::TOP), |ui| { - context_selection = Frame::none() + context_selection = Frame::NONE .show(ui, |ui| { ui.vertical(|ui| { ui.set_max_width(avail_size.x * 0.8); diff --git a/crates/notedeck_columns/src/ui/note/reply.rs b/crates/notedeck_columns/src/ui/note/reply.rs @@ -61,7 +61,7 @@ impl<'a, 'd> PostReplyView<'a, 'd> { let note_offset: i8 = pfp_offset - ui::ProfilePic::medium_size() / 2 - ui::NoteView::expand_size() / 2; - let selection = egui::Frame::none() + let selection = egui::Frame::NONE .outer_margin(egui::Margin::same(note_offset)) .show(ui, |ui| { ui::NoteView::new(self.note_context, self.note, self.note_options) diff --git a/crates/notedeck_columns/src/ui/search/mod.rs b/crates/notedeck_columns/src/ui/search/mod.rs @@ -136,9 +136,9 @@ fn search_box(query: &mut SearchQueryState, ui: &mut egui::Ui) -> bool { ui.horizontal(|ui| { // Container for search input and icon let search_container = egui::Frame { - inner_margin: egui::Margin::symmetric(8.0, 0.0), + inner_margin: egui::Margin::symmetric(8, 0), outer_margin: egui::Margin::ZERO, - rounding: Rounding::same(18.0), // More rounded corners + rounding: Rounding::same(18), // More rounded corners shadow: Default::default(), fill: Color32::from_rgb(30, 30, 30), // Darker background to match screenshot stroke: Stroke::new(1.0, Color32::from_rgb(60, 60, 60)),