Greasy Fork

Pastebin CTRL+S in Editor

Allows CTRL+S to update the script.

目前为 2015-01-15 提交的版本。查看 最新版本

// ==UserScript==
// @name Pastebin CTRL+S in Editor
// @version 1.0.0
// @description Allows CTRL+S to update the script.
// @author celliott1997
// @match http*://*pastebin.com/*
// @grant none
// @namespace https://greasyfork.org/users/8398
// ==/UserScript==

$(document).ready(function(){
    var TextArea = $("textarea#paste_code");
    var SubmitBtn = $("input.button1.btnbold[type='submit']");
    
    if (TextArea.length && SubmitBtn.length){
        $(document).keydown(function(evt){
            if (evt.ctrlKey && (evt.which == 83)){
                evt.preventDefault();
                SubmitBtn.click();
            };
        });
    };
});