Sat, 03 Jan 2015 20:18:00 +0100
Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.
michael@0 | 1 | /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ |
michael@0 | 2 | /* This Source Code Form is subject to the terms of the Mozilla Public |
michael@0 | 3 | * License, v. 2.0. If a copy of the MPL was not distributed with this |
michael@0 | 4 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
michael@0 | 5 | |
michael@0 | 6 | #include "nsISupports.idl" |
michael@0 | 7 | |
michael@0 | 8 | interface nsIVisualEventTracerLog; |
michael@0 | 9 | |
michael@0 | 10 | /** |
michael@0 | 11 | * Interface to control the visual event tracer feature. The result |
michael@0 | 12 | * is a log of various events that are monitored by a custom code |
michael@0 | 13 | * instrumentation around the mozilla code base. |
michael@0 | 14 | */ |
michael@0 | 15 | |
michael@0 | 16 | [builtinclass, scriptable, uuid(713ee3ca-95e0-4085-8616-f6d64a9508ad)] |
michael@0 | 17 | interface nsIVisualEventTracer : nsISupports |
michael@0 | 18 | { |
michael@0 | 19 | /** |
michael@0 | 20 | * Start the logging now. No affect if already started. |
michael@0 | 21 | * Current backlog is deleted by this call otherwise. |
michael@0 | 22 | * |
michael@0 | 23 | * @param minBacklogSeconds |
michael@0 | 24 | * Manimum time to keep the backlog. Entries of the log are discarded |
michael@0 | 25 | * when their age is more then value of this argument. |
michael@0 | 26 | */ |
michael@0 | 27 | void start(in unsigned long minBacklogSeconds); |
michael@0 | 28 | |
michael@0 | 29 | /** |
michael@0 | 30 | * Stop the logging now. Backlog is kept in memory. |
michael@0 | 31 | */ |
michael@0 | 32 | void stop(); |
michael@0 | 33 | |
michael@0 | 34 | /** |
michael@0 | 35 | * Obtain the log. This can be called whenever you want. |
michael@0 | 36 | * |
michael@0 | 37 | * @return |
michael@0 | 38 | * Result is an object that keeps snaphot of the log from |
michael@0 | 39 | * time this method has been called. You can then access |
michael@0 | 40 | * the log using the object. Calling stop() on the tracer |
michael@0 | 41 | * doesn't delete this log. |
michael@0 | 42 | */ |
michael@0 | 43 | nsIVisualEventTracerLog snapshot(); |
michael@0 | 44 | }; |
michael@0 | 45 | |
michael@0 | 46 | [builtinclass, scriptable, uuid(8ec6e36d-6cba-400b-bcd6-454679f5f75a)] |
michael@0 | 47 | interface nsIVisualEventTracerLog : nsISupports |
michael@0 | 48 | { |
michael@0 | 49 | /** |
michael@0 | 50 | * JSON string of the log. Use JSON.parse to get it as an object. |
michael@0 | 51 | */ |
michael@0 | 52 | readonly attribute ACString JSONString; |
michael@0 | 53 | |
michael@0 | 54 | /** |
michael@0 | 55 | * Write the JSON string returned by JSONString to the log defined by |
michael@0 | 56 | * the environment variable MOZ_PROFILING_FILE. |
michael@0 | 57 | */ |
michael@0 | 58 | void writeToProfilingFile(); |
michael@0 | 59 | }; |