rework storage paths a bit
This commit is contained in:
+2
-2
@@ -5,8 +5,8 @@ use crate::{
|
||||
ui_ext::UiExt,
|
||||
},
|
||||
util::consts::{
|
||||
APP_STORAGE_PATH,
|
||||
game::{EXE_ENHANCED, EXE_LEGACY},
|
||||
path,
|
||||
},
|
||||
};
|
||||
use eframe::egui;
|
||||
@@ -15,7 +15,7 @@ impl App {
|
||||
fn add_debug_viewport_contents(&mut self, ui: &mut egui::Ui) {
|
||||
ui.collapsing("misc", |ui| {
|
||||
if ui.button("open storage path").clicked() {
|
||||
open::that_detached(APP_STORAGE_PATH.as_path()).unwrap();
|
||||
open::that_detached(path::APP_STORAGE.as_path()).unwrap();
|
||||
}
|
||||
ui.checkbox(
|
||||
&mut self.meta.newer_version_available,
|
||||
|
||||
+2
-3
@@ -3,7 +3,7 @@ use crate::{
|
||||
app::{App, WINDOW_SIZE},
|
||||
tools,
|
||||
},
|
||||
util::{consts::APP_STORAGE_PATH, persistent_state::PersistentState, win},
|
||||
util::{consts::path, persistent_state::PersistentState, win},
|
||||
};
|
||||
use eframe::egui;
|
||||
use std::{
|
||||
@@ -13,11 +13,10 @@ use std::{
|
||||
};
|
||||
|
||||
fn panic_hook(panic_info: &std::panic::PanicHookInfo<'_>) {
|
||||
let log_path = APP_STORAGE_PATH.join("panic.log");
|
||||
let mut file = File::options()
|
||||
.create(true)
|
||||
.append(true)
|
||||
.open(log_path)
|
||||
.open(path::APP_ERROR.as_path())
|
||||
.unwrap();
|
||||
let timestamp = SystemTime::now()
|
||||
.duration_since(UNIX_EPOCH)
|
||||
|
||||
Reference in New Issue
Block a user