diff --git a/api/@ohos.screenshot.d.ts b/api/@ohos.screenshot.d.ts index 4928ee300f4532989b7680ed5f546d9cff8e3743..210ff03b84034b8b190cd13ac6f486b070960ba4 100644 --- a/api/@ohos.screenshot.d.ts +++ b/api/@ohos.screenshot.d.ts @@ -29,7 +29,15 @@ declare namespace screenshot { * @permission ohos.permission.CAPTURE_SCREEN * @since 7 */ - function save(options?: ScreenshotOptions, callback: AsyncCallback): void; + function save(options: ScreenshotOptions, callback: AsyncCallback): void; + + /** + * Takes a screenshot and saves it as a PixelMap object. + * @param options Screenshot options, which consist of screenRect, imageSize, and rotation. You need to set these parameters + * @permission ohos.permission.CAPTURE_SCREEN + * @since 7 + */ + function save(callback: AsyncCallback): void; /** * Takes a screenshot and saves it as a PixelMap object. diff --git a/api/@ohos.window.d.ts b/api/@ohos.window.d.ts index f171e3ae827883da22fe1b21cc059ea9a340186b..515bfbc8e555192ce3a5d89233abfe174513fed6 100644 --- a/api/@ohos.window.d.ts +++ b/api/@ohos.window.d.ts @@ -13,10 +13,10 @@ * limitations under the License. */ -/// +/// import { AsyncCallback, Callback } from './basic' ; -import { Context } from './application/BaseContext'; +import Context from './application/BaseContext'; import { LocalStorage } from 'StateManagement'; import image from './@ohos.multimedia.image'; import rpc from './@ohos.rpc';