Farbflash projects: Imaging lingo table | 3-D scene list | Find all | Handler menu | Lingo message window

Changeset 90 for branches


Ignore:
Timestamp:
12/09/07 12:59:45 (4 years ago)
Author:
alex
Message:

fixed bugs in beta

Location:
branches/beta
Files:
1 deleted
6 edited

Legend:

Unmodified
Added
Removed
  • branches/beta/castlib1/OSCmenu_Utilities.ls

    r87 r90  
    362362     
    363363    subli.add("Convert path from HFS to UNIX") 
    364     pLookUpCommandList.setaprop("Convert path from HFS to UNIX", ["mConvertHFS2Unix me, string_HFSPath", "alexUtilities"]) 
     364    pLookUpCommandList.setaprop("Convert path from HFS to UNIX", ["mConvertHFS2Unix me", "alexUtilities"]) 
    365365    subli.add("Convert path from UNIX to HFS") 
    366     pLookUpCommandList.setaprop("Convert path from UNIX to HFS", ["mConvertUnix2HFS me, string_UnixPath", "alexUtilities"]) 
     366    pLookUpCommandList.setaprop("Convert path from UNIX to HFS", ["mConvertUnix2HFS me", "alexUtilities"]) 
    367367     
    368368  end if 
  • branches/beta/castlib1/alexUtilities.ls

    r87 r90  
    208208   
    209209  return retval 
     210end 
     211 
     212-- xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx 
     213-- xxxxxxxxxxxxxxxxxx Write text out to a file 
     214--------------------- helper for the bbdiff and svn handler 
     215 
     216on mSaveTextToTempFile me, theText, pfad 
     217   
     218  if ilk(pfad) <> #string then 
     219    pfad = mConvertUnix2HFS("/tmp/tmpfile.txt") 
     220  end if 
     221  if length(pfad) < 1 then 
     222    pfad = mConvertUnix2HFS("/tmp/tmpfile.txt") 
     223  end if 
     224   
     225  return mSaveToTextFile(me, theText, pfad) 
     226   
    210227end 
    211228 
     
    847864 
    848865on mDeleteMembersByName me, praefix 
    849    
    850   searchParams = mProcessSearchString(me, praefix) 
    851   searchString = searchParams.getaprop(#searchString) 
    852    
    853866  repeat with n = 1 to the number of castlibs 
    854867    repeat with z = 1 to the number of members of castlib n 
    855        
    856       case searchParams.getaprop(#searchMode) of 
    857            
    858         #startsWith: 
    859           if member(z, n).name starts searchString then 
    860             member(z, n).erase() 
    861           end if 
    862            
    863         #endsWith: 
    864           theName = member(z, n).name 
    865           len = length(theName) 
    866           startchar = len - length(searchString) + 1 
    867           if theName.char[startchar .. len] = searchString then 
    868             member(z, n).erase() 
    869           end if 
    870            
    871         #equals: 
    872           if member(z, n).name = searchString then 
    873             member(z, n).erase() 
    874           end if 
    875            
    876         otherwise: 
    877           if member(z, n).name contains searchString then 
    878             member(z, n).erase() 
    879           end if 
    880            
    881       end case 
    882        
     868      if member(z, n).name starts praefix then 
     869        member(z, n).erase() 
     870      end if 
    883871    end repeat 
    884872  end repeat 
    885873end 
    886874 
    887 -- xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx 
    888  
    889 on mProcessSearchString me, srchString 
    890    
    891   searchmode = #contains 
    892    
    893   if char 1 of srchString = "^" then 
    894     if the last char of srchString <> "$" then 
    895       searchmode = #startsWith 
    896     else 
    897       searchmode = #equals 
    898       delete the last char of srchString 
    899     end if 
    900     delete char 1 of srchString 
    901   else 
    902     if the last char of srchString = "$" then 
    903       searchmode = #endsWith 
    904       delete the last char of srchString 
    905     end if 
    906   end if 
    907    
    908   return [#searchString:srchString, #searchMode:searchmode] 
    909 end 
    910875 
    911876 
     
    1031996 
    1032997on mSelectInScore me, startfr, endfr 
    1033    
    1034    
    1035   ------------------------------ 
    1036   -- this allows to enter anything other than an integer or an integer < 1 in order to search all frames 
    1037   if not(voidP(startfr)) then 
    1038     startfr = integer(startfr) 
    1039     if voidP(startfr) then 
    1040       startfr = 1 
    1041       endfr = 0 
    1042     end if 
    1043     if startfr < 1 then 
    1044       startfr = 1 
    1045       endfr = 0 
    1046     end if 
    1047   end if 
    1048   ------------------------------ 
    1049998   
    1050999  cl = the activecastlib 
     
    15531502   
    15541503  created = 0 
    1555    
    1556   if mCheckForXtra(me, "BudAPI") then 
    1557     theResult = baMsgBox("Create new index ?", "New index", "Yesno", "Question", 1) 
    1558     if theResult = "Yes" then 
    1559       theResult = baPrompt("Enter new title", "Enter new title", "New index", 0, -2, -2) 
    1560       if length(theResult) then 
    1561         tell helpwindow to mCreateIndexMember theResult 
    1562       end if 
    1563     end if 
    1564   end if 
    15651504   
    15661505  repeat with n = 1 to anz 
  • branches/beta/castlib1/bbedit_Utilities.ls

    r84 r90  
    510510     
    511511    -------- now write the results of the BBEdit diff back into the script members 
    512     memref1.scripttext = mGetTextFromTempFile(me, tempSrcHFSPath) 
     512    memref1.scripttext = mGetTextFromFile(me, tempSrcHFSPath) 
    513513     
    514514    if ilk(memref2) = #member then 
    515       memref2.scripttext = mGetTextFromTempFile(me, tempSrcHFSPath2) 
     515      memref2.scripttext = mGetTextFromFile(me, tempSrcHFSPath2) 
    516516    end if 
    517517     
     
    545545end 
    546546 
    547  
    548 -- xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx 
    549 -- xxxxxxxxxxxxxxxxxx Write text out to a file 
    550 --------------------- helper for the above bbdiff handler 
    551  
    552 on mSaveTextToTempFile me, theText, pfad 
    553    
    554   retval = 0 
    555    
    556   if ilk(theText) <> #string then return retval 
    557    
    558   fio = new(xtra "fileio") 
    559   if not objectP(fio) then return retval 
    560    
    561   if ilk(pfad) = #string then 
    562     if pfad.length > 0 then 
    563        
    564       fio.openFile(pfad, 0) 
    565       if fio.status() = 0 then fio.delete() 
    566        
    567       fio.createFile(pfad) 
    568       if fio.status() = 0 then 
    569          
    570         fio.openFile(pfad, 2) 
    571         if fio.status() = 0 then 
    572            
    573           fio.writeString(theText) 
    574            
    575           if fio.status() = 0 then retval = pfad 
    576            
    577           fio.closeFile() 
    578         end if 
    579       end if 
    580     end if 
    581   end if 
    582    
    583   fio = 0 
    584    
    585   return retval 
    586 end 
    587  
    588 -- xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx 
    589 -- xxxxxxxxxxxxxxxxxx Read text from file 
    590 --------------------- helper for the above bbdiff handler 
    591  
    592 on mGetTextFromTempFile me, pfad 
    593   retval = "" 
    594    
    595   if the runmode contains "Plugin" then return retval 
    596    
    597   fio = new(xtra "fileio") 
    598    
    599   if not objectP(fio) then return retval 
    600   if (voidP(pfad) or (pfad = "")) then return retval 
    601    
    602   if ilk(pfad) = #string then 
    603     if pfad.length > 0 then 
    604       fio.openFile(pfad, 1) 
    605       if fio.status() = 0 then 
    606         retval = fio.readFile() 
    607         fio.closeFile() 
    608       end if 
    609     end if 
    610   end if 
    611   fio = void 
    612    
    613   return retval 
    614    
    615 end 
    616547 
    617548 
  • branches/beta/castlib1/svn_Utilities.ls

    r84 r90  
    143143             
    144144            -------- now write the results of the BBEdit diff back into the script members 
    145             scrText = mGetTextFromTempFile(me, tempSrcHFSPath) 
     145            scrText = mGetTextFromFile(me, tempSrcHFSPath) 
    146146             
    147147             
Note: See TracChangeset for help on using the changeset viewer.