1
0
mirror of https://github.com/bitwarden/mobile synced 2025-12-31 23:53:25 +00:00

copy classes to autofill

This commit is contained in:
Kyle Spearrin
2018-09-20 22:24:13 -04:00
parent 219af7f288
commit d32eb9c9bc
7 changed files with 178 additions and 58 deletions

View File

@@ -0,0 +1,31 @@
using System;
using UIKit;
namespace Bit.iOS.Extension
{
public partial class PasswordGeneratorViewController : Core.Controllers.PasswordGeneratorViewController
{
public PasswordGeneratorViewController(IntPtr handle) : base(handle)
{ }
public LoginAddViewController Parent { get; set; }
public override UINavigationItem BaseNavItem => NavItem;
public override UIBarButtonItem BaseCancelButton => CancelBarButton;
public override UIBarButtonItem BaseSelectBarButton => SelectBarButton;
public override UILabel BasePasswordLabel => PasswordLabel;
partial void SelectBarButton_Activated(UIBarButtonItem sender)
{
GoogleAnalyticsService.TrackExtensionEvent("SelectedGeneratedPassword");
DismissViewController(true, () =>
{
Parent.PasswordCell.TextField.Text = PasswordLabel.Text;
});
}
partial void CancelBarButton_Activated(UIBarButtonItem sender)
{
DismissViewController(true, null);
}
}
}