home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1994 February: Tool Chest / Dev.CD Feb 94.toast / Tool Chest / Development Platforms / AppsToGo / AppsToGo.src / AppsToGo.Changes / DTS.Lib / TreeObj.c.df < prev    next >
Encoding:
Text File  |  1993-06-18  |  2.7 KB  |  86 lines  |  [TEXT/MPS ]

  1. File #1: b:-archives:93/03/25.Dev.CD.Version:AppsToGo.CD:DTS.Lib:TreeObj.c
  2. File #2: a:Desktop Folder:AppsToGo.src:DTS.Lib:TreeObj.c
  3.  
  4. Nonmatching lines (File "b:-archives:93/03/25.Dev.CD.Version:AppsToGo.CD:DTS.Lib:TreeObj.c"; Line 8; File "a:Desktop Folder:AppsToGo.src:DTS.Lib:TreeObj.c"; Line 8)
  5. ** Copyright © 1992 Apple Computer, Inc.
  6.  
  7. ** Copyright © 1992-1993 Apple Computer, Inc.
  8.  
  9.  
  10. Nonmatching lines (File "b:-archives:93/03/25.Dev.CD.Version:AppsToGo.CD:DTS.Lib:TreeObj.c"; Line 12:13; File "a:Desktop Folder:AppsToGo.src:DTS.Lib:TreeObj.c"; Line 12:19)
  11.  
  12.  
  13.  
  14. /* You may incorporate this sample code into your applications without
  15. ** restriction, though the sample code has been provided "AS IS" and the
  16. ** responsibility for its operation is 100% yours.  However, what you are
  17. ** not permitted to do is to redistribute the source as "DSC Sample Code"
  18. ** after having made changes. If you're going to re-distribute the source,
  19. ** we require that you make it clear in the source that the code was
  20. ** descended from Apple Sample Code, but that you've made changes. */
  21.  
  22.  
  23.  
  24. Nonmatching lines (File "b:-archives:93/03/25.Dev.CD.Version:AppsToGo.CD:DTS.Lib:TreeObj.c"; Line 393; File "a:Desktop Folder:AppsToGo.src:DTS.Lib:TreeObj.c"; Line 399)
  25. OSErr    SwapChildData(TreeObjHndl hndla, TreeObjHndl hndlb)
  26.  
  27. OSErr    SwapTreeObjData(TreeObjHndl hndla, TreeObjHndl hndlb)
  28.  
  29.  
  30. Nonmatching lines (File "b:-archives:93/03/25.Dev.CD.Version:AppsToGo.CD:DTS.Lib:TreeObj.c"; Line 1643; File "a:Desktop Folder:AppsToGo.src:DTS.Lib:TreeObj.c"; Line 1649)
  31.     SwapChildData(dhndl, uhndl);
  32.  
  33.     SwapTreeObjData(dhndl, uhndl);
  34.  
  35.  
  36. Extra lines in 2nd file (File "b:-archives:93/03/25.Dev.CD.Version:AppsToGo.CD:DTS.Lib:TreeObj.c"; Line 2345Δ; File "a:Desktop Folder:AppsToGo.src:DTS.Lib:TreeObj.c"; Line 2352:2398)
  37. /**********************************************************************/
  38. /**********************************************************************/
  39.  
  40.  
  41.  
  42. #pragma segment TreeObj
  43. Boolean    EqualTreeObjData(TreeObjHndl h1, TreeObjHndl h2)
  44. {
  45.     TreeObjProcPtr    proc;
  46.  
  47.     if ((h1) && (!h2)) return(false);
  48.     if ((h2) && (!h1)) return(false);
  49.  
  50.     if ((*h1)->type != (*h2)->type) return(false);
  51.  
  52.     if (proc = gTreeObjMethods[(*h1)->type])
  53.         return((*proc)(h1, COMPAREMESSAGE, (long)h2));
  54.     else
  55.         return(DefaultEqualTreeObjData(h1, h2));
  56. }
  57.  
  58.  
  59.  
  60. /**********************************************************************/
  61.  
  62.  
  63.  
  64. #pragma segment TreeObj
  65. Boolean    DefaultEqualTreeObjData(TreeObjHndl h1, TreeObjHndl h2)
  66. {
  67.     Ptr        p1, p2;
  68.     long    ii, jj;
  69.  
  70.     if ((jj = (*h1)->dataSize) != (*h2)->dataSize) return(false);
  71.  
  72.     p1 = GetDataPtr(h1);
  73.     p2 = GetDataPtr(h2);
  74.  
  75.     for (ii = 0; ii < jj; ++ii) {
  76.         if (p1[ii] != p2[ii]) return(false);
  77.     }
  78.  
  79.     return(true);
  80. }
  81.  
  82.  
  83.  
  84.  
  85. *** EOF on both files ***
  86.