diff --git a/interfaces/innerkits/dm/display_property.h b/interfaces/innerkits/dm/display_property.h index 7409c0d12d8f142e7e12ce354150b81d387f04e4..74a2fd732515b4c02ae1612493b7f929218c2e30 100644 --- a/interfaces/innerkits/dm/display_property.h +++ b/interfaces/innerkits/dm/display_property.h @@ -31,7 +31,6 @@ public: int height_; float xDpi_; float yDpi_; - // Surface surface_; }; } // namespace OHOS::Rosen diff --git a/interfaces/innerkits/wm/wm_common.h b/interfaces/innerkits/wm/wm_common.h index 453007fd5df3de23dbea407aa0856b0a1bf8c6ad..3d9a4e0e379be5ef6b0dc08d1c760b6270fc786e 100644 --- a/interfaces/innerkits/wm/wm_common.h +++ b/interfaces/innerkits/wm/wm_common.h @@ -16,8 +16,6 @@ #ifndef OHOS_ROSEN_WM_COMMON_H #define OHOS_ROSEN_WM_COMMON_H -#include - namespace OHOS { namespace Rosen { enum class WindowType : uint32_t { diff --git a/interfaces/kits/napi/window/native_window_module.cpp b/interfaces/kits/napi/window/native_window_module.cpp index 28f0e1cd7bd3a4862dbac2c897161de47e619ef9..ca5189cdfb4463f61aa46ed4873848a39706a90c 100644 --- a/interfaces/kits/napi/window/native_window_module.cpp +++ b/interfaces/kits/napi/window/native_window_module.cpp @@ -15,11 +15,11 @@ #include -#include "native_window_module.h" #include "window.h" #include "window_scene.h" #include "wm_common.h" #include "wm_napi_common.h" +#include "native_window_module.h" namespace OHOS { namespace Rosen { diff --git a/interfaces/kits/napi/window_stage_module.cpp b/interfaces/kits/napi/window_stage_module.cpp index b6ad1d3a6524d736975e43ebb38086998b678766..3b79e4c277b07e8fe756b17d99ba922185b84dfe 100644 --- a/interfaces/kits/napi/window_stage_module.cpp +++ b/interfaces/kits/napi/window_stage_module.cpp @@ -20,8 +20,7 @@ extern const char _binary_window_stage_js_end[]; extern const char _binary_window_stage_abc_start[]; extern const char _binary_window_stage_abc_end[]; -extern "C" __attribute__((constructor)) -void NAPI_application_WindowStage_AutoRegister() +extern "C" __attribute__((constructor)) void NAPI_application_WindowStage_AutoRegister() { auto moduleManager = NativeModuleManager::GetInstance(); NativeModule newModuleInfo = { diff --git a/wm/include/window_impl.h b/wm/include/window_impl.h index 4c748041b8e3d604ec7f908d3feab05bd8de90c6..98590c0962994182dcfb9396874d41cad9836767 100644 --- a/wm/include/window_impl.h +++ b/wm/include/window_impl.h @@ -35,7 +35,7 @@ class WindowImpl : public Window { if (uiContent_ != nullptr) { \ uiContent_->uiContentCb(); \ } \ - } while (0); + } while (0) public: WindowImpl(const sptr& option); diff --git a/wm/include/window_input_channel.h b/wm/include/window_input_channel.h index c58acb6f95343290038d635a32e887ec780aecbe..7fa6dcc6aa55cc7c8128c81b1a76cd475af1d806 100644 --- a/wm/include/window_input_channel.h +++ b/wm/include/window_input_channel.h @@ -12,12 +12,12 @@ * See the License for the specific language governing permissions and * limitations under the License. */ +#ifndef OHOS_WINDOW_INPUT_CHANNEL +#define OHOS_WINDOW_INPUT_CHANNEL #include #include "refbase.h" #include "vsync_station.h" -#ifndef OHOS_WINDOW_INPUT_CHANNEL -#define OHOS_WINDOW_INPUT_CHANNEL namespace OHOS { namespace Rosen { diff --git a/wm/src/window_stub.cpp b/wm/src/window_stub.cpp index 106f7165c1327b347840e179523586f81fb6abcf..dc23c5c7011a2048333fe0d3029e36b580258215 100644 --- a/wm/src/window_stub.cpp +++ b/wm/src/window_stub.cpp @@ -36,7 +36,7 @@ int WindowStub::OnRemoteRequest(uint32_t code, MessageParcel &data, MessageParce break; } case TRANS_ID_UPDATE_WINDOW_RECT: { - struct Rect rect{ data.ReadInt32(), data.ReadInt32(), data.ReadUint32(), data.ReadUint32() }; + struct Rect rect { data.ReadInt32(), data.ReadInt32(), data.ReadUint32(), data.ReadUint32() }; UpdateWindowRect(rect); break; } diff --git a/wmserver/include/window_manager_proxy.h b/wmserver/include/window_manager_proxy.h index c0f2d21d48503611f52822deaf2f0ebed4bb263b..8a7e7992659d5b3981255a01b660880fc146d030 100644 --- a/wmserver/include/window_manager_proxy.h +++ b/wmserver/include/window_manager_proxy.h @@ -16,8 +16,8 @@ #ifndef OHOS_WINDOW_MANAGER_PROXY_H #define OHOS_WINDOW_MANAGER_PROXY_H -#include "window_manager_interface.h" #include +#include "window_manager_interface.h" namespace OHOS { namespace Rosen { diff --git a/wmserver/include/window_manager_stub.h b/wmserver/include/window_manager_stub.h index 4fa7df0aa9b7335b9d08cbae98396157f10e7cb3..1d124af888ca8f69ffd544c74c654293303d18e4 100644 --- a/wmserver/include/window_manager_stub.h +++ b/wmserver/include/window_manager_stub.h @@ -16,8 +16,9 @@ #ifndef OHOS_WINDOW_MANAGER_STUB_H #define OHOS_WINDOW_MANAGER_STUB_H -#include "window_manager_interface.h" #include +#include "window_manager_interface.h" + namespace OHOS { namespace Rosen { class WindowManagerStub : public IRemoteStub { diff --git a/wmserver/src/window_inner_manager.cpp b/wmserver/src/window_inner_manager.cpp index b8a90f29f85448ec1ffaf2ce5aa1c98562cccab7..ce4688f88e2073788c3d5d0dbc301f4e880dfb37 100644 --- a/wmserver/src/window_inner_manager.cpp +++ b/wmserver/src/window_inner_manager.cpp @@ -236,4 +236,4 @@ void WindowInnerManager::Init() WLOGFI("Inner window manager thread create success"); } } -} \ No newline at end of file +} diff --git a/wmtest/frameworks/inative_test.h b/wmtest/frameworks/inative_test.h index 4a0ade056caefcb8ecb711a31d6338853cdb0437..640dd9ff0965503c80962f09d0e782aee085d58b 100644 --- a/wmtest/frameworks/inative_test.h +++ b/wmtest/frameworks/inative_test.h @@ -16,10 +16,8 @@ #ifndef OHOS_ROSEN_INATIVE_TEST_H #define OHOS_ROSEN_INATIVE_TEST_H -#include #include #include -#include namespace OHOS::Rosen { class INativeTest; diff --git a/wmtest/test/wm_native_test.cpp b/wmtest/test/wm_native_test.cpp index 6d63a5e21b9fa82c02472525b3d6a2a4f532e334..d325d84c6d16ab1ba022b6b32cdc28c09b3a3971 100644 --- a/wmtest/test/wm_native_test.cpp +++ b/wmtest/test/wm_native_test.cpp @@ -17,7 +17,7 @@ #include #include -#include +#include #include "window.h" #include "window_life_cycle_interface.h" #include "window_option.h" @@ -65,10 +65,11 @@ void WMNativeTest::Run(int32_t argc, const char **argv) return; } - while(true) { + while (true) { scene->GoForeground(); - sleep(3); + sleep(3); // Sleep for 3 seconds scene->GoBackground(); - sleep(3); + sleep(3); // Sleep for 3 seconds } } +