问题:
每当我尝试在调试器中断开或设置跟踪点时,我们的应用程序和visual studio都会完全冻结.分离调试器后,应用程序继续.
这个问题可能与WPF有关.我们已将WinForm应用程序迁移到WPF.从那以后出现这个问题.但我无法找到导致问题的代码的特定部分.我已经回滚了数百次提交但没有成功.
它也可能与UI线程有关.如果断点设置在远离UI逻辑的某个地方,则应用程序不会冻结,也不会像在UI线程中那样经常冻结.
[ 编辑: ]我在Visual Studio 2010中使用Windows 7. 64位
[ 更新: ]
当Visual Studio挂起,并且我在断点显示之前尝试分离时,消息"无法从一个或多个进程中分离.所有未完成的功能都未完成".但是我已经在调试选项中禁用了所有func评估.我认为我的问题是由无法完成的func_evaluation或者超时的func_evaluation引起的.
有没有办法看到哪个func_evaluation视觉工作室挂起?
例:
class SomeUiViewPresenterExample
{
private Timer m_Timer;
public void Init()
{
m_Timer = new Timer();
m_Timer.Elapsed += ElapsedFoo();
m_Timer.AutoReset = false;
m_Timer.Interval = 200;
}
private void ElapsedFoo(object sender, ElapsedEventArgs elapsedEventArgs)
{
// there is no code inside this method
// On the next line a trace point with "---> ElapsedFoo called" will freeze the debugger
}
Run Code Online (Sandbox Code Playgroud)
我已经尝试过:(没有成功)
我有一个自定义的 WPF 下拉框。一切都按预期工作,但是当组合框获得焦点时,组合框项目周围会出现虚线边框。我怎样才能摆脱这个边界?

我试图覆盖“FocusVisualStyle”
<Style TargetType="{x:Type ComboBox}">
....snip
<Setter Property="ItemContainerStyle">
<Setter.Value>
<Style TargetType="{x:Type ComboBoxItem}">
<Setter Property="FocusVisualStyle" Value="{x:Null}"/>
</Style>
</Setter.Value>
</Setter>
</Style>
Run Code Online (Sandbox Code Playgroud)
我不确定这个边界从哪里来以及如何消除它。
感谢您的想法和提示