rpms/arora/devel arora-0.10.1-trunk-qtwebkit.patch, NONE, 1.1 arora.spec, 1.25, 1.26
Jaroslav Reznik
jreznik at fedoraproject.org
Wed Nov 18 20:18:09 UTC 2009
Author: jreznik
Update of /cvs/pkgs/rpms/arora/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv20211
Modified Files:
arora.spec
Added Files:
arora-0.10.1-trunk-qtwebkit.patch
Log Message:
* Wed Nov 18 2009 Jaroslav Reznik <jreznik at redhat.com> - 0.10.1-4
- Build over latest qtwebkit trunk from qt 4.6-rc1
arora-0.10.1-trunk-qtwebkit.patch:
adblock/adblockpage.cpp | 2 +-
qwebplugins/clicktoflash/clicktoflash.cpp | 2 +-
tabwidget.cpp | 27 ++++++++++++++++++++-------
webpage.cpp | 2 +-
webview.cpp | 14 +++++++-------
5 files changed, 30 insertions(+), 17 deletions(-)
--- NEW FILE arora-0.10.1-trunk-qtwebkit.patch ---
diff -up arora-0.10.1/src/adblock/adblockpage.cpp.trunk-qtwebkit arora-0.10.1/src/adblock/adblockpage.cpp
--- arora-0.10.1/src/adblock/adblockpage.cpp.trunk-qtwebkit 2009-10-05 05:31:48.000000000 +0200
+++ arora-0.10.1/src/adblock/adblockpage.cpp 2009-11-18 17:38:10.876586573 +0100
@@ -85,7 +85,7 @@ void AdBlockPage::checkRule(const AdBloc
Q_UNUSED(page);
#if QT_VERSION >= 0x040600
QWebElement document = page->mainFrame()->documentElement();
- QList<QWebElement> elements = document.findAll(selectorQuery);
+ QWebElementCollection elements = document.findAll(selectorQuery);
#if defined(ADBLOCKPAGE_DEBUG)
if (elements.count() != 0)
qDebug() << "AdBlockPage::" << __FUNCTION__ << "blocking" << elements.count() << "items" << selectorQuery << elements.count() << "rule:" << rule->filter();
diff -up arora-0.10.1/src/qwebplugins/clicktoflash/clicktoflash.cpp.trunk-qtwebkit arora-0.10.1/src/qwebplugins/clicktoflash/clicktoflash.cpp
--- arora-0.10.1/src/qwebplugins/clicktoflash/clicktoflash.cpp.trunk-qtwebkit 2009-10-05 05:31:48.000000000 +0200
+++ arora-0.10.1/src/qwebplugins/clicktoflash/clicktoflash.cpp 2009-11-18 17:38:10.876586573 +0100
@@ -116,7 +116,7 @@ void ClickToFlash::load(bool loadAll)
QWebFrame *frame = frames.takeFirst();
QWebElement docElement = frame->documentElement();
- QList<QWebElement> elements;
+ QWebElementCollection elements;
elements.append(docElement.findAll(selector.arg(QLatin1String("object"))));
elements.append(docElement.findAll(selector.arg(QLatin1String("embed"))));
diff -up arora-0.10.1/src/tabwidget.cpp.trunk-qtwebkit arora-0.10.1/src/tabwidget.cpp
--- arora-0.10.1/src/tabwidget.cpp.trunk-qtwebkit 2009-10-05 05:31:48.000000000 +0200
+++ arora-0.10.1/src/tabwidget.cpp 2009-11-18 17:38:10.877706037 +0100
@@ -618,7 +618,10 @@ void TabWidget::closeTab(int index)
m_recentlyClosedTabsAction->setEnabled(true);
m_recentlyClosedTabs.prepend(tab->url());
#if QT_VERSION >= 0x040600
- m_recentlyClosedTabsHistory.prepend(tab->history()->saveState());
+ QByteArray tabHistory;
+ QDataStream tabHistoryStream(&tabHistory, QIODevice::WriteOnly);
+ tabHistoryStream << tab->history();
+ m_recentlyClosedTabsHistory.prepend(tabHistory);
#else
m_recentlyClosedTabsHistory.prepend(QByteArray());
#endif
@@ -859,7 +862,11 @@ QUrl TabWidget::guessUrlFromString(const
if (url.isValid())
return url;
+#if QT_VERSION >= 0x040600
+ url = QUrl::fromUserInput(string);
+#else
url = WebView::guessUrlFromString(string);
+#endif
if (url.scheme() == QLatin1String("about")
&& url.path() == QLatin1String("home"))
@@ -1066,10 +1073,14 @@ QByteArray TabWidget::saveState() const
if (WebView *tab = webView(i)) {
tabs.append(QString::fromUtf8(tab->url().toEncoded()));
#if QT_VERSION >= 0x040600
- if (tab->history()->count() != 0)
- tabsHistory.append(tab->history()->saveState());
- else
- tabsHistory.append(QByteArray());
+ if (tab->history()->count() != 0) {
+ QByteArray tabHistory;
+ QDataStream tabHistoryStream(&tabHistory, QIODevice::WriteOnly);
+ tabHistoryStream << tab->history();
+ tabsHistory.append(tabHistory);
+ } else {
+ tabsHistory << QByteArray();
+ }
#else
tabsHistory.append(QByteArray());
#endif
@@ -1131,8 +1142,10 @@ bool TabWidget::restoreState(const QByte
void TabWidget::createTab(const QByteArray &historyState, TabWidget::OpenUrlIn tab)
{
#if QT_VERSION >= 0x040600
- if (WebView *webView = getView(tab, currentWebView()))
- webView->history()->restoreState(historyState);
+ if (WebView *webView = getView(tab, currentWebView())) {
+ QDataStream historyStream(historyState);
+ historyStream >> *webView->history();
+ }
#else
qWarning() << "Warning: TabWidget::createTab should not be called, but it is...";
Q_UNUSED(historyState);
diff -up arora-0.10.1/src/webpage.cpp.trunk-qtwebkit arora-0.10.1/src/webpage.cpp
--- arora-0.10.1/src/webpage.cpp.trunk-qtwebkit 2009-10-05 05:31:48.000000000 +0200
+++ arora-0.10.1/src/webpage.cpp 2009-11-18 17:38:10.878705942 +0100
@@ -128,7 +128,7 @@ QList<WebPageLinkedResource> WebPage::li
#if QT_VERSION >= 0x040600 || defined(WEBKIT_TRUNK)
QUrl baseUrl = mainFrame()->baseUrl();
- QList<QWebElement> linkElements = mainFrame()->findAllElements(QLatin1String("html > head > link"));
+ QWebElementCollection linkElements = mainFrame()->findAllElements(QLatin1String("html > head > link"));
foreach (const QWebElement &linkElement, linkElements) {
QString rel = linkElement.attribute(QLatin1String("rel"));
diff -up arora-0.10.1/src/webview.cpp.trunk-qtwebkit arora-0.10.1/src/webview.cpp
--- arora-0.10.1/src/webview.cpp.trunk-qtwebkit 2009-10-05 05:31:48.000000000 +0200
+++ arora-0.10.1/src/webview.cpp 2009-11-18 17:38:10.879705998 +0100
@@ -439,7 +439,7 @@ void WebView::addSearchEngine()
QUrl searchUrl(page()->mainFrame()->baseUrl().resolved(QUrl(formElement.attribute(QLatin1String("action")))));
QMap<QString, QString> searchEngines;
- QList<QWebElement> inputFields = formElement.findAll(QLatin1String("input"));
+ QWebElementCollection inputFields = formElement.findAll(QLatin1String("input"));
foreach (QWebElement inputField, inputFields) {
QString type = inputField.attribute(QLatin1String("type"), QLatin1String("text"));
QString name = inputField.attribute(QLatin1String("name"));
@@ -461,14 +461,14 @@ void WebView::addSearchEngine()
}
}
- QList<QWebElement> selectFields = formElement.findAll(QLatin1String("select"));
+ QWebElementCollection selectFields = formElement.findAll(QLatin1String("select"));
foreach (QWebElement selectField, selectFields) {
QString name = selectField.attribute(QLatin1String("name"));
int selectedIndex = selectField.evaluateJavaScript(QLatin1String("this.selectedIndex")).toInt();
if (selectedIndex == -1)
continue;
- QList<QWebElement> options = selectField.findAll(QLatin1String("option"));
+ QWebElementCollection options = selectField.findAll(QLatin1String("option"));
QString value = options.at(selectedIndex).toPlainText();
searchUrl.addQueryItem(name, value);
}
@@ -485,8 +485,8 @@ void WebView::addSearchEngine()
}
QString engineName;
- QList<QWebElement> labels = formElement.findAll(QString(QLatin1String("label[for=\"%1\"]")).arg(elementName));
- if (!labels.isEmpty())
+ QWebElementCollection labels = formElement.findAll(QString(QLatin1String("label[for=\"%1\"]")).arg(elementName));
+ if (labels.count() > 0)
engineName = labels.at(0).toPlainText();
engineName = QInputDialog::getText(this, tr("Engine name"), tr("Type in a name for the engine"),
@@ -824,7 +824,7 @@ void WebView::showAccessKeys()
// Priority first goes to elements with accesskey attributes
QList<QWebElement> alreadyLabeled;
foreach (const QString &elementType, supportedElement) {
- QList<QWebElement> result = page()->mainFrame()->findAllElements(elementType);
+ QList<QWebElement> result = page()->mainFrame()->findAllElements(elementType).toList();
foreach (const QWebElement &element, result) {
const QRect geometry = element.geometry();
if (geometry.size().isEmpty()
@@ -853,7 +853,7 @@ void WebView::showAccessKeys()
// Pick an access key first from the letters in the text and then from the
// list of unused access keys
foreach (const QString &elementType, supportedElement) {
- QList<QWebElement> result = page()->mainFrame()->findAllElements(elementType);
+ QWebElementCollection result = page()->mainFrame()->findAllElements(elementType);
foreach (const QWebElement &element, result) {
const QRect geometry = element.geometry();
if (unusedKeys.isEmpty()
Index: arora.spec
===================================================================
RCS file: /cvs/pkgs/rpms/arora/devel/arora.spec,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -p -r1.25 -r1.26
--- arora.spec 18 Nov 2009 15:27:26 -0000 1.25
+++ arora.spec 18 Nov 2009 20:18:08 -0000 1.26
@@ -1,6 +1,6 @@
Name: arora
Version: 0.10.1
-Release: 3%{?dist}
+Release: 4%{?dist}
Summary: A cross platform web browser
Group: Applications/Internet
@@ -10,6 +10,7 @@ Source0: http://arora.googlecode.
Patch0: arora-0.10.1-gitversion.patch
Patch1: arora-0.10.0-fedorabookmarks.patch
Patch2: arora-0.10.0-fedorahome.patch
+Patch3: arora-0.10.1-trunk-qtwebkit.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: desktop-file-utils
@@ -40,6 +41,7 @@ Adds Arora to Preferred Applications lis
%patch0 -p1 -b .gitversion
%patch1 -p1 -b .fedorabookmarks
%patch2 -p1 -b .fedorahome
+%patch3 -p1 -b .trunk-webkit
%build
qmake-qt4 PREFIX=%{_prefix}
@@ -99,6 +101,9 @@ gtk-update-icon-cache %{_datadir}/icons/
%changelog
+* Wed Nov 18 2009 Jaroslav Reznik <jreznik at redhat.com> - 0.10.1-4
+- Build over latest qtwebkit trunk from qt 4.6-rc1
+
* Wed Nov 18 2009 Rex Dieter <rdieter at fedoraproject.org> - 0.10.1-3
- respin against newer qt
More information about the fedora-extras-commits
mailing list