/*********** GeneralAPIConversion: simple name changes ***********/ replacemethod "changeButtonTitle:" with "setPullsDown:" { replace "" with "!()" } within ("") { replace "" with "!" } /*********** MatrixAndCellConversion: obsolete method call replacements ***********/ replace "[ : at:]" with "[[ cellAtIndex:] :]" where "" isOneOf { "setTag", "setTarget", "setAction", "setStringValue", "setIntValue", "setFloatValue", "setDoubleValue" } replace "[ :]" with "[[ cellAtIndex:] ]" where ("", "") isOneOf { ("stringValueAt", "stringValue"), ("intValueAt", "intValue"), ("floatValueAt", "floatValue"), ("doubleValueAt", "doubleValue") } replace "[ insertEntry: atIndex:<index> tag:<tag> target:<target> action:<action>];" with "{ [<obj> insertEntry:<title> atIndex:<index>]; [[<obj> cellAtIndex:<index>] setTag:<tag>]; [[<obj> cellAtIndex:<index>] setTarget:<target>]; [[<obj> cellAtIndex:<index>] setAction:<action>]; }" replace "<w w>[<obj> addEntry:<title> tag:<tag> target:<target> action:<action>];" with "{ id _cell; [<obj> addEntry:<title>]; _cell = [<obj> cellAtIndex:[[<obj> cells] count] - 1]; [_cell setTag:<tag>]; [_cell setTarget:<target>]; [_cell setAction:<action>]; }" replace "[<obj> <t methodName>:<value> atRow:<row> column:<col>]" with "[[<obj> cellAtRow:<row> column:<col>] <t methodName>:<value>]" where "<methodName>" isOneOf { "setTag", "setTarget", "setAction" } replace "[<obj> setTag:<value> target:<target> action:<action> at:<row> :<col>];" with "{ id _cell = [<obj> cellAtRow:<row> column:<col>]; [_cell setTag:<value>]; [_cell setTarget:<target>]; [_cell setAction:<action>];< }" replace "[<obj> incrementState]" with "[<obj> setState:![<obj> state]]" warning "MatrixAndCellConversion: 'setState:' used to be 'incrementState' ; this conversion is not valid for multistate cells" /*********** MatrixAndCellConversion: obsolete methods ***********/ replacemethod "<sel>" with same error "MatrixAndCellConversion: 'setReaction' and 'reaction' are obsolete ; remove any related 'unlockFocus' calls" where "<sel>" isOneOf { "setReaction:", "reaction" } replacemethod "<sel>" with same error "MatrixAndCellConversion: <sel> is obolete ; use a cell method" where "<sel>" isOneOf { "addEntry:tag:target:action:", "doubleValueAt:", "floatValueAt:", "insertEntry:at:tag:target:action:", "intValueAt:", "setAction:at:", "setAction:at::", "setDoubleValue:at:", "setFloatValue:at:", "setIntValue:at:", "setStringValue:at:", "setTag:at:", "setTag:at::", "setTag:target:action:at::", "setTarget:at:", "setTarget:at::", "stringValueAt:", } replacemethod "incrementState" with same error "MatrixAndCellConversion: 'incrementState' is obsolete ; use 'setState:'" replace "[<matrix> cellCount]" with "[[<matrix> cells] count]" /*********** MatrixAndCellConversion: simple name changes ***********/ replacemethod "<old>" with "<new>" where ("<old>", "<new>") isOneOf { ("addItem:action:keyEquivalent:", "addItemWithTitle:action:keyEquivalent:"), ("clearSelectedCell", "deselectAllCells"), ("doubleValueAt:", "doubleValueAtIndex:"), ("drawCellAt:" "drawCellAtIndex:"), ("insertEntry:at:", "insertEntry:atIndex:"), ("insertItem:at:", "insertItem:atIndex:"), ("removeEntryAt:" , "removeEntryAtIndex:"), ("removeItemAt:", "removeItemAtIndex:"), ("selectTextAt:", "selectTextAtIndex:"), ("selectedIndex", "indexOfSelectedItem"), ("setItemList:", "setItemMatrix:"), ("setTitle:at:", "setTitle:atIndex:"), ("titleAt:", "titleAtIndex:"), ("cellList", "cells") }