1096 Commits

Author SHA1 Message Date
glazman%netscape.com
68de2ad1fd Support for Absolute Positioning, Snap to Grid, and Inline Table Editing in Composer
r=brade, sr=jst


git-svn-id: svn://10.0.0.236/trunk@144144 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-25 08:50:48 +00:00
dbaron%dbaron.org
519cf3b3d3 DeCOMtaminate nsIFrame::GetView and SetView, and add HasView, GetClosestView, and AreAncestorViewsVisible to consolidate common patterns. b=208004 r+sr=roc
git-svn-id: svn://10.0.0.236/trunk@143960 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-19 23:44:01 +00:00
glazman%netscape.com
3825cdfefa Composer's structure toolbar was showing anonymous content; b=190279, r=Neil, sr=peterv
git-svn-id: svn://10.0.0.236/trunk@143931 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-19 14:06:05 +00:00
stephend%netscape.com
2f3cf9eef5 fixing typo - s/cahced/cache
git-svn-id: svn://10.0.0.236/trunk@143895 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-18 23:04:50 +00:00
jfrancis%netscape.com
a25a16aae6 bug 140357: improving fix to handle redundant backspaces. r=brade, sr=kin
git-svn-id: svn://10.0.0.236/trunk@143891 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-18 22:42:24 +00:00
glazman%netscape.com
9519e8311f Was impossible to outdent a subset of an indented block in CSS mode
b=194963, r=kaie, sr=kin


git-svn-id: svn://10.0.0.236/trunk@143791 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-17 09:35:46 +00:00
glazman%netscape.com
2b6f3cbea5 Removing text styles in CSS mode was potentially removing too much if the styles were added in HTML mode
The fix creates a span element that will carry the inline styles and class of the HTML element to be removed, if any.
b=202037, r=kaie, sr=dmose


git-svn-id: svn://10.0.0.236/trunk@143790 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-17 08:45:54 +00:00
caillon%returnzero.com
0a6d1ae509 Bug 209087
Content interface out-parameters should use ptr-to-ptrs instead of ref-to-ptrs and some small deCOMtamination.
r+sr=jst@netscape.com


git-svn-id: svn://10.0.0.236/trunk@143683 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-13 20:10:01 +00:00
glazman%netscape.com
95747f691f error in nsHTMLEditor::SetFlags(), has side-effects on CSS editing; b=209086, r=brade, sr=kin
git-svn-id: svn://10.0.0.236/trunk@143673 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-13 12:39:35 +00:00
brade%netscape.com
2d1f651343 remove unused params; r=akkana, sr=kin, bienvenu, bug=208967
git-svn-id: svn://10.0.0.236/trunk@143639 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-12 14:51:37 +00:00
peterv%netscape.com
e0bfba43db Fix HP-UX bustage from jfrancis checkin.
git-svn-id: svn://10.0.0.236/trunk@143633 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-12 11:20:00 +00:00
glazman%netscape.com
223409d642 CSS indentation was not dropping non-editable nodes; b=203723, r=kaie, sr=peterv
git-svn-id: svn://10.0.0.236/trunk@143630 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-12 07:43:07 +00:00
jfrancis%netscape.com
d02d21d990 improvement to 140357 fix: reducing bloat of previous patch, extending functionality to css-mode editting, and improving TypeInState to recognize redundant selection change notifications.
fix for 208317: css-mode editing left empty spans around, which could cause disapearing carets
r=brade; sr=kin


git-svn-id: svn://10.0.0.236/trunk@143596 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-11 19:33:01 +00:00
kaie%netscape.com
cde4df8d96 b=207183 Smiley gets deleted, editor tries to manipulate whitespace in the -moz-user-select:all block
r=jfrancis sr=kin


git-svn-id: svn://10.0.0.236/trunk@143583 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-11 12:02:49 +00:00
kaie%netscape.com
c217443fac b=202166 Edit actions place caret on invalid position
r=jfrancis sr=kin


