mobile: Delete insertion - use graphic selection rather than clip.
The clipboard population is asynchronous and might come too late. Was missing the Delete item on Android. Change-Id: I05515f151c8d730e2aa1cb61eceacd0c3b90c455 Reviewed-on: https://gerrit.libreoffice.org/c/online/+/88579 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
This commit is contained in:
parent
1bc1034543
commit
6543ad21bb
1 changed files with 2 additions and 6 deletions
|
@ -157,11 +157,8 @@ L.Control.ContextMenu = L.Control.extend({
|
|||
},
|
||||
|
||||
_amendContextMenuData: function(obj) {
|
||||
|
||||
// Add a 'delete' entry for mobile when selection is ole/image/shape
|
||||
if (this._map._clip && this._map._clip._selectionType === 'complex' &&
|
||||
window.mode.isMobile()) {
|
||||
|
||||
// Add a 'delete' entry for mobile for graphic selection.
|
||||
if (this._map._docLayer.hasGraphicSelection() && window.mode.isMobile()) {
|
||||
var insertIndex = -1;
|
||||
obj.menu.forEach(function(item, index) {
|
||||
if (item.command === '.uno:Paste') {
|
||||
|
@ -174,7 +171,6 @@ L.Control.ContextMenu = L.Control.extend({
|
|||
{ text: _('Delete'), type: 'command', command: '.uno:Delete', enabled: true });
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
_createContextMenuStructure: function(obj) {
|
||||
|
|
Loading…
Reference in a new issue