Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(160)

Side by Side Diff: chrome/browser/extensions/context_menu_matcher.h

Issue 1871713002: Convert //chrome/browser/extensions from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and fix header Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_EXTENSIONS_CONTEXT_MENU_MATCHER_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_CONTEXT_MENU_MATCHER_H_
6 #define CHROME_BROWSER_EXTENSIONS_CONTEXT_MENU_MATCHER_H_ 6 #define CHROME_BROWSER_EXTENSIONS_CONTEXT_MENU_MATCHER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <map> 10 #include <map>
11 #include <memory>
11 #include <vector> 12 #include <vector>
12 13
13 #include "base/callback.h" 14 #include "base/callback.h"
14 #include "base/macros.h" 15 #include "base/macros.h"
15 #include "base/memory/scoped_ptr.h"
16 #include "chrome/browser/extensions/menu_manager.h" 16 #include "chrome/browser/extensions/menu_manager.h"
17 #include "ui/base/models/simple_menu_model.h" 17 #include "ui/base/models/simple_menu_model.h"
18 18
19 class ExtensionContextMenuBrowserTest; 19 class ExtensionContextMenuBrowserTest;
20 20
21 namespace content { 21 namespace content {
22 class BrowserContext; 22 class BrowserContext;
23 class RenderFrameHost; 23 class RenderFrameHost;
24 } 24 }
25 25
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 content::BrowserContext* browser_context_; 100 content::BrowserContext* browser_context_;
101 ui::SimpleMenuModel* menu_model_; 101 ui::SimpleMenuModel* menu_model_;
102 ui::SimpleMenuModel::Delegate* delegate_; 102 ui::SimpleMenuModel::Delegate* delegate_;
103 103
104 base::Callback<bool(const MenuItem*)> filter_; 104 base::Callback<bool(const MenuItem*)> filter_;
105 105
106 // Maps the id from a context menu item to the MenuItem's internal id. 106 // Maps the id from a context menu item to the MenuItem's internal id.
107 std::map<int, extensions::MenuItem::Id> extension_item_map_; 107 std::map<int, extensions::MenuItem::Id> extension_item_map_;
108 108
109 // Keep track of and clean up menu models for submenus. 109 // Keep track of and clean up menu models for submenus.
110 std::vector<scoped_ptr<ui::SimpleMenuModel>> extension_menu_models_; 110 std::vector<std::unique_ptr<ui::SimpleMenuModel>> extension_menu_models_;
111 111
112 DISALLOW_COPY_AND_ASSIGN(ContextMenuMatcher); 112 DISALLOW_COPY_AND_ASSIGN(ContextMenuMatcher);
113 }; 113 };
114 114
115 } // namespace extensions 115 } // namespace extensions
116 116
117 #endif // CHROME_BROWSER_EXTENSIONS_CONTEXT_MENU_MATCHER_H_ 117 #endif // CHROME_BROWSER_EXTENSIONS_CONTEXT_MENU_MATCHER_H_
OLDNEW
« no previous file with comments | « chrome/browser/extensions/content_verifier_browsertest.cc ('k') | chrome/browser/extensions/context_menu_matcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698