Commit baa1b0e9 authored by Florian Blasius's avatar Florian Blasius 🤘
Browse files

[bugfix] resource path for examples.

parent 7d9feeab
Pipeline #2404 passed with stage
in 2 minutes and 18 seconds
......@@ -13,7 +13,7 @@
],
"presentation": {
"reveal": "always",
"panel": "new",
"panel": "new"
},
"group": {
"kind": "build",
......@@ -21,25 +21,49 @@
}
},
{
"label": "run web examples",
"label": "run dragging web",
"command": "cargo",
"type": "shell",
"args": [
"web",
"start",
"--target=wasm32-unknown-unknown",
"----auto-reload",
"--auto-reload",
"--example",
"dragging"
],
"presentation": {
"reveal": "always",
"panel": "new",
"panel": "new"
},
"group": {
"kind": "build",
"isDefault": true
}
},
{
"label": "run drawing web",
"command": "cargo",
"type": "shell",
"args": [
"web",
"start",
"--target=wasm32-unknown-unknown",
"--auto-reload",
"--example",
"drawing"
],
"presentation": {
"reveal": "always",
"panel": "new"
},
"group": {
"kind": "build",
"isDefault": true
},
"problemMatcher": [
"$rustc"
]
}
]
}
\ No newline at end of file
......@@ -10,10 +10,10 @@ fn main() {
// todo add render dings with usize index
#[cfg(target_arch = "wasm32")]
let res_patch = "res/";
let res_path = "res/";
#[cfg(not(target_arch = "wasm32"))]
let res_path = "examples/static/res/";
let res_path = "static/res/";
let mut window = WindowBuilder::new()
.with_title("OrbRender - drawing example")
......@@ -66,8 +66,6 @@ fn main() {
.with_font(FontConfig::default().with_family("Roboto").with_size(22.0)),
);
println!("{}orbtk-space.png", res_path);
window.push_image(
Image::default()
.with_position(Point::new(10.0, 100.0))
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment