/foundation/window/window_manager/wmserver/include/utils/ |
H A D | window_manager_service_utils.h | 32 const std::map<Orientation, DisplayOrientation> WINDOW_TO_DISPLAY_ORIENTATION_MAP { 33 {Orientation::VERTICAL, DisplayOrientation::PORTRAIT }, 34 {Orientation::HORIZONTAL, DisplayOrientation::LANDSCAPE }, 35 {Orientation::REVERSE_VERTICAL, DisplayOrientation::PORTRAIT_INVERTED }, 36 {Orientation::REVERSE_HORIZONTAL, DisplayOrientation::LANDSCAPE_INVERTED }, 43 static bool IsFixedOrientation(Orientation orientation, WindowMode mode, uint32_t flags); 44 static bool IsExpectedRotateLandscapeWindow(Orientation requestOrientation, 46 static bool IsExpectedRotatableWindow(Orientation requestOrientation, 48 static bool IsExpectedRotatableWindow(Orientation requestOrientation,
|
/foundation/window/window_manager/dmserver/test/unittest/ |
H A D | screen_rotation_controller_test.cpp | 134 Orientation orientation = Orientation::SENSOR; in HWTEST_F() 137 orientation = Orientation::SENSOR_VERTICAL; in HWTEST_F() 140 orientation = Orientation::SENSOR_HORIZONTAL; in HWTEST_F() 143 orientation = Orientation::UNSPECIFIED; in HWTEST_F() 149 orientation = Orientation::AUTO_ROTATION_RESTRICTED; in HWTEST_F() 155 orientation = Orientation::AUTO_ROTATION_PORTRAIT_RESTRICTED; in HWTEST_F() 161 orientation = Orientation::AUTO_ROTATION_LANDSCAPE_RESTRICTED; in HWTEST_F() 167 orientation = Orientation::VERTICAL; in HWTEST_F() 234 ASSERT_EQ(false, ScreenRotationController::IsSensorRelatedOrientation(Orientation in HWTEST_F() [all...] |
/foundation/window/window_manager/previewer/src/ |
H A D | window_model.cpp | 33 Rosen::Orientation PreviewerWindow::TransOrientation(Previewer::Orientation orientation) in TransOrientation() 35 if (orientation == Previewer::Orientation::PORTRAIT) { in TransOrientation() 36 return Rosen::Orientation::VERTICAL; in TransOrientation() 37 } else if (orientation == Previewer::Orientation::LANDSCAPE) { in TransOrientation() 38 return Rosen::Orientation::HORIZONTAL; in TransOrientation() 41 return Rosen::Orientation::UNSPECIFIED; in TransOrientation()
|
/foundation/window/window_manager/wmserver/src/utils/ |
H A D | window_manager_service_utils.cpp | 21 bool WmsUtils::IsFixedOrientation(Orientation orientation, WindowMode mode, uint32_t flags) in IsFixedOrientation() 32 if (orientation > Orientation::REVERSE_HORIZONTAL) { in IsFixedOrientation() 35 if (orientation < Orientation::VERTICAL) { in IsFixedOrientation() 41 bool WmsUtils::IsExpectedRotateLandscapeWindow(Orientation requestOrientation, in IsExpectedRotateLandscapeWindow() 44 if (requestOrientation != Orientation::HORIZONTAL && requestOrientation != Orientation::REVERSE_HORIZONTAL) { in IsExpectedRotateLandscapeWindow() 50 bool WmsUtils::IsExpectedRotatableWindow(Orientation requestOrientation, in IsExpectedRotatableWindow() 59 bool WmsUtils::IsExpectedRotatableWindow(Orientation requestOrientation, in IsExpectedRotatableWindow()
|
/foundation/window/window_manager/wmserver/test/unittest/ |
H A D | window_manager_service_utils_test.cpp | 55 bool ret = WmsUtils::IsFixedOrientation(Orientation::HORIZONTAL, WindowMode::WINDOW_MODE_FULLSCREEN, 0); in HWTEST_F() 61 * @tc.desc: more then Orientation::REVERSE_HORIZONTAL 66 bool ret = WmsUtils::IsFixedOrientation(Orientation::SENSOR, WindowMode::WINDOW_MODE_FULLSCREEN, 0); in HWTEST_F() 72 * @tc.desc: less then Orientation::VERTICAL 77 bool ret = WmsUtils::IsFixedOrientation(Orientation::UNSPECIFIED, WindowMode::WINDOW_MODE_FULLSCREEN, 0); in HWTEST_F() 88 bool ret = WmsUtils::IsFixedOrientation(Orientation::HORIZONTAL, WindowMode::WINDOW_MODE_FULLSCREEN, in HWTEST_F() 100 bool ret = WmsUtils::IsFixedOrientation(Orientation::HORIZONTAL, WindowMode::WINDOW_MODE_FLOATING, 0); in HWTEST_F() 111 bool ret = WmsUtils::IsExpectedRotateLandscapeWindow(Orientation::VERTICAL, DisplayOrientation::PORTRAIT, 0); in HWTEST_F() 122 bool ret = WmsUtils::IsExpectedRotatableWindow(Orientation::VERTICAL, DisplayOrientation::PORTRAIT, in HWTEST_F() 134 bool ret = WmsUtils::IsExpectedRotatableWindow(Orientation in HWTEST_F() [all...] |
/foundation/window/window_manager/dmserver/src/ |
H A D | screen_rotation_controller.cpp | 33 Orientation ScreenRotationController::lastOrientationType_ = Orientation::UNSPECIFIED; 69 Orientation currentOrientation = GetPreferredOrientation(); in SetScreenRotationLocked() 91 Orientation orientation = GetPreferredOrientation(); in HandleSensorEventInput() 118 Orientation ScreenRotationController::GetPreferredOrientation() in GetPreferredOrientation() 123 return Orientation::UNSPECIFIED; in GetPreferredOrientation() 129 Orientation requestedOrientation, DeviceRotation sensorRotationConverted) in CalcTargetDisplayRotation() 132 case Orientation::SENSOR: { in CalcTargetDisplayRotation() 136 case Orientation::SENSOR_VERTICAL: { in CalcTargetDisplayRotation() 139 case Orientation in CalcTargetDisplayRotation() [all...] |
/foundation/window/window_manager/interfaces/kits/napi/window_runtime/window_napi/ |
H A D | js_window_utils.h | 200 const std::map<ApiOrientation, Orientation> JS_TO_NATIVE_ORIENTATION_MAP {
201 {ApiOrientation::UNSPECIFIED, Orientation::UNSPECIFIED },
202 {ApiOrientation::PORTRAIT, Orientation::VERTICAL },
203 {ApiOrientation::LANDSCAPE, Orientation::HORIZONTAL },
204 {ApiOrientation::PORTRAIT_INVERTED, Orientation::REVERSE_VERTICAL },
205 {ApiOrientation::LANDSCAPE_INVERTED, Orientation::REVERSE_HORIZONTAL },
206 {ApiOrientation::AUTO_ROTATION, Orientation::SENSOR },
207 {ApiOrientation::AUTO_ROTATION_PORTRAIT, Orientation::SENSOR_VERTICAL },
208 {ApiOrientation::AUTO_ROTATION_LANDSCAPE, Orientation::SENSOR_HORIZONTAL },
209 {ApiOrientation::AUTO_ROTATION_RESTRICTED, Orientation [all...] |
/foundation/window/window_manager/dmserver/include/ |
H A D | screen_rotation_controller.h | 52 static void ProcessOrientationSwitch(Orientation orientation, bool withAnimation); 61 static Orientation GetPreferredOrientation(); 63 static Rotation CalcTargetDisplayRotation(Orientation requestedOrientation, 72 static bool IsSensorRelatedOrientation(Orientation orientation); 80 static void ProcessSwitchToSensorRelatedOrientation(Orientation orientation, DeviceRotation deviceRotation); 81 static void ProcessSwitchToSensorUnrelatedOrientation(Orientation orientation, bool withAnimation); 91 static Orientation lastOrientationType_;
|
H A D | abstract_screen.h | 46 bool SetOrientation(Orientation orientation);
47 Rotation CalcRotation(Orientation orientation) const;
87 Orientation orientation_ { Orientation::UNSPECIFIED };
89 Orientation screenRequestedOrientation_ { Orientation::UNSPECIFIED };
|
H A D | abstract_display.h | 55 Orientation GetOrientation() const;
67 void SetOrientation(Orientation orientation);
85 Orientation orientation_ { Orientation::UNSPECIFIED };
|
/foundation/window/window_manager/previewer/include/ |
H A D | window_model.h | 23 enum class Orientation : int32_t { class 50 Orientation orientation = Orientation::PORTRAIT; // orientation 63 static Rosen::Orientation TransOrientation(Previewer::Orientation orientation);
|
H A D | window_option.h | 197 void SetRequestedOrientation(Orientation orientation); 337 Orientation GetRequestedOrientation() const; 435 Orientation requestedOrientation_ { Orientation::UNSPECIFIED };
|
/foundation/window/window_manager/test/systemtest/wms/ |
H A D | window_rotation_test.cpp | 141 fullInfo_.orientation_ = Orientation::UNSPECIFIED; in HWTEST_F() 151 fullWindow->SetRequestedOrientation(Orientation::REVERSE_HORIZONTAL); in HWTEST_F() 153 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, fullWindow->GetRequestedOrientation()); in HWTEST_F() 160 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, screen->GetOrientation()); in HWTEST_F() 161 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, display->GetOrientation()); in HWTEST_F() 177 fullInfo_.orientation_ = Orientation::REVERSE_HORIZONTAL; in HWTEST_F() 188 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, fullWindow->GetRequestedOrientation()); in HWTEST_F() 194 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, screen->GetOrientation()); in HWTEST_F() 195 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, display->GetOrientation()); in HWTEST_F() 200 screen->SetOrientation(Orientation in HWTEST_F() [all...] |
/foundation/window/window_manager/window_scene/session/screen/include/ |
H A D | screen_property.h | 101 void SetOrientation(Orientation orientation); 102 Orientation GetOrientation() const; 136 void SetScreenRequestedOrientation(Orientation orientation); 137 Orientation GetScreenRequestedOrientation() const; 180 Orientation orientation_ { Orientation::UNSPECIFIED }; 183 Orientation screenRequestedOrientation_ { Orientation::UNSPECIFIED };
|
/foundation/window/window_manager/wmserver/src/ |
H A D | starting_window.cpp | 38 const std::map<OHOS::AppExecFwk::DisplayOrientation, Orientation> ABILITY_TO_WMS_ORIENTATION_MAP { 39 {OHOS::AppExecFwk::DisplayOrientation::UNSPECIFIED, Orientation::UNSPECIFIED}, 40 {OHOS::AppExecFwk::DisplayOrientation::LANDSCAPE, Orientation::HORIZONTAL}, 41 {OHOS::AppExecFwk::DisplayOrientation::PORTRAIT, Orientation::VERTICAL}, 42 {OHOS::AppExecFwk::DisplayOrientation::FOLLOWRECENT, Orientation::LOCKED}, 43 {OHOS::AppExecFwk::DisplayOrientation::LANDSCAPE_INVERTED, Orientation::REVERSE_HORIZONTAL}, 44 {OHOS::AppExecFwk::DisplayOrientation::PORTRAIT_INVERTED, Orientation::REVERSE_VERTICAL}, 45 {OHOS::AppExecFwk::DisplayOrientation::AUTO_ROTATION, Orientation::SENSOR}, 46 {OHOS::AppExecFwk::DisplayOrientation::AUTO_ROTATION_LANDSCAPE, Orientation::SENSOR_HORIZONTAL}, 47 {OHOS::AppExecFwk::DisplayOrientation::AUTO_ROTATION_PORTRAIT, Orientation [all...] |
/foundation/arkui/ace_engine/adapter/ohos/entrance/ |
H A D | ace_viewport_config.h | 36 config_.Orientation() == other.config_.Orientation() && in operator ==() 48 config_.Orientation() != other.config_.Orientation() || in operator !=()
|
/foundation/window/window_manager/test/fuzztest/dms/screen_fuzzer/ |
H A D | screen_fuzzer.cpp | 66 startPos += GetObject<Orientation>(info->orientation_, data + startPos, size - startPos); in CreateScreenInfo() 77 Orientation orientation; in ScreenFuzzTest() 87 GetObject<Orientation>(orientation, data + startPos, size - startPos); in ScreenFuzzTest() 92 screen->SetOrientation(Orientation::UNSPECIFIED); in ScreenFuzzTest() 103 Orientation orientation; in ScreenFuzzTestNoDisplay() 115 GetObject<Orientation>(orientation, data + startPos, size - startPos); in ScreenFuzzTestNoDisplay() 120 screen->SetOrientation(Orientation::UNSPECIFIED); in ScreenFuzzTestNoDisplay()
|
/foundation/window/window_manager/interfaces/innerkits/wm/ |
H A D | window_option.h | 196 void SetRequestedOrientation(Orientation orientation); 392 Orientation GetRequestedOrientation() const; 517 Orientation requestedOrientation_ { Orientation::UNSPECIFIED };
|
/foundation/window/window_manager/utils/include/ |
H A D | screen_info.h | 52 DEFINE_VAR_DEFAULT_FUNC_GET_SET(Orientation, Orientation, orientation, Orientation::UNSPECIFIED);
|
H A D | display_info.h | 56 DEFINE_VAR_DEFAULT_FUNC_GET_SET(Orientation, Orientation, orientation, Orientation::UNSPECIFIED);
|
/foundation/multimodalinput/input/test/unittest/common/include/ |
H A D | window_utils_test.h | 47 Rosen::Orientation orientation_ { Rosen::Orientation::UNSPECIFIED };
|
/foundation/window/window_manager/window_scene/test/unittest/ |
H A D | window_session_property_test.cpp | 97 Orientation orientation = Orientation::REVERSE_HORIZONTAL; in HWTEST_F() 100 Orientation ret = property->GetRequestedOrientation(); in HWTEST_F() 103 property->SetRequestedOrientation(Orientation::AUTO_ROTATION_UNSPECIFIED); in HWTEST_F() 104 Orientation ret1 = property->GetRequestedOrientation(); in HWTEST_F() 105 ASSERT_EQ(ret1, Orientation::AUTO_ROTATION_UNSPECIFIED); in HWTEST_F() 107 property->SetRequestedOrientation(Orientation::USER_ROTATION_PORTRAIT); in HWTEST_F() 108 Orientation ret2 = property->GetRequestedOrientation(); in HWTEST_F() 109 ASSERT_EQ(ret2, Orientation::USER_ROTATION_PORTRAIT); in HWTEST_F() 111 property->SetRequestedOrientation(Orientation in HWTEST_F() [all...] |
H A D | scene_session_test.cpp | 314 Orientation ori = Orientation::UNSPECIFIED; in HWTEST_F() 316 Orientation ret = scensession->GetRequestedOrientation(); in HWTEST_F() 319 scensession->SetRequestedOrientation(Orientation::AUTO_ROTATION_UNSPECIFIED); in HWTEST_F() 320 Orientation ret1 = scensession->GetRequestedOrientation(); in HWTEST_F() 321 ASSERT_EQ(ret1, Orientation::AUTO_ROTATION_UNSPECIFIED); in HWTEST_F() 323 scensession->SetRequestedOrientation(Orientation::USER_ROTATION_PORTRAIT); in HWTEST_F() 324 Orientation ret2 = scensession->GetRequestedOrientation(); in HWTEST_F() 325 ASSERT_EQ(ret2, Orientation::USER_ROTATION_PORTRAIT); in HWTEST_F() 327 scensession->SetRequestedOrientation(Orientation in HWTEST_F() [all...] |
/foundation/window/window_manager/wm/test/unittest/ |
H A D | window_session_impl_test.cpp | 1025 Orientation ori = Orientation::VERTICAL; in HWTEST_F() 1027 Orientation ret = window->GetRequestedOrientation(); in HWTEST_F() 1030 window->SetRequestedOrientation(Orientation::AUTO_ROTATION_UNSPECIFIED); in HWTEST_F() 1031 Orientation ret1 = window->GetRequestedOrientation(); in HWTEST_F() 1032 ASSERT_EQ(ret1, Orientation::AUTO_ROTATION_UNSPECIFIED); in HWTEST_F() 1034 window->SetRequestedOrientation(Orientation::USER_ROTATION_PORTRAIT); in HWTEST_F() 1035 Orientation ret2 = window->GetRequestedOrientation(); in HWTEST_F() 1036 ASSERT_EQ(ret2, Orientation::USER_ROTATION_PORTRAIT); in HWTEST_F() 1038 window->SetRequestedOrientation(Orientation in HWTEST_F() [all...] |
/foundation/arkui/ace_engine/interfaces/inner_api/ace/ |
H A D | viewport_config.h | 78 int32_t Orientation() const in Orientation() function in OHOS::Ace::ViewportConfig 100 orientation_ == other.Orientation() && in operator ==()
|