diff options
author | David Karlaš <david.karlas@xamarin.com> | 2015-02-05 19:11:25 +0300 |
---|---|---|
committer | David Karlaš <david.karlas@xamarin.com> | 2015-02-05 19:11:25 +0300 |
commit | 3422508bd8167451275bfdb423f2dd543d958d3e (patch) | |
tree | e62f588948f12b6280229aa353f76758c431d940 /main | |
parent | 4210cb99d6915dc75a431c0e5907a617437348bc (diff) |
[Debugger] Fixing NRE when there is no default value visualizer
Diffstat (limited to 'main')
-rw-r--r-- | main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger.Visualizer/ValueVisualizerDialog.cs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger.Visualizer/ValueVisualizerDialog.cs b/main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger.Visualizer/ValueVisualizerDialog.cs index c81a76e95f..37d36b59ed 100644 --- a/main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger.Visualizer/ValueVisualizerDialog.cs +++ b/main/src/addins/MonoDevelop.Debugger/MonoDevelop.Debugger.Visualizer/ValueVisualizerDialog.cs @@ -67,7 +67,11 @@ namespace MonoDevelop.Debugger.Viewers button.Show (); } - defaultVis.Click (); + if (defaultVis != null) + defaultVis.Click (); + else if (buttons.Count > 0) + buttons [0].Click (); + if (val.IsReadOnly || !visualizers.Any (v => v.CanEdit (val))) { buttonCancel.Label = Gtk.Stock.Close; buttonSave.Hide (); |