blob: 569f3f7f91df99ea958df1d79f837e7972eb28bd [file] [log] [blame]
Scroggof33d1532011-05-31 17:10:21 +00001/*
2 * Copyright (C) 2011 Skia
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#ifndef SkOSWindow_Android_DEFINED
18#define SkOSWindow_Android_DEFINED
19
20#include "SkWindow.h"
21#include "SkEvent.h"
22
djsollen@google.come32b5832011-06-13 16:58:40 +000023class GrContext;
24
Scroggof33d1532011-05-31 17:10:21 +000025class SkOSWindow : public SkWindow {
26public:
27 SkOSWindow(void*) {}
28 ~SkOSWindow() {}
djsollen@google.come32b5832011-06-13 16:58:40 +000029 bool attachGL() { return true; }
Scroggof33d1532011-05-31 17:10:21 +000030 void detachGL() {}
31 void presentGL() {}
djsollen@google.come32b5832011-06-13 16:58:40 +000032 virtual bool drawsToHardware() { return false; }
33 virtual bool setGrContext(GrContext*) { return false; }
34 virtual GrContext* getGrContext() { return NULL; }
35 virtual void changeZoomLevel(float delta) {}
Scroggof33d1532011-05-31 17:10:21 +000036protected:
37 // overrides from SkWindow
38 virtual void onHandleInval(const SkIRect&);
39 virtual void onSetTitle(const char title[]);
40
41private:
42 typedef SkWindow INHERITED;
43};
44
45#endif
46