Example #1
0
		public int IndexOf(Scale ax)
		{
			for (int i = 0; i < _linkedScales.Length; i++)
			{
				if (_linkedScales[i].Scale == ax)
					return i;
			}

			return -1;
		}
Example #2
0
		/// <summary>
		/// Measures if the linked axis has changed.
		/// </summary>
		/// <param name="linkedAxis">The axis that is the master axis (our axis is linked to this axis).</param>
		public void EhLinkedLayerAxesChanged(Scale linkedAxis)
		{
			if (_isLinked)
			{
				// we must disable our own interrogator because otherwise we can not change the axis
				_scale.IsLinked = false;
				_scale.ProcessDataBounds(
					LinkOrgA + LinkOrgB * linkedAxis.OrgAsVariant, true,
					LinkEndA + LinkEndB * linkedAxis.EndAsVariant, true);
				_scale.IsLinked = true; // restore the linked state of the axis

				this.OnLinkPropertiesChanged(); // indicate that the axes boundaries have changed
			}
		}
Example #3
0
		public void SetScale(int i, Scale ax)
		{
			_linkedScales[i].Scale = ax;
		}