mirror of
https://github.com/debauchee/barrier.git
synced 2026-05-05 21:02:39 +08:00
Added mutex for updating zeroconf service
This commit is contained in:
@@ -804,6 +804,8 @@ void MainWindow::changeEvent(QEvent* event)
|
||||
|
||||
void MainWindow::updateZeroconfService()
|
||||
{
|
||||
QMutexLocker locker(&m_Mutex);
|
||||
|
||||
if (isBonjourRunning()) {
|
||||
if (!m_AppConfig.wizardShouldRun()) {
|
||||
if (m_pZeroconfService) {
|
||||
@@ -960,6 +962,7 @@ void MainWindow::on_m_pCheckBoxAutoConnect_toggled(bool checked)
|
||||
|
||||
if (!checked) {
|
||||
m_pComboServerList->clear();
|
||||
m_pComboServerList->hide();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
#include "IpcClient.h"
|
||||
#include "Ipc.h"
|
||||
|
||||
#include <QMutex>
|
||||
|
||||
class QAction;
|
||||
class QMenu;
|
||||
class QLineEdit;
|
||||
@@ -176,6 +178,7 @@ class MainWindow : public QMainWindow, public Ui::MainWindowBase
|
||||
DataDownloader* m_pDataDownloader;
|
||||
QMessageBox* m_DownloadMessageBox;
|
||||
QAbstractButton* m_pCancelButton;
|
||||
QMutex m_Mutex;
|
||||
|
||||
private slots:
|
||||
void on_m_pComboServerList_currentIndexChanged(QString );
|
||||
|
||||
Reference in New Issue
Block a user