Skip to content

Commit

Permalink
[BUGFIX] Allow to switch clipboard mode to copy without items
Browse files Browse the repository at this point in the history
This change allows to change to "Copy Mode" in the clipboard
without having items on the clipboard.

However, switching to a different clipboard will have this
selection vanish again (before and after the change). Changing
this behavior is considered out of scope for this patch.

Resolves: #89726
Releases: master, 9.5
Change-Id: I83483c631915b390dfb0c9584c29f0f86a44d051
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62453
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Susanne Moog <look@susi.dev>
Reviewed-by: Susanne Moog <look@susi.dev>
  • Loading branch information
bmack authored and susannemoog committed Nov 29, 2019
1 parent 3adc562 commit 737b165
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion typo3/sysext/backend/Classes/Clipboard/Clipboard.php
Expand Up @@ -183,7 +183,7 @@ public function setCmd($cmd)
}
// Set copy mode of the tab
if (isset($cmd['setCopyMode'])) {
$this->clipData[$this->current]['mode'] = $this->isElements() ? ($cmd['setCopyMode'] ? 'copy' : '') : '';
$this->clipData[$this->current]['mode'] = $cmd['setCopyMode'] ? 'copy' : '';
$this->changed = 1;
}
}
Expand Down

0 comments on commit 737b165

Please sign in to comment.