ServerPicture:SyncState(): sync with Canvas instead of View

When the canvas api was introduced, ServerPicture was changed to work with Canvas,but this was not updated.

Change-Id: I37c68111f4a60408768656260bfc73a27f1f65f4
Reviewed-on: https://review.haiku-os.org/c/501
Reviewed-by: Stephan Aßmus <superstippi@gmx.de>
This commit is contained in:
JackBurton79 2018-08-30 11:59:58 +02:00 committed by Stephan Aßmus
parent 74726e7014
commit b3470a55cf
2 changed files with 13 additions and 13 deletions

View File

@ -1042,23 +1042,23 @@ ServerPicture::ExitStateChange()
void
ServerPicture::SyncState(View* view)
ServerPicture::SyncState(Canvas* canvas)
{
// TODO: Finish this
EnterStateChange();
WriteSetOrigin(view->CurrentState()->Origin());
WriteSetPenLocation(view->CurrentState()->PenLocation());
WriteSetPenSize(view->CurrentState()->UnscaledPenSize());
WriteSetScale(view->CurrentState()->Scale());
WriteSetLineMode(view->CurrentState()->LineCapMode(),
view->CurrentState()->LineJoinMode(),
view->CurrentState()->MiterLimit());
//WriteSetPattern(*view->CurrentState()->GetPattern().GetInt8());
WriteSetDrawingMode(view->CurrentState()->GetDrawingMode());
WriteSetOrigin(canvas->CurrentState()->Origin());
WriteSetPenLocation(canvas->CurrentState()->PenLocation());
WriteSetPenSize(canvas->CurrentState()->UnscaledPenSize());
WriteSetScale(canvas->CurrentState()->Scale());
WriteSetLineMode(canvas->CurrentState()->LineCapMode(),
canvas->CurrentState()->LineJoinMode(),
canvas->CurrentState()->MiterLimit());
//WriteSetPattern(*canvas->CurrentState()->GetPattern().GetInt8());
WriteSetDrawingMode(canvas->CurrentState()->GetDrawingMode());
WriteSetHighColor(view->CurrentState()->HighColor());
WriteSetLowColor(view->CurrentState()->LowColor());
WriteSetHighColor(canvas->CurrentState()->HighColor());
WriteSetLowColor(canvas->CurrentState()->LowColor());
ExitStateChange();
}

View File

@ -49,7 +49,7 @@ public:
void EnterStateChange();
void ExitStateChange();
void SyncState(View* view);
void SyncState(Canvas* canvas);
void WriteFontState(const ServerFont& font,
uint16 mask);