refactor: collapse the table views into a generic TableView and drop dead code - #38
Merged
Merged
Conversation
…eView Topics, Nodes and Diagnostics were the same ViewClass, ViewState and visualizer copied three times. They are now TableSpec impls behind a generic TableView<S>/TableSystem<S>. The sort header draws re_ui's arrow icons and takes a column index instead of a per-view enum, view icons are inlined into their specs, and the Arrow text helper moves next to its only caller. The visualizer no longer advertises rewire's untagged descriptors as queried, which removes the "won't show in the defaults ui" warning.
node_count and topic_count differed only in entity path and component.
The struct only kept the MessageProxyHandle alive and its addr() had no caller outside its own tests.
The two-variant Forward enum had a single consumer.
Neither is referenced from src; re_sdk_types re-exports re_types_core. wasm-bindgen-futures stays because the #[wasm_bindgen] expansion of an async fn names it directly.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Ponytail audit pass over the viewer. Same three panels, same status bar, same CLI, about 40% less source and two fewer direct dependencies. The Topics, Nodes and Diagnostics views were the same
ViewClass,ViewStateand visualizer copied three times; everything else here is smaller cuts the same audit turned up.Changes
src/views/table.rsis a genericTableView<S>/TableSystem<S>over aTableSpectrait;topics.rs,nodes.rsanddiagnostics.rsare now 70–110 line specs (columns, descriptors, row parse,cmp,cell). The publicTopicsView/NodesView/DiagnosticsViewnames survive as type aliases, somain.rsandweb.rsregistration is untouched. Start the review here.re_ui::icons::ARROW_UP/ARROW_DOWNinstead of a hand-painted triangle and take a column index instead of per-view enums.queried, which removes the "won't show in the defaults ui" toast.queriedonly feeds the selection panel and visualizability is gated byconstraints, which staysNone.ControlServeris acontrol::spawn()function, the status bar's two count helpers are onelatest_len,RelayLink::forwardreturnsOption<bool>, and the bareuse <crate>;lines are gone.rerunandre_types_corewere unreferenced and are dropped.wasm-bindgen-futuresstays with a comment, since the#[wasm_bindgen]expansion ofasync fn startnames it.new Blob(chunks).arrayBuffer()instead of a manual copy loop.Checklist
cargo fmt --checkis cleancargo clippy --all-targets -- -D warningsis clean (native)cargo build --lib --target wasm32-unknown-unknown --no-default-featuresbuilds (wasm) — rancargo checkfor that target locally, leaving the full build to thebuild-wasmCI jobcargo testpasses///docsBreaking changes
Library API only. The
iconsandutilmodules andcontrol::ControlServerare removed from therewire_viewercrate. CLI flags, ports and the bridge/viewer protocol are unchanged.