LibreOffice Module writerfilter (master) 1
TrackChangesHandler.cxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 */
11#include "PropertyMap.hxx"
12#include "ConversionHelper.hxx"
13#include <ooxml/resourceids.hxx>
14#include <oox/token/tokens.hxx>
15#include <osl/diagnose.h>
16
17namespace writerfilter::dmapper {
18
19using namespace ::com::sun::star;
20using namespace oox;
21
22
24 LoggedProperties("TrackChangesHandler"),
25 m_pRedlineParams(new RedlineParams)
26{
27 m_pRedlineParams->m_nToken = nToken;
28}
29
30
32{
33}
34
35
37{
38 OUString sStringValue = rVal.getString();
39 switch( rName )
40 {
41 case NS_ooxml::LN_CT_TrackChange_author:
42 {
43 m_pRedlineParams->m_sAuthor = sStringValue;
44 }
45 break;
46 case NS_ooxml::LN_CT_TrackChange_date:
47 {
48 m_pRedlineParams->m_sDate = sStringValue;
49 }
50 break;
51 case NS_ooxml::LN_CT_Markup_id:
52 break;
53 default:
54 OSL_FAIL( "unknown attribute");
55 }
56}
57
59{
60 OUString sType;
61 switch ( m_pRedlineParams->m_nToken & 0xffff )
62 {
63 case XML_tableRowInsert:
65 break;
66 case XML_tableRowDelete:
68 break;
69 case XML_tableCellInsert:
71 break;
72 case XML_tableCellDelete:
74 break;
75 }
76 return {
80 //comphelper::makePropertyValue(getPropertyName(PROP_REDLINE_REVERT_PROPERTIES), uno::Any(pRedline->m_aRevertProperties))
81 };
82}
83
85
86} //namespace writerfilter::dmapper
87
88/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
OptionalString sType
An SPRM: Section, Paragraph and Run Modifier.
virtual OUString getString() const =0
Returns string representation of the value.
virtual void lcl_sprm(Sprm &sprm) override
css::uno::Sequence< css::beans::PropertyValue > getRedlineProperties() const
Compute the UNO properties for the track changes object based on the received tokens.
virtual void lcl_attribute(Id Name, Value &val) override
css::beans::PropertyValue makePropertyValue(const OUString &rName, T &&rValue)
util::DateTime ConvertDateStringToDateTime(std::u16string_view rDateTime)
OUString getPropertyName(PropertyIds eId)
DefTokenId nToken
sal_uInt32 Id