2 * Copyright 2017 Google Inc.
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
8 #ifndef Window_ios_DEFINED
9 #define Window_ios_DEFINED
11 #include "include/private/SkChecksum.h"
12 #include "src/core/SkTDynamicHash.h"
13 #include "tools/sk_app/Window.h"
15 #import <UIKit/UIKit.h>
19 class Window_ios : public Window {
24 ~Window_ios() override { this->closeWindow(); }
28 void setTitle(const char*) override {}
29 void show() override {}
31 bool attach(BackendType) override;
33 void onInval() override;
35 static void PaintWindow();
37 UIWindow* uiWindow() { return fWindow; }
39 static Window_ios* MainWindow() { return gWindow; }
46 static Window_ios* gWindow; // there should be only one
48 using INHERITED = Window;
53 //////////////////////////////////////////////////////////////////////////
55 @interface MainView : UIView
57 - (MainView*)initWithWindow:(sk_app::Window_ios*)initWindow;