New in version 0.26.0

Released one year ago

Please remember to uno clean your projects after upgrading Fuse.

Highlights
  • Lots of new features for working with Observables
  • New Selection API
  • Custom map markers
  • New, highly performant Shadow tag, which can often replace the slower DropShadow
  • A number of bug fixes dealing with anything from crashes to statusbars that just wouldn't take no for an answer!
  • The inspector has been retired.
Observable improvements
  • Added .addAll(), .insertAll() and .removeRange() for faster list manipulation
  • Fixed bugs in .where() and .count() dealing incorrectly with some operations
  • .where() and .count() now supports objects as filters, e.g. list.where({id: 4})
  • Added .any( [criteria] ) which returns an observable boolean of whether the observable contains an object that meets the criteria.
  • Added .first( [criteria] ) and .last( [criteria] ) which returns an observable of the first/last item that meets the criteria, or simply the first/last element if the criteria is omited.
  • Added .identity(), .pick() and .flatMap()
New Observable.inner() superpowers to ease two-way bindings on ux:Property
  • Two-way data bindings are an experimental feature and their exact form and syntax may still change significantly.
  • On observables returned by .inner(): support for .twoWayMap() to ease construction of components with two-way bindable properties. For example usage, see https://github.com/Duckers/FusePlayground/tree/master/Components/DateEditor
  • On observables returned by .inner(): support for .setInnerValue() which sets the value of the inner observable without sending a message back to the observable returned by .inner(). When creating a component with a two-way bindable property, this should be used to notify users of the component that a property has been changed from within the component, typically driven by user interaction.
  • Fixed initial value race condition in implicit observables for ux:Property causing unpredictable behavior
  • BREAKING CHANGE: An ux:Property of a class type (e.g. object or Brush) with value null in Uno will now produce an empty observable Observable() instead of Observable(null) in JavaScript. This prevents a lot of annoying scenarios where e.g. map() will unexpectedly map null instead of a real value (often leading to crash). When the Uno side is null, obs.value will now be undefined (as the observable is empty, length=0). This might have backwards incompatible side effects if you relied on null being set.
Selection
  • Added the Selection API, comprising Selection, WhileSelected, ToggleSelection, Selectable, Selected, and Deselected. As this is a new feature the API may still undergo some minor changes in the upcoming releases.
  • You can check out this pizza ordering example to learn more. (Mmmmm pizza!)
Inspector removed

The Inspector was intended as a proof-of-concept and testing ground for some of our ideas around visual tooling. It has now overstayed its welcome, been a fairly low priority for a while (and contained a few long-lived bugs) so we finally decided to remove it. We will however take what we learned from it and be back with much cooler visual tools in the future! :)

New ScrollView features
  • Added Scrolled and WhileScrolled triggers which respond to scrolling within a region of the ScrollView. These provide more flexibility e.g. for dynamically loading more data in an infinite feed (compared to WhileScrollable).
  • Added LayoutRole="Placeholder" to create items that are part of a ScrollView or Navigation's layout but not a logical item (like page, or scroll anchor). This is an experimental feature and it's behaviour may change in future releases.
LayoutParams
  • DeriveClone renamed CloneAndDerive and TrueClone renamed Clone to help avoid confusion about what they do.
LinearRangeBehavior
  • Added LinearRangeBehavior.Orientation to allow vertical range controls
WhileNavigating
  • WhileNavigating changed to a WhileTrigger to add Invert functionality
  • Fixed issue so WhileNavigating now finds ancestor navigation
Fuse.Maps
  • MapMarker now has an IconFile attribute, letting you specify a file asset to replace the marker icon graphic.
  • Added IconAnchorX and IconAnchorY attributes to MapMarker. These are normalized coordinates from 0,0 to 1,1 determining the point on the icon graphic where it rests on the map. This defaults to 0.5, 0.5, being centered.
  • Fixed an issue that caused a crash on iOS when used together with FuseJS/GeoLocation package
GeoLocation
  • Improved the iOS implementation of GeoLocation. The most significant changes are that getLocation now respects its timeout parameter, and that multiple concurrent calls to getLocation are handled gracefully.
  • Fixed issue where location fetch requests on Android would run on the wrong thread
Each/Match/Deferred
  • Fixed some issues to ensure the resulting children order matches the logical UX order of Each Match and Deferred. This affects code where these triggers are used directly inside each other without an intervening Panel (adding that Panel was the previous workaround).
  • Fixed an issue where the content in an Deferred was not removed while unrooting the Deferred
Select/With
  • The previous reactive Select trigger has been renamed With to better reflect what it does and not cause confusion with the selection API.
WhileString
  • Added WhileString, a WhileTrigger that tests conditions on a string value.
V8
  • Optimise string handling by avoiding needless conversions back and forth to UTF-8.
Native views
  • Images inside <NativeViewHost /> can now have URL-sources with <Image Url="..." />
Fuse.Reactive
  • Fixed a crash due to unhandled types passed to the JavaScript VM.
  • Fixed a crash while trying to re-bind data-bindings on unrooted nodes.
  • Fixed a bug where databinding to outer data contexts often failed due to a race-condition
FileSystem
  • Fix problem getting dataDirectory and cacheDirectory while running with fuse preview
Shadow
  • Added a Shadow-tag that is generally a faster alternative to DropShadow. It works by approximating the background of a rectangle by applying a gradient on the distance field of a rectangle instead. This only works well for rectangles and panels, but has a Mode-property that can be set to PerPixel (instead of it's default, Background) to get the same effect as with DropShadow.
Android.StatusBarConfig
  • Fixed a bug, where setting IsVisible on Android.StatusBarConfig accidentally also had effect on iOS.
  • Fixed Android issue where the StatusBar visibility would be reset whenever the softkeyboard is onscreen. The visibility is restored when the keyboard is dismissed

AlternativeRoot

  • The content of AlternativeRoot can now be any class that inherits from Node, not just a Visual.
Input Handling
  • Fixed a crash due to a null-pointer reference while handling input-events
Xcode project generation
  • We now add the directory of Required Xcode.Frameworks and Xcode.EmbeddedFrameworks to Xcode.FrameworkDirectory, meaning that Xcode.FrameworkDirectory will rarely be necessary to use.
PushNotification
  • Fixed marshalling of GCM push notifications, caused by change in protocol
Fuse.Physics
  • Moved declaration of attached property Friction from Fuse.Physics.Body to Fuse.Physics.BodyAttr. No UX changes are required.
Fuse.Elements
  • Moved declaration of attached properties LayoutMaster and ResetLayoutMaster from Fuse.Elements.LayoutMasterBoxSizing to Fuse.Elements.LayoutMasterAttr. No UX changes are required.
  • Element.OnDraw has slightly changed meaning. It used do draw both the element itself and it's children (which was implemented in the base-class). Now it just draws the element itself. Instead, we have a new method called Element.DrawWithChildren that will call Element.OnDraw and then draw the children. This was done to accomedate Layer.Underlay, which required the base-class to draw some things both before and after the element itself was drawn. If you want to avoid drawing the children under some circumstances, override this method instead of Element.OnDraw.