Opened 13 years ago

Closed 12 years ago

Last modified 12 years ago

#2439 closed defect (fixed)

Editor: Update (Insert) Image not functional in IE6sp2

Reported by: tdedischew@… Owned by: Adam Peller
Priority: high Milestone: 1.1
Component: Dojox Version: 0.4.1
Keywords: Editor2 InsertImage IE6 Cc:
Blocked By: Blocking:

Description

Test Case: http://download.dojotoolkit.org/release-0.4.1/dojo-0.4.1-kitchen_sink/tests/widget/Editor/test_Editor2.html

Add an image to one of the Editor2's via the toolbar or cut/paste of html (say http://dojotoolkit.org/img/page-title-smaller.png), then select that image and hit the toolbar icon again to modify.

Regardless of any property changes, when you hit Ok, you'll get a javascript error in IE6 (line 4971 Object doesn't support this property or method).

The exception is happening during the inserthtml execCommand...

I have to find a solution this weekend (or scrap using Editor2) so will hopefully post a fix shortly. I couldn't find this bug logged elsewhere in trac, but maybe someone has encountered this strange IE/Editor2 behavior before?

Change History (11)

comment:1 Changed 13 years ago by tdedischew@…

Current solution is to nuke the existing image node (explicit delete+insert vs. relying on the implied replacement via the "inserthtml" command)...

		if(this.imageNode){
			dojo.withGlobal(curInst.window, "selectElement", dojo.html.selection, [this.imageNode]);
			/* if IE, nuke node -- 'cursor' remains where node was, 
			   so this seems safe and the later inserthtml command
			   inserts right where the old image was... */
			if (dojo.render.html.ie)
			  curInst.execCommand('delete');
		}

comment:2 Changed 13 years ago by alex

Milestone: 0.4.20.9
Priority: highnormal

comment:3 Changed 12 years ago by liucougar

Milestone: 0.91.0

0.9 editor does not yet have an image dialog plugin, punt this

comment:4 Changed 12 years ago by bill

Component: EditorDojox
Milestone: 1.0
Owner: changed from liucougar to Tom Trenka
Summary: Editor2 Update (Insert) Image not functional in IE6sp2Editor: Update (Insert) Image not functional in IE6sp2

comment:5 Changed 12 years ago by bill

Owner: changed from Tom Trenka to liucougar

comment:6 Changed 12 years ago by Adam Peller

(In [12335]) First stab at porting the old url 'insertImage' dialog feature from 0.4. Refs #2439 Uses same code as 'createLink' in LinkDialog? plugin. A fancy dojox.image plugin might extend this. Refs #5759. Also, cleanup code in LinkDialog?.js.

comment:7 Changed 12 years ago by alex

Milestone: 1.1

we should verify and fix/spike for 1.1

comment:8 Changed 12 years ago by Adam Peller

Owner: changed from liucougar to Adam Peller

comment:9 Changed 12 years ago by Adam Peller

Resolution: fixed
Status: newclosed

generally working. have some other tickets open to track issues.

comment:10 Changed 12 years ago by Adam Peller

(In [12770]) Remove 'experimental.' Refs #2439, #4171, #4971

comment:11 Changed 12 years ago by Adam Peller

(In [12771]) Oops. Remove log. Refs #2439

Note: See TracTickets for help on using tickets.