ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
ccCorkDlg.cpp
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - CloudViewer: www.cloudViewer.org -
3 // ----------------------------------------------------------------------------
4 // Copyright (c) 2018-2024 www.cloudViewer.org
5 // SPDX-License-Identifier: MIT
6 // ----------------------------------------------------------------------------
7 
8 #include "ccCorkDlg.h"
9 
10 ccCorkDlg::ccCorkDlg(QWidget* parent)
11  : QDialog(parent, Qt::Tool),
12  Ui::CorkDialog(),
13  m_selectedOperation(UNION),
14  m_isSwapped(false) {
15  setupUi(this);
16 
17  connect(unionPushButton, SIGNAL(clicked()), this, SLOT(unionSelected()));
18  connect(interPushButton, SIGNAL(clicked()), this,
19  SLOT(intersectSelected()));
20  connect(diffPushButton, SIGNAL(clicked()), this, SLOT(diffSelected()));
21  connect(symDiffPushButton, SIGNAL(clicked()), this,
22  SLOT(symDiffSelected()));
23  connect(swapToolButton, SIGNAL(clicked()), this, SLOT(swap()));
24 }
25 
26 void ccCorkDlg::setNames(QString A, QString B) {
27  meshALineEdit->setText(A);
28  meshBLineEdit->setText(B);
29 }
30 
33  accept();
34 }
35 
38  accept();
39 }
40 
43  accept();
44 }
45 
48  accept();
49 }
50 
53 
54  QString A = meshALineEdit->text();
55  QString B = meshBLineEdit->text();
56  setNames(B, A);
57 }
void symDiffSelected()
Definition: ccCorkDlg.cpp:46
@ INTERSECT
Definition: ccCorkDlg.h:21
@ SYM_DIFF
Definition: ccCorkDlg.h:21
void swap()
Definition: ccCorkDlg.cpp:51
void diffSelected()
Definition: ccCorkDlg.cpp:41
void intersectSelected()
Definition: ccCorkDlg.cpp:36
CSG_OPERATION m_selectedOperation
Definition: ccCorkDlg.h:41
ccCorkDlg(QWidget *parent=0)
Default constructor.
Definition: ccCorkDlg.cpp:10
void setNames(QString A, QString B)
Set meshes names.
Definition: ccCorkDlg.cpp:26
void unionSelected()
Definition: ccCorkDlg.cpp:31
bool m_isSwapped
Definition: ccCorkDlg.h:42