# ##########################################################################
# 
#      dtfile.dt
# 
#      Actions for interfacing to the Common Desktop Environment 
#      File Manager.
# 
#     (c) Copyright 1993, 1994, 1995 Hewlett-Packard Company
#     (c) Copyright 1993, 1994, 1995 International Business Machines Corp.
#     (c) Copyright 1993, 1994, 1995 Sun Microsystems, Inc.
#     (c) Copyright 1993, 1994, 1995 Novell, Inc.
# 
#      $TOG: dtfile.dt.src /main/5 1997/03/28 14:46:11 mgreess $
# 
# ##########################################################################
set DtDbVersion=1.0
# ##########################################################################
# 
# WARNING:  This file may be overwritten in subsequent installations of
#     the Common Desktop Environment (CDE).  Consequently, any system wide
#     changes should be made to an equivalent database file in
#     /usr/pkg/etc/dt/types and not in this file.
# 
# ##########################################################################
# ##################################################################
# 
# Data Attributes - mainly consumed by the File Manager
# 
# ##################################################################
# ###########################################################
# 
# Folders
# 
# ###########################################################
DATA_ATTRIBUTES TRASH_FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON            DtdirR
        MEDIA           FILE_NAME
        MOVE_TO_ACTION  FILESYSTEM_MOVE
	DESCRIPTION	This folder is a temporary location for trash. 
        TYPE_LABEL      TRASH_FOLDER
}
DATA_CRITERIA TRASH_FOLDER1
{
        DATA_ATTRIBUTES_NAME TRASH_FOLDER
        MODE            d
        PATH_PATTERN    */.dt/Trash
}
ACTION Open
{
        LABEL           Open
        ARG_TYPE        TRASH_FOLDER
        TYPE            MAP
        MAP_ACTION      OpenFolder
}
ACTION Print
{
        LABEL           Print
        ARG_TYPE        TRASH_FOLDER
        TYPE            MAP
        MAP_ACTION      PrintFolderList
}
# ###########################################################
DATA_ATTRIBUTES OPEN_PARENT_FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON		Dtdirup
        MEDIA           FILE_NAME
        MOVE_TO_ACTION	FILESYSTEM_MOVE
        COPY_TO_ACTION	FILESYSTEM_COPY
        LINK_TO_ACTION	FILESYSTEM_LINK
}
DATA_ATTRIBUTES PARENT_FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON		Dtdirup
        MEDIA           FILE_NAME
        MOVE_TO_ACTION	FILESYSTEM_MOVE
        COPY_TO_ACTION	FILESYSTEM_COPY
        LINK_TO_ACTION	FILESYSTEM_LINK
	DESCRIPTION	The '..' icon represents the parent folder \
                        of the current folder.  Open it to move one \
                        level up the folder tree. Its data type is \
                        named PARENT_FOLDER.
        TYPE_LABEL      PARENT_FOLDER
}
DATA_CRITERIA PARENT_FOLDER1
{
	DATA_ATTRIBUTES_NAME PARENT_FOLDER
	MODE		d
	NAME_PATTERN	..
}
ACTION Open
{
        LABEL           Open
        ARG_TYPE        PARENT_FOLDER
        TYPE            MAP
        MAP_ACTION      OpenFolder
}
ACTION Print
{
        LABEL           Print
        ARG_TYPE        PARENT_FOLDER
        TYPE            MAP
        MAP_ACTION      PrintFolderList
}
# ###########################################################
DATA_ATTRIBUTES OPEN_CURRENT_FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON		DtdirB
        MEDIA           FILE_NAME
        MOVE_TO_ACTION	FILESYSTEM_MOVE
        COPY_TO_ACTION	FILESYSTEM_COPY
        LINK_TO_ACTION	FILESYSTEM_LINK
}
DATA_ATTRIBUTES CURRENT_FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON		DtdirB
        MEDIA           FILE_NAME
        MOVE_TO_ACTION	FILESYSTEM_MOVE
        COPY_TO_ACTION	FILESYSTEM_COPY
        LINK_TO_ACTION	FILESYSTEM_LINK
	DESCRIPTION	The '.' icon represents the current folder. \
                        Its data type is named CURRENT_FOLDER.
        TYPE_LABEL      CURRENT_FOLDER
}
DATA_CRITERIA CURRENT_FOLDER1
{
	DATA_ATTRIBUTES_NAME CURRENT_FOLDER
	MODE		d
	NAME_PATTERN	.
}
ACTION Open
{
        LABEL           Open
        ARG_TYPE        CURRENT_FOLDER
        TYPE            MAP
        MAP_ACTION      OpenFolder
}
ACTION Print
{
        LABEL           Print
        ARG_TYPE        CURRENT_FOLDER
        TYPE            MAP
        MAP_ACTION      PrintFolderList
}
# ###########################################################
DATA_ATTRIBUTES DOT_FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON		DtdirB
        MEDIA           FILE_NAME
        MOVE_TO_ACTION	FILESYSTEM_MOVE
        COPY_TO_ACTION	FILESYSTEM_COPY
        LINK_TO_ACTION	FILESYSTEM_LINK
	DESCRIPTION	This folder's data type is named DOT_FOLDER. \
                        A DOT_FOLDER folder is a folder whose name \
                        begins with a dot (.). A DOT_FOLDER is normally hidden.
        TYPE_LABEL      DOT_FOLDER
}
DATA_CRITERIA DOT_FOLDER1
{
	DATA_ATTRIBUTES_NAME DOT_FOLDER
	MODE		d
	NAME_PATTERN	.*
}
ACTION Open
{
        LABEL           Open
        ARG_TYPE        DOT_FOLDER
        TYPE            MAP
        MAP_ACTION      OpenFolder
}
ACTION Print
{
        LABEL           Print
        ARG_TYPE        DOT_FOLDER
        TYPE            MAP
        MAP_ACTION      PrintFolderList
}
# ###########################################################
DATA_ATTRIBUTES FOLDER_LOCK
{
	ACTIONS         OpenInPlace,OpenNewView,Print
        ICON		Dtdirlk
        MEDIA           FILE_NAME
        MOVE_TO_ACTION	FILESYSTEM_MOVE
        COPY_TO_ACTION	FILESYSTEM_COPY
        LINK_TO_ACTION	FILESYSTEM_LINK
	DESCRIPTION	This is a folder to which you lack write \
                        permission.  You cannot add or remove files. Its \
                        data type is named FOLDER_LOCK.
        TYPE_LABEL      FOLDER_LOCK
}
DATA_CRITERIA FOLDER_LOCK1
{
	DATA_ATTRIBUTES_NAME FOLDER_LOCK
	MODE            d&!r
}
DATA_CRITERIA FOLDER_LOCK2
{
	DATA_ATTRIBUTES_NAME FOLDER_LOCK
	MODE            d&!x
}
DATA_ATTRIBUTES OPEN_NON_WRITABLE_FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON            DtdirBO
        MEDIA           FILE_NAME
        MOVE_TO_ACTION  FILESYSTEM_MOVE
        COPY_TO_ACTION  FILESYSTEM_COPY
        LINK_TO_ACTION  FILESYSTEM_LINK
}
DATA_ATTRIBUTES NON_WRITABLE_FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON            Dtdirnw
        MEDIA           FILE_NAME
        MOVE_TO_ACTION  FILESYSTEM_MOVE
        COPY_TO_ACTION  FILESYSTEM_COPY
        LINK_TO_ACTION  FILESYSTEM_LINK
        DESCRIPTION     This is a folder to which you lack write \
                        permission.  You cannot add or remove files. Its \
                        data type is named FOLDER_LOCK.
        TYPE_LABEL      NON_WRITABLE_FOLDER
}
DATA_CRITERIA NON_WRITABLE_FOLDER1
{
	DATA_ATTRIBUTES_NAME NON_WRITABLE_FOLDER
	MODE            d&!w
}
ACTION Open
{
        LABEL           Open
        ARG_TYPE        FOLDER_LOCK
        TYPE            MAP
        MAP_ACTION      OpenFolder
}
ACTION Print
{
        LABEL           Print
        ARG_TYPE        FOLDER_LOCK
        TYPE            MAP
        MAP_ACTION      PrintFolderList
}
# ###########################################################
DATA_ATTRIBUTES OPEN_FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON		DtdirBO
        MEDIA           FILE_NAME
        MOVE_TO_ACTION	FILESYSTEM_MOVE
        COPY_TO_ACTION	FILESYSTEM_COPY
        LINK_TO_ACTION	FILESYSTEM_LINK
}
DATA_ATTRIBUTES FOLDER
{
        ACTIONS         OpenInPlace,OpenNewView,Print
        ICON		DtdirB
        MEDIA           FILE_NAME
        MOVE_TO_ACTION	FILESYSTEM_MOVE
        COPY_TO_ACTION	FILESYSTEM_COPY
        LINK_TO_ACTION	FILESYSTEM_LINK
	DESCRIPTION	This is a folder. A folder is a \
                        container that holds files or other folders. \
                        Its data type is named FOLDER.
        TYPE_LABEL      FOLDER
}
DATA_CRITERIA FOLDER1
{
	DATA_ATTRIBUTES_NAME FOLDER
	MODE		d
}
ACTION Open
{
        LABEL           Open
        ARG_TYPE        FOLDER
        TYPE            MAP
        MAP_ACTION      OpenFolder
}
ACTION Print
{
        LABEL           Print
        ARG_TYPE        FOLDER
        TYPE            MAP
        MAP_ACTION      PrintFolderList
}
# ###########################################################
# ###########################################################
# 
# Data Attributes
# 
# ###########################################################
DATA_ATTRIBUTES RECURSIVE_LINK
{
	ICON		Dtinf
	DESCRIPTION	This icon represents a symbolic link that points \
                        to itself, either folder or through a series of \
                        intermediate symbolic links.  Its data type is \
                        named RECURSIVE_LINK.
        TYPE_LABEL      RECURSIVE_LINK
}
# ###########################################################
DATA_ATTRIBUTES BROKEN_LINK
{
        ICON            Dtblink
        DESCRIPTION     This icon represents a symbolic link that \
                        points to a non-existent file.  Its data type is \
                        named BROKEN_LINK.
        TYPE_LABEL      BROKEN_LINK
}
# ###########################################################
DATA_ATTRIBUTES DOT_FILE
{
        ACTIONS         Open,Print
        ICON		Dtdata
        IS_TEXT		true
        MIME_TYPE	text/plain
        MEDIA           C_STRING
	DESCRIPTION	This file's data type is named DOT_FILE. \
                        A DOT_FILE is a file whose name begins with a \
                        dot (.).  A DOT_FILE is normally hidden.
        TYPE_LABEL      DOT_FILE
}
DATA_CRITERIA DOT_FILE1
{
	DATA_ATTRIBUTES_NAME DOT_FILE
        MODE            f
	NAME_PATTERN	.*
}
# ###########################################################
DATA_ATTRIBUTES EXECUTABLE
{
	ACTIONS		Run,Open
        ICON		Dtexec
        IS_EXECUTABLE	true
        COPY_TO_ACTION  Execute
        MIME_TYPE	application/octet-stream
	SUNV3_TYPE	default-app
        MEDIA           _DT_DATA
	DESCRIPTION	This file contains a shell script or a compiled \
                        program that can be executed.  Its data type is \
                        named EXECUTABLE.
        TYPE_LABEL      EXECUTABLE
}
DATA_CRITERIA EXECUTABLE1
{
	DATA_ATTRIBUTES_NAME EXECUTABLE
	MODE		f&x
}
ACTION Run
{
        LABEL           Run
        ARG_TYPE        EXECUTABLE
        TYPE            MAP
        MAP_ACTION      Execute
}
# ###########################################################
DATA_ATTRIBUTES UNKNOWN
{
	ACTIONS		Open,Print
        ICON		Dtdata
        MIME_TYPE	application/octet-stream
        MEDIA           _DT_DATA
	DESCRIPTION	This file does not match any other data type, \
                        so it has been assigned the data type named UNKNOWN.
        TYPE_LABEL      UNKNOWN
}
# ###########################################################
DATA_ATTRIBUTES DATA
{
	ACTIONS		Open,Print
        ICON		Dtdata
        MIME_TYPE	text/plain
        MEDIA           _DT_DATA
	DESCRIPTION	This file does not match any other data type, \
                        so it has been assigned the data type named DATA.
        TYPE_LABEL      DATA
}
DATA_CRITERIA DATA1
{
	DATA_ATTRIBUTES_NAME DATA
	MODE		f&!x
}
# ###################################################################
# ###################################################################
# 
#  Actions provided by the Common Desktop Environment File Manager.
# 
# ###################################################################
ACTION DtfileHome
{
        LABEL           	File Manager - Home
        ARG_COUNT		0
        ICON			Fphome
        TYPE            	TT_MSG
        TT_CLASS		TT_REQUEST
        TT_SCOPE		TT_SESSION
        TT_OPERATION		DtHome_Show
        DESCRIPTION     	The File Manager - Home (DtfileHome) action opens a \
                        File Manager view of the user's home folder.
}
# #####
ACTION Dtfile
{
        LABEL           	File Manager
        ICON			Fphome
        TYPE            	TT_MSG
        TT_CLASS		TT_REQUEST
        TT_SCOPE		TT_SESSION
        TT_OPERATION		Edit
        TT_FILE		   	%Arg_1"Folder to open:"%
        TT_ARG0_MODE		TT_INOUT
        TT_ARG0_VTYPE   	FILE_NAME
        DESCRIPTION     	The File Manager (Dtfile) action opens a File Manager \
                        view of the specified folder.
}
# #####
ACTION Dtappmgr
{
        LABEL           	Application Manager
        ICON			Fpapps
        TYPE            	TT_MSG
        TT_CLASS		TT_REQUEST
        TT_SCOPE		TT_SESSION
        TT_OPERATION		DtTools_Show
        TT_FILE			/var/dt/appconfig/appmanager/$DTUSERSESSION
        TT_ARG0_MODE            TT_IN
        TT_ARG0_VTYPE           -title
        TT_ARG0_REP_TYPE        TT_REP_STRING
        TT_ARG0_VALUE   	Application Manager
        TT_ARG1_MODE            TT_IN
        TT_ARG1_VTYPE           -help_volume
        TT_ARG1_REP_TYPE        TT_REP_STRING
        TT_ARG1_VALUE   	Appmanager
        DESCRIPTION     	The Application Manger (Dtappmgr) action opens a \
                        File Manager view of the the Application Manager.
}
# #####
ACTION DtEmptyTrash
{
        LABEL           Empty Trash Can
        ARG_COUNT	      0
        ICON            Dtshred
        TYPE           	TT_MSG
        TT_CLASS        TT_REQUEST
        TT_SCOPE        TT_SESSION
        TT_OPERATION    DtTrash_Empty
	DESCRIPTION     The Empty Trash Can (DtEmptyTrash) action empties the desktop Trash \
                        Can window when the action icon is double-clicked.
}
ACTION Dttrash
{
        LABEL           Trash Can
        ARG_COUNT	0
        ICON		Dttrsh
        TYPE           	TT_MSG
        TT_CLASS	TT_REQUEST
        TT_SCOPE	TT_SESSION
        TT_OPERATION	DtTrash_Show
	DESCRIPTION	The Trash Can (Dttrash) action opens the desktop Trash \
                        Can window when the action icon is double-clicked. \
                        When a file is dropped on the icon, the file is \
                        moved to the Trash Can.
}
ACTION Dttrash
{
        LABEL           	Trash Can
        ARG_COUNT		>0
        ICON			Dttrsh
        TYPE            	TT_MSG
        TT_CLASS                TT_REQUEST
        TT_SCOPE		TT_SESSION
        TT_OPERATION		DtTrash_Remove
        TT_ARG0_MODE		TT_IN
        TT_ARG0_VTYPE		string
        TT_ARG1_MODE		TT_IN
        TT_ARG1_VTYPE		string
        TT_ARG1_REP_TYPE	TT_REP_STRING
        TT_ARG1_VALUE		%Arg_1%
	DESCRIPTION		The Trash Can (Dttrash) action opens the desktop Trash \
                        Can window when the action icon is double-clicked. \
                        When a file is dropped on the icon, the file is \
                        moved to the Trash Can.
}
ACTION DtUnlink
{
        LABEL           	Trash Can
        ARG_COUNT		2
        ICON			Dttrsh
        TYPE            	TT_MSG
        TT_CLASS		TT_REQUEST
        TT_SCOPE		TT_SESSION
        TT_OPERATION		DtTrash_Remove
        TT_FILE			%Arg_1%
        TT_ARG0_MODE		TT_IN
        TT_ARG0_VTYPE   	string
        TT_ARG1_MODE		TT_IN
        TT_ARG1_VTYPE   	string
        TT_ARG1_REP_TYPE	TT_REP_STRING
	TT_ARG1_VALUE		%Arg_2%
	DESCRIPTION	The Trash Can (Dttrash) action opens the desktop Trash \
                        Can window when the action icon is double-clicked. \
                        When a file is dropped on the icon, the file is \
                        moved to the Trash Can.
}
ACTION DtUnlink
{
        LABEL           	Trash Can
        ARG_COUNT		>2
        ICON			Dttrsh
        TYPE            	TT_MSG
        TT_CLASS		TT_REQUEST
        TT_SCOPE		TT_SESSION
        TT_OPERATION		DtTrash_Remove
        TT_FILE			%Arg_1%
        TT_ARG0_MODE		TT_IN
        TT_ARG0_VTYPE   	string
        TT_ARG0_REP_TYPE	TT_REP_STRING
	TT_ARG0_VALUE		%Args%
	DESCRIPTION		The Trash Can (Dttrash) action opens the desktop Trash \
                        Can window when the action icon is double-clicked. \
                        When a file is dropped on the icon, the file is \
                        moved to the Trash Can.
}
ACTION PutOnWorkspace
{
        LABEL           	Put On Workspace
        ICON			Dtpodt
        TYPE			TT_MSG
        TT_CLASS			TT_REQUEST
        TT_SCOPE			TT_SESSION
        TT_OPERATION		DtFile_PutOnWorkspace
        TT_FILE			%Arg_3%
        TT_ARG0_MODE		TT_IN
        TT_ARG0_VTYPE   	-workspace
        TT_ARG0_REP_TYPE      	TT_REP_STRING
	TT_ARG0_VALUE		%Arg_2%
        TT_ARG2_MODE		TT_IN
        TT_ARG2_VTYPE   	string
        TT_ARG2_REP_TYPE	TT_REP_STRING
	TT_ARG2_VALUE		%Arg_3%
	DESCRIPTION		This action (DtPutOnWorkspace) will place an object on the workspace
}
# #####
ACTION FILESYSTEM_MOVE
{
        LABEL                   Move To Directory
        TYPE                    TT_MSG
        TT_CLASS                TT_REQUEST
        TT_SCOPE                TT_SESSION
        TT_OPERATION            DtFile_Move
        TT_FILE                 %Arg_1%
        TT_ARG0_MODE            TT_IN
        TT_ARG0_VTYPE           string
        TT_ARG0_REP_TYPE        TT_REP_STRING
        TT_ARG0_VALUE           %Arg_1%
        TT_ARG1_MODE            TT_IN
        TT_ARG1_VTYPE           string
        TT_ARG1_REP_TYPE        TT_REP_STRING
        TT_ARG1_VALUE           %Args%
        DESCRIPTION             The FILESYSTEM_MOVE action allows an Common                                Desktop Environment compliant application                                 to run an action to which causes the File                                 Manager to preform a move on the file(s)                                 passed in.  The format for this action is:                                 'FILESYSTEM_MOVE <folder_name_to> <files>'                                 where files is a full path name list of files                                 separated by spaces.
}
# #####
ACTION FILESYSTEM_COPY
{
        LABEL                   Copy To Directory
        TYPE                    TT_MSG
        TT_CLASS                TT_REQUEST
        TT_SCOPE                TT_SESSION
        TT_OPERATION            DtFile_Copy
        TT_FILE                 %Arg_1%
        TT_ARG0_MODE            TT_IN
        TT_ARG0_VTYPE           string
        TT_ARG0_REP_TYPE        TT_REP_STRING
        TT_ARG0_VALUE           %Arg_1%
        TT_ARG1_MODE            TT_IN
        TT_ARG1_VTYPE           string
        TT_ARG1_REP_TYPE        TT_REP_STRING
        TT_ARG1_VALUE           %Args%
        DESCRIPTION             The FILESYSTEM_COPY action allows an Common                                Desktop Environment compliant application                                 to run an action to which causes the File                                 Manager to preform a copy on the file(s)                                 passed in.  The format for this action is:                                 'FILESYSTEM_COPY <folder_name_to> <files>'                                 where files is a full path name list of files                                 separated by spaces.
}
# #####
ACTION FILESYSTEM_LINK
{
        LABEL                   Link To Directory
        TYPE                    TT_MSG
        TT_CLASS                TT_REQUEST
        TT_SCOPE                TT_SESSION
        TT_OPERATION            DtFile_Link
        TT_FILE                 %Arg_1%
        TT_ARG0_MODE            TT_IN
        TT_ARG0_VTYPE           string
        TT_ARG0_REP_TYPE        TT_REP_STRING
        TT_ARG0_VALUE           %Arg_1%
        TT_ARG1_MODE            TT_IN
        TT_ARG1_VTYPE           string
        TT_ARG1_REP_TYPE        TT_REP_STRING
        TT_ARG1_VALUE           %Args%
        DESCRIPTION             The FILESYSTEM_LINK action allows an Common                                Desktop Environment compliant application                                 to run an action to which causes the File                                 Manager to preform a link on the file(s)                                 passed in.  The format for this action is:                                 'FILESYSTEM_LINK <folder_name_to> <files>'                                 where files is a full path name list of files                                 separated by spaces.
}
# #####
ACTION OpenFolder
{
        LABEL           	Open
        TYPE            	TT_MSG
        TT_CLASS		TT_REQUEST
        TT_SCOPE		TT_SESSION
        TT_OPERATION		Edit
        TT_FILE		   	%Arg_1"Folder to open:"%
        TT_ARG0_MODE		TT_INOUT
        TT_ARG0_VTYPE   	FILE_NAME
        DESCRIPTION		The Open New View action displays a File Manager \
                        view of the specified folder in a new File \
                        Manager window.
}
# #####
ACTION OpenNewView
{
        LABEL           Open New View
        TYPE            MAP
	MAP_ACTION      Open
}
# #####
ACTION OpenInPlace
{
        LABEL           Open In Place
        TYPE            MAP
	MAP_ACTION      Open
}
# #####
ACTION PrintFolderList
{
        LABEL           PrintFolderList
        TYPE            COMMAND
        WINDOW_TYPE     NO_STDIO
        EXEC_STRING     sh -c '                         ls -aLlF "%(File)Arg_1%" |                         /usr/pkg/dt/bin/dtlp -u "%(File)Arg_1%"'
        DESCRIPTION     The PrintFolderList action prints the contents \
                        of a folder on the default printer.
}
# ######################## EOF ############################################
