X-Git-Url: https://gitweb.stoutner.com/?a=blobdiff_plain;f=src%2Fdialogs%2FEditFolderDialog.cpp;h=bae0965f2e16290ba40838c629729a91f0db34f0;hb=HEAD;hp=cabcf5dce6b838ca3315c5bfcddbf61b5a191447;hpb=cc59ec7b2c1ad4d7832b2c05f7245e8387379e66;p=PrivacyBrowserPC.git diff --git a/src/dialogs/EditFolderDialog.cpp b/src/dialogs/EditFolderDialog.cpp index cabcf5d..5ad5f05 100644 --- a/src/dialogs/EditFolderDialog.cpp +++ b/src/dialogs/EditFolderDialog.cpp @@ -1,20 +1,20 @@ -/* - * Copyright 2023-2024 Soren Stoutner . +/* SPDX-License-Identifier: GPL-3.0-or-later + * SPDX-FileCopyrightText: 2023-2024 Soren Stoutner * - * This file is part of Privacy Browser PC . + * 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. + * This program 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. + * This program 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 . + * You should have received a copy of the GNU General Public License along with + * this program. If not, see . */ // Application headers. @@ -42,6 +42,7 @@ EditFolderDialog::EditFolderDialog(QWidget *parentWidgetPointer, const int datab // Get handles for the widgets. currentFolderIconRadioButtonPointer = editFolderDialogUi.currentFolderIconRadioButton; + defaultFolderIconRadioButtonPointer = editFolderDialogUi.defaultFolderIconRadioButton; currentWebsiteFavoriteIconRadioButtonPointer = editFolderDialogUi.currentWebsiteFavoriteIconRadioButton; customFolderIconRadioButtonPointer = editFolderDialogUi.customFolderIconRadioButton; parentFolderTreeWidgetPointer = editFolderDialogUi.parentFolderTreeWidget; @@ -152,6 +153,8 @@ void EditFolderDialog::save() // Get the favorite icon. if (currentFolderIconRadioButtonPointer->isChecked()) // The current folder icon is checked. favoriteIcon = currentFolderIconRadioButtonPointer->icon(); + else if (defaultFolderIconRadioButtonPointer->isChecked()) // The default folder icon is checked. + favoriteIcon = defaultFolderIconRadioButtonPointer->icon(); else if (currentWebsiteFavoriteIconRadioButtonPointer->isChecked()) // The current website favorite icon is checked. favoriteIcon = currentWebsiteFavoriteIconRadioButtonPointer->icon(); else // The custom favorite icon is checked. @@ -175,7 +178,7 @@ void EditFolderDialog::save() BookmarksDatabase::updateFolderContentsDisplayOrder(folderBookmarkStructPointer->parentFolderId); // Emit the folder saved signal. - emit folderSaved(); + Q_EMIT folderSaved(); // Close the dialog. close();