-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhooks.rs
More file actions
22 lines (19 loc) · 942 Bytes
/
Copy pathhooks.rs
File metadata and controls
22 lines (19 loc) · 942 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at https://mozilla.org/MPL/2.0/.
//
// Copyright (c) 2024-2026 TripleACS Pty Ltd t/a 2pi Software
//! Result types for tree menu action invocations.
//!
//! Menu actions are now registered via `register_menu()` and stored in
//! [`SchemaRegistry`](super::schema::SchemaRegistry). This module provides the
//! result type returned by `invoke_tree_action_hook`.
use crate::core::save_transaction::SaveTransaction;
/// Return value from `invoke_tree_action_hook`.
#[derive(Debug, Default)]
pub struct TreeActionResult {
/// If the closure returned an array of IDs, they are placed here (reorder path).
pub reorder: Option<Vec<String>>,
/// Gated notes queued via `create_child` / `set_title` / `set_field` / `commit()`.
pub transaction: SaveTransaction,
}