Move the reconciler into the lifecycle crate, so that we can (properly) support state changes. Wrap the reconciliation phase in a RenderEngine, which root-level objects (windows, etc) can subscribe to and interface with. Migrate a few things relating to themes out of alchemy core and into styles, because the reconciliation phase requires them and they fit well enough there... solving a circular dependency.
This commit is contained in:
parent
f1cb5fea93
commit
6833e39d52
16 changed files with 57 additions and 1098 deletions
|
|
@ -2,14 +2,42 @@
|
|||
//! Flexbox in Alchemy. For all intents and purposes, you can essentially consider
|
||||
//! this to be the root crate for Alchemy, as just about everything ends up using it.
|
||||
|
||||
// We hoist this for ease of use in other crates, since... well, pretty much
|
||||
// every other crate in the project imports this already.
|
||||
pub use lazy_static::lazy_static;
|
||||
|
||||
#[cfg(feature="parser")]
|
||||
#[macro_use] pub extern crate cssparser;
|
||||
|
||||
mod stretch;
|
||||
pub use stretch::{geometry, node, number, result, Stretch, Error};
|
||||
pub use stretch::result::Layout;
|
||||
|
||||
pub mod color;
|
||||
pub use color::Color;
|
||||
|
||||
mod engine;
|
||||
use engine::ThemeEngine;
|
||||
|
||||
mod spacedlist;
|
||||
pub use spacedlist::SpacedList;
|
||||
|
||||
mod spacedset;
|
||||
pub use spacedset::SpacedSet;
|
||||
|
||||
mod style_keys;
|
||||
pub use style_keys::StyleKey;
|
||||
pub type StylesList = SpacedSet<StyleKey>;
|
||||
|
||||
pub mod styles;
|
||||
pub use styles::{Style, Styles};
|
||||
|
||||
pub mod stylesheet;
|
||||
pub use stylesheet::StyleSheet;
|
||||
|
||||
#[cfg(feature="parser")]
|
||||
pub mod styles_parser;
|
||||
|
||||
lazy_static! {
|
||||
pub static ref THEME_ENGINE: ThemeEngine = ThemeEngine::new();
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue