|
|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 11264 (0x2c00)
Types: Ada Source
Notes: 03_class, FILE, R1k_Segment, e3_tag, package body Xlbp_Context_Manager, seg_004f51
└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
└─⟦cfc2e13cd⟧ »Space Info Vol 2«
└─⟦this⟧
with Xlbt_Arithmetic;
use Xlbt_Arithmetic;
with Xlbt_Basic;
use Xlbt_Basic;
with Xlbt_Context_Manager;
use Xlbt_Context_Manager;
with Xlbt_Context_Manager2;
use Xlbt_Context_Manager2;
with Xlbt_Rm;
use Xlbt_Rm;
with Xlbt_Rm2;
use Xlbt_Rm2;
with Xlbt_String;
use Xlbt_String;
with Xlbt_Univ_Ptr;
use Xlbt_Univ_Ptr;
with Xlbp_Rm_Quark;
use Xlbp_Rm_Quark;
package body Xlbp_Context_Manager is
------------------------------------------------------------------------------
-- X Library Context Management
--
-- Xlbp_Context_Manager - Used to associate data with a window.
------------------------------------------------------------------------------
-- Copyright 1989 - 1991 by Rational, Santa Clara, California.
-- Copyright 1987 - 1989 by Digital Equipment Corporation, Maynard, Mass.
-- Copyright 1987 - 1989 by Massachusetts Institute of Technology
-- Cambridge, Massachusetts.
--
-- All Rights Reserved.
--
-- Permission to use, copy, modify, and distribute this software and its
-- documentation for any purpose and without fee is hereby granted,
-- provided that the above copyright notice(s) appear in all copies and that
-- both that copyright notice(s) and this permission notice appear in
-- supporting documentation, and that the names of Digital, MIT, or Rational
-- not be used in advertising or publicity pertaining to distribution of
-- the software without specific, written prior permission.
--
-- Digital, MIT, and Rational disclaim all warranties with regard to this
-- software, including all implied warranties of merchantability and fitness,
-- in no event shall Digital, MIT, or Rational be liable for any special,
-- indirect or consequential damages or any damages whatsoever resulting from
-- loss of use, data or profits, whether in an action of contract, negligence
-- or other tortious action, arising out of or in connection with the use or
-- performance of this software.
------------------------------------------------------------------------------
--/ if OLD_CONTEXT_MANAGER then
--// --\x0c
--// function Hash (Window : X_Window;
--// Context : X_Context) return S_Natural is
--// begin
--// return S_Natural ((Window.Drawable.Id.Number / 8 * 7 + Context.Id) rem
--// X_Context_Hash_Table'Length);
--// end Hash;
--//
--// --/ if INLINE then
--// --// pragma Inline (Hash);
--// --/ end if;
--//
--// --\x0c
--// function X_Delete_Context
--// (Display : X_Display;
--// Window : X_Window;
--// Context : X_Context) return X_Associative_Returns is
--// ------------------------------------------------------------------------------
--// -- Locate and remove a Window/Context pair.
--// ------------------------------------------------------------------------------
--// The_Hash : S_Natural := Hash (Window, Context);
--// The_Entry : X_Context_Table_Entry;
--// Nxt_Entry : X_Context_Table_Entry;
--// Tmp_Entry : X_Context_Table_Entry;
--// Contexts : X_Context_Hash_List;
--// begin
--//
--// if Display.Contexts /= None_X_Universal_Pointer then
--// Contexts := Univ_X_Context_Hash_List.From_X_Universal_Pointer
--// (Display.Contexts);
--// The_Entry := Contexts (The_Hash);
--//
--// if The_Entry.Window = Window and then
--// The_Entry.Context = Context then
--// Contexts (The_Hash) := The_Entry.Next;
--// Free_X_Context_Table_Entry (The_Entry);
--// return Xc_Success;
--// end if;
--//
--// Nxt_Entry := The_Entry.Next;
--// while Nxt_Entry /= null loop
--// if Nxt_Entry.Window = Window and then
--// Nxt_Entry.Context = Context then
--// Tmp_Entry := Nxt_Entry;
--// The_Entry.Next := Nxt_Entry.Next;
--// Free_X_Context_Table_Entry (Nxt_Entry);
--// return Xc_Success;
--// end if;
--// The_Entry := Nxt_Entry;
--// Nxt_Entry := Nxt_Entry.Next;
--// end loop;
--// end if;
--//
--// return Xc_No_Ent;
--//
--// end X_Delete_Context;
--//
--// --\x0c
--// procedure X_Find_Context (Display : X_Display;
--// Window : X_Window;
--// Context : X_Context;
--// Data : out X_Rm_Value;
--// Status : out X_Associative_Returns) is
--// ------------------------------------------------------------------------------
--// -- Insert/Replace an entry corresponding to Window/Context into the Contexts
--// -- table for this Display.
--// ------------------------------------------------------------------------------
--// The_Hash : S_Natural := Hash (Window, Context);
--// The_Entry : X_Context_Table_Entry;
--// Contexts : X_Context_Hash_List;
--// begin
--//
--// if Display.Contexts /= None_X_Universal_Pointer then
--// Contexts := Univ_X_Context_Hash_List.From_X_Universal_Pointer
--// (Display.Contexts);
--// The_Entry := Contexts (The_Hash);
--//
--// while The_Entry /= null loop
--// if The_Entry.Window = Window and then
--// The_Entry.Context = Context then
--// Data := The_Entry.Data;
--// Status := Xc_Success;
--// return;
--// end if;
--// end loop;
--// end if;
--//
--// Data := None_X_Rm_Value;
--// Status := Xc_No_Ent;
--//
--// end X_Find_Context;
--//
--// --\x0c
--// function X_Save_Context
--// (Display : X_Display;
--// Window : X_Window;
--// Context : X_Context;
--// Data : X_Rm_Value) return X_Associative_Returns is
--// ------------------------------------------------------------------------------
--// -- Insert/Replace an entry corresponding to Window/Context into the Contexts
--// -- table for this Display.
--// ------------------------------------------------------------------------------
--// The_Hash : S_Natural := Hash (Window, Context);
--// The_Entry : X_Context_Table_Entry;
--// Contexts : X_Context_Hash_List;
--// begin
--// if Display.Contexts = None_X_Universal_Pointer then
--// Contexts := new X_Context_Hash_Table;
--// Display.Contexts :=
--// Univ_X_Context_Hash_List.To_X_Universal_Pointer (Contexts);
--// else
--// Contexts := Univ_X_Context_Hash_List.From_X_Universal_Pointer
--// (Display.Contexts);
--// end if;
--//
--// The_Entry := Contexts (The_Hash);
--//
--// while The_Entry /= null loop
--// if The_Entry.Window = Window and then
--// The_Entry.Context = Context then
--// The_Entry.Data := Data;
--// return Xc_Success;
--// end if;
--// end loop;
--//
--// Contexts (The_Hash) :=
--// new X_Context_Table_Entry_Rec'((Window => Window,
--// Context => Context,
--// Data => Data,
--// Next => Contexts (The_Hash)));
--// return Xc_Success;
--//
--// exception
--//
--// when Storage_Error =>
--// return Xc_No_Mem;
--//
--// end X_Save_Context;
--//
--// --\x0c
--// function X_String_To_Context (Name : X_String) return X_Context is
--// begin
--// return X_Context (X_Rm_String_To_Quark (Name));
--// end X_String_To_Context;
--//
--// --\x0c
--// function X_Context_To_String (Context : X_Context) return X_String is
--// ------------------------------------------------------------------------------
--// -- Context - Specifies the X_Context to convert.
--// --
--// -- Returns the original string name of a context.
--// ------------------------------------------------------------------------------
--// begin
--// return X_Rm_Quark_To_String (X_Rm_Quark (Context));
--// end X_Context_To_String;
--//
--// --\x0c
--// function X_Unique_Context return X_Context is
--// begin
--// return X_Context (X_Rm_Unique_Quark);
--// end X_Unique_Context;
--//
--/ end if;
--\x0c
end Xlbp_Context_Manager;
nblk1=a
nid=0
hdr6=14
[0x00] rec0=21 rec1=00 rec2=01 rec3=016
[0x01] rec0=0f rec1=00 rec2=02 rec3=08e
[0x02] rec0=19 rec1=00 rec2=03 rec3=006
[0x03] rec0=15 rec1=00 rec2=04 rec3=074
[0x04] rec0=17 rec1=00 rec2=05 rec3=042
[0x05] rec0=16 rec1=00 rec2=06 rec3=008
[0x06] rec0=16 rec1=00 rec2=07 rec3=03e
[0x07] rec0=18 rec1=00 rec2=08 rec3=01a
[0x08] rec0=1c rec1=00 rec2=09 rec3=006
[0x09] rec0=05 rec1=00 rec2=0a rec3=000
tail 0x217006aca819781e605fa 0x42a00088462063203