Skip to content

Commit 1b5d5db

Browse files
committed
box layout fixes
1 parent 8a887e4 commit 1b5d5db

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

src/components/BoxView/RNBoxView.ts

+3-7
Original file line numberDiff line numberDiff line change
@@ -31,18 +31,14 @@ const setBoxViewProps = (
3131
*/
3232
export class RNBoxView extends QWidget implements RNComponent {
3333
native: any;
34-
_layout?: QBoxLayout;
3534
initialProps?: BoxViewProps;
3635
children: Array<NodeWidget<any>> = [];
37-
3836
get layout() {
39-
return this.layout;
37+
return super.layout as QBoxLayout | undefined;
4038
}
41-
42-
set layout(l: QBoxLayout) {
43-
this._layout = l;
39+
set layout(l: QBoxLayout | undefined) {
40+
super.layout = l;
4441
}
45-
4642
setProps(newProps: BoxViewProps, oldProps: BoxViewProps): void {
4743
if (this.layout) {
4844
setBoxViewProps(this, newProps, oldProps);

0 commit comments

Comments
 (0)