Hallo Freunde
Was eine Klasse "class" das ist klar
Nur für was benutzt man s.u.
für eine Funktion den class Ausdruck.
Also
Result := 'APPLICATION';
wird überschrieben.
Aber geht dies nicht auch ohne class ?
Delphi-Quellcode:
type
TFormMain =
class(TUIRibbonForm)
procedure FormContextPopup(Sender: TObject; MousePos: TPoint;
var Handled: Boolean);
private
{ Private declarations }
FCurrentContext: Integer;
FCommandContexts:
array [0..3]
of TUICommandBoolean;
private
procedure ContextToggle(
const Args: TUICommandBooleanEventArgs);
strict protected
procedure RibbonLoaded;
override;
public
{ Public declarations }
class function RibbonResourceName:
String;
override;
//// Hier dies class meine ich
end;
--------------------------------------------------------
{ Returns the name of the ribbon resource. By default, this is 'APPLICATION',
which is the name the Ribbon Compiler uses when no name is specified.
If you specified a name to the Ribbon Compiler (using then /name switch),
then you need to override this function and return that name.
Specifying an incorrect name will cause an exception on startup. }
class function RibbonResourceName:
String;
virtual;
class function TUIRibbonForm.RibbonResourceName:
String;
begin
Result := '
APPLICATION';
end;