Migrated some files to new LANG system

This commit is contained in:
2026-03-05 10:05:14 +01:00
parent ce8c58a5e3
commit 4bb7262171
9 changed files with 176 additions and 182 deletions
-39
View File
@@ -59,43 +59,4 @@ macro_rules! warnln {
format!($($arg)*)
);
};
}
#[macro_export]
macro_rules! lang {
($key:expr) => {
{
/*use $crate::{LANG, errln};
let value = unsafe {
LANG
.as_ref()
.expect("LANG must be initialized before use")
.get($key)
};
if value.is_none() { errln!("Key not found in LANG JSON: \"{}\"", $key); }
value.unwrap().as_str().expect("LANG JSON value is not a string!").to_string()*/
"hello".to_string()
}
};
($key:expr, $($arg:expr),*) => {{
/*use $crate::{LANG, errln};
use formatx::formatx;
let value = unsafe {
LANG
.as_ref()
.expect("LANG must be initialized before use")
.get($key)
};
if value.is_none() { errln!("Key not found in LANG JSON: \"{}\"", $key); }
let format_str = value.unwrap().as_str().expect("LANG JSON value is not a string!");
formatx!(format_str, $($arg),*).unwrap()*/
"hello".to_string()
}};
}