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

Commit 4810866e authored by Prabir Pradhan's avatar Prabir Pradhan
Browse files

inputflinger: Use #pragma once instead of explicit define guards

The #pragma once directive is commonly used by modern cpp code, and
support for its use in Andorid is proposed in go/droidcppstyle.

Bug: 245989146
Test: Build, Presubmit
Change-Id: Id257f056972b753f505afe1d253d306bb1824098
parent 739dca4e
Loading
Loading
Loading
Loading
+1 −4
Original line number Diff line number Diff line
@@ -14,8 +14,7 @@
 * limitations under the License.
 */

#ifndef _UI_INPUT_BLOCKING_QUEUE_H
#define _UI_INPUT_BLOCKING_QUEUE_H
#pragma once

#include "android-base/thread_annotations.h"
#include <condition_variable>
@@ -106,6 +105,4 @@ private:
    std::vector<T> mQueue GUARDED_BY(mLock);
};


} // namespace android
#endif
+1 −4
Original line number Diff line number Diff line
@@ -14,8 +14,7 @@
 * limitations under the License.
 */

#ifndef _UI_INPUT_MANAGER_H
#define _UI_INPUT_MANAGER_H
#pragma once

/**
 * Native input manager.
@@ -130,5 +129,3 @@ private:
};

} // namespace android

#endif // _UI_INPUT_MANAGER_H
+1 −3
Original line number Diff line number Diff line
@@ -14,8 +14,7 @@
 * limitations under the License.
 */

#ifndef _UI_INPUT_CLASSIFIER_H
#define _UI_INPUT_CLASSIFIER_H
#pragma once

#include <android-base/thread_annotations.h>
#include <future>
@@ -288,4 +287,3 @@ private:
};

} // namespace android
#endif
+1 −4
Original line number Diff line number Diff line
@@ -14,8 +14,7 @@
 * limitations under the License.
 */

#ifndef _UI_INPUT_INPUTDISPATCHER_ANRTRACKER_H
#define _UI_INPUT_INPUTDISPATCHER_ANRTRACKER_H
#pragma once

#include <binder/IBinder.h>
#include <utils/Timers.h>
@@ -56,5 +55,3 @@ private:
};

} // namespace android::inputdispatcher

#endif // _UI_INPUT_INPUTDISPATCHER_ANRTRACKER_H
+1 −4
Original line number Diff line number Diff line
@@ -14,8 +14,7 @@
 * limitations under the License.
 */

#ifndef _UI_INPUT_INPUTDISPATCHER_CANCELLATIONOPTIONS_H
#define _UI_INPUT_INPUTDISPATCHER_CANCELLATIONOPTIONS_H
#pragma once

#include <utils/BitSet.h>
#include <optional>
@@ -55,5 +54,3 @@ struct CancelationOptions {

} // namespace inputdispatcher
} // namespace android

#endif // _UI_INPUT_INPUTDISPATCHER_CANCELLATIONOPTIONS_H
Loading