Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
S
swiftcleanerphonehelper
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wanglei
swiftcleanerphonehelper
Commits
c89d55f4
Commit
c89d55f4
authored
Dec 20, 2024
by
wanglei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
...
parent
15a6be7c
Pipeline
#1395
canceled with stages
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
8 deletions
+10
-8
NotificationUtils.kt
app/src/main/java/com/zxdemo/notity/NotificationUtils.kt
+10
-8
No files found.
app/src/main/java/com/zxdemo/notity/NotificationUtils.kt
View file @
c89d55f4
...
...
@@ -283,14 +283,16 @@ object NotificationUtils {
private
var
currentNotificationIdIndex
=
-
1
private
val
nextNotificationId
:
String
get
()
{
// 将当前通知 ID 索引加 1
currentNotificationIdIndex
++
// 如果当前通知 ID 索引超出列表范围,则将其重置为 0
if
(
currentNotificationIdIndex
>=
NOTIFICATION_IDS
.
size
)
{
currentNotificationIdIndex
=
0
}
// 返回下一个通知 ID
return
NOTIFICATION_IDS
[
currentNotificationIdIndex
]
// // 将当前通知 ID 索引加 1
// currentNotificationIdIndex++
// // 如果当前通知 ID 索引超出列表范围,则将其重置为 0
// if (currentNotificationIdIndex >= NOTIFICATION_IDS.size) {
// currentNotificationIdIndex = 0
// }
// // 返回下一个通知 ID
// return NOTIFICATION_IDS[currentNotificationIdIndex]
return
NOTIFICATION_IDS
.
random
()
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment