mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-14 03:19:25 +02:00
changed lazarus to use the widgetset it is compiled with as the default when building projects
+ added WidgetSetName function to TWidgetSet. + changed the order of units on qtint and fpguiint git-svn-id: trunk@10216 -
This commit is contained in:
parent
a51b2a96e2
commit
5302d4b562
@ -178,11 +178,6 @@ begin
|
|||||||
List.Add('/var/tmp/');
|
List.Add('/var/tmp/');
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function GetDefaultLCLWidgetType: string;
|
|
||||||
begin
|
|
||||||
Result:='gtk';
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure GetDefaultBrowser(var Browser, Params: string);
|
procedure GetDefaultBrowser(var Browser, Params: string);
|
||||||
|
|
||||||
function Find(const ShortFilename: string; var Filename: string): boolean;
|
function Find(const ShortFilename: string; var Filename: string): boolean;
|
||||||
|
@ -151,11 +151,6 @@ begin
|
|||||||
List.Add('c:\windows\temp\');
|
List.Add('c:\windows\temp\');
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function GetDefaultLCLWidgetType: string;
|
|
||||||
begin
|
|
||||||
Result:='win32';
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure GetDefaultBrowser(var Browser, Params: string);
|
procedure GetDefaultBrowser(var Browser, Params: string);
|
||||||
begin
|
begin
|
||||||
Browser:= SearchFileInPath('rundll32.exe','',
|
Browser:= SearchFileInPath('rundll32.exe','',
|
||||||
|
@ -150,11 +150,6 @@ begin
|
|||||||
List.Add('c:\windows\temp\');
|
List.Add('c:\windows\temp\');
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function GetDefaultLCLWidgetType: string;
|
|
||||||
begin
|
|
||||||
Result:='win32';
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure GetDefaultBrowser(var Browser, Params: string);
|
procedure GetDefaultBrowser(var Browser, Params: string);
|
||||||
begin
|
begin
|
||||||
Browser:= SearchFileInPath('rundll32.exe','',
|
Browser:= SearchFileInPath('rundll32.exe','',
|
||||||
|
@ -46,7 +46,7 @@ interface
|
|||||||
{$endif}
|
{$endif}
|
||||||
|
|
||||||
uses
|
uses
|
||||||
SysUtils, Classes, FileUtil;
|
SysUtils, Classes, FileUtil, InterfaceBase;
|
||||||
|
|
||||||
type
|
type
|
||||||
TLCLPlatform = (
|
TLCLPlatform = (
|
||||||
@ -143,6 +143,11 @@ begin
|
|||||||
[sffDontSearchInBasePath]);
|
[sffDontSearchInBasePath]);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function GetDefaultLCLWidgetType: string;
|
||||||
|
begin
|
||||||
|
Result:=WidgetSet.WidgetSetName;
|
||||||
|
end;
|
||||||
|
|
||||||
function GetDefaultLCLLibPaths(const Prefix, Postfix, Separator: string): string;
|
function GetDefaultLCLLibPaths(const Prefix, Postfix, Separator: string): string;
|
||||||
var
|
var
|
||||||
List: TStringList;
|
List: TStringList;
|
||||||
|
@ -46,3 +46,9 @@ procedure TWidgetSet.AppSetTitle(const ATitle: string);
|
|||||||
begin
|
begin
|
||||||
Debugln('TWidgetSet.AppSetTitle not implemented by ', ClassName);
|
Debugln('TWidgetSet.AppSetTitle not implemented by ', ClassName);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TWidgetSet.WidgetSetName: string;
|
||||||
|
begin
|
||||||
|
Result := '';
|
||||||
|
Debugln('TWidgetSet.WidgetSetName not implemented by ', ClassName);
|
||||||
|
end;
|
||||||
|
@ -67,6 +67,8 @@ type
|
|||||||
procedure AppMinimize; virtual; abstract;
|
procedure AppMinimize; virtual; abstract;
|
||||||
procedure AppBringToFront; virtual; abstract;
|
procedure AppBringToFront; virtual; abstract;
|
||||||
procedure AppSetTitle(const ATitle: string); virtual;
|
procedure AppSetTitle(const ATitle: string); virtual;
|
||||||
|
|
||||||
|
function WidgetSetName: string; virtual;
|
||||||
|
|
||||||
function DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor; virtual; abstract;
|
function DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor; virtual; abstract;
|
||||||
procedure DCSetPixel(CanvasHandle: HDC; X, Y: integer; AColor: TGraphicsColor); virtual; abstract;
|
procedure DCSetPixel(CanvasHandle: HDC; X, Y: integer; AColor: TGraphicsColor); virtual; abstract;
|
||||||
|
@ -70,6 +70,7 @@ type
|
|||||||
procedure AppTerminate; override;
|
procedure AppTerminate; override;
|
||||||
procedure AppMinimize; override;
|
procedure AppMinimize; override;
|
||||||
procedure AppBringToFront; override;
|
procedure AppBringToFront; override;
|
||||||
|
function WidgetSetName: string; override;
|
||||||
|
|
||||||
function DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor; override;
|
function DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor; override;
|
||||||
procedure DCSetPixel(CanvasHandle: HDC; X, Y: integer; AColor: TGraphicsColor); override;
|
procedure DCSetPixel(CanvasHandle: HDC; X, Y: integer; AColor: TGraphicsColor); override;
|
||||||
|
@ -350,6 +350,11 @@ begin
|
|||||||
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TCarbonWidgetSet.WidgetSetName: string;
|
||||||
|
begin
|
||||||
|
Result:='carbon';
|
||||||
|
end;
|
||||||
|
|
||||||
function TCarbonWidgetSet.DCGetPixel(CanvasHandle: HDC; X, Y: integer
|
function TCarbonWidgetSet.DCGetPixel(CanvasHandle: HDC; X, Y: integer
|
||||||
): TGraphicsColor;
|
): TGraphicsColor;
|
||||||
begin
|
begin
|
||||||
|
@ -34,10 +34,12 @@ interface
|
|||||||
{$endif}
|
{$endif}
|
||||||
|
|
||||||
uses
|
uses
|
||||||
|
// FCL
|
||||||
|
Classes, Types, SysUtils, Math,
|
||||||
// LCL
|
// LCL
|
||||||
Types, InterfaceBase, SysUtils, LCLProc, LCLType, LMessages, Classes,
|
InterfaceBase, LCLProc, LCLType, LMessages,
|
||||||
Controls, ExtCtrls, Forms, Dialogs, StdCtrls, Comctrls, LCLIntf,
|
Controls, ExtCtrls, Forms, Dialogs, StdCtrls, Comctrls, LCLIntf,
|
||||||
GraphType, Math;
|
GraphType;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
@ -55,6 +57,7 @@ type
|
|||||||
procedure AppMinimize; override;
|
procedure AppMinimize; override;
|
||||||
procedure AppBringToFront; override;
|
procedure AppBringToFront; override;
|
||||||
// procedure AppSetTitle(const ATitle: string); override;
|
// procedure AppSetTitle(const ATitle: string); override;
|
||||||
|
function WidgetSetName: string; override;
|
||||||
public
|
public
|
||||||
constructor Create;
|
constructor Create;
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
|
@ -145,6 +145,11 @@ begin
|
|||||||
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TFpGuiWidgetSet.WidgetSetName: string;
|
||||||
|
begin
|
||||||
|
Result:='fpgui';
|
||||||
|
end;
|
||||||
|
|
||||||
function TFpGuiWidgetSet.DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor;
|
function TFpGuiWidgetSet.DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor;
|
||||||
begin
|
begin
|
||||||
Result:=clNone;
|
Result:=clNone;
|
||||||
|
@ -44,6 +44,9 @@ uses
|
|||||||
libgnome, libart, libgnomeui;
|
libgnome, libart, libgnomeui;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
|
{ TGnomeWidgetSet }
|
||||||
|
|
||||||
TGnomeWidgetSet = class(TGtkWidgetSet)
|
TGnomeWidgetSet = class(TGtkWidgetSet)
|
||||||
private
|
private
|
||||||
procedure PassCmdLineOptions; override;
|
procedure PassCmdLineOptions; override;
|
||||||
@ -55,6 +58,7 @@ type
|
|||||||
|
|
||||||
function CreateComponent(Sender: TObject): THandle; override;
|
function CreateComponent(Sender: TObject): THandle; override;
|
||||||
public
|
public
|
||||||
|
function WidgetSetName: string; override;
|
||||||
{$I gnomewinapih.inc}
|
{$I gnomewinapih.inc}
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -289,6 +293,11 @@ begin
|
|||||||
Result:=THandle(P);
|
Result:=THandle(P);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TGnomeWidgetSet.WidgetSetName: string;
|
||||||
|
begin
|
||||||
|
Result:='gnome';
|
||||||
|
end;
|
||||||
|
|
||||||
{$I gnomewinapi.inc}
|
{$I gnomewinapi.inc}
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
@ -310,6 +310,7 @@ type
|
|||||||
procedure AppMinimize; override;
|
procedure AppMinimize; override;
|
||||||
procedure AppBringToFront; override;
|
procedure AppBringToFront; override;
|
||||||
procedure AppSetTitle(const ATitle: string); override;
|
procedure AppSetTitle(const ATitle: string); override;
|
||||||
|
function WidgetSetName: string; override;
|
||||||
public
|
public
|
||||||
constructor Create;
|
constructor Create;
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
|
@ -1968,6 +1968,11 @@ begin
|
|||||||
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TGTKWidgetSet.WidgetSetName: string;
|
||||||
|
begin
|
||||||
|
Result:='gtk';
|
||||||
|
end;
|
||||||
|
|
||||||
{------------------------------------------------------------------------------
|
{------------------------------------------------------------------------------
|
||||||
Method: TGtkWidgetSet.RecreateWnd
|
Method: TGtkWidgetSet.RecreateWnd
|
||||||
Params: Sender: TObject - the lcl wincontrol, that is to recreated
|
Params: Sender: TObject - the lcl wincontrol, that is to recreated
|
||||||
|
@ -74,7 +74,8 @@ type
|
|||||||
SelWidget: PGtkWidget); override;
|
SelWidget: PGtkWidget); override;
|
||||||
procedure CreatePreviewDialogControl(
|
procedure CreatePreviewDialogControl(
|
||||||
PreviewDialog: TPreviewFileDialog; SelWidget: PGtkWidget); override;
|
PreviewDialog: TPreviewFileDialog; SelWidget: PGtkWidget); override;
|
||||||
public
|
public
|
||||||
|
function WidgetSetName: string; override;
|
||||||
{$I gtk2winapih.inc}
|
{$I gtk2winapih.inc}
|
||||||
{$I gtk2lclintfh.inc}
|
{$I gtk2lclintfh.inc}
|
||||||
end;
|
end;
|
||||||
|
@ -1007,6 +1007,11 @@ begin
|
|||||||
gtk_widget_show(PreviewWidget);
|
gtk_widget_show(PreviewWidget);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TGtk2WidgetSet.WidgetSetName: string;
|
||||||
|
begin
|
||||||
|
Result:='gtk2';
|
||||||
|
end;
|
||||||
|
|
||||||
{$IFDEF ASSERT_IS_ON}
|
{$IFDEF ASSERT_IS_ON}
|
||||||
{$UNDEF ASSERT_IS_ON}
|
{$UNDEF ASSERT_IS_ON}
|
||||||
{$C-}
|
{$C-}
|
||||||
|
@ -36,10 +36,11 @@ interface
|
|||||||
uses
|
uses
|
||||||
// Bindings - qt4 must come first to avoid type redefinition problems on Windows
|
// Bindings - qt4 must come first to avoid type redefinition problems on Windows
|
||||||
qt4,
|
qt4,
|
||||||
|
// FPC
|
||||||
|
Classes, SysUtils, Math, Types,
|
||||||
// LCL
|
// LCL
|
||||||
Types, InterfaceBase, SysUtils, LCLProc, LCLType, LMessages, Classes,
|
InterfaceBase, LCLProc, LCLType, LMessages, Controls, ExtCtrls, Forms,
|
||||||
Controls, ExtCtrls, Forms, Dialogs, StdCtrls, Comctrls, LCLIntf,
|
Dialogs, StdCtrls, Comctrls, LCLIntf, GraphType;
|
||||||
GraphType, Math;
|
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
@ -58,6 +59,7 @@ type
|
|||||||
procedure AppMinimize; override;
|
procedure AppMinimize; override;
|
||||||
procedure AppBringToFront; override;
|
procedure AppBringToFront; override;
|
||||||
// procedure AppSetTitle(const ATitle: string); override;
|
// procedure AppSetTitle(const ATitle: string); override;
|
||||||
|
function WidgetSetName: string; override;
|
||||||
public
|
public
|
||||||
constructor Create;
|
constructor Create;
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
|
@ -145,6 +145,11 @@ begin
|
|||||||
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TQtWidgetSet.WidgetSetName: string;
|
||||||
|
begin
|
||||||
|
Result:='qt';
|
||||||
|
end;
|
||||||
|
|
||||||
function TQtWidgetSet.DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor;
|
function TQtWidgetSet.DCGetPixel(CanvasHandle: HDC; X, Y: integer): TGraphicsColor;
|
||||||
{var
|
{var
|
||||||
Color: QColorH;}
|
Color: QColorH;}
|
||||||
|
@ -186,6 +186,7 @@ Type
|
|||||||
procedure AppWaitMessage; override;
|
procedure AppWaitMessage; override;
|
||||||
Procedure AppTerminate; Override;
|
Procedure AppTerminate; Override;
|
||||||
procedure AppSetTitle(const ATitle: string); override;
|
procedure AppSetTitle(const ATitle: string); override;
|
||||||
|
function WidgetSetName: string; override;
|
||||||
|
|
||||||
Function InitHintFont(HintFont: TObject): Boolean; Override;
|
Function InitHintFont(HintFont: TObject): Boolean; Override;
|
||||||
Procedure AttachMenuToWindow(AMenuObject: TComponent); Override;
|
Procedure AttachMenuToWindow(AMenuObject: TComponent); Override;
|
||||||
|
@ -418,6 +418,11 @@ begin
|
|||||||
{$endif}
|
{$endif}
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TWin32WidgetSet.WidgetSetName: string;
|
||||||
|
begin
|
||||||
|
Result:='win32';
|
||||||
|
end;
|
||||||
|
|
||||||
{------------------------------------------------------------------------------
|
{------------------------------------------------------------------------------
|
||||||
Function: CreateTimer
|
Function: CreateTimer
|
||||||
Params: Interval:
|
Params: Interval:
|
||||||
|
@ -176,6 +176,7 @@ type
|
|||||||
procedure AppProcessMessages; override;
|
procedure AppProcessMessages; override;
|
||||||
procedure AppWaitMessage; override;
|
procedure AppWaitMessage; override;
|
||||||
Procedure AppTerminate; Override;
|
Procedure AppTerminate; Override;
|
||||||
|
function WidgetSetName: string; override;
|
||||||
Function InitHintFont(HintFont: TObject): Boolean; override;
|
Function InitHintFont(HintFont: TObject): Boolean; override;
|
||||||
Procedure AttachMenuToWindow(AMenuObject: TComponent); override;
|
Procedure AttachMenuToWindow(AMenuObject: TComponent); override;
|
||||||
procedure AppRun(const ALoop: TApplicationMainLoop); override;
|
procedure AppRun(const ALoop: TApplicationMainLoop); override;
|
||||||
|
@ -301,6 +301,11 @@ begin
|
|||||||
PostQuitMessage(0);
|
PostQuitMessage(0);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TWinCEWidgetSet.WidgetSetName: string;
|
||||||
|
begin
|
||||||
|
Result:='wince';
|
||||||
|
end;
|
||||||
|
|
||||||
function TWinCEWidgetSet.InitHintFont(HintFont: TObject): Boolean;
|
function TWinCEWidgetSet.InitHintFont(HintFont: TObject): Boolean;
|
||||||
begin
|
begin
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user