feature add log for privacy policy changed.

This commit is contained in:
alves
2026-01-06 20:45:05 +08:00
parent 3e790b4b9e
commit 49546332c3
3 changed files with 5 additions and 3 deletions

View File

@@ -7072,7 +7072,7 @@ bool GUI_App::run_wizard(ConfigWizard::RunReason reason, ConfigWizard::StartPage
auto isAgree = wxGetApp().app_config->get("app", "privacy_policy_isagree");
set_privacy_policy(isAgree == "true");
BOOST_LOG_TRIVIAL(warning) << "run_wizard changed the privacy policy with: " << (isAgree);
return res;
}
@@ -7292,7 +7292,7 @@ bool GUI_App::config_wizard_startup()
{
auto isAgree = wxGetApp().app_config->get("app", "privacy_policy_isagree");
set_privacy_policy(isAgree == "true");
BOOST_LOG_TRIVIAL(warning) << "config_wizard_startup changed the privacy policy with: " << (isAgree);
if (!m_app_conf_exists || preset_bundle->printers.only_default_printers()) {
BOOST_LOG_TRIVIAL(info) << "run wizard...";
run_wizard(ConfigWizard::RR_DATA_EMPTY);

View File

@@ -750,7 +750,8 @@ wxBoxSizer *PreferencesDialog::create_item_checkbox(wxString title, wxWindow *pa
if (param == "privacy_policy_isagree")
{
app_config->set("app", "privacy_policy_isagree", checkbox->GetValue());
app_config->set("app", "privacy_policy_isagree", checkbox->GetValue());
BOOST_LOG_TRIVIAL(warning) <<"create_item_checkbox changed the privacy policy with: "<<(checkbox->GetValue()?"true" : "false");
set_privacy_policy(checkbox->GetValue());
}
// if (param == "staff_pick_switch") {

View File

@@ -650,6 +650,7 @@ int GuideFrame::SaveProfile()
// } else
// m_MainPtr->app_config->set(std::string(m_SectionName.mb_str()), "privacyuse", "0");
m_MainPtr->app_config->set("app", "privacy_policy_isagree", PrivacyUse);
BOOST_LOG_TRIVIAL(warning) << "SaveProfile changed the privacy policy with: " << (PrivacyUse ? "true" : "false");
set_privacy_policy(PrivacyUse);
m_MainPtr->app_config->set("region", m_Region);
m_MainPtr->app_config->set_bool("stealth_mode", StealthMode);