All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.sonar.l10n.delphi.rules.community-delphi.FormFmx.html Maven / Gradle / Ivy

The newest version!

Why is this an issue?

Omitting the corresponding .fmx resource for a FireMonkey form or frame is typically a programming error. While there are some cases that won't cause problems at runtime, it remains unintuitive and confusing.

Additionally, a unit that doesn't contain a .fmx resource will lack design-time form editing functionality.

This rule flags any TForm or TFrame descendant in a unit that doesn't include a .fmx resource.

How to fix it

Add a .fmx resource to the unit:

unit Foo;

interface

uses
  FMX.Forms;

type
  TFoo = class(TForm)
    // ...
  end;

implementation

end.
unit Foo;

interface

uses
  FMX.Forms;

type
  TFoo = class(TForm)
    // ...
  end;

implementation

{$R *.fmx}

end.




© 2015 - 2024 Weber Informatics LLC | Privacy Policy