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

Commit 65d47878 authored by Chih-Hung Hsieh's avatar Chih-Hung Hsieh
Browse files

Fix google-explicit-constructor warnings in gui and ui.

* Add explicit keyword to conversion constructors.
Bug: 28341362
Test: build with WITH_TIDY=1

Change-Id: I476ad1e9a4d47acb11bf4a87ad8baa855f441417
parent 0322a717
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -60,7 +60,7 @@ public:
    // weak references.
    // weak references.
    class ProxyConsumerListener : public BnConsumerListener {
    class ProxyConsumerListener : public BnConsumerListener {
    public:
    public:
        ProxyConsumerListener(const wp<ConsumerListener>& consumerListener);
        explicit ProxyConsumerListener(const wp<ConsumerListener>& consumerListener);
        virtual ~ProxyConsumerListener();
        virtual ~ProxyConsumerListener();
        virtual void onFrameAvailable(const BufferItem& item) override;
        virtual void onFrameAvailable(const BufferItem& item) override;
        virtual void onFrameReplaced(const BufferItem& item) override;
        virtual void onFrameReplaced(const BufferItem& item) override;
+1 −1
Original line number Original line Diff line number Diff line
@@ -94,7 +94,7 @@ protected:
    // buffers from the given IGraphicBufferConsumer.
    // buffers from the given IGraphicBufferConsumer.
    // The controlledByApp flag indicates that this consumer is under the application's
    // The controlledByApp flag indicates that this consumer is under the application's
    // control.
    // control.
    ConsumerBase(const sp<IGraphicBufferConsumer>& consumer, bool controlledByApp = false);
    explicit ConsumerBase(const sp<IGraphicBufferConsumer>& consumer, bool controlledByApp = false);


    // onLastStrongRef gets called by RefBase just before the dtor of the most
    // onLastStrongRef gets called by RefBase just before the dtor of the most
    // derived class.  It is used to clean up the buffers so that ConsumerBase
    // derived class.  It is used to clean up the buffers so that ConsumerBase
+1 −1
Original line number Original line Diff line number Diff line
@@ -292,7 +292,7 @@ public:


    struct QueueBufferInput : public Flattenable<QueueBufferInput> {
    struct QueueBufferInput : public Flattenable<QueueBufferInput> {
        friend class Flattenable<QueueBufferInput>;
        friend class Flattenable<QueueBufferInput>;
        inline QueueBufferInput(const Parcel& parcel);
        explicit inline QueueBufferInput(const Parcel& parcel);
        // timestamp - a monotonically increasing value in nanoseconds
        // timestamp - a monotonically increasing value in nanoseconds
        // isAutoTimestamp - if the timestamp was synthesized at queue time
        // isAutoTimestamp - if the timestamp was synthesized at queue time
        // dataSpace - description of the contents, interpretation depends on format
        // dataSpace - description of the contents, interpretation depends on format
+1 −1
Original line number Original line Diff line number Diff line
@@ -66,7 +66,7 @@ public:
     * the controlledByApp flag indicates that this Surface (producer) is
     * the controlledByApp flag indicates that this Surface (producer) is
     * controlled by the application. This flag is used at connect time.
     * controlled by the application. This flag is used at connect time.
     */
     */
    Surface(const sp<IGraphicBufferProducer>& bufferProducer, bool controlledByApp = false);
    explicit Surface(const sp<IGraphicBufferProducer>& bufferProducer, bool controlledByApp = false);


    /* getIGraphicBufferProducer() returns the IGraphicBufferProducer this
    /* getIGraphicBufferProducer() returns the IGraphicBufferProducer this
     * Surface was created with. Usually it's an error to use the
     * Surface was created with. Usually it's an error to use the
+1 −1
Original line number Original line Diff line number Diff line
@@ -53,7 +53,7 @@ public:
    // Construct a new Fence object to manage a given fence file descriptor.
    // Construct a new Fence object to manage a given fence file descriptor.
    // When the new Fence object is destructed the file descriptor will be
    // When the new Fence object is destructed the file descriptor will be
    // closed.
    // closed.
    Fence(int fenceFd);
    explicit Fence(int fenceFd);


    // Check whether the Fence has an open fence file descriptor. Most Fence
    // Check whether the Fence has an open fence file descriptor. Most Fence
    // methods treat an invalid file descriptor just like a valid fence that
    // methods treat an invalid file descriptor just like a valid fence that