~ubuntu-branches/ubuntu/trusty/moodle/trusty

« back to all changes in this revision

Viewing changes to lib/yui/src/blocks/js/blocks.js

  • Committer: Package Import Robot
  • Author(s): Thijs Kinkhorst
  • Date: 2014-01-21 13:40:52 UTC
  • mfrom: (1.1.13)
  • Revision ID: package-import@ubuntu.com-20140121134052-ym2qvsp2cd9vq0p6
Tags: 2.5.4-1
* New upstream release, fixing security issues:
  - MSA-14-0001 Config passwords visibility issue [CVE-2014-0008]
  - MSA-14-0002 Group constraints lacking in "login as" [CVE-2014-0009]
  - MSA-14-0003 CSRF vulnerability in profile fields [CVE-2014-0010]
* Move /var/lib/moodle directory into package.
* Revert back to bundled yui3. Unfortunately, version in Debian and
  of upstream are not compatible (closes: #735312).

Show diffs side-by-side

added added

removed removed

Lines of Context:
61
61
 
62
62
        // See if we are missing either of block regions,
63
63
        // if yes we need to add an empty one to use as target
64
 
        if (blockregionlist.size() != this.get('regions').length) {
 
64
        if (blockregionlist.size() !== this.get('regions').length) {
65
65
            var blockregion = Y.Node.create('<div></div>')
66
66
                .addClass(CSS.BLOCKREGION);
67
67
            var regioncontent = Y.Node.create('<div></div>')
88
88
            // Setting blockregion as droptarget (the case when it is empty)
89
89
            // The region-post (the right one)
90
90
            // is very narrow, so add extra padding on the left to drop block on it.
91
 
            var tar = new Y.DD.Drop({
 
91
            new Y.DD.Drop({
92
92
                node: blockregionnode.one('div.'+CSS.REGIONCONTENT),
93
93
                groups: this.groups,
94
94
                padding: '40 240 40 240'
197
197
        // Moving from empty region-content towards the opposite one,
198
198
        // hide empty one (only for region-pre, region-post areas at the moment).
199
199
        regionname = this.get_region_id(drop.ancestor('div.'+CSS.BLOCKREGION));
200
 
        if (this.dragsourceregion.all('.'+CSS.BLOCK).size() == 0 && this.dragsourceregion.get('id').match(/(region-pre|region-post)/i)) {
 
200
        if (this.dragsourceregion.all('.'+CSS.BLOCK).size() === 0 && this.dragsourceregion.get('id').match(/(region-pre|region-post)/i)) {
201
201
            if (!documentbody.hasClass('side-'+regionname+'-only')) {
202
202
                documentbody.addClass('side-'+regionname+'-only');
203
203
            }
377
377
M.core_blocks = M.core_blocks || {};
378
378
M.core_blocks.init_dragdrop = function(params) {
379
379
    M.core.blockdraganddrop.init(params);
380
 
};
 
 
b'\\ No newline at end of file'
 
380
};