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

Side by Side Diff: ios/chrome/browser/ui/downloads/download_manager_controller.mm

Issue 2912863005: Use MDCTypography instead of MDFRobotoFontLoader directly. (Closed)
Patch Set: Tentative fix for ManualTextFramerTest 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
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 "ios/chrome/browser/ui/downloads/download_manager_controller.h" 5 #import "ios/chrome/browser/ui/downloads/download_manager_controller.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 17 matching lines...) Expand all
28 #import "ios/chrome/browser/ui/network_activity_indicator_manager.h" 28 #import "ios/chrome/browser/ui/network_activity_indicator_manager.h"
29 #include "ios/chrome/browser/ui/ui_util.h" 29 #include "ios/chrome/browser/ui/ui_util.h"
30 #import "ios/chrome/browser/ui/uikit_ui_util.h" 30 #import "ios/chrome/browser/ui/uikit_ui_util.h"
31 #include "ios/chrome/grit/ios_strings.h" 31 #include "ios/chrome/grit/ios_strings.h"
32 #include "ios/public/provider/chrome/browser/chrome_browser_provider.h" 32 #include "ios/public/provider/chrome/browser/chrome_browser_provider.h"
33 #import "ios/public/provider/chrome/browser/native_app_launcher/native_app_metad ata.h" 33 #import "ios/public/provider/chrome/browser/native_app_launcher/native_app_metad ata.h"
34 #import "ios/public/provider/chrome/browser/native_app_launcher/native_app_white list_manager.h" 34 #import "ios/public/provider/chrome/browser/native_app_launcher/native_app_white list_manager.h"
35 #import "ios/third_party/material_components_ios/src/components/ActivityIndicato r/src/MaterialActivityIndicator.h" 35 #import "ios/third_party/material_components_ios/src/components/ActivityIndicato r/src/MaterialActivityIndicator.h"
36 #import "ios/third_party/material_components_ios/src/components/Buttons/src/Mate rialButtons.h" 36 #import "ios/third_party/material_components_ios/src/components/Buttons/src/Mate rialButtons.h"
37 #import "ios/third_party/material_components_ios/src/components/Typography/src/M aterialTypography.h" 37 #import "ios/third_party/material_components_ios/src/components/Typography/src/M aterialTypography.h"
38 #import "ios/third_party/material_roboto_font_loader_ios/src/src/MaterialRobotoF ontLoader.h"
39 #include "ios/web/public/browser_state.h" 38 #include "ios/web/public/browser_state.h"
40 #include "ios/web/public/web_state/web_state.h" 39 #include "ios/web/public/web_state/web_state.h"
41 #include "ios/web/public/web_thread.h" 40 #include "ios/web/public/web_thread.h"
42 #include "net/base/filename_util.h" 41 #include "net/base/filename_util.h"
43 #include "net/http/http_response_headers.h" 42 #include "net/http/http_response_headers.h"
44 #include "net/http/http_util.h" 43 #include "net/http/http_util.h"
45 #include "net/url_request/url_fetcher.h" 44 #include "net/url_request/url_fetcher.h"
46 #include "net/url_request/url_fetcher_delegate.h" 45 #include "net/url_request/url_fetcher_delegate.h"
47 #include "net/url_request/url_request_context_getter.h" 46 #include "net/url_request/url_request_context_getter.h"
48 #include "net/url_request/url_request_status.h" 47 #include "net/url_request/url_request_status.h"
(...skipping 813 matching lines...) Expand 10 before | Expand all | Expand 10 after
862 [_timeLeftLabel setFont:[MDCTypography body1Font]]; 861 [_timeLeftLabel setFont:[MDCTypography body1Font]];
863 [_fileNameLabel setFont:[MDCTypography subheadFont]]; 862 [_fileNameLabel setFont:[MDCTypography subheadFont]];
864 [_errorOrSizeLabel setFont:[MDCTypography captionFont]]; 863 [_errorOrSizeLabel setFont:[MDCTypography captionFont]];
865 } else { 864 } else {
866 [self.view addConstraints:_landscapeConstraintsArray]; 865 [self.view addConstraints:_landscapeConstraintsArray];
867 866
868 [_fileTypeLabel setFont:[MDCTypography display1Font]]; 867 [_fileTypeLabel setFont:[MDCTypography display1Font]];
869 [_timeLeftLabel setFont:[MDCTypography captionFont]]; 868 [_timeLeftLabel setFont:[MDCTypography captionFont]];
870 [_fileNameLabel setFont:[MDCTypography body1Font]]; 869 [_fileNameLabel setFont:[MDCTypography body1Font]];
871 [_errorOrSizeLabel 870 [_errorOrSizeLabel
872 setFont:[[MDFRobotoFontLoader sharedInstance] regularFontOfSize:10]]; 871 setFont:[[MDCTypography fontLoader] regularFontOfSize:10]];
873 } 872 }
874 } 873 }
875 874
876 - (void)updatePortraitActionBarConstraints { 875 - (void)updatePortraitActionBarConstraints {
877 [self removePortraitActionBarConstraints]; 876 [self removePortraitActionBarConstraints];
878 [self addPortraitActionBarConstraints]; 877 [self addPortraitActionBarConstraints];
879 } 878 }
880 879
881 - (void)removePortraitActionBarConstraints { 880 - (void)removePortraitActionBarConstraints {
882 [self.view removeConstraints:_portraitActionBarOneButtonConstraintsArray]; 881 [self.view removeConstraints:_portraitActionBarOneButtonConstraintsArray];
(...skipping 762 matching lines...) Expand 10 before | Expand all | Expand 10 after
1645 1644
1646 #pragma mark - CRWNativeContent 1645 #pragma mark - CRWNativeContent
1647 1646
1648 - (void)close { 1647 - (void)close {
1649 // Makes sure that all outstanding network requests are shut down before 1648 // Makes sure that all outstanding network requests are shut down before
1650 // this controller is closed. 1649 // this controller is closed.
1651 _fetcher.reset(); 1650 _fetcher.reset();
1652 } 1651 }
1653 1652
1654 @end 1653 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698