Changeset View
Changeset View
Standalone View
Standalone View
krusader/Dialogs/krmaskchoice.cpp
Show First 20 Lines • Show All 99 Lines • ▼ Show 20 Line(s) | 49 | { | |||
---|---|---|---|---|---|
100 | PushButton7_3->setToolTip(i18n("Clears the entire list of selections")); | 100 | PushButton7_3->setToolTip(i18n("Clears the entire list of selections")); | ||
101 | vbox->addWidget(PushButton7_3); | 101 | vbox->addWidget(PushButton7_3); | ||
102 | vbox->addItem(new QSpacerItem(5, 5, QSizePolicy::Fixed, QSizePolicy::Expanding)); | 102 | vbox->addItem(new QSpacerItem(5, 5, QSizePolicy::Fixed, QSizePolicy::Expanding)); | ||
103 | 103 | | |||
104 | QDialogButtonBox* ButtonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel, this); | 104 | QDialogButtonBox* ButtonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel, this); | ||
105 | MainLayout->addWidget(ButtonBox); | 105 | MainLayout->addWidget(ButtonBox); | ||
106 | 106 | | |||
107 | // signals and slots connections | 107 | // signals and slots connections | ||
108 | connect(ButtonBox, SIGNAL(rejected()), this, SLOT(reject())); | 108 | connect(ButtonBox, &QDialogButtonBox::rejected, this, &KRMaskChoice::reject); | ||
109 | connect(ButtonBox, SIGNAL(accepted()), this, SLOT(accept())); | 109 | connect(ButtonBox, &QDialogButtonBox::accepted, this, &KRMaskChoice::accept); | ||
110 | connect(PushButton7, SIGNAL(clicked()), this, SLOT(addSelection())); | 110 | connect(PushButton7, &QPushButton::clicked, this, &KRMaskChoice::addSelection); | ||
111 | connect(PushButton7_2, SIGNAL(clicked()), this, SLOT(deleteSelection())); | 111 | connect(PushButton7_2, &QPushButton::clicked, this, &KRMaskChoice::deleteSelection); | ||
112 | connect(PushButton7_3, SIGNAL(clicked()), this, SLOT(clearSelections())); | 112 | connect(PushButton7_3, &QPushButton::clicked, this, &KRMaskChoice::clearSelections); | ||
113 | connect(selection, SIGNAL(activated(QString)), selection, SLOT(setEditText(QString))); | 113 | connect(selection, QOverload<const QString &>::of(&KComboBox::activated), selection, &KComboBox::setEditText); | ||
114 | connect(selection->lineEdit(), SIGNAL(returnPressed()), this, SLOT(accept())); | 114 | connect(selection->lineEdit(), &QLineEdit::returnPressed, this, &KRMaskChoice::accept); | ||
115 | connect(preSelections, SIGNAL(currentItemChanged(QListWidgetItem*,QListWidgetItem*)), this, SLOT(currentItemChanged(QListWidgetItem*))); | 115 | connect(preSelections, &KrListWidget::currentItemChanged, this, &KRMaskChoice::currentItemChanged); | ||
116 | connect(preSelections, SIGNAL(itemActivated(QListWidgetItem*)), this, SLOT(acceptFromList(QListWidgetItem*))); | 116 | connect(preSelections, &KrListWidget::itemActivated, this, &KRMaskChoice::acceptFromList); | ||
117 | } | 117 | } | ||
118 | 118 | | |||
119 | /* | 119 | /* | ||
120 | * Destroys the object and frees any allocated resources | 120 | * Destroys the object and frees any allocated resources | ||
121 | */ | 121 | */ | ||
122 | KRMaskChoice::~KRMaskChoice() | 122 | KRMaskChoice::~KRMaskChoice() | ||
123 | { | 123 | { | ||
124 | // no need to delete child widgets, Qt does it all for us | 124 | // no need to delete child widgets, Qt does it all for us | ||
Show All 27 Lines |