X-Git-Url: https://gitweb.stoutner.com/?a=blobdiff_plain;f=src%2Fwindows%2FDomainSettingsWindow.cpp;fp=src%2Fwindows%2FDomainSettingsWindow.cpp;h=0000000000000000000000000000000000000000;hb=16118809a11aa423f453a03c47f5263e9dd8b662;hp=af4b3e7a42e6a99a5d4d83e7cf7f87570d41d3e3;hpb=0a7bcc3ab2d2a1015f29293fc9c527c1448a86cf;p=PrivacyBrowserPC.git diff --git a/src/windows/DomainSettingsWindow.cpp b/src/windows/DomainSettingsWindow.cpp deleted file mode 100644 index af4b3e7..0000000 --- a/src/windows/DomainSettingsWindow.cpp +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright © 2022 Soren Stoutner . - * - * This file is part of Privacy Browser PC . - * - * Privacy Browser PC is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * Privacy Browser PC is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Privacy Browser PC. If not, see . - */ - -// Application headers. -#include "DomainSettingsWindow.h" -#include "views/DomainSettingsView.h" - -// KDE Frameworks headers. -#include -#include - -DomainSettingsWindow::DomainSettingsWindow() : KXmlGuiWindow() -{ - // Instantiate the domain settings view pointer. - DomainSettingsView *domainSettingsViewPointer = new DomainSettingsView(this); - - // Set the domain settings view as the central widget. - setCentralWidget(domainSettingsViewPointer); - - // Set the object name. - this->setObjectName(QStringLiteral("domain_settings")); - - // Set the window title. - setCaption(i18nc("The Domain Settings window title", "Domain Settings")); - - // Get a handle for the action collection. - KActionCollection *actionCollectionPointer = this->actionCollection(); - - // Add the custom actions. - QAction *addDomainActionPointer = actionCollectionPointer->addAction(QStringLiteral("add_domain")); - QAction *deleteDomainActionPointer = actionCollectionPointer->addAction(QStringLiteral("delete_domain")); - QAction *okActionPointer = actionCollectionPointer->addAction(QStringLiteral("ok")); - QAction *applyActionPointer = actionCollectionPointer->addAction(QStringLiteral("apply")); - QAction *cancelActionPointer = actionCollectionPointer->addAction(QStringLiteral("cancel")); - - // Set the action text. - addDomainActionPointer->setText(i18nc("Add domain toolbar button", "Add Domain")); - deleteDomainActionPointer->setText(i18nc("Delete domain toolbar button", "Delete Domain")); - okActionPointer->setText(i18nc("OK toolbar button", "OK")); - applyActionPointer->setText(i18nc("Apply toolbar button", "Apply")); - cancelActionPointer->setText(i18nc("Cancel toolbar button", "Cancel")); - - // Set the action icons. - addDomainActionPointer->setIcon(QIcon::fromTheme(QStringLiteral("document-new"))); - deleteDomainActionPointer->setIcon(QIcon::fromTheme(QStringLiteral("delete"))); - okActionPointer->setIcon(QIcon::fromTheme(QStringLiteral("dialog-ok"))); - applyActionPointer->setIcon(QIcon::fromTheme(QStringLiteral("dialog-ok-apply"))); - cancelActionPointer->setIcon(QIcon::fromTheme(QStringLiteral("dialog-cancel"))); - - // Connect the button signals. - connect(addDomainActionPointer, SIGNAL(triggered()), domainSettingsViewPointer, SLOT(addDomain())); - connect(deleteDomainActionPointer, SIGNAL(triggered()), domainSettingsViewPointer, SLOT(deleteDomain())); - - // Setup the GUI without a status bar based on the domain_settings_ui.rc file. - setupGUI(StandardWindowOption::ToolBar | StandardWindowOption::Keys | StandardWindowOption::Save | StandardWindowOption::Create, ("domain_settings_ui.rc")); -}