Index: src/OFThread.h ================================================================== --- src/OFThread.h +++ src/OFThread.h @@ -129,20 +129,10 @@ * * \param block A block which is executed by the thread * \return A new, autoreleased thread */ + threadWithBlock: (of_thread_block_t)block; - -/** - * \brief Creates a new thread with the specified block and object. - * - * \param object An object which is passed for use in the main method or nil - * \param block A block which is executed by the thread - * \return A new, autoreleased thread - */ -+ threadWithObject: (id)object - block: (of_thread_block_t)block; #endif /** * \brief Sets the Thread Local Storage for the specified key. * @@ -229,21 +219,10 @@ * * \param block A block which is executed by the thread * \return An initialized OFThread. */ - initWithBlock: (of_thread_block_t)block; - -/** - * \brief Initializes an already allocated thread with the specified block and - * object. - * - * \param block A block which is executed by the thread - * \param object An object which is passed for use in the main method or nil - * \return An initialized OFThread. - */ -- initWithObject: (id)object - block: (of_thread_block_t)block; #endif /** * \brief The main routine of the thread. You need to reimplement this! * Index: src/OFThread.m ================================================================== --- src/OFThread.m +++ src/OFThread.m @@ -130,17 +130,10 @@ #ifdef OF_HAVE_BLOCKS + threadWithBlock: (of_thread_block_t)block { return [[[self alloc] initWithBlock: block] autorelease]; } - -+ threadWithObject: (id)object - block: (of_thread_block_t)block -{ - return [[[self alloc] initWithObject: object - block: block] autorelease]; -} #endif + (void)setObject: (id)object forTLSKey: (OFTLSKey*)key { @@ -266,21 +259,13 @@ } #ifdef OF_HAVE_BLOCKS - initWithBlock: (of_thread_block_t)block_ { - return [self initWithObject: nil - block: block_]; -} - -- initWithObject: (id)object_ - block: (of_thread_block_t)block_ -{ self = [super init]; @try { - object = [object_ retain]; block = [block_ copy]; } @catch (id e) { [self release]; @throw e; }