Drag.pas 57 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730
  1. {
  2. File: HIToolbox/Drag.h
  3. Contains: Drag and Drop Interfaces.
  4. Version: HIToolbox-219.4.81~2
  5. Copyright: © 1992-2005 by Apple Computer, Inc., all rights reserved.
  6. Bugs?: For bug reports, consult the following page on
  7. the World Wide Web:
  8. http://www.freepascal.org/bugs.html
  9. }
  10. { Pascal Translation Updated: Peter N Lewis, <[email protected]>, August 2005 }
  11. {
  12. Modified for use with Free Pascal
  13. Version 200
  14. Please report any bugs to <[email protected]>
  15. }
  16. {$mode macpas}
  17. {$packenum 1}
  18. {$macro on}
  19. {$inline on}
  20. {$CALLING MWPASCAL}
  21. unit Drag;
  22. interface
  23. {$setc UNIVERSAL_INTERFACES_VERSION := $0342}
  24. {$setc GAP_INTERFACES_VERSION := $0200}
  25. {$ifc not defined USE_CFSTR_CONSTANT_MACROS}
  26. {$setc USE_CFSTR_CONSTANT_MACROS := TRUE}
  27. {$endc}
  28. {$ifc defined CPUPOWERPC and defined CPUI386}
  29. {$error Conflicting initial definitions for CPUPOWERPC and CPUI386}
  30. {$endc}
  31. {$ifc defined FPC_BIG_ENDIAN and defined FPC_LITTLE_ENDIAN}
  32. {$error Conflicting initial definitions for FPC_BIG_ENDIAN and FPC_LITTLE_ENDIAN}
  33. {$endc}
  34. {$ifc not defined __ppc__ and defined CPUPOWERPC}
  35. {$setc __ppc__ := 1}
  36. {$elsec}
  37. {$setc __ppc__ := 0}
  38. {$endc}
  39. {$ifc not defined __i386__ and defined CPUI386}
  40. {$setc __i386__ := 1}
  41. {$elsec}
  42. {$setc __i386__ := 0}
  43. {$endc}
  44. {$ifc defined __ppc__ and __ppc__ and defined __i386__ and __i386__}
  45. {$error Conflicting definitions for __ppc__ and __i386__}
  46. {$endc}
  47. {$ifc defined __ppc__ and __ppc__}
  48. {$setc TARGET_CPU_PPC := TRUE}
  49. {$setc TARGET_CPU_X86 := FALSE}
  50. {$elifc defined __i386__ and __i386__}
  51. {$setc TARGET_CPU_PPC := FALSE}
  52. {$setc TARGET_CPU_X86 := TRUE}
  53. {$elsec}
  54. {$error Neither __ppc__ nor __i386__ is defined.}
  55. {$endc}
  56. {$setc TARGET_CPU_PPC_64 := FALSE}
  57. {$ifc defined FPC_BIG_ENDIAN}
  58. {$setc TARGET_RT_BIG_ENDIAN := TRUE}
  59. {$setc TARGET_RT_LITTLE_ENDIAN := FALSE}
  60. {$elifc defined FPC_LITTLE_ENDIAN}
  61. {$setc TARGET_RT_BIG_ENDIAN := FALSE}
  62. {$setc TARGET_RT_LITTLE_ENDIAN := TRUE}
  63. {$elsec}
  64. {$error Neither FPC_BIG_ENDIAN nor FPC_LITTLE_ENDIAN are defined.}
  65. {$endc}
  66. {$setc ACCESSOR_CALLS_ARE_FUNCTIONS := TRUE}
  67. {$setc CALL_NOT_IN_CARBON := FALSE}
  68. {$setc OLDROUTINENAMES := FALSE}
  69. {$setc OPAQUE_TOOLBOX_STRUCTS := TRUE}
  70. {$setc OPAQUE_UPP_TYPES := TRUE}
  71. {$setc OTCARBONAPPLICATION := TRUE}
  72. {$setc OTKERNEL := FALSE}
  73. {$setc PM_USE_SESSION_APIS := TRUE}
  74. {$setc TARGET_API_MAC_CARBON := TRUE}
  75. {$setc TARGET_API_MAC_OS8 := FALSE}
  76. {$setc TARGET_API_MAC_OSX := TRUE}
  77. {$setc TARGET_CARBON := TRUE}
  78. {$setc TARGET_CPU_68K := FALSE}
  79. {$setc TARGET_CPU_MIPS := FALSE}
  80. {$setc TARGET_CPU_SPARC := FALSE}
  81. {$setc TARGET_OS_MAC := TRUE}
  82. {$setc TARGET_OS_UNIX := FALSE}
  83. {$setc TARGET_OS_WIN32 := FALSE}
  84. {$setc TARGET_RT_MAC_68881 := FALSE}
  85. {$setc TARGET_RT_MAC_CFM := FALSE}
  86. {$setc TARGET_RT_MAC_MACHO := TRUE}
  87. {$setc TYPED_FUNCTION_POINTERS := TRUE}
  88. {$setc TYPE_BOOL := FALSE}
  89. {$setc TYPE_EXTENDED := FALSE}
  90. {$setc TYPE_LONGLONG := TRUE}
  91. uses MacTypes,AEDataModel,CGImage,CGGeometry,Events,Files,AppleEvents,Quickdraw,Pasteboard,HIGeometry;
  92. {$ALIGN MAC68K}
  93. {
  94. _________________________________________________________________________________________________________
  95. ¥ DRAG MANAGER DATA TYPES
  96. _________________________________________________________________________________________________________
  97. }
  98. type
  99. DragRef = ^SInt32; { an opaque 32-bit type }
  100. DragRefPtr = ^DragRef; { when a var xx:DragRef parameter can be nil, it is changed to xx: DragRefPtr }
  101. type
  102. DragItemRef = UInt32;
  103. type
  104. FlavorType = OSType;
  105. {
  106. _________________________________________________________________________________________________________
  107. ¥ DRAG ATTRIBUTES
  108. _________________________________________________________________________________________________________
  109. }
  110. type
  111. DragAttributes = UInt32;
  112. const
  113. kDragHasLeftSenderWindow = 1 shl 0; { drag has left the source window since TrackDrag}
  114. kDragInsideSenderApplication = 1 shl 1; { drag is occurring within the sender application}
  115. kDragInsideSenderWindow = 1 shl 2; { drag is occurring within the sender window}
  116. {
  117. _________________________________________________________________________________________________________
  118. ¥ DRAG BEHAVIORS
  119. _________________________________________________________________________________________________________
  120. }
  121. type
  122. DragBehaviors = UInt32;
  123. const
  124. kDragBehaviorNone = 0;
  125. kDragBehaviorZoomBackAnimation = 1 shl 0; { do zoomback animation for failed drags (normally enabled).}
  126. {
  127. _________________________________________________________________________________________________________
  128. ¥ DRAG IMAGE FLAGS
  129. _________________________________________________________________________________________________________
  130. }
  131. {
  132. * DragImageFlags
  133. *
  134. * Summary:
  135. * Parameters to SetDragImage and SetDragImageWithCGImage.
  136. }
  137. type
  138. DragImageFlags = UInt32;
  139. const
  140. {
  141. * Indicates that the outline region passed to TrackDrag should be
  142. * drawn onscreen, in addition to the translucent drag image.
  143. }
  144. kDragRegionAndImage = 1 shl 4;
  145. {
  146. * Indicates that the image and offset being passed in are already at
  147. * device resolution, and the image should be drawn as-is. If this
  148. * option is not specified, the image will be scaled according to the
  149. * user's current scaling factor. Available in Mac OS X 10.4 and
  150. * later.
  151. }
  152. kDragDoNotScaleImage = 1 shl 5;
  153. {
  154. _________________________________________________________________________________________________________
  155. ¥ DRAG IMAGE TRANSLUCENCY LEVELS
  156. _________________________________________________________________________________________________________
  157. }
  158. const
  159. kDragStandardTranslucency = 0; { 65% image translucency (standard)}
  160. kDragDarkTranslucency = 1; { 50% image translucency}
  161. kDragDarkerTranslucency = 2; { 25% image translucency}
  162. kDragOpaqueTranslucency = 3; { 0% image translucency (opaque)}
  163. {
  164. _________________________________________________________________________________________________________
  165. ¥ DRAG DRAWING PROCEDURE MESSAGES
  166. _________________________________________________________________________________________________________
  167. }
  168. type
  169. DragRegionMessage = SInt16;
  170. const
  171. kDragRegionBegin = 1; { initialize drawing}
  172. kDragRegionDraw = 2; { draw drag feedback}
  173. kDragRegionHide = 3; { hide drag feedback}
  174. kDragRegionIdle = 4; { drag feedback idle time}
  175. kDragRegionEnd = 5; { end of drawing}
  176. {
  177. _________________________________________________________________________________________________________
  178. ¥ ZOOM ACCELERATION
  179. _________________________________________________________________________________________________________
  180. }
  181. type
  182. ZoomAcceleration = SInt16;
  183. const
  184. kZoomNoAcceleration = 0; { use linear interpolation}
  185. kZoomAccelerate = 1; { ramp up step size}
  186. kZoomDecelerate = 2; { ramp down step size}
  187. {
  188. _________________________________________________________________________________________________________
  189. ¥ FLAVOR FLAGS
  190. _________________________________________________________________________________________________________
  191. }
  192. type
  193. FlavorFlags = UInt32;
  194. const
  195. flavorSenderOnly = 1 shl 0; { flavor is available to sender only}
  196. flavorSenderTranslated = 1 shl 1; { flavor is translated by sender}
  197. flavorNotSaved = 1 shl 2; { flavor should not be saved}
  198. flavorSystemTranslated = 1 shl 8; { flavor is translated by system}
  199. flavorDataPromised = 1 shl 9; { flavor data is promised by sender}
  200. {
  201. _________________________________________________________________________________________________________
  202. ¥ FILE SYSTEM CONSTANTS
  203. _________________________________________________________________________________________________________
  204. }
  205. const
  206. kDragFlavorTypeHFS = $68667320 (* 'hfs ' *); { flavor type for HFS data}
  207. kDragFlavorTypePromiseHFS = $70686673 (* 'phfs' *); { flavor type for promised HFS data}
  208. flavorTypeHFS = kDragFlavorTypeHFS; { old name}
  209. flavorTypePromiseHFS = kDragFlavorTypePromiseHFS; { old name}
  210. const
  211. kDragPromisedFlavorFindFile = $72576D31 (* 'rWm1' *); { promisedFlavor value for Find File}
  212. kDragPromisedFlavor = $66737350 (* 'fssP' *); { promisedFlavor value for everything else}
  213. const
  214. kDragPseudoCreatorVolumeOrDirectory = $4D414353 (* 'MACS' *); { "creator code" for volume or directory}
  215. kDragPseudoFileTypeVolume = $6469736B (* 'disk' *); { "file type" for volume}
  216. kDragPseudoFileTypeDirectory = $666F6C64 (* 'fold' *); { "file type" for directory}
  217. {
  218. _________________________________________________________________________________________________________
  219. ¥ SPECIAL FLAVORS
  220. _________________________________________________________________________________________________________
  221. }
  222. const
  223. flavorTypeDirectory = $64697279 (* 'diry' *); { flavor type for AOCE directories}
  224. {
  225. _________________________________________________________________________________________________________
  226. ¥ FLAVORS FOR FINDER 8.0 AND LATER
  227. _________________________________________________________________________________________________________
  228. }
  229. const
  230. kFlavorTypeClippingName = $636C6E6D (* 'clnm' *); { name hint for clipping file (preferred over 'clfn')}
  231. kFlavorTypeClippingFilename = $636C666E (* 'clfn' *); { name for clipping file}
  232. kFlavorTypeUnicodeClippingName = $75636C6E (* 'ucln' *); { unicode name hint for clipping file (preferred over 'uclf')}
  233. kFlavorTypeUnicodeClippingFilename = $75636C66 (* 'uclf' *); { unicode name for clipping file}
  234. kFlavorTypeDragToTrashOnly = $66647474 (* 'fdtt' *); { for apps that want to allow dragging private data to the trash}
  235. kFlavorTypeFinderNoTrackingBehavior = $666E7462 (* 'fntb' *); { Finder completely ignores any drag containing this flavor}
  236. {
  237. _________________________________________________________________________________________________________
  238. ¥ DRAG TRACKING HANDLER MESSAGES
  239. _________________________________________________________________________________________________________
  240. }
  241. type
  242. DragTrackingMessage = SInt16;
  243. const
  244. kDragTrackingEnterHandler = 1; { drag has entered handler}
  245. kDragTrackingEnterWindow = 2; { drag has entered window}
  246. kDragTrackingInWindow = 3; { drag is moving within window}
  247. kDragTrackingLeaveWindow = 4; { drag has exited window}
  248. kDragTrackingLeaveHandler = 5; { drag has exited handler}
  249. {
  250. ÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑ
  251. ¥ STANDARD DROP LOCATIONS
  252. ÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑ
  253. }
  254. {
  255. * Summary:
  256. * Standard Drop Location constants
  257. *
  258. * Discussion:
  259. * The following constants define common "meta" drop locations.
  260. }
  261. const
  262. {
  263. * The drop location was in the trash. This is set when a drag is
  264. * dropped on the trash icon. Setting this standard drop location
  265. * sets the traditional drop location to an alias to the trash folder
  266. * automatically.
  267. }
  268. kDragStandardDropLocationTrash = $74727368 (* 'trsh' *);
  269. {
  270. * The receiver did not specify a drop lcoation. This is the default.
  271. }
  272. kDragStandardDropLocationUnknown = $756E6B6E (* 'unkn' *);
  273. type
  274. StandardDropLocation = OSType;
  275. {
  276. _________________________________________________________________________________________________________
  277. ¥ DRAG ACTIONS
  278. _________________________________________________________________________________________________________
  279. }
  280. {
  281. * Summary:
  282. * Drag Action constants
  283. *
  284. * Discussion:
  285. * The following constants define, in a general way, what actions a
  286. * drag should or has performed. Some drag actions enforce a mode
  287. * of operation while others are flexible suggestions. These
  288. * constants are used in conjunction with the
  289. * Get/SetDragAllowableActions() and Get/SetDragDropAction() APIs.
  290. * Adopting the Drag Action APIs increases compatability with the
  291. * Cocoa drag operation model.
  292. }
  293. const
  294. {
  295. * Suggests nothing should be/was done with the data in a drag. When
  296. * set as an allowable action for remote drags, the drag will not be
  297. * sent to apps other than the sender.
  298. }
  299. kDragActionNothing = 0;
  300. {
  301. * Suggests the data contained within the drag can be/was copied.
  302. }
  303. kDragActionCopy = 1;
  304. {
  305. * Suggests the data contained within the drag can be/is shared.
  306. }
  307. kDragActionAlias = 1 shl 1;
  308. {
  309. * Suggests the drag action is can be defined by the drag destination
  310. * or was not defined by the drag destination.
  311. }
  312. kDragActionGeneric = 1 shl 2;
  313. {
  314. * Suggests the drag action should be negotiated privately between
  315. * the drag source and destination.
  316. }
  317. kDragActionPrivate = 1 shl 3;
  318. {
  319. * Description forthcoming.
  320. }
  321. kDragActionMove = 1 shl 4;
  322. {
  323. * Description forthcoming.
  324. }
  325. kDragActionDelete = 1 shl 5;
  326. {
  327. * All of the above drag actions are allowed.
  328. }
  329. kDragActionAll = $FFFFFFFF;
  330. type
  331. DragActions = UInt32;
  332. {
  333. _________________________________________________________________________________________________________
  334. ¥ HFS FLAVORS
  335. _________________________________________________________________________________________________________
  336. }
  337. type
  338. HFSFlavorPtr = ^HFSFlavor;
  339. HFSFlavor = record
  340. fileType: OSType; { file type }
  341. fileCreator: OSType; { file creator }
  342. fdFlags: UInt16; { Finder flags }
  343. fileSpec: FSSpec; { file system specification }
  344. end;
  345. type
  346. PromiseHFSFlavorPtr = ^PromiseHFSFlavor;
  347. PromiseHFSFlavor = record
  348. fileType: OSType; { file type }
  349. fileCreator: OSType; { file creator }
  350. fdFlags: UInt16; { Finder flags }
  351. promisedFlavor: FlavorType; { promised flavor containing an FSSpec }
  352. end;
  353. {
  354. _________________________________________________________________________________________________________
  355. ¥ APPLICATION-DEFINED DRAG HANDLER ROUTINES
  356. _________________________________________________________________________________________________________
  357. }
  358. type
  359. DragTrackingHandlerProcPtr = function( message: DragTrackingMessage; theWindow: WindowRef; handlerRefCon: UnivPtr; theDrag: DragRef ): OSErr;
  360. type
  361. DragReceiveHandlerProcPtr = function( theWindow: WindowRef; handlerRefCon: UnivPtr; theDrag: DragRef ): OSErr;
  362. type
  363. DragTrackingHandlerUPP = DragTrackingHandlerProcPtr;
  364. type
  365. DragReceiveHandlerUPP = DragReceiveHandlerProcPtr;
  366. {
  367. * NewDragTrackingHandlerUPP()
  368. *
  369. * Availability:
  370. * Mac OS X: in version 10.0 and later in Carbon.framework
  371. * CarbonLib: in CarbonLib 1.0 and later
  372. * Non-Carbon CFM: available as macro/inline
  373. }
  374. function NewDragTrackingHandlerUPP( userRoutine: DragTrackingHandlerProcPtr ): DragTrackingHandlerUPP; external name '_NewDragTrackingHandlerUPP';
  375. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  376. {
  377. * NewDragReceiveHandlerUPP()
  378. *
  379. * Availability:
  380. * Mac OS X: in version 10.0 and later in Carbon.framework
  381. * CarbonLib: in CarbonLib 1.0 and later
  382. * Non-Carbon CFM: available as macro/inline
  383. }
  384. function NewDragReceiveHandlerUPP( userRoutine: DragReceiveHandlerProcPtr ): DragReceiveHandlerUPP; external name '_NewDragReceiveHandlerUPP';
  385. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  386. {
  387. * DisposeDragTrackingHandlerUPP()
  388. *
  389. * Availability:
  390. * Mac OS X: in version 10.0 and later in Carbon.framework
  391. * CarbonLib: in CarbonLib 1.0 and later
  392. * Non-Carbon CFM: available as macro/inline
  393. }
  394. procedure DisposeDragTrackingHandlerUPP( userUPP: DragTrackingHandlerUPP ); external name '_DisposeDragTrackingHandlerUPP';
  395. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  396. {
  397. * DisposeDragReceiveHandlerUPP()
  398. *
  399. * Availability:
  400. * Mac OS X: in version 10.0 and later in Carbon.framework
  401. * CarbonLib: in CarbonLib 1.0 and later
  402. * Non-Carbon CFM: available as macro/inline
  403. }
  404. procedure DisposeDragReceiveHandlerUPP( userUPP: DragReceiveHandlerUPP ); external name '_DisposeDragReceiveHandlerUPP';
  405. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  406. {
  407. * InvokeDragTrackingHandlerUPP()
  408. *
  409. * Availability:
  410. * Mac OS X: in version 10.0 and later in Carbon.framework
  411. * CarbonLib: in CarbonLib 1.0 and later
  412. * Non-Carbon CFM: available as macro/inline
  413. }
  414. function InvokeDragTrackingHandlerUPP( message: DragTrackingMessage; theWindow: WindowRef; handlerRefCon: UnivPtr; theDrag: DragRef; userUPP: DragTrackingHandlerUPP ): OSErr; external name '_InvokeDragTrackingHandlerUPP';
  415. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  416. {
  417. * InvokeDragReceiveHandlerUPP()
  418. *
  419. * Availability:
  420. * Mac OS X: in version 10.0 and later in Carbon.framework
  421. * CarbonLib: in CarbonLib 1.0 and later
  422. * Non-Carbon CFM: available as macro/inline
  423. }
  424. function InvokeDragReceiveHandlerUPP( theWindow: WindowRef; handlerRefCon: UnivPtr; theDrag: DragRef; userUPP: DragReceiveHandlerUPP ): OSErr; external name '_InvokeDragReceiveHandlerUPP';
  425. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  426. {
  427. _________________________________________________________________________________________________________
  428. ¥ APPLICATION-DEFINED ROUTINES
  429. _________________________________________________________________________________________________________
  430. }
  431. type
  432. DragSendDataProcPtr = function( theType: FlavorType; dragSendRefCon: UnivPtr; theItemRef: DragItemRef; theDrag: DragRef ): OSErr;
  433. type
  434. DragInputProcPtr = function( var mouse: Point; var modifiers: SInt16; dragInputRefCon: UnivPtr; theDrag: DragRef ): OSErr;
  435. type
  436. DragDrawingProcPtr = function( message: DragRegionMessage; showRegion: RgnHandle; showOrigin: Point; hideRegion: RgnHandle; hideOrigin: Point; dragDrawingRefCon: UnivPtr; theDrag: DragRef ): OSErr;
  437. type
  438. DragSendDataUPP = DragSendDataProcPtr;
  439. type
  440. DragInputUPP = DragInputProcPtr;
  441. type
  442. DragDrawingUPP = DragDrawingProcPtr;
  443. {
  444. * NewDragSendDataUPP()
  445. *
  446. * Availability:
  447. * Mac OS X: in version 10.0 and later in Carbon.framework
  448. * CarbonLib: in CarbonLib 1.0 and later
  449. * Non-Carbon CFM: available as macro/inline
  450. }
  451. function NewDragSendDataUPP( userRoutine: DragSendDataProcPtr ): DragSendDataUPP; external name '_NewDragSendDataUPP';
  452. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  453. {
  454. * NewDragInputUPP()
  455. *
  456. * Availability:
  457. * Mac OS X: in version 10.0 and later in Carbon.framework
  458. * CarbonLib: in CarbonLib 1.0 and later
  459. * Non-Carbon CFM: available as macro/inline
  460. }
  461. function NewDragInputUPP( userRoutine: DragInputProcPtr ): DragInputUPP; external name '_NewDragInputUPP';
  462. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  463. {
  464. * NewDragDrawingUPP()
  465. *
  466. * Availability:
  467. * Mac OS X: in version 10.0 and later in Carbon.framework
  468. * CarbonLib: in CarbonLib 1.0 and later
  469. * Non-Carbon CFM: available as macro/inline
  470. }
  471. function NewDragDrawingUPP( userRoutine: DragDrawingProcPtr ): DragDrawingUPP; external name '_NewDragDrawingUPP';
  472. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  473. {
  474. * DisposeDragSendDataUPP()
  475. *
  476. * Availability:
  477. * Mac OS X: in version 10.0 and later in Carbon.framework
  478. * CarbonLib: in CarbonLib 1.0 and later
  479. * Non-Carbon CFM: available as macro/inline
  480. }
  481. procedure DisposeDragSendDataUPP( userUPP: DragSendDataUPP ); external name '_DisposeDragSendDataUPP';
  482. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  483. {
  484. * DisposeDragInputUPP()
  485. *
  486. * Availability:
  487. * Mac OS X: in version 10.0 and later in Carbon.framework
  488. * CarbonLib: in CarbonLib 1.0 and later
  489. * Non-Carbon CFM: available as macro/inline
  490. }
  491. procedure DisposeDragInputUPP( userUPP: DragInputUPP ); external name '_DisposeDragInputUPP';
  492. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  493. {
  494. * DisposeDragDrawingUPP()
  495. *
  496. * Availability:
  497. * Mac OS X: in version 10.0 and later in Carbon.framework
  498. * CarbonLib: in CarbonLib 1.0 and later
  499. * Non-Carbon CFM: available as macro/inline
  500. }
  501. procedure DisposeDragDrawingUPP( userUPP: DragDrawingUPP ); external name '_DisposeDragDrawingUPP';
  502. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  503. {
  504. * InvokeDragSendDataUPP()
  505. *
  506. * Availability:
  507. * Mac OS X: in version 10.0 and later in Carbon.framework
  508. * CarbonLib: in CarbonLib 1.0 and later
  509. * Non-Carbon CFM: available as macro/inline
  510. }
  511. function InvokeDragSendDataUPP( theType: FlavorType; dragSendRefCon: UnivPtr; theItemRef: DragItemRef; theDrag: DragRef; userUPP: DragSendDataUPP ): OSErr; external name '_InvokeDragSendDataUPP';
  512. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  513. {
  514. * InvokeDragInputUPP()
  515. *
  516. * Availability:
  517. * Mac OS X: in version 10.0 and later in Carbon.framework
  518. * CarbonLib: in CarbonLib 1.0 and later
  519. * Non-Carbon CFM: available as macro/inline
  520. }
  521. function InvokeDragInputUPP( var mouse: Point; var modifiers: SInt16; dragInputRefCon: UnivPtr; theDrag: DragRef; userUPP: DragInputUPP ): OSErr; external name '_InvokeDragInputUPP';
  522. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  523. {
  524. * InvokeDragDrawingUPP()
  525. *
  526. * Availability:
  527. * Mac OS X: in version 10.0 and later in Carbon.framework
  528. * CarbonLib: in CarbonLib 1.0 and later
  529. * Non-Carbon CFM: available as macro/inline
  530. }
  531. function InvokeDragDrawingUPP( message: DragRegionMessage; showRegion: RgnHandle; showOrigin: Point; hideRegion: RgnHandle; hideOrigin: Point; dragDrawingRefCon: UnivPtr; theDrag: DragRef; userUPP: DragDrawingUPP ): OSErr; external name '_InvokeDragDrawingUPP';
  532. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  533. {
  534. _________________________________________________________________________________________________________
  535. ¥ INSTALLING AND REMOVING HANDLERS API'S
  536. _________________________________________________________________________________________________________
  537. }
  538. {
  539. * InstallTrackingHandler()
  540. *
  541. * Mac OS X threading:
  542. * Not thread safe
  543. *
  544. * Availability:
  545. * Mac OS X: in version 10.0 and later in Carbon.framework
  546. * CarbonLib: in CarbonLib 1.0 and later
  547. * Non-Carbon CFM: in DragLib 1.1 and later
  548. }
  549. function InstallTrackingHandler( trackingHandler: DragTrackingHandlerUPP; theWindow: WindowRef; handlerRefCon: UnivPtr ): OSErr; external name '_InstallTrackingHandler';
  550. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  551. {
  552. * InstallReceiveHandler()
  553. *
  554. * Mac OS X threading:
  555. * Not thread safe
  556. *
  557. * Availability:
  558. * Mac OS X: in version 10.0 and later in Carbon.framework
  559. * CarbonLib: in CarbonLib 1.0 and later
  560. * Non-Carbon CFM: in DragLib 1.1 and later
  561. }
  562. function InstallReceiveHandler( receiveHandler: DragReceiveHandlerUPP; theWindow: WindowRef; handlerRefCon: UnivPtr ): OSErr; external name '_InstallReceiveHandler';
  563. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  564. {
  565. * RemoveTrackingHandler()
  566. *
  567. * Mac OS X threading:
  568. * Not thread safe
  569. *
  570. * Availability:
  571. * Mac OS X: in version 10.0 and later in Carbon.framework
  572. * CarbonLib: in CarbonLib 1.0 and later
  573. * Non-Carbon CFM: in DragLib 1.1 and later
  574. }
  575. function RemoveTrackingHandler( trackingHandler: DragTrackingHandlerUPP; theWindow: WindowRef ): OSErr; external name '_RemoveTrackingHandler';
  576. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  577. {
  578. * RemoveReceiveHandler()
  579. *
  580. * Mac OS X threading:
  581. * Not thread safe
  582. *
  583. * Availability:
  584. * Mac OS X: in version 10.0 and later in Carbon.framework
  585. * CarbonLib: in CarbonLib 1.0 and later
  586. * Non-Carbon CFM: in DragLib 1.1 and later
  587. }
  588. function RemoveReceiveHandler( receiveHandler: DragReceiveHandlerUPP; theWindow: WindowRef ): OSErr; external name '_RemoveReceiveHandler';
  589. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  590. {
  591. _________________________________________________________________________________________________________
  592. ¥ CREATING & DISPOSING
  593. _________________________________________________________________________________________________________
  594. }
  595. {
  596. * NewDrag()
  597. *
  598. * Mac OS X threading:
  599. * Not thread safe
  600. *
  601. * Availability:
  602. * Mac OS X: in version 10.0 and later in Carbon.framework
  603. * CarbonLib: in CarbonLib 1.0 and later
  604. * Non-Carbon CFM: in DragLib 1.1 and later
  605. }
  606. function NewDrag( var theDrag: DragRef ): OSErr; external name '_NewDrag';
  607. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  608. {
  609. * DisposeDrag()
  610. *
  611. * Mac OS X threading:
  612. * Not thread safe
  613. *
  614. * Availability:
  615. * Mac OS X: in version 10.0 and later in Carbon.framework
  616. * CarbonLib: in CarbonLib 1.0 and later
  617. * Non-Carbon CFM: in DragLib 1.1 and later
  618. }
  619. function DisposeDrag( theDrag: DragRef ): OSErr; external name '_DisposeDrag';
  620. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  621. {
  622. _________________________________________________________________________________________________________
  623. ¥ DRAG PASTEBOARD
  624. _________________________________________________________________________________________________________
  625. }
  626. {
  627. * NewDragWithPasteboard()
  628. *
  629. * Discussion:
  630. * Creates a new Drag reference containing the pasteboard reference
  631. * provided.
  632. *
  633. * Mac OS X threading:
  634. * Not thread safe
  635. *
  636. * Parameters:
  637. *
  638. * inPasteboard:
  639. * A pasteboard created by the drag sender for use with the drag.
  640. * Items may be added to the pasteboard via the Pasteboard Manager
  641. * API either before or after this routine is called. It is still
  642. * possible to add data via the Drag Manager API, but only after
  643. * this routine is called. It is the drag sender's responsibility
  644. * to clear the pasteboard before adding items. It is also the
  645. * drag sender's responsibility to release the pasteboard. This
  646. * may be done at any time after this routine is called. The
  647. * pasteboard is retained by the Drag Manager for the duration of
  648. * the drag.
  649. *
  650. * outDrag:
  651. * A drag reference which receives the newly created drag.
  652. *
  653. * Result:
  654. * An operating system result code.
  655. *
  656. * Availability:
  657. * Mac OS X: in version 10.3 and later in Carbon.framework
  658. * CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
  659. * Non-Carbon CFM: not available
  660. }
  661. function NewDragWithPasteboard( inPasteboard: PasteboardRef; var outDrag: DragRef ): OSStatus; external name '_NewDragWithPasteboard';
  662. (* AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER *)
  663. {
  664. * GetDragPasteboard()
  665. *
  666. * Discussion:
  667. * Returns the pasteboard reference contained within the provided
  668. * drag reference. This routine may be called by a drag sender or
  669. * receiver at any point after a valid drag reference has been
  670. * created/received.
  671. *
  672. * Mac OS X threading:
  673. * Not thread safe
  674. *
  675. * Parameters:
  676. *
  677. * inDrag:
  678. * The drag reference containing the requested pasteboard.
  679. *
  680. * outPasteboard:
  681. * A pasteboard reference which receives the pasteboard contained
  682. * by the drag.
  683. *
  684. * Result:
  685. * An operating system result code.
  686. *
  687. * Availability:
  688. * Mac OS X: in version 10.3 and later in Carbon.framework
  689. * CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.3 and later
  690. * Non-Carbon CFM: not available
  691. }
  692. function GetDragPasteboard( inDrag: DragRef; var outPasteboard: PasteboardRef ): OSStatus; external name '_GetDragPasteboard';
  693. (* AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER *)
  694. {
  695. _________________________________________________________________________________________________________
  696. ¥ ADDING DRAG ITEM FLAVORS
  697. _________________________________________________________________________________________________________
  698. }
  699. {
  700. The method for setting Drag Manager promises differs from that for Scrap Manger promises. This chart
  701. describes the method for setting drag promises via AddDragItemFlavor().
  702. dataPtr dataSize result
  703. pointer value actual data size The data of size dataSize pointed to by dataPtr is added to the drag.
  704. NULL ignored A promise is placed on the drag.
  705. }
  706. {
  707. * AddDragItemFlavor()
  708. *
  709. * Mac OS X threading:
  710. * Not thread safe
  711. *
  712. * Availability:
  713. * Mac OS X: in version 10.0 and later in Carbon.framework
  714. * CarbonLib: in CarbonLib 1.0 and later
  715. * Non-Carbon CFM: in DragLib 1.1 and later
  716. }
  717. function AddDragItemFlavor( theDrag: DragRef; theItemRef: DragItemRef; theType: FlavorType; dataPtr: {const} UnivPtr; dataSize: Size; theFlags: FlavorFlags ): OSErr; external name '_AddDragItemFlavor';
  718. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  719. {
  720. * SetDragItemFlavorData()
  721. *
  722. * Mac OS X threading:
  723. * Not thread safe
  724. *
  725. * Availability:
  726. * Mac OS X: in version 10.0 and later in Carbon.framework
  727. * CarbonLib: in CarbonLib 1.0 and later
  728. * Non-Carbon CFM: in DragLib 1.1 and later
  729. }
  730. function SetDragItemFlavorData( theDrag: DragRef; theItemRef: DragItemRef; theType: FlavorType; dataPtr: {const} UnivPtr; dataSize: Size; dataOffset: UInt32 ): OSErr; external name '_SetDragItemFlavorData';
  731. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  732. {
  733. _________________________________________________________________________________________________________
  734. ¥ PROVIDING CALLBACK PROCEDURES
  735. _________________________________________________________________________________________________________
  736. }
  737. {
  738. * SetDragSendProc()
  739. *
  740. * Mac OS X threading:
  741. * Not thread safe
  742. *
  743. * Availability:
  744. * Mac OS X: in version 10.0 and later in Carbon.framework
  745. * CarbonLib: in CarbonLib 1.0 and later
  746. * Non-Carbon CFM: in DragLib 1.1 and later
  747. }
  748. function SetDragSendProc( theDrag: DragRef; sendProc: DragSendDataUPP; dragSendRefCon: UnivPtr ): OSErr; external name '_SetDragSendProc';
  749. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  750. {
  751. * SetDragInputProc()
  752. *
  753. * Mac OS X threading:
  754. * Not thread safe
  755. *
  756. * Availability:
  757. * Mac OS X: in version 10.0 and later in Carbon.framework
  758. * CarbonLib: in CarbonLib 1.0 and later
  759. * Non-Carbon CFM: in DragLib 1.1 and later
  760. }
  761. function SetDragInputProc( theDrag: DragRef; inputProc: DragInputUPP; dragInputRefCon: UnivPtr ): OSErr; external name '_SetDragInputProc';
  762. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  763. {
  764. * SetDragDrawingProc()
  765. *
  766. * Mac OS X threading:
  767. * Not thread safe
  768. *
  769. * Availability:
  770. * Mac OS X: in version 10.0 and later in Carbon.framework
  771. * CarbonLib: in CarbonLib 1.0 and later
  772. * Non-Carbon CFM: in DragLib 1.1 and later
  773. }
  774. function SetDragDrawingProc( theDrag: DragRef; drawingProc: DragDrawingUPP; dragDrawingRefCon: UnivPtr ): OSErr; external name '_SetDragDrawingProc';
  775. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  776. {
  777. _________________________________________________________________________________________________________
  778. ¥ SETTING THE DRAG IMAGE
  779. _________________________________________________________________________________________________________
  780. }
  781. {
  782. * SetDragImageWithCGImage()
  783. *
  784. * Discussion:
  785. * Used by the sender of the drag to set the image, in CGImage
  786. * format, to be displayed as user feedback during the drag. This
  787. * API may be called at any point during the drag to update the
  788. * image.
  789. *
  790. * Mac OS X threading:
  791. * Not thread safe
  792. *
  793. * Parameters:
  794. *
  795. * inDrag:
  796. * The drag reference for which the image will be displayed.
  797. *
  798. * inCGImage:
  799. * The CGImageRef for the image to be displayed during the drag.
  800. * The image is retained internally by the Drag Manager for the
  801. * duration of the drag so it may be released by the client
  802. * immediately after setting.
  803. *
  804. * inImageOffsetPt:
  805. * A pointer to the offset from the mouse to the upper left of the
  806. * image (normally expressed in negative values). This differs
  807. * from the usage of the offset passed to SetDragImage(). Here,
  808. * an offset of ( -30, -30 ) will center a 60x60 pixel image on
  809. * the drag mouse.
  810. *
  811. * inImageFlags:
  812. * The flags determining image drawing during the drag.
  813. *
  814. * Result:
  815. * An operating system result code.
  816. *
  817. * Availability:
  818. * Mac OS X: in version 10.2 and later in Carbon.framework
  819. * CarbonLib: not available in CarbonLib 1.x
  820. * Non-Carbon CFM: not available
  821. }
  822. function SetDragImageWithCGImage( inDrag: DragRef; inCGImage: CGImageRef; const (*var*) inImageOffsetPt: HIPoint; inImageFlags: DragImageFlags ): OSStatus; external name '_SetDragImageWithCGImage';
  823. (* AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER *)
  824. {
  825. _________________________________________________________________________________________________________
  826. ¥ ALTERING THE BEHAVIOR OF A DRAG
  827. _________________________________________________________________________________________________________
  828. }
  829. {
  830. * ChangeDragBehaviors()
  831. *
  832. * Mac OS X threading:
  833. * Not thread safe
  834. *
  835. * Availability:
  836. * Mac OS X: in version 10.0 and later in Carbon.framework
  837. * CarbonLib: in CarbonLib 1.0 and later
  838. * Non-Carbon CFM: in DragLib 9.0 and later
  839. }
  840. function ChangeDragBehaviors( theDrag: DragRef; inBehaviorsToSet: DragBehaviors; inBehaviorsToClear: DragBehaviors ): OSErr; external name '_ChangeDragBehaviors';
  841. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  842. {
  843. _________________________________________________________________________________________________________
  844. ¥ PERFORMING A DRAG
  845. _________________________________________________________________________________________________________
  846. }
  847. {
  848. * TrackDrag()
  849. *
  850. * Mac OS X threading:
  851. * Not thread safe
  852. *
  853. * Availability:
  854. * Mac OS X: in version 10.0 and later in Carbon.framework
  855. * CarbonLib: in CarbonLib 1.0 and later
  856. * Non-Carbon CFM: in DragLib 1.1 and later
  857. }
  858. function TrackDrag( theDrag: DragRef; const (*var*) theEvent: EventRecord; theRegion: RgnHandle ): OSErr; external name '_TrackDrag';
  859. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  860. {
  861. _________________________________________________________________________________________________________
  862. ¥ GETTING DRAG ITEM INFORMATION
  863. _________________________________________________________________________________________________________
  864. }
  865. {
  866. * CountDragItems()
  867. *
  868. * Mac OS X threading:
  869. * Not thread safe
  870. *
  871. * Availability:
  872. * Mac OS X: in version 10.0 and later in Carbon.framework
  873. * CarbonLib: in CarbonLib 1.0 and later
  874. * Non-Carbon CFM: in DragLib 1.1 and later
  875. }
  876. function CountDragItems( theDrag: DragRef; var numItems: UInt16 ): OSErr; external name '_CountDragItems';
  877. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  878. {
  879. * GetDragItemReferenceNumber()
  880. *
  881. * Mac OS X threading:
  882. * Not thread safe
  883. *
  884. * Availability:
  885. * Mac OS X: in version 10.0 and later in Carbon.framework
  886. * CarbonLib: in CarbonLib 1.0 and later
  887. * Non-Carbon CFM: in DragLib 1.1 and later
  888. }
  889. function GetDragItemReferenceNumber( theDrag: DragRef; index: UInt16; var theItemRef: DragItemRef ): OSErr; external name '_GetDragItemReferenceNumber';
  890. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  891. {
  892. * CountDragItemFlavors()
  893. *
  894. * Mac OS X threading:
  895. * Not thread safe
  896. *
  897. * Availability:
  898. * Mac OS X: in version 10.0 and later in Carbon.framework
  899. * CarbonLib: in CarbonLib 1.0 and later
  900. * Non-Carbon CFM: in DragLib 1.1 and later
  901. }
  902. function CountDragItemFlavors( theDrag: DragRef; theItemRef: DragItemRef; var numFlavors: UInt16 ): OSErr; external name '_CountDragItemFlavors';
  903. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  904. {
  905. * GetFlavorType()
  906. *
  907. * Mac OS X threading:
  908. * Not thread safe
  909. *
  910. * Availability:
  911. * Mac OS X: in version 10.0 and later in Carbon.framework
  912. * CarbonLib: in CarbonLib 1.0 and later
  913. * Non-Carbon CFM: in DragLib 1.1 and later
  914. }
  915. function GetFlavorType( theDrag: DragRef; theItemRef: DragItemRef; index: UInt16; var theType: FlavorType ): OSErr; external name '_GetFlavorType';
  916. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  917. {
  918. * GetFlavorFlags()
  919. *
  920. * Mac OS X threading:
  921. * Not thread safe
  922. *
  923. * Availability:
  924. * Mac OS X: in version 10.0 and later in Carbon.framework
  925. * CarbonLib: in CarbonLib 1.0 and later
  926. * Non-Carbon CFM: in DragLib 1.1 and later
  927. }
  928. function GetFlavorFlags( theDrag: DragRef; theItemRef: DragItemRef; theType: FlavorType; var theFlags: FlavorFlags ): OSErr; external name '_GetFlavorFlags';
  929. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  930. {
  931. * GetFlavorDataSize()
  932. *
  933. * Mac OS X threading:
  934. * Not thread safe
  935. *
  936. * Availability:
  937. * Mac OS X: in version 10.0 and later in Carbon.framework
  938. * CarbonLib: in CarbonLib 1.0 and later
  939. * Non-Carbon CFM: in DragLib 1.1 and later
  940. }
  941. function GetFlavorDataSize( theDrag: DragRef; theItemRef: DragItemRef; theType: FlavorType; var dataSize: Size ): OSErr; external name '_GetFlavorDataSize';
  942. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  943. {
  944. * GetFlavorData()
  945. *
  946. * Mac OS X threading:
  947. * Not thread safe
  948. *
  949. * Availability:
  950. * Mac OS X: in version 10.0 and later in Carbon.framework
  951. * CarbonLib: in CarbonLib 1.0 and later
  952. * Non-Carbon CFM: in DragLib 1.1 and later
  953. }
  954. function GetFlavorData( theDrag: DragRef; theItemRef: DragItemRef; theType: FlavorType; dataPtr: UnivPtr; var dataSize: Size; dataOffset: UInt32 ): OSErr; external name '_GetFlavorData';
  955. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  956. {
  957. _________________________________________________________________________________________________________
  958. ¥ DRAG ITEM BOUNDS
  959. _________________________________________________________________________________________________________
  960. }
  961. {
  962. * GetDragItemBounds()
  963. *
  964. * Mac OS X threading:
  965. * Not thread safe
  966. *
  967. * Availability:
  968. * Mac OS X: in version 10.0 and later in Carbon.framework
  969. * CarbonLib: in CarbonLib 1.0 and later
  970. * Non-Carbon CFM: in DragLib 1.1 and later
  971. }
  972. function GetDragItemBounds( theDrag: DragRef; theItemRef: DragItemRef; var itemBounds: Rect ): OSErr; external name '_GetDragItemBounds';
  973. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  974. {
  975. * SetDragItemBounds()
  976. *
  977. * Mac OS X threading:
  978. * Not thread safe
  979. *
  980. * Availability:
  981. * Mac OS X: in version 10.0 and later in Carbon.framework
  982. * CarbonLib: in CarbonLib 1.0 and later
  983. * Non-Carbon CFM: in DragLib 1.1 and later
  984. }
  985. function SetDragItemBounds( theDrag: DragRef; theItemRef: DragItemRef; const (*var*) itemBounds: Rect ): OSErr; external name '_SetDragItemBounds';
  986. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  987. {
  988. _________________________________________________________________________________________________________
  989. ¥ DROP LOCATIONS
  990. _________________________________________________________________________________________________________
  991. }
  992. {
  993. * GetDropLocation()
  994. *
  995. * Mac OS X threading:
  996. * Not thread safe
  997. *
  998. * Availability:
  999. * Mac OS X: in version 10.0 and later in Carbon.framework
  1000. * CarbonLib: in CarbonLib 1.0 and later
  1001. * Non-Carbon CFM: in DragLib 1.1 and later
  1002. }
  1003. function GetDropLocation( theDrag: DragRef; var dropLocation: AEDesc ): OSErr; external name '_GetDropLocation';
  1004. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1005. {
  1006. * SetDropLocation()
  1007. *
  1008. * Mac OS X threading:
  1009. * Not thread safe
  1010. *
  1011. * Availability:
  1012. * Mac OS X: in version 10.0 and later in Carbon.framework
  1013. * CarbonLib: in CarbonLib 1.0 and later
  1014. * Non-Carbon CFM: in DragLib 1.1 and later
  1015. }
  1016. function SetDropLocation( theDrag: DragRef; const (*var*) dropLocation: AEDesc ): OSErr; external name '_SetDropLocation';
  1017. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1018. {
  1019. _________________________________________________________________________________________________________
  1020. ¥ STANDARD DROP LOCATIONS
  1021. _________________________________________________________________________________________________________
  1022. }
  1023. {
  1024. * GetStandardDropLocation()
  1025. *
  1026. * Discussion:
  1027. * Gets the standard drop location that was set by the receiver of
  1028. * the drag.
  1029. *
  1030. * Mac OS X threading:
  1031. * Not thread safe
  1032. *
  1033. * Parameters:
  1034. *
  1035. * theDrag:
  1036. * The drag reference from which to retrieve the allowable drag
  1037. * actions.
  1038. *
  1039. * outDropLocation:
  1040. * A pointer to the standard drop location, set by the receiver,
  1041. * representing the location where the drag was dropped.
  1042. *
  1043. * Result:
  1044. * An operating system result code.
  1045. *
  1046. * Availability:
  1047. * Mac OS X: in version 10.2 and later in Carbon.framework
  1048. * CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
  1049. * Non-Carbon CFM: not available
  1050. }
  1051. function GetStandardDropLocation( theDrag: DragRef; var outDropLocation: StandardDropLocation ): OSStatus; external name '_GetStandardDropLocation';
  1052. (* AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER *)
  1053. {
  1054. * SetStandardDropLocation()
  1055. *
  1056. * Discussion:
  1057. * Used by the receiver of the drag to set the standard drop
  1058. * location.
  1059. *
  1060. * Mac OS X threading:
  1061. * Not thread safe
  1062. *
  1063. * Parameters:
  1064. *
  1065. * theDrag:
  1066. * The drag reference from which to retrieve the allowable drag
  1067. * actions.
  1068. *
  1069. * dropLocation:
  1070. * The standard drop location representing the location where the
  1071. * drag was dropped.
  1072. *
  1073. * Result:
  1074. * An operating system result code.
  1075. *
  1076. * Availability:
  1077. * Mac OS X: in version 10.2 and later in Carbon.framework
  1078. * CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.2 and later
  1079. * Non-Carbon CFM: not available
  1080. }
  1081. function SetStandardDropLocation( theDrag: DragRef; dropLocation: StandardDropLocation ): OSStatus; external name '_SetStandardDropLocation';
  1082. (* AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER *)
  1083. {
  1084. _________________________________________________________________________________________________________
  1085. ¥ GETTING INFORMATION ABOUT A DRAG
  1086. _________________________________________________________________________________________________________
  1087. }
  1088. {
  1089. * GetDragAttributes()
  1090. *
  1091. * Mac OS X threading:
  1092. * Not thread safe
  1093. *
  1094. * Availability:
  1095. * Mac OS X: in version 10.0 and later in Carbon.framework
  1096. * CarbonLib: in CarbonLib 1.0 and later
  1097. * Non-Carbon CFM: in DragLib 1.1 and later
  1098. }
  1099. function GetDragAttributes( theDrag: DragRef; var flags: DragAttributes ): OSErr; external name '_GetDragAttributes';
  1100. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1101. {
  1102. * GetDragMouse()
  1103. *
  1104. * Mac OS X threading:
  1105. * Not thread safe
  1106. *
  1107. * Availability:
  1108. * Mac OS X: in version 10.0 and later in Carbon.framework
  1109. * CarbonLib: in CarbonLib 1.0 and later
  1110. * Non-Carbon CFM: in DragLib 1.1 and later
  1111. }
  1112. function GetDragMouse( theDrag: DragRef; var mouse: Point; var globalPinnedMouse: Point ): OSErr; external name '_GetDragMouse';
  1113. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1114. {
  1115. * SetDragMouse()
  1116. *
  1117. * Mac OS X threading:
  1118. * Not thread safe
  1119. *
  1120. * Availability:
  1121. * Mac OS X: in version 10.0 and later in Carbon.framework
  1122. * CarbonLib: in CarbonLib 1.0 and later
  1123. * Non-Carbon CFM: in DragLib 1.1 and later
  1124. }
  1125. function SetDragMouse( theDrag: DragRef; globalPinnedMouse: Point ): OSErr; external name '_SetDragMouse';
  1126. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1127. {
  1128. * GetDragOrigin()
  1129. *
  1130. * Mac OS X threading:
  1131. * Not thread safe
  1132. *
  1133. * Availability:
  1134. * Mac OS X: in version 10.0 and later in Carbon.framework
  1135. * CarbonLib: in CarbonLib 1.0 and later
  1136. * Non-Carbon CFM: in DragLib 1.1 and later
  1137. }
  1138. function GetDragOrigin( theDrag: DragRef; var globalInitialMouse: Point ): OSErr; external name '_GetDragOrigin';
  1139. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1140. {
  1141. * GetDragModifiers()
  1142. *
  1143. * Mac OS X threading:
  1144. * Not thread safe
  1145. *
  1146. * Availability:
  1147. * Mac OS X: in version 10.0 and later in Carbon.framework
  1148. * CarbonLib: in CarbonLib 1.0 and later
  1149. * Non-Carbon CFM: in DragLib 1.1 and later
  1150. }
  1151. function GetDragModifiers( theDrag: DragRef; var modifiers: SInt16; var mouseDownModifiers: SInt16; var mouseUpModifiers: SInt16 ): OSErr; external name '_GetDragModifiers';
  1152. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1153. {
  1154. _________________________________________________________________________________________________________
  1155. ¥ ACCESSING DRAG ACTIONS
  1156. _________________________________________________________________________________________________________
  1157. }
  1158. {
  1159. * GetDragAllowableActions()
  1160. *
  1161. * Discussion:
  1162. * Gets the actions the drag sender has allowed the receiver to
  1163. * perform. These are not requirements, but they highly suggested
  1164. * actions which allows the drag receiver to improve harmony across
  1165. * the system. The allowable actions received are always those
  1166. * local to the caller's process.
  1167. *
  1168. * Mac OS X threading:
  1169. * Not thread safe
  1170. *
  1171. * Parameters:
  1172. *
  1173. * theDrag:
  1174. * The drag reference from which to retreive the allowable drag
  1175. * actions.
  1176. *
  1177. * outActions:
  1178. * A pointer to receive the field of allowable drag actions.
  1179. *
  1180. * Result:
  1181. * An operating system result code.
  1182. *
  1183. * Availability:
  1184. * Mac OS X: in version 10.1 and later in Carbon.framework
  1185. * CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.1 and later
  1186. * Non-Carbon CFM: not available
  1187. }
  1188. function GetDragAllowableActions( theDrag: DragRef; var outActions: DragActions ): OSStatus; external name '_GetDragAllowableActions';
  1189. (* AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER *)
  1190. {
  1191. * SetDragAllowableActions()
  1192. *
  1193. * Discussion:
  1194. * Sets the actions the receiver of the drag is allowed to perform.
  1195. * These are not requirements, but they highly suggested actions
  1196. * which allows the drag receiver to improve harmony across the
  1197. * system. The caller may select wether these drag actions apply to
  1198. * a local or remote process.
  1199. *
  1200. * Mac OS X threading:
  1201. * Not thread safe
  1202. *
  1203. * Parameters:
  1204. *
  1205. * theDrag:
  1206. * The drag reference in which to set the allowable drag actions.
  1207. *
  1208. * inActions:
  1209. * A field of allowable drag actions to be set.
  1210. *
  1211. * isLocal:
  1212. * A boolean value allowing the drag sender to distinguish between
  1213. * those drag actions allowable by the local receiver versus a
  1214. * remote one.
  1215. *
  1216. * Result:
  1217. * An operating system result code.
  1218. *
  1219. * Availability:
  1220. * Mac OS X: in version 10.1 and later in Carbon.framework
  1221. * CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.1 and later
  1222. * Non-Carbon CFM: not available
  1223. }
  1224. function SetDragAllowableActions( theDrag: DragRef; inActions: DragActions; isLocal: Boolean ): OSStatus; external name '_SetDragAllowableActions';
  1225. (* AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER *)
  1226. {
  1227. * GetDragDropAction()
  1228. *
  1229. * Discussion:
  1230. * Gets the action performed by the receiver of the drag. More than
  1231. * one action may have been performed.
  1232. *
  1233. * Mac OS X threading:
  1234. * Not thread safe
  1235. *
  1236. * Parameters:
  1237. *
  1238. * theDrag:
  1239. * The drag reference from which to retreive the performed drop
  1240. * action.
  1241. *
  1242. * outAction:
  1243. * A pointer to receive the drag action performed.
  1244. *
  1245. * Result:
  1246. * An operating system result code.
  1247. *
  1248. * Availability:
  1249. * Mac OS X: in version 10.1 and later in Carbon.framework
  1250. * CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.1 and later
  1251. * Non-Carbon CFM: not available
  1252. }
  1253. function GetDragDropAction( theDrag: DragRef; var outAction: DragActions ): OSStatus; external name '_GetDragDropAction';
  1254. (* AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER *)
  1255. {
  1256. * SetDragDropAction()
  1257. *
  1258. * Discussion:
  1259. * Sets the action performed by the receiver of the drag. More than
  1260. * one action may be performed.
  1261. *
  1262. * Mac OS X threading:
  1263. * Not thread safe
  1264. *
  1265. * Parameters:
  1266. *
  1267. * theDrag:
  1268. * The drag reference in which to set the performed drop action.
  1269. *
  1270. * inAction:
  1271. * The drop action performed.
  1272. *
  1273. * Result:
  1274. * An operating system result code.
  1275. *
  1276. * Availability:
  1277. * Mac OS X: in version 10.1 and later in Carbon.framework
  1278. * CarbonLib: not available in CarbonLib 1.x, is available on Mac OS X version 10.1 and later
  1279. * Non-Carbon CFM: not available
  1280. }
  1281. function SetDragDropAction( theDrag: DragRef; inAction: DragActions ): OSStatus; external name '_SetDragDropAction';
  1282. (* AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER *)
  1283. {
  1284. _________________________________________________________________________________________________________
  1285. ¥ DRAG HIGHLIGHTING
  1286. _________________________________________________________________________________________________________
  1287. }
  1288. {
  1289. * ShowDragHilite()
  1290. *
  1291. * Mac OS X threading:
  1292. * Not thread safe
  1293. *
  1294. * Availability:
  1295. * Mac OS X: in version 10.0 and later in Carbon.framework
  1296. * CarbonLib: in CarbonLib 1.0 and later
  1297. * Non-Carbon CFM: in DragLib 1.1 and later
  1298. }
  1299. function ShowDragHilite( theDrag: DragRef; hiliteFrame: RgnHandle; inside: Boolean ): OSErr; external name '_ShowDragHilite';
  1300. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1301. {
  1302. * HideDragHilite()
  1303. *
  1304. * Mac OS X threading:
  1305. * Not thread safe
  1306. *
  1307. * Availability:
  1308. * Mac OS X: in version 10.0 and later in Carbon.framework
  1309. * CarbonLib: in CarbonLib 1.0 and later
  1310. * Non-Carbon CFM: in DragLib 1.1 and later
  1311. }
  1312. function HideDragHilite( theDrag: DragRef ): OSErr; external name '_HideDragHilite';
  1313. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1314. {
  1315. * DragPreScroll()
  1316. *
  1317. * Mac OS X threading:
  1318. * Not thread safe
  1319. *
  1320. * Availability:
  1321. * Mac OS X: in version 10.0 and later in Carbon.framework
  1322. * CarbonLib: in CarbonLib 1.0 and later
  1323. * Non-Carbon CFM: in DragLib 1.1 and later
  1324. }
  1325. function DragPreScroll( theDrag: DragRef; dH: SInt16; dV: SInt16 ): OSErr; external name '_DragPreScroll';
  1326. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1327. {
  1328. * DragPostScroll()
  1329. *
  1330. * Mac OS X threading:
  1331. * Not thread safe
  1332. *
  1333. * Availability:
  1334. * Mac OS X: in version 10.0 and later in Carbon.framework
  1335. * CarbonLib: in CarbonLib 1.0 and later
  1336. * Non-Carbon CFM: in DragLib 1.1 and later
  1337. }
  1338. function DragPostScroll( theDrag: DragRef ): OSErr; external name '_DragPostScroll';
  1339. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1340. {
  1341. * UpdateDragHilite()
  1342. *
  1343. * Mac OS X threading:
  1344. * Not thread safe
  1345. *
  1346. * Availability:
  1347. * Mac OS X: in version 10.0 and later in Carbon.framework
  1348. * CarbonLib: in CarbonLib 1.0 and later
  1349. * Non-Carbon CFM: in DragLib 1.1 and later
  1350. }
  1351. function UpdateDragHilite( theDrag: DragRef; updateRgn: RgnHandle ): OSErr; external name '_UpdateDragHilite';
  1352. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1353. {
  1354. * GetDragHiliteColor()
  1355. *
  1356. * Mac OS X threading:
  1357. * Not thread safe
  1358. *
  1359. * Availability:
  1360. * Mac OS X: in version 10.0 and later in Carbon.framework
  1361. * CarbonLib: in CarbonLib 1.0 and later
  1362. * Non-Carbon CFM: in DragLib 7.5 and later
  1363. }
  1364. function GetDragHiliteColor( window: WindowRef; var color: RGBColor ): OSErr; external name '_GetDragHiliteColor';
  1365. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1366. {
  1367. _________________________________________________________________________________________________________
  1368. ¥ UTILITIES
  1369. _________________________________________________________________________________________________________
  1370. }
  1371. {
  1372. * WaitMouseMoved()
  1373. *
  1374. * Mac OS X threading:
  1375. * Not thread safe
  1376. *
  1377. * Availability:
  1378. * Mac OS X: in version 10.0 and later in Carbon.framework
  1379. * CarbonLib: in CarbonLib 1.0 and later
  1380. * Non-Carbon CFM: in DragLib 1.1 and later
  1381. }
  1382. function WaitMouseMoved( initialGlobalMouse: Point ): Boolean; external name '_WaitMouseMoved';
  1383. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1384. {
  1385. * ZoomRects()
  1386. *
  1387. * Mac OS X threading:
  1388. * Not thread safe
  1389. *
  1390. * Availability:
  1391. * Mac OS X: in version 10.0 and later in Carbon.framework
  1392. * CarbonLib: in CarbonLib 1.0 and later
  1393. * Non-Carbon CFM: in DragLib 1.1 and later
  1394. }
  1395. function ZoomRects( const (*var*) fromRect: Rect; const (*var*) toRect: Rect; zoomSteps: SInt16; acceleration: ZoomAcceleration ): OSErr; external name '_ZoomRects';
  1396. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1397. {
  1398. * ZoomRegion()
  1399. *
  1400. * Mac OS X threading:
  1401. * Not thread safe
  1402. *
  1403. * Availability:
  1404. * Mac OS X: in version 10.0 and later in Carbon.framework
  1405. * CarbonLib: in CarbonLib 1.0 and later
  1406. * Non-Carbon CFM: in DragLib 1.1 and later
  1407. }
  1408. function ZoomRegion( region: RgnHandle; zoomDistance: Point; zoomSteps: SInt16; acceleration: ZoomAcceleration ): OSErr; external name '_ZoomRegion';
  1409. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  1410. {--------------------------------------------------------------------------------------}
  1411. { ¥ DEPRECATED }
  1412. { All functions below this point are either deprecated (they continue to function }
  1413. { but are not the most modern nor most efficient solution to a problem), or they are }
  1414. { completely unavailable on Mac OS X. }
  1415. {--------------------------------------------------------------------------------------}
  1416. {
  1417. * SetDragImage() *** DEPRECATED ***
  1418. *
  1419. * Deprecated:
  1420. * Applications should use SetDragImageWithCGImage instead.
  1421. *
  1422. * Summary:
  1423. * Associates an image with a drag reference.
  1424. *
  1425. * Discussion:
  1426. * Used by the sender of the drag to set the image, in PixMapHandle
  1427. * format, to be displayed as user feedback during the drag. This
  1428. * API may be called at any point during the drag to update the
  1429. * image.
  1430. *
  1431. * Mac OS X threading:
  1432. * Not thread safe
  1433. *
  1434. * Parameters:
  1435. *
  1436. * inDrag:
  1437. * The drag reference for which the image will be displayed.
  1438. *
  1439. * inImagePixMap:
  1440. * The PixMapHandle for the image to be displayed during the drag.
  1441. *
  1442. * inImageRgn:
  1443. * A mask describing the portion of the PixMap contained in the
  1444. * imagePixMap parameter which contains the drag image. Pass NULL
  1445. * for inImageRgn if the entire PixMap, including white space,
  1446. * should be dragged.
  1447. *
  1448. * inImageOffsetPt:
  1449. * The offset required to move the PixMap specified in the
  1450. * imagePixMap parameter to the global coordinates where the image
  1451. * initially appears. If this parameter is (0,0), the PixMap
  1452. * should already be in global coordinates.
  1453. *
  1454. * inImageFlags:
  1455. * Flags controlling the appearance of the drag image.
  1456. *
  1457. * Result:
  1458. * An operating system result code.
  1459. *
  1460. * Availability:
  1461. * Mac OS X: in version 10.0 and later in Carbon.framework but deprecated in 10.4
  1462. * CarbonLib: in CarbonLib 1.0 and later
  1463. * Non-Carbon CFM: in DragLib 7.5 and later
  1464. }
  1465. function SetDragImage( inDrag: DragRef; inImagePixMap: PixMapHandle; inImageRgn: RgnHandle; inImageOffsetPt: Point; inImageFlags: DragImageFlags ): OSErr; external name '_SetDragImage';
  1466. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4 *)
  1467. {
  1468. _________________________________________________________________________________________________________
  1469. ¥ OLD NAMES
  1470. These are provided for compatiblity with older source bases. It is recommended to not use them since
  1471. they may removed from this interface file at any time.
  1472. _________________________________________________________________________________________________________
  1473. }
  1474. type
  1475. DragReference = DragRef;
  1476. type
  1477. ItemReference = DragItemRef;
  1478. (*
  1479. #if OLDROUTINENAMES
  1480. const
  1481. dragHasLeftSenderWindow = kDragHasLeftSenderWindow; { drag has left the source window since TrackDrag }
  1482. dragInsideSenderApplication = kDragInsideSenderApplication; { drag is occurring within the sender application }
  1483. dragInsideSenderWindow = kDragInsideSenderWindow; { drag is occurring within the sender window }
  1484. const
  1485. dragTrackingEnterHandler = kDragTrackingEnterHandler; { drag has entered handler }
  1486. dragTrackingEnterWindow = kDragTrackingEnterWindow; { drag has entered window }
  1487. dragTrackingInWindow = kDragTrackingInWindow; { drag is moving within window }
  1488. dragTrackingLeaveWindow = kDragTrackingLeaveWindow; { drag has exited window }
  1489. dragTrackingLeaveHandler = kDragTrackingLeaveHandler; { drag has exited handler }
  1490. const
  1491. dragRegionBegin = kDragRegionBegin; { initialize drawing }
  1492. dragRegionDraw = kDragRegionDraw; { draw drag feedback }
  1493. dragRegionHide = kDragRegionHide; { hide drag feedback }
  1494. dragRegionIdle = kDragRegionIdle; { drag feedback idle time }
  1495. dragRegionEnd = kDragRegionEnd; { end of drawing }
  1496. const
  1497. zoomNoAcceleration = kZoomNoAcceleration; { use linear interpolation }
  1498. zoomAccelerate = kZoomAccelerate; { ramp up step size }
  1499. zoomDecelerate = kZoomDecelerate; { ramp down step size }
  1500. const
  1501. kDragStandardImage = kDragStandardTranslucency; { 65% image translucency (standard)}
  1502. kDragDarkImage = kDragDarkTranslucency; { 50% image translucency}
  1503. kDragDarkerImage = kDragDarkerTranslucency; { 25% image translucency}
  1504. kDragOpaqueImage = kDragOpaqueTranslucency; { 0% image translucency (opaque)}
  1505. #endif { OLDROUTINENAMES }
  1506. *)
  1507. end.