Home
last modified time | relevance | path

Searched refs:Orientation (Results 1 – 25 of 99) sorted by relevance

1234

/foundation/window/window_manager/wmserver/include/utils/
Dwindow_manager_service_utils.h32 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/
Dscreen_rotation_controller_test.cpp215 Orientation orientation = Orientation::SENSOR;
218 orientation = Orientation::SENSOR_VERTICAL;
221 orientation = Orientation::SENSOR_HORIZONTAL;
224 orientation = Orientation::UNSPECIFIED;
230 orientation = Orientation::AUTO_ROTATION_RESTRICTED;
236 orientation = Orientation::AUTO_ROTATION_PORTRAIT_RESTRICTED;
242 orientation = Orientation::AUTO_ROTATION_LANDSCAPE_RESTRICTED;
248 orientation = Orientation::VERTICAL;
315 ASSERT_EQ(false, ScreenRotationController::IsSensorRelatedOrientation(Orientation::LOCKED));
316 … ASSERT_EQ(false, ScreenRotationController::IsSensorRelatedOrientation(Orientation::UNSPECIFIED));
[all …]
Dabstract_screen_test.cpp171 ASSERT_EQ(Rotation::ROTATION_0, absScreen_->CalcRotation(Orientation::UNSPECIFIED));
178 ASSERT_EQ(Rotation::ROTATION_0, absScreen_->CalcRotation(Orientation::UNSPECIFIED));
179 ASSERT_EQ(Rotation::ROTATION_90, absScreen_->CalcRotation(Orientation::VERTICAL));
180 ASSERT_EQ(Rotation::ROTATION_0, absScreen_->CalcRotation(Orientation::HORIZONTAL));
181 ASSERT_EQ(Rotation::ROTATION_270, absScreen_->CalcRotation(Orientation::REVERSE_VERTICAL));
182 ASSERT_EQ(Rotation::ROTATION_180, absScreen_->CalcRotation(Orientation::REVERSE_HORIZONTAL));
183 ASSERT_EQ(Rotation::ROTATION_0, absScreen_->CalcRotation(Orientation::LOCKED));
/foundation/window/window_manager/dmserver/src/
Dscreen_rotation_controller.cpp33 Orientation ScreenRotationController::lastOrientationType_ = Orientation::UNSPECIFIED;
66 Orientation currentOrientation = GetPreferredOrientation(); in SetScreenRotationLocked()
88 Orientation orientation = GetPreferredOrientation(); in HandleSensorEventInput()
115 Orientation ScreenRotationController::GetPreferredOrientation() in GetPreferredOrientation()
120 return Orientation::UNSPECIFIED; in GetPreferredOrientation()
126 Orientation requestedOrientation, DeviceRotation sensorRotationConverted) in CalcTargetDisplayRotation()
129 case Orientation::SENSOR: { in CalcTargetDisplayRotation()
133 case Orientation::SENSOR_VERTICAL: { in CalcTargetDisplayRotation()
136 case Orientation::SENSOR_HORIZONTAL: { in CalcTargetDisplayRotation()
139 case Orientation::AUTO_ROTATION_RESTRICTED: { in CalcTargetDisplayRotation()
[all …]
/foundation/window/window_manager/window_scene/session_manager/src/
Dscreen_rotation_property.cpp33 Orientation ScreenRotationProperty::lastOrientationType_ = Orientation::UNSPECIFIED;
76 Orientation currentOrientation = GetPreferredOrientation(); in SetScreenRotationLocked()
98 Orientation orientation = GetPreferredOrientation(); in HandleSensorEventInput()
125 Orientation ScreenRotationProperty::GetPreferredOrientation() in GetPreferredOrientation()
127 return Orientation::SENSOR; in GetPreferredOrientation()
131 Orientation requestedOrientation, DeviceRotation sensorRotationConverted) in CalcTargetDisplayRotation()
134 case Orientation::SENSOR: { in CalcTargetDisplayRotation()
138 case Orientation::SENSOR_VERTICAL: { in CalcTargetDisplayRotation()
141 case Orientation::SENSOR_HORIZONTAL: { in CalcTargetDisplayRotation()
144 case Orientation::AUTO_ROTATION_RESTRICTED: { in CalcTargetDisplayRotation()
[all …]
/foundation/window/window_manager/previewer/src/
Dwindow_model.cpp33 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/
Dwindow_manager_service_utils.cpp21 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_HO… 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/
Dwindow_manager_service_utils_test.cpp55 …bool ret = WmsUtils::IsFixedOrientation(Orientation::HORIZONTAL, WindowMode::WINDOW_MODE_FULLSCREE…
66 …bool ret = WmsUtils::IsFixedOrientation(Orientation::SENSOR, WindowMode::WINDOW_MODE_FULLSCREEN, 0…
77 …bool ret = WmsUtils::IsFixedOrientation(Orientation::UNSPECIFIED, WindowMode::WINDOW_MODE_FULLSCRE…
88 …bool ret = WmsUtils::IsFixedOrientation(Orientation::HORIZONTAL, WindowMode::WINDOW_MODE_FULLSCREE…
100 …bool ret = WmsUtils::IsFixedOrientation(Orientation::HORIZONTAL, WindowMode::WINDOW_MODE_FLOATING,…
111 …bool ret = WmsUtils::IsExpectedRotateLandscapeWindow(Orientation::VERTICAL, DisplayOrientation::PO…
122 …bool ret = WmsUtils::IsExpectedRotatableWindow(Orientation::VERTICAL, DisplayOrientation::PORTRAIT,
134 …bool ret = WmsUtils::IsExpectedRotatableWindow(Orientation::VERTICAL, DisplayOrientation::PORTRAIT…
145 …bool ret = WmsUtils::IsExpectedRotatableWindow(Orientation::VERTICAL, DisplayOrientation::PORTRAIT…
156 …bool ret = WmsUtils::IsExpectedRotatableWindow(Orientation::REVERSE_VERTICAL, DisplayOrientation::…
[all …]
/foundation/window/window_manager/test/systemtest/wms/
Dwindow_rotation_test.cpp139 fullInfo_.orientation_ = Orientation::UNSPECIFIED;
146 fullWindow->SetRequestedOrientation(Orientation::REVERSE_HORIZONTAL);
148 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, fullWindow->GetRequestedOrientation());
155 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, screen->GetOrientation());
156 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, display->GetOrientation());
172 fullInfo_.orientation_ = Orientation::REVERSE_HORIZONTAL;
179 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, fullWindow->GetRequestedOrientation());
185 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, screen->GetOrientation());
186 ASSERT_EQ(Orientation::REVERSE_HORIZONTAL, display->GetOrientation());
191 screen->SetOrientation(Orientation::UNSPECIFIED);
[all …]
/foundation/window/window_manager/window_scene/session/screen/include/
Dscreen_property.h61 void SetOrientation(Orientation orientation);
62 Orientation GetOrientation() const;
81 void SetScreenRequestedOrientation(Orientation orientation);
82 Orientation GetScreenRequestedOrientation() const;
98 Orientation orientation_ { Orientation::UNSPECIFIED };
101 Orientation screenRequestedOrientation_ { Orientation::UNSPECIFIED };
Dscreen_session.h68 Orientation GetOrientation() const;
69 void SetOrientation(Orientation orientation);
72 void SetScreenRequestedOrientation(Orientation orientation);
73 Orientation GetScreenRequestedOrientation() const;
84 Rotation CalcRotation(Orientation orientation) const;
/foundation/window/window_manager/window_scene/interfaces/kits/napi/scene_session_manager/
Djs_scene_utils.h121 const std::map<Orientation, JsSessionOrientation> WINDOW_ORIENTATION_TO_JS_SESSION_MAP {
122 … {Orientation::UNSPECIFIED, JsSessionOrientation::UNSPECIFIED },
123 … {Orientation::VERTICAL, JsSessionOrientation::PORTRAIT },
124 … {Orientation::HORIZONTAL, JsSessionOrientation::LANDSCAPE },
125 … {Orientation::REVERSE_VERTICAL, JsSessionOrientation::PORTRAIT_INVERTED },
126 … {Orientation::REVERSE_HORIZONTAL, JsSessionOrientation::LANDSCAPE_INVERTED },
127 … {Orientation::SENSOR, JsSessionOrientation::AUTO_ROTATION },
128 … {Orientation::SENSOR_VERTICAL, JsSessionOrientation::AUTO_ROTATION_PORTRAIT },
129 … {Orientation::SENSOR_HORIZONTAL, JsSessionOrientation::AUTO_ROTATION_LANDSCAPE },
130 … {Orientation::AUTO_ROTATION_RESTRICTED, JsSessionOrientation::AUTO_ROTATION_RESTRICTED},
[all …]
/foundation/window/window_manager/dmserver/include/
Dscreen_rotation_controller.h54 static void ProcessOrientationSwitch(Orientation orientation, bool withAnimation);
64 static Orientation GetPreferredOrientation();
66 static Rotation CalcTargetDisplayRotation(Orientation requestedOrientation,
75 static bool IsSensorRelatedOrientation(Orientation orientation);
83 …static void ProcessSwitchToSensorRelatedOrientation(Orientation orientation, DeviceRotation device…
84 …static void ProcessSwitchToSensorUnrelatedOrientation(Orientation orientation, bool withAnimation);
94 static Orientation lastOrientationType_;
Dabstract_screen.h46 bool SetOrientation(Orientation orientation);
47 Rotation CalcRotation(Orientation orientation) const;
85 Orientation orientation_ { Orientation::UNSPECIFIED };
87 Orientation screenRequestedOrientation_ { Orientation::UNSPECIFIED };
Dabstract_display.h55 Orientation GetOrientation() const;
67 void SetOrientation(Orientation orientation);
85 Orientation orientation_ { Orientation::UNSPECIFIED };
/foundation/window/window_manager/window_scene/session_manager/include/
Dscreen_rotation_property.h54 static void ProcessOrientationSwitch(Orientation orientation);
64 static Orientation GetPreferredOrientation();
66 static Rotation CalcTargetDisplayRotation(Orientation requestedOrientation,
75 static bool IsSensorRelatedOrientation(Orientation orientation);
83 …static void ProcessSwitchToSensorRelatedOrientation(Orientation orientation, DeviceRotation device…
84 static void ProcessSwitchToSensorUnrelatedOrientation(Orientation orientation);
96 static Orientation lastOrientationType_;
/foundation/window/window_manager/previewer/include/
Dwindow_model.h23 enum class Orientation : int32_t { enum
50 Orientation orientation = Orientation::PORTRAIT; // orientation
63 static Rosen::Orientation TransOrientation(Previewer::Orientation orientation);
Dwindow_option.h196 void SetRequestedOrientation(Orientation orientation);
322 Orientation GetRequestedOrientation() const;
361 Orientation requestedOrientation_ { Orientation::UNSPECIFIED };
/foundation/window/window_manager/wm/include/
Dwindow_scene_session_impl.h24 const std::map<OHOS::AppExecFwk::DisplayOrientation, Orientation> ABILITY_TO_SESSION_ORIENTATION_MA…
25 …{OHOS::AppExecFwk::DisplayOrientation::UNSPECIFIED, Orientation::UNSPECIFI…
26 …{OHOS::AppExecFwk::DisplayOrientation::LANDSCAPE, Orientation::HORIZONTA…
27 …{OHOS::AppExecFwk::DisplayOrientation::PORTRAIT, Orientation::VERTICAL},
28 … {OHOS::AppExecFwk::DisplayOrientation::FOLLOWRECENT, Orientation::LOCKED},
29 …{OHOS::AppExecFwk::DisplayOrientation::LANDSCAPE_INVERTED, Orientation::REVERSE_H…
30 …{OHOS::AppExecFwk::DisplayOrientation::PORTRAIT_INVERTED, Orientation::REVERSE_V…
31 … {OHOS::AppExecFwk::DisplayOrientation::AUTO_ROTATION, Orientation::SENSOR},
32 …{OHOS::AppExecFwk::DisplayOrientation::AUTO_ROTATION_LANDSCAPE, Orientation::SENSOR_HO…
33 …{OHOS::AppExecFwk::DisplayOrientation::AUTO_ROTATION_PORTRAIT, Orientation::SENSOR_VE…
[all …]
/foundation/window/window_manager/interfaces/kits/napi/window_runtime/window_napi/
Djs_window_utils.h148 const std::map<ApiOrientation, Orientation> JS_TO_NATIVE_ORIENTATION_MAP {
149 …{ApiOrientation::UNSPECIFIED, Orientation::UNSPECIFIED …
150 …{ApiOrientation::PORTRAIT, Orientation::VERTICAL …
151 …{ApiOrientation::LANDSCAPE, Orientation::HORIZONTAL …
152 …{ApiOrientation::PORTRAIT_INVERTED, Orientation::REVERSE_VERTICAL …
153 …{ApiOrientation::LANDSCAPE_INVERTED, Orientation::REVERSE_HORIZONTAL …
154 …{ApiOrientation::AUTO_ROTATION, Orientation::SENSOR …
155 …{ApiOrientation::AUTO_ROTATION_PORTRAIT, Orientation::SENSOR_VERTICAL …
156 …{ApiOrientation::AUTO_ROTATION_LANDSCAPE, Orientation::SENSOR_HORIZONTAL …
157 …{ApiOrientation::AUTO_ROTATION_RESTRICTED, Orientation::AUTO_ROTATION_RESTRICTED …
[all …]
/foundation/window/window_manager/wmserver/src/
Dstarting_window.cpp38 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::SENSOR_VERTICAL},
[all …]
/foundation/window/window_manager/interfaces/innerkits/wm/
Dwindow_option.h196 void SetRequestedOrientation(Orientation orientation);
322 Orientation GetRequestedOrientation() const;
361 Orientation requestedOrientation_ { Orientation::UNSPECIFIED };
/foundation/window/window_manager/utils/include/
Dscreen_info.h50 … DEFINE_VAR_DEFAULT_FUNC_GET_SET(Orientation, Orientation, orientation, Orientation::UNSPECIFIED);
Ddisplay_info.h53 … DEFINE_VAR_DEFAULT_FUNC_GET_SET(Orientation, Orientation, orientation, Orientation::UNSPECIFIED);
/foundation/window/window_manager/test/fuzztest/dms/screen_fuzzer/
Dscreen_fuzzer.cpp66 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()

1234