Minor bug fixes

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1891 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
shadow303 2002-11-09 21:16:58 +00:00
parent 5ea0e0a5d0
commit bcb5296173

View File

@ -63,8 +63,8 @@ BClipboard::BClipboard(const char *name, bool transient = false)
BMessage handlerMessage(B_REG_ADD_CLIPBOARD), handlerReply;
int32 result;
if ( (handlerMessage.AddString("name",fName) == B_OK) &&
(fClipHandler.SendMessage(&message, &reply) == B_OK) )
reply.FindInt32("result",&result);
(fClipHandler.SendMessage(&handlerMessage, &handlerReply) == B_OK) )
handlerReply.FindInt32("result",&result);
}
}
//------------------------------------------------------------------------------
@ -106,7 +106,11 @@ status_t BClipboard::StartWatching(BMessenger target)
if ( (message.AddString("name",fName) == B_OK) &&
(message.AddMessenger("target", target ) == B_OK) &&
(fClipHandler.SendMessage(&message, &reply) == B_OK) )
return B_OK;
{
int32 result;
reply.FindInt32("result",&result);
return result;
}
return B_ERROR;
}
//------------------------------------------------------------------------------
@ -116,7 +120,11 @@ status_t BClipboard::StopWatching(BMessenger target)
if ( (message.AddString("name",fName) == B_OK) &&
(message.AddMessenger("target", target ) == B_OK) &&
(fClipHandler.SendMessage(&message, &reply) == B_OK) )
return B_OK;
{
int32 result;
reply.FindInt32("result",&result);
return result;
}
return B_ERROR;
}
//------------------------------------------------------------------------------