Skip to content

Commit

Permalink
Update after review
Browse files Browse the repository at this point in the history
Co-authored-by: daxpedda <daxpedda@gmail.com>
  • Loading branch information
madsmtm and daxpedda committed Dec 25, 2023
1 parent eec47d5 commit f43bfde
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/platform/android.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,11 @@ pub mod activity {

#[cfg(not(android_platform))]
#[doc(hidden)]
pub struct Rect(());
pub struct Rect;
#[cfg(not(android_platform))]
#[doc(hidden)]
pub struct ConfigurationRef(());
pub struct ConfigurationRef;
#[cfg(not(android_platform))]
#[doc(hidden)]
pub struct AndroidApp(());
pub struct AndroidApp;
}
7 changes: 6 additions & 1 deletion src/platform/web.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ use web_sys::HtmlCanvasElement;

#[cfg(not(wasm_platform))]
#[doc(hidden)]
pub struct HtmlCanvasElement(());
pub struct HtmlCanvasElement;

pub trait WindowExtWebSys {
/// Only returns the canvas if called from inside the window context (the
Expand Down Expand Up @@ -86,6 +86,11 @@ pub trait WindowBuilderExtWebSys {
/// In any case, the canvas won't be automatically inserted into the web page.
///
/// [`None`] by default.
#[cfg_attr(
not(wasm_platform),
doc = "",
doc = "[`HtmlCanvasElement`]: #only-available-on-wasm"
)]
fn with_canvas(self, canvas: Option<HtmlCanvasElement>) -> Self;

/// Sets whether `event.preventDefault()` should be called on events on the
Expand Down

0 comments on commit f43bfde

Please sign in to comment.