ContextMenuService.ShowOnDisabled Propriedade Anexada

Definição

Obtém ou define um valor que indica se o ContextMenu deve ser mostrado quando o seu pai está a cinzento.

see GetShowOnDisabled, and SetShowOnDisabled
see GetShowOnDisabled, and SetShowOnDisabled
see GetShowOnDisabled, and SetShowOnDisabled

Exemplos

Este exemplo cria e apresenta um ContextMenu num botão desativado.

<Button Height="30" Content="Disabled Button" IsEnabled="False" 
        ContextMenuService.ShowOnDisabled="True">
  <Button.ContextMenu>
    <ContextMenu>
      <MenuItem Header="Edit">
        <MenuItem Header="Cut"/>
        <MenuItem Header="Copy"/>
        <MenuItem Header="Paste"/>
        <Separator/>
        <MenuItem Header="Context Menu item with ToolTip">
          <MenuItem.ToolTip>
            <ToolTip>
              Some information.
            </ToolTip>
          </MenuItem.ToolTip>
        </MenuItem>
      </MenuItem>
    </ContextMenu>
  </Button.ContextMenu>
</Button>

Observações

Informação de Propriedade de Dependência

Iteme Value
Campo identificador ShowOnDisabledProperty
Propriedades dos metadados definidas como true None

Aplica-se a

Ver também