Jump to content

Search the Community

Showing results for tags 'objectatpoint'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Delphi Questions and Answers
    • Algorithms, Data Structures and Class Design
    • VCL
    • FMX
    • RTL and Delphi Object Pascal
    • Databases
    • Network, Cloud and Web
    • Windows API
    • Cross-platform
    • Delphi IDE and APIs
    • General Help
    • Delphi Third-Party
  • C++Builder Questions and Answers
    • General Help
  • General Discussions
    • Embarcadero Lounge
    • Tips / Blogs / Tutorials / Videos
    • Job Opportunities / Coder for Hire
    • I made this
  • Software Development
    • Project Planning and -Management
    • Software Testing and Quality Assurance
  • Community
    • Community Management

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Delphi-Version

Found 1 result

  1. hello girls and boys, RAD 11.2 Alexandria FMX project / 32bits Button1 is on Form1 (directly); Button1.HitTest = false; I'm having a little problem with something that would, shall we say, not be a problem... I need to get control over the mouse cursor to perform some extra tasks. However, I'm not understanding why the result is always "nil" for the "ObjectAtPoint" function. According to the code below, I believe that it should have the intended return, that is, the control "Button1" (IControl representing it)... however, the function is returning "nil"... and, how can be seen on the printscreen, everything goes well until the line number "101", after it, the "result" is again used to check if "ITSELF" has an "object (children... but does not )" in the given coordinates... this part seems strange to me, however, the code is from Embarcadero... so there was even more doubt! So, if anyone can say something that helps me, I thank you in advance. here my code for tests... type TForm1 = class(TForm) Button1: TButton; // <---- my control into form, "Button1.HitTest := false" ... procedure TForm1.FormMouseMove(Sender: TObject; Shift: TShiftState; X, Y: single); var LPointF: TPointF; LIControl: IControl; begin LPointF := TPointF.Create(X, Y); // LIControl := ObjectAtPoint(LPointF); = it's nil // or LIControl := ObjectAtPoint(ClientToScreen(LPointF)); = it's nil ... end; NOTE: on screenshot is "TEDIT" but in fact is "TButton"... ok == I pasted old printscreen ! SORRY!
×