woboq / qmetaobject-rs

Integrate Qml and Rust by building the QMetaObject at compile time.
MIT License
648 stars 89 forks source link

Replaced QApplication from QtWidgets by QGuiApplication from QtGui #288

Closed Atlas42 closed 1 year ago

Atlas42 commented 1 year ago

When using QML the application class should be a QGuiApplication. On targets without QtWidgets (my case on an aarch64 with a custom-build qt), the crate does not build. Replacing this class usage fixes it.

ratijas commented 1 year ago

IMHO this kind of switch should be configurable. QGuiApplication is more compatible with targets, but QApplication provides automatic style change events and other nice things. How about a cargo feature flag?

Also, your pull request contains lots of unrelated commits, please your change rebase on master.

ratijas commented 1 year ago

Also, your pull request contains lots of unrelated commits, please your change rebase on master.

oh, it's probably because you submitted this pull request from your own master branch, but you continued working on it for your own project. That doesn't work well in practice. Normally, you'd create a new branch per pull request, and only push to it those changes which you intend to land as a part of such pull request.

Atlas42 commented 1 year ago

Using an other pull request from another branch #294