// Copyright 2012 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef UI_BASE_MODELS_SIMPLE_MENU_MODEL_H_ #define UI_BASE_MODELS_SIMPLE_MENU_MODEL_H_ #include <optional> #include <string> #include <vector> #include "base/component_export.h" #include "base/functional/callback_forward.h" #include "base/memory/raw_ptr.h" #include "base/memory/weak_ptr.h" #include "base/types/pass_key.h" #include "ui/base/accelerators/accelerator.h" #include "ui/base/models/image_model.h" #include "ui/base/models/menu_model.h" namespace user_education { class NewBadgeController; } class ChromeLabsViewController; namespace ui { class ButtonMenuItemModel; // Boolean-like value that determines if a menu item should be marked as // "new". Cannot be constructed in a truthy sate except by a fixed set of // classes, forcing the use of those classes (or wrappers around those classes) // in order to display as new. This prevents creating menu items which are // marked as "new" for an extended/indefinite period of time. class COMPONENT_EXPORT(UI_BASE) IsNewFeatureAtValue { … }; // A simple MenuModel implementation with an imperative API for adding menu // items. This makes it easy to construct fixed menus. Menus populated by // dynamic data sources may be better off implementing MenuModel directly. // The breadth of MenuModel is not exposed through this API. class COMPONENT_EXPORT(UI_BASE) SimpleMenuModel : public MenuModel { … }; } // namespace ui #endif // UI_BASE_MODELS_SIMPLE_MENU_MODEL_H_