mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
This CL plumbs resize notifications from SkyView to Engine. I've taken the opportunity to reorganize how notifications generated by SkyView are plumbed to the GPU and UI threads. This approach should reduce the amount of plumbing needed for new notifications. R=eseidel@chromium.org Review URL: https://codereview.chromium.org/880443003
46 lines
963 B
C++
46 lines
963 B
C++
// Copyright 2015 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 SKY_SHELL_SHELL_H_
|
|
#define SKY_SHELL_SHELL_H_
|
|
|
|
#include "base/macros.h"
|
|
#include "base/memory/ref_counted.h"
|
|
#include "base/memory/scoped_ptr.h"
|
|
|
|
namespace base {
|
|
class Thread;
|
|
class SingleThreadTaskRunner;
|
|
}
|
|
|
|
namespace sky {
|
|
namespace shell {
|
|
class Engine;
|
|
class Rasterizer;
|
|
class SkyView;
|
|
|
|
class Shell {
|
|
public:
|
|
explicit Shell(scoped_refptr<base::SingleThreadTaskRunner> java_task_runner);
|
|
~Shell();
|
|
|
|
void Init();
|
|
|
|
private:
|
|
scoped_refptr<base::SingleThreadTaskRunner> java_task_runner_;
|
|
scoped_ptr<base::Thread> gpu_thread_;
|
|
scoped_ptr<base::Thread> ui_thread_;
|
|
|
|
scoped_ptr<SkyView> view_;
|
|
scoped_ptr<Rasterizer> rasterizer_;
|
|
scoped_ptr<Engine> engine_;
|
|
|
|
DISALLOW_COPY_AND_ASSIGN(Shell);
|
|
};
|
|
|
|
} // namespace shell
|
|
} // namespace sky
|
|
|
|
#endif // SKY_SHELL_SHELL_H_
|