rpms/firefox/FC-6 firefox-1.5-dnd-nograb.patch, NONE, 1.1 firefox-1.5-pango-cursor-position-more.patch, NONE, 1.1 firefox-1.5-pango-justified-range.patch, NONE, 1.1 firefox-1.5-pango-underline.patch, NONE, 1.1 firefox.sh.in, 1.14, 1.15 firefox.spec, 1.161, 1.162

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Wed Jan 31 05:08:10 UTC 2007


Author: caillon

Update of /cvs/dist/rpms/firefox/FC-6
In directory cvs.devel.redhat.com:/tmp/cvs-serv16557

Modified Files:
	firefox.sh.in firefox.spec 
Added Files:
	firefox-1.5-dnd-nograb.patch 
	firefox-1.5-pango-cursor-position-more.patch 
	firefox-1.5-pango-justified-range.patch 
	firefox-1.5-pango-underline.patch 
Log Message:
* Tue Jan 30 2007 Christopher Aillon <caillon at redhat.com> 1.5.0.9-2
- Fix the DND implementation to not grab, so it works with new GTK+.
- Multilib -devel and -debuginfo fixes
- Various pango fixes from behdad and tagoh
- Some minor langpack fixes


firefox-1.5-dnd-nograb.patch:
 nsDragService.cpp |    2 --
 1 files changed, 2 deletions(-)

--- NEW FILE firefox-1.5-dnd-nograb.patch ---
See https://bugzilla.mozilla.org/show_bug.cgi?id=367203

Index: mozilla/widget/src/gtk2/nsDragService.cpp
===================================================================
RCS file: /cvsroot/mozilla/widget/src/gtk2/nsDragService.cpp,v
retrieving revision 1.9.10.1
diff -d -u -p -r1.9.10.1 nsDragService.cpp
--- mozilla/widget/src/gtk2/nsDragService.cpp	22 Jun 2006 21:37:45 -0000	1.9.10.1
+++ mozilla/widget/src/gtk2/nsDragService.cpp	31 Jan 2007 04:27:43 -0000
@@ -799,7 +799,6 @@ nsDragService::IsTargetContextList(void)
 void
 nsDragService::GetTargetDragData(GdkAtom aFlavor)
 {
-    gtk_grab_add(mHiddenWidget);
     PR_LOG(sDragLm, PR_LOG_DEBUG, ("getting data flavor %d\n", aFlavor));
     PR_LOG(sDragLm, PR_LOG_DEBUG, ("mLastWidget is %p and mLastContext is %p\n",
                                    mTargetWidget, mTargetDragContext));
@@ -817,7 +816,6 @@ nsDragService::GetTargetDragData(GdkAtom
         gtk_main_iteration();
     }
     PR_LOG(sDragLm, PR_LOG_DEBUG, ("finished inner iteration\n"));
-    gtk_grab_remove(mHiddenWidget);
 }
 
 void

firefox-1.5-pango-cursor-position-more.patch:
 nsTextFrame.cpp |    8 +++-----
 1 files changed, 3 insertions(+), 5 deletions(-)

