Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
c7f0c9c9
Kaydet (Commit)
c7f0c9c9
authored
Ock 10, 2001
tarafından
Daniel Vogelheim
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
- added: redline ID property
- added: SwXRedlineText class for XML redline import
üst
52d244de
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
123 additions
and
10 deletions
+123
-10
unoprnms.hxx
sw/inc/unoprnms.hxx
+3
-2
unoredline.hxx
sw/inc/unoredline.hxx
+30
-2
unomap.cxx
sw/source/core/unocore/unomap.cxx
+3
-2
unoprnms.cxx
sw/source/core/unocore/unoprnms.cxx
+3
-2
unoredline.cxx
sw/source/core/unocore/unoredline.cxx
+84
-2
No files found.
sw/inc/unoprnms.hxx
Dosyayı görüntüle @
c7f0c9c9
...
...
@@ -2,9 +2,9 @@
*
* $RCSfile: unoprnms.hxx,v $
*
* $Revision: 1.
29
$
* $Revision: 1.
30
$
*
* last change: $Author: dvo $ $Date: 2001-01-
02 14:29:22
$
* last change: $Author: dvo $ $Date: 2001-01-
10 21:11:43
$
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
...
...
@@ -641,6 +641,7 @@ extern const SwPropNameLen __FAR_DATA UNO_NAME_REDLINE_DATE_TIME;
extern
const
SwPropNameLen
__FAR_DATA
UNO_NAME_REDLINE_COMMENT
;
extern
const
SwPropNameLen
__FAR_DATA
UNO_NAME_REDLINE_TYPE
;
extern
const
SwPropNameLen
__FAR_DATA
UNO_NAME_REDLINE_SUCCESSOR_DATA
;
extern
const
SwPropNameLen
__FAR_DATA
UNO_NAME_REDLINE_IDENTIFIER
;
#endif
...
...
sw/inc/unoredline.hxx
Dosyayı görüntüle @
c7f0c9c9
...
...
@@ -2,9 +2,9 @@
*
* $RCSfile: unoredline.hxx,v $
*
* $Revision: 1.
2
$
* $Revision: 1.
3
$
*
* last change: $Author:
os $ $Date: 2000-12-21 12:17:15
$
* last change: $Author:
dvo $ $Date: 2001-01-10 21:11:43
$
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
...
...
@@ -68,6 +68,34 @@
/* -----------------------------19.12.00 11:35--------------------------------
---------------------------------------------------------------------------*/
/**
* SwXRedlineText provides an XText which may be used to write
* directly into a redline node. It got implemented to enable XML
* import of redlines and should not be used directly via the API.
*/
class
SwXRedlineText
:
public
SwXText
,
public
cppu
::
OWeakObject
{
SwNodeIndex
aNodeIndex
;
public
:
SwXRedlineText
(
SwDoc
*
pDoc
,
SwNodeIndex
aNodeIndex
);
virtual
::
com
::
sun
::
star
::
uno
::
Any
SAL_CALL
queryInterface
(
const
::
com
::
sun
::
star
::
uno
::
Type
&
aType
)
throw
(
::
com
::
sun
::
star
::
uno
::
RuntimeException
);
virtual
void
SAL_CALL
acquire
(
)
throw
(){
OWeakObject
::
acquire
();}
virtual
void
SAL_CALL
release
(
)
throw
(){
OWeakObject
::
release
();}
virtual
::
com
::
sun
::
star
::
uno
::
Sequence
<
::
com
::
sun
::
star
::
uno
::
Type
>
SAL_CALL
getTypes
(
)
throw
(
::
com
::
sun
::
star
::
uno
::
RuntimeException
);
virtual
::
com
::
sun
::
star
::
uno
::
Sequence
<
sal_Int8
>
SAL_CALL
getImplementationId
(
)
throw
(
::
com
::
sun
::
star
::
uno
::
RuntimeException
);
//XText
virtual
::
com
::
sun
::
star
::
uno
::
Reference
<
::
com
::
sun
::
star
::
text
::
XTextCursor
>
SAL_CALL
createTextCursor
(
void
)
throw
(
::
com
::
sun
::
star
::
uno
::
RuntimeException
);
virtual
::
com
::
sun
::
star
::
uno
::
Reference
<
::
com
::
sun
::
star
::
text
::
XTextCursor
>
SAL_CALL
createTextCursorByRange
(
const
::
com
::
sun
::
star
::
uno
::
Reference
<
::
com
::
sun
::
star
::
text
::
XTextRange
>
&
aTextPosition
)
throw
(
::
com
::
sun
::
star
::
uno
::
RuntimeException
);
};
class
SwXRedlinePortion
:
public
SwXTextPortion
,
public
SwXText
,
public
::
com
::
sun
::
star
::
container
::
XEnumerationAccess
...
...
sw/source/core/unocore/unomap.cxx
Dosyayı görüntüle @
c7f0c9c9
...
...
@@ -2,9 +2,9 @@
*
* $RCSfile: unomap.cxx,v $
*
* $Revision: 1.3
7
$
* $Revision: 1.3
8
$
*
* last change: $Author: dvo $ $Date: 2001-01-
02 14:29:24
$
* last change: $Author: dvo $ $Date: 2001-01-
10 21:11:42
$
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
...
...
@@ -1862,6 +1862,7 @@ const SfxItemPropertyMap* SwUnoPropertyMapProvider::GetPropertyMap(sal_uInt16
{
SW_PROP_NAME
(
UNO_NAME_REDLINE_COMMENT
),
0
,
&::
getCppuType
((
OUString
*
)
0
),
PropertyAttribute
::
MAYBEVOID
|
PropertyAttribute
::
READONLY
,
0
},
{
SW_PROP_NAME
(
UNO_NAME_REDLINE_TYPE
),
0
,
&::
getCppuType
((
OUString
*
)
0
),
PropertyAttribute
::
MAYBEVOID
|
PropertyAttribute
::
READONLY
,
0
},
{
SW_PROP_NAME
(
UNO_NAME_REDLINE_SUCCESSOR_DATA
),
0
,
&::
getCppuType
((
Sequence
<
PropertyValue
>*
)
0
),
PropertyAttribute
::
MAYBEVOID
|
PropertyAttribute
::
READONLY
,
0
},
{
SW_PROP_NAME
(
UNO_NAME_REDLINE_IDENTIFIER
),
0
,
&::
getCppuType
((
OUString
*
)
0
),
PropertyAttribute
::
MAYBEVOID
|
PropertyAttribute
::
READONLY
,
0
},
{
SW_PROP_NAME
(
UNO_NAME_TEXT_PORTION_TYPE
),
0
,
&::
getCppuType
((
OUString
*
)
0
),
PropertyAttribute
::
READONLY
,
0
},
{
0
,
0
,
0
,
0
}
};
...
...
sw/source/core/unocore/unoprnms.cxx
Dosyayı görüntüle @
c7f0c9c9
...
...
@@ -2,9 +2,9 @@
*
* $RCSfile: unoprnms.cxx,v $
*
* $Revision: 1.3
1
$
* $Revision: 1.3
2
$
*
* last change: $Author: dvo $ $Date: 2001-01-
02 14:29:24
$
* last change: $Author: dvo $ $Date: 2001-01-
10 21:11:42
$
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
...
...
@@ -636,3 +636,4 @@ const SwPropNameLen __FAR_DATA UNO_NAME_REDLINE_DATE_TIME (MAP
const
SwPropNameLen
__FAR_DATA
UNO_NAME_REDLINE_COMMENT
(
MAP_CHAR_LEN
(
"RedlineComment"
));
const
SwPropNameLen
__FAR_DATA
UNO_NAME_REDLINE_TYPE
(
MAP_CHAR_LEN
(
"RedlineType"
));
const
SwPropNameLen
__FAR_DATA
UNO_NAME_REDLINE_SUCCESSOR_DATA
(
MAP_CHAR_LEN
(
"RedlineSuccessorData"
));
const
SwPropNameLen
__FAR_DATA
UNO_NAME_REDLINE_IDENTIFIER
(
MAP_CHAR_LEN
(
"RedlineIdentifier"
));
sw/source/core/unocore/unoredline.cxx
Dosyayı görüntüle @
c7f0c9c9
...
...
@@ -2,9 +2,9 @@
*
* $RCSfile: unoredline.cxx,v $
*
* $Revision: 1.
4
$
* $Revision: 1.
5
$
*
* last change: $Author: dvo $ $Date: 2001-01-
08 11:48:58
$
* last change: $Author: dvo $ $Date: 2001-01-
10 21:11:42
$
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
...
...
@@ -99,6 +99,9 @@
#include <rtl/uuid.h>
#endif
#ifndef _RTL_USTRBUF_HXX_
#include <rtl/ustrbuf.hxx>
#endif
#ifndef _COM_SUN_STAR_UTIL_DATETIME_HPP_
#include <com/sun/star/util/DateTime.hpp>
#endif
...
...
@@ -111,6 +114,73 @@ using namespace ::com::sun::star::container;
using
namespace
::
com
::
sun
::
star
::
beans
;
using
namespace
::
rtl
;
/* -----------------------------19.12.00 11:36--------------------------------
---------------------------------------------------------------------------*/
SwXRedlineText
::
SwXRedlineText
(
SwDoc
*
pDoc
,
SwNodeIndex
aIndex
)
:
SwXText
(
pDoc
,
CURSOR_REDLINE
),
aNodeIndex
(
aIndex
)
{
}
Any
SwXRedlineText
::
queryInterface
(
const
Type
&
rType
)
throw
(
RuntimeException
)
{
// deledate to SwXText and OWeakObject
Any
aRet
=
SwXText
::
queryInterface
(
rType
);
if
(
!
aRet
.
hasValue
())
{
aRet
=
OWeakObject
::
queryInterface
(
rType
);
}
return
aRet
;
}
Sequence
<
Type
>
SwXRedlineText
::
getTypes
()
throw
(
RuntimeException
)
{
// merge getTypes() from superclasses
// SwXText::getTypes()
uno
::
Sequence
<
uno
::
Type
>
aTypes
=
SwXText
::
getTypes
();
return
aTypes
;
}
Sequence
<
sal_Int8
>
SwXRedlineText
::
getImplementationId
()
throw
(
RuntimeException
)
{
static
uno
::
Sequence
<
sal_Int8
>
aId
(
16
);
static
sal_Bool
bInit
=
FALSE
;
if
(
!
bInit
)
rtl_createUuid
(
(
sal_uInt8
*
)
aId
.
getArray
(),
0
,
sal_True
);
return
aId
;
}
Reference
<
XTextCursor
>
SwXRedlineText
::
createTextCursor
(
void
)
throw
(
RuntimeException
)
{
vos
::
OGuard
aGuard
(
Application
::
GetSolarMutex
());
SwPosition
aPos
(
aNodeIndex
);
SwXTextCursor
*
pCrsr
=
new
SwXTextCursor
(
this
,
aPos
,
CURSOR_REDLINE
,
GetDoc
());
SwUnoCrsr
*
pUnoCursor
=
pCrsr
->
GetCrsr
();
pUnoCursor
->
Move
(
fnMoveForward
,
fnGoNode
);
return
(
XWordCursor
*
)
pCrsr
;
}
Reference
<
XTextCursor
>
SwXRedlineText
::
createTextCursorByRange
(
const
Reference
<
XTextRange
>
&
aTextRange
)
throw
(
RuntimeException
)
{
Reference
<
XTextCursor
>
xCursor
=
createTextCursor
();
xCursor
->
gotoRange
(
aTextRange
->
getStart
(),
sal_False
);
xCursor
->
gotoRange
(
aTextRange
->
getEnd
(),
sal_True
);
return
xCursor
;
}
/* -----------------------------19.12.00 11:36--------------------------------
---------------------------------------------------------------------------*/
...
...
@@ -119,6 +189,7 @@ SwXRedlinePortion::SwXRedlinePortion( const SwRedline* pRed,
Reference
<
XText
>
xParent
,
BOOL
bStart
)
:
SwXTextPortion
(
pPortionCrsr
,
xParent
,
bStart
?
PORTION_REDLINE_START
:
PORTION_REDLINE_END
),
SwXText
(
pPortionCrsr
->
GetDoc
(),
CURSOR_REDLINE
),
// SwXRedlineText(pPortionCrsr->GetDoc(), *pRed->GetContentIdx()),
pRedline
(
pRed
)
{
SetCollapsed
(
!
pRedline
->
HasMark
());
...
...
@@ -276,6 +347,17 @@ Any SwXRedlinePortion::getPropertyValue( const OUString& rPropertyName )
aRet
<<=
aValues
;
}
}
else
if
(
rPropertyName
.
equalsAsciiL
(
UNO_NAME_REDLINE_IDENTIFIER
.
pName
,
UNO_NAME_REDLINE_IDENTIFIER
.
nNameLen
))
{
// create identifier from SwRedline address (if available)
if
(
NULL
!=
pRedline
)
{
OUStringBuffer
sBuf
;
sBuf
.
append
((
sal_Int64
)
pRedline
);
aRet
<<=
sBuf
.
makeStringAndClear
();
}
}
else
aRet
=
SwXTextPortion
::
getPropertyValue
(
rPropertyName
);
return
aRet
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment