当AllowsTransparency为True且WindowStyle为None时,无法显示上下文菜单(从XBAP调用窗口) [英] Context Menu can not be shown when AllowsTransparency is True and WindowStyle is None (The window is called from XBAP)

查看:404
本文介绍了当AllowsTransparency为True且WindowStyle为None时,无法显示上下文菜单(从XBAP调用窗口)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我创建了一个简单的完全信任XBAP应用程序来复制此问题.
在此应用程序中,当我单击一个按钮时,它将打开一个WPF窗口,AllowsTransparencey属性为true,WindowStyle为None.
如果正在打开的WPF窗口中有一个ContextMenu,似乎无法显示它.

I created a simple Full Trust XBAP application to replicate this issue.
In this application when I click a button, it will open a WPF Window, the AllowsTransparencey property is true and WindowStyle is None.
If in the WPF window that is being opened there is a ContextMenu, seems that it cannot be displayed.

我的操作系统是Windows 7 64位,并且正在使用.NET Framework 4.

My OS is Windows 7 64 bit and I'm using .NET Framework 4.

这是完全信任" XBAP应用程序的代码,非常简单:

This is the code of the Full Trust XBAP Application, it's very simple:

 


<Page x:Class="WindowXBAP.Page1"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
      mc:Ignorable="d" 
      Title="Page1">
    <Grid>
        <Button Content="Launch Window" Click="LaunchWindow" Height="35" Width="150" />
    </Grid>
</Page>

推荐答案

这听起来像是关于图层的非常老的问题.

This sounds like a very old issue regarding layers.

 

我收集了安装修补程序:WindowsXP-KB943326-x86-ENU.exe并且KB968537应该为您修复它?

I gather installing hot fix : WindowsXP-KB943326-x86-ENU.exe   and  KB968537  should fix it for you?

 

此致,
佩德罗(Pedro)

Regards,
Pedro


这篇关于当AllowsTransparency为True且WindowStyle为None时,无法显示上下文菜单(从XBAP调用窗口)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