#ifndef CONTENT_BROWSER_RENDERER_HOST_MEDIA_MIDI_DISPATCHER_HOST_H_
#define CONTENT_BROWSER_RENDERER_HOST_MEDIA_MIDI_DISPATCHER_HOST_H_
#include "content/public/browser/browser_message_filter.h"
class GURL;
namespace content {
class BrowserContext;
class MidiDispatcherHost : public BrowserMessageFilter {
public:
MidiDispatcherHost(int render_process_id, BrowserContext* browser_context);
virtual bool OnMessageReceived(const IPC::Message& message,
bool* message_was_ok) OVERRIDE;
virtual void OverrideThreadForMessage(
const IPC::Message& message, BrowserThread::ID* thread) OVERRIDE;
protected:
virtual ~MidiDispatcherHost();
private:
void OnRequestSysExPermission(int render_view_id,
int bridge_id,
const GURL& origin,
bool user_gesture);
void OnCancelSysExPermissionRequest(int render_view_id,
int bridge_id,
const GURL& requesting_frame);
void WasSysExPermissionGranted(int render_view_id,
int bridge_id,
bool success);
int render_process_id_;
BrowserContext* browser_context_;
DISALLOW_COPY_AND_ASSIGN(MidiDispatcherHost);
};
}
#endif