Opened 7 years ago

Closed 7 years ago

#6020 closed Bug (fixed)

Copy and cut icons should be disabled on empty selection

Reported by: Sa'ar Zac Elias Owned by: Sa'ar Zac Elias
Priority: Normal Milestone: CKEditor 3.5.1
Component: General Version: 3.0
Keywords: Oracle Cc: satya_minnekanti@…

Description

Copy and cut toolbar buttons should be disabled when the selection is empty.

Attachments (5)

6020.patch (1.5 KB) - added by Martin 7 years ago.
6020_2.patch (1.6 KB) - added by Sa'ar Zac Elias 7 years ago.
6020_3.patch (3.6 KB) - added by Sa'ar Zac Elias 7 years ago.
6020_4.patch (3.8 KB) - added by Sa'ar Zac Elias 7 years ago.
6020_5.patch (5.2 KB) - added by Sa'ar Zac Elias 7 years ago.

Download all attachments as: .zip

Change History (24)

comment:1 Changed 7 years ago by Frederico Caldeira Knabben

Status: newconfirmed

comment:2 Changed 7 years ago by Sa'ar Zac Elias

#6239 has been marked has a DUP.

comment:3 Changed 7 years ago by Satya Minnekanti

Cc: satya_minnekanti@… added

comment:4 Changed 7 years ago by Senthil

Keywords: Oracle added

comment:5 Changed 7 years ago by Martin

Owner: set to Martin
Status: confirmedassigned

Changed 7 years ago by Martin

Attachment: 6020.patch added

comment:6 Changed 7 years ago by Martin

Status: assignedreview

comment:7 Changed 7 years ago by Wiktor Walc

Milestone: CKEditor 3.5.1

comment:8 Changed 7 years ago by Sa'ar Zac Elias

Owner: changed from Martin to Sa'ar Zac Elias
Status: reviewassigned

I'm taking this one over @mani.

Changed 7 years ago by Sa'ar Zac Elias

Attachment: 6020_2.patch added

comment:9 Changed 7 years ago by Sa'ar Zac Elias

Status: assignedreview

comment:10 Changed 7 years ago by Garry Yao

Status: reviewreview_failed

Not an option, keyboard hook brings serious performance just like #6438.

Changed 7 years ago by Sa'ar Zac Elias

Attachment: 6020_3.patch added

comment:11 Changed 7 years ago by Sa'ar Zac Elias

Status: review_failedreview

Another approach is to use queryCommandEnabled and hook the selectionChange for readOnly check.

comment:12 Changed 7 years ago by Garry Yao

Status: reviewreview_failed

Looks good, while readonly doesn't affect "paste" command state.

Changed 7 years ago by Sa'ar Zac Elias

Attachment: 6020_4.patch added

comment:13 Changed 7 years ago by Sa'ar Zac Elias

Status: review_failedreview

comment:14 Changed 7 years ago by Garry Yao

Status: reviewreview_failed

Let's also check whether the paste command state need to be constantly checked.

comment:15 Changed 7 years ago by Sa'ar Zac Elias

Status: review_failedreview

queryCommandEnabled is false when there is no data to paste (probably other limitations as well). In Webkit, it will always return false for security reasons (#3788). In any case, the toolbar buttons' state should match the context menu's options.

comment:16 Changed 7 years ago by Garry Yao

Status: reviewreview_failed

Other two paste commands could be aligned also. (paste plain text and paste word)

Changed 7 years ago by Sa'ar Zac Elias

Attachment: 6020_5.patch added

comment:17 Changed 7 years ago by Sa'ar Zac Elias

Status: review_failedreview

comment:18 Changed 7 years ago by Garry Yao

Status: reviewreview_passed

comment:19 Changed 7 years ago by Sa'ar Zac Elias

Resolution: fixed
Status: review_passedclosed

Fixed with [6311].

Note: See TracTickets for help on using tickets.
© 2003 – 2017 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy