Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Implement navigation event and cancellation, closes #456 #519

Merged
merged 20 commits into from
Mar 18, 2022
Merged
Changes from 1 commit
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
32d41e7
Modify webcontext to take EventLoopProxy
atlanticaccent Mar 5, 2022
4b4ee4d
Attempt to make other platforms accept generic webcontext
atlanticaccent Mar 5, 2022
f6ce724
Modify with_event_loop proxy to allow different event_loop types
atlanticaccent Mar 6, 2022
f296b3d
Fix WebViewBuilder to be able to switch types
atlanticaccent Mar 6, 2022
8f6197e
Add event loop proxy getter
atlanticaccent Mar 6, 2022
a76bca4
Add getter and setter for naviagtion event constructor callback
atlanticaccent Mar 6, 2022
460d896
Complete initial implementation of nav events, cancellation
atlanticaccent Mar 7, 2022
9978b07
Move majority implementation into WebView/WebViewData
atlanticaccent Mar 7, 2022
6ae72f5
Revert changes to Gtk WebContext
atlanticaccent Mar 7, 2022
6893f74
Revert changes to wkwebview
atlanticaccent Mar 7, 2022
f0f5d96
Extend event to cover new window/popup events
atlanticaccent Mar 8, 2022
011e612
Move navigation callback into WebViewAttributes
atlanticaccent Mar 8, 2022
7099b87
Remove unnecessary brackets in WebView
atlanticaccent Mar 8, 2022
8c0f535
Remove new window handler
atlanticaccent Mar 8, 2022
8a5df2f
Remove references to new window values
atlanticaccent Mar 8, 2022
0500e74
Implement navigation event callback handler on gtk
atlanticaccent Mar 9, 2022
e9a0929
Add navigation handler on macOS
Mar 15, 2022
10ce4aa
Call the navigation handler on macOS
Mar 15, 2022
b03231f
Update navifation logic and type signature
Mar 16, 2022
eff4a6b
Fix errors on windows
Mar 16, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Revert changes to wkwebview
atlanticaccent committed Mar 7, 2022
commit 6893f742061a3c2ff84a2888dca50a7de133ea1c
6 changes: 3 additions & 3 deletions src/webview/wkwebview/mod.rs
Original file line number Diff line number Diff line change
@@ -46,7 +46,7 @@ use crate::{
dpi::{LogicalSize, PhysicalSize},
window::Window,
},
webview::{FileDropEvent, WebContextGeneric, WebViewAttributes},
webview::{FileDropEvent, WebContext, WebViewAttributes},
Result,
};

@@ -68,10 +68,10 @@ pub struct InnerWebView {
}

impl InnerWebView {
pub fn new<T>(
pub fn new(
window: Rc<Window>,
attributes: WebViewAttributes,
mut web_context: Option<&mut WebContextGeneric<T>>,
mut web_context: Option<&mut WebContext>,
) -> Result<Self> {
// Function for ipc handler
extern "C" fn did_receive(this: &Object, _: Sel, _: id, msg: id) {