-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5 from gintama91/dev
load with url,cleanup and wip tht eval
- Loading branch information
Showing
11 changed files
with
108 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"rust-analyzer.linkedProjects": [ | ||
"./ext/wry_ruby/Cargo.toml" | ||
] | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
require_relative "../lib/wry_ruby/wry_ruby" | ||
|
||
new_window("Hello Wry", 100, 400, true, 3) | ||
# new_window("Hello Wry", 100, 400, true, 3) | ||
|
||
# load_with_url("https://github.com/scarpe-team/scarpe") | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
// use magnus::Error; | ||
// mod utils; | ||
|
||
// pub fn init() -> Result<(), Error> { | ||
// // utils::init()?; | ||
// Ok(()) | ||
// } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
// hmm i am tired of this errors where traits are not implemented for tht , this hmmmm i will look into this later. | ||
// we need this mostly to eval js code | ||
|
||
|
||
// ************************************************************************************************************************************************************************************** | ||
|
||
// use std::sync::{Arc, Mutex}; | ||
// use webkit2gtk::WebView; | ||
|
||
// use magnus::{function, Error, ExceptionClass, Module, Object, RString, define_global_function, class}; | ||
// use wry::application::window::Window as WindowImpl; | ||
// use wry::webview::WebView as WebViewImpl; | ||
|
||
// pub struct WebViewWrapper { | ||
// inner: Arc<Mutex<WebViewImpl>>, | ||
// } | ||
|
||
// impl WebViewWrapper { | ||
// pub fn window(&self) -> Result<(), Error> { | ||
// let inner = self.inner.lock().unwrap(); | ||
// WebViewImpl::window(&inner); | ||
// Ok(()) | ||
// } | ||
|
||
// pub fn eval(&self, js: RString) -> Result<(), Error> { | ||
// let inner = self.inner.lock().unwrap(); | ||
// WebViewImpl::evaluate_script(&inner, unsafe { js.as_str() })?; | ||
// Ok(()) | ||
// } | ||
// } | ||
|
||
// pub fn init() -> Result<(), Error> { | ||
// // define_global_function("webview_eval", WebViewWrapper::eval); | ||
|
||
// class::string() | ||
// .define_private_method("eval",function!(WebViewWrapper::eval,2)); | ||
// Ok(()) | ||
// } | ||
// // inner: Arc<Mutex<WebViewImpl>>, | ||
|
||
|