Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
typo3
qfq
Commits
3d569f48
Commit
3d569f48
authored
Jul 03, 2019
by
bbaer
Browse files
Readonly now displays annotations again.
parent
ac77d667
Pipeline
#2078
passed with stages
in 2 minutes and 43 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
javascript/src/Plugins/qfq.fabric.js
View file @
3d569f48
...
...
@@ -282,6 +282,9 @@ $(function (n) {
var
that
=
this
;
if
(
viewOnly
)
{
if
(
inputField
)
{
this
.
outputField
=
$
(
"
#
"
+
inputField
);
}
this
.
getMeta
(
this
.
backgroundImage
,
function
(
width
,
height
)
{
that
.
prepareStaticCanvas
(
width
,
height
);
}
);
}
else
if
(
editImage
)
{
this
.
outputField
=
$
(
"
#
"
+
inputField
);
...
...
@@ -400,9 +403,16 @@ $(function (n) {
console
.
log
(
"
prepareStaticCanvas
"
);
var
that
=
this
;
this
.
generateStaticCanvas
(
width
,
height
);
if
(
this
.
fabricJSON
)
{
this
.
canvas
.
loadFromJSON
(
this
.
fabricJSON
,
function
()
{
that
.
resizeCanvas
(
true
);
if
(
this
.
outputField
.
val
())
{
fabricJSON
=
this
.
outputField
.
val
();
}
else
if
(
this
.
fabricJSON
)
{
fabricJSON
=
this
.
fabricJSON
;
}
if
(
fabricJSON
)
{
this
.
canvas
.
loadFromJSON
(
fabricJSON
,
function
()
{
that
.
firstLoad
=
true
;
that
.
setBackground
();
that
.
resizeCanvas
();
that
.
canvas
.
renderAll
();
});
}
else
{
...
...
Write
Preview
Supports
Markdown
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