Adding support for surface views. also removed subplugin's dependency on ANPCanvas.
diff --git a/samples/BrowserPlugin/jni/audio/AudioPlugin.h b/samples/BrowserPlugin/jni/audio/AudioPlugin.h
index 2291f0f..129d33a 100644
--- a/samples/BrowserPlugin/jni/audio/AudioPlugin.h
+++ b/samples/BrowserPlugin/jni/audio/AudioPlugin.h
@@ -42,9 +42,15 @@
AudioPlugin(NPP inst);
virtual ~AudioPlugin();
virtual bool supportsDrawingModel(ANPDrawingModel);
- virtual void draw(ANPCanvas*);
virtual int16 handleEvent(const ANPEvent* evt);
private:
+ void draw(ANPCanvas*);
+ void drawPlugin(const ANPBitmap& bitmap, const ANPRectI& clip);
+
+ void handleTouch(int x, int y);
+ void invalActiveRect();
+ ANPPaint* getPaint(ANPRectF*);
+ ANPRectF* validTouch(int x, int y);
ANPRectF m_trackRect;
ANPRectF m_playRect;
@@ -63,13 +69,6 @@
bool m_activeTouch;
ANPRectF* m_activeTouchRect;
ANPRectF* m_activeRect;
-
- ANPPaint* getPaint(ANPRectF*);
- ANPRectF* validTouch(int x, int y);
- void handleTouch(int x, int y);
- void invalActiveRect();
-
-
};
#endif // audioPlugin__DEFINED