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
Copy file name to clipboardExpand all lines: README.md
+6-5Lines changed: 6 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@ The player's functionality is designed around a dual interaction model:
20
20
21
21
-**Commands and Settings**: Through these, you instruct the player on what to do and how to do it. Settings define the environment and initial state, while commands offer real-time control.
22
22
23
-
-**Event Feedback**: Through event handling, the player communicates back to the application, informing it of internal changes that may need attention.
23
+
-**Event Feedback**: Through event handling, the player communicates back to the application, informing it of internal changes that may need attention. Due to the nature of media players, especially in environments with dynamic content or user interactions, the flow of events can become flooded. To manage this effectively and prevent the application from being overwhelmed by the volume of incoming events, the system collects these events every second and returns them as a batch.
24
24
25
25
## API Specifications
26
26
@@ -98,12 +98,13 @@ The player's functionality is designed around a dual interaction model:
|`idle`| Represents a state where the player is idle, meaning it is not currently performing any action. |
102
101
|`seek(Bool, currentTime: Double)`| Represents an end seek action within the player. The first parameter (`Bool`) indicates whether the seek was successful, and the second parameter (`currentTime`) provides the time (in seconds) to which the player is seeking. |
103
102
|`paused`| Indicates that the player's playback is currently paused. This state occurs when the player has been manually paused by the user or programmatically through a method like `pause()`. The player is not playing any content while in this state. |
104
103
|`waitingToPlayAtSpecifiedRate`| Indicates that the player is currently waiting to play at the specified rate. This state generally occurs when the player is buffering or waiting for sufficient data to continue playback. It can also occur if the playback rate is temporarily reduced to zero due to external factors, such as network conditions or system resource limitations. |
105
104
|`playing`| Indicates that the player is actively playing content. This state occurs when the player is currently playing video or audio content at the specified playback rate. This is the active state where media is being rendered to the user. |
106
-
105
+
|`currentItemChanged`| Triggered when the player's `currentItem` is updated to a new `AVPlayerItem`. This event indicates a change in the media item currently being played. |
106
+
|`currentItemRemoved`| Occurs when the player's `currentItem` is set to `nil`, indicating that the current media item has been removed from the player. |
107
+
|`volumeChanged`| Happens when the player's volume level is adjusted. This event provides the new volume level, which ranges from 0.0 (muted) to 1.0 (maximum volume). |
107
108
108
109
### Additional Notes on Adding and Removing Vector Graphics
0 commit comments