Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
godot
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
community
godot
Commits
02ed4b39
Unverified
Commit
02ed4b39
authored
Jun 19, 2019
by
Rémi Verschelde
Committed by
GitHub
Jun 19, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #29902 from KoBeWi/dem_setters
Fix set_pick_color error
parents
922a4f54
9bdf1108
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
3 deletions
+9
-3
color_picker.cpp
scene/gui/color_picker.cpp
+7
-2
color_picker.h
scene/gui/color_picker.h
+2
-1
No files found.
scene/gui/color_picker.cpp
View file @
02ed4b39
...
...
@@ -126,7 +126,7 @@ void ColorPicker::_update_controls() {
}
}
void
ColorPicker
::
set_pick_color
(
const
Color
&
p_color
,
bool
p_update_sliders
)
{
void
ColorPicker
::
_
set_pick_color
(
const
Color
&
p_color
,
bool
p_update_sliders
)
{
color
=
p_color
;
if
(
color
!=
last_hsv
)
{
...
...
@@ -142,6 +142,11 @@ void ColorPicker::set_pick_color(const Color &p_color, bool p_update_sliders) {
_update_color
(
p_update_sliders
);
}
void
ColorPicker
::
set_pick_color
(
const
Color
&
p_color
)
{
_set_pick_color
(
p_color
,
true
);
//because setters can't have more arguments
}
void
ColorPicker
::
set_edit_alpha
(
bool
p_show
)
{
edit_alpha
=
p_show
;
...
...
@@ -175,7 +180,7 @@ void ColorPicker::_value_changed(double) {
}
}
set_pick_color
(
color
,
false
);
_
set_pick_color
(
color
,
false
);
emit_signal
(
"color_changed"
,
color
);
}
...
...
scene/gui/color_picker.h
View file @
02ed4b39
...
...
@@ -108,7 +108,8 @@ public:
void
set_edit_alpha
(
bool
p_show
);
bool
is_editing_alpha
()
const
;
void
set_pick_color
(
const
Color
&
p_color
,
bool
p_update_sliders
=
true
);
void
_set_pick_color
(
const
Color
&
p_color
,
bool
p_update_sliders
);
void
set_pick_color
(
const
Color
&
p_color
);
Color
get_pick_color
()
const
;
void
add_preset
(
const
Color
&
p_color
);
...
...
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