40 lines
868 B
Rust
40 lines
868 B
Rust
//! This module contains the `windows` specific logic.
|
|
|
|
pub mod ansi_support;
|
|
pub mod cursor;
|
|
pub mod kernel;
|
|
pub mod terminal;
|
|
|
|
use self::winapi::um::wincon::{CONSOLE_SCREEN_BUFFER_INFO, COORD, SMALL_RECT};
|
|
use shared::traits::Empty;
|
|
use winapi;
|
|
|
|
impl Empty for COORD {
|
|
fn empty() -> COORD {
|
|
COORD { X: 0, Y: 0 }
|
|
}
|
|
}
|
|
|
|
impl Empty for SMALL_RECT {
|
|
fn empty() -> SMALL_RECT {
|
|
SMALL_RECT {
|
|
Top: 0,
|
|
Right: 0,
|
|
Bottom: 0,
|
|
Left: 0,
|
|
}
|
|
}
|
|
}
|
|
|
|
impl Empty for CONSOLE_SCREEN_BUFFER_INFO {
|
|
fn empty() -> CONSOLE_SCREEN_BUFFER_INFO {
|
|
CONSOLE_SCREEN_BUFFER_INFO {
|
|
dwSize: COORD::empty(),
|
|
dwCursorPosition: COORD::empty(),
|
|
wAttributes: 0,
|
|
srWindow: SMALL_RECT::empty(),
|
|
dwMaximumWindowSize: COORD::empty(),
|
|
}
|
|
}
|
|
}
|