Убрал кнопки Справка из диалогов ГУИ

This commit is contained in:
2025-09-15 11:54:51 +03:00
parent 908430fd24
commit 762437a908
10 changed files with 27 additions and 15 deletions

View File

@@ -311,6 +311,7 @@ bool EditorInstructors::verifyInstructor(Instructor instructor)
bool EditorInstructors::editInstructor(Instructor instructor, Instructor* instructor_edit)
{
DialogEditInstructor dlg(this);
dlg.setWindowFlags(dlg.windowFlags() & ~Qt::WindowContextHelpButtonHint);
dlg.setInstructor(instructor);

View File

@@ -16,22 +16,22 @@ void InstructorsView::resizeEvent(QResizeEvent *event)
treeWidget->setColumnWidth(ColumnsTreeInsructors::clmn_ID, 50);
treeWidget->setColumnWidth(ColumnsTreeInsructors::clmn_Login, 100);
treeWidget->setColumnWidth(ColumnsTreeInsructors::clmn_Password, 100);
treeWidget->setColumnWidth(ColumnsTreeInsructors::clmn_Administrator, 120);
treeWidget->setColumnWidth(ColumnsTreeInsructors::clmn_Archived, 80);
treeWidget->setColumnWidth(ColumnsTreeInsructors::clmn_Logged, 100);
treeWidget->setColumnWidth(ColumnsTreeInsructors::clmn_Administrator, 140);
treeWidget->setColumnWidth(ColumnsTreeInsructors::clmn_Archived, 100);
treeWidget->setColumnWidth(ColumnsTreeInsructors::clmn_Logged, 120);
int widthInstructor;
if(typeView == TypeView::onlyView)
{//onlyView
widthInstructor = width - (230 + 10);
widthInstructor = width - (290 + 10);
}
else
{//control
if(adminMode)
widthInstructor = width - (550 + 10);
widthInstructor = width - (610 + 10);
else
widthInstructor = width - (420 + 10);
widthInstructor = width - (480 + 10);
}
if(widthInstructor < 250)
widthInstructor = 250;

View File

@@ -63,7 +63,7 @@ void ViewerInstructors::on_btnEditorInstructors_clicked()
layout->addWidget(&editorInstructors);
dialog->setWindowTitle(tr("Editor of instructors"));
dialog->setMinimumSize(1600, 800);
dialog->setStyleSheet(this->styleSheet());
dialog->setWindowFlags(dialog->windowFlags() & ~Qt::WindowContextHelpButtonHint);
dialog->exec();
loadInstructorsFromDB();

View File

@@ -288,6 +288,7 @@ bool InstructorsAndTraineesWidget::authorizationInstructorDialog(QWidget* parent
{
DialogAuthorizationInstructor dlg(parent);
dlg.setWindowTitle(tr("Instructor authorization"));
dlg.setWindowFlags(dlg.windowFlags() & ~Qt::WindowContextHelpButtonHint);
do
{
@@ -424,6 +425,7 @@ void InstructorsAndTraineesWidget::setLanguageInterfase()
void InstructorsAndTraineesWidget::on_btnSettings_clicked()
{
DialogSettings dlg(connectorToServer, (loginInstructorLoggedInLocal != ""), this);
dlg.setWindowFlags(dlg.windowFlags() & ~Qt::WindowContextHelpButtonHint);
connect(&dlg, &DialogSettings::signal_LanguageChanged, this, &InstructorsAndTraineesWidget::slot_LanguageChanged);
connect(&dlg, &DialogSettings::signal_UpdateStyleSheet, this, &InstructorsAndTraineesWidget::slot_UpdateStyleSheet);

View File

@@ -314,7 +314,7 @@ void AMMtasksWidget::on_btnCheck_clicked()
if(!task.getID())
return;
DialogCheckTask dlg(connectorToServer, "amm", this);
DialogCheckTask dlg(connectorToServer, "amm", this);
dlg.setTask(&task);
@@ -323,7 +323,8 @@ void AMMtasksWidget::on_btnCheck_clicked()
layout->addWidget(&dlg);
dialog->setWindowTitle(tr("Status Task"));
dialog->setMinimumSize(200, 100);
dialog->setStyleSheet(this->styleSheet());
dialog->setWindowFlags(dialog->windowFlags() & ~Qt::WindowContextHelpButtonHint);
//dialog->setStyleSheet(this->styleSheet());
dialog->exec();
if(dlg.getFlChanged())

View File

@@ -373,7 +373,8 @@ void FIMtasksWidget::on_btnCheck_clicked()
layout->addWidget(&dlg);
dialog->setWindowTitle(tr("Check Task"));
dialog->setMinimumSize(1600, 800);
dialog->setStyleSheet(this->styleSheet());
dialog->setWindowFlags(dialog->windowFlags() & ~Qt::WindowContextHelpButtonHint);
//dialog->setStyleSheet(this->styleSheet());
dialog->exec();
if(dlg.getFlChanged())

View File

@@ -129,6 +129,8 @@ QTreeWidgetItem *TaskAMMFIMTreePreparation::addModuleToTreeWidgetAMM(Module *mod
void TaskAMMFIMTreePreparation::loadAMMtasksFromXML(QByteArray array)
{
qDebug() << "TaskAMMFIMTreePreparation::loadAMMtasksFromXML thread ID " << QThread::currentThreadId();
mtxAccess.lock();
deleteAllModulsAMM();
@@ -152,6 +154,8 @@ void TaskAMMFIMTreePreparation::loadAMMtasksFromXML(QByteArray array)
void TaskAMMFIMTreePreparation::loadFIMtasksFromXML(QByteArray array)
{
qDebug() << "TaskAMMFIMTreePreparation::loadFIMtasksFromXML thread ID " << QThread::currentThreadId();
mtxAccess.lock();
listTasksFIM.clear();

View File

@@ -492,6 +492,7 @@ bool EditorTrainees::verifyTrainee(Trainee trainee)
bool EditorTrainees::editGroup(Group group, Group *group_edit)
{
DialogEditGroup dlg(this);
dlg.setWindowFlags(dlg.windowFlags() & ~Qt::WindowContextHelpButtonHint);
dlg.setGroup(group);
@@ -522,6 +523,7 @@ bool EditorTrainees::editGroup(Group group, Group *group_edit)
bool EditorTrainees::editTrainee(Trainee trainee, Trainee *trainee_edit)
{
DialogEditTrainee dlg(this);
dlg.setWindowFlags(dlg.windowFlags() & ~Qt::WindowContextHelpButtonHint);
dlg.setTrainee(trainee);

View File

@@ -18,21 +18,21 @@ void TraineesView::resizeEvent(QResizeEvent *event)
treeWidget->setColumnWidth(ColumnsTreeTrainees::clmn_Class, 100);
treeWidget->setColumnWidth(ColumnsTreeTrainees::clmn_Computer, 100);
treeWidget->setColumnWidth(ColumnsTreeTrainees::clmn_IP_address, 130);
treeWidget->setColumnWidth(ColumnsTreeTrainees::clmn_Archived, 80);
treeWidget->setColumnWidth(ColumnsTreeTrainees::clmn_Logged, 100);
treeWidget->setColumnWidth(ColumnsTreeTrainees::clmn_Archived, 100);
treeWidget->setColumnWidth(ColumnsTreeTrainees::clmn_Logged, 120);
int widthTrainee;
if(typeView == TypeView::onlyView)
{//onlyView
widthTrainee = width - (230 + 10);
widthTrainee = width - (270 + 10);
}
else
{//control
if(adminMode)
widthTrainee = width - (760 + 10);
widthTrainee = width - (800 + 10);
else
widthTrainee = width - (630 + 10);
widthTrainee = width - (670 + 10);
}
if(widthTrainee < 250)
widthTrainee = 250;

View File

@@ -79,6 +79,7 @@ void ViewerTrainees::on_btnEditorTrainees_clicked()
layout->addWidget(&editorTraineesGroups);
dialog->setWindowTitle(tr("Editor of trainees"));
dialog->setMinimumSize(1600, 800);
dialog->setWindowFlags(dialog->windowFlags() & ~Qt::WindowContextHelpButtonHint);
dialog->exec();
loadTraineesFromDB();