Skip to content

#448-A: Extract fn dispatch() from fn update; replace sender.input() in impl App (sub-task 1/3 of #448) #538

Description

@JDonaghy

Sub-task of #448 — Migrate GTK event dispatch to ShellApp::handle(UiEvent)

Scope (chunk 1 of 3): #448-A: Extract fn dispatch() from fn update; replace sender.input() in impl App

Mechanical refactor only — no logic changes. (1) Add fn dispatch(&mut self, msg: Msg) to impl App; move body of fn update (lines 4128–4889) into it; make fn update a 1-liner calling self.dispatch(msg). (2) Inside the moved body, replace the 2 sender.input(Msg::RefreshFileTree) calls with self.dispatch(Msg::RefreshFileTree). (3) In impl App (lines 4890–10485), replace all 43 sender.input(Msg::X) calls with self.dispatch(Msg::X) — pure search-and-replace, do not interpret logic. DO NOT touch fn init (lines 1913–4127): GDK controller closures there still use sender.input() and will be deleted wholesale in #448-C. Do not read the full file — grep sender.input( in range 4128–10485 to find all 45 sites. Exit criterion: cargo build and cargo test --no-default-features pass, no behavior change.

Files likely touched

  • src/gtk/mod.rs

Context

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    coordTracked by coord-tui pipelineenhancementNew feature or requestinfrastructureBuild, CI, distributionstatus:readyRefined and ready to enter the work pipelinesub-taskSub-task of a parent issue

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions