mirror of
https://github.com/ProtonMail/proton-bridge.git
synced 2025-12-20 17:16:46 +00:00
GODT-1346: GODT-1340 GODT-1315 QML changes
GODT-1365: Create ComboBox component GODT-1338: GODT-1343 Help view buttons GODT-1340: Not crashing, user list updating in main thread. GODT-1345: adding panic handlers
This commit is contained in:
@ -43,6 +43,11 @@ func (f *FrontendQt) watchEvents() {
|
||||
userChangedCh := f.eventListener.ProvideChannel(events.UserRefreshEvent)
|
||||
certIssue := f.eventListener.ProvideChannel(events.TLSCertIssue)
|
||||
|
||||
// This loop is executed outside main Qt application thread. In order
|
||||
// to make sure that all signals are propagated correctly to QML we
|
||||
// must call QMLBackend signals to apply any changes to GUI. The
|
||||
// signals will make sure the changes are executed in main Qt app
|
||||
// thread.
|
||||
for {
|
||||
select {
|
||||
case errorDetails := <-errorCh:
|
||||
@ -77,7 +82,7 @@ func (f *FrontendQt) watchEvents() {
|
||||
case <-updateApplicationCh:
|
||||
f.updateForce()
|
||||
case userID := <-userChangedCh:
|
||||
f.userChanged(userID)
|
||||
f.qml.UserChanged(userID)
|
||||
case <-certIssue:
|
||||
f.qml.ApiCertIssue()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user