filter/source/pdf/impdialog.cxx |   10 +++++-----
 filter/source/pdf/impdialog.hxx |    2 +-
 2 files changed, 6 insertions(+), 6 deletions(-)

New commits:
commit 86e8abc2b171f56511787eda28f1604a0ee6d000
Author:     Tomaž Vajngerl <tomaz.vajng...@collabora.co.uk>
AuthorDate: Sat May 3 00:10:18 2025 +0900
Commit:     Tomaž Vajngerl <qui...@gmail.com>
CommitDate: Sat May 3 13:54:16 2025 +0200

    tdf#165858 pdf: use the correct widget to dissble the forms options
    
    "formsframe" widget was a grid that previously contained the forms
    options only, but after restructuring the "forms_frame" is actually
    a frame that contains all the forms option and checkbox to enable
    writing of the forms. A different "forms_options_grid" is used to
    contain only the form options.
    
    This was changed in the .ui file, but it was not changed correctly
    in the code (only "formsframe" was renamed to "forms_frame").
    
    The change fixes the code to use "forms_options_grid" instead of
    "forms_frame" and renames the variables so now the correct widget
    is used.
    
    Change-Id: I15f967575d1a53ab9545e68867c48abefbc6b0dd
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/184910
    Tested-by: Jenkins
    Reviewed-by: Tomaž Vajngerl <qui...@gmail.com>

diff --git a/filter/source/pdf/impdialog.cxx b/filter/source/pdf/impdialog.cxx
index 8b06f194012b..19a5c7f2633a 100644
--- a/filter/source/pdf/impdialog.cxx
+++ b/filter/source/pdf/impdialog.cxx
@@ -495,7 +495,7 @@ ImpPDFTabGeneralPage::ImpPDFTabGeneralPage(weld::Container* 
pPage, weld::DialogC
     , mxRbPDFVersion(m_xBuilder->weld_combo_box(u"pdf_version"_ustr))
     , mxCbTaggedPDF(m_xBuilder->weld_check_button(u"tagged"_ustr))
     , mxCbExportFormFields(m_xBuilder->weld_check_button(u"forms"_ustr))
-    , mxFormsFrame(m_xBuilder->weld_widget(u"forms_frame"_ustr))
+    , mxFormsOptionGrid(m_xBuilder->weld_widget(u"forms_options_grid"_ustr))
     , mxLbFormsFormat(m_xBuilder->weld_combo_box(u"format"_ustr))
     , 
mxCbAllowDuplicateFieldNames(m_xBuilder->weld_check_button(u"allowdups"_ustr))
     , mxCbExportBookmarks(m_xBuilder->weld_check_button(u"bookmarks"_ustr))
@@ -647,8 +647,8 @@ void 
ImpPDFTabGeneralPage::SetFilterConfigItem(ImpPDFTabDialog* pParent)
 
     mxLbFormsFormat->set_active(static_cast<sal_uInt16>(pParent->mnFormsType));
     mxCbAllowDuplicateFieldNames->set_active( 
pParent->mbAllowDuplicateFieldNames );
-    // FormsFrame contains (and thus sets_sensitive) FormsFormat and 
AllowDuplicateFieldNames
-    mxFormsFrame->set_sensitive(pParent->mbExportFormFields);
+    // FormsOptionGrid contains (and thus sets_sensitive) FormsFormat and 
AllowDuplicateFieldNames
+    mxFormsOptionGrid->set_sensitive(pParent->mbExportFormFields);
     if (pParent->mbExportFormFields)
     {
         if (pParent->maConfigItem.IsReadOnly(u"FormsType"_ustr))
@@ -874,8 +874,8 @@ void ImpPDFTabGeneralPage::EnableExportNotesPages()
 IMPL_LINK_NOARG(ImpPDFTabGeneralPage, ToggleExportFormFieldsHdl, 
weld::Toggleable&, void)
 {
     const bool bExportFormFields = mxCbExportFormFields->get_active();
-    // FormsFrame contains (and thus sets_sensitive) FormsFormat and 
AllowDuplicateFieldNames
-    mxFormsFrame->set_sensitive(bExportFormFields);
+    // FormsOptionsGrid contains (and thus sets_sensitive) FormsFormat and 
AllowDuplicateFieldNames
+    mxFormsOptionGrid->set_sensitive(bExportFormFields);
     if (bExportFormFields)
     {
         if (IsReadOnlyProperty(u"FormsType"_ustr))
diff --git a/filter/source/pdf/impdialog.hxx b/filter/source/pdf/impdialog.hxx
index 66bf90e5b51a..aff0023acda0 100644
--- a/filter/source/pdf/impdialog.hxx
+++ b/filter/source/pdf/impdialog.hxx
@@ -199,7 +199,7 @@ class ImpPDFTabGeneralPage : public SfxTabPage
     std::unique_ptr<weld::ComboBox> mxRbPDFVersion;
     std::unique_ptr<weld::CheckButton> mxCbTaggedPDF;
     std::unique_ptr<weld::CheckButton> mxCbExportFormFields;
-    std::unique_ptr<weld::Widget> mxFormsFrame;
+    std::unique_ptr<weld::Widget> mxFormsOptionGrid;
     std::unique_ptr<weld::ComboBox> mxLbFormsFormat;
     std::unique_ptr<weld::CheckButton> mxCbAllowDuplicateFieldNames;
     std::unique_ptr<weld::CheckButton> mxCbExportBookmarks;

Reply via email to