1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
//! Browser Window is a Rust crate that allows you to have and manipulate windows with browsers in them.
//! Just like Electron, you can build graphical user interfaces with HTML/CSS/JS technology, but you can also use it to just have some browser functionality in your application.
//!
//! To start using Browser Window, you need to start it before anything else, and preferably on the main thread.
//! To do this we use `Application::start()`, which gives you an application handle that can be used to create the browser windows.
//!
//! Your program might look something like this:
//! ```
//! use browser_window::*;
//!
//! fn main() {
//! let app = Application::start();
//!
//! BrowserWindowBuilder::new( Source::Url("https://www.duckduckgo.com/".to_owned()) )
//! .spawn( &app, |browser| {
//! browser.exec_js(" ... ");
//! });
//! }
//! ```
//!
//! For an example that uses Browser Window in an asynchronous context, see [this example code](https://github.com/bamilab/browser-window/blob/master/example/src/main.rs).
pub use ;
pub use ;
pub use ;