mirror of
https://github.com/a-b-street/abstreet.git
synced 2024-11-23 08:54:30 +03:00
deploy: 0eb366a5e3
This commit is contained in:
parent
3479799e4e
commit
5bf51b50b7
@ -43,7 +43,7 @@ minimap. <a href="../../map_gui/tools/minimap/trait.MinimapControls.html#method.
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.before_quit" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/game/app.rs.html#876-878">source</a></span><a href="#method.before_quit" class="anchor"></a><h4 class="code-header">fn <a href="#method.before_quit" class="fnname">before_quit</a>(&self, canvas: &Canvas)</h4></section></summary><div class='docblock'><p>Called before a normal exit, like window close</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.free_memory" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/game/app.rs.html#880-882">source</a></span><a href="#method.free_memory" class="anchor"></a><h4 class="code-header">fn <a href="#method.free_memory" class="fnname">free_memory</a>(&mut self)</h4></section></summary><div class='docblock'><p>If widgetry determines the video card is low on memory, this may be called. The application
|
||||
should make its best effort to delete any unused Drawables. <a href="#method.free_memory">Read more</a></p>
|
||||
</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-SimpleState%3CApp%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/game/challenges/mod.rs.html#240-279">source</a></span><a href="#impl-SimpleState%3CApp%3E" class="anchor"></a><h3 class="code-header in-band">impl SimpleState<<a class="struct" href="struct.App.html" title="struct game::app::App">App</a>> for <a class="struct" href="../challenges/struct.ChallengesPicker.html" title="struct game::challenges::ChallengesPicker">ChallengesPicker</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/game/challenges/mod.rs.html#241-278">source</a></span><a href="#method.on_click" class="anchor"></a><h4 class="code-header">fn <a class="fnname">on_click</a>(<br> &mut self, <br> ctx: &mut EventCtx<'_>, <br> app: &mut <a class="struct" href="struct.App.html" title="struct game::app::App">App</a>, <br> x: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>, <br> _: &mut Panel<br>) -> Transition<<a class="struct" href="struct.App.html" title="struct game::app::App">App</a>></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked. Since the action is just a string,
|
||||
</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-SimpleState%3CApp%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/game/challenges/mod.rs.html#241-292">source</a></span><a href="#impl-SimpleState%3CApp%3E" class="anchor"></a><h3 class="code-header in-band">impl SimpleState<<a class="struct" href="struct.App.html" title="struct game::app::App">App</a>> for <a class="struct" href="../challenges/struct.ChallengesPicker.html" title="struct game::challenges::ChallengesPicker">ChallengesPicker</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/game/challenges/mod.rs.html#242-291">source</a></span><a href="#method.on_click" class="anchor"></a><h4 class="code-header">fn <a class="fnname">on_click</a>(<br> &mut self, <br> ctx: &mut EventCtx<'_>, <br> app: &mut <a class="struct" href="struct.App.html" title="struct game::app::App">App</a>, <br> x: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>, <br> _: &mut Panel<br>) -> Transition<<a class="struct" href="struct.App.html" title="struct game::app::App">App</a>></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked. Since the action is just a string,
|
||||
the fallback case can just use <code>unreachable!()</code>. <a href="#tymethod.on_click">Read more</a></p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click_custom" class="method trait-impl has-srclink"><a href="#method.on_click_custom" class="anchor"></a><h4 class="code-header">fn <a href="#method.on_click_custom" class="fnname">on_click_custom</a>(<br> &mut self, <br> _ctx: &mut EventCtx<'_>, <br> _app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> _action: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="../../abstutil/clone/trait.CloneableAny.html" title="trait abstutil::clone::CloneableAny">CloneableAny</a> + 'static, <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/alloc/struct.Global.html" title="struct alloc::alloc::Global">Global</a>>, <br> _panel: &mut Panel<br>) -> Transition<A></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked.</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.panel_changed" class="method trait-impl has-srclink"><a href="#method.panel_changed" class="anchor"></a><h4 class="code-header">fn <a href="#method.panel_changed" class="fnname">panel_changed</a>(<br> &mut self, <br> &mut EventCtx<'_>, <br> <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> &mut Panel<br>) -> <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><Transition<A>></h4></section></summary><div class='docblock'><p>Called when something on the panel has changed. If a transition is returned, stop handling
|
||||
|
@ -4,7 +4,7 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../game/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"><a href="#">Module challenges</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#modules">Modules</a></li><li><a href="#structs">Structs</a></li></ul></div></section><div id="sidebar-vars" data-name="challenges" data-ty="mod" data-relpath="./"></div><script defer src="./sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../game/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../index.html">game</a>::<wbr><a class="mod" href="#">challenges</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/game/challenges/mod.rs.html#1-279">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="modules" class="small-section-header"><a href="#modules">Modules</a></h2>
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../index.html">game</a>::<wbr><a class="mod" href="#">challenges</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/game/challenges/mod.rs.html#1-292">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="modules" class="small-section-header"><a href="#modules">Modules</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="mod" href="cutscene/index.html" title="game::challenges::cutscene mod">cutscene</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="mod" href="prebake/index.html" title="game::challenges::prebake mod">prebake</a></div><div class="item-right docblock-short"></div></div></div><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Challenge.html" title="game::challenges::Challenge struct">Challenge</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.ChallengesPicker.html" title="game::challenges::ChallengesPicker struct">ChallengesPicker</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.HighScore.html" title="game::challenges::HighScore struct">HighScore</a></div><div class="item-right docblock-short"></div></div></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="game" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -4,5 +4,5 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../game/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In game::pregame::proposals</a></h2><div id="sidebar-vars" data-name="launch" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../game/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">game</a>::<wbr><a href="../index.html">pregame</a>::<wbr><a href="index.html">proposals</a>::<wbr><a class="fn" href="#">launch</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/game/pregame/proposals.rs.html#137-180">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn launch(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../app/struct.App.html" title="struct game::app::App">App</a>, <br> edits: <a class="struct" href="../../../map_model/edits/perma/struct.PermanentMapEdits.html" title="struct map_model::edits::perma::PermanentMapEdits">PermanentMapEdits</a><br>) -> Transition<<a class="struct" href="../../app/struct.App.html" title="struct game::app::App">App</a>></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="game" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">game</a>::<wbr><a href="../index.html">pregame</a>::<wbr><a href="index.html">proposals</a>::<wbr><a class="fn" href="#">launch</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/game/pregame/proposals.rs.html#137-184">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn launch(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../app/struct.App.html" title="struct game::app::App">App</a>, <br> edits: <a class="struct" href="../../../map_model/edits/perma/struct.PermanentMapEdits.html" title="struct map_model::edits::perma::PermanentMapEdits">PermanentMapEdits</a><br>) -> Transition<<a class="struct" href="../../app/struct.App.html" title="struct game::app::App">App</a>></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="game" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,7 +4,7 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../game/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"><a href="#">Module proposals</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#structs">Structs</a></li><li><a href="#functions">Functions</a></li></ul></div></section><div id="sidebar-vars" data-name="proposals" data-ty="mod" data-relpath="./"></div><script defer src="./sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../game/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../../index.html">game</a>::<wbr><a href="../index.html">pregame</a>::<wbr><a class="mod" href="#">proposals</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/game/pregame/proposals.rs.html#1-180">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2>
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../../index.html">game</a>::<wbr><a href="../index.html">pregame</a>::<wbr><a class="mod" href="#">proposals</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/game/pregame/proposals.rs.html#1-184">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Proposals.html" title="game::pregame::proposals::Proposals struct">Proposals</a></div><div class="item-right docblock-short"></div></div></div><h2 id="functions" class="small-section-header"><a href="#functions">Functions</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.launch.html" title="game::pregame::proposals::launch fn">launch</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="game" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,5 +4,5 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_gui::tools::city_picker</a></h2><div id="sidebar-vars" data-name="chose_city" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="fn" href="#">chose_city</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#500-519">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn chose_city<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static>(<br> ctx: &mut EventCtx<'_>, <br> app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> name: <a class="struct" href="../../../abstio/abst_paths/struct.MapName.html" title="struct abstio::abst_paths::MapName">MapName</a>, <br> on_load: &mut <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>><br>) -> Transition<A></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="fn" href="#">chose_city</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#517-543">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn chose_city<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static>(<br> ctx: &mut EventCtx<'_>, <br> app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> name: <a class="struct" href="../../../abstio/abst_paths/struct.MapName.html" title="struct abstio::abst_paths::MapName">MapName</a>, <br> on_load: &mut <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>><br>) -> Transition<A></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,5 +4,5 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_gui::tools::city_picker</a></h2><div id="sidebar-vars" data-name="cities_per_country" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="fn" href="#">cities_per_country</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#489-498">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn cities_per_country() -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/collections/btree/map/struct.BTreeMap.html" title="struct alloc::collections::btree::map::BTreeMap">BTreeMap</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>, <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/vec/struct.Vec.html" title="struct alloc::vec::Vec">Vec</a><<a class="struct" href="../../../abstio/abst_paths/struct.CityName.html" title="struct abstio::abst_paths::CityName">CityName</a>>></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="fn" href="#">cities_per_country</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#506-515">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn cities_per_country() -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/collections/btree/map/struct.BTreeMap.html" title="struct alloc::collections::btree::map::BTreeMap">BTreeMap</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>, <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/vec/struct.Vec.html" title="struct alloc::vec::Vec">Vec</a><<a class="struct" href="../../../abstio/abst_paths/struct.CityName.html" title="struct abstio::abst_paths::CityName">CityName</a>>></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,5 +4,5 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_gui::tools::city_picker</a></h2><div id="sidebar-vars" data-name="reimport_city" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="fn" href="#">reimport_city</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#522-577">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn reimport_city<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static>(<br> ctx: &mut EventCtx<'_>, <br> app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&</a>A<br>) -> Transition<A></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="fn" href="#">reimport_city</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#546-601">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn reimport_city<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static>(<br> ctx: &mut EventCtx<'_>, <br> app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&</a>A<br>) -> Transition<A></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,7 +4,7 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"><a href="#">Module city_picker</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#structs">Structs</a></li><li><a href="#functions">Functions</a></li></ul></div></section><div id="sidebar-vars" data-name="city_picker" data-ty="mod" data-relpath="./"></div><script defer src="./sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a class="mod" href="#">city_picker</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#1-577">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2>
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a class="mod" href="#">city_picker</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#1-601">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.AllCityPicker.html" title="map_gui::tools::city_picker::AllCityPicker struct">AllCityPicker</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.CitiesInCountryPicker.html" title="map_gui::tools::city_picker::CitiesInCountryPicker struct">CitiesInCountryPicker</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.CityPicker.html" title="map_gui::tools::city_picker::CityPicker struct">CityPicker</a></div><div class="item-right docblock-short"><p>Lets the player switch maps.</p>
|
||||
</div></div></div><h2 id="functions" class="small-section-header"><a href="#functions">Functions</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.chose_city.html" title="map_gui::tools::city_picker::chose_city fn">chose_city</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.cities_per_country.html" title="map_gui::tools::city_picker::cities_per_country fn">cities_per_country</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.reimport_city.html" title="map_gui::tools::city_picker::reimport_city fn">reimport_city</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
|
@ -4,12 +4,12 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"><a href="#">AllCityPicker</a></h2><div class="sidebar-elems"><section><div class="block"><h3 class="sidebar-title"><a href="#fields">Fields</a></h3><ul><li><a href="#structfield.on_load">on_load</a></li><li><a href="#structfield.panel">panel</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#implementations">Methods</a></h3><ul><li><a href="#method.new_state">new_state</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#trait-implementations">Trait Implementations</a></h3><ul><li><a href="#impl-State%3CA%3E">State<A></a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#synthetic-implementations">Auto Trait Implementations</a></h3><ul><li><a href="#impl-RefUnwindSafe">!RefUnwindSafe</a></li><li><a href="#impl-Send">!Send</a></li><li><a href="#impl-Sync">!Sync</a></li><li><a href="#impl-Unpin">Unpin</a></li><li><a href="#impl-UnwindSafe">!UnwindSafe</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#blanket-implementations">Blanket Implementations</a></h3><ul><li><a href="#impl-Any">Any</a></li><li><a href="#impl-Borrow%3CT%3E">Borrow<T></a></li><li><a href="#impl-BorrowMut%3CT%3E">BorrowMut<T></a></li><li><a href="#impl-Downcast">Downcast</a></li><li><a href="#impl-From%3CT%3E">From<T></a></li><li><a href="#impl-Instrument">Instrument</a></li><li><a href="#impl-Into%3CU%3E">Into<U></a></li><li><a href="#impl-Same%3CT%3E">Same<T></a></li><li><a href="#impl-TryFrom%3CU%3E">TryFrom<U></a></li><li><a href="#impl-TryInto%3CU%3E">TryInto<U></a></li><li><a href="#impl-VZip%3CV%3E">VZip<V></a></li></ul></div></section><h2 class="location"><a href="index.html">In map_gui::tools::city_picker</a></h2><div id="sidebar-vars" data-name="AllCityPicker" data-ty="struct" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Struct <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="struct" href="#">AllCityPicker</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#258-262">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust struct"><code>struct AllCityPicker<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a>> {
|
||||
<h1 class="fqn"><span class="in-band">Struct <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="struct" href="#">AllCityPicker</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#264-268">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust struct"><code>struct AllCityPicker<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a>> {
|
||||
panel: Panel,
|
||||
on_load: <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>>,
|
||||
}</code></pre></div><h2 id="fields" class="fields small-section-header">Fields<a href="#fields" class="anchor"></a></h2><span id="structfield.panel" class="structfield small-section-header"><a href="#structfield.panel" class="anchor field"></a><code>panel: Panel</code></span><span id="structfield.on_load" class="structfield small-section-header"><a href="#structfield.on_load" class="anchor field"></a><code>on_load: <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>></code></span><h2 id="implementations" class="small-section-header">Implementations<a href="#implementations" class="anchor"></a></h2><div id="implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#264-303">source</a></span><a href="#impl" class="anchor"></a><h3 class="code-header in-band">impl<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static> <a class="struct" href="struct.AllCityPicker.html" title="struct map_gui::tools::city_picker::AllCityPicker">AllCityPicker</a><A></h3></section></summary><div class="impl-items"><section id="method.new_state" class="method has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#265-302">source</a></span><a href="#method.new_state" class="anchor"></a><h4 class="code-header">fn <a href="#method.new_state" class="fnname">new_state</a>(<br> ctx: &mut EventCtx<'_>, <br> on_load: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>><br>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<A>></h4></section></div></details></div><h2 id="trait-implementations" class="small-section-header">Trait Implementations<a href="#trait-implementations" class="anchor"></a></h2><div id="trait-implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-State%3CA%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#305-344">source</a></span><a href="#impl-State%3CA%3E" class="anchor"></a><h3 class="code-header in-band">impl<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static> State<A> for <a class="struct" href="struct.AllCityPicker.html" title="struct map_gui::tools::city_picker::AllCityPicker">AllCityPicker</a><A></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.event" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#306-334">source</a></span><a href="#method.event" class="anchor"></a><h4 class="code-header">fn <a class="fnname">event</a>(&mut self, ctx: &mut EventCtx<'_>, app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A></h4></section></summary><div class='docblock'><p>Respond to a UI event, such as input or time passing.</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.draw_baselayer" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#336-338">source</a></span><a href="#method.draw_baselayer" class="anchor"></a><h4 class="code-header">fn <a href="#method.draw_baselayer" class="fnname">draw_baselayer</a>(&self) -> DrawBaselayer</h4></section></summary><div class='docblock'><p>Specifies what to draw before draw()</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.draw" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#340-343">source</a></span><a href="#method.draw" class="anchor"></a><h4 class="code-header">fn <a class="fnname">draw</a>(&self, g: &mut GfxCtx<'_>, app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&</a>A)</h4></section></summary><div class='docblock'><p>Draw</p>
|
||||
}</code></pre></div><h2 id="fields" class="fields small-section-header">Fields<a href="#fields" class="anchor"></a></h2><span id="structfield.panel" class="structfield small-section-header"><a href="#structfield.panel" class="anchor field"></a><code>panel: Panel</code></span><span id="structfield.on_load" class="structfield small-section-header"><a href="#structfield.on_load" class="anchor field"></a><code>on_load: <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>></code></span><h2 id="implementations" class="small-section-header">Implementations<a href="#implementations" class="anchor"></a></h2><div id="implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#270-309">source</a></span><a href="#impl" class="anchor"></a><h3 class="code-header in-band">impl<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static> <a class="struct" href="struct.AllCityPicker.html" title="struct map_gui::tools::city_picker::AllCityPicker">AllCityPicker</a><A></h3></section></summary><div class="impl-items"><section id="method.new_state" class="method has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#271-308">source</a></span><a href="#method.new_state" class="anchor"></a><h4 class="code-header">fn <a href="#method.new_state" class="fnname">new_state</a>(<br> ctx: &mut EventCtx<'_>, <br> on_load: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>><br>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<A>></h4></section></div></details></div><h2 id="trait-implementations" class="small-section-header">Trait Implementations<a href="#trait-implementations" class="anchor"></a></h2><div id="trait-implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-State%3CA%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#311-355">source</a></span><a href="#impl-State%3CA%3E" class="anchor"></a><h3 class="code-header in-band">impl<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static> State<A> for <a class="struct" href="struct.AllCityPicker.html" title="struct map_gui::tools::city_picker::AllCityPicker">AllCityPicker</a><A></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.event" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#312-345">source</a></span><a href="#method.event" class="anchor"></a><h4 class="code-header">fn <a class="fnname">event</a>(&mut self, ctx: &mut EventCtx<'_>, app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A></h4></section></summary><div class='docblock'><p>Respond to a UI event, such as input or time passing.</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.draw_baselayer" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#347-349">source</a></span><a href="#method.draw_baselayer" class="anchor"></a><h4 class="code-header">fn <a href="#method.draw_baselayer" class="fnname">draw_baselayer</a>(&self) -> DrawBaselayer</h4></section></summary><div class='docblock'><p>Specifies what to draw before draw()</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.draw" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#351-354">source</a></span><a href="#method.draw" class="anchor"></a><h4 class="code-header">fn <a class="fnname">draw</a>(&self, g: &mut GfxCtx<'_>, app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&</a>A)</h4></section></summary><div class='docblock'><p>Draw</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_destroy" class="method trait-impl has-srclink"><a href="#method.on_destroy" class="anchor"></a><h4 class="code-header">fn <a href="#method.on_destroy" class="fnname">on_destroy</a>(&mut self, &mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A)</h4></section></summary><div class='docblock'><p>Before this state is popped or replaced, call this.</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.recreate" class="method trait-impl has-srclink"><a href="#method.recreate" class="anchor"></a><h4 class="code-header">fn <a href="#method.recreate" class="fnname">recreate</a>(<br> &mut self, <br> &mut EventCtx<'_>, <br> <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A<br>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<A> + 'static, <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/alloc/struct.Global.html" title="struct alloc::alloc::Global">Global</a>></h4></section></summary><div class='docblock'><p>Respond to <code>Transition::Recreate</code> by assuming state in the app has changed, but preserving
|
||||
the <code>State</code>-specific state appropriately. <a href="#method.recreate">Read more</a></p>
|
||||
|
@ -4,12 +4,12 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"><a href="#">CitiesInCountryPicker</a></h2><div class="sidebar-elems"><section><div class="block"><h3 class="sidebar-title"><a href="#fields">Fields</a></h3><ul><li><a href="#structfield.on_load">on_load</a></li><li><a href="#structfield.panel">panel</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#implementations">Methods</a></h3><ul><li><a href="#method.new_state">new_state</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#trait-implementations">Trait Implementations</a></h3><ul><li><a href="#impl-State%3CA%3E">State<A></a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#synthetic-implementations">Auto Trait Implementations</a></h3><ul><li><a href="#impl-RefUnwindSafe">!RefUnwindSafe</a></li><li><a href="#impl-Send">!Send</a></li><li><a href="#impl-Sync">!Sync</a></li><li><a href="#impl-Unpin">Unpin</a></li><li><a href="#impl-UnwindSafe">!UnwindSafe</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#blanket-implementations">Blanket Implementations</a></h3><ul><li><a href="#impl-Any">Any</a></li><li><a href="#impl-Borrow%3CT%3E">Borrow<T></a></li><li><a href="#impl-BorrowMut%3CT%3E">BorrowMut<T></a></li><li><a href="#impl-Downcast">Downcast</a></li><li><a href="#impl-From%3CT%3E">From<T></a></li><li><a href="#impl-Instrument">Instrument</a></li><li><a href="#impl-Into%3CU%3E">Into<U></a></li><li><a href="#impl-Same%3CT%3E">Same<T></a></li><li><a href="#impl-TryFrom%3CU%3E">TryFrom<U></a></li><li><a href="#impl-TryInto%3CU%3E">TryInto<U></a></li><li><a href="#impl-VZip%3CV%3E">VZip<V></a></li></ul></div></section><h2 class="location"><a href="index.html">In map_gui::tools::city_picker</a></h2><div id="sidebar-vars" data-name="CitiesInCountryPicker" data-ty="struct" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Struct <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="struct" href="#">CitiesInCountryPicker</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#346-350">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust struct"><code>struct CitiesInCountryPicker<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a>> {
|
||||
<h1 class="fqn"><span class="in-band">Struct <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">city_picker</a>::<wbr><a class="struct" href="#">CitiesInCountryPicker</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#357-361">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust struct"><code>struct CitiesInCountryPicker<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a>> {
|
||||
panel: Panel,
|
||||
on_load: <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>>,
|
||||
}</code></pre></div><h2 id="fields" class="fields small-section-header">Fields<a href="#fields" class="anchor"></a></h2><span id="structfield.panel" class="structfield small-section-header"><a href="#structfield.panel" class="anchor field"></a><code>panel: Panel</code></span><span id="structfield.on_load" class="structfield small-section-header"><a href="#structfield.on_load" class="anchor field"></a><code>on_load: <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>></code></span><h2 id="implementations" class="small-section-header">Implementations<a href="#implementations" class="anchor"></a></h2><div id="implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#352-430">source</a></span><a href="#impl" class="anchor"></a><h3 class="code-header in-band">impl<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static> <a class="struct" href="struct.CitiesInCountryPicker.html" title="struct map_gui::tools::city_picker::CitiesInCountryPicker">CitiesInCountryPicker</a><A></h3></section></summary><div class="impl-items"><section id="method.new_state" class="method has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#353-429">source</a></span><a href="#method.new_state" class="anchor"></a><h4 class="code-header">fn <a href="#method.new_state" class="fnname">new_state</a>(<br> ctx: &mut EventCtx<'_>, <br> app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&</a>A, <br> on_load: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>, <br> country: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a><br>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<A>></h4></section></div></details></div><h2 id="trait-implementations" class="small-section-header">Trait Implementations<a href="#trait-implementations" class="anchor"></a></h2><div id="trait-implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-State%3CA%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#432-487">source</a></span><a href="#impl-State%3CA%3E" class="anchor"></a><h3 class="code-header in-band">impl<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static> State<A> for <a class="struct" href="struct.CitiesInCountryPicker.html" title="struct map_gui::tools::city_picker::CitiesInCountryPicker">CitiesInCountryPicker</a><A></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.event" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#433-477">source</a></span><a href="#method.event" class="anchor"></a><h4 class="code-header">fn <a class="fnname">event</a>(&mut self, ctx: &mut EventCtx<'_>, app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A></h4></section></summary><div class='docblock'><p>Respond to a UI event, such as input or time passing.</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.draw_baselayer" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#479-481">source</a></span><a href="#method.draw_baselayer" class="anchor"></a><h4 class="code-header">fn <a href="#method.draw_baselayer" class="fnname">draw_baselayer</a>(&self) -> DrawBaselayer</h4></section></summary><div class='docblock'><p>Specifies what to draw before draw()</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.draw" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#483-486">source</a></span><a href="#method.draw" class="anchor"></a><h4 class="code-header">fn <a class="fnname">draw</a>(&self, g: &mut GfxCtx<'_>, app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&</a>A)</h4></section></summary><div class='docblock'><p>Draw</p>
|
||||
}</code></pre></div><h2 id="fields" class="fields small-section-header">Fields<a href="#fields" class="anchor"></a></h2><span id="structfield.panel" class="structfield small-section-header"><a href="#structfield.panel" class="anchor field"></a><code>panel: Panel</code></span><span id="structfield.on_load" class="structfield small-section-header"><a href="#structfield.on_load" class="anchor field"></a><code>on_load: <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>></code></span><h2 id="implementations" class="small-section-header">Implementations<a href="#implementations" class="anchor"></a></h2><div id="implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#363-441">source</a></span><a href="#impl" class="anchor"></a><h3 class="code-header in-band">impl<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static> <a class="struct" href="struct.CitiesInCountryPicker.html" title="struct map_gui::tools::city_picker::CitiesInCountryPicker">CitiesInCountryPicker</a><A></h3></section></summary><div class="impl-items"><section id="method.new_state" class="method has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#364-440">source</a></span><a href="#method.new_state" class="anchor"></a><h4 class="code-header">fn <a href="#method.new_state" class="fnname">new_state</a>(<br> ctx: &mut EventCtx<'_>, <br> app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&</a>A, <br> on_load: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>>, <br> country: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a><br>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<A>></h4></section></div></details></div><h2 id="trait-implementations" class="small-section-header">Trait Implementations<a href="#trait-implementations" class="anchor"></a></h2><div id="trait-implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-State%3CA%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#443-504">source</a></span><a href="#impl-State%3CA%3E" class="anchor"></a><h3 class="code-header in-band">impl<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static> State<A> for <a class="struct" href="struct.CitiesInCountryPicker.html" title="struct map_gui::tools::city_picker::CitiesInCountryPicker">CitiesInCountryPicker</a><A></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.event" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#444-494">source</a></span><a href="#method.event" class="anchor"></a><h4 class="code-header">fn <a class="fnname">event</a>(&mut self, ctx: &mut EventCtx<'_>, app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A></h4></section></summary><div class='docblock'><p>Respond to a UI event, such as input or time passing.</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.draw_baselayer" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#496-498">source</a></span><a href="#method.draw_baselayer" class="anchor"></a><h4 class="code-header">fn <a href="#method.draw_baselayer" class="fnname">draw_baselayer</a>(&self) -> DrawBaselayer</h4></section></summary><div class='docblock'><p>Specifies what to draw before draw()</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.draw" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../../src/map_gui/tools/city_picker.rs.html#500-503">source</a></span><a href="#method.draw" class="anchor"></a><h4 class="code-header">fn <a class="fnname">draw</a>(&self, g: &mut GfxCtx<'_>, app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&</a>A)</h4></section></summary><div class='docblock'><p>Draw</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_destroy" class="method trait-impl has-srclink"><a href="#method.on_destroy" class="anchor"></a><h4 class="code-header">fn <a href="#method.on_destroy" class="fnname">on_destroy</a>(&mut self, &mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A)</h4></section></summary><div class='docblock'><p>Before this state is popped or replaced, call this.</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.recreate" class="method trait-impl has-srclink"><a href="#method.recreate" class="anchor"></a><h4 class="code-header">fn <a href="#method.recreate" class="fnname">recreate</a>(<br> &mut self, <br> &mut EventCtx<'_>, <br> <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A<br>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<A> + 'static, <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/alloc/struct.Global.html" title="struct alloc::alloc::Global">Global</a>></h4></section></summary><div class='docblock'><p>Respond to <code>Transition::Recreate</code> by assuming state in the app has changed, but preserving
|
||||
the <code>State</code>-specific state appropriately. <a href="#method.recreate">Read more</a></p>
|
||||
|
File diff suppressed because one or more lines are too long
@ -1,11 +1,8 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Prompt to download a missing city. On either success or failure (maybe the player choosing to not download, maybe a network error), the new map isn’t automatically loaded or anything; up to the caller to handle that."><meta name="keywords" content="rust, rustlang, rust-lang, prompt_to_download_missing_data"><title>prompt_to_download_missing_data in map_gui::tools - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script src="../../crates.js"></script><script defer src="../../main.js"></script>
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="API documentation for the Rust `prompt_to_download_missing_data` fn in crate `map_gui`."><meta name="keywords" content="rust, rustlang, rust-lang, prompt_to_download_missing_data"><title>prompt_to_download_missing_data in map_gui::tools - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../normalize.css"><link rel="stylesheet" type="text/css" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script src="../../crates.js"></script><script defer src="../../main.js"></script>
|
||||
<noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></head><body class="rustdoc fn"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"></h2>
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_gui::tools</a></h2><div id="sidebar-vars" data-name="prompt_to_download_missing_data" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../map_gui/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">map_gui</a>::<wbr><a href="index.html">tools</a>::<wbr><a class="fn" href="#">prompt_to_download_missing_data</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/map_gui/tools/updater.rs.html#38-93">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn prompt_to_download_missing_data<A: <a class="trait" href="../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static>(<br> ctx: &mut EventCtx<'_>, <br> map_name: <a class="struct" href="../../abstio/abst_paths/struct.MapName.html" title="struct abstio::abst_paths::MapName">MapName</a><br>) -> Transition<A></code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Prompt to download a missing city. On either success or failure (maybe the player choosing to
|
||||
not download, maybe a network error), the new map isn’t automatically loaded or anything; up to
|
||||
the caller to handle that.</p>
|
||||
</div></details></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">map_gui</a>::<wbr><a href="index.html">tools</a>::<wbr><a class="fn" href="#">prompt_to_download_missing_data</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/map_gui/tools/updater.rs.html#36-93">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn prompt_to_download_missing_data<A: <a class="trait" href="../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static>(<br> ctx: &mut EventCtx<'_>, <br> map_name: <a class="struct" href="../../abstio/abst_paths/struct.MapName.html" title="struct abstio::abst_paths::MapName">MapName</a>, <br> on_load: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>><br>) -> Transition<A></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -40,10 +40,7 @@ and a button to change maps. Callers must handle the <code>change map</code> and
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.goal_marker.html" title="map_gui::tools::goal_marker fn">goal_marker</a></div><div class="item-right docblock-short"><p>Draw a goal marker pointing at something.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.grey_out_map.html" title="map_gui::tools::grey_out_map fn">grey_out_map</a></div><div class="item-right docblock-short"><p>Make it clear the map can’t be interacted with right now.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.home_btn.html" title="map_gui::tools::home_btn fn">home_btn</a></div><div class="item-right docblock-short"><p>A button to return to the title screen</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.intersections_from_roads.html" title="map_gui::tools::intersections_from_roads fn">intersections_from_roads</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.loading_tips.html" title="map_gui::tools::loading_tips fn">loading_tips</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.make_heatmap.html" title="map_gui::tools::make_heatmap fn">make_heatmap</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.nice_country_name.html" title="map_gui::tools::nice_country_name fn">nice_country_name</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.nice_map_name.html" title="map_gui::tools::nice_map_name fn">nice_map_name</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.percentage_bar.html" title="map_gui::tools::percentage_bar fn">percentage_bar</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.prompt_to_download_missing_data.html" title="map_gui::tools::prompt_to_download_missing_data fn">prompt_to_download_missing_data</a></div><div class="item-right docblock-short"><p>Prompt to download a missing city. On either success or failure (maybe the player choosing to
|
||||
not download, maybe a network error), the new map isn’t automatically loaded or anything; up to
|
||||
the caller to handle that.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.start_marker.html" title="map_gui::tools::start_marker fn">start_marker</a></div><div class="item-right docblock-short"><p>Draw a start marker pointing at something.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.intersections_from_roads.html" title="map_gui::tools::intersections_from_roads fn">intersections_from_roads</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.loading_tips.html" title="map_gui::tools::loading_tips fn">loading_tips</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.make_heatmap.html" title="map_gui::tools::make_heatmap fn">make_heatmap</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.nice_country_name.html" title="map_gui::tools::nice_country_name fn">nice_country_name</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.nice_map_name.html" title="map_gui::tools::nice_map_name fn">nice_map_name</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.percentage_bar.html" title="map_gui::tools::percentage_bar fn">percentage_bar</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.prompt_to_download_missing_data.html" title="map_gui::tools::prompt_to_download_missing_data fn">prompt_to_download_missing_data</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.start_marker.html" title="map_gui::tools::start_marker fn">start_marker</a></div><div class="item-right docblock-short"><p>Draw a start marker pointing at something.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.update_url_map_name.html" title="map_gui::tools::update_url_map_name fn">update_url_map_name</a></div><div class="item-right docblock-short"><p>Modify the current URL to set the first free parameter to the current map name.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.version.html" title="map_gui::tools::version fn">version</a></div><div class="item-right docblock-short"><p>Returns the version of A/B Street to link to. When building for a release, this points to that
|
||||
new release. Otherwise it points to the current dev version.</p>
|
||||
|
@ -1 +1 @@
|
||||
initSidebarItems({"constant":[["NEXT_RELEASE",""]],"enum":[["Executable",""]],"fn":[["app_header","A standard way to group a home button back to the title screen, the title of the current app, and a button to change maps. Callers must handle the `change map` and `home` click events."],["change_map_btn","A button to change maps, with default keybindings"],["checkbox_per_mode",""],["cmp_count","Less is better"],["cmp_dist","Shorter is better"],["cmp_duration","Shorter is better"],["color_for_mode",""],["draw_isochrone","Thresholds are Durations, in units of seconds"],["draw_overlapping_paths",""],["find_exe","Returns the path to an executable. Native-only."],["goal_marker","Draw a goal marker pointing at something."],["grey_out_map","Make it clear the map can’t be interacted with right now."],["home_btn","A button to return to the title screen"],["intersections_from_roads",""],["loading_tips",""],["make_heatmap",""],["nice_country_name",""],["nice_map_name",""],["percentage_bar",""],["prompt_to_download_missing_data","Prompt to download a missing city. On either success or failure (maybe the player choosing to not download, maybe a network error), the new map isn’t automatically loaded or anything; up to the caller to handle that."],["start_marker","Draw a start marker pointing at something."],["update_url_map_name","Modify the current URL to set the first free parameter to the current map name."],["version","Returns the version of A/B Street to link to. When building for a release, this points to that new release. Otherwise it points to the current dev version."]],"mod":[["camera",""],["city_picker",""],["colors",""],["command",""],["compare_counts",""],["draw_overlapping_paths",""],["heatmap",""],["icons",""],["importer",""],["labels",""],["minimap",""],["navigate",""],["polygon",""],["title_screen",""],["trip_files",""],["turn_explorer",""],["ui","Generic UI tools. Some of this should perhaps be lifted to widgetry."],["updater",""],["waypoints",""]],"struct":[["CameraState","Represents the state of a widgetry Canvas."],["ChooseSomething","Choose something from a menu, then feed the answer to a callback."],["CityPicker","Lets the player switch maps."],["ColorDiscrete",""],["ColorLegend",""],["ColorNetwork",""],["ColorScale",""],["DefaultMap","Track the last map used, to resume next session."],["DivergingScale",""],["DrawRoadLabels","Labels roads when unzoomed. Label size and frequency depends on the zoom level."],["EditPolygon",""],["FilePicker",""],["Grid","A 2D grid containing some arbitrary data."],["HeatmapOptions",""],["InputWaypoints","Click to add waypoints, drag them, see the list on a panel and delete them. The caller owns the Panel and the World, since there’s probably more stuff there too."],["Minimap",""],["Navigator",""],["PromptInput","Prompt for arbitrary text input, then feed the answer to a callback."],["RunCommand","Executes a command and displays STDOUT and STDERR in a loading screen window. Only works on native, of course."],["TitleScreen","A title screen shared among all of the A/B Street apps."],["TripManagement","Save sequences of waypoints as named trips. Basic file management – save, load, browse. This is useful to define “test cases,” then edit the bike network and “run the tests” to compare results."],["TurnExplorer","A tool to explore all of the turns from a single lane."],["WaypointID",""]],"trait":[["MinimapControls","Customize the appearance and behavior of a minimap."],["TripManagementState",""]]});
|
||||
initSidebarItems({"constant":[["NEXT_RELEASE",""]],"enum":[["Executable",""]],"fn":[["app_header","A standard way to group a home button back to the title screen, the title of the current app, and a button to change maps. Callers must handle the `change map` and `home` click events."],["change_map_btn","A button to change maps, with default keybindings"],["checkbox_per_mode",""],["cmp_count","Less is better"],["cmp_dist","Shorter is better"],["cmp_duration","Shorter is better"],["color_for_mode",""],["draw_isochrone","Thresholds are Durations, in units of seconds"],["draw_overlapping_paths",""],["find_exe","Returns the path to an executable. Native-only."],["goal_marker","Draw a goal marker pointing at something."],["grey_out_map","Make it clear the map can’t be interacted with right now."],["home_btn","A button to return to the title screen"],["intersections_from_roads",""],["loading_tips",""],["make_heatmap",""],["nice_country_name",""],["nice_map_name",""],["percentage_bar",""],["prompt_to_download_missing_data",""],["start_marker","Draw a start marker pointing at something."],["update_url_map_name","Modify the current URL to set the first free parameter to the current map name."],["version","Returns the version of A/B Street to link to. When building for a release, this points to that new release. Otherwise it points to the current dev version."]],"mod":[["camera",""],["city_picker",""],["colors",""],["command",""],["compare_counts",""],["draw_overlapping_paths",""],["heatmap",""],["icons",""],["importer",""],["labels",""],["minimap",""],["navigate",""],["polygon",""],["title_screen",""],["trip_files",""],["turn_explorer",""],["ui","Generic UI tools. Some of this should perhaps be lifted to widgetry."],["updater",""],["waypoints",""]],"struct":[["CameraState","Represents the state of a widgetry Canvas."],["ChooseSomething","Choose something from a menu, then feed the answer to a callback."],["CityPicker","Lets the player switch maps."],["ColorDiscrete",""],["ColorLegend",""],["ColorNetwork",""],["ColorScale",""],["DefaultMap","Track the last map used, to resume next session."],["DivergingScale",""],["DrawRoadLabels","Labels roads when unzoomed. Label size and frequency depends on the zoom level."],["EditPolygon",""],["FilePicker",""],["Grid","A 2D grid containing some arbitrary data."],["HeatmapOptions",""],["InputWaypoints","Click to add waypoints, drag them, see the list on a panel and delete them. The caller owns the Panel and the World, since there’s probably more stuff there too."],["Minimap",""],["Navigator",""],["PromptInput","Prompt for arbitrary text input, then feed the answer to a callback."],["RunCommand","Executes a command and displays STDOUT and STDERR in a loading screen window. Only works on native, of course."],["TitleScreen","A title screen shared among all of the A/B Street apps."],["TripManagement","Save sequences of waypoints as named trips. Basic file management – save, load, browse. This is useful to define “test cases,” then edit the bike network and “run the tests” to compare results."],["TurnExplorer","A tool to explore all of the turns from a single lane."],["WaypointID",""]],"trait":[["MinimapControls","Customize the appearance and behavior of a minimap."],["TripManagementState",""]]});
|
File diff suppressed because one or more lines are too long
@ -4,6 +4,6 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_gui::tools::title_screen::built_info</a></h2><div id="sidebar-vars" data-name="BUILT_TIME_UTC" data-ty="constant" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../../map_gui/index.html"><img class="rust-logo" src="../../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Constant <a href="../../../index.html">map_gui</a>::<wbr><a href="../../index.html">tools</a>::<wbr><a href="../index.html">title_screen</a>::<wbr><a href="index.html">built_info</a>::<wbr><a class="constant" href="#">BUILT_TIME_UTC</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../../src/map_gui/home/runner/work/abstreet/abstreet/target/debug/build/map_gui-ed50344f6d8f69b9/out/built.rs.html#78">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust const"><code>pub const BUILT_TIME_UTC: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a> = r"Tue, 14 Jun 2022 17:32:12 +0000";</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>The build time in RFC2822, UTC.</p>
|
||||
<h1 class="fqn"><span class="in-band">Constant <a href="../../../index.html">map_gui</a>::<wbr><a href="../../index.html">tools</a>::<wbr><a href="../index.html">title_screen</a>::<wbr><a href="index.html">built_info</a>::<wbr><a class="constant" href="#">BUILT_TIME_UTC</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../../src/map_gui/home/runner/work/abstreet/abstreet/target/debug/build/map_gui-ed50344f6d8f69b9/out/built.rs.html#78">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust const"><code>pub const BUILT_TIME_UTC: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a> = r"Mon, 20 Jun 2022 10:39:25 +0000";</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>The build time in RFC2822, UTC.</p>
|
||||
</div></details></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,5 +4,5 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_gui::tools::updater</a></h2><div id="sidebar-vars" data-name="download_cities" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">updater</a>::<wbr><a class="fn" href="#">download_cities</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/updater.rs.html#95-155">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>async fn download_cities(<br> cities: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/vec/struct.Vec.html" title="struct alloc::vec::Vec">Vec</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>>, <br> outer_progress: Sender<<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>>, <br> inner_progress: Sender<<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>><br>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/vec/struct.Vec.html" title="struct alloc::vec::Vec">Vec</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">updater</a>::<wbr><a class="fn" href="#">download_cities</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/updater.rs.html#95-157">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>async fn download_cities(<br> cities: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/vec/struct.Vec.html" title="struct alloc::vec::Vec">Vec</a><<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>>, <br> outer_progress: Sender<<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>>, <br> inner_progress: Sender<<a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>><br>) -> <a class="type" href="https://docs.rs/anyhow/1.0.41/anyhow/type.Result.html" title="type anyhow::Result">Result</a><<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.unit.html">()</a>></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -1,11 +1,8 @@
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Prompt to download a missing city. On either success or failure (maybe the player choosing to not download, maybe a network error), the new map isn’t automatically loaded or anything; up to the caller to handle that."><meta name="keywords" content="rust, rustlang, rust-lang, prompt_to_download_missing_data"><title>prompt_to_download_missing_data in map_gui::tools::updater - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../../normalize.css"><link rel="stylesheet" type="text/css" href="../../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../../storage.js"></script><script src="../../../crates.js"></script><script defer src="../../../main.js"></script>
|
||||
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="API documentation for the Rust `prompt_to_download_missing_data` fn in crate `map_gui`."><meta name="keywords" content="rust, rustlang, rust-lang, prompt_to_download_missing_data"><title>prompt_to_download_missing_data in map_gui::tools::updater - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" type="text/css" href="../../../normalize.css"><link rel="stylesheet" type="text/css" href="../../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../../ayu.css" disabled><link rel="stylesheet" type="text/css" href="../../../dark.css" disabled><link rel="stylesheet" type="text/css" href="../../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../../storage.js"></script><script src="../../../crates.js"></script><script defer src="../../../main.js"></script>
|
||||
<noscript><link rel="stylesheet" href="../../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../../favicon.svg"></head><body class="rustdoc fn"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">☰</button><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"></h2>
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_gui::tools::updater</a></h2><div id="sidebar-vars" data-name="prompt_to_download_missing_data" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">updater</a>::<wbr><a class="fn" href="#">prompt_to_download_missing_data</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/updater.rs.html#38-93">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn prompt_to_download_missing_data<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static>(<br> ctx: &mut EventCtx<'_>, <br> map_name: <a class="struct" href="../../../abstio/abst_paths/struct.MapName.html" title="struct abstio::abst_paths::MapName">MapName</a><br>) -> Transition<A></code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Prompt to download a missing city. On either success or failure (maybe the player choosing to
|
||||
not download, maybe a network error), the new map isn’t automatically loaded or anything; up to
|
||||
the caller to handle that.</p>
|
||||
</div></details></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">updater</a>::<wbr><a class="fn" href="#">prompt_to_download_missing_data</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/updater.rs.html#36-93">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn prompt_to_download_missing_data<A: <a class="trait" href="../../trait.AppLike.html" title="trait map_gui::AppLike">AppLike</a> + 'static>(<br> ctx: &mut EventCtx<'_>, <br> map_name: <a class="struct" href="../../../abstio/abst_paths/struct.MapName.html" title="struct abstio::abst_paths::MapName">MapName</a>, <br> on_load: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="https://doc.rust-lang.org/1.61.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(&mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A) -> Transition<A>><br>) -> Transition<A></code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,6 +4,6 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_gui::tools::updater</a></h2><div id="sidebar-vars" data-name="size_of_city" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">updater</a>::<wbr><a class="fn" href="#">size_of_city</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/updater.rs.html#17-33">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn size_of_city(map: &<a class="struct" href="../../../abstio/abst_paths/struct.MapName.html" title="struct abstio::abst_paths::MapName">MapName</a>) -> <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.u64.html">u64</a></code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>How many bytes to download for a city?</p>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a href="index.html">updater</a>::<wbr><a class="fn" href="#">size_of_city</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/updater.rs.html#18-34">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn size_of_city(map: &<a class="struct" href="../../../abstio/abst_paths/struct.MapName.html" title="struct abstio::abst_paths::MapName">MapName</a>) -> <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.u64.html">u64</a></code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>How many bytes to download for a city?</p>
|
||||
</div></details></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,10 +4,7 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../../map_gui/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"><a href="#">Module updater</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#functions">Functions</a></li></ul></div></section><div id="sidebar-vars" data-name="updater" data-ty="mod" data-relpath="./"></div><script defer src="./sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_gui/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a class="mod" href="#">updater</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/updater.rs.html#1-155">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="functions" class="small-section-header"><a href="#functions">Functions</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.download_cities.html" title="map_gui::tools::updater::download_cities fn">download_cities</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.prompt_to_download_missing_data.html" title="map_gui::tools::updater::prompt_to_download_missing_data fn">prompt_to_download_missing_data</a></div><div class="item-right docblock-short"><p>Prompt to download a missing city. On either success or failure (maybe the player choosing to
|
||||
not download, maybe a network error), the new map isn’t automatically loaded or anything; up to
|
||||
the caller to handle that.</p>
|
||||
</div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.size_of_city.html" title="map_gui::tools::updater::size_of_city fn">size_of_city</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"><p>How many bytes to download for a city?</p>
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../../index.html">map_gui</a>::<wbr><a href="../index.html">tools</a>::<wbr><a class="mod" href="#">updater</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_gui/tools/updater.rs.html#1-157">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="functions" class="small-section-header"><a href="#functions">Functions</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.download_cities.html" title="map_gui::tools::updater::download_cities fn">download_cities</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.prompt_to_download_missing_data.html" title="map_gui::tools::updater::prompt_to_download_missing_data fn">prompt_to_download_missing_data</a></div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.size_of_city.html" title="map_gui::tools::updater::size_of_city fn">size_of_city</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"><p>How many bytes to download for a city?</p>
|
||||
</div></div></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -1 +1 @@
|
||||
initSidebarItems({"fn":[["download_cities",""],["prompt_to_download_missing_data","Prompt to download a missing city. On either success or failure (maybe the player choosing to not download, maybe a network error), the new map isn’t automatically loaded or anything; up to the caller to handle that."],["size_of_city","How many bytes to download for a city?"]]});
|
||||
initSidebarItems({"fn":[["download_cities",""],["prompt_to_download_missing_data",""],["size_of_city","How many bytes to download for a city?"]]});
|
@ -4,5 +4,5 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../santa/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In santa::title</a></h2><div id="sidebar-vars" data-name="level_btn" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../santa/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="fn" href="#">level_btn</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#117-137">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn level_btn(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> level: &<a class="struct" href="../levels/struct.Level.html" title="struct santa::levels::Level">Level</a>, <br> idx: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.usize.html">usize</a><br>) -> GeomBatch</code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="santa" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="fn" href="#">level_btn</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#124-144">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn level_btn(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> level: &<a class="struct" href="../levels/struct.Level.html" title="struct santa::levels::Level">Level</a>, <br> idx: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.usize.html">usize</a><br>) -> GeomBatch</code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="santa" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,5 +4,5 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../santa/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In santa::title</a></h2><div id="sidebar-vars" data-name="link" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../santa/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="fn" href="#">link</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#200-205">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn link(ctx: &mut EventCtx<'_>, label: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>, url: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>) -> Widget</code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="santa" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="fn" href="#">link</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#207-212">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn link(ctx: &mut EventCtx<'_>, label: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>, url: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>) -> Widget</code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="santa" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,5 +4,5 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../santa/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In santa::title</a></h2><div id="sidebar-vars" data-name="locked_level" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../santa/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="fn" href="#">locked_level</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#140-147">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn locked_level(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> level: &<a class="struct" href="../levels/struct.Level.html" title="struct santa::levels::Level">Level</a>, <br> idx: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.usize.html">usize</a><br>) -> Widget</code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="santa" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="fn" href="#">locked_level</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#147-154">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn locked_level(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> level: &<a class="struct" href="../levels/struct.Level.html" title="struct santa::levels::Level">Level</a>, <br> idx: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.usize.html">usize</a><br>) -> Widget</code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="santa" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,5 +4,5 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../santa/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In santa::title</a></h2><div id="sidebar-vars" data-name="unlocked_level" data-ty="fn" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../santa/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="fn" href="#">unlocked_level</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#149-159">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn unlocked_level(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> level: &<a class="struct" href="../levels/struct.Level.html" title="struct santa::levels::Level">Level</a>, <br> idx: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.usize.html">usize</a><br>) -> Widget</code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="santa" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="fn" href="#">unlocked_level</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#156-166">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn unlocked_level(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> level: &<a class="struct" href="../levels/struct.Level.html" title="struct santa::levels::Level">Level</a>, <br> idx: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.usize.html">usize</a><br>) -> Widget</code></pre></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="santa" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,7 +4,7 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../santa/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"><a href="#">Module title</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#structs">Structs</a></li><li><a href="#functions">Functions</a></li></ul></div></section><div id="sidebar-vars" data-name="title" data-ty="mod" data-relpath="./"></div><script defer src="./sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../santa/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../index.html">santa</a>::<wbr><a class="mod" href="#">title</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#1-230">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2>
|
||||
<h1 class="fqn"><span class="in-band">Module <a href="../index.html">santa</a>::<wbr><a class="mod" href="#">title</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#1-237">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.Credits.html" title="santa::title::Credits struct">Credits</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.TitleScreen.html" title="santa::title::TitleScreen struct">TitleScreen</a></div><div class="item-right docblock-short"></div></div></div><h2 id="functions" class="small-section-header"><a href="#functions">Functions</a></h2>
|
||||
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.level_btn.html" title="santa::title::level_btn fn">level_btn</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.link.html" title="santa::title::link fn">link</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.locked_level.html" title="santa::title::locked_level fn">locked_level</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div><div class="item-row"><div class="item-left module-item"><a class="fn" href="fn.unlocked_level.html" title="santa::title::unlocked_level fn">unlocked_level</a><span title="Restricted Visibility"> 🔒</span> </div><div class="item-right docblock-short"></div></div></div></section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="santa" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
</body></html>
|
@ -4,11 +4,11 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../santa/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"><a href="#">Credits</a></h2><div class="sidebar-elems"><section><div class="block"><h3 class="sidebar-title"><a href="#implementations">Methods</a></h3><ul><li><a href="#method.new_state">new_state</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#trait-implementations">Trait Implementations</a></h3><ul><li><a href="#impl-SimpleState%3CSimpleApp%3CSession%3E%3E">SimpleState<SimpleApp<Session>></a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#synthetic-implementations">Auto Trait Implementations</a></h3><ul><li><a href="#impl-RefUnwindSafe">RefUnwindSafe</a></li><li><a href="#impl-Send">Send</a></li><li><a href="#impl-Sync">Sync</a></li><li><a href="#impl-Unpin">Unpin</a></li><li><a href="#impl-UnwindSafe">UnwindSafe</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#blanket-implementations">Blanket Implementations</a></h3><ul><li><a href="#impl-Any">Any</a></li><li><a href="#impl-Borrow%3CT%3E">Borrow<T></a></li><li><a href="#impl-BorrowMut%3CT%3E">BorrowMut<T></a></li><li><a href="#impl-Downcast">Downcast</a></li><li><a href="#impl-DowncastSync">DowncastSync</a></li><li><a href="#impl-From%3CT%3E">From<T></a></li><li><a href="#impl-Instrument">Instrument</a></li><li><a href="#impl-Into%3CU%3E">Into<U></a></li><li><a href="#impl-Same%3CT%3E">Same<T></a></li><li><a href="#impl-TryFrom%3CU%3E">TryFrom<U></a></li><li><a href="#impl-TryInto%3CU%3E">TryInto<U></a></li><li><a href="#impl-VZip%3CV%3E">VZip<V></a></li></ul></div></section><h2 class="location"><a href="index.html">In santa::title</a></h2><div id="sidebar-vars" data-name="Credits" data-ty="struct" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../santa/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Struct <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="struct" href="#">Credits</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#161">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust struct"><code>struct Credits;</code></pre></div><h2 id="implementations" class="small-section-header">Implementations<a href="#implementations" class="anchor"></a></h2><div id="implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#163-198">source</a></span><a href="#impl" class="anchor"></a><h3 class="code-header in-band">impl <a class="struct" href="struct.Credits.html" title="struct santa::title::Credits">Credits</a></h3></section></summary><div class="impl-items"><section id="method.new_state" class="method has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#164-197">source</a></span><a href="#method.new_state" class="anchor"></a><h4 class="code-header">fn <a href="#method.new_state" class="fnname">new_state</a>(ctx: &mut EventCtx<'_>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>>></h4></section></div></details></div><h2 id="trait-implementations" class="small-section-header">Trait Implementations<a href="#trait-implementations" class="anchor"></a></h2><div id="trait-implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-SimpleState%3CSimpleApp%3CSession%3E%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#207-230">source</a></span><a href="#impl-SimpleState%3CSimpleApp%3CSession%3E%3E" class="anchor"></a><h3 class="code-header in-band">impl SimpleState<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>> for <a class="struct" href="struct.Credits.html" title="struct santa::title::Credits">Credits</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#208-220">source</a></span><a href="#method.on_click" class="anchor"></a><h4 class="code-header">fn <a class="fnname">on_click</a>(<br> &mut self, <br> _: &mut EventCtx<'_>, <br> _: &mut <a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> x: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>, <br> _: &mut Panel<br>) -> Transition<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked. Since the action is just a string,
|
||||
<h1 class="fqn"><span class="in-band">Struct <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="struct" href="#">Credits</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#168">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust struct"><code>struct Credits;</code></pre></div><h2 id="implementations" class="small-section-header">Implementations<a href="#implementations" class="anchor"></a></h2><div id="implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#170-205">source</a></span><a href="#impl" class="anchor"></a><h3 class="code-header in-band">impl <a class="struct" href="struct.Credits.html" title="struct santa::title::Credits">Credits</a></h3></section></summary><div class="impl-items"><section id="method.new_state" class="method has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#171-204">source</a></span><a href="#method.new_state" class="anchor"></a><h4 class="code-header">fn <a href="#method.new_state" class="fnname">new_state</a>(ctx: &mut EventCtx<'_>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>>></h4></section></div></details></div><h2 id="trait-implementations" class="small-section-header">Trait Implementations<a href="#trait-implementations" class="anchor"></a></h2><div id="trait-implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-SimpleState%3CSimpleApp%3CSession%3E%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#214-237">source</a></span><a href="#impl-SimpleState%3CSimpleApp%3CSession%3E%3E" class="anchor"></a><h3 class="code-header in-band">impl SimpleState<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>> for <a class="struct" href="struct.Credits.html" title="struct santa::title::Credits">Credits</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#215-227">source</a></span><a href="#method.on_click" class="anchor"></a><h4 class="code-header">fn <a class="fnname">on_click</a>(<br> &mut self, <br> _: &mut EventCtx<'_>, <br> _: &mut <a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> x: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>, <br> _: &mut Panel<br>) -> Transition<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked. Since the action is just a string,
|
||||
the fallback case can just use <code>unreachable!()</code>. <a href="#tymethod.on_click">Read more</a></p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.other_event" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#222-225">source</a></span><a href="#method.other_event" class="anchor"></a><h4 class="code-header">fn <a href="#method.other_event" class="fnname">other_event</a>(<br> &mut self, <br> ctx: &mut EventCtx<'_>, <br> app: &mut <a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>><br>) -> Transition<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>></h4></section></summary><div class='docblock'><p>If a panel <code>on_click</code> event didn’t occur and <code>panel_changed</code> didn’t return transition, then
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.other_event" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#229-232">source</a></span><a href="#method.other_event" class="anchor"></a><h4 class="code-header">fn <a href="#method.other_event" class="fnname">other_event</a>(<br> &mut self, <br> ctx: &mut EventCtx<'_>, <br> app: &mut <a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>><br>) -> Transition<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>></h4></section></summary><div class='docblock'><p>If a panel <code>on_click</code> event didn’t occur and <code>panel_changed</code> didn’t return transition, then
|
||||
call this to handle all other events. <a href="#method.other_event">Read more</a></p>
|
||||
</div></details><section id="method.draw" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#227-229">source</a></span><a href="#method.draw" class="anchor"></a><h4 class="code-header">fn <a href="#method.draw" class="fnname">draw</a>(&self, g: &mut GfxCtx<'_>, app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>)</h4></section><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click_custom" class="method trait-impl has-srclink"><a href="#method.on_click_custom" class="anchor"></a><h4 class="code-header">fn <a href="#method.on_click_custom" class="fnname">on_click_custom</a>(<br> &mut self, <br> _ctx: &mut EventCtx<'_>, <br> _app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> _action: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="../../abstutil/clone/trait.CloneableAny.html" title="trait abstutil::clone::CloneableAny">CloneableAny</a> + 'static, <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/alloc/struct.Global.html" title="struct alloc::alloc::Global">Global</a>>, <br> _panel: &mut Panel<br>) -> Transition<A></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked.</p>
|
||||
</div></details><section id="method.draw" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#234-236">source</a></span><a href="#method.draw" class="anchor"></a><h4 class="code-header">fn <a href="#method.draw" class="fnname">draw</a>(&self, g: &mut GfxCtx<'_>, app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>)</h4></section><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click_custom" class="method trait-impl has-srclink"><a href="#method.on_click_custom" class="anchor"></a><h4 class="code-header">fn <a href="#method.on_click_custom" class="fnname">on_click_custom</a>(<br> &mut self, <br> _ctx: &mut EventCtx<'_>, <br> _app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> _action: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="../../abstutil/clone/trait.CloneableAny.html" title="trait abstutil::clone::CloneableAny">CloneableAny</a> + 'static, <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/alloc/struct.Global.html" title="struct alloc::alloc::Global">Global</a>>, <br> _panel: &mut Panel<br>) -> Transition<A></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked.</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.panel_changed" class="method trait-impl has-srclink"><a href="#method.panel_changed" class="anchor"></a><h4 class="code-header">fn <a href="#method.panel_changed" class="fnname">panel_changed</a>(<br> &mut self, <br> &mut EventCtx<'_>, <br> <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> &mut Panel<br>) -> <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><Transition<A>></h4></section></summary><div class='docblock'><p>Called when something on the panel has changed. If a transition is returned, stop handling
|
||||
the event and immediately apply the transition. <a href="#method.panel_changed">Read more</a></p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_mouseover" class="method trait-impl has-srclink"><a href="#method.on_mouseover" class="anchor"></a><h4 class="code-header">fn <a href="#method.on_mouseover" class="fnname">on_mouseover</a>(&mut self, &mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A)</h4></section></summary><div class='docblock'><p>Called when the mouse has moved.</p>
|
||||
|
@ -4,11 +4,11 @@
|
||||
</nav>
|
||||
<nav class="sidebar"><a class="sidebar-logo" href="../../santa/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div>
|
||||
</a><h2 class="location"><a href="#">TitleScreen</a></h2><div class="sidebar-elems"><section><div class="block"><h3 class="sidebar-title"><a href="#implementations">Methods</a></h3><ul><li><a href="#method.new_state">new_state</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#trait-implementations">Trait Implementations</a></h3><ul><li><a href="#impl-SimpleState%3CSimpleApp%3CSession%3E%3E">SimpleState<SimpleApp<Session>></a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#synthetic-implementations">Auto Trait Implementations</a></h3><ul><li><a href="#impl-RefUnwindSafe">RefUnwindSafe</a></li><li><a href="#impl-Send">Send</a></li><li><a href="#impl-Sync">Sync</a></li><li><a href="#impl-Unpin">Unpin</a></li><li><a href="#impl-UnwindSafe">UnwindSafe</a></li></ul></div><div class="block"><h3 class="sidebar-title"><a href="#blanket-implementations">Blanket Implementations</a></h3><ul><li><a href="#impl-Any">Any</a></li><li><a href="#impl-Borrow%3CT%3E">Borrow<T></a></li><li><a href="#impl-BorrowMut%3CT%3E">BorrowMut<T></a></li><li><a href="#impl-Downcast">Downcast</a></li><li><a href="#impl-DowncastSync">DowncastSync</a></li><li><a href="#impl-From%3CT%3E">From<T></a></li><li><a href="#impl-Instrument">Instrument</a></li><li><a href="#impl-Into%3CU%3E">Into<U></a></li><li><a href="#impl-Same%3CT%3E">Same<T></a></li><li><a href="#impl-TryFrom%3CU%3E">TryFrom<U></a></li><li><a href="#impl-TryInto%3CU%3E">TryInto<U></a></li><li><a href="#impl-VZip%3CV%3E">VZip<V></a></li></ul></div></section><h2 class="location"><a href="index.html">In santa::title</a></h2><div id="sidebar-vars" data-name="TitleScreen" data-ty="struct" data-relpath=""></div><script defer src="sidebar-items.js"></script></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../santa/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><div class="theme-picker hidden"><button id="theme-picker" aria-label="Pick another theme!" aria-haspopup="menu" title="themes"><img width="22" height="22" alt="Pick another theme!" src="../../brush.svg"></button><div id="theme-choices" role="menu"></div></div><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><button type="button" id="help-button" title="help">?</button><a id="settings-menu" href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
|
||||
<h1 class="fqn"><span class="in-band">Struct <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="struct" href="#">TitleScreen</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#11">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust struct"><code>pub struct TitleScreen;</code></pre></div><h2 id="implementations" class="small-section-header">Implementations<a href="#implementations" class="anchor"></a></h2><div id="implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#13-69">source</a></span><a href="#impl" class="anchor"></a><h3 class="code-header in-band">impl <a class="struct" href="struct.TitleScreen.html" title="struct santa::title::TitleScreen">TitleScreen</a></h3></section></summary><div class="impl-items"><section id="method.new_state" class="method has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#14-68">source</a></span><a href="#method.new_state" class="anchor"></a><h4 class="code-header">pub fn <a href="#method.new_state" class="fnname">new_state</a>(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>><br>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>>></h4></section></div></details></div><h2 id="trait-implementations" class="small-section-header">Trait Implementations<a href="#trait-implementations" class="anchor"></a></h2><div id="trait-implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-SimpleState%3CSimpleApp%3CSession%3E%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#71-115">source</a></span><a href="#impl-SimpleState%3CSimpleApp%3CSession%3E%3E" class="anchor"></a><h3 class="code-header in-band">impl SimpleState<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>> for <a class="struct" href="struct.TitleScreen.html" title="struct santa::title::TitleScreen">TitleScreen</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#72-105">source</a></span><a href="#method.on_click" class="anchor"></a><h4 class="code-header">fn <a class="fnname">on_click</a>(<br> &mut self, <br> ctx: &mut EventCtx<'_>, <br> app: &mut <a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> x: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>, <br> _: &mut Panel<br>) -> Transition<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked. Since the action is just a string,
|
||||
<h1 class="fqn"><span class="in-band">Struct <a href="../index.html">santa</a>::<wbr><a href="index.html">title</a>::<wbr><a class="struct" href="#">TitleScreen</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/santa/title.rs.html#11">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">−</span>]</a></span></div><div class="docblock item-decl"><pre class="rust struct"><code>pub struct TitleScreen;</code></pre></div><h2 id="implementations" class="small-section-header">Implementations<a href="#implementations" class="anchor"></a></h2><div id="implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#13-69">source</a></span><a href="#impl" class="anchor"></a><h3 class="code-header in-band">impl <a class="struct" href="struct.TitleScreen.html" title="struct santa::title::TitleScreen">TitleScreen</a></h3></section></summary><div class="impl-items"><section id="method.new_state" class="method has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#14-68">source</a></span><a href="#method.new_state" class="anchor"></a><h4 class="code-header">pub fn <a href="#method.new_state" class="fnname">new_state</a>(<br> ctx: &mut EventCtx<'_>, <br> app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>><br>) -> <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn State<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>>></h4></section></div></details></div><h2 id="trait-implementations" class="small-section-header">Trait Implementations<a href="#trait-implementations" class="anchor"></a></h2><div id="trait-implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-SimpleState%3CSimpleApp%3CSession%3E%3E" class="impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#71-122">source</a></span><a href="#impl-SimpleState%3CSimpleApp%3CSession%3E%3E" class="anchor"></a><h3 class="code-header in-band">impl SimpleState<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>> for <a class="struct" href="struct.TitleScreen.html" title="struct santa::title::TitleScreen">TitleScreen</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#72-112">source</a></span><a href="#method.on_click" class="anchor"></a><h4 class="code-header">fn <a class="fnname">on_click</a>(<br> &mut self, <br> ctx: &mut EventCtx<'_>, <br> app: &mut <a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>, <br> x: &<a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.str.html">str</a>, <br> _: &mut Panel<br>) -> Transition<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked. Since the action is just a string,
|
||||
the fallback case can just use <code>unreachable!()</code>. <a href="#tymethod.on_click">Read more</a></p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.other_event" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#107-110">source</a></span><a href="#method.other_event" class="anchor"></a><h4 class="code-header">fn <a href="#method.other_event" class="fnname">other_event</a>(<br> &mut self, <br> ctx: &mut EventCtx<'_>, <br> app: &mut <a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>><br>) -> Transition<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>></h4></section></summary><div class='docblock'><p>If a panel <code>on_click</code> event didn’t occur and <code>panel_changed</code> didn’t return transition, then
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.other_event" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#114-117">source</a></span><a href="#method.other_event" class="anchor"></a><h4 class="code-header">fn <a href="#method.other_event" class="fnname">other_event</a>(<br> &mut self, <br> ctx: &mut EventCtx<'_>, <br> app: &mut <a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>><br>) -> Transition<<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>></h4></section></summary><div class='docblock'><p>If a panel <code>on_click</code> event didn’t occur and <code>panel_changed</code> didn’t return transition, then
|
||||
call this to handle all other events. <a href="#method.other_event">Read more</a></p>
|
||||
</div></details><section id="method.draw" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#112-114">source</a></span><a href="#method.draw" class="anchor"></a><h4 class="code-header">fn <a href="#method.draw" class="fnname">draw</a>(&self, g: &mut GfxCtx<'_>, app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>)</h4></section><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click_custom" class="method trait-impl has-srclink"><a href="#method.on_click_custom" class="anchor"></a><h4 class="code-header">fn <a href="#method.on_click_custom" class="fnname">on_click_custom</a>(<br> &mut self, <br> _ctx: &mut EventCtx<'_>, <br> _app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> _action: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="../../abstutil/clone/trait.CloneableAny.html" title="trait abstutil::clone::CloneableAny">CloneableAny</a> + 'static, <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/alloc/struct.Global.html" title="struct alloc::alloc::Global">Global</a>>, <br> _panel: &mut Panel<br>) -> Transition<A></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked.</p>
|
||||
</div></details><section id="method.draw" class="method trait-impl has-srclink"><span class="rightside"><a class="srclink" href="../../src/santa/title.rs.html#119-121">source</a></span><a href="#method.draw" class="anchor"></a><h4 class="code-header">fn <a href="#method.draw" class="fnname">draw</a>(&self, g: &mut GfxCtx<'_>, app: &<a class="struct" href="../../map_gui/simple_app/struct.SimpleApp.html" title="struct map_gui::simple_app::SimpleApp">SimpleApp</a><<a class="struct" href="../session/struct.Session.html" title="struct santa::session::Session">Session</a>>)</h4></section><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_click_custom" class="method trait-impl has-srclink"><a href="#method.on_click_custom" class="anchor"></a><h4 class="code-header">fn <a href="#method.on_click_custom" class="fnname">on_click_custom</a>(<br> &mut self, <br> _ctx: &mut EventCtx<'_>, <br> _app: <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> _action: <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a><dyn <a class="trait" href="../../abstutil/clone/trait.CloneableAny.html" title="trait abstutil::clone::CloneableAny">CloneableAny</a> + 'static, <a class="struct" href="https://doc.rust-lang.org/1.61.0/alloc/alloc/struct.Global.html" title="struct alloc::alloc::Global">Global</a>>, <br> _panel: &mut Panel<br>) -> Transition<A></h4></section></summary><div class='docblock'><p>Called when something on the panel has been clicked.</p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.panel_changed" class="method trait-impl has-srclink"><a href="#method.panel_changed" class="anchor"></a><h4 class="code-header">fn <a href="#method.panel_changed" class="fnname">panel_changed</a>(<br> &mut self, <br> &mut EventCtx<'_>, <br> <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A, <br> &mut Panel<br>) -> <a class="enum" href="https://doc.rust-lang.org/1.61.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><Transition<A>></h4></section></summary><div class='docblock'><p>Called when something on the panel has changed. If a transition is returned, stop handling
|
||||
the event and immediately apply the transition. <a href="#method.panel_changed">Read more</a></p>
|
||||
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.on_mouseover" class="method trait-impl has-srclink"><a href="#method.on_mouseover" class="anchor"></a><h4 class="code-header">fn <a href="#method.on_mouseover" class="fnname">on_mouseover</a>(&mut self, &mut EventCtx<'_>, <a class="primitive" href="https://doc.rust-lang.org/1.61.0/std/primitive.reference.html">&mut </a>A)</h4></section></summary><div class='docblock'><p>Called when the mouse has moved.</p>
|
||||
|
File diff suppressed because one or more lines are too long
@ -282,10 +282,24 @@
|
||||
<span id="277">277</span>
|
||||
<span id="278">278</span>
|
||||
<span id="279">279</span>
|
||||
<span id="280">280</span>
|
||||
<span id="281">281</span>
|
||||
<span id="282">282</span>
|
||||
<span id="283">283</span>
|
||||
<span id="284">284</span>
|
||||
<span id="285">285</span>
|
||||
<span id="286">286</span>
|
||||
<span id="287">287</span>
|
||||
<span id="288">288</span>
|
||||
<span id="289">289</span>
|
||||
<span id="290">290</span>
|
||||
<span id="291">291</span>
|
||||
<span id="292">292</span>
|
||||
</pre><pre class="rust"><code><span class="kw">use</span> <span class="ident">std::collections::BTreeMap</span>;
|
||||
|
||||
<span class="kw">use</span> <span class="ident">geom</span>::{<span class="ident">Duration</span>, <span class="ident">Percent</span>};
|
||||
<span class="kw">use</span> <span class="ident">synthpop::OrigPersonID</span>;
|
||||
<span class="kw">use</span> <span class="ident">widgetry::tools::PopupMsg</span>;
|
||||
<span class="kw">use</span> <span class="ident">widgetry</span>::{<span class="ident">EventCtx</span>, <span class="ident">Key</span>, <span class="ident">Line</span>, <span class="ident">Panel</span>, <span class="ident">SimpleState</span>, <span class="ident">State</span>, <span class="ident">Text</span>, <span class="ident">TextExt</span>, <span class="ident">Widget</span>};
|
||||
|
||||
<span class="kw">use</span> <span class="ident"><span class="kw">crate</span>::app::App</span>;
|
||||
@ -541,7 +555,19 @@
|
||||
.<span class="ident">map</span>(<span class="op">|</span><span class="ident">c</span><span class="op">|</span> <span class="ident">c</span>.<span class="ident">gameplay</span>.<span class="ident">map_name</span>())
|
||||
.<span class="ident">unwrap</span>();
|
||||
<span class="kw">if</span> <span class="op">!</span><span class="ident">abstio::file_exists</span>(<span class="ident">map_name</span>.<span class="ident">path</span>()) {
|
||||
<span class="kw">return</span> <span class="ident">map_gui::tools::prompt_to_download_missing_data</span>(<span class="ident">ctx</span>, <span class="ident">map_name</span>);
|
||||
<span class="comment">// Be lazy here and just tell the user what to do, instead of running the</span>
|
||||
<span class="comment">// code below. This is a rare case anyway.</span>
|
||||
<span class="kw">return</span> <span class="ident">map_gui::tools::prompt_to_download_missing_data</span>(
|
||||
<span class="ident">ctx</span>,
|
||||
<span class="ident">map_name</span>,
|
||||
<span class="ident">Box::new</span>(<span class="op">|</span><span class="ident">ctx</span>, <span class="kw">_</span><span class="op">|</span> {
|
||||
<span class="ident">Transition::Replace</span>(<span class="ident">PopupMsg::new_state</span>(
|
||||
<span class="ident">ctx</span>,
|
||||
<span class="string">"Download complete"</span>,
|
||||
<span class="macro">vec!</span>[<span class="string">"Download complete. Click 'Start!' again"</span>],
|
||||
))
|
||||
}),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -183,6 +183,10 @@
|
||||
<span id="178">178</span>
|
||||
<span id="179">179</span>
|
||||
<span id="180">180</span>
|
||||
<span id="181">181</span>
|
||||
<span id="182">182</span>
|
||||
<span id="183">183</span>
|
||||
<span id="184">184</span>
|
||||
</pre><pre class="rust"><code><span class="kw">use</span> <span class="ident">std::collections::HashMap</span>;
|
||||
|
||||
<span class="kw">use</span> <span class="ident">geom::Percent</span>;
|
||||
@ -323,7 +327,11 @@
|
||||
<span class="attribute">#[<span class="ident">cfg</span>(<span class="ident">not</span>(<span class="ident">target_arch</span> <span class="op">=</span> <span class="string">"wasm32"</span>))]</span>
|
||||
{
|
||||
<span class="kw">if</span> <span class="op">!</span><span class="ident">abstio::file_exists</span>(<span class="ident">edits</span>.<span class="ident">map_name</span>.<span class="ident">path</span>()) {
|
||||
<span class="kw">return</span> <span class="ident">map_gui::tools::prompt_to_download_missing_data</span>(<span class="ident">ctx</span>, <span class="ident">edits</span>.<span class="ident">map_name</span>);
|
||||
<span class="kw">return</span> <span class="ident">map_gui::tools::prompt_to_download_missing_data</span>(
|
||||
<span class="ident">ctx</span>,
|
||||
<span class="ident">edits</span>.<span class="ident">map_name</span>.<span class="ident">clone</span>(),
|
||||
<span class="ident">Box::new</span>(<span class="kw">move</span> <span class="op">|</span><span class="ident">ctx</span>, <span class="ident">app</span><span class="op">|</span> <span class="ident">launch</span>(<span class="ident">ctx</span>, <span class="ident">app</span>, <span class="ident">edits</span>)),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -179,7 +179,7 @@
|
||||
<span class="kw">pub</span> <span class="kw">const</span> <span class="ident">RUSTDOC_VERSION</span>: <span class="kw-2">&</span><span class="ident">str</span> <span class="op">=</span> <span class="string">r"rustdoc 1.61.0 (fe5b13d68 2022-05-18)"</span>;
|
||||
<span class="attribute">#[<span class="ident">doc</span><span class="op">=</span><span class="string">r#"The build time in RFC2822, UTC."#</span>]</span>
|
||||
<span class="attribute">#[<span class="ident">allow</span>(<span class="ident">dead_code</span>)]</span>
|
||||
<span class="kw">pub</span> <span class="kw">const</span> <span class="ident">BUILT_TIME_UTC</span>: <span class="kw-2">&</span><span class="ident">str</span> <span class="op">=</span> <span class="string">r"Tue, 14 Jun 2022 17:32:12 +0000"</span>;
|
||||
<span class="kw">pub</span> <span class="kw">const</span> <span class="ident">BUILT_TIME_UTC</span>: <span class="kw-2">&</span><span class="ident">str</span> <span class="op">=</span> <span class="string">r"Mon, 20 Jun 2022 10:39:25 +0000"</span>;
|
||||
<span class="attribute">#[<span class="ident">doc</span><span class="op">=</span><span class="string">r#"The target architecture, given by `CARGO_CFG_TARGET_ARCH`."#</span>]</span>
|
||||
<span class="attribute">#[<span class="ident">allow</span>(<span class="ident">dead_code</span>)]</span>
|
||||
<span class="kw">pub</span> <span class="kw">const</span> <span class="ident">CFG_TARGET_ARCH</span>: <span class="kw-2">&</span><span class="ident">str</span> <span class="op">=</span> <span class="string">r"x86_64"</span>;
|
||||
|
@ -580,6 +580,30 @@
|
||||
<span id="575">575</span>
|
||||
<span id="576">576</span>
|
||||
<span id="577">577</span>
|
||||
<span id="578">578</span>
|
||||
<span id="579">579</span>
|
||||
<span id="580">580</span>
|
||||
<span id="581">581</span>
|
||||
<span id="582">582</span>
|
||||
<span id="583">583</span>
|
||||
<span id="584">584</span>
|
||||
<span id="585">585</span>
|
||||
<span id="586">586</span>
|
||||
<span id="587">587</span>
|
||||
<span id="588">588</span>
|
||||
<span id="589">589</span>
|
||||
<span id="590">590</span>
|
||||
<span id="591">591</span>
|
||||
<span id="592">592</span>
|
||||
<span id="593">593</span>
|
||||
<span id="594">594</span>
|
||||
<span id="595">595</span>
|
||||
<span id="596">596</span>
|
||||
<span id="597">597</span>
|
||||
<span id="598">598</span>
|
||||
<span id="599">599</span>
|
||||
<span id="600">600</span>
|
||||
<span id="601">601</span>
|
||||
</pre><pre class="rust"><code><span class="kw">use</span> <span class="ident">std::collections::BTreeMap</span>;
|
||||
|
||||
<span class="kw">use</span> <span class="ident">abstio</span>::{<span class="ident">CityName</span>, <span class="ident">Manifest</span>, <span class="ident">MapName</span>};
|
||||
@ -768,6 +792,12 @@
|
||||
|
||||
<span class="kw">impl</span><span class="op"><</span><span class="ident">A</span>: <span class="ident">AppLike</span> <span class="op">+</span> <span class="lifetime">'static</span><span class="op">></span> <span class="ident">State</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> <span class="kw">for</span> <span class="ident">CityPicker</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> {
|
||||
<span class="kw">fn</span> <span class="ident">event</span>(<span class="kw-2">&mut</span> <span class="self">self</span>, <span class="ident">ctx</span>: <span class="kw-2">&mut</span> <span class="ident">EventCtx</span>, <span class="ident">app</span>: <span class="kw-2">&mut</span> <span class="ident">A</span>) -> <span class="ident">Transition</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> {
|
||||
<span class="comment">// TODO This happens if we prompt the user to download something, but they cancel. At that</span>
|
||||
<span class="comment">// point, we've lost the callback, so for now, just totally bail out.</span>
|
||||
<span class="kw">if</span> <span class="self">self</span>.<span class="ident">on_load</span>.<span class="ident">is_none</span>() {
|
||||
<span class="kw">return</span> <span class="ident">Transition::Pop</span>;
|
||||
}
|
||||
|
||||
<span class="kw">match</span> <span class="self">self</span>.<span class="ident">panel</span>.<span class="ident">event</span>(<span class="ident">ctx</span>) {
|
||||
<span class="ident">Outcome::Clicked</span>(<span class="ident">x</span>) => <span class="kw">match</span> <span class="ident">x</span>.<span class="ident">as_ref</span>() {
|
||||
<span class="string">"close"</span> => {
|
||||
@ -886,6 +916,11 @@
|
||||
|
||||
<span class="kw">impl</span><span class="op"><</span><span class="ident">A</span>: <span class="ident">AppLike</span> <span class="op">+</span> <span class="lifetime">'static</span><span class="op">></span> <span class="ident">State</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> <span class="kw">for</span> <span class="ident">AllCityPicker</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> {
|
||||
<span class="kw">fn</span> <span class="ident">event</span>(<span class="kw-2">&mut</span> <span class="self">self</span>, <span class="ident">ctx</span>: <span class="kw-2">&mut</span> <span class="ident">EventCtx</span>, <span class="ident">app</span>: <span class="kw-2">&mut</span> <span class="ident">A</span>) -> <span class="ident">Transition</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> {
|
||||
<span class="comment">// Same as CityPicker</span>
|
||||
<span class="kw">if</span> <span class="self">self</span>.<span class="ident">on_load</span>.<span class="ident">is_none</span>() {
|
||||
<span class="kw">return</span> <span class="ident">Transition::Pop</span>;
|
||||
}
|
||||
|
||||
<span class="kw">if</span> <span class="kw">let</span> <span class="ident">Outcome::Clicked</span>(<span class="ident">x</span>) <span class="op">=</span> <span class="self">self</span>.<span class="ident">panel</span>.<span class="ident">event</span>(<span class="ident">ctx</span>) {
|
||||
<span class="kw">match</span> <span class="ident">x</span>.<span class="ident">as_ref</span>() {
|
||||
<span class="string">"close"</span> => {
|
||||
@ -1013,6 +1048,11 @@
|
||||
|
||||
<span class="kw">impl</span><span class="op"><</span><span class="ident">A</span>: <span class="ident">AppLike</span> <span class="op">+</span> <span class="lifetime">'static</span><span class="op">></span> <span class="ident">State</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> <span class="kw">for</span> <span class="ident">CitiesInCountryPicker</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> {
|
||||
<span class="kw">fn</span> <span class="ident">event</span>(<span class="kw-2">&mut</span> <span class="self">self</span>, <span class="ident">ctx</span>: <span class="kw-2">&mut</span> <span class="ident">EventCtx</span>, <span class="ident">app</span>: <span class="kw-2">&mut</span> <span class="ident">A</span>) -> <span class="ident">Transition</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> {
|
||||
<span class="comment">// Same as CityPicker</span>
|
||||
<span class="kw">if</span> <span class="self">self</span>.<span class="ident">on_load</span>.<span class="ident">is_none</span>() {
|
||||
<span class="kw">return</span> <span class="ident">Transition::Pop</span>;
|
||||
}
|
||||
|
||||
<span class="kw">if</span> <span class="kw">let</span> <span class="ident">Outcome::Clicked</span>(<span class="ident">x</span>) <span class="op">=</span> <span class="self">self</span>.<span class="ident">panel</span>.<span class="ident">event</span>(<span class="ident">ctx</span>) {
|
||||
<span class="kw">match</span> <span class="ident">x</span>.<span class="ident">as_ref</span>() {
|
||||
<span class="string">"close"</span> => {
|
||||
@ -1042,6 +1082,7 @@
|
||||
<span class="kw">return</span> <span class="ident"><span class="kw">crate</span>::tools::prompt_to_download_missing_data</span>(
|
||||
<span class="ident">ctx</span>,
|
||||
<span class="ident">maps</span>.<span class="ident">pop</span>().<span class="ident">unwrap</span>(),
|
||||
<span class="self">self</span>.<span class="ident">on_load</span>.<span class="ident">take</span>().<span class="ident">unwrap</span>(),
|
||||
);
|
||||
}
|
||||
}
|
||||
@ -1088,7 +1129,14 @@
|
||||
<span class="attribute">#[<span class="ident">cfg</span>(<span class="ident">not</span>(<span class="ident">target_arch</span> <span class="op">=</span> <span class="string">"wasm32"</span>))]</span>
|
||||
{
|
||||
<span class="kw">if</span> <span class="op">!</span><span class="ident">abstio::file_exists</span>(<span class="ident">name</span>.<span class="ident">path</span>()) {
|
||||
<span class="kw">return</span> <span class="ident"><span class="kw">crate</span>::tools::prompt_to_download_missing_data</span>(<span class="ident">ctx</span>, <span class="ident">name</span>);
|
||||
<span class="kw">let</span> <span class="ident">on_load</span> <span class="op">=</span> <span class="ident">on_load</span>.<span class="ident">take</span>().<span class="ident">unwrap</span>();
|
||||
<span class="kw">return</span> <span class="ident"><span class="kw">crate</span>::tools::prompt_to_download_missing_data</span>(
|
||||
<span class="ident">ctx</span>,
|
||||
<span class="ident">name</span>.<span class="ident">clone</span>(),
|
||||
<span class="ident">Box::new</span>(<span class="kw">move</span> <span class="op">|</span><span class="ident">ctx</span>, <span class="ident">app</span><span class="op">|</span> {
|
||||
<span class="ident">Transition::Replace</span>(<span class="ident">MapLoader::new_state</span>(<span class="ident">ctx</span>, <span class="ident">app</span>, <span class="ident">name</span>, <span class="ident">on_load</span>))
|
||||
}),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -158,8 +158,11 @@
|
||||
<span id="153">153</span>
|
||||
<span id="154">154</span>
|
||||
<span id="155">155</span>
|
||||
<span id="156">156</span>
|
||||
<span id="157">157</span>
|
||||
</pre><pre class="rust"><code><span class="kw">use</span> <span class="ident">std::collections::BTreeSet</span>;
|
||||
|
||||
<span class="kw">use</span> <span class="ident">anyhow::Result</span>;
|
||||
<span class="kw">use</span> <span class="ident">fs_err::File</span>;
|
||||
<span class="kw">use</span> <span class="ident">futures_channel::mpsc</span>;
|
||||
|
||||
@ -192,12 +195,10 @@
|
||||
<span class="ident">bytes</span>
|
||||
}
|
||||
|
||||
<span class="doccomment">/// Prompt to download a missing city. On either success or failure (maybe the player choosing to</span>
|
||||
<span class="doccomment">/// not download, maybe a network error), the new map isn't automatically loaded or anything; up to</span>
|
||||
<span class="doccomment">/// the caller to handle that.</span>
|
||||
<span class="kw">pub</span> <span class="kw">fn</span> <span class="ident">prompt_to_download_missing_data</span><span class="op"><</span><span class="ident">A</span>: <span class="ident">AppLike</span> <span class="op">+</span> <span class="lifetime">'static</span><span class="op">></span>(
|
||||
<span class="ident">ctx</span>: <span class="kw-2">&mut</span> <span class="ident">EventCtx</span>,
|
||||
<span class="ident">map_name</span>: <span class="ident">MapName</span>,
|
||||
<span class="ident">on_load</span>: <span class="ident">Box</span><span class="op"><</span><span class="kw">dyn</span> <span class="ident">FnOnce</span>(<span class="kw-2">&mut</span> <span class="ident">EventCtx</span>, <span class="kw-2">&mut</span> <span class="ident">A</span>) -> <span class="ident">Transition</span><span class="op"><</span><span class="ident">A</span><span class="op">></span><span class="op">></span>,
|
||||
) -> <span class="ident">Transition</span><span class="op"><</span><span class="ident">A</span><span class="op">></span> {
|
||||
<span class="ident">Transition::Push</span>(<span class="ident">ChooseSomething::new_state</span>(
|
||||
<span class="ident">ctx</span>,
|
||||
@ -224,28 +225,29 @@
|
||||
|
||||
<span class="kw">let</span> (<span class="ident">outer_progress_tx</span>, <span class="ident">outer_progress_rx</span>) <span class="op">=</span> <span class="ident">futures_channel::mpsc::channel</span>(<span class="number">1000</span>);
|
||||
<span class="kw">let</span> (<span class="ident">inner_progress_tx</span>, <span class="ident">inner_progress_rx</span>) <span class="op">=</span> <span class="ident">futures_channel::mpsc::channel</span>(<span class="number">1000</span>);
|
||||
<span class="ident">Transition::Replace</span>(<span class="ident">FutureLoader</span>::<span class="op"><</span><span class="ident">A</span>, <span class="ident">Vec</span><span class="op"><</span><span class="ident">String</span><span class="op">></span><span class="op">></span><span class="ident">::new_state</span>(
|
||||
<span class="ident">Transition::Replace</span>(<span class="ident">FutureLoader</span>::<span class="op"><</span><span class="ident">A</span>, <span class="prelude-ty">Result</span><span class="op"><</span>()<span class="op">></span><span class="op">></span><span class="ident">::new_state</span>(
|
||||
<span class="ident">ctx</span>,
|
||||
<span class="ident">Box::pin</span>(<span class="kw">async</span> {
|
||||
<span class="kw">let</span> <span class="ident">result</span> <span class="op">=</span>
|
||||
<span class="ident">download_cities</span>(<span class="ident">cities</span>, <span class="ident">outer_progress_tx</span>, <span class="ident">inner_progress_tx</span>).<span class="kw">await</span>;
|
||||
<span class="kw">let</span> <span class="ident">wrap</span>: <span class="ident">Box</span><span class="op"><</span><span class="kw">dyn</span> <span class="ident">Send</span> <span class="op">+</span> <span class="ident">FnOnce</span>(<span class="kw-2">&</span><span class="ident">A</span>) -> <span class="ident">Vec</span><span class="op"><</span><span class="ident">String</span><span class="op">></span><span class="op">></span> <span class="op">=</span>
|
||||
<span class="kw">let</span> <span class="ident">wrap</span>: <span class="ident">Box</span><span class="op"><</span><span class="kw">dyn</span> <span class="ident">Send</span> <span class="op">+</span> <span class="ident">FnOnce</span>(<span class="kw-2">&</span><span class="ident">A</span>) -> <span class="prelude-ty">Result</span><span class="op"><</span>()<span class="op">></span><span class="op">></span> <span class="op">=</span>
|
||||
<span class="ident">Box::new</span>(<span class="kw">move</span> <span class="op">|</span><span class="kw">_</span>: <span class="kw-2">&</span><span class="ident">A</span><span class="op">|</span> <span class="ident">result</span>);
|
||||
<span class="prelude-val">Ok</span>(<span class="ident">wrap</span>)
|
||||
}),
|
||||
<span class="ident">outer_progress_rx</span>,
|
||||
<span class="ident">inner_progress_rx</span>,
|
||||
<span class="string">"Downloading missing files"</span>,
|
||||
<span class="ident">Box::new</span>(<span class="op">|</span><span class="ident">ctx</span>, <span class="kw">_</span>, <span class="ident">maybe_messages</span><span class="op">|</span> {
|
||||
<span class="kw">let</span> <span class="ident">messages</span> <span class="op">=</span> <span class="kw">match</span> <span class="ident">maybe_messages</span> {
|
||||
<span class="prelude-val">Ok</span>(<span class="ident">m</span>) => <span class="ident">m</span>,
|
||||
<span class="prelude-val">Err</span>(<span class="ident">err</span>) => <span class="macro">vec!</span>[<span class="macro">format!</span>(<span class="string">"Something went very wrong: {}"</span>, <span class="ident">err</span>)],
|
||||
<span class="ident">Box::new</span>(<span class="op">|</span><span class="ident">ctx</span>, <span class="ident">app</span>, <span class="ident">maybe_result</span><span class="op">|</span> {
|
||||
<span class="kw">let</span> <span class="ident">error_msg</span> <span class="op">=</span> <span class="kw">match</span> <span class="ident">maybe_result</span> {
|
||||
<span class="prelude-val">Ok</span>(<span class="prelude-val">Ok</span>(())) => <span class="prelude-val">None</span>,
|
||||
<span class="prelude-val">Ok</span>(<span class="prelude-val">Err</span>(<span class="ident">err</span>)) => <span class="prelude-val">Some</span>(<span class="ident">err</span>.<span class="ident">to_string</span>()),
|
||||
<span class="prelude-val">Err</span>(<span class="ident">err</span>) => <span class="prelude-val">Some</span>(<span class="macro">format!</span>(<span class="string">"Something went very wrong: {}"</span>, <span class="ident">err</span>)),
|
||||
};
|
||||
<span class="ident">Transition::Replace</span>(<span class="ident">PopupMsg::new_state</span>(
|
||||
<span class="ident">ctx</span>,
|
||||
<span class="string">"Download complete. Try again!"</span>,
|
||||
<span class="ident">messages</span>,
|
||||
))
|
||||
<span class="kw">if</span> <span class="kw">let</span> <span class="prelude-val">Some</span>(<span class="ident">err</span>) <span class="op">=</span> <span class="ident">error_msg</span> {
|
||||
<span class="ident">Transition::Replace</span>(<span class="ident">PopupMsg::new_state</span>(<span class="ident">ctx</span>, <span class="string">"Download failed"</span>, <span class="macro">vec!</span>[<span class="ident">err</span>]))
|
||||
} <span class="kw">else</span> {
|
||||
<span class="ident">on_load</span>(<span class="ident">ctx</span>, <span class="ident">app</span>)
|
||||
}
|
||||
}),
|
||||
))
|
||||
}),
|
||||
@ -256,7 +258,7 @@
|
||||
<span class="ident">cities</span>: <span class="ident">Vec</span><span class="op"><</span><span class="ident">String</span><span class="op">></span>,
|
||||
<span class="kw-2">mut</span> <span class="ident">outer_progress</span>: <span class="ident">mpsc::Sender</span><span class="op"><</span><span class="ident">String</span><span class="op">></span>,
|
||||
<span class="kw-2">mut</span> <span class="ident">inner_progress</span>: <span class="ident">mpsc::Sender</span><span class="op"><</span><span class="ident">String</span><span class="op">></span>,
|
||||
) -> <span class="ident">Vec</span><span class="op"><</span><span class="ident">String</span><span class="op">></span> {
|
||||
) -> <span class="prelude-ty">Result</span><span class="op"><</span>()<span class="op">></span> {
|
||||
<span class="kw">let</span> <span class="kw-2">mut</span> <span class="ident">data_packs</span> <span class="op">=</span> <span class="ident">DataPacks</span> {
|
||||
<span class="ident">runtime</span>: <span class="ident">BTreeSet::new</span>(),
|
||||
<span class="ident">input</span>: <span class="ident">BTreeSet::new</span>(),
|
||||
@ -310,8 +312,10 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
<span class="ident">messages</span>.<span class="ident">insert</span>(<span class="number">0</span>, <span class="macro">format!</span>(<span class="string">"Downloaded {} files"</span>, <span class="ident">num_files</span>));
|
||||
<span class="ident">messages</span>
|
||||
<span class="kw">if</span> <span class="op">!</span><span class="ident">messages</span>.<span class="ident">is_empty</span>() {
|
||||
<span class="macro">bail!</span>(<span class="string">"{} errors: {}"</span>, <span class="ident">messages</span>.<span class="ident">len</span>(), <span class="ident">messages</span>.<span class="ident">join</span>(<span class="string">", "</span>));
|
||||
}
|
||||
<span class="prelude-val">Ok</span>(())
|
||||
}
|
||||
</code></pre></div>
|
||||
</section><section id="search" class="content hidden"></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.61.0 (fe5b13d68 2022-05-18)" ></div>
|
||||
|
@ -233,6 +233,13 @@
|
||||
<span id="228">228</span>
|
||||
<span id="229">229</span>
|
||||
<span id="230">230</span>
|
||||
<span id="231">231</span>
|
||||
<span id="232">232</span>
|
||||
<span id="233">233</span>
|
||||
<span id="234">234</span>
|
||||
<span id="235">235</span>
|
||||
<span id="236">236</span>
|
||||
<span id="237">237</span>
|
||||
</pre><pre class="rust"><code><span class="kw">use</span> <span class="ident">geom::Percent</span>;
|
||||
<span class="kw">use</span> <span class="ident">widgetry::tools::open_browser</span>;
|
||||
<span class="kw">use</span> <span class="ident">widgetry</span>::{
|
||||
@ -321,8 +328,15 @@
|
||||
{
|
||||
<span class="kw">let</span> <span class="ident">map_name</span> <span class="op">=</span> <span class="ident">level</span>.<span class="ident">map</span>.<span class="ident">clone</span>();
|
||||
<span class="kw">if</span> <span class="op">!</span><span class="ident">abstio::file_exists</span>(<span class="ident">map_name</span>.<span class="ident">path</span>()) {
|
||||
<span class="kw">let</span> <span class="ident">level</span> <span class="op">=</span> <span class="ident">level</span>.<span class="ident">clone</span>();
|
||||
<span class="kw">return</span> <span class="ident">map_gui::tools::prompt_to_download_missing_data</span>(
|
||||
<span class="ident">ctx</span>, <span class="ident">map_name</span>,
|
||||
<span class="ident">ctx</span>,
|
||||
<span class="ident">map_name</span>,
|
||||
<span class="ident">Box::new</span>(<span class="kw">move</span> <span class="op">|</span><span class="ident">ctx</span>, <span class="ident">app</span><span class="op">|</span> {
|
||||
<span class="ident">Transition::Replace</span>(<span class="ident"><span class="kw">crate</span>::before_level::Picker::new_state</span>(
|
||||
<span class="ident">ctx</span>, <span class="ident">app</span>, <span class="ident">level</span>,
|
||||
))
|
||||
}),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user