diff options
author | tsxv478 <vt0451@yandex.ru> | 2022-09-27 11:47:02 +0300 |
---|---|---|
committer | tsxv478 <vt0451@yandex.ru> | 2022-09-27 11:47:02 +0300 |
commit | 66f6efcef9f8f83a1d270003beee7aceb60dcfaf (patch) | |
tree | 370659390d3fee8910795bad71c2fb767dabaca1 | |
parent | 9b7c59e32d5980856f3e8a066dbf5e84ff61d030 (diff) |
play external
-rw-r--r-- | config.def.h | 2 | ||||
-rw-r--r-- | surf.c | 10 |
2 files changed, 12 insertions, 0 deletions
diff --git a/config.def.h b/config.def.h index 305957d..edf61b1 100644 --- a/config.def.h +++ b/config.def.h @@ -141,6 +141,8 @@ static Key keys[] = { { MODKEY, GDK_KEY_f, spawn, SETPROP("_SURF_FIND", "_SURF_FIND", PROMPT_FIND) }, { MODKEY, GDK_KEY_slash, spawn, SETPROP("_SURF_FIND", "_SURF_FIND", PROMPT_FIND) }, + { MODKEY, GDK_KEY_w, playexternal, { 0 } }, + { 0, GDK_KEY_Escape, stop, { 0 } }, { MODKEY, GDK_KEY_c, stop, { 0 } }, @@ -243,6 +243,7 @@ static void togglefullscreen(Client *c, const Arg *a); static void togglecookiepolicy(Client *c, const Arg *a); static void toggleinspector(Client *c, const Arg *a); static void find(Client *c, const Arg *a); +static void playexternal(Client *c, const Arg *a); /* Buttons */ static void clicknavigate(Client *c, const Arg *a, WebKitHitTestResult *h); @@ -2028,6 +2029,15 @@ clickexternplayer(Client *c, const Arg *a, WebKitHitTestResult *h) spawn(c, &arg); } +void +playexternal(Client *c, const Arg *a) +{ + Arg arg; + + arg = (Arg)VIDEOPLAY(geturi(c)); + spawn(c, &arg); +} + int main(int argc, char *argv[]) { |