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

Side by Side Diff: chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.mm

Issue 2921693002: [Mac] Hide the page info when navigating (Closed)
Patch Set: Created 3 years, 6 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
« no previous file with comments | « chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #import "chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.h" 5 #import "chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.h"
6 6
7 #import <AppKit/AppKit.h> 7 #import <AppKit/AppKit.h>
8 8
9 #include <cmath> 9 #include <cmath>
10 10
(...skipping 12 matching lines...) Expand all
23 #import "chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.h" 23 #import "chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.h"
24 #import "chrome/browser/ui/cocoa/page_info/permission_selector_button.h" 24 #import "chrome/browser/ui/cocoa/page_info/permission_selector_button.h"
25 #include "chrome/browser/ui/page_info/permission_menu_model.h" 25 #include "chrome/browser/ui/page_info/permission_menu_model.h"
26 #import "chrome/browser/ui/tab_dialogs.h" 26 #import "chrome/browser/ui/tab_dialogs.h"
27 #include "chrome/common/url_constants.h" 27 #include "chrome/common/url_constants.h"
28 #include "chrome/grit/chromium_strings.h" 28 #include "chrome/grit/chromium_strings.h"
29 #include "chrome/grit/generated_resources.h" 29 #include "chrome/grit/generated_resources.h"
30 #include "chrome/grit/theme_resources.h" 30 #include "chrome/grit/theme_resources.h"
31 #include "components/strings/grit/components_chromium_strings.h" 31 #include "components/strings/grit/components_chromium_strings.h"
32 #include "components/strings/grit/components_strings.h" 32 #include "components/strings/grit/components_strings.h"
33 #include "content/public/browser/navigation_handle.h"
33 #include "content/public/browser/page_navigator.h" 34 #include "content/public/browser/page_navigator.h"
34 #include "content/public/browser/ssl_host_state_delegate.h" 35 #include "content/public/browser/ssl_host_state_delegate.h"
35 #include "content/public/browser/web_contents.h" 36 #include "content/public/browser/web_contents.h"
36 #include "content/public/common/url_constants.h" 37 #include "content/public/common/url_constants.h"
37 #include "extensions/common/constants.h" 38 #include "extensions/common/constants.h"
38 #include "skia/ext/skia_utils_mac.h" 39 #include "skia/ext/skia_utils_mac.h"
39 #import "third_party/google_toolbox_for_mac/src/AppKit/GTMUILocalizerAndLayoutTw eaker.h" 40 #import "third_party/google_toolbox_for_mac/src/AppKit/GTMUILocalizerAndLayoutTw eaker.h"
40 #import "ui/base/cocoa/a11y_util.h" 41 #import "ui/base/cocoa/a11y_util.h"
41 #include "ui/base/cocoa/cocoa_base_utils.h" 42 #include "ui/base/cocoa/cocoa_base_utils.h"
42 #import "ui/base/cocoa/controls/hyperlink_button_cell.h" 43 #import "ui/base/cocoa/controls/hyperlink_button_cell.h"
(...skipping 1286 matching lines...) Expand 10 before | Expand all | Expand 10 after
1329 void PageInfoUIBridge::SetCookieInfo(const CookieInfoList& cookie_info_list) { 1330 void PageInfoUIBridge::SetCookieInfo(const CookieInfoList& cookie_info_list) {
1330 [bubble_controller_ setCookieInfo:cookie_info_list]; 1331 [bubble_controller_ setCookieInfo:cookie_info_list];
1331 } 1332 }
1332 1333
1333 void PageInfoUIBridge::SetPermissionInfo( 1334 void PageInfoUIBridge::SetPermissionInfo(
1334 const PermissionInfoList& permission_info_list, 1335 const PermissionInfoList& permission_info_list,
1335 ChosenObjectInfoList chosen_object_info_list) { 1336 ChosenObjectInfoList chosen_object_info_list) {
1336 [bubble_controller_ setPermissionInfo:permission_info_list 1337 [bubble_controller_ setPermissionInfo:permission_info_list
1337 andChosenObjects:std::move(chosen_object_info_list)]; 1338 andChosenObjects:std::move(chosen_object_info_list)];
1338 } 1339 }
1340
1341 void PageInfoUIBridge::DidFinishNavigation(
1342 content::NavigationHandle* navigation_handle) {
1343 if (!navigation_handle->IsInMainFrame() ||
1344 !navigation_handle->HasCommitted()) {
1345 return;
1346 }
1347 // If the browser navigates to another page, close the bubble.
1348 [bubble_controller_ close];
1349 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/page_info/page_info_bubble_controller.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698