git-svn-id: svn://10.0.0.236/trunk@143582 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-11 11:50:36 +00:00
brade%netscape.com
596c8b1e49 remove some useless local variables, fix whitespace, add param to insertion hook (sourceDoc), r=rogermw, sr=kin, bug=208539
git-svn-id: svn://10.0.0.236/trunk@143517 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-10 18:53:11 +00:00
brade%netscape.com
601b8b9d42 add param to insertion hook (sourceDoc), r=rogermw, sr=kin, bug=208539
git-svn-id: svn://10.0.0.236/trunk@143515 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-10 18:52:31 +00:00
jfrancis%netscape.com
bf700200ef bug 140357: (html editor) deletion should preserve style state. r=brade; sr=kin
git-svn-id: svn://10.0.0.236/trunk@143203 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-02 22:21:06 +00:00
timeless%mozdev.org
d5bcd46d89 Bug 205347 warning: `PRBool IsInlineNode(class nsIDOMNode *)' defined but not used
r=brade,jfrancis sr=sfraser


git-svn-id: svn://10.0.0.236/trunk@142850 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-23 22:10:06 +00:00
timeless%mozdev.org
3031c88dab Bug 204076 Remove unused variable `PRBool sameNode' from nsHTMLEditorStyle.cpp:524
r=brade sr=tor


git-svn-id: svn://10.0.0.236/trunk@142840 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-23 21:55:17 +00:00
timeless%mozdev.org
0e56e202cb Bug 199989 Remove gNoisy code from libeditor.
r=brade sr=alecf


git-svn-id: svn://10.0.0.236/trunk@142832 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-23 21:43:10 +00:00
dwitte%stanford.edu
dc7e857400 bug 100649: Length() being used where IsEmpty() is meant
treewide changes to convert incorrect usages of string.Length() to string.IsEmpty().

thanks to afatecha@idea.com.py (Ariel Fatecha) for the patch. r=dwitte, sr=jst.

got the ok from Asa to land into a closed tree.


git-svn-id: svn://10.0.0.236/trunk@142828 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-23 21:34:47 +00:00
glazman%netscape.com
0e36fded62 crash when doing multiple redo commands in Composer; r=brade, sr=peterv, a=sspitzer
git-svn-id: svn://10.0.0.236/trunk@142543 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-16 09:08:03 +00:00
kaie%netscape.com
6ac32319ca b=169213 hitting backspace deletes HR above, fix confusing caret placement around <hr> lines
r=jfrancis sr=sfraser a=sspitzer


git-svn-id: svn://10.0.0.236/trunk@142433 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-14 13:20:09 +00:00
kaie%netscape.com
321982814e b=200417 backspace, enter keys have no visible impact
r=jfrancis sr=sfraser a=sspitzer


git-svn-id: svn://10.0.0.236/trunk@142432 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-14 13:17:32 +00:00
brade%netscape.com
7863d97a97 api change to insertion filter to add flag for delete selection; r=timeless; sr=kin; a=asa; bug=204066
git-svn-id: svn://10.0.0.236/trunk@142277 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-09 18:33:14 +00:00
brade%netscape.com
df5fbef10f api change to insertion filter to add flag for delete selection; r=timeless; sr= kin; a=asa; bug=204066
git-svn-id: svn://10.0.0.236/trunk@142276 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-09 18:32:50 +00:00
brade%netscape.com
9c8c9c525c cleanup transferable hooks in editor; defer selection manipulation in plain text; ensure hooks are properly positioned (bug 203062) r=kaie, kin; sr=smfr
git-svn-id: svn://10.0.0.236/trunk@141821 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-25 21:05:32 +00:00
brade%netscape.com
431f30b30a missing hook from bug 192171 (r=brian johnson, sr=sfraser)
git-svn-id: svn://10.0.0.236/trunk@141617 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-22 20:32:59 +00:00
brade%netscape.com
672b3839a4 editor changes for drag/drop/copy/paste hooks (bug 197121) r=jfrancis, sr=smfr
git-svn-id: svn://10.0.0.236/trunk@141304 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-17 13:18:51 +00:00
jaggernaut%netscape.com
797cb9f849 Bug 198546: Format -> Font submenu doesn't deal with "unknown" font. r=glazou, r=Neil, sr=bryner, moa=brade.
git-svn-id: svn://10.0.0.236/trunk@141297 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-17 07:35:55 +00:00
alecf%netscape.com
272139fbdf fix for bug 201982 - r=brade, sr=smfr
nsIEditProperty was an interface with no methods and only static members - moved it to an entirely static class.


git-svn-id: svn://10.0.0.236/trunk@141290 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-17 05:42:33 +00:00
kaie%netscape.com
1306f85f65 b=201974 Caret partially/completely visible with initial <p> </p>
r=jfrancis sr=sfraser


