text
stringlengths
0
234
Put_Line (File, " with Pre => Object.Has_Proxy and Surface.Has_Proxy and Pointer.Has_Proxy;");
elsif Name = "Locked_Pointer_V1" then
Put_Line (File, "");
Put_Line (File, " procedure Set_Cursor_Position_Hint");
Put_Line (File, " (Object : Locked_Pointer_V1;");
Put_Line (File, " X, Y : Fixed)");
Put_Line (File, " with Pre => Object.Has_Proxy;");
Put_Line (File, "");
Put_Line (File, " procedure Set_Region");
Put_Line (File, " (Object : Locked_Pointer_V1;");
Put_Line (File, " Region : Client.Region'Class)");
Put_Line (File, " with Pre => Object.Has_Proxy and Region.Has_Proxy;");
elsif Name = "Confined_Pointer_V1" then
Put_Line (File, "");
Put_Line (File, " procedure Set_Region");
Put_Line (File, " (Object : Confined_Pointer_V1;");
Put_Line (File, " Region : Client.Region'Class)");
Put_Line (File, " with Pre => Object.Has_Proxy and Region.Has_Proxy;");
end if;
end Handle_Interface_Subprogram_Pointer_Constraints;
procedure Handle_Interface_Events_Pointer_Constraints
(Interface_Tag : aliased Wayland_XML.Interface_Tag)
is
Name : constant String
:= Xml_Parser_Utils.Adaify_Name (Wayland_XML.Name (Interface_Tag));
begin
if not Exists_Events (Interface_Tag) then
return;
end if;
Generate_Prefix_Spec_Events;
if Name = "Locked_Pointer_V1" then
Put_Line (File, " with procedure Locked");
Put_Line (File, " (Pointer : in out Locked_Pointer_V1'Class);");
Put_Line (File, "");
Put_Line (File, " with procedure Unlocked");
Put_Line (File, " (Pointer : in out Locked_Pointer_V1'Class);");
elsif Name = "Confined_Pointer_V1" then
Put_Line (File, " with procedure Confined");
Put_Line (File, " (Pointer : in out Confined_Pointer_V1'Class);");
Put_Line (File, "");
Put_Line (File, " with procedure Unconfined");
Put_Line (File, " (Pointer : in out Confined_Pointer_V1'Class);");
end if;
Generate_Suffix_Spec_Events (Name);
end Handle_Interface_Events_Pointer_Constraints;
procedure Handle_Interface_Subprogram_Pointer_Gestures
(Interface_Tag : aliased Wayland_XML.Interface_Tag)
is
procedure Print_Constructor (Name : String) is
begin
Put_Line (File, "");
Put_Line (File, " procedure Get_" & Name & "_Gesture");
Put_Line (File, " (Object : Pointer_Gestures_V1;");
Put_Line (File, " Pointer : Client.Pointer'Class;");
Put_Line (File, " Gesture : in out Pointer_Gesture_" & Name & "_V1'Class)");
Put_Line (File, " with Pre => Object.Has_Proxy and Pointer.Has_Proxy;");
end Print_Constructor;
Name : constant String
:= Xml_Parser_Utils.Adaify_Name (Wayland_XML.Name (Interface_Tag));
begin
if Name in "Pointer_Gestures_V1" then
Generate_Spec_Bind_Subprogram (Name);
end if;
if Name in "Pointer_Gestures_V1" then
Print_Constructor ("Swipe");
Print_Constructor ("Pinch");
Print_Constructor ("Hold");
end if;
end Handle_Interface_Subprogram_Pointer_Gestures;
procedure Handle_Interface_Events_Pointer_Gestures
(Interface_Tag : aliased Wayland_XML.Interface_Tag)
is
Name : constant String
:= Xml_Parser_Utils.Adaify_Name (Wayland_XML.Name (Interface_Tag));
begin
if not Exists_Events (Interface_Tag) then
return;
end if;
Generate_Prefix_Spec_Events;
if Name = "Pointer_Gesture_Swipe_V1" then
Put_Line (File, " with procedure Gesture_Begin");
Put_Line (File, " (Gesture : in out Pointer_Gesture_Swipe_V1'Class;");
Put_Line (File, " Serial : Unsigned_32;");
Put_Line (File, " Timestamp : Duration;");
Put_Line (File, " Surface : Client.Surface;");
Put_Line (File, " Fingers : Unsigned_32);");
Put_Line (File, "");
Put_Line (File, " with procedure Gesture_Update");
Put_Line (File, " (Gesture : in out Pointer_Gesture_Swipe_V1'Class;");
Put_Line (File, " Timestamp : Duration;");