Comment 101 for bug 434476

Revision history for this message
In , Karlt (karlt) wrote :

Comment on attachment 8424521
Implement WakeLockListener on Linux to disable screensaver while video is playing

>+nsCOMPtr<nsIDOMMozWakeLockListener> WakeLockListener::sSingleton = nullptr;

AFAIK compilers are not clever enough to avoid running a constructor for this
at startup, and so this should be avoided (comment 12 and comment 14). It
will be used soon after startup anyway, but I don't know the details on how
the different reads benefit from read-ahead. There are people who have worked
hard to remove similar variables, so let's not add one here. I guess
either StaticRefPtr or manual ref counting can be used.