summaryrefslogtreecommitdiff
path: root/src/desktop/rule/layerRule/LayerRuleEffectContainer.cpp
blob: 17394239d0a8b0b0eb121798947ee0b8b780bae4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#include "LayerRuleEffectContainer.hpp"

using namespace Desktop;
using namespace Desktop::Rule;

//
SP<CLayerRuleEffectContainer> Rule::layerEffects() {
    static SP<CLayerRuleEffectContainer> container = makeShared<CLayerRuleEffectContainer>();
    return container;
}

static const std::vector<std::string> EFFECT_STRINGS = {
    "__internal_none",        //
    "no_anim",                //
    "blur",                   //
    "blur_popups",            //
    "ignore_alpha",           //
    "dim_around",             //
    "xray",                   //
    "animation",              //
    "order",                  //
    "above_lock",             //
    "no_screen_share",        //
    "__internal_last_static", //
};

// This is here so that if we change the rules, we get reminded to update
// the strings.
static_assert(LAYER_RULE_EFFECT_LAST_STATIC == 11);

CLayerRuleEffectContainer::CLayerRuleEffectContainer() : IEffectContainer<eLayerRuleEffect>(std::vector<std::string>{EFFECT_STRINGS}) {
    ;
}