🏷️ Simplifica nombres de traits esenciales
Los traits `ExtensionTrait`, `ThemeTrait` y `ComponentTrait` pasan a ser `Extension`, `Theme`y `Component`, respectivamente,
This commit is contained in:
parent
ac0889cb8c
commit
bf3ea43b53
23 changed files with 78 additions and 79 deletions
|
@ -3,7 +3,7 @@ use crate::prelude::*;
|
|||
use crate::base::action::FnActionWithComponent;
|
||||
|
||||
/// Ejecuta [`FnActionWithComponent`] antes de que un tema renderice el componente.
|
||||
pub struct BeforeRender<C: ComponentTrait> {
|
||||
pub struct BeforeRender<C: Component> {
|
||||
f: FnActionWithComponent<C>,
|
||||
theme_type_id: Option<UniqueId>,
|
||||
referer_type_id: Option<UniqueId>,
|
||||
|
@ -11,7 +11,7 @@ pub struct BeforeRender<C: ComponentTrait> {
|
|||
|
||||
/// Filtro para despachar [`FnActionWithComponent`] antes de que un tema renderice el componente
|
||||
/// `C`.
|
||||
impl<C: ComponentTrait> ActionDispatcher for BeforeRender<C> {
|
||||
impl<C: Component> ActionDispatcher for BeforeRender<C> {
|
||||
/// Devuelve el identificador de tipo ([`UniqueId`]) del tema.
|
||||
fn theme_type_id(&self) -> Option<UniqueId> {
|
||||
self.theme_type_id
|
||||
|
@ -23,9 +23,9 @@ impl<C: ComponentTrait> ActionDispatcher for BeforeRender<C> {
|
|||
}
|
||||
}
|
||||
|
||||
impl<C: ComponentTrait> BeforeRender<C> {
|
||||
/// Permite [registrar](ExtensionTrait::actions) una nueva acción [`FnActionWithComponent`] para
|
||||
/// un tema dado.
|
||||
impl<C: Component> BeforeRender<C> {
|
||||
/// Permite [registrar](Extension::actions) una nueva acción [`FnActionWithComponent`] para un
|
||||
/// tema dado.
|
||||
pub fn new(theme: ThemeRef, f: FnActionWithComponent<C>) -> Self {
|
||||
BeforeRender {
|
||||
f,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue