Class Hierarchy:
cObject

Mixin


Entry_View_Client_mixinMixins:
View_Dependent_Item_Mixin, 
Class Definition
Properties
Integer
Auto_Top_Item_State
When activate is performed (as opposed to set current_scope) the
first focusable object is activated. Should the first item of the
first object become the current_item?
If Top_View is true and Top_Item is false you get the old dac
behaviors.
 Integer
Auto_Top_View_State
**JJT**(2) New properties
when false activate will attempt to activate the scope_focus
when true, activate activates first object.
 Integer
DEO_Attach_All_State
 Integer
DSO_Detach_Mode
**JJT**(2) New properties
 Integer
Main_DD
 RowId
priInitialRowId
keeps track of main-file record when new view is entered!
this was public but is no longer user. RowId replaces it.
Property Integer Initial_Main_record      0 // obsolete...should it be maintained?
 Integer
private.Last_View_Focus
**JJT**(2)
When changing views this will keep track of the object that had
the focus when this view (scope) was exited. This manages nested
scopes within a view.
 Integer
View_Latch_State
**JJT**(2) New properties
If Main_DD is defined
View_latch_state = T : Latch if main-file exists
View_latch_state = F : Clear the buffer
Default_View_Latch_State
 String
View_Name
default name...could be useful
 integer
wasNotinUse_State
internal use
 Functions and Procedures
Integer
Activate()
			
Augmented to allow views to take the focus without changing the
focus within the object. The property Auto_top_View_State controls
this. If true, always return to first object, first item. If false
return to current-item of scope focus (when possible).
 Integer
Add_Focus(Handle hoParent)
			
**JJT**(2) --- Start of changes
Augmented to send Opening_view. If add_focus fails it sends
closing_view to reverse effects of Opening_view
 
Closing_View()
			
Disconnect servers from deos according to rules.

Construct_Object(integer img#)
			

Deactivating()
			
Augmented to Send Closing view
as of 15.1 we changed all deactivating/activating signatures to not return values (see windows.pkg / ComboForm / Activating for more)
Returns Integer
Integer
Default_Static_Server_State()
			
Views don't delegate to get this property. It uses system default
 
End_Construct_Object()
			
augment for dependent_item view support v.1.1
integer
Entering_Scope()
			
added to make the file buffers more reliable
 Integer
Exit_Application_Check()
			
Augment exit_application_check. If a change
is detected activate the changed view. This way the user sees what
has been changed.
 
Exiting_Scope(Handle hoNewScope)
			
Augment to keep track of the scope that had the focus when this
view was exited. Exiting_Scope seems to get called at the right
times - only when focus is moved to an object outside of view's focus.
rowId
FileRowId(Integer iFile)
			
Needed by view. Find the record number of the requested file.
If file = 0 use the main_file of Main_DD (if it exists).
 integer
Last_View_Focus()
			
Returns The last scope in the view to have the focus. Before returning
the value make sure that the scope object is active, else return 0
 Integer
Opening_View()
			
1) Take care of any buffer initialization
 integer
Opening_view_Recursive()
			
 
Prepare_Data_Sets()
			
only called if Main_DD exists and it is not yet in-use

Seed_Data_Sets()
			
use to preload anything into DSOs. By default, if a Main_DD is
defined, we will attempt to latch on
the record that was in the buffer when the view was entered!

Seed_Data_Sets_Recursive()
			

Set(Integer Foc)
			
Function File_Recnum Integer File# Returns Integer
integer Obj rec#
// if file not passed use main-file of main data set
If File# eq 0 Begin
Get Main_DD to Obj
If Obj get main_file of Obj to file#
end
If File# begin
//       Move file# to filenumber
//       move 0 to fieldindex
//       Move Indirect_file.recnum to Rec#
Get_Field_Value file# 0 to Rec#
end
Function_Return rec#
End_Function
We maintain Last_View_Focus to control for nested scopes. A normal
will have its scope_state true and no scoped children. However, a
zoom might be scoped. We control this by keeping track of the scope when
a scope is exited.