IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)

QCalendarPermission Class

Access the user's calendar.

This class was introduced in Qt 6.5.

Article lu   fois.

L'auteur

Liens sociaux

Viadeo Twitter Facebook Share on Google+   

QCalendarPermission Class

  • Header: QPermissions

  • Since: Qt 6.5

  • CMake:

    find_package(Qt6 REQUIRED COMPONENTS Core)

    target_link_libraries(mytarget PRIVATE Qt6::Core)

  • qmake: QT += core

  • Group: QCalendarPermission is part of permissions

Detailed Description

By default the request is for read-only access. Use setAccessMode() to override the default.

Requirements

To request this permission at runtime, the following platform specific usage declarations have to be made at build time:

Platform

Type

 

Apple

Usage description

NSCalendarsUsageDescription

Android

uses-permission

android.permission.READ_CALENDAR. android.permission.WRITE_CALENDAR if QCalendarPermission::accessMode() is set to AccessMode::ReadWrite.

Please see the individual usage declaration types for how to add them to your project.

See Also

Member Type Documentation

 

enum QCalendarPermission::AccessMode

This enum is used to control access to the calendar data.

Constant

Value

Description

QCalendarPermission::ReadOnly

0

Read-only access to the calendar data (the default).

QCalendarPermission::ReadWrite

1

Read and write access to the calendar data.

See Also

Member Function Documentation

 

QCalendarPermission::AccessMode QCalendarPermission::accessMode() const

Returns AccessMode::ReadWrite when the request is for read-write and AccessMode::ReadOnly when it is for read-only access to the calendar.

See Also

See also setAccessMode()

void QCalendarPermission::setAccessMode(QCalendarPermission::AccessMode mode)

Sets whether the request is for read-write (mode == AccessMode::ReadOnly) or read-only (mode == AccessMode::ReadOnly) access to the calendar.

See Also

See also accessMode()

Vous avez aimé ce tutoriel ? Alors partagez-le en cliquant sur les boutons suivants : Viadeo Twitter Facebook Share on Google+