NicoNicoPlaylist & nnp_cooperation.js update

CodeRepos の userscripts に NicoNicoPlaylist の最新版があったので CommandEvent を仕込んでみた。んだけど Fx 以外のこと考えてなかった。まぁ addEventListener してるだけだから副作用はでないと思うけど…。

http://coderepos.org/share/browser/lang/javascript/userscripts/niconicoplaylist.user.js?

最新版だと loop, random, fullscreen の 3 つのモードが使えるようになっているので nnp_cooperation.js のほうはそれに対応。あと NicoNicoPlaylist が仕込む要素の中身が微妙に違うみたいなので XPath 式を変更。

http://coderepos.org/share/browser/lang/javascript/vimperator-plugins/trunk/nnp_cooperation.js

以下の 3 つのコマンドでそれぞれのモードを切り替える。

  • :nnprandom
  • :nnploop
  • :nnpfullscreen

そして :nnpgetlist の caption 部分をちょっと変更。今流してるタイトルとモードも表示するようにしてみた。

わかりづらいかもしれないけど caption の右端のカッコの中にある R とか F とかがモード表示ね。それぞれ以下の略記にした。

  • R
    • random
  • L
    • loop
  • F
    • fullscreen