Projet

Général

Profil

Paste
Télécharger (1,23 ko) Statistiques
| Branche: | Révision:

root / drupal7 / sites / all / themes / adaptivetheme / at_core / scripts / check-all.js @ 74f6bef0

1
/**
2
 * Just a wee script to give some nice check all check boxes to the
3
 * Unset CSS extension checkboxes, there can be a lot of them.
4
 */
5
(function ($) {
6
  Drupal.behaviors.ATcheckAll = {
7
    attach: function (context) {
8
      // Core
9
      $(":input[name=core_check_all]").click(function()
10
      {
11
        var checked_status = this.checked;
12
        $("input.drupal-core-css-file").each(function()
13
        {
14
          this.checked = checked_status;
15
        });
16
      });
17
      // Contrib
18
      $(":input[name=contrib_check_all]").click(function()
19
      {
20
        var checked_status = this.checked;
21
        $("input.contrib-module-css-file").each(function()
22
        {
23
          this.checked = checked_status;
24
        });
25
      });
26
      // Library
27
      $(":input[name=libraries_check_all]").click(function()
28
      {
29
        var checked_status = this.checked;
30
        $("input.library-css-file").each(function()
31
        {
32
          this.checked = checked_status;
33
        });
34
      });
35
      // User
36
      $(":input[name=explicit_check_all]").click(function()
37
      {
38
        var checked_status = this.checked;
39
        $("input.user-defined-css-file").each(function()
40
        {
41
          this.checked = checked_status;
42
        });
43
      });
44
    }
45
  };
46
})(jQuery);