From 10a6d0c442ba75c0ffec5814c5419f38116ba509 Mon Sep 17 00:00:00 2001 From: 18719058668 <718092089@qq.com> Date: Tue, 26 Mar 2024 10:37:39 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E9=A2=84=E8=A7=88=E5=9B=BE?= =?UTF-8?q?=E5=83=8F=E5=81=8F=E8=BD=AC90=E5=BA=A6=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 18719058668 <718092089@qq.com> --- ohos/testcamera/lib/CameraPage.dart | 18 ++++++++++++++---- .../src/ohosTest/ets/test/Ability.test.ets | 2 +- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/ohos/testcamera/lib/CameraPage.dart b/ohos/testcamera/lib/CameraPage.dart index b8a1404e..9bf592da 100644 --- a/ohos/testcamera/lib/CameraPage.dart +++ b/ohos/testcamera/lib/CameraPage.dart @@ -15,6 +15,7 @@ import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; +import 'dart:math' as math; class CameraPage extends StatefulWidget { const CameraPage({super.key}); @@ -73,10 +74,19 @@ class _CameraPageState extends State { appBar: AppBar( title: Text("daex_texture"), ), - body: Container( - height: 500, - width: 500, - child: body, + body: AspectRatio( + aspectRatio: 1, + child:Transform.rotate( + angle: 90 * math.pi / 180, + child: Container( + color: Colors.white, + height: 500, + width: 500, + child: Center( + child: body, + ), + ), + ), ), ); } diff --git a/ohos/testcamera/ohos/entry/src/ohosTest/ets/test/Ability.test.ets b/ohos/testcamera/ohos/entry/src/ohosTest/ets/test/Ability.test.ets index 25d4c71f..741f7eb8 100644 --- a/ohos/testcamera/ohos/entry/src/ohosTest/ets/test/Ability.test.ets +++ b/ohos/testcamera/ohos/entry/src/ohosTest/ets/test/Ability.test.ets @@ -20,7 +20,7 @@ export default function abilityTest() { describe('ActsAbilityTest', function () { // Defines a test suite. Two parameters are supported: test suite name and test suite function. beforeAll(function () { - // Presets an action, which is performed only once before all test cases of the test suite start. + // Presets an action, which is performed only once before all test cases of the test suite start . // This API supports only one parameter: preset action function. }) beforeEach(function () { -- Gitee