• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2023 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #include "accessibility_circle_drawing_manager.h"
17 #include "hilog_wrapper.h"
18 
19 namespace OHOS {
20 namespace Accessibility {
21 std::shared_ptr<AccessibilityCircleDrawingManager> AccessibilityCircleDrawingManager::pointDrawMgr_ = nullptr;
22 
GetInstance()23 std::shared_ptr<AccessibilityCircleDrawingManager> AccessibilityCircleDrawingManager::GetInstance()
24 {
25     HILOG_DEBUG();
26     if (pointDrawMgr_ == nullptr) {
27         pointDrawMgr_ = std::make_shared<AccessibilityCircleDrawingManager>();
28     }
29     return pointDrawMgr_;
30 }
31 
DeleteInstance()32 void AccessibilityCircleDrawingManager::DeleteInstance()
33 {
34     HILOG_DEBUG();
35     if (pointDrawMgr_ == nullptr) {
36         HILOG_ERROR("surfaceNode_ is nullptr");
37         return;
38     }
39     pointDrawMgr_ = nullptr;
40 }
41 
AccessibilityCircleDrawingManager()42 AccessibilityCircleDrawingManager::AccessibilityCircleDrawingManager()
43 {
44     HILOG_DEBUG();
45 }
46 
~AccessibilityCircleDrawingManager()47 AccessibilityCircleDrawingManager::~AccessibilityCircleDrawingManager()
48 {
49     HILOG_DEBUG();
50 }
51 
UpdatePointerVisible(bool state)52 void AccessibilityCircleDrawingManager::UpdatePointerVisible(bool state)
53 {
54     HILOG_DEBUG();
55     (void)state;
56 }
57 
DrawPointer(int32_t physicalX,int32_t physicalY,int32_t angle,uint64_t screenId,int32_t startAngle)58 void AccessibilityCircleDrawingManager::DrawPointer(int32_t physicalX, int32_t physicalY, int32_t angle,
59     uint64_t screenId, int32_t startAngle)
60 {
61     HILOG_DEBUG();
62     (void)physicalX;
63     (void)physicalY;
64     (void)angle;
65     (void)screenId;
66     (void)startAngle;
67 }
68 } // namespace Accessibility
69 } // namespace OHOS