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
2025fe8d
Commit
2025fe8d
authored
Oct 11, 2016
by
Alexander.Trofimov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bug 33202
parent
7c46b97d
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
322 additions
and
309 deletions
+322
-309
cell/model/History.js
cell/model/History.js
+1
-1
cell/model/Workbook.js
cell/model/Workbook.js
+1
-1
cell/view/WorkbookView.js
cell/view/WorkbookView.js
+2
-2
cell/view/WorksheetView.js
cell/view/WorksheetView.js
+318
-305
No files found.
cell/model/History.js
View file @
2025fe8d
...
...
@@ -371,7 +371,7 @@ CHistory.prototype.UndoRedoEnd = function (Point, oRedoObjectParam, bUndo) {
}
for
(
i
in
Point
.
UpdateRigions
)
this
.
workbook
.
handlers
.
trigger
(
"
cleanCellCache
"
,
i
,
{
'
0
'
:
Point
.
UpdateRigions
[
i
]},
false
,
true
,
oRedoObjectParam
.
bAddRemoveRowCol
);
this
.
workbook
.
handlers
.
trigger
(
"
cleanCellCache
"
,
i
,
{
'
0
'
:
Point
.
UpdateRigions
[
i
]},
true
,
oRedoObjectParam
.
bAddRemoveRowCol
);
for
(
i
in
oRedoObjectParam
.
oChangeWorksheetUpdate
)
this
.
workbook
.
handlers
.
trigger
(
"
changeWorksheetUpdate
"
,
...
...
cell/model/Workbook.js
View file @
2025fe8d
...
...
@@ -3179,7 +3179,7 @@ Workbook.prototype.getTableNameColumnByIndex = function(tableName, columnIndex){
}
}
for
(
i
in
oCleanCellCacheArea
)
{
this
.
handlers
.
trigger
(
"
cleanCellCache
"
,
i
,
oCleanCellCacheArea
[
i
]
,
AscCommonExcel
.
c_oAscCanChangeColWidth
.
none
);
this
.
handlers
.
trigger
(
"
cleanCellCache
"
,
i
,
oCleanCellCacheArea
[
i
]);
}
AscCommonExcel
.
g_oVLOOKUPCache
.
clean
();
...
...
cell/view/WorkbookView.js
View file @
2025fe8d
...
...
@@ -689,10 +689,10 @@
}
});
this
.
model
.
handlers
.
add
(
"
cleanCellCache
"
,
function
(
wsId
,
oRanges
,
canChangeColWidth
,
bLockDraw
,
updateHeight
)
{
this
.
model
.
handlers
.
add
(
"
cleanCellCache
"
,
function
(
wsId
,
oRanges
,
bLockDraw
,
updateHeight
)
{
var
ws
=
self
.
getWorksheetById
(
wsId
,
true
);
if
(
ws
)
{
ws
.
updateRanges
(
oRanges
,
canChangeColWidth
,
bLockDraw
||
wsId
!=
self
.
getWorksheet
(
self
.
wsActive
).
model
.
getId
(),
updateHeight
);
ws
.
updateRanges
(
oRanges
,
bLockDraw
||
wsId
!=
self
.
getWorksheet
(
self
.
wsActive
).
model
.
getId
(),
updateHeight
);
}
});
this
.
model
.
handlers
.
add
(
"
changeWorksheetUpdate
"
,
function
(
wsId
,
val
)
{
...
...
cell/view/WorksheetView.js
View file @
2025fe8d
...
...
@@ -4412,75 +4412,73 @@
}
};
WorksheetView
.
prototype
.
_addCellTextToCache
=
function
(
col
,
row
,
canChangeColWidth
)
{
WorksheetView
.
prototype
.
_addCellTextToCache
=
function
(
col
,
row
,
canChangeColWidth
)
{
var
self
=
this
;
function
makeFnIsGoodNumFormat
(
flags
,
width
)
{
return
function
(
str
)
{
return
self
.
stringRender
.
measureString
(
str
,
flags
,
width
).
width
<=
width
;
function
makeFnIsGoodNumFormat
(
flags
,
width
)
{
return
function
(
str
)
{
return
self
.
stringRender
.
measureString
(
str
,
flags
,
width
).
width
<=
width
;
};
}
var
c
=
this
.
_getCell
(
col
,
row
);
if
(
null
===
c
)
{
var
c
=
this
.
_getCell
(
col
,
row
);
if
(
null
===
c
)
{
return
col
;
}
var
bUpdateScrollX
=
false
;
var
bUpdateScrollY
=
false
;
// Проверка на увеличение колличества столбцов
if
(
col
>=
this
.
cols
.
length
)
{
bUpdateScrollX
=
this
.
expandColsOnScroll
(
/*isNotActive*/
false
,
/*updateColsCount*/
true
);
if
(
col
>=
this
.
cols
.
length
)
{
bUpdateScrollX
=
this
.
expandColsOnScroll
(
/*isNotActive*/
false
,
/*updateColsCount*/
true
);
}
// Проверка на увеличение колличества строк
if
(
row
>=
this
.
rows
.
length
)
{
bUpdateScrollY
=
this
.
expandRowsOnScroll
(
/*isNotActive*/
false
,
/*updateRowsCount*/
true
);
}
if
(
bUpdateScrollX
&&
bUpdateScrollY
)
{
this
.
handlers
.
trigger
(
"
reinitializeScroll
"
);
if
(
row
>=
this
.
rows
.
length
)
{
bUpdateScrollY
=
this
.
expandRowsOnScroll
(
/*isNotActive*/
false
,
/*updateRowsCount*/
true
);
}
else
if
(
bUpdateScrollX
)
{
this
.
handlers
.
trigger
(
"
reinitializeScrollX
"
);
}
else
if
(
bUpdateScrollY
)
{
this
.
handlers
.
trigger
(
"
reinitializeScrollY
"
);
if
(
bUpdateScrollX
&&
bUpdateScrollY
)
{
this
.
handlers
.
trigger
(
"
reinitializeScroll
"
);
}
else
if
(
bUpdateScrollX
)
{
this
.
handlers
.
trigger
(
"
reinitializeScrollX
"
);
}
else
if
(
bUpdateScrollY
)
{
this
.
handlers
.
trigger
(
"
reinitializeScrollY
"
);
}
var
str
,
tm
,
isMerged
=
false
,
strCopy
;
// Range для замерженной ячейки
var
fl
=
this
.
_getCellFlags
(
c
);
var
fl
=
this
.
_getCellFlags
(
c
);
var
mc
=
fl
.
merged
;
var
fMergedColumns
=
false
;
// Замержены ли колонки (если да, то автоподбор ширины не должен работать)
var
fMergedRows
=
false
;
// Замержены ли строки (если да, то автоподбор высоты не должен работать)
if
(
null
!==
mc
)
{
if
(
col
!==
mc
.
c1
||
row
!==
mc
.
r1
)
{
if
(
null
!==
mc
)
{
if
(
col
!==
mc
.
c1
||
row
!==
mc
.
r1
)
{
// Проверим внесена ли первая ячейка в cache (иначе если была скрыта первая строка или первый столбец, то мы не внесем)
if
(
undefined
===
this
.
_getCellTextCache
(
mc
.
c1
,
mc
.
r1
,
true
))
{
return
this
.
_addCellTextToCache
(
mc
.
c1
,
mc
.
r1
,
canChangeColWidth
);
}
return
mc
.
c2
;
}
// skip other merged cell from range
if
(
mc
.
c1
!==
mc
.
c2
)
{
if
(
mc
.
c1
!==
mc
.
c2
)
{
fMergedColumns
=
true
;
}
if
(
mc
.
r1
!==
mc
.
r2
)
{
if
(
mc
.
r1
!==
mc
.
r2
)
{
fMergedRows
=
true
;
}
isMerged
=
true
;
}
var
angle
=
c
.
getAngle
();
if
(
this
.
_isCellEmptyTextString
(
c
)
)
{
if
(
!
angle
&&
c
.
isNotDefaultFont
()
)
{
if
(
this
.
_isCellEmptyTextString
(
c
)
)
{
if
(
!
angle
&&
c
.
isNotDefaultFont
()
)
{
// Пустая ячейка с измененной гарнитурой или размером, учитвается в высоте
str
=
c
.
getValue2
();
if
(
0
<
str
.
length
)
{
if
(
0
<
str
.
length
)
{
// Без текста не будет толка
strCopy
=
[
str
[
0
].
clone
()];
strCopy
[
0
].
text
=
'
A
'
;
tm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
strCopy
,
fl
)
);
this
.
_updateRowHeight
(
tm
,
col
,
row
,
isMerged
,
fMergedRows
);
tm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
strCopy
,
fl
)
);
this
.
_updateRowHeight
(
tm
,
col
,
row
,
isMerged
,
fMergedRows
);
}
}
...
...
@@ -4495,51 +4493,53 @@
var
pad
=
this
.
width_padding
*
2
+
this
.
width_1px
;
var
sstr
,
sfl
,
stm
;
if
(
!
this
.
cols
[
col
].
isCustomWidth
&&
fl
.
isNumberFormat
&&
!
fMergedColumns
&&
(
c_oAscCanChangeColWidth
.
numbers
===
canChangeColWidth
||
c_oAscCanChangeColWidth
.
all
===
canChangeColWidth
)
)
{
if
(
!
this
.
cols
[
col
].
isCustomWidth
&&
fl
.
isNumberFormat
&&
!
fMergedColumns
&&
(
c_oAscCanChangeColWidth
.
numbers
===
canChangeColWidth
||
c_oAscCanChangeColWidth
.
all
===
canChangeColWidth
))
{
colWidth
=
this
.
cols
[
col
].
innerWidth
;
// Измеряем целую часть числа
sstr
=
c
.
getValue2
(
gc_nMaxDigCountView
,
function
()
{
sstr
=
c
.
getValue2
(
gc_nMaxDigCountView
,
function
()
{
return
true
;
}
);
if
(
"
General
"
===
numFormatStr
&&
c_oAscCanChangeColWidth
.
all
!==
canChangeColWidth
)
{
});
if
(
"
General
"
===
numFormatStr
&&
c_oAscCanChangeColWidth
.
all
!==
canChangeColWidth
)
{
// asc.truncFracPart изменяет исходный массив, поэтому клонируем
var
fragmentsTmp
=
[];
for
(
var
k
=
0
;
k
<
sstr
.
length
;
++
k
)
fragmentsTmp
.
push
(
sstr
[
k
].
clone
()
);
sstr
=
asc
.
truncFracPart
(
fragmentsTmp
);
for
(
var
k
=
0
;
k
<
sstr
.
length
;
++
k
)
{
fragmentsTmp
.
push
(
sstr
[
k
].
clone
());
}
sstr
=
asc
.
truncFracPart
(
fragmentsTmp
);
}
sfl
=
fl
.
clone
();
sfl
.
wrapText
=
false
;
stm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
sstr
,
sfl
,
colWidth
)
);
stm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
sstr
,
sfl
,
colWidth
)
);
// Если целая часть числа не убирается в ячейку, то расширяем столбец
if
(
stm
.
width
>
colWidth
)
{
this
.
_changeColWidth
(
col
,
stm
.
width
,
pad
);
if
(
stm
.
width
>
colWidth
)
{
this
.
_changeColWidth
(
col
,
stm
.
width
,
pad
);
}
// Обновленная ячейка
dDigitsCount
=
this
.
cols
[
col
].
charCount
;
colWidth
=
this
.
cols
[
col
].
innerWidth
;
}
else
if
(
null
===
mc
)
{
}
else
if
(
null
===
mc
)
{
// Обычная ячейка
dDigitsCount
=
this
.
cols
[
col
].
charCount
;
colWidth
=
this
.
cols
[
col
].
innerWidth
;
// подбираем ширину
if
(
!
this
.
cols
[
col
].
isCustomWidth
&&
!
fMergedColumns
&&
!
fl
.
wrapText
&&
c_oAscCanChangeColWidth
.
all
===
canChangeColWidth
)
{
sstr
=
c
.
getValue2
(
gc_nMaxDigCountView
,
function
()
{
if
(
!
this
.
cols
[
col
].
isCustomWidth
&&
!
fMergedColumns
&&
!
fl
.
wrapText
&&
c_oAscCanChangeColWidth
.
all
===
canChangeColWidth
)
{
sstr
=
c
.
getValue2
(
gc_nMaxDigCountView
,
function
()
{
return
true
;
}
);
stm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
sstr
,
fl
,
colWidth
)
);
if
(
stm
.
width
>
colWidth
)
{
this
.
_changeColWidth
(
col
,
stm
.
width
,
pad
);
});
stm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
sstr
,
fl
,
colWidth
)
);
if
(
stm
.
width
>
colWidth
)
{
this
.
_changeColWidth
(
col
,
stm
.
width
,
pad
);
// Обновленная ячейка
dDigitsCount
=
this
.
cols
[
col
].
charCount
;
colWidth
=
this
.
cols
[
col
].
innerWidth
;
}
}
}
else
{
}
else
{
// Замерженная ячейка, нужна сумма столбцов
for
(
var
i
=
mc
.
c1
;
i
<=
mc
.
c2
&&
i
<
this
.
cols
.
length
;
++
i
)
{
for
(
var
i
=
mc
.
c1
;
i
<=
mc
.
c2
&&
i
<
this
.
cols
.
length
;
++
i
)
{
colWidth
+=
this
.
cols
[
i
].
width
;
dDigitsCount
+=
this
.
cols
[
i
].
charCount
;
}
...
...
@@ -4549,33 +4549,34 @@
var
rowHeight
=
this
.
rows
[
row
].
height
;
// ToDo dDigitsCount нужно рассчитывать исходя не из дефалтового шрифта и размера, а исходя из текущего шрифта и размера ячейки
str
=
c
.
getValue2
(
dDigitsCount
,
makeFnIsGoodNumFormat
(
fl
,
colWidth
)
);
str
=
c
.
getValue2
(
dDigitsCount
,
makeFnIsGoodNumFormat
(
fl
,
colWidth
)
);
var
ha
=
c
.
getAlignHorizontalByValue
().
toLowerCase
();
var
va
=
c
.
getAlignVertical
().
toLowerCase
();
var
maxW
=
fl
.
wrapText
||
fl
.
shrinkToFit
||
isMerged
||
asc
.
isFixedWidthCell
(
str
)
?
this
.
_calcMaxWidth
(
col
,
row
,
mc
)
:
undefined
;
tm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
str
,
fl
,
maxW
)
);
var
maxW
=
fl
.
wrapText
||
fl
.
shrinkToFit
||
isMerged
||
asc
.
isFixedWidthCell
(
str
)
?
this
.
_calcMaxWidth
(
col
,
row
,
mc
)
:
undefined
;
tm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
str
,
fl
,
maxW
));
var
cto
=
(
isMerged
||
fl
.
wrapText
)
?
{
maxWidth
:
maxW
-
this
.
cols
[
col
].
innerWidth
+
this
.
cols
[
col
].
width
,
leftSide
:
0
,
rightSide
:
0
}
:
this
.
_calcCellTextOffset
(
col
,
row
,
ha
,
tm
.
width
);
}
:
this
.
_calcCellTextOffset
(
col
,
row
,
ha
,
tm
.
width
);
// check right side of cell text and append columns if it exceeds existing cells borders
if
(
!
isMerged
)
{
if
(
!
isMerged
)
{
var
rside
=
this
.
cols
[
col
-
cto
.
leftSide
].
left
+
tm
.
width
;
var
lc
=
this
.
cols
[
this
.
cols
.
length
-
1
];
if
(
rside
>
lc
.
left
+
lc
.
width
)
{
this
.
_appendColumns
(
rside
);
cto
=
this
.
_calcCellTextOffset
(
col
,
row
,
ha
,
tm
.
width
);
if
(
rside
>
lc
.
left
+
lc
.
width
)
{
this
.
_appendColumns
(
rside
);
cto
=
this
.
_calcCellTextOffset
(
col
,
row
,
ha
,
tm
.
width
);
}
}
var
oFontColor
=
c
.
getFontcolor
();
var
textBound
=
{};
if
(
angle
)
{
if
(
angle
)
{
// повернутый текст учитывает мерж ячеек по строкам
if
(
fMergedRows
)
{
if
(
fMergedRows
)
{
rowHeight
=
0
;
for
(
var
j
=
mc
.
r1
;
j
<=
mc
.
r2
&&
j
<
this
.
nRowsCount
;
++
j
)
{
for
(
var
j
=
mc
.
r1
;
j
<=
mc
.
r2
&&
j
<
this
.
nRowsCount
;
++
j
)
{
rowHeight
+=
this
.
rows
[
j
].
height
;
}
}
...
...
@@ -4584,20 +4585,20 @@
if
(
fl
.
wrapText
)
{
if
(
this
.
rows
[
row
].
isCustomHeight
)
{
tm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
str
,
fl
,
rowHeight
)
);
textBound
=
this
.
stringRender
.
getTransformBound
(
angle
,
colWidth
,
rowHeight
,
tm
.
width
,
ha
,
va
,
rowHeight
);
}
else
{
tm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
str
,
fl
,
rowHeight
)
);
textBound
=
this
.
stringRender
.
getTransformBound
(
angle
,
colWidth
,
rowHeight
,
tm
.
width
,
ha
,
va
,
rowHeight
);
}
else
{
if
(
!
fMergedRows
)
{
rowHeight
=
tm
.
height
;
}
tm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
str
,
fl
,
rowHeight
)
);
textBound
=
this
.
stringRender
.
getTransformBound
(
angle
,
colWidth
,
rowHeight
,
tm
.
width
,
ha
,
va
,
tm
.
width
);
}
tm
=
this
.
_roundTextMetrics
(
this
.
stringRender
.
measureString
(
str
,
fl
,
rowHeight
)
);
textBound
=
this
.
stringRender
.
getTransformBound
(
angle
,
colWidth
,
rowHeight
,
tm
.
width
,
ha
,
va
,
tm
.
width
);
}
else
{
textBound
=
this
.
stringRender
.
getTransformBound
(
angle
,
colWidth
,
rowHeight
,
textW
,
ha
,
va
,
maxW
);
}
else
{
textBound
=
this
.
stringRender
.
getTransformBound
(
angle
,
colWidth
,
rowHeight
,
textW
,
ha
,
va
,
maxW
);
}
// NOTE: если проекция строчки на Y больше высоты ячейки подставлять # и рисовать все по центру
...
...
@@ -4619,29 +4620,29 @@
// }
}
this
.
_fetchCellCache
(
col
,
row
).
text
=
{
state
:
this
.
stringRender
.
getInternalState
(),
flags
:
fl
,
color
:
(
oFontColor
||
this
.
settings
.
cells
.
defaultState
.
color
),
metrics
:
tm
,
cellW
:
cto
.
maxWidth
,
cellHA
:
ha
,
cellVA
:
va
,
sideL
:
cto
.
leftSide
,
sideR
:
cto
.
rightSide
,
cellType
:
cellType
,
this
.
_fetchCellCache
(
col
,
row
).
text
=
{
state
:
this
.
stringRender
.
getInternalState
(),
flags
:
fl
,
color
:
(
oFontColor
||
this
.
settings
.
cells
.
defaultState
.
color
),
metrics
:
tm
,
cellW
:
cto
.
maxWidth
,
cellHA
:
ha
,
cellVA
:
va
,
sideL
:
cto
.
leftSide
,
sideR
:
cto
.
rightSide
,
cellType
:
cellType
,
isFormula
:
c
.
isFormula
(),
angle
:
angle
,
angle
:
angle
,
textBound
:
textBound
};
this
.
_fetchCellCacheText
(
col
,
row
).
hasText
=
true
;
this
.
_fetchCellCacheText
(
col
,
row
).
hasText
=
true
;
if
(
!
angle
&&
(
cto
.
leftSide
!==
0
||
cto
.
rightSide
!==
0
)
)
{
this
.
_addErasedBordersToCache
(
col
-
cto
.
leftSide
,
col
+
cto
.
rightSide
,
row
);
if
(
!
angle
&&
(
cto
.
leftSide
!==
0
||
cto
.
rightSide
!==
0
)
)
{
this
.
_addErasedBordersToCache
(
col
-
cto
.
leftSide
,
col
+
cto
.
rightSide
,
row
);
}
this
.
_updateRowHeight
(
tm
,
col
,
row
,
fl
,
isMerged
,
fMergedRows
,
va
,
ha
,
angle
,
maxW
,
colWidth
,
textBound
);
this
.
_updateRowHeight
(
tm
,
col
,
row
,
fl
,
isMerged
,
fMergedRows
,
va
,
ha
,
angle
,
maxW
,
colWidth
,
textBound
);
return
mc
?
mc
.
c2
:
col
;
};
...
...
@@ -8486,25 +8487,25 @@
}
var
t
=
this
;
var
checkRange
=
null
;
var
checkRange
=
[]
;
var
activeCell
=
this
.
model
.
selectionRange
.
activeCell
.
clone
();
var
arn
=
this
.
model
.
selectionRange
.
getLast
().
clone
(
true
);
if
(
onlyActive
)
{
checkRange
=
new
asc_Range
(
activeCell
.
col
,
activeCell
.
row
,
activeCell
.
col
,
activeCell
.
row
);
checkRange
.
push
(
new
asc_Range
(
activeCell
.
col
,
activeCell
.
row
,
activeCell
.
col
,
activeCell
.
row
));
}
else
{
checkRange
=
arn
.
getAllRange
();
this
.
model
.
selectionRange
.
ranges
.
forEach
(
function
(
item
)
{
checkRange
.
push
(
item
.
getAllRange
());
});
}
var
onSelectionCallback
=
function
(
isSuccess
)
{
if
(
false
===
isSuccess
)
{
return
;
}
var
range
=
t
.
model
.
getRange3
(
checkRange
.
r1
,
checkRange
.
c1
,
checkRange
.
r2
,
checkRange
.
c2
);
var
canChangeColWidth
=
c_oAscCanChangeColWidth
.
none
;
var
bIsUpdate
=
true
;
var
oUpdateRanges
=
{},
hasUpdates
=
false
;
var
isLargeRange
=
t
.
_isLargeRange
(
range
.
bbox
),
callTrigger
=
false
;
var
callTrigger
=
false
;
var
res
;
var
mc
,
r
,
c
,
cell
;
...
...
@@ -8528,6 +8529,11 @@
History
.
Create_NewPoint
();
History
.
StartTransaction
();
checkRange
.
forEach
(
function
(
item
,
i
)
{
var
range
=
t
.
model
.
getRange3
(
item
.
r1
,
item
.
c1
,
item
.
r2
,
item
.
c2
);
var
isLargeRange
=
t
.
_isLargeRange
(
range
.
bbox
);
var
canChangeColWidth
=
c_oAscCanChangeColWidth
.
none
;
switch
(
prop
)
{
case
"
fn
"
:
range
.
setFontname
(
val
);
...
...
@@ -8745,12 +8751,19 @@
}
if
(
bIsUpdate
)
{
hasUpdates
=
true
;
oUpdateRanges
[
i
]
=
item
;
oUpdateRanges
[
i
].
canChangeColWidth
=
canChangeColWidth
;
bIsUpdate
=
false
;
}
});
if
(
hasUpdates
)
{
t
.
updateRanges
(
oUpdateRanges
,
false
,
true
);
}
if
(
callTrigger
)
{
t
.
handlers
.
trigger
(
"
slowOperation
"
,
false
);
}
t
.
isChanged
=
true
;
t
.
_updateCellsRange
(
arn
,
canChangeColWidth
);
}
//в случае, если вставляем из глобального буфера, транзакцию закрываем внутри функции _loadDataBeforePaste на callbacks от загрузки шрифтов и картинок
if
(
prop
!==
"
paste
"
||
(
prop
===
"
paste
"
&&
isLocal
))
{
...
...
@@ -8760,9 +8773,9 @@
if
(
"
paste
"
===
prop
&&
val
.
onlyImages
!==
true
)
{
// Для past свой диапазон
if
(
isLocal
===
"
binary
"
)
{
checkRange
=
t
.
_pasteFromBinary
(
val
,
true
);
checkRange
.
push
(
this
.
_pasteFromBinary
(
val
,
true
)
);
}
else
{
checkRange
=
t
.
_pasteFromHTML
(
val
,
true
);
checkRange
.
push
(
this
.
_pasteFromHTML
(
val
,
true
)
);
}
}
if
(
"
paste
"
===
prop
&&
val
.
onlyImages
===
true
)
{
...
...
@@ -11121,11 +11134,11 @@
* @param lockDraw
* @param updateHeight
*/
WorksheetView
.
prototype
.
updateRanges
=
function
(
ranges
,
canChangeColWidth
,
lockDraw
,
updateHeight
)
{
WorksheetView
.
prototype
.
updateRanges
=
function
(
ranges
,
lockDraw
,
updateHeight
)
{
var
arrRanges
=
[],
range
;
for
(
var
i
in
ranges
)
{
range
=
ranges
[
i
];
this
.
updateRange
(
range
,
canChangeColWidth
,
true
);
this
.
updateRange
(
range
,
range
.
canChangeColWidth
||
c_oAscCanChangeColWidth
.
none
,
true
);
arrRanges
.
push
(
range
);
}
...
...
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