Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Messaging service on mac on external drive detection .

Messaging service on mac on external drive detection .

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 1.3k Views 1 Watching
  • 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.
  • V Offline
    V Offline
    vivekmalik2466
    wrote on last edited by
    #1

    messaging service on mac on external drive detection .
    can any one let me know how to i find a signal on drive plugin and plugout

    1 Reply Last reply
    0
    • R Offline
      R Offline
      rcari
      wrote on last edited by
      #2

      You should look at the Apple documentation on "I/O Kit":https://developer.apple.com/library/mac/#documentation/IOKit/Reference/IOKitLib_header_reference/Reference/reference.html
      Look especially at @IONotificationPortCreate()@ and @IONotificationPortGetRunLoopSource()@
      Then take a look at the CFRunloop API "here":https://developer.apple.com/library/mac/#documentation/CoreFOundation/Reference/CFRunLoopRef/Reference/reference.html
      Qt uses a NSRunloop/CFRunloop in the backend so you can safely call @CFRunLoopGetCurrent()@
      and register your notification port source to that.
      You can then get the plug/unplug events by overloading @QApplication::macEventFilter()@

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved