MōBrowser API
Loading...
Searching...
No Matches
mobrowser::StartDownloadAction Class Reference

The BrowserDelegates::onStartDownload action. More...

#include <browser_delegates.hpp>

Inheritance diagram for mobrowser::StartDownloadAction:
mobrowser::Action

Public Member Functions

 StartDownloadAction (std::unique_ptr< rpc::internal::Callback > callback)
 
void download (const std::string &file_path)
 Download and save the file at the given file path without displaying the Save File dialog.
 
void cancel ()
 Cancel file download.
 
void prompt ()
 Display the native Save File dialog where the end user can select the directory where to save the file or cancel file download.
 
- Public Member Functions inherited from mobrowser::Action
 Action (std::unique_ptr< rpc::internal::Callback > callback)
 

Additional Inherited Members

- Protected Attributes inherited from mobrowser::Action
std::unique_ptr< rpc::internal::Callback > callback_
 

Detailed Description

Member Function Documentation

◆ download()

void mobrowser::StartDownloadAction::download ( const std::string &  file_path)

Download and save the file at the given file path without displaying the Save File dialog.

Parameters
file_paththe absolute or relative path to the target file. The application must have the write permissions on the target file.

The documentation for this class was generated from the following file: