Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Unsolved How to detect if a mouse is connected to the device or not?

    General and Desktop
    2
    2
    75
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S
      samarthraj11 last edited by samarthraj11

      I'm a SoK'22 contributor. My activity aims to teach the difference between left and right click. So this activity should only be visible to the devices which have a mouse attached to them.
      And invible to other devices such as mobile phones.

      1 Reply Last reply Reply Quote 0
      • SGaist
        SGaist Lifetime Qt Champion last edited by

        Hi and welcome to devnet,

        If memory serves well SoK is for summer of KDE, hence you could use their Solid framework to list available devices and see if there's a mouse connected. The fact that your application runs in a phone or tablet does not mean that there might not be a mouse connected at some point.

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply Reply Quote 0
        • First post
          Last post