pub struct TableOperations {
pub groups: Vec<Vec<Box<dyn TableOperation>>>,
pub pending_tracker: HashSet<(usize, usize), RandomState>,
pub last_tick: u64,
}Expand description
Coordinates grouped sequences of toolbar actions, polling systems, and error dialogs.
Fields§
§groups: Vec<Vec<Box<dyn TableOperation>>>§pending_tracker: HashSet<(usize, usize), RandomState>§last_tick: u64Implementations§
Source§impl TableOperations
impl TableOperations
pub fn new() -> Self
pub fn with_group(self, group: Vec<Box<dyn TableOperation>>) -> Self
pub fn with_operation(self, op: impl TableOperation + 'static) -> Self
Sourcepub fn update(&mut self, ctx: &Context) -> bool
pub fn update(&mut self, ctx: &Context) -> bool
Evaluates state transitions exactly once per unique frame tick.
Returns true if any completed operation requested a view refresh.
Sourcepub fn gui(
&mut self,
ui: &mut Ui,
provider: &dyn TableProvider,
data: &mut TableState,
context_menu: bool,
) -> Result<bool, TableError>
pub fn gui( &mut self, ui: &mut Ui, provider: &dyn TableProvider, data: &mut TableState, context_menu: bool, ) -> Result<bool, TableError>
Renders standard table operation buttons with default look.
Sourcepub fn gui_custom<F>(
&mut self,
ui: &mut Ui,
provider: &dyn TableProvider,
data: &mut TableState,
context_menu: bool,
button_renderer: F,
) -> Result<bool, TableError>
pub fn gui_custom<F>( &mut self, ui: &mut Ui, provider: &dyn TableProvider, data: &mut TableState, context_menu: bool, button_renderer: F, ) -> Result<bool, TableError>
Renders table operations using a custom button builder callback.
This handles all the state machine details (polling, execution, pending modes, group separation) but allows full control over the visual presentation of each button.
Sourcepub fn show_group<F>(
&mut self,
ui: &mut Ui,
provider: &dyn TableProvider,
data: &mut TableState,
group_idx: usize,
context_menu: bool,
button_renderer: F,
) -> Result<bool, TableError>
pub fn show_group<F>( &mut self, ui: &mut Ui, provider: &dyn TableProvider, data: &mut TableState, group_idx: usize, context_menu: bool, button_renderer: F, ) -> Result<bool, TableError>
Renders all operations in a specific group. This is useful for building custom caller layouts, submenus, and advanced structural separations.
Sourcepub fn show_operation<F>(
&mut self,
ui: &mut Ui,
provider: &dyn TableProvider,
data: &mut TableState,
group_idx: usize,
op_idx: usize,
context_menu: bool,
button_renderer: F,
) -> Result<bool, TableError>
pub fn show_operation<F>( &mut self, ui: &mut Ui, provider: &dyn TableProvider, data: &mut TableState, group_idx: usize, op_idx: usize, context_menu: bool, button_renderer: F, ) -> Result<bool, TableError>
Renders a single operation directly at a specific group and operation index. Gives the caller total control over fine-grained placement and visual arrangement.
Trait Implementations§
Source§impl Debug for TableOperations
impl Debug for TableOperations
Source§impl Default for TableOperations
impl Default for TableOperations
Source§fn default() -> TableOperations
fn default() -> TableOperations
Auto Trait Implementations§
impl !RefUnwindSafe for TableOperations
impl !UnwindSafe for TableOperations
impl Freeze for TableOperations
impl Send for TableOperations
impl Sync for TableOperations
impl Unpin for TableOperations
impl UnsafeUnpin for TableOperations
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more