commands.dart 964 Bytes
Newer Older
Ian Hickson's avatar
Ian Hickson committed
1
// Copyright 2014 The Flutter Authors. All rights reserved.
2 3 4 5 6 7 8
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';

void main() {
9
  print('called main');
10
  runApp(const MaterialApp(home: Test()));
11 12 13
}

class Test extends SingleChildRenderObjectWidget {
14
  const Test({ Key? key }) : super(key: key);
15 16

  @override
17
  RenderTest createRenderObject(BuildContext context) => RenderTest();
18 19 20
}

class RenderTest extends RenderProxyBox {
21
  RenderTest({ RenderBox? child }) : super(child);
22 23 24 25

  @override
  void debugPaintSize(PaintingContext context, Offset offset) {
    super.debugPaintSize(context, offset);
26
    print('called debugPaintSize');
27 28 29 30
  }

  @override
  void paint(PaintingContext context, Offset offset) {
31 32 33 34 35 36 37
    print('called paint');
  }

  @override
  void reassemble() {
    print('called reassemble');
    super.reassemble();
38 39
  }
}