Full split of lang.rs

This commit is contained in:
micialware committed 2026-08-24 11:35:37 +03:00
1 parent 22b455a640
commit c67663141f
17 files changed
+81 -78

No files matched your search

+4 -3
View File
@@ -1,5 +1,4 @@
use crate::data_provider::history::{get_history_of_set, HistoryItem};
use crate::lang::{WordData, INVALID_ID};
use crate::data_provider::history::{get_history_of_set};
use crate::navigation::*;
use crate::styling::*;
use chrono::Local;
@@ -11,6 +10,8 @@ use parking_lot::Mutex;
use std::sync::Arc;
use HistoryMessage::Back;
use crate::app::AppState;
use crate::data::entities::{HistoryItem, WordData};
use crate::data::INVALID_ID;
#[derive(Clone)]
pub struct HistoryState {
@@ -47,7 +48,7 @@ impl NavigatedPage<HistoryMessage> for HistoryState {
}
impl HistoryState {
pub fn new(id: crate::lang::Id, state: Arc<Mutex<AppState>>) -> Self {
pub fn new(id: crate::data::Id, state: Arc<Mutex<AppState>>) -> Self {
let state = state.lock();
let history = get_history_of_set(id).unwrap_or_default();
let words = history