handle_report_pool_drain_decision

Function handle_report_pool_drain_decision 

Source
pub(super) fn handle_report_pool_drain_decision(
    state: &mut State,
    label: String,
    was_last: bool,
    saga_id: Option<u64>,
) -> Vec<Event>
Expand description

Phase F.6 — host-emitted signal carrying the result of the post-close drain-pool-if-last decision. Maps was_last directly to the corresponding terminal event for Step 2 of the window-cleanup-cascade saga:

  • trueEvent::PoolDrained (last user-visible window closed; warm-pool drain initiated)
  • falseEvent::PoolNotLast (other windows remain; pool stays warm)

Pure pass-through (same reasoning as handle_report_panes_reaped).