mirror of
https://bitbucket.org/skobkin/chrome_point_plus.git
synced 2024-11-23 18:56:04 +00:00
Moar fixes.
This commit is contained in:
parent
93a24c57d4
commit
0dae3f8661
|
@ -94,7 +94,7 @@ chrome.runtime.onMessage.addListener(function(message, sender, sendResponse) {
|
|||
|
||||
sendResponse(true);
|
||||
|
||||
// Fuck You, Chrome API documentation!!11
|
||||
// Fuck You, Chrome API documentation!
|
||||
return true;
|
||||
break;
|
||||
|
||||
|
@ -110,9 +110,10 @@ chrome.runtime.onMessage.addListener(function(message, sender, sendResponse) {
|
|||
sendResponse(true);
|
||||
|
||||
console.info('JS file executed: "%s"', message.file);
|
||||
return true;
|
||||
});
|
||||
|
||||
// Fuck You, Chrome API documentation!!11
|
||||
// Fuck You, Chrome API documentation!
|
||||
return true;
|
||||
break;
|
||||
|
||||
|
@ -126,7 +127,6 @@ chrome.runtime.onMessage.addListener(function(message, sender, sendResponse) {
|
|||
console.info('All scripts executed');
|
||||
|
||||
sendResponse(true);
|
||||
|
||||
return true;
|
||||
});
|
||||
} else {
|
||||
|
@ -139,7 +139,7 @@ chrome.runtime.onMessage.addListener(function(message, sender, sendResponse) {
|
|||
console.warn('No scripts executed (empty script array)');
|
||||
}
|
||||
|
||||
// Fuck You, Chrome API documentation!!11
|
||||
// Fuck You, Chrome API documentation!
|
||||
return true;
|
||||
break;
|
||||
|
||||
|
@ -151,12 +151,13 @@ chrome.runtime.onMessage.addListener(function(message, sender, sendResponse) {
|
|||
chrome.tabs.insertCSS(sender.tab.id ? sender.tab.id : null, {
|
||||
file: message.file
|
||||
}, function() {
|
||||
sendResponse(true);
|
||||
// @todo message response callback processing
|
||||
//sendResponse(true);
|
||||
|
||||
console.info('CSS file "%s" injected', message.file);
|
||||
});
|
||||
|
||||
// Fuck You, Chrome API documentation!!11
|
||||
// Fuck You, Chrome API documentation!
|
||||
return true;
|
||||
break;
|
||||
|
||||
|
@ -165,13 +166,19 @@ chrome.runtime.onMessage.addListener(function(message, sender, sendResponse) {
|
|||
chrome.tabs.insertCSS(sender.tab.id ? sender.tab.id : null, {
|
||||
code: message.code
|
||||
}, function() {
|
||||
sendResponse(true);
|
||||
// @todo message response callback processing
|
||||
//sendResponse(true);
|
||||
|
||||
console.info('CSS code injected: \n%s', message.file);
|
||||
});
|
||||
}
|
||||
|
||||
// Fuck You, Chrome API documentation!!11
|
||||
// Fuck You, Chrome API documentation!
|
||||
return true;
|
||||
break;
|
||||
|
||||
default:
|
||||
sendResponse(false);
|
||||
return true;
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -151,6 +151,7 @@ $(document).ready(function() {
|
|||
if (options.is('option_fancybox')) {
|
||||
// Injecting Fancybox to the page
|
||||
// CSS
|
||||
// @todo message response callback processing
|
||||
chrome.runtime.sendMessage({
|
||||
type: 'injectCSSFile',
|
||||
file: 'vendor/fancybox/source/jquery.fancybox.css'
|
||||
|
@ -305,10 +306,12 @@ $(document).ready(function() {
|
|||
$('#new-post-form #text-input, .post-content #text-input').addClass('markitup').css('height', '20em');
|
||||
|
||||
// CSS
|
||||
// @todo message response callback processing
|
||||
chrome.runtime.sendMessage({
|
||||
type: 'injectCSSFile',
|
||||
file: 'vendor/markitup/markitup/skins/markitup/style.css'
|
||||
});
|
||||
// @todo message response callback processing
|
||||
chrome.runtime.sendMessage({
|
||||
type: 'injectCSSFile',
|
||||
file: 'css/markitup/sets/markdown/style.css'
|
||||
|
@ -575,6 +578,7 @@ $(document).ready(function() {
|
|||
}
|
||||
// @ before username
|
||||
if (options.is('option_at_before_username')) {
|
||||
// @todo message response callback processing
|
||||
chrome.runtime.sendMessage({
|
||||
type: 'injectCSSFile',
|
||||
file: 'css/modules/at_before_username.css'
|
||||
|
|
Loading…
Reference in a new issue