158 Commits

Author SHA1 Message Date
roc+%cs.cmu.edu
8721fb6de7 Bug 53966. Don't just capture to the nearest view when selecting with mouse; only capture to the nearest scrolling view. r+sr=dbaron
git-svn-id: svn://10.0.0.236/trunk@159520 18797224-902f-48f8-a5cc-f745e15eee43
2004-07-20 00:02:43 +00:00
peterv%propagandism.org
0a98e68e54 Fix for bug 236408 (deCOMtaminate nsINodeInfoManager). r=caillon, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@158468 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-25 12:26:02 +00:00
bryner%brianryner.com
2a1c8d3594 deCOMtaminate nsBoxLayoutState. Bug 247766, r+sr=roc.
git-svn-id: svn://10.0.0.236/trunk@158283 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-22 02:55:04 +00:00
bryner%brianryner.com
c69233d235 oops, this wasn't supposed to go on the trunk. backing out.
git-svn-id: svn://10.0.0.236/trunk@158278 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-21 23:41:30 +00:00
bryner%brianryner.com
ea5334a7ce bringing branch changes forward
git-svn-id: svn://10.0.0.236/trunk@158277 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-21 23:35:56 +00:00
bryner%brianryner.com
c52276bdfd Make XUL box debug code be #ifdef DEBUG_LAYOUT. r+sr=roc, bug 103844.
git-svn-id: svn://10.0.0.236/trunk@158188 18797224-902f-48f8-a5cc-f745e15eee43
2004-06-19 09:07:47 +00:00
bzbarsky%mit.edu
61611d381f Instead of setting inline style for every text input's anonymous div, have a
rule in forms.css to set the style.  Bug 243588, r+sr=dbaron


git-svn-id: svn://10.0.0.236/trunk@156425 18797224-902f-48f8-a5cc-f745e15eee43
2004-05-15 05:09:37 +00:00
rbs%maths.uq.edu.au
58f6833e11 Fix the inconsistent behavior of the caret on text controls when their readonly attribute is changed, b=235294, r+sr=bzbarsky
git-svn-id: svn://10.0.0.236/trunk@156014 18797224-902f-48f8-a5cc-f745e15eee43
2004-05-05 22:48:51 +00:00
bzbarsky%mit.edu
2627a4e419 Don't clear undo/redo buffers when JS changes the value. Bug 158071, patch by
Martijn Wargers <m.wargers@hccnet.nl>, r=bryner, sr=dbaron


git-svn-id: svn://10.0.0.236/trunk@155848 18797224-902f-48f8-a5cc-f745e15eee43
2004-05-02 22:14:49 +00:00
gerv%gerv.net
2ac510b678 Bug 236613: change to MPL/LGPL/GPL tri-license.
git-svn-id: svn://10.0.0.236/trunk@155068 18797224-902f-48f8-a5cc-f745e15eee43
2004-04-18 14:30:37 +00:00
rbs%maths.uq.edu.au
bfe77ca6d3 Add the much requested support for find in <textarea> and text <input> elements. Also fix a long-standing problem with the mutually-exclusion: selecting something in a text field doesn't clear an earlier selection outside. b=58305, r=akkana, sr=jst
git-svn-id: svn://10.0.0.236/trunk@154934 18797224-902f-48f8-a5cc-f745e15eee43
2004-04-15 19:45:46 +00:00
bzbarsky%mit.edu
c2c4cce304 Make sure to apply our styles to our anonymous content no matter what the
page's style language is.  Bug 234761, r=sicking, sr=jst


git-svn-id: svn://10.0.0.236/trunk@154840 18797224-902f-48f8-a5cc-f745e15eee43
2004-04-14 02:05:52 +00:00
roc+%cs.cmu.edu
80b27683f0 Bug 227838. Remove unused RequiresWidget method from nsIFormControlFrame. r+sr=bzbarsky
git-svn-id: svn://10.0.0.236/trunk@154764 18797224-902f-48f8-a5cc-f745e15eee43
2004-04-13 03:11:05 +00:00
bryner%brianryner.com
4b70febae6 inline IsPaginated, SetPaginatedScrolling, and GetPaginatedScrolling. Bug 229371, r+sr=roc.
git-svn-id: svn://10.0.0.236/trunk@153488 18797224-902f-48f8-a5cc-f745e15eee43
2004-03-03 18:24:20 +00:00
bzbarsky%mit.edu
8a5b5bbe43 Don't lie about our scrollable view, and don't claim to have one if we're not
scrollable.  Bug 209807, r+sr=roc


