pub struct CloseOptions {
pub return_back: Option<bool>,
}Expand description
Options supported by crate::webapp::TelegramWebApp::close_with_options.
§Examples
use telegram_webapp_sdk::webapp::{CloseOptions, TelegramWebApp};
if let Some(app) = TelegramWebApp::instance() {
let _ = app.close_with_options(&CloseOptions {
return_back: Some(true)
});
}Fields§
§return_back: Option<bool>If true and the host client is Bot API 7.6+, returns the user to the
previous chat instead of just closing the mini app.
Trait Implementations§
Source§impl Debug for CloseOptions
impl Debug for CloseOptions
Source§impl Default for CloseOptions
impl Default for CloseOptions
Source§fn default() -> CloseOptions
fn default() -> CloseOptions
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for CloseOptions
impl RefUnwindSafe for CloseOptions
impl Send for CloseOptions
impl Sync for CloseOptions
impl Unpin for CloseOptions
impl UnsafeUnpin for CloseOptions
impl UnwindSafe for CloseOptions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more