Skip to main content

parse_css_with_layers_poll

Function parse_css_with_layers_poll 

Source
pub fn parse_css_with_layers_poll(
    css: &str,
    layer_names: &mut Vec<String>,
    poll: &mut dyn FnMut() -> bool,
) -> StyleSheet
Expand description

parse_css_with_layers に、規則 PARSE_CSS_POLL_EVERY 個ごと(@media などの中の規則も数える)に poll を呼ぶ口を 付けたもの(2026-11-18、TODO R2 (b) ②)。poll が true(このタブだけ止める合図)を返したら、そこまでの規則を返す (途中までの表。呼び出し側は合図を見て使わずに捨てる)。 poll に止める確かめを渡すのは、錠を持っていないアプリのスレッドの呼び出し元(parse_and_layout の中)だけ。