diff --git a/src/angular/components/view.component.ts b/src/angular/components/view.component.ts index 995f8cfc..a0d60764 100644 --- a/src/angular/components/view.component.ts +++ b/src/angular/components/view.component.ts @@ -17,9 +17,7 @@ import { CipherService } from '../../abstractions/cipher.service'; import { CryptoService } from '../../abstractions/crypto.service'; import { EventService } from '../../abstractions/event.service'; import { I18nService } from '../../abstractions/i18n.service'; -import { MessagingService } from '../../abstractions/messaging.service'; import { PlatformUtilsService } from '../../abstractions/platformUtils.service'; -import { StorageService } from '../../abstractions/storage.service'; import { TokenService } from '../../abstractions/token.service'; import { TotpService } from '../../abstractions/totp.service'; import { UserService } from '../../abstractions/user.service'; @@ -30,8 +28,6 @@ import { FieldView } from '../../models/view/fieldView'; import { LoginUriView } from '../../models/view/loginUriView'; import { BroadcasterService } from '../services/broadcaster.service'; -import { ElectronConstants } from '../../electron/electronConstants'; - const BroadcasterSubscriptionId = 'ViewComponent'; export class ViewComponent implements OnDestroy, OnInit { @@ -60,8 +56,7 @@ export class ViewComponent implements OnDestroy, OnInit { protected auditService: AuditService, protected win: Window, protected broadcasterService: BroadcasterService, protected ngZone: NgZone, protected changeDetectorRef: ChangeDetectorRef, protected userService: UserService, - protected eventService: EventService, protected messagingService: MessagingService, - protected storageService: StorageService) { } + protected eventService: EventService) { } ngOnInit() { this.broadcasterService.subscribe(BroadcasterSubscriptionId, (message: any) => { @@ -175,7 +170,6 @@ export class ViewComponent implements OnDestroy, OnInit { this.platformUtilsService.copyToClipboard(value, copyOptions); this.platformUtilsService.showToast('info', null, this.i18nService.t('valueCopied', this.i18nService.t(typeI18nKey))); - this.minimizeIfNeeded(); if (typeI18nKey === 'password') { this.eventService.collect(EventType.Cipher_ClientToggledHiddenFieldVisible, this.cipherId); @@ -190,14 +184,6 @@ export class ViewComponent implements OnDestroy, OnInit { event.dataTransfer.setData('text', data); } - public async minimizeIfNeeded(): Promise { - const shouldMinimize = - await this.storageService.get(ElectronConstants.minimizeOnCopyToClipboardKey); - if (shouldMinimize) { - this.messagingService.send('minimize'); - } - } - async downloadAttachment(attachment: AttachmentView) { const a = (attachment as any); if (a.downloading) {