From 0b3f1bb595e1438995a0ff916d7b3e98545ff3e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20M=C3=B6ller?= Date: Sat, 8 Jun 2013 17:07:18 +0000 Subject: [PATCH] Some modifications to the OxyPlot library to simplify the use in the Open Hardware Monitor. --- External/OxyPlot/OxyPlot.WindowsForms/Plot.cs | 17 ++++++++--------- External/OxyPlot/OxyPlot/Axes/Axis.cs | 4 ++-- 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/External/OxyPlot/OxyPlot.WindowsForms/Plot.cs b/External/OxyPlot/OxyPlot.WindowsForms/Plot.cs index aa56dec..db59dd8 100644 --- a/External/OxyPlot/OxyPlot.WindowsForms/Plot.cs +++ b/External/OxyPlot/OxyPlot.WindowsForms/Plot.cs @@ -841,24 +841,23 @@ namespace OxyPlot.WindowsForms bool xb2 = e.Button == MouseButtons.XButton2; // MMB / control RMB / control+alt LMB - if (mmb || (control && rmb) || (control && alt && lmb)) + if (mmb || (control && lmb) || (control && alt && rmb)) + { + return new ZoomRectangleManipulator(this); + } + + // Right mouse button / alt+left mouse button + if (lmb || (rmb && alt)) { if (e.Clicks == 2) { return new ResetManipulator(this); } - - return new ZoomRectangleManipulator(this); - } - - // Right mouse button / alt+left mouse button - if (rmb || (lmb && alt)) - { return new PanManipulator(this); } // Left mouse button - if (lmb) + if (rmb) { return new TrackerManipulator(this) { Snap = !control, PointsOnly = shift }; } diff --git a/External/OxyPlot/OxyPlot/Axes/Axis.cs b/External/OxyPlot/OxyPlot/Axes/Axis.cs index c9aead3..1dd2bff 100644 --- a/External/OxyPlot/OxyPlot/Axes/Axis.cs +++ b/External/OxyPlot/OxyPlot/Axes/Axis.cs @@ -703,13 +703,13 @@ namespace OxyPlot.Axes /// Gets or sets the current view's maximum. This value is used when the user zooms or pans. /// /// The view maximum. - protected double ViewMaximum { get; set; } + public double ViewMaximum { get; protected set; } /// /// Gets or sets the current view's minimum. This value is used when the user zooms or pans. /// /// The view minimum. - protected double ViewMinimum { get; set; } + public double ViewMinimum { get; protected set; } /// /// Transforms the specified point to screen coordinates.