Skip to content

Commit

Permalink
🚀 update docs from verso repository
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Nov 20, 2024
1 parent afc4a17 commit ddeb609
Show file tree
Hide file tree
Showing 31 changed files with 1,184 additions and 103 deletions.
2 changes: 1 addition & 1 deletion docs/search-index.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/search.desc/versoview/versoview-desc-0-.js

Large diffs are not rendered by default.

48 changes: 47 additions & 1 deletion docs/src/versoview/compositor.rs.html
Original file line number Diff line number Diff line change
Expand Up @@ -2189,6 +2189,29 @@
<a href="#2189" id="2189">2189</a>
<a href="#2190" id="2190">2190</a>
<a href="#2191" id="2191">2191</a>
<a href="#2192" id="2192">2192</a>
<a href="#2193" id="2193">2193</a>
<a href="#2194" id="2194">2194</a>
<a href="#2195" id="2195">2195</a>
<a href="#2196" id="2196">2196</a>
<a href="#2197" id="2197">2197</a>
<a href="#2198" id="2198">2198</a>
<a href="#2199" id="2199">2199</a>
<a href="#2200" id="2200">2200</a>
<a href="#2201" id="2201">2201</a>
<a href="#2202" id="2202">2202</a>
<a href="#2203" id="2203">2203</a>
<a href="#2204" id="2204">2204</a>
<a href="#2205" id="2205">2205</a>
<a href="#2206" id="2206">2206</a>
<a href="#2207" id="2207">2207</a>
<a href="#2208" id="2208">2208</a>
<a href="#2209" id="2209">2209</a>
<a href="#2210" id="2210">2210</a>
<a href="#2211" id="2211">2211</a>
<a href="#2212" id="2212">2212</a>
<a href="#2213" id="2213">2213</a>
<a href="#2214" id="2214">2214</a>
</pre></div><pre class="rust"><code><span class="kw">use </span>std::collections::{HashMap, HashSet};
<span class="kw">use </span>std::ffi::c_void;
<span class="kw">use </span>std::rc::Rc;
Expand Down Expand Up @@ -3297,6 +3320,10 @@

<span class="kw">if </span>close_window {
window_id = <span class="prelude-val">Some</span>(window.id());
} <span class="kw">else </span>{
<span class="comment">// if the window is not closed, we need to update the display list
// to remove the webview from viewport
</span><span class="self">self</span>.send_root_pipeline_display_list(window);
}

<span class="self">self</span>.frame_tree_id.next();
Expand Down Expand Up @@ -3520,7 +3547,8 @@
}
}

<span class="kw">fn </span>hit_test_at_point(<span class="kw-2">&amp;</span><span class="self">self</span>, point: DevicePoint) -&gt; <span class="prelude-ty">Option</span>&lt;CompositorHitTestResult&gt; {
<span class="doccomment">/// TODO: doc
</span><span class="kw">pub fn </span>hit_test_at_point(<span class="kw-2">&amp;</span><span class="self">self</span>, point: DevicePoint) -&gt; <span class="prelude-ty">Option</span>&lt;CompositorHitTestResult&gt; {
<span class="kw">return </span><span class="self">self
</span>.hit_test_at_point_with_flags_and_pipeline(point, HitTestFlags::empty(), <span class="prelude-val">None</span>)
.first()
Expand Down Expand Up @@ -4349,6 +4377,24 @@
<span class="self">self</span>.webrender_api
.send_transaction(<span class="self">self</span>.webrender_document, transaction);
}

<span class="doccomment">/// Get webview id on the position
</span><span class="kw">pub fn </span>webview_id_on_position(
<span class="kw-2">&amp;</span><span class="self">self</span>,
position: DevicePoint,
) -&gt; <span class="prelude-ty">Option</span>&lt;TopLevelBrowsingContextId&gt; {
<span class="kw">let </span>hit_result: <span class="prelude-ty">Option</span>&lt;CompositorHitTestResult&gt; = <span class="self">self</span>.hit_test_at_point(position);
<span class="kw">if let </span><span class="prelude-val">Some</span>(result) = hit_result {
<span class="kw">let </span>pipeline_id = result.pipeline_id;
<span class="kw">for </span>(w_id, p_id) <span class="kw">in </span><span class="kw-2">&amp;</span><span class="self">self</span>.webviews {
<span class="kw">if </span><span class="kw-2">*</span>p_id == pipeline_id {
<span class="kw">return </span><span class="prelude-val">Some</span>(<span class="kw-2">*</span>w_id);
}
}
}

<span class="prelude-val">None
</span>}
}

<span class="attr">#[derive(Debug, PartialEq)]
Expand Down
Loading

0 comments on commit ddeb609

Please # to comment.