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