карта блок-в. Блокировка правильная. Множ. доступ

This commit is contained in:
2026-01-21 15:44:01 +03:00
parent fe75f2c6ca
commit 2772c3aaba
26 changed files with 146 additions and 91 deletions

View File

@@ -214,6 +214,8 @@ void DialogSettings::on_btnSetVersion_clicked()
if(connectorToServer)
if(connectorToServer->getIsConnected())
{
connectorToServer->sendQueryBlockAuth(true, "VersionControl");
dlgVersionControl = new DialogVersionControl(connectorToServer, this);
dlgVersionControl->initialize(connectorToServer->getLoginName());
dlgVersionControl->exec();
@@ -222,7 +224,9 @@ void DialogSettings::on_btnSetVersion_clicked()
{
delete dlgVersionControl;
dlgVersionControl = nullptr;
}
}
connectorToServer->sendQueryBlockAuth(false, "VersionControl");
}
}

View File

@@ -58,7 +58,6 @@ void DialogVersionControl::initialize(QString authorName)
this->authorName = authorName;
connect (connectorToServer, &ConnectorToServer::signal_SetVersion, this, &DialogVersionControl::slot_SetVersion);
connect(connectorToServer, &ConnectorToServer::signal_AnimationActivated, this, &DialogVersionControl::slot_activateLoadAnimation);
connect(connectorToServer, &ConnectorToServer::signal_showServerList, this, &DialogVersionControl::slot_showServerList);
connect(connectorToServer, &ConnectorToServer::signal_NotifyVersionControl, this, &DialogVersionControl::slot_NotifyVersionControl);
@@ -69,6 +68,7 @@ void DialogVersionControl::initialize(QString authorName)
connect(this, &DialogVersionControl::signal_getVersion, connectorToServer, &ConnectorToServer::slot_getVersion);
waitAnimationWidget->showWithPlay();
emit signal_getVersion();
}
@@ -124,6 +124,7 @@ void DialogVersionControl::sendCopyEmit(QString newName)
}
versionContainer->setLocalVersionData(selectedVersion);
waitAnimationWidget->showWithPlay();
emit sigSendCopyVersion(result);
}
@@ -144,6 +145,7 @@ void DialogVersionControl::on_createDuplicateButton_clicked()
case QDialog::Accepted:
{
QString newName = dlgNewVersion->getNewName();
waitAnimationWidget->showWithPlay();
sendCopyEmit(newName);
break;
}
@@ -171,6 +173,7 @@ void DialogVersionControl::on_deleteVersionButton_clicked()
if(SpecMsgBox::WarningYesNo(this, tr("The deletion will be irrevocable.\nDelete it anyway?")) == QDialog::Accepted)
{
waitAnimationWidget->showWithPlay();
emit sigSendDeleteVersion(selectedVersion);
}
}
@@ -186,24 +189,14 @@ void DialogVersionControl::on_switchServerVersionButton_clicked()
//versionContainer->setServerVersionData(selectedVersion);
//ui->verValue->setText(selectedVersion->getViewName());
waitAnimationWidget->showWithPlay();
emit sigSendSwitchVersion(selectedVersion);
}
void DialogVersionControl::slot_activateLoadAnimation(bool flag)
{
if (flag)
{
waitAnimationWidget->showWithPlay();
}
else
{
waitAnimationWidget->hideWithStop();
}
}
void DialogVersionControl::slot_showServerList(QList<StreamingVersionData *> *serverList)
{
fillView(serverList);
waitAnimationWidget->hideWithStop();
}
void DialogVersionControl::slot_SetVersion(StreamingVersionData *serverVersion)
@@ -215,11 +208,15 @@ void DialogVersionControl::slot_SetVersion(StreamingVersionData *serverVersion)
connectorToServer->sendShowVersionSelect();
flGetVersion = true;
waitAnimationWidget->hideWithStop();
}
void DialogVersionControl::slot_NotifyVersionControl(QString text)
{
SpecMsgBox::WarningClose(this, text);
waitAnimationWidget->hideWithStop();
}
void DialogVersionControl::resizeEvent(QResizeEvent *event)

View File

@@ -36,7 +36,6 @@ private slots:
void on_verListView_itemClicked(QListWidgetItem *item);
private slots:
void slot_activateLoadAnimation(bool flag);
void slot_showServerList(QList<StreamingVersionData*> *serverList);
void slot_SetVersion(StreamingVersionData* serverVersion);
void slot_NotifyVersionControl(QString text);