- apply upstream patch to fix the regression
- drop the kdelibs-4.1.1-bz#461725-regression.patch
This commit is contained in:
parent
26a0c05ef0
commit
0212771a65
@ -1,189 +0,0 @@
|
||||
Index: khtml/khtml_part.cpp
|
||||
===================================================================
|
||||
--- khtml/khtml_part.cpp (Revision 852920)
|
||||
+++ khtml/khtml_part.cpp (Revision 852919)
|
||||
@@ -1080,7 +1080,8 @@
|
||||
if ( !d->m_frame->m_jscript )
|
||||
if (!createJScript(d->m_frame))
|
||||
return 0;
|
||||
- d->m_frame->m_jscript->setDebugEnabled(d->m_bJScriptDebugEnabled);
|
||||
+ if (d->m_bJScriptDebugEnabled)
|
||||
+ d->m_frame->m_jscript->setDebugEnabled(true);
|
||||
|
||||
return d->m_frame->m_jscript;
|
||||
}
|
||||
Index: khtml/ecma/debugger/debugwindow.cpp
|
||||
===================================================================
|
||||
--- khtml/ecma/debugger/debugwindow.cpp (Revision 852920)
|
||||
+++ khtml/ecma/debugger/debugwindow.cpp (Revision 852919)
|
||||
@@ -91,12 +91,23 @@
|
||||
using namespace KJSDebugger;
|
||||
|
||||
DebugWindow* DebugWindow::s_debugger = 0;
|
||||
+DebugWindow *DebugWindow::createInstance()
|
||||
+{
|
||||
+ Q_ASSERT(!s_debugger);
|
||||
+ s_debugger = new DebugWindow();
|
||||
+ return s_debugger;
|
||||
+}
|
||||
|
||||
+void DebugWindow::destroyInstance()
|
||||
+{
|
||||
+ Q_ASSERT(s_debugger);
|
||||
+ Q_ASSERT(s_debugger->m_activeSessionCtxs.isEmpty());
|
||||
+ s_debugger->hide();
|
||||
+ delete s_debugger;
|
||||
+}
|
||||
+
|
||||
DebugWindow * DebugWindow::window()
|
||||
{
|
||||
- if (!s_debugger)
|
||||
- s_debugger = new DebugWindow();
|
||||
-
|
||||
return s_debugger;
|
||||
}
|
||||
|
||||
@@ -365,8 +376,6 @@
|
||||
assert(m_docsForIntrp.isEmpty());
|
||||
assert(m_docForSid.isEmpty());
|
||||
assert(m_docForIUKey.isEmpty());
|
||||
- assert(m_activeSessionCtxs.isEmpty());
|
||||
- s_debugger = 0;
|
||||
}
|
||||
|
||||
void DebugWindow::closeEvent(QCloseEvent* event)
|
||||
Index: khtml/ecma/debugger/debugwindow.h
|
||||
===================================================================
|
||||
--- khtml/ecma/debugger/debugwindow.h (Revision 852920)
|
||||
+++ khtml/ecma/debugger/debugwindow.h (Revision 852919)
|
||||
@@ -39,7 +39,6 @@
|
||||
#include "khtml_pagecache.h"
|
||||
#include "khtml_part.h"
|
||||
#include "dom/dom_misc.h"
|
||||
-#include "misc/shared.h"
|
||||
|
||||
#include <QStack>
|
||||
#include <QVector>
|
||||
@@ -72,8 +71,7 @@
|
||||
*
|
||||
* There is only one debug window per program. This can be obtained by calling #instance
|
||||
*/
|
||||
-class DebugWindow : public KXmlGuiWindow, public KJS::Debugger, public KComponentData,
|
||||
- public khtml::Shared<DebugWindow>
|
||||
+class DebugWindow : public KXmlGuiWindow, public KJS::Debugger, public KComponentData
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
@@ -81,6 +79,8 @@
|
||||
DebugWindow(QWidget *parent = 0);
|
||||
virtual ~DebugWindow();
|
||||
|
||||
+ static DebugWindow *createInstance();
|
||||
+ static void destroyInstance();
|
||||
static DebugWindow *window();
|
||||
|
||||
// Returns true if the debugger is active, and has blocked the execution
|
||||
Index: khtml/ecma/kjs_proxy.cpp
|
||||
===================================================================
|
||||
--- khtml/ecma/kjs_proxy.cpp (Revision 852920)
|
||||
+++ khtml/ecma/kjs_proxy.cpp (Revision 852919)
|
||||
@@ -66,9 +66,9 @@
|
||||
|
||||
void initScript();
|
||||
void applyUserAgent();
|
||||
+
|
||||
private:
|
||||
KJS::ScriptInterpreter* m_script;
|
||||
- WTF::RefPtr<DebugWindow> m_debugWindow;
|
||||
bool m_debugEnabled;
|
||||
#ifndef NDEBUG
|
||||
static int s_count;
|
||||
@@ -141,8 +141,8 @@
|
||||
#ifdef KJS_DEBUGGER
|
||||
if (inlineCode)
|
||||
filename = "(unknown file)";
|
||||
- if (m_debugWindow)
|
||||
- m_debugWindow->attach(m_script);
|
||||
+ if (DebugWindow::window())
|
||||
+ DebugWindow::window()->attach(m_script);
|
||||
#else
|
||||
Q_UNUSED(baseLine);
|
||||
#endif
|
||||
@@ -202,8 +202,9 @@
|
||||
// (we used to delete and re-create it, previously)
|
||||
if (m_script) {
|
||||
#ifdef KJS_DEBUGGER
|
||||
- if (m_debugWindow)
|
||||
- m_debugWindow->clearInterpreter(m_script);
|
||||
+ DebugWindow *debugWin = DebugWindow::window();
|
||||
+ if (debugWin)
|
||||
+ debugWin->clearInterpreter(m_script);
|
||||
#endif
|
||||
m_script->clear();
|
||||
|
||||
@@ -224,14 +225,6 @@
|
||||
;
|
||||
JSLock::unlock();
|
||||
}
|
||||
-
|
||||
-#ifdef KJS_DEBUGGER
|
||||
- // Detach from debugging entirely if it's been turned off.
|
||||
- if (m_debugWindow && !m_debugEnabled) {
|
||||
- m_debugWindow->detach(m_script);
|
||||
- m_debugWindow = 0;
|
||||
- }
|
||||
-#endif
|
||||
}
|
||||
|
||||
DOM::EventListener *KJSProxyImpl::createHTMLEventHandler(QString sourceUrl, QString name, QString code, DOM::NodeImpl *node)
|
||||
@@ -239,8 +232,8 @@
|
||||
initScript();
|
||||
|
||||
#ifdef KJS_DEBUGGER
|
||||
- if (m_debugWindow)
|
||||
- m_debugWindow->attach(m_script);
|
||||
+ if (DebugWindow::window())
|
||||
+ DebugWindow::window()->attach(m_script);
|
||||
#else
|
||||
Q_UNUSED(sourceUrl);
|
||||
#endif
|
||||
@@ -269,21 +262,30 @@
|
||||
{
|
||||
#ifdef KJS_DEBUGGER
|
||||
m_debugEnabled = enabled;
|
||||
-
|
||||
- // Note that we attach to the debugger only before
|
||||
- // running a script. Detaches/disabling are done between
|
||||
- // documents, at clear. Both are done so the debugger
|
||||
- // see the entire session
|
||||
- if (enabled)
|
||||
- m_debugWindow = DebugWindow::window();
|
||||
+ //if (m_script)
|
||||
+ // m_script->setDebuggingEnabled(enabled);
|
||||
+ // NOTE: this is consistent across all KJSProxyImpl instances, as we only
|
||||
+ // ever have 1 debug window
|
||||
+ if (!enabled && DebugWindow::window())
|
||||
+ {
|
||||
+ DebugWindow::destroyInstance();
|
||||
+ }
|
||||
+ else if (enabled && !DebugWindow::window())
|
||||
+ {
|
||||
+ DebugWindow::createInstance();
|
||||
+ initScript();
|
||||
+ DebugWindow::window()->attach(m_script);
|
||||
+ }
|
||||
+#else
|
||||
+ Q_UNUSED(enabled);
|
||||
#endif
|
||||
}
|
||||
|
||||
void KJSProxyImpl::showDebugWindow(bool /*show*/)
|
||||
{
|
||||
#ifdef KJS_DEBUGGER
|
||||
- if (m_debugWindow)
|
||||
- m_debugWindow->show();
|
||||
+ if (DebugWindow::window())
|
||||
+ DebugWindow::window()->show();
|
||||
#else
|
||||
//Q_UNUSED(show);
|
||||
#endif
|
13
kdelibs-4.1.1-kde#858795-mimeassoc.patch
Normal file
13
kdelibs-4.1.1-kde#858795-mimeassoc.patch
Normal file
@ -0,0 +1,13 @@
|
||||
Index: kded/kmimeassociations.cpp
|
||||
===================================================================
|
||||
--- kded/kmimeassociations.cpp (revision 858794)
|
||||
+++ kded/kmimeassociations.cpp (revision 858795)
|
||||
@@ -62,7 +62,7 @@
|
||||
const QString mimeappsFile = mimeappsIter.previous();
|
||||
kDebug(7021) << "Parsing" << mimeappsFile;
|
||||
parseMimeAppsList(mimeappsFile, basePreference);
|
||||
- basePreference -= 50;
|
||||
+ basePreference += 50;
|
||||
}
|
||||
return true;
|
||||
}
|
14
kdelibs-4.1.1-kde#860005-emoticons.patch
Normal file
14
kdelibs-4.1.1-kde#860005-emoticons.patch
Normal file
@ -0,0 +1,14 @@
|
||||
Index: kutils/kemoticons/kemoticonstheme.cpp
|
||||
===================================================================
|
||||
--- kutils/kemoticons/kemoticonstheme.cpp (revision 860004)
|
||||
+++ kutils/kemoticons/kemoticonstheme.cpp (revision 860005)
|
||||
@@ -161,6 +161,9 @@
|
||||
QString KEmoticonsTheme::parseEmoticons(const QString &text, ParseMode mode, const QStringList &exclude) const
|
||||
{
|
||||
QList<Token> tokens = tokenize(text, mode | SkipHTML);
|
||||
+ if (tokens.isEmpty() && !text.isEmpty())
|
||||
+ return text;
|
||||
+
|
||||
QString result;
|
||||
|
||||
foreach(const Token &token , tokens) {
|
24
kdelibs-4.1.1-kde#860095-khtml-scroll-crash.patch
Normal file
24
kdelibs-4.1.1-kde#860095-khtml-scroll-crash.patch
Normal file
@ -0,0 +1,24 @@
|
||||
Index: khtml/rendering/render_layer.cpp
|
||||
===================================================================
|
||||
--- khtml/rendering/render_layer.cpp (revision 860094)
|
||||
+++ khtml/rendering/render_layer.cpp (revision 860095)
|
||||
@@ -715,9 +715,6 @@
|
||||
for (RenderLayer* child = firstChild(); child; child = child->nextSibling())
|
||||
child->updateLayerPositions(rootLayer);
|
||||
|
||||
- // Fire the scroll DOM event.
|
||||
- m_object->element()->dispatchHTMLEvent(EventImpl::SCROLL_EVENT, true, false);
|
||||
-
|
||||
// Just schedule a full repaint of our object.
|
||||
if (repaint)
|
||||
m_object->repaint(RealtimePriority);
|
||||
@@ -728,6 +725,9 @@
|
||||
if (m_vBar)
|
||||
m_vBar->setValue(m_scrollY);
|
||||
}
|
||||
+
|
||||
+ // Fire the scroll DOM event. Do this the very last thing, since the handler may kill us.
|
||||
+ m_object->element()->dispatchHTMLEvent(EventImpl::SCROLL_EVENT, true, false);
|
||||
}
|
||||
|
||||
void RenderLayer::updateScrollPositionFromScrollbars()
|
@ -0,0 +1,69 @@
|
||||
Index: khtml/ecma/kjs_proxy.h
|
||||
===================================================================
|
||||
--- khtml/ecma/kjs_proxy.h (Revision 854182)
|
||||
+++ khtml/ecma/kjs_proxy.h (Revision 854183)
|
||||
@@ -62,6 +62,7 @@
|
||||
virtual KJS::Interpreter *interpreter() = 0;
|
||||
|
||||
virtual void setDebugEnabled(bool enabled) = 0;
|
||||
+ virtual bool debugEnabled() const = 0;
|
||||
virtual void showDebugWindow(bool show=true) = 0;
|
||||
virtual bool paused() const = 0;
|
||||
virtual void dataReceived() = 0;
|
||||
Index: khtml/ecma/kjs_events.cpp
|
||||
===================================================================
|
||||
--- khtml/ecma/kjs_events.cpp (Revision 854182)
|
||||
+++ khtml/ecma/kjs_events.cpp (Revision 854183)
|
||||
@@ -62,18 +62,18 @@
|
||||
|
||||
void JSEventListener::handleEvent(DOM::Event &evt)
|
||||
{
|
||||
-#ifdef KJS_DEBUGGER
|
||||
- //### This is the wrong place to do this --- we need
|
||||
- // a more global/general stategy to prevent unwanted event loop recursion issues.
|
||||
- if (DebugWindow::window() && DebugWindow::window()->inSession())
|
||||
- return;
|
||||
-#endif
|
||||
KHTMLPart *part = qobject_cast<KHTMLPart*>(static_cast<Window*>(win.get())->part());
|
||||
KJSProxy *proxy = 0L;
|
||||
if (part)
|
||||
proxy = part->jScript();
|
||||
|
||||
if (proxy && listener && listener->implementsCall()) {
|
||||
+#ifdef KJS_DEBUGGER
|
||||
+ //### This is the wrong place to do this --- we need
|
||||
+ // a more global/general stategy to prevent unwanted event loop recursion issues.
|
||||
+ if (proxy->debugEnabled() && DebugWindow::window()->inSession())
|
||||
+ return;
|
||||
+#endif
|
||||
ref();
|
||||
|
||||
KJS::ScriptInterpreter *interpreter = static_cast<KJS::ScriptInterpreter *>(proxy->interpreter());
|
||||
Index: khtml/ecma/kjs_proxy.cpp
|
||||
===================================================================
|
||||
--- khtml/ecma/kjs_proxy.cpp (Revision 854182)
|
||||
+++ khtml/ecma/kjs_proxy.cpp (Revision 854183)
|
||||
@@ -60,6 +60,7 @@
|
||||
virtual KJS::Interpreter *interpreter();
|
||||
|
||||
virtual void setDebugEnabled(bool enabled);
|
||||
+ virtual bool debugEnabled() const;
|
||||
virtual void showDebugWindow(bool show=true);
|
||||
virtual bool paused() const;
|
||||
virtual void dataReceived();
|
||||
@@ -279,6 +280,15 @@
|
||||
#endif
|
||||
}
|
||||
|
||||
+bool KJSProxyImpl::debugEnabled() const
|
||||
+{
|
||||
+#ifdef KJS_DEBUGGER
|
||||
+ return m_debugEnabled;
|
||||
+#else
|
||||
+ return false;
|
||||
+#endif
|
||||
+}
|
||||
+
|
||||
void KJSProxyImpl::showDebugWindow(bool /*show*/)
|
||||
{
|
||||
#ifdef KJS_DEBUGGER
|
24
kdelibs.spec
24
kdelibs.spec
@ -2,7 +2,7 @@
|
||||
|
||||
Summary: K Desktop Environment 4 - Libraries
|
||||
Version: 4.1.1
|
||||
Release: 9%{?dist}
|
||||
Release: 11%{?dist}
|
||||
|
||||
%if 0%{?fedora} > 8
|
||||
Name: kdelibs
|
||||
@ -78,7 +78,6 @@ Patch18: kdelibs-4.1.0-kstandarddirs.patch
|
||||
# fix running commands in kglobalconfig before KComponentData init (#455130)
|
||||
Patch19: kdelibs-4.1.0-#455130.patch
|
||||
Patch20: kdelibs-4.1.1-cmake.patch
|
||||
Patch21: kdelibs-4.1.1-bz#461725-regression.patch
|
||||
|
||||
## upstream patches
|
||||
Patch100: kdelibs-4.1.1-kde#169447-khtml-regression.patch
|
||||
@ -86,6 +85,10 @@ Patch101: kdelibs-4.1.1-kde#856379-cookiejar.patch
|
||||
Patch102: kdelibs-4.1.1-kde#856403-urlnav.patch
|
||||
Patch103: kdelibs-4.1.1-kutils-fixes.patch
|
||||
Patch104: kdelibs-4.1.1-kdeui-widgets-fixes.patch
|
||||
Patch105: kdelibs-4.1.1-kde#858795-mimeassoc.patch
|
||||
Patch106: kdelibs-4.1.1-kde#860095-khtml-scroll-crash.patch
|
||||
Patch107: kdelibs-4.1.1-kde#860005-emoticons.patch
|
||||
Patch108: kdelibs-4.1.1-kdelibs-4.1.1-kde#170461-khtml-regression.patch
|
||||
|
||||
BuildRequires: qt4-devel >= 4.4.0
|
||||
Requires: qt4 >= %{_qt4_version}
|
||||
@ -210,7 +213,6 @@ sed -i -e "s|@@VERSION_RELEASE@@|%{version}-%{release}|" kio/kio/kprotocolmanage
|
||||
%patch18 -p1 -b .kstandarddirs
|
||||
%patch19 -p1 -b .#455130
|
||||
%patch20 -p1 -b .cmake
|
||||
%patch21 -p0 -b .bz#461725-regression
|
||||
|
||||
## upstream patches
|
||||
%patch100 -p0 -b .kde#169447-khtml-regression
|
||||
@ -218,6 +220,10 @@ sed -i -e "s|@@VERSION_RELEASE@@|%{version}-%{release}|" kio/kio/kprotocolmanage
|
||||
%patch102 -p0 -b .kde#856403-urlnav
|
||||
%patch103 -p0 -b .kutils-fixes
|
||||
%patch104 -p0 -b .kdeui-widgets-fixes
|
||||
%patch105 -p0 -b .kde#858795-mimeassoc
|
||||
%patch106 -p0 -b .kde#860095-khtml-scroll-crash
|
||||
%patch107 -p0 -b .kde#860005-emoticons
|
||||
%patch108 -p0 -b .kde#170461-khtml-regression
|
||||
|
||||
%build
|
||||
|
||||
@ -378,6 +384,18 @@ rm -rf %{buildroot}
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Sep 18 2008 Than Ngo <than@redhat.com> 4.1.1-11
|
||||
- apply upstream patch to fix the regression
|
||||
- drop the kdelibs-4.1.1-bz#461725-regression.patch
|
||||
|
||||
* Thu Sep 18 2008 Lukáš Tinkl <ltinkl@redhat.com> 4.1.1-10
|
||||
- Fix file association bug, the global mimeapps.list file had priority
|
||||
over the local one.
|
||||
- khtml scroll crash fix (kdebug:170880)
|
||||
- Don't eat text when the emoticons were not installed. This fixes
|
||||
mail text not being displayed in KMail when kdebase-runtime wasn't
|
||||
installed.
|
||||
|
||||
* Wed Sep 17 2008 Than Ngo <than@redhat.com> 4.1.1-9
|
||||
- #461725, revert the patch to fix the regression
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user