What I ended up doing was to move the CommandBinding
from the UserControl.Resources
to the TextBlock
:
<TextBlock ...>
<TextBlock.CommandBindings>
<CommandBinding CanExecute="ShowDiagnostics_CanExecute" Command="cs:CarSystemCommands.ShowDiagnostics" Executed="ShowDiagnostics_Executed" />
</TextBlock.CommandBindings>
</TextBlock>
Now, nothing happens until you hold down the shift key & right double click on the TextBlock
.
I gave the other answers up votes because they'll work, too.