summaryrefslogtreecommitdiffstats
path: root/native/src/element.rs
diff options
context:
space:
mode:
Diffstat (limited to 'native/src/element.rs')
-rw-r--r--native/src/element.rs16
1 files changed, 16 insertions, 0 deletions
diff --git a/native/src/element.rs b/native/src/element.rs
index 23f069f1..791bf9cf 100644
--- a/native/src/element.rs
+++ b/native/src/element.rs
@@ -299,6 +299,14 @@ where
A: Clone,
Renderer: crate::Renderer,
{
+ fn width(&self) -> Length {
+ self.widget.width()
+ }
+
+ fn height(&self) -> Length {
+ self.widget.height()
+ }
+
fn layout(
&self,
renderer: &Renderer,
@@ -375,6 +383,14 @@ impl<'a, Message, Renderer> Widget<Message, Renderer>
where
Renderer: crate::Renderer + renderer::Debugger,
{
+ fn width(&self) -> Length {
+ self.element.widget.width()
+ }
+
+ fn height(&self) -> Length {
+ self.element.widget.height()
+ }
+
fn layout(
&self,
renderer: &Renderer,