e4d0a88ffd
This change introduces a get_frame method to the viewer protocol, replacing the previous is_running check. This allows the viewer loop to skip rendering and lifecycle events when no active frame is ready (for example, when no browser is connected to the web viewer). Additionally, this change: - Adds a shutdown hook to ViewerHandle to wait for the viewer to cleanly release resources before exiting. - Implements an ExitEvent handler in the viewer protocol to stop the run loop. - Adds an http_port configuration option for the web viewer. - Prevents double-closing in the viewer. PiperOrigin-RevId: 954603868 Change-Id: Iaba7d131dc94191de51150464514dd10fa7834b0