diff options
author | 2011-01-26 23:30:19 +0000 | |
---|---|---|
committer | 2011-01-26 23:30:19 +0000 | |
commit | 6a6b99060e1b13cc5b9ebe394137fa23a1308710 (patch) | |
tree | 5a3ef95f355a33ccd3907811073b18bd87888a0f /Source/ModelViewer/Main.cs | |
parent | 34e214d35927c2cf49efdab79d111c67ae283ce7 (diff) |
Double-click in state list brings up source view
Diffstat (limited to 'Source/ModelViewer/Main.cs')
-rw-r--r-- | Source/ModelViewer/Main.cs | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/Source/ModelViewer/Main.cs b/Source/ModelViewer/Main.cs index 1df48a29..d18e1daf 100644 --- a/Source/ModelViewer/Main.cs +++ b/Source/ModelViewer/Main.cs @@ -623,7 +623,7 @@ namespace Microsoft.Boogie.ModelViewer }
private SourceView sourceView;
- private void showSourceToolStripMenuItem_Click(object sender, EventArgs e)
+ private void ShowSource()
{
if (stateList.SelectedItems.Count == 0) return;
var li = stateList.SelectedItems[0] as ListViewItem;
@@ -634,9 +634,19 @@ namespace Microsoft.Boogie.ModelViewer sourceView = new SourceView();
}
sourceView.SetSourceLocation(r);
- }
+ }
}
}
+
+ private void showSourceToolStripMenuItem_Click(object sender, EventArgs e)
+ {
+ ShowSource();
+ }
+
+ private void stateList_DoubleClick(object sender, EventArgs e)
+ {
+ ShowSource();
+ }
}
internal class DisplayItem : ListViewItem
|