git-svn-id: svn://10.0.0.236/trunk@152983 18797224-902f-48f8-a5cc-f745e15eee43
2004-02-19 23:04:51 +00:00
bryner%brianryner.com
7ace3321e6 Inline TwipsToPixels and PixelsToTwips on nsIPresContext. Bug 229371, r+sr=dbaron.
git-svn-id: svn://10.0.0.236/trunk@152647 18797224-902f-48f8-a5cc-f745e15eee43
2004-02-11 04:57:07 +00:00
sicking%bigfoot.com
26c9ab7b2b Bug 232706: Remove unneccesary datatypes from nsHTMLValue and cleanup AttributeToString.
r=caillon sr=jst


git-svn-id: svn://10.0.0.236/trunk@152623 18797224-902f-48f8-a5cc-f745e15eee43
2004-02-11 00:38:12 +00:00
bryner%brianryner.com
5b5cd321a4 Guarantee that the pres context's device context will be non-null by returning failure from Init() if it's null. Rename inline getter GetDeviceContext() to DeviceContext(), convert all callers to use the inline getter, and remove the virtual/refcounting getter. Bug 229371, r+sr=dbaron.
git-svn-id: svn://10.0.0.236/trunk@152182 18797224-902f-48f8-a5cc-f745e15eee43
2004-02-02 22:17:21 +00:00
bryner%brianryner.com
3d8a7179f8 Improve the way in which nsEvent and its subclasses are initialized. Commonly-used members can now be initialized via an inline constructor, and all other members are initialized to zero. eventStructType is set automatically. This also fixes some cases where an eventStructType was doubling as a message -- NS_TEXT_EVENT is now only used as an eventStructType, with a message of NS_TEXT_TEXT. NS_COMPOSITION_* events get an eventStructType of NS_COMPOSITION_EVENT, and ditto for NS_RECONVERSION_*. NS_DRAGDROP_EVENT is no longer an eventStructType since it is not a unique type of struct. There is also some miscellaneous cleanup to nsDOMEvent. Bug 220228, r=jst, sr=blizzard.
git-svn-id: svn://10.0.0.236/trunk@151191 18797224-902f-48f8-a5cc-f745e15eee43
2004-01-12 08:25:18 +00:00
roc+%cs.cmu.edu
35c266025d Bug 190735. deCOMtaminate nsIFrame::FirstChild and nsIFrame::GetAdditionalChildListName. r+sr=bz
git-svn-id: svn://10.0.0.236/trunk@151077 18797224-902f-48f8-a5cc-f745e15eee43
2004-01-09 14:20:53 +00:00
bryner%brianryner.com
4cca78120d deCOMtaminate nsIPresContext::GetCompatibilityMode / SetCompatibilityMode (bug 229081). r+sr=bzbarsky.
git-svn-id: svn://10.0.0.236/trunk@150720 18797224-902f-48f8-a5cc-f745e15eee43
2003-12-24 21:51:50 +00:00
bryner%brianryner.com
b5347dd60c Change all callers of nsIPresContext::GetShell() to use the non-refcounting versions. Most callers now use PresShell(), a few that were checking for null conditions are using GetPresShell() -- this will be remedied once we can ensure that a prescontext never has a null pres shell. Bug 227690, r+sr=bzbarsky.
git-svn-id: svn://10.0.0.236/trunk@150598 18797224-902f-48f8-a5cc-f745e15eee43
2003-12-21 05:36:36 +00:00
dbaron%dbaron.org
08ec785b8b Account for 1 twip width of BR when computing the size of textareas. b=228752 Patch by Mats Palmgren <mats.palmgren@bredband.net>. r+sr=dbaron a=brendan
git-svn-id: svn://10.0.0.236/trunk@150407 18797224-902f-48f8-a5cc-f745e15eee43
2003-12-18 06:06:00 +00:00
jst%mozilla.jstenback.com
2affc5b4f0 Fixing bug 225837. DeCOMtaminating nsIContent more, making GetTag() return a weak raw pointer, and renaming GetTag() to Tag(), and making GetRangeList() return an const nsVoidArray*, and changing GetContentID() to return the id, and renaming it to ContentID(). r=jonas@sicking.cc, sr=bryner@brianryner.com.
git-svn-id: svn://10.0.0.236/trunk@149527 18797224-902f-48f8-a5cc-f745e15eee43
2003-11-19 01:20:56 +00:00
bzbarsky%mit.edu
fe8bc15211 Don't do our "enlarge the control a bit to make it look better for small sizes"
thing for fixed-width fonts -- it's unnecessary and just makes it look like
"size" is broken.  Bug 103293, r+sr=rbs


