diff --git a/native/CMakeLists.txt b/native/CMakeLists.txt index dcc7e3f7d2..a6a1b45666 100644 --- a/native/CMakeLists.txt +++ b/native/CMakeLists.txt @@ -1778,7 +1778,6 @@ cocos_source_files( cocos/core/Any.h cocos/core/ArrayBuffer.h - cocos/core/CoreModuleHeader.h cocos/core/DataView.h cocos/core/DataView.cpp # cocos/core/Director.cpp @@ -1945,12 +1944,6 @@ cocos_source_files( cocos/core/event/EventTypesToJS.cpp # cocos/core/event/Event.cpp # cocos/core/event/Event.h - cocos/core/event/EventModuleHeader.h - cocos/core/event/EventTarget.cpp - cocos/core/event/EventTarget.h - cocos/core/event/EventTargetFactory.cpp - cocos/core/event/EventTargetFactory.h - # cocos/core/scene-graph/Find.cpp # cocos/core/scene-graph/Find.h cocos/core/scene-graph/Layers.h diff --git a/native/cocos/application/BaseGame.h b/native/cocos/application/BaseGame.h index bb412446b2..d4e16bd4ef 100644 --- a/native/cocos/application/BaseGame.h +++ b/native/cocos/application/BaseGame.h @@ -22,6 +22,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ****************************************************************************/ +#pragma once #include #include "CocosApplication.h" diff --git a/native/cocos/audio/android/utils/Utils.h b/native/cocos/audio/android/utils/Utils.h index dbed904d18..7995dfe972 100644 --- a/native/cocos/audio/android/utils/Utils.h +++ b/native/cocos/audio/android/utils/Utils.h @@ -23,6 +23,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ****************************************************************************/ +#pragma once #include "base/std/container/string.h" namespace cc { diff --git a/native/cocos/audio/include/Export.h b/native/cocos/audio/include/Export.h index a3819ee2d1..a3b526f09a 100644 --- a/native/cocos/audio/include/Export.h +++ b/native/cocos/audio/include/Export.h @@ -25,8 +25,7 @@ THE SOFTWARE. ****************************************************************************/ -#ifndef __EXPORT_COMMON__ -#define __EXPORT_COMMON__ +#pragma once #if defined(SHP) #include @@ -51,4 +50,3 @@ #endif #endif -#endif // end of __EXPORT_COMMON__ diff --git a/native/cocos/base/job-system/JobSystem.h b/native/cocos/base/job-system/JobSystem.h index 3a4def2c0e..8888854a37 100644 --- a/native/cocos/base/job-system/JobSystem.h +++ b/native/cocos/base/job-system/JobSystem.h @@ -23,6 +23,8 @@ THE SOFTWARE. ****************************************************************************/ +#pragma once + #if CC_USE_JOB_SYSTEM_TASKFLOW #include "job-system-taskflow/TFJobGraph.h" #include "job-system-taskflow/TFJobSystem.h" diff --git a/native/cocos/bindings/jswrapper/v8/MissingSymbols.h b/native/cocos/bindings/jswrapper/v8/MissingSymbols.h index a68086020c..2da7b4eedf 100644 --- a/native/cocos/bindings/jswrapper/v8/MissingSymbols.h +++ b/native/cocos/bindings/jswrapper/v8/MissingSymbols.h @@ -23,6 +23,8 @@ THE SOFTWARE. ****************************************************************************/ +#pragma once + #include #include #include diff --git a/native/cocos/cocos.h b/native/cocos/cocos.h index 29baa35b9a..ec3edc74cc 100644 --- a/native/cocos/cocos.h +++ b/native/cocos/cocos.h @@ -23,6 +23,8 @@ THE SOFTWARE. ****************************************************************************/ +#pragma once + // public headers for user application #include "application/ApplicationManager.h" diff --git a/native/cocos/core/CoreModuleHeader.h b/native/cocos/core/CoreModuleHeader.h deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/native/cocos/core/event/EventModuleHeader.h b/native/cocos/core/event/EventModuleHeader.h deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/native/cocos/core/event/EventTarget.cpp b/native/cocos/core/event/EventTarget.cpp deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/native/cocos/core/event/EventTarget.h b/native/cocos/core/event/EventTarget.h deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/native/cocos/core/event/EventTargetFactory.cpp b/native/cocos/core/event/EventTargetFactory.cpp deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/native/cocos/core/event/EventTargetFactory.h b/native/cocos/core/event/EventTargetFactory.h deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/native/cocos/core/scene-graph/SceneGraphModuleHeader.h b/native/cocos/core/scene-graph/SceneGraphModuleHeader.h index 1fb9af1d00..9847e03b59 100644 --- a/native/cocos/core/scene-graph/SceneGraphModuleHeader.h +++ b/native/cocos/core/scene-graph/SceneGraphModuleHeader.h @@ -23,6 +23,8 @@ THE SOFTWARE. ****************************************************************************/ +#pragma once + //#include "core/scene-graph/ComponentScheduler.h" //#include "core/scene-graph/Find.h" #include "core/scene-graph/Layers.h" diff --git a/native/cocos/platform/mac/AppDelegate.h b/native/cocos/platform/mac/AppDelegate.h index 37a15c3f23..70cc630a1d 100644 --- a/native/cocos/platform/mac/AppDelegate.h +++ b/native/cocos/platform/mac/AppDelegate.h @@ -23,6 +23,8 @@ THE SOFTWARE. ****************************************************************************/ +#pragma once + #import @interface AppDelegate : NSObject diff --git a/native/cocos/platform/mac/KeyCodeHelper.h b/native/cocos/platform/mac/KeyCodeHelper.h index 275613fa51..abca2d2970 100644 --- a/native/cocos/platform/mac/KeyCodeHelper.h +++ b/native/cocos/platform/mac/KeyCodeHelper.h @@ -23,9 +23,10 @@ THE SOFTWARE. ****************************************************************************/ -#import "cocos/bindings/event/EventDispatcher.h" #pragma once +#import "cocos/bindings/event/EventDispatcher.h" + extern int translateKeycode(int); extern void updateModifierKeyState(int keyCodeInWeb); extern cc::KeyboardEvent::Action getModifierKeyAction(int keyCodeInWeb); diff --git a/native/cocos/platform/mac/View.h b/native/cocos/platform/mac/View.h index e49a72b8b5..282e355d26 100644 --- a/native/cocos/platform/mac/View.h +++ b/native/cocos/platform/mac/View.h @@ -23,6 +23,8 @@ THE SOFTWARE. ****************************************************************************/ +#pragma once + #import #import diff --git a/native/cocos/platform/mac/ViewController.h b/native/cocos/platform/mac/ViewController.h index f716829646..56a33ac433 100644 --- a/native/cocos/platform/mac/ViewController.h +++ b/native/cocos/platform/mac/ViewController.h @@ -23,6 +23,8 @@ THE SOFTWARE. ****************************************************************************/ +#pragma once + #import #import diff --git a/native/cocos/renderer/pipeline/custom/test/test.h b/native/cocos/renderer/pipeline/custom/test/test.h index b32a9a9166..30ec30673e 100644 --- a/native/cocos/renderer/pipeline/custom/test/test.h +++ b/native/cocos/renderer/pipeline/custom/test/test.h @@ -22,6 +22,8 @@ THE SOFTWARE. ****************************************************************************/ +#pragma once + #include #include #include diff --git a/native/tests/sebind-tests/common/Classes/demo/sebind_fruits.h b/native/tests/sebind-tests/common/Classes/demo/sebind_fruits.h index b3bd639322..4d0ec4f543 100644 --- a/native/tests/sebind-tests/common/Classes/demo/sebind_fruits.h +++ b/native/tests/sebind-tests/common/Classes/demo/sebind_fruits.h @@ -1,3 +1,5 @@ +#pragma once + #include "bindings/jswrapper/SeApi.h" #include "bindings/manual/jsb_conversions.h" #include "bindings/manual/jsb_global.h" diff --git a/templates/ios/AppDelegate.h b/templates/ios/AppDelegate.h index 5e8e48f50c..d91c20ec3f 100644 --- a/templates/ios/AppDelegate.h +++ b/templates/ios/AppDelegate.h @@ -26,6 +26,8 @@ you. THE SOFTWARE. ****************************************************************************/ +#pragma once + #import "platform/ios/AppDelegateBridge.h" #import diff --git a/templates/ios/ViewController.h b/templates/ios/ViewController.h index abf7b9555b..caeb7ee98c 100644 --- a/templates/ios/ViewController.h +++ b/templates/ios/ViewController.h @@ -26,6 +26,8 @@ you. THE SOFTWARE. ****************************************************************************/ +#pragma once + #import @interface ViewController : UIViewController diff --git a/templates/ios/service/SDKWrapper.h b/templates/ios/service/SDKWrapper.h index 9a3ff770d0..e933342c04 100644 --- a/templates/ios/service/SDKWrapper.h +++ b/templates/ios/service/SDKWrapper.h @@ -24,6 +24,8 @@ you. THE SOFTWARE. ****************************************************************************/ +#pragma once + #import #import NS_ASSUME_NONNULL_BEGIN