From 95b1b718d4da1eb073017d74110e9922ba8a5b43 Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Thu, 24 Nov 2011 00:30:50 +0100 Subject: [PATCH] Remove image preloading --- changelog | 2 +- script.coffee | 29 ----------------------------- 2 files changed, 1 insertion(+), 30 deletions(-) diff --git a/changelog b/changelog index 49590ee57..caab61480 100644 --- a/changelog +++ b/changelog @@ -3,7 +3,7 @@ master initiate 4chan X earlier performance improvements regular expressions based filter - do not preload images automatically + remove image preloading automatically reload expanded pictures on error update archives redirections for /diy/, /pol/ and /sci/ handle bans with the thread updater diff --git a/script.coffee b/script.coffee index 59db6faf8..bb8570d7c 100644 --- a/script.coffee +++ b/script.coffee @@ -20,7 +20,6 @@ config = 'Image Auto-Gif': [false, 'Animate gif thumbnails'] 'Image Expansion': [true, 'Expand images'] 'Image Hover': [false, 'Show full image on mouseover'] - 'Image Preloading': [false, 'Preload Images'] 'Sauce': [true, 'Add sauce to images'] 'Reveal Spoilers': [false, 'Replace spoiler thumbnails by the original thumbnail'] Monitoring: @@ -2065,31 +2064,6 @@ imgHover = src: @parentNode.href $.add d.body, ui.el -imgPreloading = - init: -> - unless controls = $.id 'imgControls' - controls = $.el 'div', - id: 'imgControls' - form = $ 'body > form' - $.prepend form, controls - - label = $.el 'label', - innerHTML: 'Preload Images' - $.on $('input', label), 'click', imgPreloading.click - $.add controls, label - - g.callbacks.push imgPreloading.node - - click: -> - if imgPreloading.on = @checked - for thumb in $$ 'img[md5]:last-child' - imgPreloading.preload thumb - node: (root) -> - return unless imgPreloading.on and thumb = $ 'img[md5]:last-child', root - imgPreloading.preload thumb - preload: (thumb) -> - $.el 'img', src: thumb.parentNode.href - imgGif = init: -> g.callbacks.push (root) -> @@ -2401,9 +2375,6 @@ Main = if conf['Thread Stats'] threadStats.init() - if conf['Image Preloading'] - imgPreloading.init() - if conf['Reply Navigation'] nav.init()