DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦74e74108e⟧ Ada Source

    Length: 4096 (0x1000)
    Types: Ada Source
    Notes: 03_class, FILE, R1k_Segment, e3_tag, package body Panel_Interface, seg_00ff01

Derivation

└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
    └─ ⟦cfc2e13cd⟧ »Space Info Vol 2« 
        └─⟦this⟧ 

E3 Source Code



with Seat_Controls;
with Screen;
package body Panel_Interface is

    function "<" (A, B : Seats.Seat_Id) return Boolean renames Seats."<";

    The_Panel : Screen.Panel;

    procedure Dump_O2 (Open : Boolean; Seat : Seats.Seat_Id) is
    begin
        [statement]  
    end Dump_O2;

    function Is_Passenger_Reading_Light (Seat : Seats.Seat_Id) return Boolean is
    begin
        return Seat < 100;
        -- Total kludge!!
    end Is_Passenger_Reading_Light;

    procedure Light_On (Seat : Seats.Seat_Id) is
    begin
        if Is_Passenger_Reading_Light (Seat) then
            Screen.Set_Light (Screen.On, The_Panel);
        else  -- Must be the service call light.
            Screen.Set_Service_Call (Screen.On, The_Panel);
        end if;
    end Light_On;

    procedure Light_Off (Seat : Seats.Seat_Id) is
    begin
        if Is_Passenger_Reading_Light (Seat) then
            Screen.Set_Light (Screen.Off, The_Panel);
        else  -- Must be the service call light.
            Screen.Set_Service_Call (Screen.Off, The_Panel);
        end if;
    end Light_Off;


    procedure Interact_Passenger is  
        Selection : Screen.Display_Item_With_Label;
        use Screen;  
        Available_Choices :
           constant array (Screen.Display_Item_With_Passenger_Choices) of
                       String (1 .. 40) :=
           (Audio_Channel => "1,2,3,4,5,6                             ",
            Game => "Pong, Pac_Man, Chess, Go, Tic_Tac_Toe   ",
            Movie => "Airport, Witness, Silver_Streak, Big    ");
    begin
        Screen.Create (The_Panel);
        loop
            Selection := Screen.Get_Selection (The_Panel);
            case Selection is
                when Weather | Flight_Info | Reservations |
                     Call | Redial | Modem =>
                    null;
                when Audio_Channel | Game | Movie =>
                    declare
                        Choice : constant String :=
                           Screen.Get_Choice
                              (For_Item => Selection,
                               From_List => Available_Choices (Selection),
                               On_The_Panel => The_Panel);
                    begin
                        null; -- don't need to do anything with the choice yet.
                    end;
                when Stock_Market =>
                    null;
                    -- Hard coded message!
                when Light_On =>
                    Seat_Controls.Light_On (23);
                when Light_Off =>
                    Seat_Controls.Light_Off (23);
                when Service_Call =>
                    Seat_Controls.Call_Button (23);
            end case;
        end loop;
        Screen.Close (The_Panel);
    end Interact_Passenger;

end Panel_Interface;

E3 Meta Data

    nblk1=3
    nid=0
    hdr6=6
        [0x00] rec0=22 rec1=00 rec2=01 rec3=00e
        [0x01] rec0=19 rec1=00 rec2=02 rec3=00e
        [0x02] rec0=17 rec1=00 rec2=03 rec3=000
    tail 0x2170c1fa4822f64176575 0x42a00088462060003