git-svn-id: svn://10.0.0.236/trunk@149128 18797224-902f-48f8-a5cc-f745e15eee43
2003-11-10 23:42:43 +00:00
uid502
e56ed2443c Bug 190735. DeCOMtaminate nsIFrame::GetFrameType. r+sr=bzbarsky
git-svn-id: svn://10.0.0.236/trunk@148665 18797224-902f-48f8-a5cc-f745e15eee43
2003-10-31 20:19:18 +00:00
bryner%brianryner.com
eeddf02bde deCOMtaminate nsIDocument by changing methods to use return value instead of out-params, eliminating unused nsresult return values, moving some members to nsIDocument and inlining the getters/setters. Bug 222134, r=bzbarsky, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@148257 18797224-902f-48f8-a5cc-f745e15eee43
2003-10-22 06:09:48 +00:00
dbaron%dbaron.org
33601224e0 Use the correct term "float" instead of "floater". b=218654 r+sr=bzbarsky
git-svn-id: svn://10.0.0.236/trunk@147924 18797224-902f-48f8-a5cc-f745e15eee43
2003-10-13 21:51:02 +00:00
jst%mozilla.jstenback.com
ef67a47aab Fixing bug 215981. DeCOMtaminating nsIContent and nsIDocument some, and also some minor changes to other related interfaces. r=caillon@aillon.org, sr=peterv@propagandism.org.
git-svn-id: svn://10.0.0.236/trunk@147354 18797224-902f-48f8-a5cc-f745e15eee43
2003-09-27 04:18:26 +00:00
uid502
8080dd532b Bug 217201. Make nsTextControlFrame::InitEditor() happen outside of reflow, to prevent content notification flushes and reentrancy. r+rs=dbaron
git-svn-id: svn://10.0.0.236/trunk@147060 18797224-902f-48f8-a5cc-f745e15eee43
2003-09-19 15:20:00 +00:00
bryner%brianryner.com
dbbc84bf94 Fix build on gcc 3.4 by removing extra semicolons (bug 218551). r/sr=dbaron, a=brendan.
git-svn-id: svn://10.0.0.236/trunk@146620 18797224-902f-48f8-a5cc-f745e15eee43
2003-09-07 22:37:27 +00:00
darin%meer.net
0d0959dea5 fixes bug 175896 "crash when selecting data overflowing vertically in a textarea having the overflow = hidden property [@ nsSelection::GetFrameForNodeOffset ]" r+sr+a=dbaron
git-svn-id: svn://10.0.0.236/trunk@146240 18797224-902f-48f8-a5cc-f745e15eee43
2003-08-20 20:15:34 +00:00
bzbarsky%mit.edu
82c14d79dd DeCOMify GetParent/GetBindingParent/GetDocument on nsIContent. Bug 213823,
r+sr=jst


git-svn-id: svn://10.0.0.236/trunk@145289 18797224-902f-48f8-a5cc-f745e15eee43
2003-07-28 21:25:13 +00:00
jaggernaut%netscape.com
df747d0621 Bug 213602: Switch some users of NS_GetWeakReference over to do_GetWeakReference. r=bzbarsky, sr=dbaron
git-svn-id: svn://10.0.0.236/trunk@145205 18797224-902f-48f8-a5cc-f745e15eee43
2003-07-25 19:06:59 +00:00
brade%netscape.com
a6ecc06d75 patch from mjudge to maintainselection; r/sr=dbaron, bug=56401
git-svn-id: svn://10.0.0.236/trunk@145030 18797224-902f-48f8-a5cc-f745e15eee43
2003-07-21 19:51:34 +00:00
dbaron%dbaron.org
593f58592d Remove hint parameter from AttributeChanged methods and simplify style hint mechanism. b=211308 r+sr=bzbarsky
git-svn-id: svn://10.0.0.236/trunk@144735 18797224-902f-48f8-a5cc-f745e15eee43
2003-07-11 21:16:12 +00:00
roc+%cs.cmu.edu
ca3b83ccdf Ongoing deCOMtamination. r+sr=dbaron
git-svn-id: svn://10.0.0.236/trunk@144465 18797224-902f-48f8-a5cc-f745e15eee43
2003-07-04 12:50:32 +00:00
rbs%maths.uq.edu.au
a6c97c6fb0 Helper patch for bug 15364. Expose an API to allow scripts to show the caret even in selections (a la Emacs). Users can also set the pref ui.caretVisibleWithSelection to 1, which gives a nice combination with caret browsing (hit F7). r=sfraser, sr=bzbarsky
git-svn-id: svn://10.0.0.236/trunk@144128 18797224-902f-48f8-a5cc-f745e15eee43
2003-06-25 01:14:25 +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
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
dbaron%dbaron.org
69da9d4a19 Clean up API (and its callers) for getting style data: remove unneeded null checks and switch to new inline member functions (one for each struct) that return values. b=197205 r+sr=roc a=brendan
git-svn-id: svn://10.0.0.236/trunk@142488 18797224-902f-48f8-a5cc-f745e15eee43
2003-05-15 03:42:21 +00:00
sfraser%netscape.com
4a0df27c9c Fix bug 201257 -- clean up use of nsIControllerCommandManager by editor:
Renaming nsIControllerCommandManager to nsIControllerCommandTable to reduce confusion.
Moving the immutability flag from the nsBaseCommandController to the nsControllerCommandTable.
Renaming the 'refcon' on nsIControllerContext to 'context', and giving nsIControllerContext an Init() method that optionally takes a command table.
Fixing the editor and composer module code to create pre-filled nsIControllerCommandTables as services, and the controller constructors to create singleton command tables with do_GetService.
r=brade, sr=alecf.


