Skip to content

Instantly share code, notes, and snippets.

src/main/events.js

message: {type: , text: }

形式のメッセージを受け取る

コンテントスクリプトからメッセージを送信しても サイドバーで受信できてない気がする もしかしたら権限が足りない? この間のスタイル付きサイドバーのサンプルを確認してちゃんと

#mod alt -= LAlt RAlt
#mod alt += !!LAlt !!RAlt
key ~IL-A-LAlt = &Ignore
key IL-*IC-A-LAlt = $ToggleIME
key ~IL-A-RAlt = $ToggleIME &WaitKey(50) &SetImeConvStatus(0x0019) &WaitKey(0)
key IL-*IC-A-RAlt = &Ignore
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
#Persistent
SetTitleMatchMode RegEx
OnClipboardChange("ClipChanged")
return
var Selected = FV.SelectedItems();
if (Selected.Count == 0) {
return;
}
wsh.CurrentDirectory = FV.FolderItem.Path;
for (var i = Selected.Count - 1; i >= 0; i--) {
var filePath = api.GetDisplayNameOf(Selected.Item(i), SHGDN_FORPARSING | SHGDN_ORIGINAL);
var folderName = fso.GetBaseName(filePath);
if (! fso.FolderExists(folderName)) {
fso.CreateFolder(folderName);
@suiheilibe
suiheilibe / HistoireSearchMaint.html
Last active October 22, 2019 01:39
twitter-search-word-histoire-maintenance-tool
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
<script crossorigin src="https://unpkg.com/react@16/umd/react.development.js"></script>
<script crossorigin src="https://unpkg.com/react-dom@16/umd/react-dom.development.js"></script>
<script src="https://unpkg.com/@babel/standalone/babel.js"></script>
@suiheilibe
suiheilibe / TwitterSearchMaint.js
Last active December 2, 2018 01:39
TwitterSearchMaint.js
const process = require('process');
const util = require('util');
const request = require('request');
const asyncRequest = util.promisify(request);
const doTest = async (text) => {
const re = /^-from:(.+)/;
const result = re.exec(text);
if (! result) {
@suiheilibe
suiheilibe / RandomPassword.ts
Last active November 23, 2017 08:12
Generate random passwords with window.crypto.getRandomValues
interface CharMap {
[index: number]: boolean
}
class RandomUint8 {
private static readonly CHUNK_SIZE: number = 64;
private buffer: Uint8Array = new Uint8Array(RandomUint8.CHUNK_SIZE);
private index : number = RandomUint8.CHUNK_SIZE;
private crypto: Crypto;
constructor(crypto: Crypto) {
@suiheilibe
suiheilibe / Ex1.hs
Last active May 28, 2017 15:11
Coursera Machine Learning Ex1
module Main where
import Numeric.LinearAlgebra
import qualified Data.Vector.Storable as S
import qualified Data.Vector.Storable.Mutable as SM
import Control.Monad
import Control.Monad.ST
import Debug.Trace
import Graphics.Rendering.Chart.Easy hiding (Matrix, Vector, (<.>))
import Graphics.Rendering.Chart.Backend.Diagrams(toFile)
@suiheilibe
suiheilibe / twitter-searchword-histoire.md
Last active August 30, 2020 03:48
Twitter searchword for Histoire (freeware RPG)
イストワール
-from:2naoF4
-from:46P_7
-from:Histoire_V2
-from:Histoire_bot_
-from:Histy_nep
-from:Loads_of_Will_6
-from:MarisaRiyuka
-from:Nep_infoX

-from:Nepgear_V2

import Data.List
import Text.Printf
main :: IO ()
main = do
[m, n] <- map read <$> getArgs
print (map (printf "%f" . (fromRational :: Rational -> Double)) $ take (n + 1) $ solveNList (n, m, 1) :: [String])
-- putStrLn $ printf "%f" (fromRational $ solveN (n, m, 1) :: Double)
-- putStrLn $ printf "%f" (fromRational $ solveDfs (n, m, 1) :: Double)