Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
fyge_for_tb
Project
Project
Details
Activity
Releases
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
王剑峰
fyge_for_tb
Commits
43919fd6
Commit
43919fd6
authored
May 01, 2020
by
wjf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
l
parent
85298eab
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
5 deletions
+16
-5
Graphics.ts
src/2d/graphics/Graphics.ts
+16
-5
No files found.
src/2d/graphics/Graphics.ts
View file @
43919fd6
...
...
@@ -1422,9 +1422,14 @@ export default class Graphics extends Container {
}
set
width
(
value
)
{
this
.
updateLocalBoundsSelf
();
const
width
=
this
.
_localBoundsSelf
.
width
;
if
(
width
!==
0
)
{
const
s
=
sign
(
this
.
scale
.
x
)
||
1
;
this
.
scale
.
x
=
s
*
value
/
this
.
_localBoundsSelf
.
width
;
this
.
scale
.
x
=
s
*
value
/
width
;
}
else
{
this
.
scale
.
x
=
1
;
}
this
.
_width
=
value
;
}
...
...
@@ -1439,8 +1444,14 @@ export default class Graphics extends Container {
}
set
height
(
value
)
{
this
.
updateLocalBoundsSelf
()
const
height
=
this
.
_localBoundsSelf
.
height
;
if
(
height
!==
0
)
{
const
s
=
sign
(
this
.
scale
.
y
)
||
1
;
this
.
scale
.
y
=
s
*
value
/
this
.
_localBoundsSelf
.
height
;
this
.
scale
.
y
=
s
*
value
/
height
;
}
else
{
this
.
scale
.
y
=
1
;
}
this
.
_height
=
value
;
}
...
...
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