blob: 6975e07bdc3e5082fb7bfafbe8529e3d57435479 [file] [log] [blame]
Tom Anderson80d3ad42022-05-03 12:09:271// Copyright 2022 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
Tom Anderson4ee83742022-07-14 20:58:415#ifndef UI_LINUX_LINUX_UI_FACTORY_H_
6#define UI_LINUX_LINUX_UI_FACTORY_H_
Tom Anderson80d3ad42022-05-03 12:09:277
Tom Anderson074a5d412022-08-30 18:54:538#include "base/component_export.h"
Tom Andersond6ecb872022-09-02 19:13:039#include "base/features.h"
Tom Anderson80d3ad42022-05-03 12:09:2710
Tom Anderson992d9872022-07-14 21:24:5011namespace ui {
12
13class LinuxUi;
Tom Andersoncd61f3b22022-09-14 16:27:4914class LinuxUiTheme;
Tom Anderson074a5d412022-08-30 18:54:5315enum class SystemTheme : int;
Tom Anderson80d3ad42022-05-03 12:09:2716
Tom Andersond6ecb872022-09-02 19:13:0317// TODO(https://crbug.com/1317782): Remove in M110.
18COMPONENT_EXPORT(LINUX_UI_FACTORY)
19extern const base::Feature kAllowQt;
20
Tom Anderson074a5d412022-08-30 18:54:5321// Returns a LinuxUi for the default toolkit. May create a LinuxUi instance if
22// one does not exist. May return nullptr if no toolkits are available.
23COMPONENT_EXPORT(LINUX_UI_FACTORY)
24LinuxUi* GetDefaultLinuxUi();
25
Tom Anderson975c84e12022-09-14 22:17:5826// Returns a LinuxUiTheme for the default toolkit. May create a LinuxUiTheme
27// instance if one does not exist. May return nullptr if no toolkits are
28// available. Should only be used by tests or LinuxUi internals. Otherwise, use
29// the accessors in LinuxUiTheme instead.
30COMPONENT_EXPORT(LINUX_UI_FACTORY)
31LinuxUiTheme* GetDefaultLinuxUiTheme();
32
Tom Anderson074a5d412022-08-30 18:54:5333COMPONENT_EXPORT(LINUX_UI_FACTORY)
Tom Andersoncd61f3b22022-09-14 16:27:4934LinuxUiTheme* GetLinuxUiTheme(SystemTheme system_theme);
Tom Anderson074a5d412022-08-30 18:54:5335
36COMPONENT_EXPORT(LINUX_UI_FACTORY)
37SystemTheme GetDefaultSystemTheme();
Tom Anderson992d9872022-07-14 21:24:5038
39} // namespace ui
Tom Anderson80d3ad42022-05-03 12:09:2740
Tom Anderson4ee83742022-07-14 20:58:4141#endif // UI_LINUX_LINUX_UI_FACTORY_H_