Commit 9bddaf32 authored by Javier Ernesto Flores Robles's avatar Javier Ernesto Flores Robles Committed by Chromium LUCI CQ

[iOS][CredentialProvider] Use Highlight Button for accessories

This will cause the buttons to dim when touched instead of looking darker

Bug: 1100887
Change-Id: I0ed01c9844e23623fc44f3cbb4002ac557bfe297
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2583147
Auto-Submit: Javier Flores <javierrobles@chromium.org>
Commit-Queue: David Jean <djean@chromium.org>
Reviewed-by: default avatarDavid Jean <djean@chromium.org>
Cr-Commit-Position: refs/heads/master@{#835584}
parent fb56a158
...@@ -34,6 +34,7 @@ source_set("ui") { ...@@ -34,6 +34,7 @@ source_set("ui") {
"//ios/chrome/common/credential_provider:ui", "//ios/chrome/common/credential_provider:ui",
"//ios/chrome/common/ui/colors", "//ios/chrome/common/ui/colors",
"//ios/chrome/common/ui/confirmation_alert", "//ios/chrome/common/ui/confirmation_alert",
"//ios/chrome/common/ui/elements",
"//ios/chrome/common/ui/elements:popover_label_view_controller", "//ios/chrome/common/ui/elements:popover_label_view_controller",
"//ios/chrome/common/ui/resources:default_world_favicon", "//ios/chrome/common/ui/resources:default_world_favicon",
"//ios/chrome/common/ui/util", "//ios/chrome/common/ui/util",
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
#import "ios/chrome/common/constants.h" #import "ios/chrome/common/constants.h"
#import "ios/chrome/common/credential_provider/credential.h" #import "ios/chrome/common/credential_provider/credential.h"
#import "ios/chrome/common/ui/colors/semantic_color_names.h" #import "ios/chrome/common/ui/colors/semantic_color_names.h"
#import "ios/chrome/common/ui/elements/highlight_button.h"
#import "ios/chrome/credential_provider_extension/metrics_util.h" #import "ios/chrome/credential_provider_extension/metrics_util.h"
#import "ios/chrome/credential_provider_extension/ui/tooltip_view.h" #import "ios/chrome/credential_provider_extension/ui/tooltip_view.h"
...@@ -216,7 +217,7 @@ typedef NS_ENUM(NSInteger, RowIdentifier) { ...@@ -216,7 +217,7 @@ typedef NS_ENUM(NSInteger, RowIdentifier) {
: @"password_reveal_icon"]; : @"password_reveal_icon"];
image = [image imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate]; image = [image imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate];
UIButton* button = [UIButton buttonWithType:UIButtonTypeCustom]; HighlightButton* button = [HighlightButton buttonWithType:UIButtonTypeCustom];
button.frame = CGRectMake(0.0, 0.0, image.size.width, image.size.height); button.frame = CGRectMake(0.0, 0.0, image.size.width, image.size.height);
button.backgroundColor = [UIColor colorNamed:kBackgroundColor]; button.backgroundColor = [UIColor colorNamed:kBackgroundColor];
[button setBackgroundImage:image forState:UIControlStateNormal]; [button setBackgroundImage:image forState:UIControlStateNormal];
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
#include "ios/chrome/common/app_group/app_group_metrics.h" #include "ios/chrome/common/app_group/app_group_metrics.h"
#import "ios/chrome/common/credential_provider/credential.h" #import "ios/chrome/common/credential_provider/credential.h"
#import "ios/chrome/common/ui/colors/semantic_color_names.h" #import "ios/chrome/common/ui/colors/semantic_color_names.h"
#import "ios/chrome/common/ui/elements/highlight_button.h"
#import "ios/chrome/common/ui/util/pointer_interaction_util.h" #import "ios/chrome/common/ui/util/pointer_interaction_util.h"
#import "ios/chrome/credential_provider_extension/metrics_util.h" #import "ios/chrome/credential_provider_extension/metrics_util.h"
...@@ -219,7 +220,7 @@ const CGFloat kHeaderHeight = 70; ...@@ -219,7 +220,7 @@ const CGFloat kHeaderHeight = 70;
UIImage* image = [UIImage imageNamed:@"info_icon"]; UIImage* image = [UIImage imageNamed:@"info_icon"];
image = [image imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate]; image = [image imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate];
UIButton* button = [UIButton buttonWithType:UIButtonTypeCustom]; HighlightButton* button = [HighlightButton buttonWithType:UIButtonTypeCustom];
button.frame = CGRectMake(0.0, 0.0, image.size.width, image.size.height); button.frame = CGRectMake(0.0, 0.0, image.size.width, image.size.height);
[button setBackgroundImage:image forState:UIControlStateNormal]; [button setBackgroundImage:image forState:UIControlStateNormal];
[button setTintColor:[UIColor colorNamed:kBlueColor]]; [button setTintColor:[UIColor colorNamed:kBlueColor]];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment