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.
2 /*
3 * Copyright 2006 The Android Open Source Project
4 *
5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file.
7 */
10 #ifndef SkDisplayList_DEFINED
11 #define SkDisplayList_DEFINED
13 #include "SkOperand.h"
14 #include "SkIntArray.h"
15 #include "SkBounder.h"
16 #include "SkRect.h"
18 class SkAnimateMaker;
19 class SkActive;
20 class SkApply;
21 class SkDrawable;
22 class SkGroup;
24 class SkDisplayList : public SkBounder {
25 public:
26 SkDisplayList();
27 virtual ~SkDisplayList();
28 void append(SkActive* );
29 void clear() { fDrawList.reset(); }
30 int count() { return fDrawList.count(); }
31 bool draw(SkAnimateMaker& , SkMSec time);
32 #ifdef SK_DUMP_ENABLED
33 void dump(SkAnimateMaker* maker);
34 void dumpInner(SkAnimateMaker* maker);
35 static int fIndent;
36 static int fDumpIndex;
37 #endif
38 int findGroup(SkDrawable* match, SkTDDrawableArray** list,
39 SkGroup** parent, SkGroup** found, SkTDDrawableArray** grandList);
40 SkDrawable* get(int index) { return fDrawList[index]; }
41 SkMSec getTime() { return fInTime; }
42 SkTDDrawableArray* getDrawList() { return &fDrawList; }
43 void hardReset();
44 virtual bool onIRect(const SkIRect& r);
45 void reset();
46 void remove(SkActive* );
47 #ifdef SK_DEBUG
48 void validate();
49 #else
50 void validate() {}
51 #endif
52 static int SearchForMatch(SkDrawable* match, SkTDDrawableArray** list,
53 SkGroup** parent, SkGroup** found, SkTDDrawableArray**grandList);
54 static bool SearchGroupForMatch(SkDrawable* draw, SkDrawable* match,
55 SkTDDrawableArray** list, SkGroup** parent, SkGroup** found, SkTDDrawableArray** grandList,
56 int &index);
57 public:
58 SkIRect fBounds;
59 SkIRect fInvalBounds;
60 bool fDrawBounds;
61 bool fHasUnion;
62 bool fUnionBounds;
63 private:
64 SkTDDrawableArray fDrawList;
65 SkTDActiveArray fActiveList;
66 SkMSec fInTime;
67 friend class SkEvents;
68 };
70 #endif // SkDisplayList_DEFINED