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
2161baeb
Commit
2161baeb
authored
Mar 23, 2017
by
Alexander.Trofimov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bug 33457
parent
e560abee
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
110 additions
and
94 deletions
+110
-94
cell/api.js
cell/api.js
+83
-66
cell/model/WorkbookElems.js
cell/model/WorkbookElems.js
+3
-3
cell/view/WorksheetView.js
cell/view/WorksheetView.js
+24
-25
No files found.
cell/api.js
View file @
2161baeb
...
@@ -1356,21 +1356,23 @@ var editor;
...
@@ -1356,21 +1356,23 @@ var editor;
};
};
// End Load document
// End Load document
spreadsheet_api
.
prototype
.
_openDocumentEndCallback
=
function
()
{
spreadsheet_api
.
prototype
.
_openDocumentEndCallback
=
function
()
{
// Не инициализируем дважды
// Не инициализируем дважды
if
(
this
.
DocumentLoadComplete
)
{
if
(
this
.
DocumentLoadComplete
)
{
return
;
return
;
}
}
this
.
wb
=
new
AscCommonExcel
.
WorkbookView
(
this
.
wbModel
,
this
.
controller
,
this
.
handlers
,
this
.
HtmlElement
,
this
.
topLineEditorElement
,
this
,
this
.
collaborativeEditing
,
this
.
fontRenderingMode
);
this
.
wb
=
new
AscCommonExcel
.
WorkbookView
(
this
.
wbModel
,
this
.
controller
,
this
.
handlers
,
this
.
HtmlElement
,
this
.
topLineEditorElement
,
this
,
this
.
collaborativeEditing
,
this
.
fontRenderingMode
);
if
(
this
.
isMobileVersion
)
{
if
(
this
.
isMobileVersion
)
{
this
.
wb
.
defaults
.
worksheetView
.
halfSelection
=
true
;
this
.
wb
.
defaults
.
worksheetView
.
halfSelection
=
true
;
this
.
wb
.
defaults
.
worksheetView
.
activeCellBorderColor
=
new
CColor
(
79
,
158
,
79
);
this
.
wb
.
defaults
.
worksheetView
.
activeCellBorderColor
=
new
CColor
(
79
,
158
,
79
);
var
_container
=
document
.
getElementById
(
this
.
HtmlElementName
);
var
_container
=
document
.
getElementById
(
this
.
HtmlElementName
);
if
(
_container
)
if
(
_container
)
{
_container
.
style
.
overflow
=
"
hidden
"
;
_container
.
style
.
overflow
=
"
hidden
"
;
this
.
wb
.
MobileTouchManager
=
new
AscCommonExcel
.
CMobileTouchManager
({
eventsElement
:
"
cell_mobile_element
"
});
}
this
.
wb
.
MobileTouchManager
=
new
AscCommonExcel
.
CMobileTouchManager
({
eventsElement
:
"
cell_mobile_element
"
});
this
.
wb
.
MobileTouchManager
.
Init
(
this
);
this
.
wb
.
MobileTouchManager
.
Init
(
this
);
// input context must be created!!!
// input context must be created!!!
...
@@ -1410,9 +1412,18 @@ var editor;
...
@@ -1410,9 +1412,18 @@ var editor;
};
};
// Переход на диапазон в листе
// Переход на диапазон в листе
spreadsheet_api
.
prototype
.
_asc_setWorksheetRange
=
function
(
val
)
{
spreadsheet_api
.
prototype
.
_asc_setWorksheetRange
=
function
(
val
)
{
// Получаем sheet по имени
// Получаем sheet по имени
var
ws
=
this
.
wbModel
.
getWorksheetByName
(
val
.
asc_getSheet
());
var
ranges
=
null
,
ws
;
var
sheet
=
val
.
asc_getSheet
();
if
(
!
sheet
)
{
ranges
=
AscCommonExcel
.
getRangeByRef
(
val
.
asc_getLocation
(),
this
.
wbModel
.
getActiveWs
(),
true
);
if
(
ranges
=
ranges
[
0
])
{
ws
=
ranges
.
worksheet
;
}
}
else
{
ws
=
this
.
wbModel
.
getWorksheetByName
(
sheet
);
}
if
(
!
ws
)
{
if
(
!
ws
)
{
this
.
handlers
.
trigger
(
"
asc_onHyperlinkClick
"
,
null
);
this
.
handlers
.
trigger
(
"
asc_onHyperlinkClick
"
,
null
);
return
;
return
;
...
@@ -1428,10 +1439,16 @@ var editor;
...
@@ -1428,10 +1439,16 @@ var editor;
// Посылаем эвент о смене активного листа
// Посылаем эвент о смене активного листа
this
.
handlers
.
trigger
(
"
asc_onActiveSheetChanged
"
,
sheetIndex
);
this
.
handlers
.
trigger
(
"
asc_onActiveSheetChanged
"
,
sheetIndex
);
}
}
var
range
=
ws
.
getRange2
(
val
.
asc_getRange
());
var
range
;
if
(
null
!==
range
)
{
if
(
ranges
)
{
this
.
wb
.
_onSetSelection
(
range
.
getBBox0
(),
/*validRange*/
true
);
range
=
ranges
.
bbox
;
}
else
{
range
=
ws
.
getRange2
(
val
.
asc_getRange
());
if
(
range
)
{
range
=
range
.
getBBox0
();
}
}
}
this
.
wb
.
_onSetSelection
(
range
,
/*validRange*/
true
);
};
};
spreadsheet_api
.
prototype
.
onSaveCallback
=
function
(
e
)
{
spreadsheet_api
.
prototype
.
onSaveCallback
=
function
(
e
)
{
...
...
cell/model/WorkbookElems.js
View file @
2161baeb
...
@@ -2356,7 +2356,7 @@ Hyperlink.prototype = {
...
@@ -2356,7 +2356,7 @@ Hyperlink.prototype = {
this
.
Location
=
Location
;
this
.
Location
=
Location
;
this
.
LocationSheet
=
this
.
LocationRange
=
null
;
this
.
LocationSheet
=
this
.
LocationRange
=
null
;
if
(
null
!=
this
.
Location
)
{
if
(
null
!=
=
this
.
Location
)
{
var
result
=
parserHelp
.
parse3DRef
(
this
.
Location
);
var
result
=
parserHelp
.
parse3DRef
(
this
.
Location
);
if
(
null
!==
result
)
{
if
(
null
!==
result
)
{
this
.
LocationSheet
=
result
.
sheet
;
this
.
LocationSheet
=
result
.
sheet
;
...
...
cell/view/WorksheetView.js
View file @
2161baeb
...
@@ -7296,8 +7296,8 @@
...
@@ -7296,8 +7296,8 @@
}
}
var
oRes
=
null
;
var
oRes
=
null
;
var
type
=
range
.
type
;
var
type
=
range
.
type
;
if
(
type
==
c_oAscSelectionType
.
RangeCells
||
type
==
c_oAscSelectionType
.
RangeCol
||
if
(
type
==
=
c_oAscSelectionType
.
RangeCells
||
type
=
==
c_oAscSelectionType
.
RangeCol
||
type
==
c_oAscSelectionType
.
RangeRow
||
type
==
c_oAscSelectionType
.
RangeMax
)
{
type
==
=
c_oAscSelectionType
.
RangeRow
||
type
=
==
c_oAscSelectionType
.
RangeMax
)
{
this
.
cleanSelection
();
this
.
cleanSelection
();
this
.
model
.
selectionRange
.
assign2
(
range
);
this
.
model
.
selectionRange
.
assign2
(
range
);
this
.
_fixSelectionOfMergedCells
();
this
.
_fixSelectionOfMergedCells
();
...
@@ -11250,9 +11250,8 @@
...
@@ -11250,9 +11250,8 @@
// ToDo multiselect defined names
// ToDo multiselect defined names
var
selectionLast
=
this
.
model
.
selectionRange
.
getLast
();
var
selectionLast
=
this
.
model
.
selectionRange
.
getLast
();
mc
=
selectionLast
.
isOneCell
()
?
this
.
model
.
getMergedByCell
(
selectionLast
.
r1
,
selectionLast
.
c1
)
:
null
;
mc
=
selectionLast
.
isOneCell
()
?
this
.
model
.
getMergedByCell
(
selectionLast
.
r1
,
selectionLast
.
c1
)
:
null
;
var
defName
=
this
.
model
.
workbook
.
editDefinesNames
(
null
,
var
defName
=
this
.
model
.
workbook
.
editDefinesNames
(
null
,
new
Asc
.
asc_CDefName
(
reference
,
new
Asc
.
asc_CDefName
(
reference
,
parserHelp
.
get3DRef
(
this
.
model
.
getName
(),
parserHelp
.
get3DRef
(
this
.
model
.
getName
(),
(
mc
||
selectionLast
).
getAbsName
())));
(
mc
||
selectionLast
).
getAbsName
())));
if
(
defName
)
{
if
(
defName
)
{
this
.
_isLockedDefNames
(
null
,
defName
.
getNodeId
());
this
.
_isLockedDefNames
(
null
,
defName
.
getNodeId
());
...
...
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