Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
cordova-plugin-local-notifications
Overview
Overview
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Nabil Sadki
cordova-plugin-local-notifications
Commits
d8af1e9b
Commit
d8af1e9b
authored
Jan 17, 2014
by
Sebastián Katzer
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #66 from interFace-dk/ongoing_option
Added ongoing option (android only)
parents
0cc81a21
d06b1ad7
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
1 deletions
+8
-1
README.md
README.md
+1
-0
Options.java
src/android/Options.java
+4
-0
Receiver.java
src/android/Receiver.java
+2
-1
local-notification.js
www/local-notification.js
+1
-0
No files found.
README.md
View file @
d8af1e9b
...
@@ -117,6 +117,7 @@ window.plugin.notification.local.add({
...
@@ -117,6 +117,7 @@ window.plugin.notification.local.add({
sound
:
String
,
// A sound to be played
sound
:
String
,
// A sound to be played
json
:
String
,
// Data to be passed through the notification
json
:
String
,
// Data to be passed through the notification
autoCancel
:
Boolean
,
// Setting this flag and the notification is automatically canceled when the user clicks it
autoCancel
:
Boolean
,
// Setting this flag and the notification is automatically canceled when the user clicks it
ongoing
:
Boolean
,
// Prevent clearing of notification (Android only)
foreground
:
String
,
// A javascript function to be called if the app is running
foreground
:
String
,
// A javascript function to be called if the app is running
background
:
String
,
// A javascript function to be called if the app is in the background
background
:
String
,
// A javascript function to be called if the app is in the background
});
});
...
...
src/android/Options.java
View file @
d8af1e9b
...
@@ -228,6 +228,10 @@ public class Options {
...
@@ -228,6 +228,10 @@ public class Options {
return
options
.
optBoolean
(
"autoCancel"
,
false
);
return
options
.
optBoolean
(
"autoCancel"
,
false
);
}
}
public
Boolean
getOngoing
()
{
return
options
.
optBoolean
(
"ongoing"
,
false
);
}
/**
/**
* Gibt die zusätzlichen Daten als String an.
* Gibt die zusätzlichen Daten als String an.
*/
*/
...
...
src/android/Receiver.java
View file @
d8af1e9b
...
@@ -130,7 +130,8 @@ public class Receiver extends BroadcastReceiver {
...
@@ -130,7 +130,8 @@ public class Receiver extends BroadcastReceiver {
.
setSmallIcon
(
options
.
getSmallIcon
())
.
setSmallIcon
(
options
.
getSmallIcon
())
.
setLargeIcon
(
icon
)
.
setLargeIcon
(
icon
)
.
setSound
(
options
.
getSound
())
.
setSound
(
options
.
getSound
())
.
setAutoCancel
(
options
.
getAutoCancel
());
.
setAutoCancel
(
options
.
getAutoCancel
())
.
setOngoing
(
options
.
getOngoing
());
setClickEvent
(
notification
);
setClickEvent
(
notification
);
...
...
www/local-notification.js
View file @
d8af1e9b
...
@@ -36,6 +36,7 @@ LocalNotification.prototype = {
...
@@ -36,6 +36,7 @@ LocalNotification.prototype = {
message
:
''
,
message
:
''
,
title
:
''
,
title
:
''
,
autoCancel
:
false
,
autoCancel
:
false
,
ongoing
:
false
,
badge
:
0
,
badge
:
0
,
id
:
'0'
,
id
:
'0'
,
json
:
''
,
json
:
''
,
...
...
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