• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2021-2022 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 #ifndef CHARGER_UI_SURFACE_DEV_H
17 #define CHARGER_UI_SURFACE_DEV_H
18 
19 #include <cstdint>
20 
21 namespace OHOS {
22 namespace HDI {
23 namespace Battery {
24 namespace V1_1 {
25 class SurfaceDev {
26 public:
27     enum class DevType {
28         FB_DEVICE = 0,
29         DRM_DEVICE,
30     };
31 
32     explicit SurfaceDev(SurfaceDev::DevType devType);
33     ~SurfaceDev();
34     void Flip(char* buf);
35     void GetScreenSize(int32_t& w, int32_t& h);
36 };
37 }  // namespace V1_1
38 }  // namespace Battery
39 }  // namespace HDI
40 }  // namespace OHOS
41 #endif // CHARGER_UI_SURFACE_DEV_H
42