mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-06-05 05:18:17 +02:00
GTK3: Migrate TGtkSortType to enumeration type.
In Gtk3 WS code, variables of type Integer were used instead of ones of relevant enumeration type. This leads to compilation error now that `TGtkSortType` is defined as an enumeration type. This commit fixes those errors.
This commit is contained in:
parent
22c6d6658f
commit
e42a3c7df7
@ -907,6 +907,12 @@ type
|
||||
GTK_LEVEL_BAR_MODE_DISCRETE = 1,
|
||||
TGtkLevelBarModeMaxValue = $7FFFFFFF
|
||||
);
|
||||
TGtkSortType = (
|
||||
TGtkSortTypeMinValue = -$7FFFFFFF,
|
||||
GTK_SORT_ASCENDING = 0,
|
||||
GTK_SORT_DESCENDING = 1,
|
||||
TGtkSortTypeMaxValue = $7FFFFFFF
|
||||
);
|
||||
TGtkPackDirection = (
|
||||
TGtkPackDirectionMinValue = -$7FFFFFFF,
|
||||
GTK_PACK_DIRECTION_LTR = 0,
|
||||
@ -1305,13 +1311,6 @@ const
|
||||
GTK_ICON_LOOKUP_GENERIC_FALLBACK: TGtkIconLookupFlags = 8;
|
||||
GTK_ICON_LOOKUP_FORCE_SIZE: TGtkIconLookupFlags = 16;
|
||||
|
||||
type
|
||||
TGtkSortType = Integer;
|
||||
const
|
||||
{ GtkSortType }
|
||||
GTK_SORT_ASCENDING: TGtkSortType = 0;
|
||||
GTK_SORT_DESCENDING: TGtkSortType = 1;
|
||||
|
||||
type
|
||||
TGtkRcTokenType = Integer;
|
||||
const
|
||||
|
@ -6332,7 +6332,7 @@ end;
|
||||
procedure TGtk3ListView.ColumnSetSortIndicator(const AIndex: Integer;
|
||||
const AColumn: TListColumn; const ASortIndicator: TSortIndicator);
|
||||
const
|
||||
GtkOrder : array [ TSortIndicator] of TGtkSortType = (0, {GTK_SORT_ASCENDING}0, {GTK_SORT_DESCENDING}1);
|
||||
GtkOrder : array [ TSortIndicator] of TGtkSortType = (GTK_SORT_ASCENDING {0}, GTK_SORT_ASCENDING {0}, GTK_SORT_DESCENDING {1});
|
||||
var
|
||||
AGtkColumn: PGtkTreeViewColumn;
|
||||
begin
|
||||
|
Loading…
Reference in New Issue
Block a user