Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
pg mr
gajim
Commits
e985e13b
Commit
e985e13b
authored
Feb 15, 2021
by
Daniel Brötzmann
Browse files
AvatarSelector: Fix pipeline
parent
b0a95097
Changes
1
Hide whitespace changes
Inline
Side-by-side
gajim/gtk/avatar_selector.py
View file @
e985e13b
...
...
@@ -231,7 +231,7 @@ def get_pixbuf(self):
width
=
min
(
self
.
_crop
.
width
,
width
-
self
.
_crop
.
x
)
height
=
min
(
self
.
_crop
.
height
,
height
-
self
.
_crop
.
y
)
if
width
<=
0
or
height
<=
0
:
if
width
<=
0
or
height
<=
0
:
return
None
return
GdkPixbuf
.
Pixbuf
.
new_subpixbuf
(
...
...
@@ -661,7 +661,7 @@ def _eval_radial_line(center_x, center_y, bounds_x, bounds_y, user_x):
# Prevent division by zero
return
0
decision_slope
=
f
lo
at
(
bounds_y
-
center
_y
)
/
(
bounds_x
-
center
_x
)
decision_slope
=
s
lo
pe
_y
/
slope
_x
decision_intercept
=
-
float
(
decision_slope
*
bounds_x
)
return
int
(
decision_slope
*
user_x
+
decision_intercept
)
...
...
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