Skip to content

Instantly share code, notes, and snippets.

@quickgrid
Created April 14, 2016 20:11
Show Gist options
  • Save quickgrid/d968a54d4527b2be05374390f38b0ac7 to your computer and use it in GitHub Desktop.
Save quickgrid/d968a54d4527b2be05374390f38b0ac7 to your computer and use it in GitHub Desktop.
Simple chrome clock app using konva JS framework background JavaScript file
function launch(){
chrome.app.window.create('app.html',{
id: 'main',
'bounds': {
'width': 600,
'height': 600
},
minWidth: 600,
minHeight: 600,
maxWidth: 600,
maxHeight: 600,
});
}
chrome.app.runtime.onLaunched.addListener(launch);
// These event handlers are not implemented yet
chrome.runtime.onInstalled.addListener(function() {
//chrome.storage.local.set(object items, function callback);
});
chrome.runtime.onSuspend.addListener(function() {
// Do some simple clean-up tasks.
});
chrome.notifications.onClicked.addListener(function() {
// Click on notifications
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment