Last active
May 24, 2019 07:45
-
-
Save justfdot/ff060ace80b0012858e4b0b3284927a6 to your computer and use it in GitHub Desktop.
Configuration file for cVim chromium extention
This file contains 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
set smoothscroll | |
let scrollstep = 130 | |
set autohidecursor | |
let hintcharacters = "qwertyuiopasdfghjkl;zxcvbnm" | |
set defaultnewtabpage | |
map t :tabnew<CR> | |
unmap b | |
"imap <C-o> editWithVim | |
"let vimcommand = 'sakura --execute "nvim /tmp/cvim"' | |
let blacklists = ["https://www.duolingo.com/*","https://lingualeo.com/*","http://vue.local/*","http://127.0.0.1/*","http://192.168.88.1/*","http://www.speedcoder.net/*","http://www.hdseason.ru/*","https://pikabu.ru/*"] | |
site '*://bigbang-tv.net/*' { | |
TBBT -> {{ | |
document.getElementsByClassName('itemNext')[0].click(); | |
}} | |
TBBTPlayFullscreen -> {{ | |
console.log(window.frameElement); | |
window.playerInstance.play(); | |
window.playerInstance.setFullscreen(); | |
}} | |
map <C-.> :call TBBT<CR> | |
map <C-/> :call TBBTPlayFullscreen<CR> | |
} | |
site '*://www.youtube.com/*' { | |
YTFullscreen -> {{ | |
document.getElementById('movie_player').webkitRequestFullscreen(); | |
}} | |
YTGetRidOfAd -> {{ | |
var banner = document.getElementsByClassName('adDisplay'); | |
if(banner.length){ | |
banner[0].remove(); | |
}else{ | |
document.getElementsByClassName('videoAdUiSkipButton')[0].click(); | |
} | |
}} | |
map <A-f> :call YTFullscreen<CR> | |
map <A-d> :call YTGetRidOfAd<CR> | |
} | |
site '*://rutube.ru/*' { | |
RTFullscreen -> {{ | |
document.querySelector('video').requestFullscreen(); | |
}} | |
map <A-f> :call RTFullscreen<CR> | |
} | |
" site '*://rutube.ru/*' { | |
" RTSeek(direction, seconds) -> {{ | |
" seconds = seconds || 3; | |
" var player = document.getElementById('video_frame'); | |
" player.contentWindow.postMessage(JSON.stringify({ | |
" type: 'player:relativelySeek', | |
" data: { | |
" time: direction + seconds | |
" } | |
" }), '*'); | |
" }} | |
" RTFullscreen -> {{ | |
" var player = document.getElementById('video_frame'); | |
" player.contentWindow.postMessage(JSON.stringify({ | |
" type: 'player:changeFullscreen', | |
" data: { | |
" isFullscreen: true | |
" } | |
" }), '*'); | |
" }} | |
" RTPause -> {{ | |
" var html5player = document.getElementById('rutubePlayerHolder_RutubeHtml5_api'); | |
" html5player.paused ? html5player.play() : html5player.pause() | |
" }} | |
" map <Left> :call RTSeek('-')<CR> | |
" map <C-Left> :call RTSeek('-', 7)<CR> | |
" map <S-Left> :call RTSeek('-', 30)<CR> | |
" map <Right> :call RTSeek('+')<CR> | |
" map <C-Right> :call RTSeek('+', 7)<CR> | |
" map <S-Right> :call RTSeek('+', 30)<CR> | |
" map <Space> :call RTPause<CR> | |
" map <A-f> :call RTFullscreen<CR> | |
" } | |
site '*://fanserials.tv/*' { | |
FSSeek(seconds) -> {{ | |
var api = flowplayer(); | |
api.seek(api.video.time + seconds); | |
}} | |
FSFullscreen -> {{ | |
var api = flowplayer(); | |
api.fullscreen(); | |
}} | |
map <Left> :call FSSeek(-3)<CR> | |
map <C-Left> :call FSSeek(-7)<CR> | |
map <Right> :call FSSeek(3)<CR> | |
map <C-Right> :call FSSeek(7)<CR> | |
map <A-f> :call FSFullscreen<CR> | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment