This file contains hidden or 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
diff -r d1ddc3299a92 common/content/util.js | |
--- a/common/content/util.js Fri Mar 18 22:31:08 2011 +0900 | |
+++ b/common/content/util.js Tue Mar 22 02:19:26 2011 +0900 | |
@@ -762,10 +762,14 @@ | |
// Handle as URL, but remove spaces. Useful for copied/'p'asted URLs. | |
return url.replace(/\s*\n+\s*/g, ""); | |
+ let uri = util.createURI(url); | |
+ if (util.validateHost(uri)) | |
+ return uri.spec; |
This file contains hidden or 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
diff -r a9f2a2b7c47e common/content/commandline.js | |
--- a/common/content/commandline.js Fri Mar 25 23:04:39 2011 +0900 | |
+++ b/common/content/commandline.js Sat Mar 26 23:14:58 2011 +0900 | |
@@ -130,6 +130,7 @@ | |
this._promptWidget = document.getElementById("liberator-commandline-prompt-text"); | |
// the command bar which contains the current command | |
this._commandWidget = document.getElementById("liberator-commandline-command"); | |
+ this._bottombarWidget = document.getElementById("liberator-bottombar"); | |
this._messageBox = document.getElementById("liberator-message"); |
This file contains hidden or 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
let (cl = commandline) { | |
cl._autocompleteTimer = new Timer(200, 500, function autocompleteTell(tabPressed) { | |
if (events.feedingKeys || !options["autocomplete"]) | |
return; | |
if (!this._completions && this._commandWidget.value.length >= 2) { | |
this._completions = CommandLine.Completions(this._commandWidget.inputField); | |
this._completions.complete(false, false); | |
} |
This file contains hidden or 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
@echo off | |
echo "search tp4serv..." | |
tasklist | find "tp4serv.exe" >nul | |
if ERRORLEVEL 1 goto run | |
echo "shutdown tp4serv..." | |
taskkill /im tp4serv.exe /f >nul | |
if ERRORLEVEL 1 goto end |
This file contains hidden or 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
// =================================== | |
// Example | |
// =================================== | |
/** | |
* Point | |
* @class | |
* @augments Class | |
* @param {Number} x x-axis | |
* @param {Number} y y-axis | |
*/ |
This file contains hidden or 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
var $ = Proxy.ceate({ | |
get: function (_, name) { | |
return function () { | |
var args = Array.prototype.slice.call(arguments); | |
var func = function (o) { | |
return o[name].apply(o, args); | |
}; | |
return func; | |
}; | |
} |
This file contains hidden or 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
commands.addUserCommand(["memory[reports]"], "show memory reports", | |
show, | |
{}, | |
true); | |
function getMemoryInfo () { | |
const MRM = Cc["@mozilla.org/memory-reporter-manager;1"].getService(Ci.nsIMemoryReporterManager); | |
var data = [], | |
reports = MRM.enumerateReporters(); | |
while (reports.hasMoreElements()) { |
This file contains hidden or 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
const table = [ | |
0xC0, // 192(11000000) 2 byte | |
0xe0, // 224(11100000) 3 byte | |
0xf0 // 240(11110000) 4 byte | |
]; | |
/** | |
* Unicode文字をUTF-8バイト列に変換 | |
* @param {String} str |
This file contains hidden or 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
# source 読み込むこと前提 | |
# インラインやパイプ時に作成したディレクトリパスを出力する | |
# example | |
# 1. | |
# cd `mkdir foo` | |
# 2. | |
# tar -xzvf foo.tar.gz -C `mkdir foo` | |
# 3. | |
# mkdir foo bar hoge | xargs |
This file contains hidden or 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
var GooglePlus = null, | |
PostData = null; | |
(function init() { | |
if (typeof plugins.googlePlus == "undefined") { | |
window.setTimeout(init, 500); | |
} else { | |
GooglePlus = plugins.googlePlus; |