mirror of
https://github.com/ankitects/anki.git
synced 2025-09-23 16:26:40 -04:00

* Prepare to switch Rust import style * Run nightly format Closes #2320 * Clean up a few imports * Enable comment wrapping * Wrap comments
23 lines
733 B
Rust
23 lines
733 B
Rust
// Copyright: Ankitects Pty Ltd and contributors
|
|
// License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|
|
|
use crate::pb;
|
|
use crate::scheduler::states::PreviewState;
|
|
|
|
impl From<pb::scheduler::scheduling_state::Preview> for PreviewState {
|
|
fn from(state: pb::scheduler::scheduling_state::Preview) -> Self {
|
|
PreviewState {
|
|
scheduled_secs: state.scheduled_secs,
|
|
finished: state.finished,
|
|
}
|
|
}
|
|
}
|
|
|
|
impl From<PreviewState> for pb::scheduler::scheduling_state::Preview {
|
|
fn from(state: PreviewState) -> Self {
|
|
pb::scheduler::scheduling_state::Preview {
|
|
scheduled_secs: state.scheduled_secs,
|
|
finished: state.finished,
|
|
}
|
|
}
|
|
}
|