レジが遅いからというのが理由。計6回、21時間働いて首になった。
まー確かに遅いけども、オーナーと同じくらいですやん。
店長に「ようやく慣れてきたね」といわれたし、
そのうち早くなる感じもあったんだがなあ。
んで、他の店で深夜募集してるから紹介するといわれたが、
深夜はちょっと無理なので断った。
むー、ヤマトは首にならないように明日から頑張ろうと思う。
ずいぶんと前からSleipnirを使っているが、その機能については全然つかってなかった。
ちょっと見てみただけでも膨大な量の機能があって驚いた。
英単語をしらべるのに便利な機能があったが、excite翻訳なので、
google翻訳がいいなぁと思い、JScriptスクリプトの練習がてらちょっと書いてみた。
IEしか動かないが、自分で使うぶんにはこれでいいかな。
なお、Scriptをキーボードやマウスジェスチャから使えるようにするには、
公式からUserAction Extensionプラグインを導入する必要がある。
(暫く、sleipnir単体で動くんじゃないかと弄くってた。なんで外部に出してるのか意味わからん。)
/*********************************************************************
Sleipnir用スクリプト Google英訳にて英訳
by Linux_ekyu
**********************************************************************
[動作]
[改訂履歴]
ver.0.1 2010/02/08
・選択されてる箇所をgoogle翻訳にて英訳する
・geckoエンジンには未対応。
*********************************************************************/
WScript = sleipnir; // おまじない?
var pnir;
var document;
var id;
pnir = new ActiveXObject('Sleipnir.API');
id = pnir.GetDocumentID(pnir.ActiveIndex);
document = pnir.GetDocumentObject(id);
if (document == null) {
pnir.MessageBox('documentオブジェクトを作成できません');
quit_script();
}
// check a word selection is empty
// todo: IEのみなので他でも使えるようにする
if( document.selection.createRange().text == '' ){
quit_script();
}
// open new window for a selected word.
var dicUrl = 'http://translate.google.com/translate_t?hl=ja&lr=lang_ja&oe=UTF-8&q=retrieved&num=50&um=1&ie=UTF-8&sa=N&tab=wT#en|ja|';
dicUrl += document.selection.createRange().text;
// check google翻訳 is open
// http://translate.google.com/translate_t?
// #en|ja|
var tabCnt = pnir.GetCount;
for(var i=0; i<tabCnt; ++i){
var pageId = pnir.GetDocumentID(i);
var window = pnir.GetWindowObject(pageId);
var strUrl = String(window.location.href);
window = null;
var idx = strUrl.indexOf('http://translate.google.com/translate_t?');
var lang = strUrl.indexOf('#en|ja');
if( idx == 0 && lang > 0){
pnir.Navigate(pageId, dicUrl);
pnir.ActiveIndex = i;
quit_script();
}
}
var newId = pnir.NewWindow(dicUrl, true);
quit_script();
function quit_script() {
document = null;
id = null;
pnir = null;
WScript.Quit();
}