git-svn-id: svn://10.0.0.236/trunk@141255 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-16 20:18:41 +00:00
kaie%netscape.com
7f3ff56e4b b=68767 extra blank space added when block level element (hr, table) is inserted at the end of a line, between two lines
r=jfrancis sr=kin


git-svn-id: svn://10.0.0.236/trunk@141196 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-15 20:53:15 +00:00
brade%netscape.com
7c86a6fce4 add insertion listener; bug 192567 (r=jfrancis, sr=kin)
git-svn-id: svn://10.0.0.236/trunk@141181 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-15 14:07:30 +00:00
bzbarsky%mit.edu
99037d7097 Make CreateContextualFragment know what document the fragment is destined for.
Fixes some issues with images and innerHTML.  Bugs 198486, 198989, 201865.
r=jfrancis, sr=jst


git-svn-id: svn://10.0.0.236/trunk@141144 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-15 01:09:09 +00:00
bzbarsky%mit.edu
ad025b22c0 MakeList is redundant with AppendList. Bug 179810, r=jfrancis, sr=kin
git-svn-id: svn://10.0.0.236/trunk@141084 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-13 04:30:16 +00:00
alecf%netscape.com
2795f737e2 fix for bug 199170 - convert editor over to using nsStaticAtoms
r=brade, sr=sfraser


git-svn-id: svn://10.0.0.236/trunk@141003 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-10 21:04:07 +00:00
kin%netscape.com
dcb54fbdfe Fix for bug 199490: A crash occurs after clicking in (HTML tags )document - Trunk [@
nsHTMLEditor::SetFinalSize]

  - A one line fix in HideResizers() which prevents the
    reported crash by setting mIsResizing to false. I assume
    we can't be resizing if the resize handles are being hidden.
    The assertion and null check in SetFinalSize() are just because
    I'm paranoid, but they should never be triggered if HideResizers()
    is called first.

  - The changes in StartResizing() makes it so that we don't create
    a new mouse motion listener if we already have one. We were
    creating a new listener each time we clicked on the handles, and
    never unregistering the old one ... this meant that the old
    listeners could be triggered if the editor were ever destroyed
    and the document left in tact ... allowing us to crash because the
    listeners keep an un-addref'd pointer to the HTMLEditor. Note that
    this crash is not likely to be hit in Mozilla since we always
    destroy the document and editor in Composer and MailCompose, but
    it can happen in an embedding context.

r=glazman@netscape.com  sr=sfraser@netscape.com


git-svn-id: svn://10.0.0.236/trunk@140921 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-09 21:10:58 +00:00
kin%netscape.com
85050dbdbe Fix for bug 200549:Double click selects just the image in a -moz-user-select:all
subtree


mozilla/editor/libeditor/html/nsHTMLEditor.cpp
    - jfrancis' fix for netscape bug 615240 (applying mozilla patch
      on branch. Fixing problems of improper handling of del and
      backspace keys with file attachments.) which was originally
      landed in revision 1.445.6.3. This patch is necessary to make
      the fix for bug 200549 work properly.

r=sfraser@netscape.com  sr=kin@netscape.com


mozilla/editor/libeditor/html/nsHTMLEditorMouseListener.cpp
mozilla/editor/libeditor/html/nsHTMLEditorMouseListener.h

    - Modified nsHTMLEditorMouseListener::MouseDown() to
      call FindUserSelectAllNode() so that the root of a
      -moz-user-select:all subtree gets selected during
      a double or context click.

    - Modified nsHTMLEditorMouseListener so that it stores an nsHTMLEditor*
      instead of an nsIEditor* so we could have access to FindUserSelectAllNode().

r=brade@netscape.com  sr=sfraser@netscape.com


git-svn-id: svn://10.0.0.236/trunk@140807 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-07 14:32:23 +00:00
kin%netscape.com
811daa38c7 Fix for bug 42046: One click select and drag for images, hrs, and -moz-user-select:all
subtrees


mozilla/layout/html/base/src/nsFrame.cpp

  - Added utility method ContentContainsPoint()
  - Modified HandlePress() to allow selection of images, hrs and
    -moz-user-select:all subtrees, and then disable selection
    processing of drag events.


