diff options
author | Caleb Bassi <calebjbassi@gmail.com> | 2019-02-15 04:43:09 -0800 |
---|---|---|
committer | Caleb Bassi <calebjbassi@gmail.com> | 2019-02-15 05:56:09 -0800 |
commit | 29b3922f9efb9f277641a63f8f1719a15cbb8d16 (patch) | |
tree | d919ba11fa5c754565c64c43cb1614f7ae4d2546 | |
parent | 3853eef2d052460982903038daac7abd2b71d12e (diff) |
refactor: project layout
-rw-r--r-- | src/commands/change_directory.rs (renamed from src/joshuto/commands/change_directory.rs) | 8 | ||||
-rw-r--r-- | src/commands/cursor_move.rs (renamed from src/joshuto/commands/cursor_move.rs) | 6 | ||||
-rw-r--r-- | src/commands/delete_files.rs (renamed from src/joshuto/commands/delete_files.rs) | 10 | ||||
-rw-r--r-- | src/commands/file_operations.rs (renamed from src/joshuto/commands/file_operations.rs) | 8 | ||||
-rw-r--r-- | src/commands/mod.rs (renamed from src/joshuto/commands/mod.rs) | 4 | ||||
-rw-r--r-- | src/commands/new_directory.rs (renamed from src/joshuto/commands/new_directory.rs) | 8 | ||||
-rw-r--r-- | src/commands/open_file.rs (renamed from src/joshuto/commands/open_file.rs) | 18 | ||||
-rw-r--r-- | src/commands/parent_directory.rs (renamed from src/joshuto/commands/parent_directory.rs) | 9 | ||||
-rw-r--r-- | src/commands/quit.rs (renamed from src/joshuto/commands/quit.rs) | 6 | ||||
-rw-r--r-- | src/commands/reload_dir.rs (renamed from src/joshuto/commands/reload_dir.rs) | 6 | ||||
-rw-r--r-- | src/commands/rename_file.rs (renamed from src/joshuto/commands/rename_file.rs) | 10 | ||||
-rw-r--r-- | src/commands/search.rs (renamed from src/joshuto/commands/search.rs) | 8 | ||||
-rw-r--r-- | src/commands/selection.rs (renamed from src/joshuto/commands/selection.rs) | 4 | ||||
-rw-r--r-- | src/commands/set_mode.rs (renamed from src/joshuto/commands/set_mode.rs) | 12 | ||||
-rw-r--r-- | src/commands/show_hidden.rs (renamed from src/joshuto/commands/show_hidden.rs) | 4 | ||||
-rw-r--r-- | src/commands/tab_operations.rs (renamed from src/joshuto/commands/tab_operations.rs) | 8 | ||||
-rw-r--r-- | src/commands/tab_switch.rs (renamed from src/joshuto/commands/tab_switch.rs) | 6 | ||||
-rw-r--r-- | src/config/config.rs (renamed from src/joshuto/config/config.rs) | 4 | ||||
-rw-r--r-- | src/config/keymap.rs (renamed from src/joshuto/config/keymap.rs) | 4 | ||||
-rw-r--r-- | src/config/mimetype.rs (renamed from src/joshuto/config/mimetype.rs) | 2 | ||||
-rw-r--r-- | src/config/mod.rs (renamed from src/joshuto/config/mod.rs) | 0 | ||||
-rw-r--r-- | src/config/preview.rs (renamed from src/joshuto/config/preview.rs) | 2 | ||||
-rw-r--r-- | src/config/theme.rs (renamed from src/joshuto/config/theme.rs) | 2 | ||||
-rw-r--r-- | src/context.rs (renamed from src/joshuto/context.rs) | 8 | ||||
-rw-r--r-- | src/history.rs (renamed from src/joshuto/history.rs) | 4 | ||||
-rw-r--r-- | src/main.rs | 22 | ||||
-rw-r--r-- | src/preview.rs (renamed from src/joshuto/preview.rs) | 6 | ||||
-rw-r--r-- | src/run.rs (renamed from src/joshuto.rs) | 33 | ||||
-rw-r--r-- | src/sort.rs (renamed from src/joshuto/sort.rs) | 2 | ||||
-rw-r--r-- | src/structs.rs (renamed from src/joshuto/structs.rs) | 4 | ||||
-rw-r--r-- | src/tab.rs (renamed from src/joshuto/tab.rs) | 16 | ||||
-rw-r--r-- | src/textfield.rs (renamed from src/joshuto/textfield.rs) | 4 | ||||
-rw-r--r-- | src/ui.rs (renamed from src/joshuto/ui.rs) | 12 | ||||
-rw-r--r-- | src/unix.rs (renamed from src/joshuto/unix.rs) | 2 | ||||
-rw-r--r-- | src/window/mod.rs (renamed from src/joshuto/window/mod.rs) | 0 | ||||
-rw-r--r-- | src/window/page_state.rs (renamed from src/joshuto/window/page_state.rs) | 0 | ||||
-rw-r--r-- | src/window/panel.rs (renamed from src/joshuto/window/panel.rs) | 4 | ||||
-rw-r--r-- | src/window/view.rs (renamed from src/joshuto/window/view.rs) | 2 |
38 files changed, 133 insertions, 135 deletions
diff --git a/src/joshuto/commands/change_directory.rs b/src/commands/change_directory.rs index 4565cae..40ea6d8 100644 --- a/src/joshuto/commands/change_directory.rs +++ b/src/commands/change_directory.rs @@ -3,10 +3,10 @@ extern crate ncurses; use std::path; use std::process; -use joshuto::commands::{JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; -use joshuto::preview; -use joshuto::ui; +use commands::{JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; +use preview; +use ui; #[derive(Clone, Debug)] pub struct ChangeDirectory { diff --git a/src/joshuto/commands/cursor_move.rs b/src/commands/cursor_move.rs index 8523cf4..d48d2bb 100644 --- a/src/joshuto/commands/cursor_move.rs +++ b/src/commands/cursor_move.rs @@ -1,8 +1,8 @@ extern crate ncurses; -use joshuto::commands::{JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; -use joshuto::preview; +use commands::{JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; +use preview; #[derive(Clone, Debug)] pub struct CursorMove { diff --git a/src/joshuto/commands/delete_files.rs b/src/commands/delete_files.rs index d71216b..f1a9d48 100644 --- a/src/joshuto/commands/delete_files.rs +++ b/src/commands/delete_files.rs @@ -3,11 +3,11 @@ extern crate ncurses; use std::fs; use std::path; -use joshuto::commands::{self, JoshutoCommand, JoshutoRunnable}; -use joshuto::config::keymap; -use joshuto::context::JoshutoContext; -use joshuto::preview; -use joshuto::ui; +use commands::{self, JoshutoCommand, JoshutoRunnable}; +use config::keymap; +use context::JoshutoContext; +use preview; +use ui; #[derive(Clone, Debug)] pub struct DeleteFiles; diff --git a/src/joshuto/commands/file_operations.rs b/src/commands/file_operations.rs index a3898a3..53936a0 100644 --- a/src/joshuto/commands/file_operations.rs +++ b/src/commands/file_operations.rs @@ -6,10 +6,10 @@ use std::sync; use std::thread; use std::time; -use joshuto::commands::{self, JoshutoCommand, JoshutoRunnable, ProgressInfo}; -use joshuto::context::JoshutoContext; -use joshuto::preview; -use joshuto::structs::JoshutoDirList; +use commands::{self, JoshutoCommand, JoshutoRunnable, ProgressInfo}; +use context::JoshutoContext; +use preview; +use structs::JoshutoDirList; lazy_static! { static ref selected_files: sync::Mutex<Vec<path::PathBuf>> = sync::Mutex::new(vec![]); diff --git a/src/joshuto/commands/mod.rs b/src/commands/mod.rs index 9451a1d..954dbdc 100644 --- a/src/joshuto/commands/mod.rs +++ b/src/commands/mod.rs @@ -40,8 +40,8 @@ use std::collections::HashMap; use std::fmt; use std::path::PathBuf; -use joshuto::context::JoshutoContext; -use joshuto::structs; +use context::JoshutoContext; +use structs; #[derive(Debug)] pub enum CommandKeybind { diff --git a/src/joshuto/commands/new_directory.rs b/src/commands/new_directory.rs index 9095dcb..35a3b18 100644 --- a/src/joshuto/commands/new_directory.rs +++ b/src/commands/new_directory.rs @@ -2,10 +2,10 @@ extern crate ncurses; use std::path; -use joshuto::commands::{JoshutoCommand, JoshutoRunnable, ReloadDirList}; -use joshuto::context::JoshutoContext; -use joshuto::textfield::JoshutoTextField; -use joshuto::ui; +use commands::{JoshutoCommand, JoshutoRunnable, ReloadDirList}; +use context::JoshutoContext; +use textfield::JoshutoTextField; +use ui; #[derive(Clone, Debug)] pub struct NewDirectory; diff --git a/src/joshuto/commands/open_file.rs b/src/commands/open_file.rs index 3a95bd9..9f4d88e 100644 --- a/src/joshuto/commands/open_file.rs +++ b/src/commands/open_file.rs @@ -5,16 +5,16 @@ extern crate open; use std::env; use std::path; -use joshuto::commands::{self, JoshutoCommand, JoshutoRunnable}; -use joshuto::config::mimetype; -use joshuto::context::JoshutoContext; -use joshuto::preview; -use joshuto::textfield::JoshutoTextField; -use joshuto::ui; -use joshuto::unix; -use joshuto::window; +use commands::{self, JoshutoCommand, JoshutoRunnable}; +use config::mimetype; +use context::JoshutoContext; +use preview; +use textfield::JoshutoTextField; +use ui; +use unix; +use window; -use joshuto::mimetype_t; +use mimetype_t; #[derive(Clone, Debug)] pub struct OpenFile; diff --git a/src/joshuto/commands/parent_directory.rs b/src/commands/parent_directory.rs index 2dd28b9..d9066c6 100644 --- a/src/joshuto/commands/parent_directory.rs +++ b/src/commands/parent_directory.rs @@ -1,10 +1,9 @@ extern crate ncurses; -use joshuto::commands::JoshutoRunnable; -use joshuto::context::JoshutoContext; -use joshuto::preview; -use joshuto::ui; -use joshuto::JoshutoCommand; +use commands::{JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; +use preview; +use ui; #[derive(Clone, Debug)] pub struct ParentDirectory; diff --git a/src/joshuto/commands/quit.rs b/src/commands/quit.rs index d45212e..33034a5 100644 --- a/src/joshuto/commands/quit.rs +++ b/src/commands/quit.rs @@ -1,8 +1,8 @@ use std::process; -use joshuto::commands::{JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; -use joshuto::ui; +use commands::{JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; +use ui; #[derive(Clone, Debug)] pub struct Quit; diff --git a/src/joshuto/commands/reload_dir.rs b/src/commands/reload_dir.rs index 8948862..3853810 100644 --- a/src/joshuto/commands/reload_dir.rs +++ b/src/commands/reload_dir.rs @@ -1,8 +1,8 @@ extern crate ncurses; -use joshuto::commands::{JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; -use joshuto::preview; +use commands::{JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; +use preview; #[derive(Clone, Debug)] pub struct ReloadDirList; diff --git a/src/joshuto/commands/rename_file.rs b/src/commands/rename_file.rs index d298536..f61ab4c 100644 --- a/src/joshuto/commands/rename_file.rs +++ b/src/commands/rename_file.rs @@ -3,11 +3,11 @@ extern crate ncurses; use std::fs; use std::path; -use joshuto::commands::{JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; -use joshuto::preview; -use joshuto::textfield::JoshutoTextField; -use joshuto::ui; +use commands::{JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; +use preview; +use textfield::JoshutoTextField; +use ui; #[derive(Clone, Debug)] pub enum RenameFileMethod { diff --git a/src/joshuto/commands/search.rs b/src/commands/search.rs index ac0ba17..a8c1edb 100644 --- a/src/joshuto/commands/search.rs +++ b/src/commands/search.rs @@ -1,9 +1,9 @@ extern crate ncurses; -use joshuto::commands::{CursorMove, JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; -use joshuto::textfield::JoshutoTextField; -use joshuto::ui; +use commands::{CursorMove, JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; +use textfield::JoshutoTextField; +use ui; #[derive(Clone, Debug)] pub struct Search; diff --git a/src/joshuto/commands/selection.rs b/src/commands/selection.rs index d5f5d97..3d82215 100644 --- a/src/joshuto/commands/selection.rs +++ b/src/commands/selection.rs @@ -1,5 +1,5 @@ -use joshuto::commands::{CursorMove, JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; +use commands::{CursorMove, JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; #[derive(Debug, Clone)] pub struct SelectFiles { diff --git a/src/joshuto/commands/set_mode.rs b/src/commands/set_mode.rs index 4068dd2..b0cf073 100644 --- a/src/joshuto/commands/set_mode.rs +++ b/src/commands/set_mode.rs @@ -1,11 +1,11 @@ extern crate ncurses; -use joshuto::commands::{JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; -use joshuto::structs::JoshutoDirEntry; -use joshuto::textfield::JoshutoTextField; -use joshuto::ui; -use joshuto::unix; +use commands::{JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; +use structs::JoshutoDirEntry; +use textfield::JoshutoTextField; +use ui; +use unix; #[derive(Clone, Debug)] pub struct SetMode; diff --git a/src/joshuto/commands/show_hidden.rs b/src/commands/show_hidden.rs index 4de6b82..aacac3b 100644 --- a/src/joshuto/commands/show_hidden.rs +++ b/src/commands/show_hidden.rs @@ -1,7 +1,7 @@ extern crate ncurses; -use joshuto::commands::{JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; +use commands::{JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; #[derive(Clone, Debug)] pub struct ToggleHiddenFiles; diff --git a/src/joshuto/commands/tab_operations.rs b/src/commands/tab_operations.rs index 74666a8..b35c375 100644 --- a/src/joshuto/commands/tab_operations.rs +++ b/src/commands/tab_operations.rs @@ -1,10 +1,10 @@ use std::env; use std::path; -use joshuto::commands::{JoshutoCommand, JoshutoRunnable, TabSwitch}; -use joshuto::context::JoshutoContext; -use joshuto::tab::JoshutoTab; -use joshuto::ui; +use commands::{JoshutoCommand, JoshutoRunnable, TabSwitch}; +use context::JoshutoContext; +use tab::JoshutoTab; +use ui; #[derive(Clone, Debug)] pub struct NewTab; diff --git a/src/joshuto/commands/tab_switch.rs b/src/commands/tab_switch.rs index 67e2ad3..583347e 100644 --- a/src/joshuto/commands/tab_switch.rs +++ b/src/commands/tab_switch.rs @@ -1,6 +1,6 @@ -use joshuto::commands::{JoshutoCommand, JoshutoRunnable}; -use joshuto::context::JoshutoContext; -use joshuto::ui; +use commands::{JoshutoCommand, JoshutoRunnable}; +use context::JoshutoContext; +use ui; #[derive(Clone, Debug)] pub struct TabSwitch { diff --git a/src/joshuto/config/config.rs b/src/config/config.rs index 9df66d0..b970c16 100644 --- a/src/joshuto/config/config.rs +++ b/src/config/config.rs @@ -2,8 +2,8 @@ extern crate toml; extern crate whoami; extern crate xdg; -use joshuto::config::{parse_config_file, Flattenable}; -use joshuto::sort; +use config::{parse_config_file, Flattenable}; +use sort; use CONFIG_FILE; diff --git a/src/joshuto/config/keymap.rs b/src/config/keymap.rs index dcb963d..639c33c 100644 --- a/src/joshuto/config/keymap.rs +++ b/src/config/keymap.rs @@ -5,8 +5,8 @@ extern crate xdg; use std::collections::HashMap; use std::process::exit; -use joshuto::commands; -use joshuto::config::{parse_config_file, Flattenable}; +use commands; +use config::{parse_config_file, Flattenable}; use KEYMAP_FILE; pub const BACKSPACE: i32 = 0x7F; diff --git a/src/joshuto/config/mimetype.rs b/src/config/mimetype.rs index 7b7599b..1be211f 100644 --- a/src/joshuto/config/mimetype.rs +++ b/src/config/mimetype.rs @@ -4,7 +4,7 @@ extern crate xdg; use std::collections::HashMap; use std::fmt; -use joshuto::config::{parse_config_file, Flattenable}; +use config::{parse_config_file, Flattenable}; use MIMETYPE_FILE; #[derive(Debug, Deserialize)] diff --git a/src/joshuto/config/mod.rs b/src/config/mod.rs index 273b9ab..273b9ab 100644 --- a/src/joshuto/config/mod.rs +++ b/src/config/mod.rs diff --git a/src/joshuto/config/preview.rs b/src/config/preview.rs index eabbd52..d8f3072 100644 --- a/src/joshuto/config/preview.rs +++ b/src/config/preview.rs @@ -3,7 +3,7 @@ extern crate xdg; use std::collections::HashMap; -use joshuto::config::{parse_config_file, Flattenable}; +use config::{parse_config_file, Flattenable}; use PREVIEW_FILE; #[derive(Debug, Deserialize)] diff --git a/src/joshuto/config/theme.rs b/src/config/theme.rs index ea143bb..2e27663 100644 --- a/src/joshuto/config/theme.rs +++ b/src/config/theme.rs @@ -3,7 +3,7 @@ extern crate xdg; use std::collections::HashMap; -use joshuto::config::{parse_config_file, Flattenable}; +use config::{parse_config_file, Flattenable}; #[derive(Debug, Deserialize, Clone)] pub struct JoshutoColorPair { diff --git a/src/joshuto/context.rs b/src/context.rs index 2dc41f1..36c4bca 100644 --- a/src/joshuto/context.rs +++ b/src/context.rs @@ -1,7 +1,7 @@ -use joshuto::commands::FileOperationThread; -use joshuto::config; -use joshuto::tab::JoshutoTab; -use joshuto::window::JoshutoView; +use commands::FileOperationThread; +use config; +use tab::JoshutoTab; +use window::JoshutoView; pub struct JoshutoContext { pub username: String, diff --git a/src/joshuto/history.rs b/src/history.rs index 3bd422b..8f0a270 100644 --- a/src/joshuto/history.rs +++ b/src/history.rs @@ -1,8 +1,8 @@ use std::collections::{hash_map::Entry, HashMap}; use std::path::{Path, PathBuf}; -use joshuto::sort; -use joshuto::structs; +use sort; +use structs; pub struct DirHistory { map: HashMap<PathBuf, structs::JoshutoDirList>, diff --git a/src/main.rs b/src/main.rs index 2b07eb1..7c6efdd 100644 --- a/src/main.rs +++ b/src/main.rs @@ -5,12 +5,25 @@ extern crate serde_derive; extern crate structopt; extern crate xdg; -mod joshuto; +mod commands; +mod config; +mod context; +mod history; +mod preview; +mod run; +mod sort; +mod structs; +mod tab; +mod textfield; +mod ui; +mod unix; +mod window; use std::path::PathBuf; use structopt::StructOpt; -use joshuto::config::{JoshutoConfig, JoshutoKeymap}; +use config::{JoshutoConfig, JoshutoKeymap, JoshutoMimetype, JoshutoPreview, JoshutoTheme}; +use run::run; const PROGRAM_NAME: &str = "joshuto"; const CONFIG_FILE: &str = "joshuto.toml"; @@ -33,6 +46,9 @@ lazy_static! { } temp }; + static ref theme_t: JoshutoTheme = JoshutoTheme::get_config(); + static ref mimetype_t: JoshutoMimetype = JoshutoMimetype::get_config(); + static ref preview_t: JoshutoPreview = JoshutoPreview::get_config(); } #[derive(StructOpt, Debug)] @@ -44,5 +60,5 @@ fn main() { let config = JoshutoConfig::get_config(); let keymap = JoshutoKeymap::get_config(); - joshuto::run(config, keymap); + run(config, keymap); } diff --git a/src/joshuto/preview.rs b/src/preview.rs index 11d97d5..d5ff4ca 100644 --- a/src/joshuto/preview.rs +++ b/src/preview.rs @@ -5,9 +5,9 @@ extern crate ncurses; use std::path::PathBuf; use std::process; -use joshuto::context::JoshutoContext; -use joshuto::ui; -use joshuto::window; +use context::JoshutoContext; +use ui; +use window; pub fn preview_file(context: &mut JoshutoContext) { /* diff --git a/src/joshuto.rs b/src/run.rs index 934a138..6f81c40 100644 --- a/src/joshuto.rs +++ b/src/run.rs @@ -1,32 +1,15 @@ extern crate ncurses; -pub mod config; - -mod commands; -mod context; -mod history; -mod preview; -mod sort; -mod structs; -mod tab; -mod textfield; -mod ui; -mod unix; -mod window; - use std::collections::HashMap; use std::time; -use self::commands::{CommandKeybind, JoshutoCommand}; -use self::config::{JoshutoMimetype, JoshutoPreview, JoshutoTheme}; -use self::context::JoshutoContext; -use self::window::JoshutoPanel; - -lazy_static! { - static ref theme_t: JoshutoTheme = JoshutoTheme::get_config(); - static ref mimetype_t: JoshutoMimetype = JoshutoMimetype::get_config(); - static ref preview_t: JoshutoPreview = JoshutoPreview::get_config(); -} +use commands; +use commands::{CommandKeybind, JoshutoCommand}; +use config; +use context::JoshutoContext; +use preview; +use ui; +use window::JoshutoPanel; fn recurse_get_keycommand<'a>( keymap: &'a HashMap<i32, CommandKeybind>, @@ -167,7 +150,7 @@ fn resize_handler(context: &mut JoshutoContext) { pub fn run(config_t: config::JoshutoConfig, keymap_t: config::JoshutoKeymap) { ui::init_ncurses(); - let mut context = context::JoshutoContext::new(config_t); + let mut context = JoshutoContext::new(config_t); commands::NewTab::new_tab(&mut context); ncurses::doupdate(); diff --git a/src/joshuto/sort.rs b/src/sort.rs index f6b92d6..9ae8778 100644 --- a/src/joshuto/sort.rs +++ b/src/sort.rs @@ -2,7 +2,7 @@ use std::cmp; use std::fs; use std::time; -use joshuto::structs; +use structs; #[derive(Debug, Clone)] pub struct SortOption { diff --git a/src/joshuto/structs.rs b/src/structs.rs index cc4e384..1743dc5 100644 --- a/src/joshuto/structs.rs +++ b/src/structs.rs @@ -3,8 +3,8 @@ use std::fs; use std::path::{Path, PathBuf}; use std::time; -use joshuto::sort; -use joshuto::window::JoshutoPageState; +use sort; +use window::JoshutoPageState; #[derive(Clone, Debug)] pub struct JoshutoMetadata { diff --git a/src/joshuto/tab.rs b/src/tab.rs index 25c1de9..c767cfa 100644 --- a/src/joshuto/tab.rs +++ b/src/tab.rs @@ -1,13 +1,13 @@ use std::path::PathBuf; -use joshuto::config; -use joshuto::history; -use joshuto::sort; -use joshuto::structs::JoshutoDirList; -use joshuto::ui; -use joshuto::window::{JoshutoPanel, JoshutoView}; - -use joshuto::theme_t; +use config; +use history; +use sort; +use structs::JoshutoDirList; +use ui; +use window::{JoshutoPanel, JoshutoView}; + +use theme_t; pub struct JoshutoTab { pub history: history::DirHistory, diff --git a/src/joshuto/textfield.rs b/src/textfield.rs index 3fa3fb4..503097f 100644 --- a/src/joshuto/textfield.rs +++ b/src/textfield.rs @@ -1,8 +1,8 @@ extern crate ncurses; extern crate unicode_width; -use joshuto::config::keymap; -use joshuto::window; +use config::keymap; +use window; pub struct JoshutoTextField { pub win: window::JoshutoPanel, diff --git a/src/joshuto/ui.rs b/src/ui.rs index 0b97ecf..997a243 100644 --- a/src/joshuto/ui.rs +++ b/src/ui.rs @@ -5,13 +5,13 @@ extern crate unicode_width; use std::fs; use std::time; -use joshuto::config::JoshutoColorTheme; -use joshuto::context::JoshutoContext; -use joshuto::structs; -use joshuto::unix; -use joshuto::window; +use config::JoshutoColorTheme; +use context::JoshutoContext; +use structs; +use unix; +use window; -use joshuto::theme_t; +use theme_t; pub const ERR_COLOR: i16 = 240; pub const EMPTY_COLOR: i16 = 241; diff --git a/src/joshuto/unix.rs b/src/unix.rs index f5e7f02..b7d228f 100644 --- a/src/joshuto/unix.rs +++ b/src/unix.rs @@ -4,7 +4,7 @@ extern crate ncurses; use std::path::{Path, PathBuf}; use std::process; -use joshuto::config::mimetype; +use config::mimetype; /* pub const fn is_reg(mode: u32) -> bool diff --git a/src/joshuto/window/mod.rs b/src/window/mod.rs index dcffe17..dcffe17 100644 --- a/src/joshuto/window/mod.rs +++ b/src/window/mod.rs diff --git a/src/joshuto/window/page_state.rs b/src/window/page_state.rs index 19967b2..19967b2 100644 --- a/src/joshuto/window/page_state.rs +++ b/src/window/page_state.rs diff --git a/src/joshuto/window/panel.rs b/src/window/panel.rs index d7eb272..65ab704 100644 --- a/src/joshuto/window/panel.rs +++ b/src/window/panel.rs @@ -1,7 +1,7 @@ extern crate ncurses; -use joshuto::structs; -use joshuto::ui; +use structs; +use ui; #[derive(Debug, Clone)] pub struct JoshutoPanel { diff --git a/src/joshuto/window/view.rs b/src/window/view.rs index 5153654..ead7f0d 100644 --- a/src/joshuto/window/view.rs +++ b/src/window/view.rs @@ -1,6 +1,6 @@ extern crate ncurses; -use joshuto::window::JoshutoPanel; +use window::JoshutoPanel; #[derive(Debug)] pub struct JoshutoView { |