--- NEW FILE firefox-1.5-pango-cursor-position-more.patch ---
diff -pruN -x '.moz*' -x .deps -x 'firefox*' -x '*.mk' -x 'config*' -x dist -x build -x toolkit -x '*o' -x '*a' -x '*html' mozilla.orig/layout/generic/nsTextFrame.cpp mozilla/layout/generic/nsTextFrame.cpp
--- mozilla.orig/layout/generic/nsTextFrame.cpp	2006-08-26 13:33:35.000000000 +0900
+++ mozilla/layout/generic/nsTextFrame.cpp	2006-12-13 20:54:32.000000000 +0900
@@ -4261,12 +4261,10 @@ nsTextFrame::GetPointFromOffset(nsPresCo
       if (tc) {
         totalLength = tc->Text()->GetLength(); // raw value which includes whitespace
       }
-      if ((hitLength == textLength) && (inOffset = mContentLength) &&
-          (mContentOffset + mContentLength == totalLength)) {
-        // no need to re-measure when at the end of the last-in-flow
-      }
+      if (hitLength > 0)
+	inRendContext->GetRangeWidth(paintBuffer.mBuffer, textLength, 0, hitLength, (PRUint32&)width);
       else
-        inRendContext->GetWidth(paintBuffer.mBuffer, hitLength, width);
+	width = 0;
     }
     if ((hitLength == textLength) && (TEXT_TRIMMED_WS & mState)) {
       //

firefox-1.5-pango-justified-range.patch:
 nsTextFrame.cpp |   13 +++++++------
 1 files changed, 7 insertions(+), 6 deletions(-)

--- NEW FILE firefox-1.5-pango-justified-range.patch ---
diff -pruN -x '.moz*' -x .deps -x 'thunderbird*' -x '*.mk' -x 'config*' -x dist -x build -x toolkit -x '*o' -x '*a' -x '*html' -x 'firefox*' mozilla.orig/layout/generic/nsTextFrame.cpp mozilla/layout/generic/nsTextFrame.cpp
--- mozilla.orig/layout/generic/nsTextFrame.cpp	2006-12-20 12:15:38.000000000 +0900
+++ mozilla/layout/generic/nsTextFrame.cpp	2006-12-20 21:29:39.000000000 +0900
@@ -2973,15 +2973,16 @@ nsTextFrame::RenderString(nsIRenderingCo
 
   nsIFontMetrics* lastFont = aTextStyle.mLastFont;
   PRInt32 pendingCount;
-  PRUnichar* runStart = bp;
+  PRUnichar* runStart = bp, *top = aBuffer;
   nscoord charWidth, width = 0;
   PRInt32 countSoFar = 0;
+  PRUint32 offset;
   // Save the color we want to use for the text, since calls to
   // PaintTextDecorations in this method will call SetColor() on the rendering
   // context.
   nscolor textColor;
   aRenderingContext.GetColor(textColor);
-  for (; --aLength >= 0; aBuffer++) {
+  for (offset = 0; offset < aLength; aBuffer++, offset++) {
     nsIFontMetrics* nextFont;
     nscoord glyphWidth = 0;
     PRUnichar ch = *aBuffer;
@@ -3038,7 +3039,7 @@ nsTextFrame::RenderString(nsIRenderingCo
     else if (ch == ' ') {
       glyphWidth += aTextStyle.mSpaceWidth + aTextStyle.mWordSpacing + aTextStyle.mLetterSpacing;
     }
-    else if (IS_HIGH_SURROGATE(ch) && aLength > 0 &&
+    else if (IS_HIGH_SURROGATE(ch) && (offset + 1) < aLength &&
            IS_LOW_SURROGATE(*(aBuffer+1))) {
       
       // special handling for surrogate pair
@@ -3046,7 +3047,7 @@ nsTextFrame::RenderString(nsIRenderingCo
       glyphWidth += charWidth + aTextStyle.mLetterSpacing;
       // copy the surrogate low
       *bp++ = ch;
-      --aLength;
+      offset++;
       aBuffer++;
       ch = *aBuffer;
       // put the width into the space buffer
@@ -3058,10 +3059,10 @@ nsTextFrame::RenderString(nsIRenderingCo
       glyphWidth = 0;
     }
     else {
-      aRenderingContext.GetWidth(ch, charWidth);
+      aRenderingContext.GetRangeWidth(top, aLength, offset, offset + 1, (PRUint32&)charWidth);
       glyphWidth += charWidth + aTextStyle.mLetterSpacing;
     }
-    if (justifying && (!isEndOfLine || aLength > 0)
+    if (justifying && (!isEndOfLine || (offset + 1) < aLength)
         && IsJustifiableCharacter(ch, isCJ)) {
       glyphWidth += aTextStyle.mExtraSpacePerJustifiableCharacter;
       if ((PRUint32)--aTextStyle.mNumJustifiableCharacterToRender

firefox-1.5-pango-underline.patch:
 nsTextFrame.cpp |   15 +++++++--------
 1 files changed, 7 insertions(+), 8 deletions(-)

--- NEW FILE firefox-1.5-pango-underline.patch ---
diff -pruN -x '.moz*' -x .deps -x 'thunderbird*' -x '*.mk' -x 'config*' -x dist -x build -x toolkit -x '*o' -x '*a' -x '*html' mozilla.orig/layout/generic/nsTextFrame.cpp mozilla/layout/generic/nsTextFrame.cpp
--- mozilla.orig/layout/generic/nsTextFrame.cpp	2006-12-20 12:53:26.000000000 +0900
+++ mozilla/layout/generic/nsTextFrame.cpp	2006-12-20 15:43:14.000000000 +0900
@@ -2097,11 +2097,11 @@ nsTextFrame::PaintTextDecorations(nsIRen
     nsRect rect = GetRect();
     while(aDetails){
       const nscoord* sp= aSpacing;
-      PRInt32 startOffset = 0;
-      PRInt32 textWidth = 0;
-      PRInt32 start = PR_MAX(0,(aDetails->mStart - (PRInt32)aIndex));
-      PRInt32 end = PR_MIN((PRInt32)aLength,(aDetails->mEnd - (PRInt32)aIndex));
-      PRInt32 i;
+      PRUint32 startOffset = 0;
+      PRUint32 textWidth = 0;
+      PRUint32 start = PR_MAX(0,(aDetails->mStart - (PRInt32)aIndex));
+      PRUint32 end = PR_MIN((PRInt32)aLength,(aDetails->mEnd - (PRInt32)aIndex));
+      PRUint32 i;
       if ((start < end) && ((aLength - start) > 0))
       {
         //aDetails allready processed to have offsets from frame start not content offsets
@@ -2117,7 +2117,7 @@ nsTextFrame::PaintTextDecorations(nsIRen
                 }
               }
               else
-                aRenderingContext.GetWidth(aText, start, startOffset);
+                aRenderingContext.GetRangeWidth(aText, aLength, 0, start, startOffset);
             }
             if (sp){
               for (i = start; i < end;i ++){
@@ -2125,8 +2125,7 @@ nsTextFrame::PaintTextDecorations(nsIRen
               }
             }
             else
-              aRenderingContext.GetWidth(aText + start,
-                                           PRUint32(end - start), textWidth);
+              aRenderingContext.GetRangeWidth(aText, aLength, start, end, textWidth);
   
           }
           nscoord offset, size;


Index: firefox.sh.in
===================================================================
RCS file: /cvs/dist/rpms/firefox/FC-6/firefox.sh.in,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- firefox.sh.in	3 Sep 2006 22:24:52 -0000	1.14
+++ firefox.sh.in	31 Jan 2007 05:08:01 -0000	1.15
@@ -42,6 +42,7 @@
   MOZ_LIB_DIR="/usr/lib64"
 fi
 MOZ_DIST_BIN="$MOZ_LIB_DIR/firefox-FIREFOX_VERSION"
+MOZ_EXTENSIONS_DIR="$MOZ_DIST_BIN/extensions"
 MOZ_PROGRAM="$MOZ_DIST_BIN/firefox"
 MOZ_CLIENT_PROGRAM="$MOZ_DIST_BIN/mozilla-xremote-client"
 MOZ_CLIENT_PROGRAM_PARAM="-a firefox"
@@ -137,9 +138,13 @@
 
 # check system locale
 MOZARGS=
-MOZLOCALE=`echo $LANG | sed "s|_\([^.]*\).*|-\1|g"`
-[ -f $MOZILLA_FIVE_HOME/chrome/$MOZLOCALE.jar ] && MOZARGS="-UILocale $MOZLOCALE"
+# Try without a local variant first, then with a local variant
+# So that pt-BR doesn't try to use pt for example
+SHORTMOZLOCALE=`echo $LANG | sed "s|_\([^.]*\).*||g"`
+[ -f $MOZ_EXTENSIONS_DIR/langpack-${SHORTMOZLOCALE}@firefox.mozilla.org/chrome/$SHORTMOZLOCALE.jar ] && MOZARGS="-UILocale $SHORTMOZLOCALE"
 
+MOZLOCALE=`echo $LANG | sed "s|_\([^.]*\).*|-\1|g"`
+[ -f $MOZ_EXTENSIONS_DIR/langpack-${MOZLOCALE}@firefox.mozilla.org/chrome/$MOZLOCALE.jar ] && MOZARGS="-UILocale $MOZLOCALE"
 
 # if there's no command line argument and there's not a running
 # instance then just fire up a new copy of the browser


Index: firefox.spec
===================================================================
RCS file: /cvs/dist/rpms/firefox/FC-6/firefox.spec,v
retrieving revision 1.161
retrieving revision 1.162
diff -u -r1.161 -r1.162
--- firefox.spec	19 Dec 2006 18:30:28 -0000	1.161
+++ firefox.spec	31 Jan 2007 05:08:01 -0000	1.162
@@ -11,7 +11,7 @@
 Summary:        Mozilla Firefox Web browser.
 Name:           firefox
 Version:        1.5.0.9
-Release:        1%{?dist}
+Release:        2%{?dist}
 URL:            http://www.mozilla.org/projects/firefox/
 License:        MPL/LGPL
 Group:          Applications/Internet
@@ -58,9 +58,13 @@
 Patch82:        firefox-1.5-pango-mathml.patch
 Patch83:        firefox-1.5-pango-cursor-position.patch
 Patch84:        firefox-1.5-pango-printing.patch
+Patch85:        firefox-1.5-pango-cursor-position-more.patch
+Patch86:        firefox-1.5-pango-justified-range.patch
+Patch87:        firefox-1.5-pango-underline.patch
 
 # Other
 Patch102:       firefox-1.5-theme-change.patch
+Patch103:       firefox-1.5-dnd-nograb.patch
 
 %if %{official_branding}
 # Required by Mozilla Corporation
@@ -130,7 +134,9 @@
 #---------------------------------------------------------------------
 
 %prep
-%setup -q -n mozilla
+%setup -q -c %{name}-%{version}
+cd mozilla
+
 %patch3  -p1
 %patch4  -p1
 #%patch5  -p1 -b .visibility
@@ -151,6 +157,9 @@
 %patch82 -p1 -b .pango-mathml
 %patch83 -p1 -b .pango-cursor-position
 %patch84 -p1 -b .pango-printing
+%patch85 -p1 -b .pango-cursor-position-more
+%patch86 -p1 -b .pango-justified-range
+%patch87 -p1 -b .pango-underline
 pushd gfx/src/ps
   # This sort of sucks, but it works for now.
   ln -s ../gtk/nsFontMetricsPango.h .
@@ -160,6 +169,7 @@
 popd
 
 %patch102 -p0 -b .theme-change
+%patch103 -p1 -b .dnd-nograb
 
 # For branding specific patches.
 
@@ -180,12 +190,13 @@
 %endif
 
 # set up our default bookmarks
-%{__cp} %{SOURCE12} $RPM_BUILD_DIR/mozilla/profile/defaults/bookmarks.html
+%{__cp} %{SOURCE12} profile/defaults/bookmarks.html
 
 
 #---------------------------------------------------------------------
 
 %build
+cd mozilla
 
 # Build with -Os as it helps the browser; also, don't override mozilla's warning
 # level; they use -Wall but disable a few warnings that show up _everywhere_
@@ -208,6 +219,7 @@
 #---------------------------------------------------------------------
 
 %install
+cd mozilla
 %{__rm} -rf $RPM_BUILD_ROOT
 
 cd browser/installer
@@ -273,6 +285,7 @@
 # Install langpacks
 %{__mkdir_p} $RPM_BUILD_ROOT%{mozappdir}/extensions
 %{__tar} xjf %{SOURCE2}
+
 for langpack in `ls firefox-langpacks/*.xpi`; do
   language=`basename $langpack .xpi`
   extensiondir=$RPM_BUILD_ROOT%{mozappdir}/extensions/langpack-$language at firefox.mozilla.org
@@ -284,7 +297,12 @@
   %{__mkdir_p} $langtmp
   jarfile=$extensiondir/chrome/$language.jar
   unzip $jarfile -d $langtmp
-  sed -i -e "s|browser.startup.homepage.*$|browser.startup.homepage=%{indexhtml}|g;" $langtmp/locale/browser-region/region.properties
+
+  sed -i -e "s|browser.startup.homepage.*$|browser.startup.homepage=%{indexhtml}|g;" \
+         -e "s|homePageDefault.*$|homePageDefault=%{indexhtml}|g;" \
+         -e "s|startup.homepage_override_url.*$|startup.homepage_override_url=%{indexhtml}|g;" \
+      $langtmp/locale/browser-region/region.properties
+
   find $langtmp -type f | xargs chmod 644
   %{__rm} -rf $jarfile
   cd $langtmp
@@ -296,6 +314,25 @@
 
 # Prepare our devel package
 %if %{build_devel_package}
+# Fix multilib devel conflicts...
+%ifarch x86_64 ia64 s390x ppc64
+%define mozbits 64
+%else
+%define mozbits 32
+%endif
+
+for genheader in js/jsautocfg mozilla-config; do
+mv dist/include/${genheader}.h dist/include/${genheader}%{mozbits}.h
+cat > dist/include/${genheader}.h << EOF
+// This file exists to fix multilib conflicts
+#if defined(__x86_64__) || defined(__ia64__) || defined(__s390x__) || defined(__ppc64__)
+#include "${genheader}64.h"
+#else
+#include "${genheader}32.h"
+#endif
+EOF
+done
+
 %{__mkdir_p} $RPM_BUILD_ROOT/%{_includedir}/firefox-%{version}
 %{__mkdir_p} $RPM_BUILD_ROOT/%{_datadir}/idl/firefox-%{version}
 %{__mkdir_p} $RPM_BUILD_ROOT/%{_libdir}/pkgconfig
@@ -415,6 +452,12 @@
 #---------------------------------------------------------------------
 
 %changelog
+* Tue Jan 30 2007 Christopher Aillon <caillon at redhat.com> 1.5.0.9-2
+- Fix the DND implementation to not grab, so it works with new GTK+.
+- Multilib -devel and -debuginfo fixes
+- Various pango fixes from behdad and tagoh
+- Some minor langpack fixes
+
 * Tue Dec 19 2006 Christopher Aillon <caillon at redhat.com> 1.5.0.9-1
 - Update to 1.5.0.9
 




More information about the fedora-cvs-commits mailing list