Details
-
Task
-
Resolution: Unresolved
-
P2: Important
-
None
-
None
-
None
Description
@BindConnection was introduced to register connection in QML side without the need of manual emitting of the signalÂ
interface MyMainViewModelCallback { fun duplicateFound(item: String) fun erased() fun blankFound() } ///// @BindConnection private var qtCallback: MyMainViewModelCallback? = null
By annotating the interface we get:
public final class MainViewModel_MyMainViewModelCallbackImpl implements MyMainViewModelCallback { private final MainViewModel viewModel; public MainViewModel_MyMainViewModelCallbackImpl(MainViewModel var1) { this.viewModel = var1; } public void erased() { this.viewModel.emit("erased", new Object[0]); } public void blankFound() { this.viewModel.emit("blankFound", new Object[0]); } public void duplicateFound(String var1) { this.viewModel.emit("duplicateFound", new Object[]{var1}); } }
This is done however it needs to be improved as it requires to be within a QtViewModel which inherits from at QObject
Attachments
Issue Links
- is required for
-
QTBUG-134776 As a dev, I need a simple way to add a Qt Quick UI to my Java code
-
- In Progress
-