Closed Bug 105708 Opened 23 years ago Closed 17 years ago

move nsUnitConversion.h

Categories

(Core :: XPCOM, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla1.9beta3

People

(Reporter: dougt, Assigned: reg)

Details

Attachments

(1 file)

move nsUnitConversion.h to layout.
Target Milestone: --- → mozilla1.0
Keywords: mozilla1.0
not required for mozilla 1.0
Target Milestone: mozilla1.0 → Future
Blocks: 150809
No longer blocks: 150809
Assignee: dougt → nobody
QA Contact: scc → xpcom
This moves the contents of nsUnitConversion.h into nsCoord.h.  The reasons for this are that nsUnitConversion.h creates a XPCOM dependency on GFX, which should not be, and the functions in it are only used by GFX and Layout.

I've just included the contents of nsUnitCoversion.h into nsCoord.h, rather than maintaining it as a separate header, because these really are helper functions for coordinates, and might as well be a part of the 'nscoord API'.  I can easily make a patch with this as a GFX header.  In this case it might require a repo copy to maintian the history?

I've tested this patch on unix and win32 only.  

I think this should be done now, rather than till waiting till after the branch, since, if it is done after the branch then merging back unit fixes will be harder.  It is low risk in that there are no code changes.

Regards,
  -Jeremy
Attachment #294929 - Flags: superreview?(roc)
Attachment #294929 - Flags: review?(roc)
Assignee: nobody → reg
OS: Windows 2000 → All
Hardware: PC → All
Target Milestone: Future → ---
Comment on attachment 294929 [details] [diff] [review]
Move the contents of nsUnitConversion.h to nsCoord.h

Looks good to me. Thanks for this!
Attachment #294929 - Flags: superreview?(roc)
Attachment #294929 - Flags: superreview+
Attachment #294929 - Flags: review?(roc)
Attachment #294929 - Flags: review+
Attachment #294929 - Flags: approval1.9?
Comment on attachment 294929 [details] [diff] [review]
Move the contents of nsUnitConversion.h to nsCoord.h

nsCoord.h should really move to layout
Keywords: checkin-needed
+ * an integer number of device pixels, such at the CSS DPI is as close to

Did you mean "so that the"?
Checking in embedding/browser/activex/src/control/StdAfx.h;
/cvsroot/mozilla/embedding/browser/activex/src/control/StdAfx.h,v  <--  StdAfx.h
new revision: 1.35; previous revision: 1.34
done
Checking in embedding/browser/photon/src/nsPrintSettingsImpl.cpp;
/cvsroot/mozilla/embedding/browser/photon/src/nsPrintSettingsImpl.cpp,v  <--  nsPrintSettingsImpl.cpp
new revision: 1.16; previous revision: 1.15
done
Checking in embedding/components/printingui/src/win/nsPrintDialogUtil.cpp;
/cvsroot/mozilla/embedding/components/printingui/src/win/nsPrintDialogUtil.cpp,v  <--  nsPrintDialogUtil.cpp
new revision: 1.30; previous revision: 1.29
done
Checking in gfx/public/nsCoord.h;
/cvsroot/mozilla/gfx/public/nsCoord.h,v  <--  nsCoord.h
new revision: 1.11; previous revision: 1.10
done
Checking in gfx/public/nsRect.h;
/cvsroot/mozilla/gfx/public/nsRect.h,v  <--  nsRect.h
new revision: 1.22; previous revision: 1.21
done
Checking in gfx/public/nsTransform2D.h;
/cvsroot/mozilla/gfx/public/nsTransform2D.h,v  <--  nsTransform2D.h
new revision: 1.11; previous revision: 1.10
done
Checking in gfx/src/nsColor.cpp;
/cvsroot/mozilla/gfx/src/nsColor.cpp,v  <--  nsColor.cpp
new revision: 3.35; previous revision: 3.34
done
Checking in gfx/src/nsRect.cpp;
/cvsroot/mozilla/gfx/src/nsRect.cpp,v  <--  nsRect.cpp
new revision: 3.22; previous revision: 3.21
done
Checking in gfx/src/nsRegressionTestFontMetrics.h;
/cvsroot/mozilla/gfx/src/nsRegressionTestFontMetrics.h,v  <--  nsRegressionTestFontMetrics.h
new revision: 1.6; previous revision: 1.5
done
Checking in gfx/src/beos/nsDeviceContextBeOS.h;
/cvsroot/mozilla/gfx/src/beos/nsDeviceContextBeOS.h,v  <--  nsDeviceContextBeOS.h
new revision: 1.19; previous revision: 1.18
done
Checking in gfx/src/beos/nsFontMetricsBeOS.h;
/cvsroot/mozilla/gfx/src/beos/nsFontMetricsBeOS.h,v  <--  nsFontMetricsBeOS.h
new revision: 1.15; previous revision: 1.14
done
Checking in gfx/src/beos/nsRenderingContextBeOS.h;
/cvsroot/mozilla/gfx/src/beos/nsRenderingContextBeOS.h,v  <--  nsRenderingContextBeOS.h
new revision: 1.33; previous revision: 1.32
done
Checking in gfx/src/mac/nsDeviceContextMac.h;
/cvsroot/mozilla/gfx/src/mac/nsDeviceContextMac.h,v  <--  nsDeviceContextMac.h
new revision: 1.60; previous revision: 1.59
done
Checking in gfx/src/mac/nsFontMetricsMac.h;
/cvsroot/mozilla/gfx/src/mac/nsFontMetricsMac.h,v  <--  nsFontMetricsMac.h
new revision: 1.36; previous revision: 1.35
done
Checking in gfx/src/photon/nsDeviceContextPh.h;
/cvsroot/mozilla/gfx/src/photon/nsDeviceContextPh.h,v  <--  nsDeviceContextPh.h
new revision: 1.34; previous revision: 1.33
done
Checking in gfx/src/photon/nsFontMetricsPh.h;
/cvsroot/mozilla/gfx/src/photon/nsFontMetricsPh.h,v  <--  nsFontMetricsPh.h
new revision: 1.21; previous revision: 1.20
done
Checking in gfx/src/photon/nsRenderingContextPh.h;
/cvsroot/mozilla/gfx/src/photon/nsRenderingContextPh.h,v  <--  nsRenderingContextPh.h
new revision: 1.44; previous revision: 1.43
done
Checking in gfx/src/thebes/nsSystemFontsBeOS.cpp;
/cvsroot/mozilla/gfx/src/thebes/nsSystemFontsBeOS.cpp,v  <--  nsSystemFontsBeOS.cpp
new revision: 1.4; previous revision: 1.3
done
Checking in gfx/src/thebes/nsSystemFontsOS2.cpp;
/cvsroot/mozilla/gfx/src/thebes/nsSystemFontsOS2.cpp,v  <--  nsSystemFontsOS2.cpp
new revision: 1.6; previous revision: 1.5
done
Checking in gfx/src/windows/nsFontMetricsWin.h;
/cvsroot/mozilla/gfx/src/windows/nsFontMetricsWin.h,v  <--  nsFontMetricsWin.h
new revision: 3.61; previous revision: 3.60
done
Checking in gfx/src/windows/nsRenderingContextWin.h;
/cvsroot/mozilla/gfx/src/windows/nsRenderingContextWin.h,v  <--  nsRenderingContextWin.h
new revision: 3.90; previous revision: 3.89
done
Checking in layout/generic/nsSpacerFrame.cpp;
/cvsroot/mozilla/layout/generic/nsSpacerFrame.cpp,v  <--  nsSpacerFrame.cpp
new revision: 1.47; previous revision: 1.46
done
Checking in layout/mathml/base/src/nsMathMLChar.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLChar.cpp,v  <--  nsMathMLChar.cpp
new revision: 1.136; previous revision: 1.135
done
Checking in layout/mathml/base/src/nsMathMLContainerFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLContainerFrame.cpp,v  <--  nsMathMLContainerFrame.cpp
new revision: 1.174; previous revision: 1.173
done
Checking in layout/mathml/base/src/nsMathMLForeignFrameWrapper.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLForeignFrameWrapper.cpp,v  <--  nsMathMLForeignFrameWrapper.cpp
new revision: 1.17; previous revision: 1.16
done
Checking in layout/mathml/base/src/nsMathMLTokenFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLTokenFrame.cpp,v  <--  nsMathMLTokenFrame.cpp
new revision: 1.64; previous revision: 1.63
done
Checking in layout/mathml/base/src/nsMathMLmactionFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmactionFrame.cpp,v  <--  nsMathMLmactionFrame.cpp
new revision: 1.87; previous revision: 1.86
done
Checking in layout/mathml/base/src/nsMathMLmfencedFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmfencedFrame.cpp,v  <--  nsMathMLmfencedFrame.cpp
new revision: 1.73; previous revision: 1.72
done
Checking in layout/mathml/base/src/nsMathMLmfracFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmfracFrame.cpp,v  <--  nsMathMLmfracFrame.cpp
new revision: 1.65; previous revision: 1.64
done
Checking in layout/mathml/base/src/nsMathMLmmultiscriptsFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmmultiscriptsFrame.cpp,v  <--  nsMathMLmmultiscriptsFrame.cpp
new revision: 1.42; previous revision: 1.41
done
Checking in layout/mathml/base/src/nsMathMLmoFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmoFrame.cpp,v  <--  nsMathMLmoFrame.cpp
new revision: 1.96; previous revision: 1.95
done
Checking in layout/mathml/base/src/nsMathMLmoverFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmoverFrame.cpp,v  <--  nsMathMLmoverFrame.cpp
new revision: 1.58; previous revision: 1.57
done
Checking in layout/mathml/base/src/nsMathMLmpaddedFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmpaddedFrame.cpp,v  <--  nsMathMLmpaddedFrame.cpp
new revision: 1.46; previous revision: 1.45
done
Checking in layout/mathml/base/src/nsMathMLmphantomFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmphantomFrame.cpp,v  <--  nsMathMLmphantomFrame.cpp
new revision: 1.19; previous revision: 1.18
done
Checking in layout/mathml/base/src/nsMathMLmrootFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmrootFrame.cpp,v  <--  nsMathMLmrootFrame.cpp
new revision: 1.58; previous revision: 1.57
done
Checking in layout/mathml/base/src/nsMathMLmrowFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmrowFrame.cpp,v  <--  nsMathMLmrowFrame.cpp
new revision: 1.21; previous revision: 1.20
done
Checking in layout/mathml/base/src/nsMathMLmspaceFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmspaceFrame.cpp,v  <--  nsMathMLmspaceFrame.cpp
new revision: 1.22; previous revision: 1.21
done
Checking in layout/mathml/base/src/nsMathMLmsqrtFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmsqrtFrame.cpp,v  <--  nsMathMLmsqrtFrame.cpp
new revision: 1.49; previous revision: 1.48
done
Checking in layout/mathml/base/src/nsMathMLmstyleFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmstyleFrame.cpp,v  <--  nsMathMLmstyleFrame.cpp
new revision: 1.42; previous revision: 1.41
done
Checking in layout/mathml/base/src/nsMathMLmsubFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmsubFrame.cpp,v  <--  nsMathMLmsubFrame.cpp
new revision: 1.46; previous revision: 1.45
done
Checking in layout/mathml/base/src/nsMathMLmsubsupFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmsubsupFrame.cpp,v  <--  nsMathMLmsubsupFrame.cpp
new revision: 1.46; previous revision: 1.45
done
Checking in layout/mathml/base/src/nsMathMLmsupFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmsupFrame.cpp,v  <--  nsMathMLmsupFrame.cpp
new revision: 1.45; previous revision: 1.44
done
Checking in layout/mathml/base/src/nsMathMLmtableFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmtableFrame.cpp,v  <--  nsMathMLmtableFrame.cpp
new revision: 1.69; previous revision: 1.68
done
Checking in layout/mathml/base/src/nsMathMLmunderFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmunderFrame.cpp,v  <--  nsMathMLmunderFrame.cpp
new revision: 1.58; previous revision: 1.57
done
Checking in layout/mathml/base/src/nsMathMLmunderoverFrame.cpp;
/cvsroot/mozilla/layout/mathml/base/src/nsMathMLmunderoverFrame.cpp,v  <--  nsMathMLmunderoverFrame.cpp
new revision: 1.58; previous revision: 1.57
done
Checking in layout/style/nsCSSDeclaration.cpp;
/cvsroot/mozilla/layout/style/nsCSSDeclaration.cpp,v  <--  nsCSSDeclaration.cpp
new revision: 3.160; previous revision: 3.159
done
Checking in layout/style/nsCSSParser.cpp;
/cvsroot/mozilla/layout/style/nsCSSParser.cpp,v  <--  nsCSSParser.cpp
new revision: 3.378; previous revision: 3.377
done
Checking in layout/style/nsCSSStruct.cpp;
/cvsroot/mozilla/layout/style/nsCSSStruct.cpp,v  <--  nsCSSStruct.cpp
new revision: 3.157; previous revision: 3.156
done
Checking in layout/style/nsCSSStyleRule.cpp;
/cvsroot/mozilla/layout/style/nsCSSStyleRule.cpp,v  <--  nsCSSStyleRule.cpp
new revision: 3.252; previous revision: 3.251
done
Checking in layout/style/nsCSSValue.h;
/cvsroot/mozilla/layout/style/nsCSSValue.h,v  <--  nsCSSValue.h
new revision: 1.53; previous revision: 1.52
done
Checking in layout/style/nsROCSSPrimitiveValue.h;
/cvsroot/mozilla/layout/style/nsROCSSPrimitiveValue.h,v  <--  nsROCSSPrimitiveValue.h
new revision: 1.23; previous revision: 1.22
done
Checking in layout/style/nsStyleContext.cpp;
/cvsroot/mozilla/layout/style/nsStyleContext.cpp,v  <--  nsStyleContext.cpp
new revision: 3.284; previous revision: 3.283
done
Checking in layout/style/nsStyleStruct.cpp;
/cvsroot/mozilla/layout/style/nsStyleStruct.cpp,v  <--  nsStyleStruct.cpp
new revision: 3.169; previous revision: 3.168
done
Checking in layout/style/nsStyleUtil.cpp;
/cvsroot/mozilla/layout/style/nsStyleUtil.cpp,v  <--  nsStyleUtil.cpp
new revision: 3.65; previous revision: 3.64
done
Checking in layout/xul/base/src/nsBoxFrame.cpp;
/cvsroot/mozilla/layout/xul/base/src/nsBoxFrame.cpp,v  <--  nsBoxFrame.cpp
new revision: 1.344; previous revision: 1.343
done
Checking in layout/xul/base/src/nsDeckFrame.cpp;
/cvsroot/mozilla/layout/xul/base/src/nsDeckFrame.cpp,v  <--  nsDeckFrame.cpp
new revision: 1.86; previous revision: 1.85
done
Checking in layout/xul/base/src/nsScrollbarButtonFrame.cpp;
/cvsroot/mozilla/layout/xul/base/src/nsScrollbarButtonFrame.cpp,v  <--  nsScrollbarButtonFrame.cpp
new revision: 1.57; previous revision: 1.56
done
Checking in layout/xul/base/src/nsSliderFrame.cpp;
/cvsroot/mozilla/layout/xul/base/src/nsSliderFrame.cpp,v  <--  nsSliderFrame.cpp
new revision: 1.171; previous revision: 1.170
done
Checking in layout/xul/base/src/nsStackFrame.cpp;
/cvsroot/mozilla/layout/xul/base/src/nsStackFrame.cpp,v  <--  nsStackFrame.cpp
new revision: 1.33; previous revision: 1.32
done
Checking in view/src/nsScrollPortView.cpp;
/cvsroot/mozilla/view/src/nsScrollPortView.cpp,v  <--  nsScrollPortView.cpp
new revision: 3.90; previous revision: 3.89
done
Checking in view/src/nsViewManager.cpp;
/cvsroot/mozilla/view/src/nsViewManager.cpp,v  <--  nsViewManager.cpp
new revision: 3.462; previous revision: 3.461
done
Checking in widget/src/beos/nsDragService.cpp;
/cvsroot/mozilla/widget/src/beos/nsDragService.cpp,v  <--  nsDragService.cpp
new revision: 1.21; previous revision: 1.20
done
Checking in widget/src/cocoa/nsScreenCocoa.mm;
/cvsroot/mozilla/widget/src/cocoa/nsScreenCocoa.mm,v  <--  nsScreenCocoa.mm
new revision: 1.5; previous revision: 1.4
done
Checking in widget/src/gtk2/nsDeviceContextSpecG.cpp;
/cvsroot/mozilla/widget/src/gtk2/nsDeviceContextSpecG.cpp,v  <--  nsDeviceContextSpecG.cpp
new revision: 1.95; previous revision: 1.94
done
Checking in widget/src/windows/nsDeviceContextSpecWin.cpp;
/cvsroot/mozilla/widget/src/windows/nsDeviceContextSpecWin.cpp,v  <--  nsDeviceContextSpecWin.cpp
new revision: 3.73; previous revision: 3.72
done
Checking in widget/src/xpwidgets/nsPrintOptionsImpl.cpp;
/cvsroot/mozilla/widget/src/xpwidgets/nsPrintOptionsImpl.cpp,v  <--  nsPrintOptionsImpl.cpp
new revision: 1.97; previous revision: 1.96
done
Checking in widget/src/xpwidgets/nsPrintSettingsImpl.cpp;
/cvsroot/mozilla/widget/src/xpwidgets/nsPrintSettingsImpl.cpp,v  <--  nsPrintSettingsImpl.cpp
new revision: 1.41; previous revision: 1.40
done
Checking in xpcom/ds/Makefile.in;
/cvsroot/mozilla/xpcom/ds/Makefile.in,v  <--  Makefile.in
new revision: 1.117; previous revision: 1.116
done
Removing xpcom/ds/nsUnitConversion.h;
/cvsroot/mozilla/xpcom/ds/nsUnitConversion.h,v  <--  nsUnitConversion.h
new revision: delete; previous revision: 3.17
done
Status: NEW → RESOLVED
Closed: 17 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9 M11
(In reply to comment #4)
> (From update of attachment 294929 [details] [diff] [review])
> nsCoord.h should really move to layout

Yes, but so should most of the old GFX code (which would be required to move nsCoord.h), and that's a job for another day...

(In reply to comment #5)
> + * an integer number of device pixels, such at the CSS DPI is as close to
> 
> Did you mean "so that the"?
> 

Yes...  I'm hoping to get some more patches committed to nsCoord.h, so I'll stick that fix in there...

Regards,
  -Jeremy
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: