Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1130324c authored by Marissa Wall's avatar Marissa Wall
Browse files

blast: clang format LayerState.h

This patch reformats LayerState.h to match the current style
guidelines.

Test: manual
Change-Id: I89e25de7fb3cd8af58ffd04d5c3b14c742f8c9a8
parent fd668629
Loading
Loading
Loading
Loading
+93 −91
Original line number Diff line number Diff line
@@ -22,10 +22,10 @@

#include <utils/Errors.h>

#include <ui/Region.h>
#include <ui/Rect.h>
#include <gui/IGraphicBufferProducer.h>
#include <math/vec3.h>
#include <ui/Rect.h>
#include <ui/Region.h>

namespace android {

@@ -36,8 +36,6 @@ class ISurfaceComposerClient;
 * Used to communicate layer information between SurfaceFlinger and its clients.
 */
struct layer_state_t {


    enum {
        eLayerHidden = 0x01, // SURFACE_HIDDEN in SurfaceControl.java
        eLayerOpaque = 0x02, // SURFACE_OPAQUE
@@ -68,12 +66,20 @@ struct layer_state_t {

    layer_state_t()
          : what(0),
            x(0), y(0), z(0), w(0), h(0), layerStack(0),
            alpha(0), flags(0), mask(0),
            reserved(0), crop(Rect::INVALID_RECT),
            finalCrop(Rect::INVALID_RECT), frameNumber(0),
            overrideScalingMode(-1)
    {
            x(0),
            y(0),
            z(0),
            w(0),
            h(0),
            layerStack(0),
            alpha(0),
            flags(0),
            mask(0),
            reserved(0),
            crop(Rect::INVALID_RECT),
            finalCrop(Rect::INVALID_RECT),
            frameNumber(0),
            overrideScalingMode(-1) {
        matrix.dsdx = matrix.dtdy = 1.0f;
        matrix.dsdy = matrix.dtdx = 0.0f;
    }
@@ -128,7 +134,6 @@ struct ComposerState {
};

struct DisplayState {

    enum {
        eOrientationDefault = 0,
        eOrientation90 = 1,
@@ -160,8 +165,7 @@ struct DisplayState {
    status_t read(const Parcel& input);
};

static inline
int compare_type(const ComposerState& lhs, const ComposerState& rhs) {
static inline int compare_type(const ComposerState& lhs, const ComposerState& rhs) {
    if (lhs.client < rhs.client) return -1;
    if (lhs.client > rhs.client) return 1;
    if (lhs.state.surface < rhs.state.surface) return -1;
@@ -169,12 +173,10 @@ int compare_type(const ComposerState& lhs, const ComposerState& rhs) {
    return 0;
}

static inline
int compare_type(const DisplayState& lhs, const DisplayState& rhs) {
static inline int compare_type(const DisplayState& lhs, const DisplayState& rhs) {
    return compare_type(lhs.token, rhs.token);
}

}; // namespace android

#endif // ANDROID_SF_LAYER_STATE_H