rpms/blam/devel blam-1.8.7-webkit.patch,NONE,1.1 blam.spec,1.42,1.43

alexlan alexlan at fedoraproject.org
Sun Jun 6 23:56:31 UTC 2010


Author: alexlan

Update of /cvs/pkgs/rpms/blam/devel
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv31864

Modified Files:
	blam.spec 
Added Files:
	blam-1.8.7-webkit.patch 
Log Message:
- Backport patch from git upstream to fix webkit issues (#575583)


blam-1.8.7-webkit.patch:
 src/ItemView.cs          |   13 +++++++++++--
 themes/blam/theme.html   |    2 +-
 themes/pimped/theme.html |    3 +--
 themes/planet/theme.html |    3 +--
 4 files changed, 14 insertions(+), 7 deletions(-)

--- NEW FILE blam-1.8.7-webkit.patch ---
>From 4a5c831d181661640c3421685997da1349c36946 Mon Sep 17 00:00:00 2001
From: Carlos Martín Nieto <carlos at cmartin.tk>
Date: Wed, 11 Nov 2009 14:43:11 +0000
Subject: Adapt to some new WebKit changes

---
diff --git a/src/ItemView.cs b/src/ItemView.cs
index a7b007a..8097f64 100644
--- a/src/ItemView.cs
+++ b/src/ItemView.cs
@@ -25,6 +25,7 @@ namespace Imendio.Blam {
         private WebSettings webSettings;
 #endif
 	private Imendio.Blam.Item currentItem;
+    private string baseDir = null;
 
 	public bool PageLoaded;
 
@@ -67,7 +68,13 @@ namespace Imendio.Blam {
 
 		webView.NavigationRequested += delegate (object sender, NavigationRequestedArgs args) {
         try {
+            /* Allow our local files to be downloaded. Needed to load the theme */
+            if(args.Request.Uri.StartsWith(baseDir)){
+                    args.RetVal = NavigationResponse.Accept;
+                    return;
+            }
             Gnome.Url.Show(args.Request.Uri);
+                    args.RetVal = NavigationResponse.Ignore;
         }
         catch (Exception e) {
             Console.Error.WriteLine("Couldn't show URL: " + args.Request.Uri + e.Message);
@@ -119,6 +126,7 @@ namespace Imendio.Blam {
             string text    = HtmlUtils.EncodeUnicode(HtmlUtils.FixMarkup(currentItem.Text));
             string title   = HtmlUtils.Escape(currentItem.Title);
             string url     = currentItem.Link;
+            baseDir        = "file://" + theme.Path;
 
             string[] replaces = {
                 "author", author,
@@ -126,10 +134,11 @@ namespace Imendio.Blam {
                 "pubdate", pubdate,
                 "text", text,
                 "title", title,
-                "url", url
+                "url", url,
+                "localbase", baseDir
             };
 
-						webView.LoadString (theme.Render(replaces), "text/html", "utf8", "file://" + theme.Path + "/");
+			webView.LoadString(theme.Render(replaces), null, null, baseDir);
 	}
 
         private void SetFonts ()
diff --git a/themes/blam/theme.html b/themes/blam/theme.html
index 2a41912..2dbc50f 100644
--- a/themes/blam/theme.html
+++ b/themes/blam/theme.html
@@ -1,7 +1,7 @@
 <html>
   <head>
     <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
-	<link rel="stylesheet" href="blam.css" type="text/css">
+	<link rel="stylesheet" href="${localbase}/blam.css" type="text/css">
     <title>${title}</title>
     <base href="${url}" />
   </head>
diff --git a/themes/pimped/theme.html b/themes/pimped/theme.html
index 4e5e29a..681bdad 100644
--- a/themes/pimped/theme.html
+++ b/themes/pimped/theme.html
@@ -1,12 +1,11 @@
 <html>
   <head>
     <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
-    <link rel="stylesheet" href="pimped.css" type="text/css">
     <title>${title}</title>
+    <link rel="stylesheet" href="${localbase}/pimped.css" type="text/css">
     <base href="${url}" />
   </head>
   <body>
-
     <div id="body">
       ${text}
     </div>
diff --git a/themes/planet/theme.html b/themes/planet/theme.html
index bf936f8..849e6da 100644
--- a/themes/planet/theme.html
+++ b/themes/planet/theme.html
@@ -2,7 +2,7 @@
 <html>
 <head>
     <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
-    <link rel="stylesheet" href="planet.css" type="text/css">
+    <link rel="stylesheet" href="${localbase}/planet.css" type="text/css">
     <base href="${url}" />
 </head>
 <body>
--
cgit v0.8.3.1


Index: blam.spec
===================================================================
RCS file: /cvs/pkgs/rpms/blam/devel/blam.spec,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -p -r1.42 -r1.43
--- blam.spec	31 Mar 2010 00:21:18 -0000	1.42
+++ blam.spec	6 Jun 2010 23:56:31 -0000	1.43
@@ -7,7 +7,7 @@
 
 Name:		blam
 Version:	1.8.7
-Release:	2%{?dist}
+Release:	3%{?dist}
 Summary:	An RSS/RDF feed reader
 
 Group:		Applications/Internet
@@ -15,6 +15,7 @@ License:	GPLv2+
 URL:		http://www.cmartin.tk/blam.html
 
 Source0:	http://www.cmartin.tk/blam/%{name}-%{version}.tar.bz2
+Patch0:		blam-1.8.7-webkit.patch
 
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 ## Various Mono dependencies are not available for ppc64; see bug 241850.
@@ -57,6 +58,7 @@ use and clean interface to stay up to da
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 export CFLAGS="%{optflags} -debug"
@@ -119,6 +121,9 @@ update-desktop-database &> /dev/null ||:
 %{_mandir}/man?/%{name}.1*
 
 %changelog
+* Sun Jun  6 2010 Alex Lancaster <alexlan[AT]fedoraproject org> - 1.8.7-3
+- Backport patch from git upstream to fix webkit issues (#575583)
+
 * Thu Mar 25 2010 Alex Lancaster <alexlan[AT]fedoraproject org> - 1.8.7-2
 - Add missing Requires: webkit-sharp and BR: ndesk-dbus-glib-devel
 



More information about the scm-commits mailing list