Add a way to cancel a started message.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40020 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Lotz 2010-12-29 08:30:25 +00:00
parent 49e57f098a
commit c3dab48ba4
2 changed files with 10 additions and 1 deletions

View File

@ -56,6 +56,14 @@ RemoteMessage::NextMessage(uint16& code)
}
void
RemoteMessage::Cancel()
{
fAvailable += fWriteIndex;
fWriteIndex = 0;
}
#ifndef CLIENT_COMPILE
void
RemoteMessage::AddBitmap(const ServerBitmap& bitmap, bool minimal)
@ -362,7 +370,7 @@ RemoteMessage::ReadFontState(BFont& font)
font.SetSpacing(spacing);
font.SetShear(shear);
font.SetRotation(rotation);
font.SetFalseBoldWidth(falseBoldWidth);
font.SetFalseBoldWidth(falseBoldWidth);
font.SetSize(size);
font.SetFace(face);
return B_OK;

View File

@ -133,6 +133,7 @@ public:
void Start(uint16 code);
status_t Flush();
void Cancel();
status_t NextMessage(uint16& code);
uint16 Code() { return fCode; }