summaryrefslogtreecommitdiff
path: root/fpicker
diff options
context:
space:
mode:
authorJan-Marek Glogowski <glogow@fbihome.de>2022-06-02 22:42:20 +0200
committerJan-Marek Glogowski <glogow@fbihome.de>2022-06-08 18:17:17 +0200
commitea5a0918c8c32309821ab239c4b95f4d6a3b5c12 (patch)
tree04ff84b7c076a2f178e90d0eb32eb1731b10fd3c /fpicker
parentd4123356c61db269651e950a0a2cc93e6d801c90 (diff)
VCL add vcl::WindowPosSize abstract class
... and use it to remove a duplicate and simplify code. Should mostly be a refactoring, which was mainly done by some larger sed calls, except for the new API calls, which helped shrinking some LOC. All data is also now private. Originally two of the "replaced" "classes" had unsigned width and height and one had signed. Noel pointed out, that during calculations, the value might get negative temporarly, so this now settles with signed values. Still the set size should never be negative and this is enforced this way. Not sure that is what Noel had in mind. This also includes: - rename WindowState => WindowData - rename WindowStateMask => WindowDataMask - rename WindowStateState => WindowState - move WindowState and WindowDataMask to vcl/windowstate.hxx - move WindowData(Mask) and WindowState into vcl namespace - readability: replace or'ed WindowState enums with "meta" enums + add "meta" WindowState enums PosSize and PosSizeState Change-Id: Icd16cfb498531aa7238ddbde83fcb0ed6d9e4f77 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135426 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
Diffstat (limited to 'fpicker')
-rw-r--r--fpicker/source/office/RemoteFilesDialog.cxx2
-rw-r--r--fpicker/source/office/iodlg.cxx2
2 files changed, 2 insertions, 2 deletions
diff --git a/fpicker/source/office/RemoteFilesDialog.cxx b/fpicker/source/office/RemoteFilesDialog.cxx
index 4536690f9154..adaf756d3d8e 100644
--- a/fpicker/source/office/RemoteFilesDialog.cxx
+++ b/fpicker/source/office/RemoteFilesDialog.cxx
@@ -124,7 +124,7 @@ RemoteFilesDialog::~RemoteFilesDialog()
if( !m_sIniKey.isEmpty() )
{
SvtViewOptions aDlgOpt( EViewType::Dialog, m_sIniKey );
- aDlgOpt.SetWindowState(OStringToOUString(m_xDialog->get_window_state(WindowStateMask::All), RTL_TEXTENCODING_UTF8));
+ aDlgOpt.SetWindowState(OStringToOUString(m_xDialog->get_window_state(vcl::WindowDataMask::All), RTL_TEXTENCODING_UTF8));
Size aSize(m_xDialog->get_size());
diff --git a/fpicker/source/office/iodlg.cxx b/fpicker/source/office/iodlg.cxx
index a7addbb10121..80fd8614aae6 100644
--- a/fpicker/source/office/iodlg.cxx
+++ b/fpicker/source/office/iodlg.cxx
@@ -467,7 +467,7 @@ SvtFileDialog::~SvtFileDialog()
{
// save window state
SvtViewOptions aDlgOpt( EViewType::Dialog, m_xImpl->m_aIniKey );
- aDlgOpt.SetWindowState(OStringToOUString(m_xDialog->get_window_state(WindowStateMask::All), RTL_TEXTENCODING_UTF8));
+ aDlgOpt.SetWindowState(OStringToOUString(m_xDialog->get_window_state(vcl::WindowDataMask::All), RTL_TEXTENCODING_UTF8));
OUString sUserData = m_xFileView->GetConfigString();
aDlgOpt.SetUserItem( "UserData",
Any( sUserData ) );