News

.NET MAUI Community Tookit Update Adds TouchBehavior

A new feature in the .NET MAUI Community Toolkit allows developers to interact with any visual element in an app based on touch, mouse clicks and hover events.

The .NET MAUI Community Toolkit provides reusable components for building applications with .NET MAUI, the successor of Xamarin.Forms. By providing ready-made animations, behaviors, converters, effects and helpers, the toolkit simplifies typical development tasks for iOS, Android, macOS and WinUI applications.

TouchBehavior replaces the TouchEffect functionality found in Xamarin.Forms.

TouchBehavior
[Click on image for larger view.] TouchBehavior (source: Microsoft).

"The TouchBehavior implementation makes it possible to customize many different visual properties of the VisualElement that it is attached to such as the background color, opacity, rotation, and scale, as well as many other properties," the dev team said in a recent announcement of version 8. "Additionally, TouchBehavior makes it possible to implement long press touch gestures and enables you to invoke code whenever your user long presses any visual element in your app."

Along with that new feature, the team described a breaking change for the Snackbar on Windows and a new feature for Android navigation bar color.

Regarding the latter, the team said, "You can now color this bar on Android so that your app will feel even more immersive, and your theme is completely integrated with everything you see on screen."

The team also explained that this Android feature does not refer to what many people commonly think of as a navigation bar that typically appears at the top of a page, sporting the page title and possibly some toolbar items. Rather, it's the system navigation bar with the three buttons for going back a page, opening the multi-tasking view and going to the home screen on an Android device.

Going forward, the team is working on porting the CameraView over from Xamarin, to be released as a separate package.

"Furthermore we're working on improvements for MediaElement to bring deeper integration with the operating system like playing media from the lock screen and showing relevant metadata, and of course much more beyond that," the team said.

About the Author

David Ramel is an editor and writer for Converge360.

comments powered by Disqus

Featured

Subscribe on YouTube