Esempio n. 1
0
 public bool TryGetClickablePoint(out Point pt)
 {
     pt = new Point(0.0, 0.0);
     UIAutomationClient.tagPOINT nativePoint = new UIAutomationClient.tagPOINT();
     try
     {
         bool success = this._obj.GetClickablePoint(out nativePoint) != 0;
         if (success)
         {
             pt.X = nativePoint.x;
             pt.Y = nativePoint.y;
         }
         return(success);
     }
     catch (System.Runtime.InteropServices.COMException e)
     {
         Exception newEx; if (Utility.ConvertException(e, out newEx))
         {
             throw newEx;
         }
         else
         {
             throw;
         }
     }
 }
Esempio n. 2
0
 internal static UIAutomationClient.tagPOINT PointManagedToNative(System.Windows.Point pt)
 {
     UIAutomationClient.tagPOINT nativePoint = new UIAutomationClient.tagPOINT();
     nativePoint.x = (int)pt.X;
     nativePoint.y = (int)pt.Y;
     return(nativePoint);
 }
Esempio n. 3
0
 internal static UIAutomationClient.tagPOINT PointManagedToNative(System.Windows.Point pt)
 {
     UIAutomationClient.tagPOINT nativePoint = new UIAutomationClient.tagPOINT();
     nativePoint.x = (int)pt.X;
     nativePoint.y = (int)pt.Y;
     return nativePoint;
 }
Esempio n. 4
0
        public bool TryGetClickablePoint(out Point pt)
        {
            pt = new Point(0.0, 0.0);
            UIAutomationClient.tagPOINT nativePoint = new UIAutomationClient.tagPOINT();
            try
            {
                bool success = this._obj.GetClickablePoint(out nativePoint) != 0;
                if (success)
                {
                    pt.X = nativePoint.x;
                    pt.Y = nativePoint.y;
                }
                return success;
            }
            catch (System.Runtime.InteropServices.COMException e)
            {
                Exception newEx; if (Utility.ConvertException(e, out newEx)) { throw newEx; } else { throw; }
            }

        }