1
0
mirror of https://github.com/emilk/egui.git synced 2026-06-28 07:23:13 -04:00

Color picker now always pops up next to the button (#1237)

This commit is contained in:
BctfN0HUK7Yg
2022-02-15 18:55:43 +03:00
committed by GitHub
parent 635c65773d
commit cfad28936d

View File

@@ -357,7 +357,7 @@ pub fn color_edit_button_hsva(ui: &mut Ui, hsva: &mut Hsva, alpha: Alpha) -> Res
if ui.memory().is_popup_open(popup_id) {
let area_response = Area::new(popup_id)
.order(Order::Foreground)
.default_pos(button_response.rect.max)
.current_pos(button_response.rect.max)
.show(ui.ctx(), |ui| {
ui.spacing_mut().slider_width = 210.0;
Frame::popup(ui.style()).show(ui, |ui| {