STRUCT Drive
{
 .filehandle		DCD 0
 .size			DCD 0
 .media_changed		DCD 0
 .icon_handle		DCD 0
 .dismount		DCB "-HDFFS-Dismount "
 .name			DCB "1234567890123456", 0
 .hdf_filename		DBB 512-Drive.hdf_filename
 .hdf_filename_end
}
#set Drive_struct = 9	;size of Drive struct in log2 bytes

STRUCT User_Message
{
 .length		DCD 0
 .task_handle		DCD 0
 .my_ref		DCD 0
 .your_ref		DCD 0
 .message_code		DCD 0
 .filing_system		DCD 0
 .flags			DCD 0
 .directory		DBB 64-User_Message.directory
 .size
}

STRUCT WIMP_Icon
{
 .min_x			DCD 0		;Minimum x of icon
 .min_y			DCD 0		;Minimum y of icon
 .max_x			DCD 0		;Maximum x of icon
 .max_y			DCD 0		;Maximum y of icon
 .flags			DCD 0		;Icon flags
 .text			DCD 0		;pointer to text
 .validaton		DCD 0		;pointer to validation string
 .text_length		DCD 0		;length of text buffer
 .size
}

STRUCT WIMP_Taskbar_Icon
{
 .position		DCD 0		;Icon bar position
 .min_x			DCD 0		;Minimum x of icon
 .min_y			DCD 0		;Minimum y of icon
 .max_x			DCD 0		;Maximum x of icon
 .max_y			DCD 0		;Maximum y of icon
 .flags			DCD 0		;Icon flags
 .text			DCD 0		;pointer to text
 .validaton		DCD 0		;pointer to validation string
 .text_length		DCD 0		;length of text buffer
 .size
}

STRUCT Menu_Item
{
 .item_flags		DCD 0
 .submenu		DCD 0
 .icon_flags		DCD 0
 .text			DCD 0		;pointer to text
 .validaton		DCD 0		;pointer to validation string
 .text_length		DCD 0		;length of text buffer
}


#set template_buffer_size = 512			;size of Templates file
#set template_indirect_buffer_size = 256	;indirect Sprite text data

STRUCT VARS
{
 DCD 0						;pointer to itself
 .wimp_taskhandle		DCD 0
 .menu_main			DCD 0
 .filecore_private		DCD 0
 .disc_op_complete		DCD 0
 .new_style_error_block		DCD 0, 0, 0	;new style for RISC OS 3.5+
 .local_scatterlist		DBD 4
 .current_drive			DCD 0		;drive WINP is acting on
 .drive_info			DBB 8<<Drive_struct	;8 drives
 .wimp_message			DBB User_Message.size
 .WIMP_Poll_Block		DBB 256
 .WIMP_Icon_Block		DBB WIMP_Taskbar_Icon.size
 .window_handles		DBD Window_Max + 1
 .window_indirects		DBD Window_Max + 1
 .open_window_block		DBB 36
 .template_buffer		DBB template_buffer_size
 .template_indirect_buffer	DBB template_indirect_buffer_size
 .IDENTIFY_response		DBB 512
 DBB 1024
 .stack
 DCD 16
 .free_stack
 .size			;must end word aligned
}
