In this release of Studio, public API were improved to make interaction with Studio more easy and more robust.
Based on the feedback we received in the Community we exposed couple of events for: Segment Split action, Segment Merged action. The full list of events will be presented in a separate section of this wiki.
To promote:
- Automation Testing we expose interfaces which will allow users to write Integration Tests by mocking common objects from the Integration API.
- Windows Presentation Foundation (WPF), plugins which have View Parts written using WPF now are recognized by Studio whithout using an Windows Forms Element Host.
Before starting to update your pluginsto support API Changes, please make sure the plugin is migrated correctly to Studio 2021. More information can be found here.
How to update plugins which have View Parts
In the bellow example we'll update the DSI VIewer plugin to support the latest chages in the Integration API. The view part of this plugin is written using WPF and is a great example which ilustrates how easy the View Parts can be recognized by Studio.
The source code of this plugin is open Source on our GitHub Repository.
Plugin architecture
Before the API Changes we had to create an Windows Forms Control which had an ElementHost control in which we added our WPF View.
After you change the references to point to Studio16 folder you'll see in Visual Studio following error:
Why this error appeared and how to fix it
First thing we need to do is to make the WPF View to Implement the IUIControl interface exposed by Studio.