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
e059b27f
Commit
e059b27f
authored
Jul 27, 2016
by
Alexander.Trofimov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
_isEmptyCurrentRange -> _isEmptyRange
parent
a51f80c4
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1413 additions
and
1609 deletions
+1413
-1609
cell/model/autofilters.js
cell/model/autofilters.js
+4
-19
cell/view/WorksheetView.js
cell/view/WorksheetView.js
+1409
-1590
No files found.
cell/model/autofilters.js
View file @
e059b27f
...
@@ -2413,7 +2413,7 @@
...
@@ -2413,7 +2413,7 @@
{
{
//если сверху пустая строка, то просто увеличиваем диапазон и меняем флаг
//если сверху пустая строка, то просто увеличиваем диапазон и меняем флаг
var
rangeUpTable
=
new
Asc
.
Range
(
tablePart
.
Ref
.
c1
,
tablePart
.
Ref
.
r2
+
1
,
tablePart
.
Ref
.
c2
,
tablePart
.
Ref
.
r2
+
1
);
var
rangeUpTable
=
new
Asc
.
Range
(
tablePart
.
Ref
.
c1
,
tablePart
.
Ref
.
r2
+
1
,
tablePart
.
Ref
.
c2
,
tablePart
.
Ref
.
r2
+
1
);
if
(
this
.
_isEmpty
CurrentRange
(
rangeUpTable
)
&&
this
.
searchRangeInTableParts
(
rangeUpTable
)
===
-
1
)
if
(
this
.
_isEmpty
Range
(
rangeUpTable
,
0
)
&&
this
.
searchRangeInTableParts
(
rangeUpTable
)
===
-
1
)
{
{
isSetValue
=
true
;
isSetValue
=
true
;
isSetType
=
true
;
isSetType
=
true
;
...
@@ -2460,7 +2460,7 @@
...
@@ -2460,7 +2460,7 @@
{
{
//если сверху пустая строка, то просто увеличиваем диапазон и меняем флаг
//если сверху пустая строка, то просто увеличиваем диапазон и меняем флаг
var
rangeUpTable
=
new
Asc
.
Range
(
tablePart
.
Ref
.
c1
,
tablePart
.
Ref
.
r1
-
1
,
tablePart
.
Ref
.
c2
,
tablePart
.
Ref
.
r1
-
1
);
var
rangeUpTable
=
new
Asc
.
Range
(
tablePart
.
Ref
.
c1
,
tablePart
.
Ref
.
r1
-
1
,
tablePart
.
Ref
.
c2
,
tablePart
.
Ref
.
r1
-
1
);
if
(
this
.
_isEmpty
CurrentRange
(
rangeUpTable
)
&&
this
.
searchRangeInTableParts
(
rangeUpTable
)
===
-
1
)
if
(
this
.
_isEmpty
Range
(
rangeUpTable
,
0
)
&&
this
.
searchRangeInTableParts
(
rangeUpTable
)
===
-
1
)
{
{
isSetValue
=
true
;
isSetValue
=
true
;
...
@@ -2564,21 +2564,6 @@
...
@@ -2564,21 +2564,6 @@
}
}
},
},
_isEmptyCurrentRange
:
function
(
range
)
{
var
worksheet
=
this
.
worksheet
;
for
(
var
n
=
range
.
r1
;
n
<=
range
.
r2
;
n
++
)
{
for
(
var
k
=
range
.
c1
;
k
<=
range
.
c2
;
k
++
)
{
var
cell
=
worksheet
.
getCell3
(
n
,
k
,
n
,
k
);
if
(
cell
.
getValueWithoutFormat
()
!=
''
)
return
false
;
}
}
return
true
;
},
//TODO избавиться от split, передавать cellId и tableName
//TODO избавиться от split, передавать cellId и tableName
_getPressedFilter
:
function
(
activeRange
,
cellId
)
_getPressedFilter
:
function
(
activeRange
,
cellId
)
{
{
...
@@ -4928,9 +4913,9 @@
...
@@ -4928,9 +4913,9 @@
return
result
;
return
result
;
},
},
_isEmptyRange
:
function
(
ar
)
_isEmptyRange
:
function
(
ar
,
addDelta
)
{
{
var
range
=
this
.
worksheet
.
getRange3
(
Math
.
max
(
0
,
ar
.
r1
-
1
),
Math
.
max
(
0
,
ar
.
c1
-
1
),
ar
.
r2
+
1
,
ar
.
c2
+
1
);
var
range
=
this
.
worksheet
.
getRange3
(
Math
.
max
(
0
,
ar
.
r1
-
addDelta
),
Math
.
max
(
0
,
ar
.
c1
-
addDelta
),
ar
.
r2
+
addDelta
,
ar
.
c2
+
addDelta
);
var
res
=
true
;
var
res
=
true
;
range
.
_foreachNoEmpty
(
function
(
cell
)
{
range
.
_foreachNoEmpty
(
function
(
cell
)
{
if
(
!
cell
.
isEmptyText
())
{
if
(
!
cell
.
isEmptyText
())
{
...
...
cell/view/WorksheetView.js
View file @
e059b27f
This source diff could not be displayed because it is too large. You can
view the blob
instead.
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