Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
check
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abook_web
check
Commits
aac32ba2
Commit
aac32ba2
authored
Jun 21, 2018
by
tsushima
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#28696 【Biz/Web】差し替え画像が重なって表示される
parent
a8ccd51c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
14 deletions
+9
-14
abvw/js/contentview.js
+4
-5
abvw/js/contentview_CreateObjects.js
+5
-9
No files found.
abvw/js/contentview.js
View file @
aac32ba2
...
...
@@ -5088,12 +5088,11 @@ CONTENTVIEW.changeImageType4 = function(objTarget, nIndex, nIndex1) {
var
tmpW
=
objTarget
[
nIndex
].
width
*
tempRatioWidth
;
var
tmpH
=
objTarget
[
nIndex
].
height
*
tempRatioHeight
;
contextObject
.
fillStyle
=
"#FFFFFF"
;
contextObject
.
fillRect
(
tmpX
,
tmpY
,
tmpW
+
1
,
tmpH
+
1
);
var
aspectType
=
objTarget
[
nIndex
].
aspectType
;
if
(
aspectType
==
'1'
){
contextObject
.
fillStyle
=
"#FFFFFF"
;
contextObject
.
fillRect
(
tmpX
,
tmpY
,
tmpW
+
1
,
tmpH
+
1
);
var
drawObj
=
CONTENTVIEW
.
adjustAspectRatio
(
tmpX
,
tmpY
,
tmpW
,
tmpH
,
imageObj
.
width
,
imageObj
.
height
);
tmpX
=
drawObj
.
drawX
;
...
...
@@ -6445,8 +6444,8 @@ CONTENTVIEW.adjustAspectRatio = function(drawX, drawY, drawW, drawH, srcImageW,
//描画エリアとソース画像の比率計算
var
drawRatio
=
drawObj
.
drawW
/
drawObj
.
drawH
;
var
srcRatio
=
srcImageW
/
srcImageH
;
console
.
log
(
"drawRatio:"
+
drawRatio
);
console
.
log
(
"srcRatio:"
+
srcRatio
);
//
console.log("drawRatio:" + drawRatio);
//
console.log("srcRatio:" + srcRatio);
if
(
drawRatio
<
srcRatio
){
tmpW
=
drawObj
.
drawW
;
...
...
abvw/js/contentview_CreateObjects.js
View file @
aac32ba2
...
...
@@ -473,17 +473,14 @@ CONTENTVIEW_CREATEOBJECT.PageObject.prototype.drawPageObject = function (context
}
else
if
(
mediaType
==
'4'
){
context
.
fillStyle
=
"#FFFFFF"
;
context
.
fillRect
(
x
,
y
,
w
,
h
);
if
(
aspectType
==
'1'
){
context
.
fillStyle
=
"#FFFFFF"
;
context
.
fillRect
(
x
,
y
,
w
,
h
);
var
drawObj
=
CONTENTVIEW
.
adjustAspectRatio
(
x
,
y
,
w
,
h
,
img
.
width
,
img
.
height
);
x
=
drawObj
.
drawX
;
y
=
drawObj
.
drawY
;
w
=
drawObj
.
drawW
;
h
=
drawObj
.
drawH
;
}
context
.
drawImage
(
img
,
x
,
y
,
w
,
h
);
}
...
...
@@ -820,6 +817,9 @@ CONTENTVIEW_CREATEOBJECT.listImage = function (mediaType, id, imageUrl, x, y, w,
var
tmpW
=
w
*
tempRatioWidth
;
var
tmpH
=
h
*
tempRatioHeight
;
contextObject
.
fillStyle
=
"#FFFFFF"
;
contextObject
.
fillRect
(
tmpX
,
tmpY
,
tmpW
+
1
,
tmpH
+
1
);
if
(
aspectType
==
'1'
){
var
srcImageW
=
imageObj
.
width
;
...
...
@@ -840,10 +840,6 @@ CONTENTVIEW_CREATEOBJECT.listImage = function (mediaType, id, imageUrl, x, y, w,
// }
//
//}
contextObject
.
fillStyle
=
"#FFFFFF"
;
contextObject
.
fillRect
(
tmpX
,
tmpY
,
tmpW
+
1
,
tmpH
+
1
);
var
drawObj
=
CONTENTVIEW
.
adjustAspectRatio
(
tmpX
,
tmpY
,
tmpW
,
tmpH
,
imageObj
.
width
,
imageObj
.
height
);
tmpX
=
drawObj
.
drawX
;
tmpY
=
drawObj
.
drawY
;
...
...
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