Opened 16 years ago
Closed 16 years ago
#3041 closed Bug (fixed)
plugin:colorbutton incorrect state after color selected.
Reported by: | Garry Yao | Owned by: | Artur Formella |
---|---|---|---|
Priority: | Normal | Milestone: | CKEditor 3.0 |
Component: | General | Version: | SVN (CKEditor) - OLD |
Keywords: | Confirmed Review+ | Cc: |
Description
The bgColor and textColor button should have no states after applying the styles. Currently we can still found sometimes these two buttons toggled on after panel is closed.
Attachments (3)
Change History (13)
Changed 16 years ago by
Attachment: | test-colorbutton-states.patch added |
---|
comment:1 Changed 16 years ago by
Keywords: | Confirmed added |
---|---|
Version: | SVN (FCKeditor) → SVN (CKEditor) |
comment:2 Changed 16 years ago by
Owner: | set to Garry Yao |
---|---|
Status: | new → assigned |
When adding the following lines arround _source\plugins\panelbutton\plugin.js for debugging, it is found that the 'CKEDITOR.TRISTATE_OFF' state is incorrectly applied to 'text-color' when hidding the 'bg-color' panel.
this._.__defineSetter__( 'state', function( state ){ console.log( this.id ); return state; } );
Changed 16 years ago by
Attachment: | 3041.patch added |
---|
comment:3 Changed 16 years ago by
Keywords: | Review? added |
---|
The bug was found to be caused by some incorrect handler function caching.
comment:4 follow-up: 5 Changed 16 years ago by
Keywords: | Review- added; Review? removed |
---|
While this fix even makes sense, as we have a reference to "panel" that can't be shared by all buttons, it makes no difference for me. I can reproduce the problem in the same way before and after the patch:
- Click the "Background Color" button.
- Click the "Foreground Color" button.
- Click the "Background Color" twice. The "Foreground Color" button remains hilighted.
This looks like an issue with the floating panel system, as something similar can be done with the combos also.
In any case, please move the "clickFn" variable declaration from line 16 to line 71 at this point and commit your changes. A final solution is still to be found though.
comment:5 Changed 16 years ago by
comment:7 Changed 16 years ago by
Owner: | changed from Garry Yao to Artur Formella |
---|---|
Status: | assigned → new |
I'm taking over the ticket after talk with Garry.
Changed 16 years ago by
Attachment: | 3041_2.patch added |
---|
comment:8 Changed 16 years ago by
Keywords: | Review? added; Review- removed |
---|
It was a part of http://dev.fckeditor.net/attachment/ticket/3068/3068_2.patch
This is the simplest way, is solves also #3222.
comment:9 Changed 16 years ago by
Keywords: | Review+ added; Review? removed |
---|
See #3163 for information on how to reproduce it.