You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An ability slice's lifecycle is bound to the Page ability that hosts it. An ability slice has the same lifecycle states and lifecycle callbacks as its host Page ability. Once the lifecycle state of a Page ability changes, its ability slices undergo the same change. An ability slice can also have its own lifecycle state changes, which occur during the switching between the ability slices within the Page ability. Such a switching does not affect the host ability's lifecycle.
All the application resource files, such as strings, images, and audio files, are stored in the resources directory, allowing you to easily access, use, and maintain them. The resources directory consists of two types of sub-directories: the base sub-directory and qualifiers sub-directories, and the rawfile sub-directory.
Example:
resources
|---base // Default directory
| |---element
| | |---string.json
| |---media
| | |---icon.png
|---en_GB-vertical-car-mdpi // Example of a qualifiers sub-directory, which needs to be created on your own
| |---element
| | |---string.json
| |---media
| | |---icon.png
|---rawfile // Default directory
Resource files are referenced in a Java file in the following format: ResourceTable.type_name. Specifically, a system resource is referenced using ohos.global.systemres.ResourceTable.type_name.
Resource files are referenced in an XML file in the following format: $type:name. Specifically, a system resource is referenced using $ohos:type:name.