b6b6fc3bfd
Closes #762
45 lines
1.4 KiB
C++
45 lines
1.4 KiB
C++
// Copyright (c) 2013 GitHub, Inc.
|
|
// Use of this source code is governed by the MIT license that can be
|
|
// found in the LICENSE file.
|
|
|
|
#ifndef ATOM_APP_ATOM_MAIN_DELEGATE_H_
|
|
#define ATOM_APP_ATOM_MAIN_DELEGATE_H_
|
|
|
|
#include "brightray/common/main_delegate.h"
|
|
#include "brightray/common/content_client.h"
|
|
|
|
namespace atom {
|
|
|
|
class AtomMainDelegate : public brightray::MainDelegate {
|
|
public:
|
|
AtomMainDelegate();
|
|
~AtomMainDelegate();
|
|
|
|
protected:
|
|
// content::ContentMainDelegate:
|
|
virtual bool BasicStartupComplete(int* exit_code) OVERRIDE;
|
|
virtual void PreSandboxStartup() OVERRIDE;
|
|
virtual content::ContentBrowserClient* CreateContentBrowserClient() OVERRIDE;
|
|
virtual content::ContentRendererClient*
|
|
CreateContentRendererClient() OVERRIDE;
|
|
|
|
// brightray::MainDelegate:
|
|
virtual scoped_ptr<brightray::ContentClient> CreateContentClient() OVERRIDE;
|
|
virtual void AddDataPackFromPath(
|
|
ui::ResourceBundle* bundle, const base::FilePath& pak_dir) OVERRIDE;
|
|
#if defined(OS_MACOSX)
|
|
virtual void OverrideChildProcessPath() OVERRIDE;
|
|
virtual void OverrideFrameworkBundlePath() OVERRIDE;
|
|
#endif
|
|
|
|
private:
|
|
brightray::ContentClient content_client_;
|
|
scoped_ptr<content::ContentBrowserClient> browser_client_;
|
|
scoped_ptr<content::ContentRendererClient> renderer_client_;
|
|
|
|
DISALLOW_COPY_AND_ASSIGN(AtomMainDelegate);
|
|
};
|
|
|
|
} // namespace atom
|
|
|
|
#endif // ATOM_APP_ATOM_MAIN_DELEGATE_H_
|