diff options
author | Akshay <[email protected]> | 2020-08-03 11:35:55 +0100 |
---|---|---|
committer | Akshay <[email protected]> | 2020-08-03 11:35:55 +0100 |
commit | fcaf919fd1e176e4b8dd6d5d21e25db7f68c32a8 (patch) | |
tree | b1fa143f95d5bbc48f4008641ce031cd7f5f4532 /src/command.rs | |
parent | 7e1dff439f1768fc463ddcfcd6ea58a7a1711056 (diff) |
use consts for dimensions
Diffstat (limited to 'src/command.rs')
-rw-r--r-- | src/command.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/command.rs b/src/command.rs index 0ef5121..8c823a2 100644 --- a/src/command.rs +++ b/src/command.rs | |||
@@ -6,7 +6,8 @@ use cursive::view::Resizable; | |||
6 | use cursive::views::{EditView, LinearLayout, OnEventView, TextView}; | 6 | use cursive::views::{EditView, LinearLayout, OnEventView, TextView}; |
7 | use cursive::Cursive; | 7 | use cursive::Cursive; |
8 | 8 | ||
9 | use crate::{app::App, CONFIGURATION}; | 9 | use crate::app::App; |
10 | use crate::utils::{GRID_WIDTH, VIEW_WIDTH}; | ||
10 | 11 | ||
11 | static COMMANDS: &'static [&'static str] = &[ | 12 | static COMMANDS: &'static [&'static str] = &[ |
12 | "add", | 13 | "add", |
@@ -68,7 +69,7 @@ pub fn open_command_window(s: &mut Cursive) { | |||
68 | } | 69 | } |
69 | }, | 70 | }, |
70 | ) | 71 | ) |
71 | .fixed_width(CONFIGURATION.view_width * CONFIGURATION.grid_width); | 72 | .fixed_width(VIEW_WIDTH * GRID_WIDTH); |
72 | s.call_on_name("Frame", |view: &mut LinearLayout| { | 73 | s.call_on_name("Frame", |view: &mut LinearLayout| { |
73 | let mut commandline = LinearLayout::horizontal() | 74 | let mut commandline = LinearLayout::horizontal() |
74 | .child(TextView::new(":")) | 75 | .child(TextView::new(":")) |