Index: ui/gl/async_pixel_transfer_delegate.h |
diff --git a/ui/gl/async_pixel_transfer_delegate.h b/ui/gl/async_pixel_transfer_delegate.h |
index 44bcbcb21ba590abaf5ae4184a948cd98c38af19..8fed021bb9e5d654627bc4938ea44069924d94b0 100644 |
--- a/ui/gl/async_pixel_transfer_delegate.h |
+++ b/ui/gl/async_pixel_transfer_delegate.h |
@@ -112,6 +112,14 @@ class GL_EXPORT AsyncPixelTransferDelegate { |
virtual uint32 GetTextureUploadCount() = 0; |
virtual base::TimeDelta GetTotalTextureUploadTime() = 0; |
+ // ProcessPendingTransfers() will be called at a good time |
+ // to process a small amount of pending transfer work while |
+ // NeedsProcessPendingTransfers() returns true. Implementations |
+ // that can't dispatch work to separate threads should use |
+ // this to avoid blocking the caller thread inappropriately. |
+ virtual void ProcessPendingTransfers() = 0; |
+ virtual bool NeedsProcessPendingTransfers() = 0; |
+ |
protected: |
AsyncPixelTransferDelegate() {} |
// For testing, as returning scoped_ptr wouldn't work with MOCK_METHOD. |