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.
1 //
2 // Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
3 // Use of this source code is governed by a BSD-style license that can be
4 // found in the LICENSE file.
5 //
7 // Image11.h: Defines the rx::Image11 class, which acts as the interface to
8 // the actual underlying resources of a Texture
10 #ifndef LIBGLESV2_RENDERER_IMAGE11_H_
11 #define LIBGLESV2_RENDERER_IMAGE11_H_
13 #include "libGLESv2/renderer/Image.h"
15 #include "common/debug.h"
17 namespace gl
18 {
19 class Framebuffer;
20 }
22 namespace rx
23 {
24 class Renderer;
25 class Renderer11;
26 class TextureStorageInterface2D;
27 class TextureStorageInterfaceCube;
29 class Image11 : public Image
30 {
31 public:
32 Image11();
33 virtual ~Image11();
35 static Image11 *makeImage11(Image *img);
37 static void generateMipmap(Image11 *dest, Image11 *src);
39 virtual bool isDirty() const;
41 virtual bool updateSurface(TextureStorageInterface2D *storage, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
42 virtual bool updateSurface(TextureStorageInterfaceCube *storage, int face, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
44 virtual bool redefine(Renderer *renderer, GLint internalformat, GLsizei width, GLsizei height, bool forceRelease);
46 virtual bool isRenderableFormat() const;
47 DXGI_FORMAT getDXGIFormat() const;
49 virtual void loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
50 GLint unpackAlignment, const void *input);
51 virtual void loadCompressedData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
52 const void *input);
54 virtual void copy(GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, gl::Framebuffer *source);
56 protected:
57 HRESULT map(D3D11_MAPPED_SUBRESOURCE *map);
58 void unmap();
60 private:
61 DISALLOW_COPY_AND_ASSIGN(Image11);
63 ID3D11Texture2D *getStagingTexture();
64 unsigned int getStagingSubresource();
65 void createStagingTexture();
67 Renderer11 *mRenderer;
69 DXGI_FORMAT mDXGIFormat;
70 ID3D11Texture2D *mStagingTexture;
71 unsigned int mStagingSubresource;
72 };
74 }
76 #endif // LIBGLESV2_RENDERER_IMAGE11_H_