X-Git-Url: http://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=Ada95%2Fsamples%2Fsample-curses_demo.adb;h=4dd96a721d2aa9465837958cd1885588f10f8c2b;hp=aa5b10916a066ad0ff350bb6ce4ee56439e38e4b;hb=2b635f090ec43c82958cef9369464aee4dd8975f;hpb=661078ddbde3ce0f3b06e95642fbb9b5fef7dca1 diff --git a/Ada95/samples/sample-curses_demo.adb b/Ada95/samples/sample-curses_demo.adb index aa5b1091..4dd96a72 100644 --- a/Ada95/samples/sample-curses_demo.adb +++ b/Ada95/samples/sample-curses_demo.adb @@ -7,7 +7,7 @@ -- B O D Y -- -- -- ------------------------------------------------------------------------------ --- Copyright (c) 1998 Free Software Foundation, Inc. -- +-- Copyright (c) 1998-2004,2011 Free Software Foundation, Inc. -- -- -- -- Permission is hereby granted, free of charge, to any person obtaining a -- -- copy of this software and associated documentation files (the -- @@ -33,10 +33,11 @@ -- sale, use or other dealings in this Software without prior written -- -- authorization. -- ------------------------------------------------------------------------------ --- Author: Juergen Pfeifer 1996 +-- Author: Juergen Pfeifer, 1996 -- Version Control --- $Revision: 1.7 $ --- Binding Version 00.93 +-- $Revision: 1.17 $ +-- $Date: 2011/03/23 00:29:04 $ +-- Binding Version 01.00 ------------------------------------------------------------------------------ with Terminal_Interface.Curses; use Terminal_Interface.Curses; with Terminal_Interface.Curses.Menus; use Terminal_Interface.Curses.Menus; @@ -47,8 +48,7 @@ with Terminal_Interface.Curses.Panels.User_Data; with Sample.Manifest; use Sample.Manifest; with Sample.Helpers; use Sample.Helpers; with Sample.Function_Key_Setting; use Sample.Function_Key_Setting; -with Sample.Keyboard_Handler; use Sample.Keyboard_Handler; -with Sample.Header_Handler; use Sample.Header_Handler; + with Sample.Explanation; use Sample.Explanation; with Sample.Menu_Demo.Handler; @@ -61,7 +61,7 @@ package body Sample.Curses_Demo is type User_Data_Access is access all User_Data; package PUD is new Panels.User_Data (User_Data, User_Data_Access); -- We use above instantiation of the generic User_Data package to - -- demonstrate and test the use of the user data maechanism. + -- demonstrate and test the use of the user data mechanism. procedure Demo is @@ -75,7 +75,7 @@ package body Sample.Curses_Demo is New_Item ("Mouse Demo"), Null_Item); M : Menu := New_Menu (Itm); - U1 : User_Data_Access := new User_Data'(4711); + U1 : constant User_Data_Access := new User_Data'(4711); U2 : User_Data_Access; function My_Driver (M : Menu; @@ -122,9 +122,9 @@ package body Sample.Curses_Demo is declare O : Item_Option_Set; begin - Get_Options (Itm (2), O); + Get_Options (Itm.all (2), O); O.Selectable := False; - Set_Options (Itm (2), O); + Set_Options (Itm.all (2), O); end; end if;