Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
2011-01-27 Alexey Marinichev <amarinichev@chromium.org>
        Reviewed by Kenneth Russell.

        Add a callback to WebGraphicsContext3D that is called when a context is lost
        https://bugs.webkit.org/show_bug.cgi?id=53153

        * public/WebGraphicsContext3D.h:
        (WebKit::WebGraphicsContext3D::setContextLostCallback):

Canonical link: https://commits.webkit.org/67071@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@76862 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
webkit-commit-queue committed Jan 28, 2011
1 parent 14ca306 commit 67ac65c
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Source/WebKit/chromium/ChangeLog
@@ -1,3 +1,13 @@
2011-01-27 Alexey Marinichev <amarinichev@chromium.org>

Reviewed by Kenneth Russell.

Add a callback to WebGraphicsContext3D that is called when a context is lost
https://bugs.webkit.org/show_bug.cgi?id=53153

* public/WebGraphicsContext3D.h:
(WebKit::WebGraphicsContext3D::setContextLostCallback):

2011-01-27 Mihai Parparita <mihaip@chromium.org>

Unreviewed, fixed upstream Chromium build
Expand Down
7 changes: 7 additions & 0 deletions Source/WebKit/chromium/public/WebGraphicsContext3D.h
Expand Up @@ -76,6 +76,11 @@ class WebGraphicsContext3D : public WebNonCopyable {
bool canRecoverFromContextLoss;
};

class WebGraphicsContextLostCallback {
public:
virtual void onContextLost() = 0;
};

// This destructor needs to be public so that using classes can destroy instances if initialization fails.
virtual ~WebGraphicsContext3D() {}

Expand Down Expand Up @@ -328,6 +333,8 @@ class WebGraphicsContext3D : public WebNonCopyable {
virtual void deleteRenderbuffer(unsigned) = 0;
virtual void deleteShader(unsigned) = 0;
virtual void deleteTexture(unsigned) = 0;

virtual void setContextLostCallback(WebGraphicsContextLostCallback* callback) {}
};

} // namespace WebKit
Expand Down

0 comments on commit 67ac65c

Please sign in to comment.