Last Comment Bug 726347 - [Page Thumbnails] add preference to disable capturing thumbnails in the background
: [Page Thumbnails] add preference to disable capturing thumbnails in the backg...
Status: VERIFIED FIXED
:
Product: Firefox
Classification: Client Software
Component: General (show other bugs)
: Trunk
: All All
: -- normal with 4 votes (vote)
: Firefox 14
Assigned To: Tim Taubert [:ttaubert]
:
Mentors:
: 795666 (view as bug list)
Depends on: 753755
Blocks: 497543
  Show dependency treegraph
 
Reported: 2012-02-11 12:42 PST by Mats Palmgren (vacation)
Modified: 2014-10-07 07:42 PDT (History)
13 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---
verified


Attachments
temporary hack to "turn it off" (854 bytes, patch)
2012-02-11 12:44 PST, Mats Palmgren (vacation)
no flags Details | Diff | Splinter Review
patch v1 (3.25 KB, patch)
2012-04-11 10:50 PDT, Tim Taubert [:ttaubert]
dao+bmo: review-
Details | Diff | Splinter Review
patch v2 (1.11 KB, patch)
2012-04-11 11:12 PDT, Tim Taubert [:ttaubert]
dao+bmo: review-
Details | Diff | Splinter Review
patch v3 (2.04 KB, patch)
2012-04-11 11:27 PDT, Tim Taubert [:ttaubert]
dao+bmo: review-
Details | Diff | Splinter Review
patch v4 (768 bytes, patch)
2012-04-11 11:37 PDT, Tim Taubert [:ttaubert]
dao+bmo: review+
akeybl: approval‑mozilla‑beta-
Details | Diff | Splinter Review
Thumbnails (895.95 KB, text/plain)
2012-05-05 13:17 PDT, asukacharming
no flags Details

Description Mats Palmgren (vacation) 2012-02-11 12:42:13 PST
It's really painful to try to debug anything to do with painting
with thumbnail drawWindow() calls happening every couple of seconds.
I can't find a way to turn this feature off...

I would like a preference, or environment variable, or configure
build option that turns off thumbnails.
Comment 1 Mats Palmgren (vacation) 2012-02-11 12:44:04 PST
Created attachment 596369 [details] [diff] [review]
temporary hack to "turn it off"
Comment 2 Mats Palmgren (vacation) 2012-02-17 17:19:40 PST
I have no intention of fixing this myself.
Comment 3 Ed Morley [:emorley] 2012-02-18 03:04:13 PST
(Sorry was fixing a number of bugs on which people had forgotten to set the assignee, and was going by patch author)
Comment 4 Tim Taubert [:ttaubert] 2012-04-11 10:50:27 PDT
Created attachment 614060 [details] [diff] [review]
patch v1

Patch that introduces a pref to disable capturing thumbnails in the background for debugging/profiling purposes.
Comment 5 Dão Gottwald [:dao] 2012-04-11 11:02:24 PDT
Comment on attachment 614060 [details] [diff] [review]
patch v1

We shouldn't sync this. I'm not sure this needs a default value in firefox.js either...
Comment 6 Tim Taubert [:ttaubert] 2012-04-11 11:12:46 PDT
Created attachment 614068 [details] [diff] [review]
patch v2

