summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas F <ovdev@fratti.ch>2019-12-23 16:10:21 +0100
committerwm4 <1387750+wm4@users.noreply.github.com>2019-12-23 16:38:41 +0100
commit7ed70f925be815c853c54e73e2789b7094becf3a (patch)
tree76260da3b0f9a921e7e8f013163355107a62d383
parent091ee9d770e63b90a0705cfda1972fcc25b6909c (diff)
downloadmpv-7ed70f925be815c853c54e73e2789b7094becf3a.tar.bz2
mpv-7ed70f925be815c853c54e73e2789b7094becf3a.tar.xz
osc: add option to disable santa hat
A minority of users have expressed a dislike of hats, calling them "cancer [that] don't belong in software" describing the people who add them as "shitty circlejerks" and "chucklefuck." While I personally disagree with those opinions, it's probably easier to let them have it their way. For that reason this adds the option `greenandgrumpy` to the osc, which allows users to disable the hat.
-rw-r--r--DOCS/man/osc.rst5
-rw-r--r--player/lua/osc.lua5
2 files changed, 8 insertions, 2 deletions
diff --git a/DOCS/man/osc.rst b/DOCS/man/osc.rst
index 4538fbb4d4..4d1222abaa 100644
--- a/DOCS/man/osc.rst
+++ b/DOCS/man/osc.rst
@@ -368,6 +368,11 @@ Configurable Options
Supports ``left`` and ``right`` which will place the controls on those
respective sides.
+``greenandgrumpy``
+ Default: no
+
+ Set to ``yes`` to reduce festivity (i.e. disable santa hat in December.)
+
Script Commands
~~~~~~~~~~~~~~~
diff --git a/player/lua/osc.lua b/player/lua/osc.lua
index 17816dd507..7af75c2bda 100644
--- a/player/lua/osc.lua
+++ b/player/lua/osc.lua
@@ -46,7 +46,8 @@ local user_opts = {
boxmaxchars = 80, -- title crop threshold for box layout
boxvideo = false, -- apply osc_param.video_margins to video
windowcontrols = "auto", -- whether to show window controls
- windowcontrols_alignment = "right" -- which side to show window controls on
+ windowcontrols_alignment = "right", -- which side to show window controls on
+ greenandgrumpy = false, -- disable santa hat
}
-- read options from config and command-line
@@ -2469,7 +2470,7 @@ function tick()
end
-- Santa hat
- if is_december then
+ if is_december and not user_opts.greenandgrumpy then
for i, line in ipairs(santa_hat_lines) do
ass:new_event()
ass:append(line_prefix .. line)