Commit graph

24 commits

Author SHA1 Message Date
Olivier Goffart
81b63c3b3f Small reformating fix 2021-02-12 09:56:37 +01:00
Simon Hausmann
d5e72b255a Fix build when structures contain models
The generated code for structs includes #[derive(Debug)],
which requires Debug for all fields. When the field is a ModelHandle
it's up to us to provide an implementation.
2021-01-25 14:20:13 +01:00
Olivier Goffart
dfa25b96f7 Rename SharedArray to SharedVector 2020-12-18 10:26:07 +01:00
Simon Hausmann
bdebb77f14 Implement Iterator for the Model in Rust 2020-12-02 12:04:32 +01:00
Simon Hausmann
276bcd6574 Implement Model for ModelHandle
This makes extracting model data out of .60 files a little easier
2020-12-01 16:14:43 +01:00
Olivier Goffart
8a64f10e84 Remove ComponentVtable::input_event
And the custom handling of the mouse grabber
2020-11-24 16:23:37 +01:00
Olivier Goffart
3f111ecd30 Fix a few doc typo 2020-11-23 11:47:16 +01:00
Simon Hausmann
89e0b57627 Rework and simplify the focus handling
Instead of determining the focus item through item tree traversal and
pointer comparison and storing the intermediate indices in the
components in the tree, remember the focus item by a pair of
VWeak<ComponentVTable, Dyn> and item_index: usize.

This speeds up determining the focus item as well as delivering events,
which can now be done directly after retrieving an ItemRef with
get_item_ref.

This also fixes the duplicate line edit focus in the 7gui cells
test case.
2020-11-20 15:33:15 +01:00
Olivier Goffart
af801b9879 Use the new get_item_ref function instead of visiting the root 2020-11-11 15:04:49 +01:00
Olivier Goffart
a1f1fcb3a6 Use VRc<ComponentVTable> in the rust generated code 2020-11-09 14:58:37 +01:00
Olivier Goffart
2ece3817cc Make ModelHandle a struct
Last commit broke for structures containing models, because models are not PartialEq.
So we need to implement PartialEq for ModelHandle. Which means a struct needs to
be created
2020-10-31 13:32:19 +01:00
Olivier Goffart
d2255327fe Properties: make sure that the falue is different before marking all dependencies dirty
Fix the animation of the gauge in the printer demo
2020-10-31 12:58:11 +01:00
Olivier Goffart
d339ead5dd support for within box layouts
Only rust implementation for now
2020-10-30 19:12:48 +01:00
Olivier Goffart
5face45c51 Rename Component::compute_layout to apply_layout
And pass the expected rectangle.
This is currently not used yet but will be needed when we can have
repeated elements within a box layout
2020-10-29 19:08:52 +01:00
Olivier Goffart
9f08492258 Make sure that the ListView is not scrolled when there is enough room for all contents
Fixes #93
2020-10-21 09:47:33 +02:00
Olivier Goffart
14198052ac ArrayModel support in JS 2020-10-17 13:33:22 +02:00
Olivier Goffart
58193ff1c3 Fix resizing of listview should recompute the layout 2020-10-16 11:09:12 +02:00
Olivier Goffart
4169254169 StandardListView in rust 2020-10-08 16:22:16 +02:00
Olivier Goffart
3bdd71b36f Start working on the Native ListView
Currently only the interpret part
2020-10-08 15:51:33 +02:00
Olivier Goffart
2314e59ab2 Refactor the repeater in the interpreter
Use the same Repeater as the rust backend
2020-10-02 21:26:47 +02:00
Olivier Goffart
1b506a1b03 Move ther model code from the rust API to the corelib
We will need it in the dynamic component
2020-10-02 18:11:35 +02:00
Olivier Goffart
58cdaeb8dd Update license header to mention that commertial option are available 2020-08-26 13:23:42 +02:00
Simon Hausmann
2823f32692 Apply license headers to all non-binary/non-json sources 2020-08-17 17:55:20 +02:00
Simon Hausmann
df4e837b04 Move model placeholder module out of abi 2020-08-04 08:27:34 +02:00
Renamed from sixtyfps_runtime/corelib/abi/model.rs (Browse further)