root_view_mac.h 740 B

12345678910111213141516171819202122232425262728293031323334
  1. // Copyright (c) 2018 GitHub, Inc.
  2. // Use of this source code is governed by the MIT license that can be
  3. // found in the LICENSE file.
  4. #ifndef ATOM_BROWSER_UI_COCOA_ROOT_VIEW_MAC_H_
  5. #define ATOM_BROWSER_UI_COCOA_ROOT_VIEW_MAC_H_
  6. #include "ui/views/view.h"
  7. namespace atom {
  8. class NativeWindow;
  9. class RootViewMac : public views::View {
  10. public:
  11. explicit RootViewMac(NativeWindow* window);
  12. ~RootViewMac() override;
  13. // views::View:
  14. void Layout() override;
  15. gfx::Size GetMinimumSize() const override;
  16. gfx::Size GetMaximumSize() const override;
  17. private:
  18. // Parent window, weak ref.
  19. NativeWindow* window_;
  20. DISALLOW_COPY_AND_ASSIGN(RootViewMac);
  21. };
  22. } // namespace atom
  23. #endif // ATOM_BROWSER_UI_COCOA_ROOT_VIEW_MAC_H_