summaryrefslogtreecommitdiffstats
path: root/native/src/widget/radio.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2021-11-04 19:22:29 +0700
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2021-11-04 19:24:11 +0700
commit023aded2772f0cd6abd716fe5c8624d5d22e21fa (patch)
tree1bdb1a4584d7acc688b081a299bb4431cd35c349 /native/src/widget/radio.rs
parent343f9b7e2e594bd1fef1ed511d71e81f9c44e3d9 (diff)
downloadiced-023aded2772f0cd6abd716fe5c8624d5d22e21fa.tar.gz
iced-023aded2772f0cd6abd716fe5c8624d5d22e21fa.tar.bz2
iced-023aded2772f0cd6abd716fe5c8624d5d22e21fa.zip
Rename `fill_rectangle` to `fill_quad` in `Renderer`
Diffstat (limited to 'native/src/widget/radio.rs')
-rw-r--r--native/src/widget/radio.rs44
1 files changed, 24 insertions, 20 deletions
diff --git a/native/src/widget/radio.rs b/native/src/widget/radio.rs
index 7d39c526..86ad4c4e 100644
--- a/native/src/widget/radio.rs
+++ b/native/src/widget/radio.rs
@@ -10,8 +10,8 @@ use crate::text;
use crate::touch;
use crate::widget::{self, Row, Text};
use crate::{
- Alignment, Background, Clipboard, Color, Element, Hasher, Layout, Length,
- Point, Rectangle, Widget,
+ Alignment, Clipboard, Color, Element, Hasher, Layout, Length, Point,
+ Rectangle, Widget,
};
pub use iced_style::radio::{Style, StyleSheet};
@@ -243,27 +243,31 @@ where
self.style_sheet.active()
};
- renderer.fill_rectangle(renderer::Quad {
- bounds,
- background: style.background,
- border_radius: size / 2.0,
- border_width: style.border_width,
- border_color: style.border_color,
- });
+ renderer.fill_quad(
+ renderer::Quad {
+ bounds,
+ border_radius: size / 2.0,
+ border_width: style.border_width,
+ border_color: style.border_color,
+ },
+ style.background,
+ );
if self.is_selected {
- renderer.fill_rectangle(renderer::Quad {
- bounds: Rectangle {
- x: bounds.x + dot_size / 2.0,
- y: bounds.y + dot_size / 2.0,
- width: bounds.width - dot_size,
- height: bounds.height - dot_size,
+ renderer.fill_quad(
+ renderer::Quad {
+ bounds: Rectangle {
+ x: bounds.x + dot_size / 2.0,
+ y: bounds.y + dot_size / 2.0,
+ width: bounds.width - dot_size,
+ height: bounds.height - dot_size,
+ },
+ border_radius: dot_size / 2.0,
+ border_width: 0.0,
+ border_color: Color::TRANSPARENT,
},
- background: Background::Color(style.dot_color),
- border_radius: dot_size / 2.0,
- border_width: 0.0,
- border_color: Color::TRANSPARENT,
- });
+ style.dot_color,
+ );
}
}