Commit f278a975 authored by Jeremy Soller's avatar Jeremy Soller

Fix compilation, login program is broken though

parent c5510e91
#![crate_type="rlib"]
#![crate_type="lib"]
#![feature(associated_consts)]
#![feature(box_syntax)]
#![feature(core)]
......
......@@ -59,18 +59,20 @@ impl Window {
pub fn sync_path(&mut self) {
if let Ok(path) = self.file.path() {
//orbital://x/y/w/h/t
let parts: Vec<&str> = path.split('/').collect();
if let Some(x) = parts.get(3) {
self.x = x.to_num_signed();
}
if let Some(y) = parts.get(4) {
self.y = y.to_num_signed();
}
if let Some(w) = parts.get(5) {
self.w = w.to_num();
}
if let Some(h) = parts.get(6) {
self.h = h.to_num();
if let Some(path_str) = path.to_str() {
let parts: Vec<&str> = path_str.split('/').collect();
if let Some(x) = parts.get(3) {
self.x = x.to_num_signed();
}
if let Some(y) = parts.get(4) {
self.y = y.to_num_signed();
}
if let Some(w) = parts.get(5) {
self.w = w.to_num();
}
if let Some(h) = parts.get(6) {
self.h = h.to_num();
}
}
}
}
......
Markdown is supported
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