mozilla/editor/libeditor/html/nsHTMLDataTransfer.cpp

    - Modified InsertFromDrop() so that it prevents a drop from
      happening in a -moz-user-select:all subtree. (Temporary
      workaround to avoid bug 195957 and bug 195959)

r=mjudge@netscape.com  sr=sfraser@netscape.com


git-svn-id: svn://10.0.0.236/trunk@140805 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-07 14:28:51 +00:00
kin%netscape.com
fd1509505d Fix for bug # :Hiding resize handles triggers assertion in ~nsGenericHTMLElement()
Modfied DeleteRefToAnonymousNode() so that it set the content node's document and parent to nsnull.

r=brade@netscape.com  sr=sfraser@netscape.com


git-svn-id: svn://10.0.0.236/trunk@140710 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-04 20:51:36 +00:00
kin%netscape.com
d43528516f Fixes for bug 192569 (allow foreign transactions to be added to the queue)
mozilla/editor/idl/nsIEditor.idl
mozilla/editor/libeditor/base/nsEditor.cpp
mozilla/editor/libeditor/base/PlaceholderTxn.cpp
mozilla/editor/libeditor/html/nsHTMLCSSUtils.cpp
mozilla/editor/libeditor/html/nsHTMLEditor.cpp
mozilla/editor/libeditor/text/nsTextEditRules.cpp

  - Renamed nsIEditor::Do() to nsIEditor::DoTransaction() so that it
    can be called from JavaScript.

  - Cleaned up nsEditor::Begin/EndUpdateViewBatch() so that
    nothing happens outside the check of mUpdateCount.

  - Modified PlaceholderTxn.cpp so that it checks to see
    if a merged transaction implements nsPIEditorTransaction
    before attempting to cast it to (EditorTxn*).

mozilla/editor/ui/composer/content/EditorCommandsDebug.js
mozilla/editor/ui/composer/content/editorOverlay.xul
mozilla/editor/ui/composer/locale/en-US/editorOverlay.dtd

  - Added debug menu items to test execution of foreign transactions
    via the txnmgr and editor.

r=jfrancis@netscape.com  sr=sfraser@netscape.com


git-svn-id: svn://10.0.0.236/trunk@140707 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-04 20:50:25 +00:00
kin%netscape.com
a2cc97e02b Fix for bug #195959: Drop causes image in -moz-user-select:all subtree to be duplicated
Prevent nsHTMLEditRules::CreateStyleForInsertText() from trying to split non-container nodes.


r=jfrancis@netscape.com  sr=sfraser@netscape.com


git-svn-id: svn://10.0.0.236/trunk@140698 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-04 15:29:59 +00:00
jaggernaut%netscape.com
1d7b08a381 Bug 200638: fix drag copy modifier key on Mac OS X. r=Neil, sr=peterv
git-svn-id: svn://10.0.0.236/trunk@140691 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-04 12:48:23 +00:00
sfraser%netscape.com
3bb2704dcc Remove nsIIndpendentSelection, moving its one method onto nsISelectionPrivate. Bug 192827. r/sr=kin.
git-svn-id: svn://10.0.0.236/trunk@140665 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-04 01:45:06 +00:00
brade%netscape.com
0c8c6bf3da require all users of htmleditor to have EditorOverride.css so resizing will work
; bug 196075; r=jfrancis, sr=bryner


git-svn-id: svn://10.0.0.236/trunk@140634 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-03 08:05:23 +00:00
henry.jia%sun.com
365360b6e3 Patch for bug 35296: SetCaretEnabled() takes too long
Patch by Leon.Zhang@sun.com
r=sfraser, sr=kin


git-svn-id: svn://10.0.0.236/trunk@140561 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-02 05:48:09 +00:00
bryner%netscape.com
cf55de1ca0 Fix ctrl+enter in the mail compose window by getting rid of editor's key listeners in the client event pass entirely (everything now happens in the system event pass). r=brade, sr=sfraser.
git-svn-id: svn://10.0.0.236/trunk@140541 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-02 03:31:18 +00:00
glazman%netscape.com
f981e4719a meta-fix for image and table resizing bugs in html editor
solves bugs 195412, 196624, 196122, 195849, 197158, 195141, 195126, 199013
r=brade, sr=kin


git-svn-id: svn://10.0.0.236/trunk@140251 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-25 15:24:08 +00:00