gfx/gl/SurfaceTypes.cpp

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

     1 /* -*- Mode: c++; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40; -*- */
     2 /* This Source Code Form is subject to the terms of the Mozilla Public
     3  * License, v. 2.0. If a copy of the MPL was not distributed with this
     4  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     6 #include "SurfaceTypes.h"
     7 #include "mozilla/layers/ISurfaceAllocator.h"
     9 namespace mozilla {
    10 namespace gfx {
    12 SurfaceCaps::SurfaceCaps()
    13 {
    14   Clear();
    15 }
    17 SurfaceCaps::SurfaceCaps(const SurfaceCaps& other)
    18 {
    19   *this = other;
    20 }
    22 SurfaceCaps&
    23 SurfaceCaps::operator=(const SurfaceCaps& other)
    24 {
    25   any = other.any;
    26   color = other.color;
    27   alpha = other.alpha;
    28   bpp16 = other.bpp16;
    29   depth = other.depth;
    30   stencil = other.stencil;
    31   antialias = other.antialias;
    32   preserve = other.preserve;
    33   surfaceAllocator = other.surfaceAllocator;
    35   return *this;
    36 }
    38 void
    39 SurfaceCaps::Clear()
    40 {
    41   any = false;
    42   color = false;
    43   alpha = false;
    44   bpp16 = false;
    45   depth = false;
    46   stencil = false;
    47   antialias = false;
    48   preserve = false;
    49   surfaceAllocator = nullptr;
    50 }
    54 SurfaceCaps::~SurfaceCaps()
    55 {
    56 }
    58 }
    59 }

mercurial