Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
ComfyUI
Commits
4088e61a
Commit
4088e61a
authored
May 16, 2023
by
comfyanonymous
Browse files
Update litegraph from upstream.
parent
6a120943
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
7 deletions
+9
-7
web/lib/litegraph.core.js
web/lib/litegraph.core.js
+9
-7
No files found.
web/lib/litegraph.core.js
View file @
4088e61a
...
@@ -9734,7 +9734,7 @@ LGraphNode.prototype.executeAction = function(action)
...
@@ -9734,7 +9734,7 @@ LGraphNode.prototype.executeAction = function(action)
if
(
show_text
)
{
if
(
show_text
)
{
ctx
.
textAlign
=
"
center
"
;
ctx
.
textAlign
=
"
center
"
;
ctx
.
fillStyle
=
text_color
;
ctx
.
fillStyle
=
text_color
;
ctx
.
fillText
(
w
.
name
,
widget_width
*
0.5
,
y
+
H
*
0.7
);
ctx
.
fillText
(
w
.
label
||
w
.
name
,
widget_width
*
0.5
,
y
+
H
*
0.7
);
}
}
break
;
break
;
case
"
toggle
"
:
case
"
toggle
"
:
...
@@ -9755,8 +9755,9 @@ LGraphNode.prototype.executeAction = function(action)
...
@@ -9755,8 +9755,9 @@ LGraphNode.prototype.executeAction = function(action)
ctx
.
fill
();
ctx
.
fill
();
if
(
show_text
)
{
if
(
show_text
)
{
ctx
.
fillStyle
=
secondary_text_color
;
ctx
.
fillStyle
=
secondary_text_color
;
if
(
w
.
name
!=
null
)
{
const
label
=
w
.
label
||
w
.
name
;
ctx
.
fillText
(
w
.
name
,
margin
*
2
,
y
+
H
*
0.7
);
if
(
label
!=
null
)
{
ctx
.
fillText
(
label
,
margin
*
2
,
y
+
H
*
0.7
);
}
}
ctx
.
fillStyle
=
w
.
value
?
text_color
:
secondary_text_color
;
ctx
.
fillStyle
=
w
.
value
?
text_color
:
secondary_text_color
;
ctx
.
textAlign
=
"
right
"
;
ctx
.
textAlign
=
"
right
"
;
...
@@ -9791,7 +9792,7 @@ LGraphNode.prototype.executeAction = function(action)
...
@@ -9791,7 +9792,7 @@ LGraphNode.prototype.executeAction = function(action)
ctx
.
textAlign
=
"
center
"
;
ctx
.
textAlign
=
"
center
"
;
ctx
.
fillStyle
=
text_color
;
ctx
.
fillStyle
=
text_color
;
ctx
.
fillText
(
ctx
.
fillText
(
w
.
name
+
"
"
+
Number
(
w
.
value
).
toFixed
(
3
),
w
.
label
||
w
.
name
+
"
"
+
Number
(
w
.
value
).
toFixed
(
3
),
widget_width
*
0.5
,
widget_width
*
0.5
,
y
+
H
*
0.7
y
+
H
*
0.7
);
);
...
@@ -9826,7 +9827,7 @@ LGraphNode.prototype.executeAction = function(action)
...
@@ -9826,7 +9827,7 @@ LGraphNode.prototype.executeAction = function(action)
ctx
.
fill
();
ctx
.
fill
();
}
}
ctx
.
fillStyle
=
secondary_text_color
;
ctx
.
fillStyle
=
secondary_text_color
;
ctx
.
fillText
(
w
.
name
,
margin
*
2
+
5
,
y
+
H
*
0.7
);
ctx
.
fillText
(
w
.
label
||
w
.
name
,
margin
*
2
+
5
,
y
+
H
*
0.7
);
ctx
.
fillStyle
=
text_color
;
ctx
.
fillStyle
=
text_color
;
ctx
.
textAlign
=
"
right
"
;
ctx
.
textAlign
=
"
right
"
;
if
(
w
.
type
==
"
number
"
)
{
if
(
w
.
type
==
"
number
"
)
{
...
@@ -9878,8 +9879,9 @@ LGraphNode.prototype.executeAction = function(action)
...
@@ -9878,8 +9879,9 @@ LGraphNode.prototype.executeAction = function(action)
//ctx.stroke();
//ctx.stroke();
ctx
.
fillStyle
=
secondary_text_color
;
ctx
.
fillStyle
=
secondary_text_color
;
if
(
w
.
name
!=
null
)
{
const
label
=
w
.
label
||
w
.
name
;
ctx
.
fillText
(
w
.
name
,
margin
*
2
,
y
+
H
*
0.7
);
if
(
label
!=
null
)
{
ctx
.
fillText
(
label
,
margin
*
2
,
y
+
H
*
0.7
);
}
}
ctx
.
fillStyle
=
text_color
;
ctx
.
fillStyle
=
text_color
;
ctx
.
textAlign
=
"
right
"
;
ctx
.
textAlign
=
"
right
"
;
...
...
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