Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sdkjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
sdkjs
Commits
4469e7b0
Commit
4469e7b0
authored
8 years ago
by
Ilya Kirillov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Implemented forgotten work with review in footnotes. Fixed bug #33384.
parent
b144f0d0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
125 additions
and
4 deletions
+125
-4
word/Editor/Footnotes.js
word/Editor/Footnotes.js
+7
-0
word/Private/TrackRevisions.js
word/Private/TrackRevisions.js
+118
-4
No files found.
word/Editor/Footnotes.js
View file @
4469e7b0
...
...
@@ -987,6 +987,7 @@ CFootnotesController.prototype.Set_CurrentElement = function(bUpdateStates, Page
this
.
LogicDocument
.
Selection
.
Start
=
false
;
}
var
bNeedRedraw
=
this
.
LogicDocument
.
Get_DocPosType
()
===
docpostype_HdrFtr
;
this
.
LogicDocument
.
Set_DocPosType
(
docpostype_Footnotes
);
if
(
false
!=
bUpdateStates
)
...
...
@@ -995,6 +996,12 @@ CFootnotesController.prototype.Set_CurrentElement = function(bUpdateStates, Page
this
.
LogicDocument
.
Document_UpdateRulersState
();
this
.
LogicDocument
.
Document_UpdateSelectionState
();
}
if
(
bNeedRedraw
)
{
this
.
LogicDocument
.
DrawingDocument
.
ClearCachePages
();
this
.
LogicDocument
.
DrawingDocument
.
FirePaint
();
}
}
};
CFootnotesController
.
prototype
.
AddFootnoteRef
=
function
()
...
...
This diff is collapsed.
Click to expand it.
word/Private/TrackRevisions.js
View file @
4469e7b0
...
...
@@ -180,24 +180,78 @@ CDocument.prototype.private_GetRevisionsChangeParagraph = function(Direction, Cu
return
SearchEngine
;
}
var
oFootnote
=
CurrentPara
.
Parent
?
CurrentPara
.
Parent
.
Get_TopDocumentContent
()
:
null
;
var
HdrFtr
=
CurrentPara
.
Get_HdrFtr
();
if
(
null
!==
HdrFtr
)
{
this
.
private_GetRevisionsChangeParagraphInHdrFtr
(
SearchEngine
,
HdrFtr
);
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInDocument
(
SearchEngine
,
Direction
<
0
?
this
.
Content
.
length
-
1
:
0
);
if
(
Direction
>
0
)
{
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInDocument
(
SearchEngine
,
0
);
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInFooters
(
SearchEngine
,
null
);
}
else
{
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInFooters
(
SearchEngine
,
null
);
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInDocument
(
SearchEngine
,
this
.
Content
.
length
-
1
);
}
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInHdrFtr
(
SearchEngine
,
null
);
}
else
if
(
oFootnote
)
{
this
.
private_GetRevisionsChangeParagraphInFooters
(
SearchEngine
,
oFootnote
);
if
(
Direction
>
0
)
{
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInHdrFtr
(
SearchEngine
,
null
);
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInDocument
(
SearchEngine
,
0
);
}
else
{
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInDocument
(
SearchEngine
,
this
.
Content
.
length
-
1
);
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInHdrFtr
(
SearchEngine
,
null
);
}
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInFooters
(
SearchEngine
,
null
);
}
else
{
var
Pos
=
(
true
===
this
.
Selection
.
Use
&&
docpostype_DrawingObjects
!==
this
.
Get_DocPosType
()
?
(
this
.
Selection
.
StartPos
<=
this
.
Selection
.
EndPos
?
this
.
Selection
.
StartPos
:
this
.
Selection
.
EndPos
)
:
this
.
CurPos
.
ContentPos
);
this
.
private_GetRevisionsChangeParagraphInDocument
(
SearchEngine
,
Pos
);
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInHdrFtr
(
SearchEngine
,
null
);
if
(
Direction
>
0
)
{
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInFooters
(
SearchEngine
,
null
);
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInHdrFtr
(
SearchEngine
,
null
);
}
else
{
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInHdrFtr
(
SearchEngine
,
null
);
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInFooters
(
SearchEngine
,
null
);
}
if
(
true
!==
SearchEngine
.
Is_Found
())
this
.
private_GetRevisionsChangeParagraphInDocument
(
SearchEngine
,
Direction
>
0
?
0
:
this
.
Content
.
length
-
1
);
...
...
@@ -258,6 +312,45 @@ CDocument.prototype.private_GetRevisionsChangeParagraphInHdrFtr = function(Searc
AllHdrFtrs
[
Pos
].
Get_RevisionsChangeParagraph
(
SearchEngine
);
}
};
CDocument
.
prototype
.
private_GetRevisionsChangeParagraphInFooters
=
function
(
SearchEngine
,
oFootnote
)
{
var
arrFootnotes
=
this
.
Get_FootnotesList
(
null
,
null
);
var
nCount
=
arrFootnotes
.
length
;
if
(
nCount
<=
0
)
return
;
var
nPos
=
-
1
;
if
(
oFootnote
)
{
for
(
var
nIndex
=
0
;
nIndex
<
nCount
;
++
nIndex
)
{
if
(
arrFootnotes
[
nPos
]
===
oFootnote
)
{
nPos
=
nIndex
;
break
;
}
}
}
var
nDirection
=
SearchEngine
.
Get_Direction
();
if
(
nPos
<
0
||
nPos
>=
Count
)
{
if
(
nDirection
>
0
)
nPos
=
0
;
else
nPos
=
nCount
-
1
;
}
arrFootnotes
[
nPos
].
Get_RevisionsChangeParagraph
(
SearchEngine
);
while
(
true
!==
SearchEngine
.
Is_Found
())
{
nPos
=
(
nDirection
>
0
?
nPos
+
1
:
nPos
-
1
);
if
(
nPos
>=
nCount
||
nPos
<
0
)
break
;
arrFootnotes
[
nPos
].
Get_RevisionsChangeParagraph
(
SearchEngine
);
}
};
CDocument
.
prototype
.
private_SelectRevisionChange
=
function
(
Change
)
{
if
(
undefined
!==
Change
&&
Change
.
get_Paragraph
())
...
...
@@ -475,6 +568,10 @@ CDocument.prototype.Accept_RevisionChanges = function(Type, bAll)
{
this
.
DrawingObjects
.
Accept_RevisionChanges
(
Type
,
bAll
);
}
else
if
(
docpostype_Footnotes
===
this
.
CurPos
.
Type
)
{
this
.
Footnotes
.
Accept_RevisionChanges
(
Type
,
bAll
);
}
if
(
true
!==
bAll
)
{
...
...
@@ -563,6 +660,10 @@ CDocument.prototype.Reject_RevisionChanges = function(Type, bAll)
{
this
.
DrawingObjects
.
Reject_RevisionChanges
(
Type
,
bAll
);
}
else
if
(
docpostype_Footnotes
===
this
.
CurPos
.
Type
)
{
this
.
Footnotes
.
Reject_RevisionChanges
(
Type
,
bAll
);
}
if
(
true
!==
bAll
)
{
...
...
@@ -762,4 +863,17 @@ CDocumentContent.prototype.Get_RevisionsChangeParagraph = function(SearchEngine)
this
.
Content
[
Pos
].
Get_RevisionsChangeParagraph
(
SearchEngine
);
}
};
//----------------------------------------------------------------------------------------------------------------------
// CFootnotesController
//----------------------------------------------------------------------------------------------------------------------
CFootnotesController
.
prototype
.
Accept_RevisionChanges
=
function
(
Type
,
bAll
)
{
if
(
null
!==
this
.
CurFootnote
)
this
.
CurFootnote
.
Accept_RevisionChanges
(
Type
,
bAll
);
};
CFootnotesController
.
prototype
.
Reject_RevisionChanges
=
function
(
Type
,
bAll
)
{
if
(
null
!==
this
.
CurFootnote
)
this
.
CurFootnote
.
Reject_RevisionChanges
(
Type
,
bAll
);
};
\ No newline at end of file
This diff is collapsed.
Click to expand it.
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