Pregunta

Is there a way, either at runtime or (preferably) by using preprocessor macros, to determine whether the handle returned by QWidget::winId() is a handle to a Cocoa window or a handle to a Carbon window?

Windows is obvious, but I'm more interested in Mac. A particular library I'm using already knows how to use the various handles, but it needs to know which type the handle is before using it.

¿Fue útil?

Solución

There are preprocessor defines in QtCore/qconfig.h for this.

Search for QT_MAC_USE_COCOA on the internet.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top