We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit c93fdbaa authored by Sam Geeraerts's avatar Sam Geeraerts

Stop Konqueror (KDE4) from suggesting non-free plugins.

parent 97c6f5ea
......@@ -153,6 +153,7 @@ BOGOFILTER_VERSION=1
BLENDER_VERSION=1
MESA_VERSION=3
KDELIBS_VERSION=1
KDE4LIBS_VERSION=1
# PATHS
WORKINGDIR=$BASEDIR/tmp
......
......@@ -372,6 +372,7 @@ while [ $REDO -eq 1 ]; do # If versions in the config change, we could need to r
# KDE
ensure_updated kdebase kdebase $RELEASE$distro_release ./gen-kdebase $KDEBASE_VERSION
ensure_updated kdelibs kdelibs $RELEASE$distro_release ./gen-kdelibs $KDELIBS_VERSION
ensure_updated kde4libs kde4libs $RELEASE$distro_release ./gen-kde4libs $KDE4LIBS_VERSION
# ensure_updated kubuntu-default-settings k$DISTRONAME_L-default-settings $RELEASE$distro_release ./gen-kdefault-settings $KDEFAULT_SETTINGS_VERSION
# ensure_updated kubuntu-meta k$DISTRONAME_L-desktop $RELEASE$distro_release ./gen-kmeta $KMETA_VERSION
......
#!/bin/bash
#
# Copyright (C) 2006 Brian Brazil
# Copyright (C) 2013 Sam Geeraerts
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#
. config
IMGDIR=$PWD/images
rm -rf $WORKINGDIR
mkdir -p $WORKINGDIR
cd $WORKINGDIR
apt-get source kde4libs$VERSION
apt-get --yes build-dep kde4libs$VERSION
cd kde4libs-*
cp "$IMGDIR"/kde4libs_disable_missing_plugins.diff debian/patches/gns_disable_missing_plugins.diff
echo | dch -D $RELEASE -v $(sed -n '1s#^.*(\(.*\)).*#\1'${DISTRONAME_L}${KDE4LIBS_VERSION}'#p' debian/changelog) "Don't suggest downloading non-free plugins."
dpkg-buildpackage $DPKGOPTS
diff -Nur hardy/kde4libs-4.0.3//khtml/html/html_objectimpl.cpp gns1/kde4libs-4.0.3//khtml/html/html_objectimpl.cpp
--- a//khtml/html/html_objectimpl.cpp 2008-03-27 21:33:21.000000000 +0100
+++ b/khtml/html/html_objectimpl.cpp 2013-01-02 19:53:08.575294584 +0100
@@ -539,46 +539,6 @@
void HTMLObjectBaseElementImpl::slotPartLoadingErrorNotify()
{
- // If we have an embed, we may be able to tell the user where to
- // download the plugin.
-
- HTMLEmbedElementImpl *embed = relevantEmbed();
- QString serviceType; // shadows ours, but we don't care.
-
- if (!embed)
- return;
-
- serviceType = embed->serviceType;
-
- KHTMLPart* part = getDocument()->part();
- KParts::BrowserExtension *ext = part->browserExtension();
-
- if(!embed->pluginPage.isEmpty() && ext) {
- // Prepare the mimetype to show in the question (comment if available, name as fallback)
- QString mimeName = serviceType;
- KMimeType::Ptr mime = KMimeType::mimeType(serviceType);
- if ( mime && mime->name() != KMimeType::defaultMimeType() )
- mimeName = mime->comment();
-
- // Check if we already asked the user, for this page
- if (!mimeName.isEmpty() && !part->pluginPageQuestionAsked(serviceType))
- {
- part->setPluginPageQuestionAsked(serviceType);
-
- // Prepare the URL to show in the question (host only if http, to make it short)
- KUrl pluginPageURL(embed->pluginPage);
- QString shortURL = pluginPageURL.protocol() == "http" ? pluginPageURL.host() : pluginPageURL.prettyUrl();
- int res = KMessageBox::questionYesNo( part->view(),
- i18n("No plugin found for '%1'.\nDo you want to download one from %2?", mimeName, shortURL),
- i18n("Missing Plugin"), KGuiItem(i18n("Download")), KGuiItem(i18n("Do Not Download")), QString("plugin-")+serviceType);
- if (res == KMessageBox::Yes)
- {
- // Display vendor download page
- ext->createNewWindow(pluginPageURL);
- return;
- }
- }
- }
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment