Add plugin OSD control API#16
Open
xal3xhx wants to merge 26 commits intoprgmitchell:mainfrom
Open
Conversation
Remove hardcoded per-integration button action logic from targets.js and replace it with a plugin-driven resolution chain: per-target buttonActions > integration-level buttonActions > defaults. Plugins now declare their own actions in registerIntegration() and per-target in getTargetOptions(), so new integrations no longer require changes to the core app code. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Enable the tauri devtools feature and add support for opening the webview inspector via --devtools CLI flag or MIDIMASTER_DEVTOOLS=1 environment variable. Useful for plugin development and debugging. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- New plugin_show_osd / plugin_hide_osd Tauri commands with show_bar /
show_value flags so plugins can render text-only OSD cards.
- osd_settings_changed event emitted from apply_osd_settings so plugins
can react to OSD enable/anchor/monitor changes.
- Skip default volume_update / mute_update OSD emits for Integration
targets so a plugin fully owns the OSD for its own targets (no
duplicate cards). Slider sync is preserved via set_binding_feedback.
- plugin_host: ctx.osd.{showVolume, showMute, hide, getSettings,
onSettingsChanged}.
- osd feature: showVolumeOsd / showMuteOsd honor opts.showBar and
opts.showValue for text-only rendering.
- Docs updated (section 6.6, existing sections renumbered).
Owner
|
This PR has bugs, a few I immediately noticed when testing:
There may be others but after those I stopped testing |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ctx.osdnamespace lets plugins render OSD cards directly:showVolume,showMute,hide,getSettings,onSettingsChanged.plugin_show_osd,plugin_hide_osd) that handle window show + topmost + emit, respecting the user's global OSD toggle.opts.showBar/opts.showValue(both defaulttrue) for text-only status cards.volume_update/mute_updateOSD emit so a plugin fully owns the OSD for its own targets (no duplicate cards). Slider sync is preserved viaset_binding_feedback.PLUGIN_DEVELOPER_GUIDE.md, existing sections renumbered.Test plan
cargo tauri dev) and reload frontend.opts.showBar: false, showValue: falseproduces a text-only card.data.label).ctx.osd.hide()clears active cards.ctx.osd.onSettingsChangedfires.