diff options
author | Xisco Fauli <xiscofauli@libreoffice.org> | 2021-04-29 12:02:06 +0200 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2021-05-01 20:59:10 +0200 |
commit | 0957a98f6f1b8714f6650e7e67f936537ae96cc8 (patch) | |
tree | 33fc97c79491e47b4f43ce72c3e4d74fb8bd77f4 | |
parent | 7149defa3d18785603adcf3c0fc5221a42261494 (diff) |
vcl: print dialog: remove broken code
This was introduced in 149807eb6100090e178505ba4a264bb38eba1e0c
< Resolves tdf#127782 - Print dialog height >
trying to fix the problem of the window size not being remembered
after reopening the dialog, however, the problem is still
reproducible in master with GEN, thus, remove this code
Change-Id: I65f327fa692cd3e2b5597d04e9e15abc952fe6d9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114874
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114890
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
-rw-r--r-- | officecfg/registry/schema/org/openoffice/Office/Common.xcs | 10 | ||||
-rw-r--r-- | vcl/source/window/printdlg.cxx | 11 |
2 files changed, 0 insertions, 21 deletions
diff --git a/officecfg/registry/schema/org/openoffice/Office/Common.xcs b/officecfg/registry/schema/org/openoffice/Office/Common.xcs index 49018a07ca17..e1df1a0d8ffd 100644 --- a/officecfg/registry/schema/org/openoffice/Office/Common.xcs +++ b/officecfg/registry/schema/org/openoffice/Office/Common.xcs @@ -3511,16 +3511,6 @@ </info> <value>false</value> </prop> - <prop oor:name="Width" oor:type="xs:int"> - <info> - <desc>Stores the width of the print dialog.</desc> - </info> - </prop> - <prop oor:name="Height" oor:type="xs:int"> - <info> - <desc>Stores the height of the print dialog.</desc> - </info> - </prop> </group> </group> <group oor:name="AddXMLToStorage"> diff --git a/vcl/source/window/printdlg.cxx b/vcl/source/window/printdlg.cxx index 6583e1891e52..d37c0ec068bc 100644 --- a/vcl/source/window/printdlg.cxx +++ b/vcl/source/window/printdlg.cxx @@ -683,15 +683,6 @@ PrintDialog::PrintDialog(weld::Window* i_pWindow, const std::shared_ptr<PrinterC mxScrolledWindow->get_preferred_size().Width() + mxScrolledWindow->get_vscroll_width(), 450); - // restore dialog size - std::optional<long> aWidth = officecfg::Office::Common::Print::Dialog::Width::get(); - std::optional<long> aHeight = officecfg::Office::Common::Print::Dialog::Height::get(); - WindowStateData aState; - if (aWidth) aState.SetWidth(*aWidth); else aWidth = -1; - if (aHeight) aState.SetHeight(*aHeight); else aHeight = -1; - aState.SetMask(WindowStateMask::Width | WindowStateMask::Height); - m_xDialog->set_window_state(aState.ToStr()); - m_xDialog->set_centered_on_parent(true); } @@ -700,8 +691,6 @@ PrintDialog::~PrintDialog() std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Print::Dialog::RangeSectionExpanded::set(mxRangeExpander->get_expanded(), batch); officecfg::Office::Common::Print::Dialog::LayoutSectionExpanded::set(mxLayoutExpander->get_expanded(), batch); - officecfg::Office::Common::Print::Dialog::Width::set(m_xDialog->get_size().getWidth(), batch); - officecfg::Office::Common::Print::Dialog::Height::set(m_xDialog->get_size().getHeight(), batch); batch->commit(); } |