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Created December 15, 2015 08:42
Bowerize
// This script will create a bower config and a git tag into all gaia libraries.
require('shelljs/global');
require('shelljs/make');
var IGNORE_LIST = ['uranus', 'gaia', 'kronos', 'B2G', 'Applications', 'Library', 'MyPlayground.playground', 'activation-server', 'base', 'experimental'];
cd('..');
ls('.').forEach(function(appdir) {
cd('/Users/alive/Projects');
@alivedise
alivedise / quest.json
Created November 23, 2015 14:23
quest database
{
"43":{
"chapterId":"4",
"questId":"43",
"type":"0",
"raidKind":"0",
"thumbnail":"20001",
"questName":"第4章 決戦、嵐の守護神",
"rank":"1",
"synopsis":"ルリアの力と感覚を頼りに、ティアマトを探す<span>Alive</span>一行。最も強い気配があるという場所へと向かうが、そこに居たのは嵐の大星晶獣ではなく……",
@alivedise
alivedise / system_dialog.js
Created November 19, 2015 03:53
SoftKey in SystemDialog
// H5SystemDialog
// For value selector to override.
H5SystemDialog.prototype.overrideSoftKeys = function(key) {
SoftKeysHelper.registerKeys(key, this.element);
}
// For value selector to restore
H5SystemDialog.prototype.registerSoftKeys = function(keys) {
SoftKeysHelper.registerKeys(this.registeredKeys, this.element);
};
@alivedise
alivedise / wee.js
Created September 14, 2015 15:19
wee js
'use strict';
(function(exports) {
exports.singleDraw = function() {
var rareGate = Math.floor((Math.random() * 100) + 1);
if (rareGate <= 82) {
drawR();
} else if (rareGate >=82 && rareGate <=97){
drawSR();
} else {
@alivedise
alivedise / hand.diff
Created August 14, 2015 08:44
patch for mozbrowserafterkeydown in HM
diff --git a/js/app_window.js b/js/app_window.js
index 19e2bf9..2c84ec4 100644
--- a/js/app_window.js
+++ b/js/app_window.js
@@ -967,6 +967,12 @@
}
};
+ AppWindow.prototype.handleKeydown = function(evt) {
+ if (this.valueSelector && this.valueSelector.isShown()) {
@alivedise
alivedise / patch.diff
Last active August 29, 2015 14:26
Gecko patch of sendEvent
# HG changeset patch
# User Alive Kuo <alegnadise@gmail.com>
# Date 1438156107 -28800
# Wed Jul 29 15:48:27 2015 +0800
# Node ID e88d55beece4d0aeb4158b072d248209d6c2adc1
# Parent d3228c82badd270863c56fc6b395e1ff452bb99a
[mq]: browserkeyevent
diff --git a/dom/browser-element/BrowserElementChildPreload.js b/dom/browser-element/BrowserElementChildPreload.js
--- a/dom/browser-element/BrowserElementChildPreload.js
{
"properties": {
"buildnumber": 52,
"product": "b2g",
"script_repo_revision": "production",
"branch": "gaia-try",
"repository": "",
"buildername": "b2g_ubuntu64_vm gaia-try opt test gaia-unit",
"stage_platform": "linux64_gecko",
"basedir": "/builds/slave/test",
{
"properties": {
"buildnumber": 88,
"product": "b2g",
"script_repo_revision": "production",
"branch": "gaia-try",
"repository": "",
"buildername": "b2g_ubuntu64_vm gaia-try opt test gaia-unit",
"stage_platform": "linux64_gecko",
"basedir": "/builds/slave/test",