git-svn-id: svn://10.0.0.236/trunk@140988 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-10 18:44:03 +00:00
roc+%cs.cmu.edu
d4ac9a5795 Bug 126263. Whack comboboxes/listboxes to use Gfx scrollbars. Also, make scrollbars attach their XBL content only when they become visible, to avoid pageload hit. r+sr=dbaron
git-svn-id: svn://10.0.0.236/trunk@140858 18797224-902f-48f8-a5cc-f745e15eee43
2003-04-08 20:50:57 +00:00
roc+%cs.cmu.edu
071d5592f4 Bug 183905. Allow horizontal scrolling with mouse sticks. Patch by Dainis_Jonitis, r+sr=roc+moz
git-svn-id: svn://10.0.0.236/trunk@139310 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-12 03:22:11 +00:00
kin%netscape.com
dd9ec493c4 Fix for bug 190382 (selectionEnd off by one when user selects text via CMD/CTRL-A)
- Prevent DOMPointToOffset() from counting a br as a newline, if it is the last child of the anonymous div.

- Fixed 3 compiler warnings in DOMPointToOffset().

r=jkeiser@netscape.com  sr=sfraser@netscape.com  a=asa@mozilla.org


git-svn-id: svn://10.0.0.236/trunk@136979 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-27 15:25:38 +00:00
kin%netscape.com
bf1214f351 Fix for bug 188440 (textfields clobber selection when they should not.)
mozilla/layout/html/forms/src/nsTextControlFrame.cpp
  mozilla/layout/html/forms/src/nsTextControlFrame.h

Revert back to using a private method (SelectAllContents()) which implements a select all of the text widget contents by manually creating a range and adding it to the selection. This avoids triggering the autocomplete selection listener, which listens for a selection reason of SELECTALL_REASON. This change should be undone once the autocomplete listener is modified to distinguish between a programatic select all and one generated by a user gesture.

r=brade  sr=sfraser@netscape.com


git-svn-id: svn://10.0.0.236/trunk@136731 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-21 15:17:32 +00:00
dbaron%dbaron.org
a569c670f5 Replace computation of max-element-size (height and width) with max-element-width alone, since the max-element-height is practically unused and not meaningful for layout. b=186953 r+sr=bzbarsky
git-svn-id: svn://10.0.0.236/trunk@136064 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-09 14:26:32 +00:00
kin%netscape.com
4c2a2376d9 Fix for bug #88049: Support .selectionStart & friends for textareas
Patch by petejc@optonline.net and kin@netscape.com

  mozilla/content/html/content/src/nsHTMLInputElement.cpp
  mozilla/content/html/content/src/nsHTMLTextAreaElement.cpp
  mozilla/dom/public/idl/html/nsIDOMNSHTMLTextAreaElement.idl
  mozilla/layout/html/forms/src/nsTextControlFrame.cpp
  mozilla/layout/html/forms/src/nsTextControlFrame.h

Re-implemented selectionStart, selectionEnd, setSelectionRange() and various

utility methods in nsTextControlFrame to support multi-line text widgets.


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


git-svn-id: svn://10.0.0.236/trunk@136054 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-09 06:06:17 +00:00
dbaron%dbaron.org
c278517282 Bug 178643: Remove uses of NS_INIT_ISUPPORTS, since it is no longer needed. r=timeless sr=jag
git-svn-id: svn://10.0.0.236/trunk@136010 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-08 21:19:10 +00:00
jkeiser%netscape.com
ac42e42ba8 Make GetType() return int instead of nsresult (bug 167762), r=peterl@netscape.com, sr=kin@netscape.com
git-svn-id: svn://10.0.0.236/trunk@135468 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-18 23:38:09 +00:00