Skip to content

Commit

Permalink
refactor: use updated ratatui-binary-data-widget
Browse files Browse the repository at this point in the history
  • Loading branch information
EdJoPaTo committed May 21, 2024
1 parent 73c71a9 commit 9ba4c6b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 14 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 3 additions & 13 deletions src/interactive/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -576,19 +576,9 @@ impl App {
match self.get_selected_payload() {
None => return Refresh::Update, // No payload but click into payload area -> redraw
Some(Payload::Binary(_)) => {
if let Some(address) = self
.details
.payload
.binary_state
.clicked_address(column, row)
{
self.details
.payload
.binary_state
.select_address(Some(address));
self.focus = ElementInFocus::Payload;
return Refresh::Update;
}
self.details.payload.binary_state.select_at(column, row);
self.focus = ElementInFocus::Payload;
return Refresh::Update;
}
Some(Payload::Json(json)) => {
let items = tree_items_from_json(&json);
Expand Down

0 comments on commit 9ba4c6b

Please sign in to comment.