(In reply to Dão Gottwald [:dao] from comment #5)
> We shouldn't sync this. I'm not sure this needs a default value in
> firefox.js either...

Yeah, we should be fine without all that for debugging purposes.
Comment 7 Dão Gottwald [:dao] 2012-04-11 11:14:36 PDT
Comment on attachment 614068 [details] [diff] [review]
patch v2

getBoolPref will throw now, which you'll need to catch.
Comment 8 Tim Taubert [:ttaubert] 2012-04-11 11:27:01 PDT
Created attachment 614076 [details] [diff] [review]
patch v3

(In reply to Dão Gottwald [:dao] from comment #7)
> getBoolPref will throw now, which you'll need to catch.

Right...
Comment 9 Dão Gottwald [:dao] 2012-04-11 11:34:46 PDT
Comment on attachment 614076 [details] [diff] [review]
patch v3

What's the point of the extra method? This should be sufficient:

try {
  if (Services.prefs.getBoolPref(this._prefCapturingDisabled))
    return;
} catch (e) {}

You don't really need this._prefCapturingDisabled either...
Comment 10 Tim Taubert [:ttaubert] 2012-04-11 11:37:56 PDT
Created attachment 614085 [details] [diff] [review]
patch v4
Comment 11 Tim Taubert [:ttaubert] 2012-04-11 12:53:20 PDT
https://hg.mozilla.org/integration/fx-team/rev/51fe735d19a9
Comment 12 Girish Sharma [:Optimizer] 2012-04-11 14:36:42 PDT
If I set it off, then my new tab page thumbnails will never update? (or not show at all if there isn't one before the disabling of the pref)
Comment 13 Tim Taubert [:ttaubert] 2012-04-11 14:38:16 PDT
Exactly.
Comment 14 Tim Taubert [:ttaubert] 2012-04-13 03:24:40 PDT
https://hg.mozilla.org/mozilla-central/rev/51fe735d19a9
Comment 15 Tim Taubert [:ttaubert] 2012-04-14 04:22:07 PDT
Comment on attachment 614085 [details] [diff] [review]
patch v4

[Approval Request Comment]
Risk to taking this patch (and alternatives if risky): very low risk, tiny patch
String changes made by this patch: none

I think we should backport this patch for Fx 12 and set the new preference to true - to disable capturing thumbnails at all. The thumbnail service is active in Fx 12 but there's not a single piece of code using it. We have patches for Fx 13/14 that will minimize the performance impact of this service but I think it doesn't make sense to backport them to 12.

If users change their prefs to test the early version of about:newtab in Fx 12 they might as well flip this pref to have thumbnails captured.
Comment 16 Alex Keybl [:akeybl] 2012-04-16 09:41:15 PDT
Comment on attachment 614085 [details] [diff] [review]
patch v4

[Triage Comment]
The only reason to approve this for Beta 12 would be due to debug pain noted in comment 0. Since that was first noted 2 months ago, it's obviously not that painful. Let's leave things as is.
Comment 17 Virgil Dicu [:virgil] [QA] 2012-04-24 07:30:08 PDT
Mozilla/5.0 (X11; Linux i686; rv:14.0) Gecko/20120424 Firefox/14.0a1

Verified manually on latest Nightly. no thumbnails are captured for newly visited pages if the pref ("browser.pagethumbnails.capturing_disabled") is set to true.

verified on Ubuntu 11.10, Mac OS 10.6, Windows 7.
Comment 18 Jim Jeffery not reading bug-mail 1/2/11 2012-05-02 09:10:10 PDT
(In reply to Virgil Dicu [:virgil] [QA] from comment #17)
> Mozilla/5.0 (X11; Linux i686; rv:14.0) Gecko/20120424 Firefox/14.0a1
> 
> Verified manually on latest Nightly. no thumbnails are captured for newly
> visited pages if the pref ("browser.pagethumbnails.capturing_disabled") is
> set to true.
> 
> verified on Ubuntu 11.10, Mac OS 10.6, Windows 7.

This is a 'hidden' pref, i.e. has to be manually added ?
Comment 19 Tim Taubert [:ttaubert] 2012-05-02 09:11:51 PDT
Yes, you have to create it yourself as a boolean with the value 'true'.
Comment 20 CruNcher 2012-05-03 09:49:57 PDT
will this automatically delete the already created thumbnails after restart in the new thumb place or is it needed to do that manually ?
Comment 21 Tim Taubert [:ttaubert] 2012-05-03 10:01:26 PDT
This will only prevent new thumbnails from being created. Existing ones can be deleted by clearing all your browsing history or removing the "thumbnails" directory from your profile.
Comment 22 asukacharming 2012-05-05 13:17:22 PDT
Created attachment 621338 [details]
Thumbnails
Comment 23 Jim Jeffery not reading bug-mail 1/2/11 2012-05-07 06:10:09 PDT
Adding the pref and enabling does stop the storage of new thumbnails, but ...

New folders are being created every day or even more often.
Since adding the pref looking at the Properties of the Thumbnails Folder on Win7 x64
0 Files, 256 Folders

Setting the pref to true should also prevent the creation of additional useless folders.  

Should a new bug be filed to prevent the creation of 'Empty Folder' (s) ?
Comment 24 Virtual_ManPL [:Virtual] - (ni? me) 2012-05-17 10:44:47 PDT
Is there any reason why this preference in hidden in about:config ?
Comment 25 dickvl 2012-11-21 20:20:57 PST
The MDN doc page of the browser.pagethumbnails.capturing_disabled pref shows the wrong meaning of this pref.

https://developer.mozilla.org/en-US/docs/Mozilla/Preferences/Preference_reference/browser.pagethumbnails.capturing_disabled

true (default)
    The application creates screenshots of visited web pages.
false
    The application doesn't create screenshots of visited web pages.
Comment 26 Tim Taubert [:ttaubert] 2012-11-22 02:27:00 PST
(In reply to dickvl from comment #25)
> The MDN doc page of the browser.pagethumbnails.capturing_disabled pref shows
> the wrong meaning of this pref.

Thanks for noticing! I just fixed the documentation.
Comment 27 Stefan Weiss [:sir_none] 2014-10-07 07:42:21 PDT
*** Bug 795666 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.