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
92b3823a
Commit
92b3823a
authored
Nov 21, 2016
by
Oleg Korshul
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
scroll bug (web mobile version)
parent
066e81e2
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
36 additions
and
18 deletions
+36
-18
word/Drawing/DrawingDocument.js
word/Drawing/DrawingDocument.js
+36
-18
No files found.
word/Drawing/DrawingDocument.js
View file @
92b3823a
...
...
@@ -2354,12 +2354,45 @@ function CDrawingDocument()
this
.
m_oWordControl
.
OnScroll
();
}
this
.
CheckPagesSizeMaximum
=
function
(
_w
,
_h
)
{
var
w
=
_w
;
var
h
=
_h
;
// заглушка под мобильную версию (iPad не рисует большие картинки (наверное страховка по памяти))
if
(
g_bIsMobile
)
{
var
_mobile_max
=
2500
;
if
(
w
>
_mobile_max
||
h
>
_mobile_max
)
{
if
(
w
>
h
)
{
h
=
(
h
*
_mobile_max
/
w
)
>>
0
;
w
=
_mobile_max
;
}
else
{
w
=
(
w
*
_mobile_max
/
h
)
>>
0
;
h
=
_mobile_max
;
}
}
}
return
[
w
,
h
];
}
this
.
CheckRecalculatePage
=
function
(
width
,
height
,
pageIndex
)
{
var
_drawingPage
=
this
.
m_arrPages
[
pageIndex
].
drawingPage
;
var
isUnlock
=
false
;
if
(
_drawingPage
.
cachedImage
!=
null
&&
_drawingPage
.
cachedImage
.
image
!=
null
&&
(
width
!=
_drawingPage
.
cachedImage
.
image
.
width
||
height
!=
_drawingPage
.
cachedImage
.
image
.
height
))
isUnlock
=
true
;
if
(
_drawingPage
.
cachedImage
!=
null
&&
_drawingPage
.
cachedImage
.
image
!=
null
)
{
var
_check
=
this
.
CheckPagesSizeMaximum
(
width
,
height
);
if
(
_check
[
0
]
!=
_drawingPage
.
cachedImage
.
image
.
width
||
_check
[
1
]
!=
_drawingPage
.
cachedImage
.
image
.
height
)
isUnlock
=
true
;
}
if
(
_drawingPage
.
IsRecalculate
)
{
...
...
@@ -2398,24 +2431,9 @@ function CDrawingDocument()
h
*=
2
;
}
// заглушка под мобильную версию (iPad не рисует большие картинки (наверное страховка по памяти))
if
(
g_bIsMobile
)
{
var
_mobile_max
=
2000
;
if
(
w
>
_mobile_max
||
h
>
_mobile_max
)
{
if
(
w
>
h
)
{
h
=
(
h
*
_mobile_max
/
w
)
>>
0
;
w
=
_mobile_max
;
}
else
{
w
=
(
w
*
_mobile_max
/
h
)
>>
0
;
h
=
_mobile_max
;
}
}
}
var
_check
=
this
.
CheckPagesSizeMaximum
(
w
,
h
);
w
=
_check
[
0
];
h
=
_check
[
1
];
page
.
drawingPage
.
UnLock
(
this
.
m_oCacheManager
);
page
.
drawingPage
.
cachedImage
=
this
.
m_oCacheManager
.
Lock
(
w
,
h
);
...
...
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