mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
- Canvas classes moved from gfx namespace to skia namespace. - Include files moved from WebKit/port to third_party/WebKit. - Add IsMediaPlayerAvailable() webkit_glue function. - WebWidgetDelegate::GetContainingWindow() changed to WebWidgetDelegate::GetContainingView(). - Changed HCURSOR to WebCursor and HWND to gfx::NativeWindow. - WebPluginInfo 'file' member changed to 'path'. - Use base::LazyInstance for static object in BrowserPluginInstance (should be done at some point for BrowserPluginLib and BrowserPluginList as well). - BrowserPluginStream::Open() adds additional 'request_is_seekable' parameter. - Add PLUGIN_QUIRK_PATCH_SETCURSOR support to BrowserWebPluginDelegateImpl. git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@6 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
71 lines
2.1 KiB
C++
71 lines
2.1 KiB
C++
// Copyright (c) 2008 The Chromium Embedded Framework Authors.
|
|
// Portions copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
// found in the LICENSE file.
|
|
|
|
#ifndef _BROWSER_PLUGIN_STREAM_URL_H
|
|
#define _BROWSER_PLUGIN_STREAM_URL_H
|
|
|
|
#include "browser_plugin_stream.h"
|
|
|
|
#include "webkit/glue/webplugin.h"
|
|
#include "googleurl/src/gurl.h"
|
|
|
|
namespace NPAPI {
|
|
|
|
class BrowserPluginInstance;
|
|
|
|
// A NPAPI Stream based on a URL.
|
|
class BrowserPluginStreamUrl : public BrowserPluginStream,
|
|
public WebPluginResourceClient {
|
|
public:
|
|
// Create a new stream for sending to the plugin by fetching
|
|
// a URL. If notifyNeeded is set, then the plugin will be notified
|
|
// when the stream has been fully sent to the plugin. Initialize
|
|
// must be called before the object is used.
|
|
BrowserPluginStreamUrl(int resource_id,
|
|
const GURL &url,
|
|
BrowserPluginInstance *instance,
|
|
bool notify_needed,
|
|
void *notify_data);
|
|
virtual ~BrowserPluginStreamUrl();
|
|
|
|
// Stop sending the stream to the client.
|
|
// Overrides the base Close so we can cancel our fetching the URL if
|
|
// it is still loading.
|
|
virtual bool Close(NPReason reason);
|
|
|
|
virtual WebPluginResourceClient* AsResourceClient() {
|
|
return static_cast<WebPluginResourceClient*>(this);
|
|
}
|
|
|
|
virtual void CancelRequest();
|
|
|
|
//
|
|
// WebPluginResourceClient methods
|
|
//
|
|
void WillSendRequest(const GURL& url);
|
|
void DidReceiveResponse(const std::string& mime_type,
|
|
const std::string& headers,
|
|
uint32 expected_length,
|
|
uint32 last_modified,
|
|
bool request_is_seekable,
|
|
bool* cancel);
|
|
void DidReceiveData(const char* buffer, int length, int data_offset);
|
|
void DidFinishLoading();
|
|
void DidFail();
|
|
bool IsMultiByteResponseExpected() {
|
|
return seekable();
|
|
}
|
|
|
|
private:
|
|
GURL url_;
|
|
int id_;
|
|
|
|
DISALLOW_EVIL_CONSTRUCTORS(BrowserPluginStreamUrl);
|
|
};
|
|
|
|
} // namespace NPAPI
|
|
|
|
#endif // _BROWSER_PLUGIN_STREAM_URL_H
|