File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
editor/src/messages/tool/tool_messages Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -143,7 +143,7 @@ impl LayoutHolder for ShapeTool {
143
143
true ,
144
144
|_| ShapeToolMessage :: UpdateOptions ( ShapeOptionsUpdate :: FillColor ( None ) ) . into ( ) ,
145
145
|color_type : ToolColorType | WidgetCallback :: new ( move |_| ShapeToolMessage :: UpdateOptions ( ShapeOptionsUpdate :: FillColorType ( color_type. clone ( ) ) ) . into ( ) ) ,
146
- |color : & ColorInput | ShapeToolMessage :: UpdateOptions ( ShapeOptionsUpdate :: FillColor ( color. value . as_solid ( ) ) ) . into ( ) ,
146
+ |color : & ColorInput | ShapeToolMessage :: UpdateOptions ( ShapeOptionsUpdate :: FillColor ( color. value . as_solid ( ) . map ( |color| color . to_linear_srgb ( ) ) ) ) . into ( ) ,
147
147
) ) ;
148
148
149
149
widgets. push ( Separator :: new ( SeparatorType :: Unrelated ) . widget_holder ( ) ) ;
@@ -154,7 +154,7 @@ impl LayoutHolder for ShapeTool {
154
154
true ,
155
155
|_| ShapeToolMessage :: UpdateOptions ( ShapeOptionsUpdate :: StrokeColor ( None ) ) . into ( ) ,
156
156
|color_type : ToolColorType | WidgetCallback :: new ( move |_| ShapeToolMessage :: UpdateOptions ( ShapeOptionsUpdate :: StrokeColorType ( color_type. clone ( ) ) ) . into ( ) ) ,
157
- |color : & ColorInput | ShapeToolMessage :: UpdateOptions ( ShapeOptionsUpdate :: StrokeColor ( color. value . as_solid ( ) ) ) . into ( ) ,
157
+ |color : & ColorInput | ShapeToolMessage :: UpdateOptions ( ShapeOptionsUpdate :: StrokeColor ( color. value . as_solid ( ) . map ( |color| color . to_linear_srgb ( ) ) ) ) . into ( ) ,
158
158
) ) ;
159
159
widgets. push ( Separator :: new ( SeparatorType :: Unrelated ) . widget_holder ( ) ) ;
160
160
widgets. push ( create_weight_widget ( self . options . line_weight ) ) ;
You can’t perform that action at this time.
0 commit comments