There are wholesome actions that are not caused by boredom.
Any action arising out of compassion (karuna), loving kindness (maithri), sympathetic joy (mudita), equanimity (upeksha) is not born of boredom. (See: Bramhaviharas)
Being resident in the rupa jhanas (absorptions of form), and even deriving joy from them is not considered unwholesome, because it leads to insight.
When one enters a state of abhaya (fearlessness) one notices a total cessation of boredom. The mind is very content to stay idle, and do nothing. It isn't searching for peace in someone or something, it finds peace within itself.
The mind thus stilled doesn't engage in thoughtless action, such as humming a tune, or thinking about the past or future, or making idle gestures with the limbs and so on.
A mind thus stilled has no need for sensory entertainment, and will find it an idle and wasteful use of energy.
Dreams and intellectual or ambitious ideation can occupy one's mind too, but it is unwholesome, and could be viewed as forms of entertainment.
Hence my statement - "Entertainment is the distractive cure for fear masked as boredom"
There are several ways to describe enlightenment [SN 35.204] - one can describe it as a lack of need for external entertainment, but there are other descriptions. I'll offer one more here.
Enlightenment as an energy conservation model of the central nervous system.
All actions are born out of some root emotion, even so called neutral actions.
Let's examine some principal emotions in ascending order of fuel efficiency.
At the least fuel efficient and even dangerous end, there are anger and fear.
Anger - this is perhaps the most energetic of emotions, but also the least fuel efficient - it offers a sudden burst of energy but can deplete one's vital energy reserve (some systems call it qi or prana) rather quickly.
As an example, notice that in boxing matches, and 100m sprints, the athletes typically produce a lot of energy through anger and bravado, and one even notices this in their pre-game interviews. However they cannot sustain this energy for very long, and grow tired quickly, thus these events are short and furious. At the opposite end, marathon runners are generally mild mannered and don't carry the same kind of hatred towards the opponent - an angry and furious marathoner will find it hard to even complete the event.
Fear is similar to anger, and anger is in fact derived from fear, but it doesn't end when energy runs out. One can be too tired to be angry, but one is never too tired to be afraid, and this leads to depression where the sufferer totally lacks any energy. An angry person who grows tired will sustain that anger as fear.
At the most efficient end there are the peaceful emotions of compassion, loving kindness, sympathetic joy and equanimity. One can sustain compassion for a long while (even indefinitely) provided one doesn't let other emotions like despair eat into the energy body.
There is a psychological concept of compassion fatigue, but this isn't pure compassion, it is compassion tinged with fear. The fear depletes energy reserves and even compassion becomes impossible. This is why there are records of field surgeons in WW2 committing suicide after saving hundreds of lives.
Thus enlightenment is about having maximum energy in the CNS through the wise use of highly efficient emotional states.
The unenlightened who are unwise in their use of emotions will need the use of CNS stimulants to sustain their energy levels. Caffeine is the most common, anti-depressants and pharma drugs are in the middle, and at the extreme end there are psychotropics like Cocaine and other drugs.
Entertainment is a CNS stimulant like coffee. Some people wake up to dance music to feel happy, or dull their emotional pain with death metal.
To one who has control over their emotions, and already conserves the vital energy of prana or qi, all entertainment is frivolous, because it messes with what is already perfect.
Enlightenment can thus be also viewed as a lack of need for CNS stimulants, including entertainment.
In Buddhism, anything that doesn't lead to enlightenment must be eschewed.