diff options
author | Jesse Luehrs <doy@tozt.net> | 2013-04-08 21:56:10 -0500 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2013-04-08 21:56:10 -0500 |
commit | ad2578a7ad98de9171400aea20c38f3ca237d88e (patch) | |
tree | cc1068a80a9d7bf47e5a8b7ded0af53d3fe98c02 /src/util.rs | |
parent | 50fe57cbcba4a35665e0c622852bfa33b024aea8 (diff) | |
download | rust-term-ad2578a7ad98de9171400aea20c38f3ca237d88e.tar.gz rust-term-ad2578a7ad98de9171400aea20c38f3ca237d88e.zip |
move size back to term::ios
Diffstat (limited to 'src/util.rs')
-rw-r--r-- | src/util.rs | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/src/util.rs b/src/util.rs index 09d8c11..149f425 100644 --- a/src/util.rs +++ b/src/util.rs @@ -1,4 +1,4 @@ -use core::libc::{c_int,c_uint}; +use core::libc::c_int; // XXX huge hack until there's a better built-in way to do this pub fn timed_read (timeout: int) -> Option<char> { @@ -24,16 +24,3 @@ pub fn timed_read (timeout: int) -> Option<char> { extern mod io_helper { fn timed_read (timeout: c_int) -> c_int; } - -pub fn size() -> (uint, uint) { - let cols: c_uint = 0; - let rows: c_uint = 0; - unsafe { - termios_wrapper::size(&cols, &rows) - } - (cols as uint, rows as uint) -} - -extern mod termios_wrapper { - fn size(cols: *c_uint, rows: *c_uint); -} |