Code Duplication    Length = 37-37 lines in 2 locations

public/js/tinymce/themes/modern/theme.js 1 location

@@ 4341-4377 (lines=37) @@
4338
        self$$1.aria('label', settings.title);
4339
        self$$1._fullscreen = false;
4340
      },
4341
      recalc: function () {
4342
        var self$$1 = this;
4343
        var statusbar$$1 = self$$1.statusbar;
4344
        var layoutRect, width, x, needsRecalc;
4345
        if (self$$1._fullscreen) {
4346
          self$$1.layoutRect(funcs.getWindowSize());
4347
          self$$1.layoutRect().contentH = self$$1.layoutRect().innerH;
4348
        }
4349
        self$$1._super();
4350
        layoutRect = self$$1.layoutRect();
4351
        if (self$$1.settings.title && !self$$1._fullscreen) {
4352
          width = layoutRect.headerW;
4353
          if (width > layoutRect.w) {
4354
            x = layoutRect.x - Math.max(0, width / 2);
4355
            self$$1.layoutRect({
4356
              w: width,
4357
              x: x
4358
            });
4359
            needsRecalc = true;
4360
          }
4361
        }
4362
        if (statusbar$$1) {
4363
          statusbar$$1.layoutRect({ w: self$$1.layoutRect().innerW }).recalc();
4364
          width = statusbar$$1.layoutRect().minW + layoutRect.deltaW;
4365
          if (width > layoutRect.w) {
4366
            x = layoutRect.x - Math.max(0, width - layoutRect.w);
4367
            self$$1.layoutRect({
4368
              w: width,
4369
              x: x
4370
            });
4371
            needsRecalc = true;
4372
          }
4373
        }
4374
        if (needsRecalc) {
4375
          self$$1.recalc();
4376
        }
4377
      },
4378
      initLayoutRect: function () {
4379
        var self$$1 = this;
4380
        var layoutRect = self$$1._super();

public/js/tinymce/themes/inlite/theme.js 1 location

@@ 3819-3855 (lines=37) @@
3816
        self$$1.aria('label', settings.title);
3817
        self$$1._fullscreen = false;
3818
      },
3819
      recalc: function () {
3820
        var self$$1 = this;
3821
        var statusbar$$1 = self$$1.statusbar;
3822
        var layoutRect, width, x, needsRecalc;
3823
        if (self$$1._fullscreen) {
3824
          self$$1.layoutRect(funcs.getWindowSize());
3825
          self$$1.layoutRect().contentH = self$$1.layoutRect().innerH;
3826
        }
3827
        self$$1._super();
3828
        layoutRect = self$$1.layoutRect();
3829
        if (self$$1.settings.title && !self$$1._fullscreen) {
3830
          width = layoutRect.headerW;
3831
          if (width > layoutRect.w) {
3832
            x = layoutRect.x - Math.max(0, width / 2);
3833
            self$$1.layoutRect({
3834
              w: width,
3835
              x: x
3836
            });
3837
            needsRecalc = true;
3838
          }
3839
        }
3840
        if (statusbar$$1) {
3841
          statusbar$$1.layoutRect({ w: self$$1.layoutRect().innerW }).recalc();
3842
          width = statusbar$$1.layoutRect().minW + layoutRect.deltaW;
3843
          if (width > layoutRect.w) {
3844
            x = layoutRect.x - Math.max(0, width - layoutRect.w);
3845
            self$$1.layoutRect({
3846
              w: width,
3847
              x: x
3848
            });
3849
            needsRecalc = true;
3850
          }
3851
        }
3852
        if (needsRecalc) {
3853
          self$$1.recalc();
3854
        }
3855
      },
3856
      initLayoutRect: function () {
3857
        var self$$1 = this;
3858
        var layoutRect = self$$1._super();