summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHeiko Tietze <tietze.heiko@gmail.com>2023-01-07 10:23:07 +0100
committerHeiko Tietze <heiko.tietze@documentfoundation.org>2023-01-08 09:13:10 +0000
commite37f06f534ac864f9fe8cd20b07a85c36e697d41 (patch)
tree4511860d185ed54ab74ced1036e852d5c27f2d28
parent9b5c342121e8cc2d05569f7339bd32e9c8133938 (diff)
Resolves tdf#139141 - Make variable date/time field the default
Switched the fixed and variable/current field See also I18136feebed225f7645b6869d3600ee78f945bfb and I56f42b4ce104dbb96d8fda1bc71af727fa46d536 Change-Id: Id885c09410dc9aecc9570c8d3b7750e9d69e9c9c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145170 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
-rw-r--r--sw/inc/flddat.hxx2
-rw-r--r--sw/source/ui/fldui/flddok.cxx4
-rw-r--r--sw/source/uibase/fldui/fldmgr.cxx6
3 files changed, 6 insertions, 6 deletions
diff --git a/sw/inc/flddat.hxx b/sw/inc/flddat.hxx
index 39c00f68a235..6c452072e926 100644
--- a/sw/inc/flddat.hxx
+++ b/sw/inc/flddat.hxx
@@ -30,8 +30,8 @@ namespace tools { class Time; }
enum SwDateSubFormat
{
+ DATE_VAR,
DATE_FIX,
- DATE_VAR
};
class SAL_DLLPUBLIC_RTTI SwDateTimeFieldType final : public SwValueFieldType
diff --git a/sw/source/ui/fldui/flddok.cxx b/sw/source/ui/fldui/flddok.cxx
index e29bd09d828a..66d6e63d6259 100644
--- a/sw/source/ui/fldui/flddok.cxx
+++ b/sw/source/ui/fldui/flddok.cxx
@@ -241,9 +241,9 @@ IMPL_LINK_NOARG(SwFieldDokPage, TypeHdl, weld::TreeView&, void)
case SwFieldTypesEnum::Date:
case SwFieldTypesEnum::Time:
m_xSelectionLB->append(sId, aLst[i]);
- if (static_cast<SwDateTimeField*>(GetCurField())->IsFixed() && !i)
+ if (static_cast<SwDateTimeField*>(GetCurField())->IsFixed() && i)
m_xSelectionLB->select_id(sId);
- if (!static_cast<SwDateTimeField*>(GetCurField())->IsFixed() && i)
+ if (!static_cast<SwDateTimeField*>(GetCurField())->IsFixed() && !i)
m_xSelectionLB->select_id(sId);
break;
case SwFieldTypesEnum::ExtendedUser:
diff --git a/sw/source/uibase/fldui/fldmgr.cxx b/sw/source/uibase/fldui/fldmgr.cxx
index 8a0e81c882ec..d8f1fcc04ad0 100644
--- a/sw/source/uibase/fldui/fldmgr.cxx
+++ b/sw/source/uibase/fldui/fldmgr.cxx
@@ -159,14 +159,14 @@ const TranslateId FMT_AUTHOR_ARY[] =
const TranslateId FLD_DATE_ARY[] =
{
- FLD_DATE_FIX,
FLD_DATE_STD,
+ FLD_DATE_FIX
};
const TranslateId FLD_TIME_ARY[] =
{
- FLD_TIME_FIX,
- FLD_TIME_STD
+ FLD_TIME_STD,
+ FLD_TIME_FIX
};
const TranslateId FMT_NUM_ARY[] =