summaryrefslogtreecommitdiff
path: root/data/extensions/https-everywhere-eff@eff.org/chrome/content/toolbar_button_binding.xml
blob: 1981b3a2b9137a51d6f1a65b8793a2b5121519d0 (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
<?xml version="1.0"?>
<!-- 
Toolbar button needs to be extended to show a counter for the number of
rulesets applied, and this can be done using XBL. 

See: https://developer.mozilla.org/en-US/docs/XBL
-->
<bindings xmlns="http://www.mozilla.org/xbl"
    xmlns:xbl="http://www.mozilla.org/xbl"
    xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">

  <binding id="https-everywhere-binding">
    <content>
      <!-- ruleset counter (rscounter) and rulesets applied (rsapplied) -->
      <xul:stack id="rscounter">
        <xul:label id="rsapplied" xbl:inherits="value=rulesetsApplied" />
      </xul:stack>

      <!-- 
      Https everywhere toolbar button is already defined; just use its settings. 
      TODO: Look into any issues with oncommand/oncontext.
      -->
      <xul:toolbarbutton 
          class="https-everywhere-button toolbarbutton-1 chromeclass-toolbar-additional"
          flex="1" 
          allowevents="true"
          xbl:inherits="type,crop,image,label,accesskey,command,align,dir,pack,orient,wrap">

        <children includes="menupopup" />
      </xul:toolbarbutton>
    </content>
  </binding>
</bindings>