I want to open a context menu when the user right clicks on an object but I want to pass all other mouse hits through it.
protected override HitTestResult HitTestCore( PointHitTestParameters hitTestParameters )
{
var hitPoint = hitTestParameters.HitPoint;
if ( ( _xOffset <= hitPoint.X && hitPoint.X <= _xOffset + _width ) &&
_isRightClick )
{
return new PointHitTestResult( this, hitPoint );
}
return null;
}
How do I figure out _isRightClick?
Any better architected solutions are welcome. :)