OpenMacroBoard / StreamDeckSharp

A simple .NET wrapper for Stream Deck
MIT License
351 stars 47 forks source link

Remember brightness if disconnected and set again if the device reconnects #26

Closed wischi-chr closed 3 years ago

wischi-chr commented 3 years ago

Since streamdecksharp 3.0 it's possible to wrap a board with the extension method IMacroBoard.WithDisconnectReplay() to create a deck reference that does that.

Example:

using var deck = StreamDeck.OpenDevice().WithDisconnectReplay();
// use deck here.
// 1. Set brightness and some key images
// 2. disconnect deck usb connection
// 3. reconnect deck
// 4. images and brightness are automatically set again