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

Commit c91f9afe authored by Peiyong Lin's avatar Peiyong Lin Committed by Android (Google) Code Review
Browse files

Merge "Add proper namespace to GraphicTypes."

parents da15f137 9f034475
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -43,6 +43,8 @@

namespace android {

using ui::ColorMode;

class BpSurfaceComposer : public BpInterface<ISurfaceComposer>
{
public:
+2 −0
Original line number Diff line number Diff line
@@ -44,6 +44,8 @@

namespace android {

using ui::ColorMode;

Surface::Surface(const sp<IGraphicBufferProducer>& bufferProducer, bool controlledByApp)
      : mGraphicBufferProducer(bufferProducer),
        mCrop(Rect::EMPTY_RECT),
+2 −0
Original line number Diff line number Diff line
@@ -43,6 +43,8 @@
#include <private/gui/ComposerService.h>

namespace android {

using ui::ColorMode;
// ---------------------------------------------------------------------------

ANDROID_SINGLETON_STATIC_INSTANCE(ComposerService);
+4 −4
Original line number Diff line number Diff line
@@ -30,7 +30,7 @@
#include <ui/FrameStats.h>
#include <ui/PixelFormat.h>
#include <ui/GraphicBuffer.h>
#include <ui/GraphicsTypes.h>
#include <ui/GraphicTypes.h>

#include <vector>

@@ -161,10 +161,10 @@ public:
    virtual status_t setActiveConfig(const sp<IBinder>& display, int id) = 0;

    virtual status_t getDisplayColorModes(const sp<IBinder>& display,
            Vector<ColorMode>* outColorModes) = 0;
    virtual ColorMode getActiveColorMode(const sp<IBinder>& display) = 0;
            Vector<ui::ColorMode>* outColorModes) = 0;
    virtual ui::ColorMode getActiveColorMode(const sp<IBinder>& display) = 0;
    virtual status_t setActiveColorMode(const sp<IBinder>& display,
            ColorMode colorMode) = 0;
            ui::ColorMode colorMode) = 0;

    /* Capture the specified screen. requires READ_FRAME_BUFFER permission
     * This function will fail if there is a secure window on screen.
+5 −4
Original line number Diff line number Diff line
@@ -29,7 +29,7 @@
#include <utils/threads.h>

#include <ui/FrameStats.h>
#include <ui/GraphicsTypes.h>
#include <ui/GraphicTypes.h>
#include <ui/PixelFormat.h>

#include <gui/CpuConsumer.h>
@@ -89,13 +89,14 @@ public:

    // Gets the list of supported color modes for the given display
    static status_t getDisplayColorModes(const sp<IBinder>& display,
            Vector<ColorMode>* outColorModes);
            Vector<ui::ColorMode>* outColorModes);

    // Gets the active color mode for the given display
    static ColorMode getActiveColorMode(const sp<IBinder>& display);
    static ui::ColorMode getActiveColorMode(const sp<IBinder>& display);

    // Sets the active color mode for the given display
    static status_t setActiveColorMode(const sp<IBinder>& display, ColorMode colorMode);
    static status_t setActiveColorMode(const sp<IBinder>& display,
            ui::ColorMode colorMode);

    /* Triggers screen on/off or low power mode and waits for it to complete */
    static void setDisplayPowerMode(const sp<IBinder>& display, int mode);
Loading