GuiToggle method

(int, bool) GuiToggle(
  1. RectangleD bounds,
  2. String? text,
  3. bool active
)

Implementation

(int result, bool active) GuiToggle(
  RectangleD bounds,
  String? text,
  bool active,
) => run(
  () => 'GuiToggle($bounds, $text, $active)',
  () {
    final valuePtr = rl.Temp.Bool$.Ref1(active);
    final result = rl.Gui.GuiToggle(
      rl.Temp.Rectangle$.Ref1(bounds).ref,
      rl.Temp.String$.ValueOrNull(text),
      valuePtr,
    );
    return (result, valuePtr.value);
  },
);