323 Commits

Author SHA1 Message Date
e9278ec813
Derived and Memo now use EffectRun instead of implementing Fn(). 2025-04-30 06:59:01 +01:00
1f0b3c6ec7
Effect now uses a custom trait EffectRun instead of relying on Fn(). 2025-04-30 06:57:44 +01:00
f3526737be
IMut::{read, write} are now track_caller. 2025-04-30 06:46:16 +01:00
34d1cc7c29
Added primitives for borrowing a signal without gathering or updating dependencies. 2025-04-30 06:27:09 +01:00
ba0fa2dde0
Effect now keeps it's dependencies in debug releases for debugging. 2025-04-30 06:14:07 +01:00
564469c9c2
Trigger and WeakTrigger now implement PartialEq, Eq and Hash. 2025-04-30 06:11:31 +01:00
4c6eb8dd01
Improved Debug representation of all types in dynatos-reactive. 2025-04-30 06:04:54 +01:00
7c6f6bede3
Effect's Debug impl now shows some fields. 2025-04-30 05:39:18 +01:00
dbeda6d4b0
Fixed AsyncSignal only triggering the subscriber that started loading. 2025-04-25 17:52:36 +01:00
864b1c4a77
Added _raw methods to access the inner values without loading to AsyncSignal and LoadableSignal. 2025-04-25 17:21:52 +01:00
6523e43a11
AsyncSignal and LoadableSignal now support mutable access. 2025-04-25 17:15:05 +01:00
0ca6b58224
Renamed ContextStackOpaque::Handle to OpaqueHandle. 2025-04-20 18:08:44 +01:00
2b4185c55c
Opaque handles now store the type id themselves. 2025-04-20 18:06:23 +01:00
18013bb675
Separated the opaque parts of ContextStack into ContextStackOpaque 2025-04-20 18:00:43 +01:00
6aae04d3f3
ContextStack no longer exposes (most) implementation details. 2025-04-20 17:47:37 +01:00
2ab423586a
ContextStack is now parameterized by type, allowing for more efficient context storage in the future. 2025-04-20 00:07:55 +01:00
97b808123f
Added a test for opaque handles. 2025-04-20 00:07:54 +01:00
28818e766f
dynatos-context is now parametrized by a world. 2025-04-19 23:51:43 +01:00
c7e65f9308
Fixed dynatos-world failing to compile if no other crate enabled features of derive_more. 2025-04-19 23:44:49 +01:00
5e3bddfb27
Renamed World::{RC, IM} and ReactiveWorld::EF to more explicit names. 2025-04-19 21:52:45 +01:00
a3d54fb1e7
Moved World::{RC, IM} to it's own crate. 2025-04-19 21:51:27 +01:00
db7041df89
dynatos_reactive::*::new now always uses the default world.
Added `new_in` constructors for everything in `dynatos_reactive` to use other worlds.
2025-04-16 15:50:23 +01:00
cccc82210a
All types in dynatos-reactive now have a type parameter for their backend, instead of it being selected with features. 2025-04-16 15:34:45 +01:00
2e42f92e5f
Added dynatos_html::ev::WheelEvent. 2025-04-15 12:20:54 +01:00
702b94db48
Updated all dependencies. 2025-04-14 17:14:08 +01:00
d5c08efb8e
Updated to rustc 1.88.0-nightly (0fe8f3454 2025-04-10). 2025-04-14 16:56:40 +01:00
6a1011f0ad
Merged dynatos-reactive-async into dynatos-reactive. 2025-01-26 04:32:53 +00:00
8dcffe7676
AsyncSignal no longer polls futures manually through the reactive system. 2025-01-26 04:30:18 +00:00
5a399e663c
Fixed typo. 2025-01-26 02:43:20 +00:00
75f97793f8
Updated to rustc 1.86.0-nightly (99768c80a 2025-01-23). 2025-01-26 02:42:15 +00:00
08ce16ab43
Added async fn support for builder. 2025-01-25 05:42:43 +00:00
775a105501
Added missing track_caller for EguiEffect::new. 2025-01-09 08:50:02 +00:00
84c296a325
Added missing track_caller for Effect::new_raw. 2025-01-09 08:49:16 +00:00
55af4a5f11
Moved AsyncSignal into it's own crate. 2024-12-28 07:17:18 +00:00
7398a7e34c
Introduced experimental support for egui. 2024-12-28 07:11:42 +00:00
e8a1334288
dynatos-reactive-sync now requires send_guard feature of parking_lot. 2024-12-28 07:03:45 +00:00
c08b71e14f
AsyncSignal now stores the value inside of an IMut<Option<T>>.
This avoids some issues when initializing, and makes it so we can reset the value later.
2024-12-28 05:07:41 +00:00
1c93044e21
Removed unsafe from bench. 2024-12-28 04:53:06 +00:00
f442fa6d83
Fixed safety comment being on the wrong statement. 2024-12-28 04:38:01 +00:00
059295cd67
Merged AsyncSignal's loader waker into InnerLoader.
This reduces the number of locks and prevents a timing issue where it was possible for the loader to be updated before the waker registered, making the waiter hang forever.
2024-12-25 19:32:42 +00:00
15c11ea98e
Trigger now allows using it as a waker.
`AsyncSignal` now uses `Trigger` as a waker if `sync` is enabled.
2024-12-23 22:31:38 +00:00
b2e3c31b77
Fixed trigger::test::basic test failing due to hash impl.
Although most pointers are hashed the same, fat pointers are hashed with their metadata, so when hashing an `Effect<dyn ...>` this could cause problems if the metadata were different.
2024-12-23 19:42:03 +00:00
8ad23fe09a
AsyncSignal now keeps a loader instead of just a future.
This allows a nicer interface in relation to stopping / restarting the loading.
2024-12-23 18:53:20 +00:00
d4497e1935
AsyncSignal now keeps track if the it's loading. 2024-12-22 18:52:52 +00:00
33d480aa3e
AsyncSignal now keeps track if the future has been polled. 2024-12-22 18:33:58 +00:00
8b936d8f1d
Fixed AsyncSignal sometimes not triggering when values were loaded. 2024-12-22 18:28:42 +00:00
575dc5be17
Fixed AsyncSignal sometimes polling the future after being finished.
`AsyncSignal` and `LoadableSignal` no longer support mutable access.

This change fixes the mentioned bug and allows us to be more efficient by removing locks.
2024-12-22 18:25:13 +00:00
95103a9ad9
Moved suspended support from LoadableSignal to AsyncSignal. 2024-12-22 17:58:40 +00:00
a638ff10f1
Added {AsyncSignal, LoadableSignal}::load. 2024-12-22 17:48:24 +00:00
a12ef68a21
LoadableSignal now allows suspending the loading. 2024-12-22 17:08:18 +00:00