-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
21 changed files
with
7,302 additions
and
348 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,6 +5,7 @@ const { | |
let tray; | ||
class menu { | ||
static create_menu() { | ||
app.dock.hide() | ||
let icon_path = path.join(path.res,'/image/[email protected]') | ||
tray = new Tray(icon_path) | ||
|
||
|
@@ -26,8 +27,8 @@ class menu { | |
}, | ||
|
||
]) | ||
tray.setToolTip('This is my application.') | ||
tray.setTitle("\u001b[34m") | ||
// tray.setToolTip('This is my application.') | ||
// tray.setTitle("\u001b[34m") | ||
tray.setContextMenu(contextMenu) | ||
} | ||
} | ||
|
2 changes: 1 addition & 1 deletion
2
app/renderer/js/promise_entends.js → app/renderer/js/extends/promise.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
/*! | ||
*@name jquery.barrager.js | ||
*@version 1.1 | ||
*@author [email protected] | ||
*@url https://github.com/yaseng/jquery.barrager.js | ||
*/ | ||
(function($) { | ||
|
||
$.fn.barrager = function(barrage) { | ||
barrage = $.extend({ | ||
close:true, | ||
bottom: 0, | ||
max: 10, | ||
speed: 8, | ||
color: '#fff', | ||
old_ie_color : '#000000' | ||
}, barrage || {}); | ||
|
||
var time = new Date().getTime(); | ||
var barrager_id = 'barrage_' + time; | ||
var id = '#' + barrager_id; | ||
var div_barrager = $("<div class='barrage' id='" + barrager_id + "'></div>").appendTo($(this)); | ||
var window_height = $(window).height() - 100; | ||
var this_height = (window_height > this.height()) ? this.height() : window_height; | ||
var window_width = $(window).width() + 500; | ||
var this_width = (window_width > this.width()) ? this.width() : window_width; | ||
var bottom = (barrage.bottom == 0) ? Math.floor(Math.random() * this_height + 40) : barrage.bottom; | ||
div_barrager.css("bottom", bottom + "px"); | ||
|
||
div_barrager_box = $("<div class='barrage_box cl'></div>").appendTo(div_barrager); | ||
if(barrage.img){ | ||
|
||
div_barrager_box.append("<a class='portrait z' href='javascript:;'></a>"); | ||
var img = $("<img src='' >").appendTo(id + " .barrage_box .portrait"); | ||
img.attr('src', barrage.img); | ||
} | ||
div_barrager_box.append(" <div class='z p'></div>"); | ||
if(barrage.close){ | ||
|
||
div_barrager_box.append(" <div class='close z'></div>"); | ||
|
||
} | ||
|
||
var content = $("<a title='' href='' target='_blank'></a>").appendTo(id + " .barrage_box .p"); | ||
content.attr({ | ||
'href': barrage.href, | ||
'id': barrage.id | ||
}).empty().append(barrage.info); | ||
if(navigator.userAgent.indexOf("MSIE 6.0")>0 || navigator.userAgent.indexOf("MSIE 7.0")>0 || navigator.userAgent.indexOf("MSIE 8.0")>0 ){ | ||
|
||
content.css('color', barrage.old_ie_color); | ||
|
||
}else{ | ||
|
||
content.css('color', barrage.color); | ||
|
||
} | ||
|
||
var i = 0; | ||
div_barrager.css('margin-right', 0); | ||
|
||
$(id).animate({right:this_width},barrage.speed*1000,function(){ | ||
|
||
$(id).remove(); | ||
}); | ||
|
||
div_barrager_box.mouseover(function() { | ||
$(id).stop(true); | ||
}); | ||
|
||
div_barrager_box.mouseout(function() { | ||
|
||
$(id).animate({right:this_width},barrage.speed*1000,function(){ | ||
|
||
$(id).remove(); | ||
}); | ||
|
||
}); | ||
|
||
$(id+'.barrage .barrage_box .close').click(function(){ | ||
|
||
$(id).remove(); | ||
|
||
}) | ||
|
||
} | ||
|
||
$.fn.barrager.removeAll=function(){ | ||
|
||
$('.barrage').remove(); | ||
|
||
} | ||
|
||
})(jQuery); |
Oops, something went wrong.