OLD | NEW |
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_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ | 5 #ifndef CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ |
6 #define CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ | 6 #define CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <map> | 9 #include <map> |
10 #include <string> | 10 #include <string> |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 // int response, | 66 // int response, |
67 // const net::ResponseCookies& cookies, | 67 // const net::ResponseCookies& cookies, |
68 // const std::string& data) { | 68 // const std::string& data) { |
69 // bool enabled = response == 200; | 69 // bool enabled = response == 200; |
70 // const char* text = enabled ? "OK" : "ERROR"; | 70 // const char* text = enabled ? "OK" : "ERROR"; |
71 // proxy_->UpdateMenuItem(id_, enabled, ASCIIToUTF16(text)); | 71 // proxy_->UpdateMenuItem(id_, enabled, ASCIIToUTF16(text)); |
72 // } | 72 // } |
73 // void Start(const GURL* url, net::URLRequestContextGetter* context) { | 73 // void Start(const GURL* url, net::URLRequestContextGetter* context) { |
74 // fetcher_.reset(new URLFetcher(url, URLFetcher::GET, this)); | 74 // fetcher_.reset(new URLFetcher(url, URLFetcher::GET, this)); |
75 // fetcher_->SetRequestContext(context); | 75 // fetcher_->SetRequestContext(context); |
| 76 // fetcher_->AssociateWithRenderView( |
| 77 // proxy_->GetRenderViewHost()->process()->GetID(), |
| 78 // proxy_->GetRenderViewHost()->routing_id()); |
76 // fetcher_->Start(); | 79 // fetcher_->Start(); |
77 // } | 80 // } |
78 // | 81 // |
79 // private: | 82 // private: |
80 // URLFetcher fetcher_; | 83 // URLFetcher fetcher_; |
81 // RenderViewContextMenuProxy* proxy_; | 84 // RenderViewContextMenuProxy* proxy_; |
82 // int id_; | 85 // int id_; |
83 // }; | 86 // }; |
84 // | 87 // |
85 // void RenderViewContextMenu::AppendEditableItems() { | 88 // void RenderViewContextMenu::AppendEditableItems() { |
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
284 // An observer that disables menu items when print preview is active. | 287 // An observer that disables menu items when print preview is active. |
285 scoped_ptr<PrintPreviewContextMenuObserver> print_preview_menu_observer_; | 288 scoped_ptr<PrintPreviewContextMenuObserver> print_preview_menu_observer_; |
286 | 289 |
287 // Our observers. | 290 // Our observers. |
288 mutable ObserverList<RenderViewContextMenuObserver> observers_; | 291 mutable ObserverList<RenderViewContextMenuObserver> observers_; |
289 | 292 |
290 DISALLOW_COPY_AND_ASSIGN(RenderViewContextMenu); | 293 DISALLOW_COPY_AND_ASSIGN(RenderViewContextMenu); |
291 }; | 294 }; |
292 | 295 |
293 #endif // CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ | 296 #endif // CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_H_ |
OLD | NEW |