File: table.adb

package info (click to toggle)
libgtkada 2.24.4dfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 12,208 kB
  • ctags: 1,676
  • sloc: ada: 119,686; ansic: 4,719; sh: 3,003; makefile: 690; xml: 338; perl: 70
file content (38 lines) | stat: -rw-r--r-- 814 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
with Gtk.Main;

with Ada.Text_IO;
use  Ada.Text_IO;

package body Table is

   procedure Callback
     (Widget : access Gtk_Widget_Record'Class;
      Data   : String_Access)
   is
      pragma Unreferenced (Widget);
   begin
      Put_Line ("Hello again - " & Data.all & " was pressed");
   end Callback;

   function Delete_Event
     (Widget : access Gtk_Widget_Record'Class;
      Event  : Gdk_Event) return Boolean
   is
      pragma Unreferenced (Widget);
      pragma Unreferenced (Event);
   begin
      Gtk.Main.Main_Quit;
      return False;
   end Delete_Event;

   procedure Quit
     (Widget : access Gtk_Widget_Record'Class;
      Data   : String_Access)
   is
      pragma Unreferenced (Widget);
   begin
      Put_Line ("Quitting - " & Data.all);
      Gtk.Main.Main_Quit;
   end Quit;

end Table;