mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 18:56:34 +01:00
Coding style: Use empty QString() constructor instead of "" everywhere
This commit is contained in:
parent
0437ae171f
commit
b2181f0bab
2
src/lib/3rdparty/ecwin7.cpp
vendored
2
src/lib/3rdparty/ecwin7.cpp
vendored
@ -75,7 +75,7 @@ void EcWin7::setOverlayIcon(QString iconName, QString description)
|
|||||||
if (mOverlayIcon != NULL) {
|
if (mOverlayIcon != NULL) {
|
||||||
oldIcon = mOverlayIcon;
|
oldIcon = mOverlayIcon;
|
||||||
}
|
}
|
||||||
if (iconName == "") {
|
if (iconName.isEmpty()) {
|
||||||
mTaskbar->SetOverlayIcon(mWindowId, NULL, NULL);
|
mTaskbar->SetOverlayIcon(mWindowId, NULL, NULL);
|
||||||
mOverlayIcon = NULL;
|
mOverlayIcon = NULL;
|
||||||
}
|
}
|
||||||
|
2
src/lib/3rdparty/qtsingleapplication.cpp
vendored
2
src/lib/3rdparty/qtsingleapplication.cpp
vendored
@ -295,7 +295,7 @@ bool QtSingleApplication::sendMessage(const QString &message, int timeout)
|
|||||||
*/
|
*/
|
||||||
QString QtSingleApplication::id() const
|
QString QtSingleApplication::id() const
|
||||||
{
|
{
|
||||||
return (peer ? peer->applicationId() : "");
|
return (peer ? peer->applicationId() : QString());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -481,8 +481,8 @@ void AdBlockRule::parseFilter()
|
|||||||
if (parsedLine.contains('*') || parsedLine.contains('^') || parsedLine.contains('|')) {
|
if (parsedLine.contains('*') || parsedLine.contains('^') || parsedLine.contains('|')) {
|
||||||
parsedLine.replace(QRegExp(QLatin1String("\\*+")), QLatin1String("*")) // remove multiple wildcards
|
parsedLine.replace(QRegExp(QLatin1String("\\*+")), QLatin1String("*")) // remove multiple wildcards
|
||||||
.replace(QRegExp(QLatin1String("\\^\\|$")), QLatin1String("^")) // remove anchors following separator placeholder
|
.replace(QRegExp(QLatin1String("\\^\\|$")), QLatin1String("^")) // remove anchors following separator placeholder
|
||||||
.replace(QRegExp(QLatin1String("^(\\*)")), QLatin1String("")) // remove leading wildcards
|
.replace(QRegExp(QLatin1String("^(\\*)")), QString()) // remove leading wildcards
|
||||||
.replace(QRegExp(QLatin1String("(\\*)$")), QLatin1String(""))
|
.replace(QRegExp(QLatin1String("(\\*)$")), QString())
|
||||||
.replace(QRegExp(QLatin1String("(\\W)")), QLatin1String("\\\\1")) // escape special symbols
|
.replace(QRegExp(QLatin1String("(\\W)")), QLatin1String("\\\\1")) // escape special symbols
|
||||||
.replace(QRegExp(QLatin1String("^\\\\\\|\\\\\\|")),
|
.replace(QRegExp(QLatin1String("^\\\\\\|\\\\\\|")),
|
||||||
QLatin1String("^[\\w\\-]+:\\/+(?!\\/)(?:[^\\/]+\\.)?")) // process extended anchor at expression start
|
QLatin1String("^[\\w\\-]+:\\/+(?!\\/)(?:[^\\/]+\\.)?")) // process extended anchor at expression start
|
||||||
|
@ -372,7 +372,7 @@ void MainApplication::loadSettings()
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
setWheelScrollLines(settings.value("wheelScrollLines", wheelScrollLines()).toInt());
|
setWheelScrollLines(settings.value("wheelScrollLines", wheelScrollLines()).toInt());
|
||||||
m_websettings->setUserStyleSheetUrl(userStyleSheet(settings.value("userStyleSheet", "").toString()));
|
m_websettings->setUserStyleSheetUrl(userStyleSheet(settings.value("userStyleSheet", QString()).toString()));
|
||||||
settings.endGroup();
|
settings.endGroup();
|
||||||
|
|
||||||
settings.beginGroup("Browser-Fonts");
|
settings.beginGroup("Browser-Fonts");
|
||||||
@ -803,7 +803,7 @@ void MainApplication::reloadUserStyleSheet()
|
|||||||
{
|
{
|
||||||
Settings settings;
|
Settings settings;
|
||||||
settings.beginGroup("Web-Browser-Settings");
|
settings.beginGroup("Web-Browser-Settings");
|
||||||
m_websettings->setUserStyleSheetUrl(userStyleSheet(settings.value("userStyleSheet", "").toString()));
|
m_websettings->setUserStyleSheetUrl(userStyleSheet(settings.value("userStyleSheet", QString()).toString()));
|
||||||
settings.endGroup();
|
settings.endGroup();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -145,7 +145,7 @@ void QupZilla::postLaunch()
|
|||||||
|
|
||||||
switch (afterLaunch) {
|
switch (afterLaunch) {
|
||||||
case 0:
|
case 0:
|
||||||
startUrl = QUrl("");
|
startUrl = QUrl();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 2:
|
case 2:
|
||||||
|
@ -117,7 +117,7 @@ public slots:
|
|||||||
|
|
||||||
void bookmarkPage();
|
void bookmarkPage();
|
||||||
void loadAddress(const QUrl &url);
|
void loadAddress(const QUrl &url);
|
||||||
void showSource(QWebFrame* frame = 0, const QString &selectedHtml = "");
|
void showSource(QWebFrame* frame = 0, const QString &selectedHtml = QString());
|
||||||
void printPage(QWebFrame* frame = 0);
|
void printPage(QWebFrame* frame = 0);
|
||||||
void showPageInfo();
|
void showPageInfo();
|
||||||
void receiveMessage(Qz::AppMessageType mes, bool state);
|
void receiveMessage(Qz::AppMessageType mes, bool state);
|
||||||
|
@ -238,7 +238,7 @@ void AutoFillModel::completePage(WebPage* page)
|
|||||||
for (int i = 0; i < inputs.count(); i++) {
|
for (int i = 0; i < inputs.count(); i++) {
|
||||||
QWebElement element = inputs.at(i);
|
QWebElement element = inputs.at(i);
|
||||||
|
|
||||||
if (element.attribute("type") != "text" && element.attribute("type") != "password" && element.attribute("type") != "") {
|
if (element.attribute("type") != "text" && element.attribute("type") != "password" && !element.attribute("type").isEmpty()) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -16,9 +16,6 @@
|
|||||||
<verstretch>0</verstretch>
|
<verstretch>0</verstretch>
|
||||||
</sizepolicy>
|
</sizepolicy>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true">Form</string>
|
|
||||||
</property>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
<number>3</number>
|
<number>3</number>
|
||||||
|
@ -181,7 +181,7 @@ void BookmarksManager::itemChanged(QTreeWidgetItem* item)
|
|||||||
int id = item->data(0, Qt::UserRole + 10).toInt();
|
int id = item->data(0, Qt::UserRole + 10).toInt();
|
||||||
|
|
||||||
ui->bookmarksTree->deleteItem(item);
|
ui->bookmarksTree->deleteItem(item);
|
||||||
m_bookmarksModel->editBookmark(id, name, url, "");
|
m_bookmarksModel->editBookmark(id, name, url, QString());
|
||||||
}
|
}
|
||||||
|
|
||||||
void BookmarksManager::itemControlClicked(QTreeWidgetItem* item)
|
void BookmarksManager::itemControlClicked(QTreeWidgetItem* item)
|
||||||
|
@ -85,7 +85,7 @@ public:
|
|||||||
void removeBookmark(int id);
|
void removeBookmark(int id);
|
||||||
void removeBookmark(const QList<int> list);
|
void removeBookmark(const QList<int> list);
|
||||||
|
|
||||||
bool editBookmark(int id, const QString &title = "", const QUrl &url = QUrl(), const QString &folder = "");
|
bool editBookmark(int id, const QString &title = QString(), const QUrl &url = QUrl(), const QString &folder = QString());
|
||||||
bool changeIcon(int id, const QIcon &icon);
|
bool changeIcon(int id, const QIcon &icon);
|
||||||
|
|
||||||
bool createFolder(const QString &name);
|
bool createFolder(const QString &name);
|
||||||
|
@ -10,9 +10,6 @@
|
|||||||
<height>74</height>
|
<height>74</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
<property name="margin">
|
<property name="margin">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
|
@ -115,7 +115,7 @@ void DesktopNotificationsFactory::nativeNotificationPreview()
|
|||||||
args.append(m_uint);
|
args.append(m_uint);
|
||||||
args.append(tmp.fileName());
|
args.append(tmp.fileName());
|
||||||
args.append(QObject::tr("Native System Notification"));
|
args.append(QObject::tr("Native System Notification"));
|
||||||
args.append("");
|
args.append(QString());
|
||||||
args.append(QStringList());
|
args.append(QStringList());
|
||||||
args.append(QVariantMap());
|
args.append(QVariantMap());
|
||||||
args.append(m_timeout);
|
args.append(m_timeout);
|
||||||
|
@ -10,9 +10,6 @@
|
|||||||
<height>73</height>
|
<height>73</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<property name="topMargin">
|
<property name="topMargin">
|
||||||
<number>2</number>
|
<number>2</number>
|
||||||
@ -73,9 +70,6 @@
|
|||||||
<property name="textVisible">
|
<property name="textVisible">
|
||||||
<bool>false</bool>
|
<bool>false</bool>
|
||||||
</property>
|
</property>
|
||||||
<property name="format">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
|
@ -67,14 +67,14 @@ void DownloadManager::loadSettings()
|
|||||||
{
|
{
|
||||||
Settings settings;
|
Settings settings;
|
||||||
settings.beginGroup("DownloadManager");
|
settings.beginGroup("DownloadManager");
|
||||||
m_downloadPath = settings.value("defaultDownloadPath", "").toString();
|
m_downloadPath = settings.value("defaultDownloadPath", QString()).toString();
|
||||||
m_lastDownloadPath = settings.value("lastDownloadPath", QDir::homePath().append("/")).toString();
|
m_lastDownloadPath = settings.value("lastDownloadPath", QDir::homePath().append("/")).toString();
|
||||||
m_closeOnFinish = settings.value("CloseManagerOnFinish", false).toBool();
|
m_closeOnFinish = settings.value("CloseManagerOnFinish", false).toBool();
|
||||||
m_useNativeDialog = settings.value("useNativeDialog", DEFAULT_DOWNLOAD_USE_NATIVE_DIALOG).toBool();
|
m_useNativeDialog = settings.value("useNativeDialog", DEFAULT_DOWNLOAD_USE_NATIVE_DIALOG).toBool();
|
||||||
|
|
||||||
m_useExternalManager = settings.value("UseExternalManager", false).toBool();
|
m_useExternalManager = settings.value("UseExternalManager", false).toBool();
|
||||||
m_externalExecutable = settings.value("ExternalManagerExecutable", "").toString();
|
m_externalExecutable = settings.value("ExternalManagerExecutable", QString()).toString();
|
||||||
m_externalArguments = settings.value("ExternalManagerArguments", "").toString();
|
m_externalArguments = settings.value("ExternalManagerArguments", QString()).toString();
|
||||||
settings.endGroup();
|
settings.endGroup();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -112,9 +112,11 @@ void LocationCompleterDelegate::paint(QPainter* painter, const QStyleOptionViewI
|
|||||||
|
|
||||||
drawHighlightedTextLine(linkRect, link, searchText, painter, style, opt, colorLinkRole);
|
drawHighlightedTextLine(linkRect, link, searchText, painter, style, opt, colorLinkRole);
|
||||||
|
|
||||||
// Draw line at the very bottom of item
|
// Draw line at the very bottom of item if the item is not highlighted
|
||||||
QRect lineRect(opt.rect.left(), opt.rect.bottom(), opt.rect.width(), 1);
|
if (!(opt.state & QStyle::State_Selected)) {
|
||||||
painter->fillRect(lineRect, opt.palette.color(QPalette::AlternateBase));
|
QRect lineRect(opt.rect.left(), opt.rect.bottom(), opt.rect.width(), 1);
|
||||||
|
painter->fillRect(lineRect, opt.palette.color(QPalette::AlternateBase));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool sizeBiggerThan(const QString &s1, const QString &s2)
|
bool sizeBiggerThan(const QString &s1, const QString &s2)
|
||||||
|
@ -33,15 +33,15 @@ void NetworkProxyFactory::loadSettings()
|
|||||||
m_proxyType = QNetworkProxy::ProxyType(settings.value("ProxyType", QNetworkProxy::HttpProxy).toInt());
|
m_proxyType = QNetworkProxy::ProxyType(settings.value("ProxyType", QNetworkProxy::HttpProxy).toInt());
|
||||||
m_useDifferentProxyForHttps = settings.value("UseDifferentProxyForHttps", false).toBool();
|
m_useDifferentProxyForHttps = settings.value("UseDifferentProxyForHttps", false).toBool();
|
||||||
|
|
||||||
m_hostName = settings.value("HostName", "").toString();
|
m_hostName = settings.value("HostName", QString()).toString();
|
||||||
m_port = settings.value("Port", 8080).toInt();
|
m_port = settings.value("Port", 8080).toInt();
|
||||||
m_username = settings.value("Username", "").toString();
|
m_username = settings.value("Username", QString()).toString();
|
||||||
m_password = settings.value("Password", "").toString();
|
m_password = settings.value("Password", QString()).toString();
|
||||||
|
|
||||||
m_httpsHostName = settings.value("HttpsHostName", "").toString();
|
m_httpsHostName = settings.value("HttpsHostName", QString()).toString();
|
||||||
m_httpsPort = settings.value("HttpsPort", 8080).toInt();
|
m_httpsPort = settings.value("HttpsPort", 8080).toInt();
|
||||||
m_httpsUsername = settings.value("HttpsUsername", "").toString();
|
m_httpsUsername = settings.value("HttpsUsername", QString()).toString();
|
||||||
m_httpsPassword = settings.value("HttpsPassword", "").toString();
|
m_httpsPassword = settings.value("HttpsPassword", QString()).toString();
|
||||||
|
|
||||||
m_proxyExceptions = settings.value("ProxyExceptions", QStringList() << "localhost" << "127.0.0.1").toStringList();
|
m_proxyExceptions = settings.value("ProxyExceptions", QStringList() << "localhost" << "127.0.0.1").toStringList();
|
||||||
settings.endGroup();
|
settings.endGroup();
|
||||||
|
@ -188,7 +188,7 @@ QString FileSchemeReply::loadDirectory()
|
|||||||
line += "\">";
|
line += "\">";
|
||||||
line += info.fileName();
|
line += info.fileName();
|
||||||
line += "</a></td><td class=\"td-size\">";
|
line += "</a></td><td class=\"td-size\">";
|
||||||
line += info.isDir() ? "" : qz_fileSizeToString(info.size());
|
line += info.isDir() ? QString() : qz_fileSizeToString(info.size());
|
||||||
line += "</td><td>";
|
line += "</td><td>";
|
||||||
line += info.lastModified().toString("dd.MM.yyyy");
|
line += info.lastModified().toString("dd.MM.yyyy");
|
||||||
line += "</td><td>";
|
line += "</td><td>";
|
||||||
|
@ -176,7 +176,7 @@ QString QupZillaSchemeReply::startPage()
|
|||||||
sPage.replace("%SEARCH-BY%", tr("Search results provided by DuckDuckGo"));
|
sPage.replace("%SEARCH-BY%", tr("Search results provided by DuckDuckGo"));
|
||||||
sPage.replace("%WWW%", QupZilla::WIKIADDRESS);
|
sPage.replace("%WWW%", QupZilla::WIKIADDRESS);
|
||||||
sPage.replace("%ABOUT-QUPZILLA%", tr("About QupZilla"));
|
sPage.replace("%ABOUT-QUPZILLA%", tr("About QupZilla"));
|
||||||
sPage.replace("%PRIVATE-BROWSING%", mApp->isPrivateSession() ? tr("<h1>Private Browsing</h1>") : "");
|
sPage.replace("%PRIVATE-BROWSING%", mApp->isPrivateSession() ? tr("<h1>Private Browsing</h1>") : QString());
|
||||||
sPage = qz_applyDirectionToPage(sPage);
|
sPage = qz_applyDirectionToPage(sPage);
|
||||||
|
|
||||||
return sPage;
|
return sPage;
|
||||||
|
@ -264,7 +264,7 @@ void SearchEnginesManager::addEngine(OpenSearchEngine* engine)
|
|||||||
en.name = engine->name();
|
en.name = engine->name();
|
||||||
en.url = engine->searchUrl("searchstring").toString().replace("searchstring", "%s");
|
en.url = engine->searchUrl("searchstring").toString().replace("searchstring", "%s");
|
||||||
if (engine->image().isNull()) {
|
if (engine->image().isNull()) {
|
||||||
en.icon = iconForSearchEngine(engine->searchUrl(""));
|
en.icon = iconForSearchEngine(engine->searchUrl(QString()));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
en.icon = QIcon(QPixmap::fromImage(engine->image()));
|
en.icon = QIcon(QPixmap::fromImage(engine->image()));
|
||||||
|
@ -138,7 +138,7 @@ void StatusBarMessage::showMessage(const QString &message)
|
|||||||
void StatusBarMessage::clearMessage()
|
void StatusBarMessage::clearMessage()
|
||||||
{
|
{
|
||||||
if (p_QupZilla->statusBar()->isVisible()) {
|
if (p_QupZilla->statusBar()->isVisible()) {
|
||||||
p_QupZilla->statusBar()->showMessage("");
|
p_QupZilla->statusBar()->showMessage(QString());
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
m_statusBarText->hideDelayed();
|
m_statusBarText->hideDelayed();
|
||||||
|
@ -45,8 +45,8 @@ void SpeedDial::loadSettings()
|
|||||||
|
|
||||||
Settings settings;
|
Settings settings;
|
||||||
settings.beginGroup("SpeedDial");
|
settings.beginGroup("SpeedDial");
|
||||||
QString allPages = settings.value("pages", "").toString();
|
QString allPages = settings.value("pages", QString()).toString();
|
||||||
m_backgroundImage = settings.value("background", "").toString();
|
m_backgroundImage = settings.value("background", QString()).toString();
|
||||||
m_backgroundImageSize = settings.value("backsize", "auto").toString();
|
m_backgroundImageSize = settings.value("backsize", "auto").toString();
|
||||||
m_maxPagesInRow = settings.value("pagesrow", 4).toInt();
|
m_maxPagesInRow = settings.value("pagesrow", 4).toInt();
|
||||||
m_sizeOfSpeedDials = settings.value("sdsize", 231).toInt();
|
m_sizeOfSpeedDials = settings.value("sdsize", 231).toInt();
|
||||||
@ -217,7 +217,7 @@ QString SpeedDial::initialScript()
|
|||||||
imgSource = "qrc:html/loading.gif";
|
imgSource = "qrc:html/loading.gif";
|
||||||
|
|
||||||
if (page.url.isEmpty()) {
|
if (page.url.isEmpty()) {
|
||||||
imgSource = "";
|
imgSource.clear();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -77,7 +77,7 @@ void PopupStatusBarMessage::showMessage(const QString &message)
|
|||||||
void PopupStatusBarMessage::clearMessage()
|
void PopupStatusBarMessage::clearMessage()
|
||||||
{
|
{
|
||||||
if (m_popupWindow->statusBar()->isVisible()) {
|
if (m_popupWindow->statusBar()->isVisible()) {
|
||||||
m_popupWindow->statusBar()->showMessage("");
|
m_popupWindow->statusBar()->showMessage(QString());
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
m_statusBarText->hideDelayed();
|
m_statusBarText->hideDelayed();
|
||||||
|
@ -10,9 +10,6 @@
|
|||||||
<height>348</height>
|
<height>348</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||||
<item>
|
<item>
|
||||||
<widget class="QTabWidget" name="tabWidget">
|
<widget class="QTabWidget" name="tabWidget">
|
||||||
|
@ -10,9 +10,6 @@
|
|||||||
<height>462</height>
|
<height>462</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
<property name="margin">
|
<property name="margin">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
|
@ -10,9 +10,6 @@
|
|||||||
<height>36</height>
|
<height>36</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
<property name="topMargin">
|
<property name="topMargin">
|
||||||
<number>2</number>
|
<number>2</number>
|
||||||
|
@ -10,9 +10,6 @@
|
|||||||
<height>70</height>
|
<height>70</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
<property name="margin">
|
<property name="margin">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
|
@ -41,7 +41,7 @@ SideBar::SideBar(SideBarManager* manager, QupZilla* mainClass)
|
|||||||
m_layout->setSpacing(0);
|
m_layout->setSpacing(0);
|
||||||
setLayout(m_layout);
|
setLayout(m_layout);
|
||||||
|
|
||||||
m_titleBar = new DockTitleBarWidget("", this);
|
m_titleBar = new DockTitleBarWidget(QString(), this);
|
||||||
m_layout->addWidget(m_titleBar);
|
m_layout->addWidget(m_titleBar);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -279,8 +279,8 @@ QString CertificateInfoWidget::clearCertSpecialSymbols(const QString &string)
|
|||||||
n.replace("\\xC2\\xBD", "1/2"); // one half
|
n.replace("\\xC2\\xBD", "1/2"); // one half
|
||||||
n.replace("\\xC2\\xBE", "3/4"); // three quarters
|
n.replace("\\xC2\\xBE", "3/4"); // three quarters
|
||||||
n.replace("\\xCA\\xBF", "\\x27"); // c-single quote
|
n.replace("\\xCA\\xBF", "\\x27"); // c-single quote
|
||||||
n.replace("\\xCC\\xA8", ""); // modifier - under curve
|
n.replace("\\xCC\\xA8", QChar()); // modifier - under curve
|
||||||
n.replace("\\xCC\\xB1", ""); // modifier - under line
|
n.replace("\\xCC\\xB1", QChar()); // modifier - under line
|
||||||
|
|
||||||
return n;
|
return n;
|
||||||
}
|
}
|
||||||
|
@ -27,11 +27,7 @@
|
|||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="label">
|
<widget class="QLabel" name="label"/>
|
||||||
<property name="text">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QToolButton" name="closeButton">
|
<widget class="QToolButton" name="closeButton">
|
||||||
|
@ -10,9 +10,6 @@
|
|||||||
<height>374</height>
|
<height>374</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
|
@ -10,9 +10,6 @@
|
|||||||
<height>344</height>
|
<height>344</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
|
@ -10,9 +10,6 @@
|
|||||||
<height>300</height>
|
<height>300</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
|
@ -16,9 +16,6 @@
|
|||||||
<verstretch>0</verstretch>
|
<verstretch>0</verstretch>
|
||||||
</sizepolicy>
|
</sizepolicy>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||||
<property name="margin">
|
<property name="margin">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
|
@ -218,11 +218,11 @@ void TabbedWebView::linkHovered(const QString &link, const QString &title, const
|
|||||||
Q_UNUSED(content)
|
Q_UNUSED(content)
|
||||||
|
|
||||||
if (isCurrent()) {
|
if (isCurrent()) {
|
||||||
if (link != "") {
|
if (link.isEmpty()) {
|
||||||
p_QupZilla->statusBarMessage()->showMessage(link);
|
p_QupZilla->statusBarMessage()->clearMessage();
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
p_QupZilla->statusBarMessage()->clearMessage();
|
p_QupZilla->statusBarMessage()->showMessage(link);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -303,10 +303,10 @@ int TabWidget::addView(QNetworkRequest req, const QString &title, const Qz::NewT
|
|||||||
int index;
|
int index;
|
||||||
|
|
||||||
if (position == -1) {
|
if (position == -1) {
|
||||||
index = addTab(new WebTab(p_QupZilla, locBar), "");
|
index = addTab(new WebTab(p_QupZilla, locBar), QString());
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
index = insertTab(position, new WebTab(p_QupZilla, locBar), "");
|
index = insertTab(position, new WebTab(p_QupZilla, locBar), QString());
|
||||||
}
|
}
|
||||||
|
|
||||||
TabbedWebView* webView = weTab(index)->view();
|
TabbedWebView* webView = weTab(index)->view();
|
||||||
@ -505,7 +505,7 @@ void TabWidget::setTabText(int index, const QString &text)
|
|||||||
|
|
||||||
if (WebTab* webTab = weTab(index)) {
|
if (WebTab* webTab = weTab(index)) {
|
||||||
if (webTab->isPinned()) {
|
if (webTab->isPinned()) {
|
||||||
newtext = "";
|
newtext.clear();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -307,7 +307,7 @@ void WebTab::pinTab(int index)
|
|||||||
m_pinned = true;
|
m_pinned = true;
|
||||||
tabWidget->setCurrentIndex(0); // <<-- those 2 lines fixes
|
tabWidget->setCurrentIndex(0); // <<-- those 2 lines fixes
|
||||||
tabWidget->getTabBar()->moveTab(index, 0); // | weird behavior with bad
|
tabWidget->getTabBar()->moveTab(index, 0); // | weird behavior with bad
|
||||||
tabWidget->setTabText(0, ""); // | tabwidget update if we
|
tabWidget->setTabText(0, QString()); // | tabwidget update if we
|
||||||
tabWidget->setCurrentIndex(0); // <<-- are moving current tab
|
tabWidget->setCurrentIndex(0); // <<-- are moving current tab
|
||||||
tabWidget->getTabBar()->updateCloseButton(0);
|
tabWidget->getTabBar()->updateCloseButton(0);
|
||||||
}
|
}
|
||||||
|
@ -821,7 +821,7 @@ void WebView::createLinkContextMenu(QMenu* menu, const QWebHitTestResult &hitTes
|
|||||||
{
|
{
|
||||||
// Workaround for QtWebKit <= 2.0 when selecting link text on right click
|
// Workaround for QtWebKit <= 2.0 when selecting link text on right click
|
||||||
if (page()->selectedText() == hitTest.linkText()) {
|
if (page()->selectedText() == hitTest.linkText()) {
|
||||||
findText("");
|
findText(QString());
|
||||||
}
|
}
|
||||||
|
|
||||||
menu->addSeparator();
|
menu->addSeparator();
|
||||||
@ -882,7 +882,7 @@ void WebView::createSelectedTextContextMenu(QMenu* menu, const QWebHitTestResult
|
|||||||
connect(gtwact, SIGNAL(middleClicked()), this, SLOT(openUrlInBackgroundTab()));
|
connect(gtwact, SIGNAL(middleClicked()), this, SLOT(openUrlInBackgroundTab()));
|
||||||
menu->addAction(gtwact);
|
menu->addAction(gtwact);
|
||||||
Action* dictact = new Action(QIcon::fromTheme("accessories-dictionary"), tr("Dictionary"));
|
Action* dictact = new Action(QIcon::fromTheme("accessories-dictionary"), tr("Dictionary"));
|
||||||
dictact->setData(QUrl("http://" + (langCode != "" ? langCode + "." : langCode) + "wiktionary.org/wiki/Special:Search?search=" + selectedText));
|
dictact->setData(QUrl("http://" + (!langCode.isEmpty() ? langCode + "." : langCode) + "wiktionary.org/wiki/Special:Search?search=" + selectedText));
|
||||||
connect(dictact, SIGNAL(triggered()), this, SLOT(openUrlInSelectedTab()));
|
connect(dictact, SIGNAL(triggered()), this, SLOT(openUrlInSelectedTab()));
|
||||||
connect(dictact, SIGNAL(middleClicked()), this, SLOT(openUrlInBackgroundTab()));
|
connect(dictact, SIGNAL(middleClicked()), this, SLOT(openUrlInBackgroundTab()));
|
||||||
menu->addAction(dictact);
|
menu->addAction(dictact);
|
||||||
|
@ -41,20 +41,20 @@ void PIM_Handler::loadSettings()
|
|||||||
QSettings settings(m_settingsFile, QSettings::IniFormat);
|
QSettings settings(m_settingsFile, QSettings::IniFormat);
|
||||||
|
|
||||||
settings.beginGroup("PIM");
|
settings.beginGroup("PIM");
|
||||||
m_allInfo[PI_LastName] = settings.value("LastName", "").toString();
|
m_allInfo[PI_LastName] = settings.value("LastName", QString()).toString();
|
||||||
m_allInfo[PI_FirstName] = settings.value("FirstName", "").toString();
|
m_allInfo[PI_FirstName] = settings.value("FirstName", QString()).toString();
|
||||||
m_allInfo[PI_Email] = settings.value("Email", "").toString();
|
m_allInfo[PI_Email] = settings.value("Email", QString()).toString();
|
||||||
m_allInfo[PI_Mobile] = settings.value("Mobile", "").toString();
|
m_allInfo[PI_Mobile] = settings.value("Mobile", QString()).toString();
|
||||||
m_allInfo[PI_Phone] = settings.value("Phone", "").toString();
|
m_allInfo[PI_Phone] = settings.value("Phone", QString()).toString();
|
||||||
m_allInfo[PI_Address] = settings.value("Address", "").toString();
|
m_allInfo[PI_Address] = settings.value("Address", QString()).toString();
|
||||||
m_allInfo[PI_City] = settings.value("City", "").toString();
|
m_allInfo[PI_City] = settings.value("City", QString()).toString();
|
||||||
m_allInfo[PI_Zip] = settings.value("Zip", "").toString();
|
m_allInfo[PI_Zip] = settings.value("Zip", QString()).toString();
|
||||||
m_allInfo[PI_State] = settings.value("State", "").toString();
|
m_allInfo[PI_State] = settings.value("State", QString()).toString();
|
||||||
m_allInfo[PI_Country] = settings.value("Country", "").toString();
|
m_allInfo[PI_Country] = settings.value("Country", QString()).toString();
|
||||||
m_allInfo[PI_HomePage] = settings.value("HomePage", "").toString();
|
m_allInfo[PI_HomePage] = settings.value("HomePage", QString()).toString();
|
||||||
m_allInfo[PI_Special1] = settings.value("Special1", "").toString();
|
m_allInfo[PI_Special1] = settings.value("Special1", QString()).toString();
|
||||||
m_allInfo[PI_Special2] = settings.value("Special2", "").toString();
|
m_allInfo[PI_Special2] = settings.value("Special2", QString()).toString();
|
||||||
m_allInfo[PI_Special3] = settings.value("Special3", "").toString();
|
m_allInfo[PI_Special3] = settings.value("Special3", QString()).toString();
|
||||||
settings.endGroup();
|
settings.endGroup();
|
||||||
|
|
||||||
m_translations[PI_LastName] = tr("Last Name");
|
m_translations[PI_LastName] = tr("Last Name");
|
||||||
|
@ -33,20 +33,20 @@ PIM_Settings::PIM_Settings(const QString &settingsFile, QWidget* parent)
|
|||||||
|
|
||||||
QSettings settings(m_settingsFile, QSettings::IniFormat);
|
QSettings settings(m_settingsFile, QSettings::IniFormat);
|
||||||
settings.beginGroup("PIM");
|
settings.beginGroup("PIM");
|
||||||
ui->pim_firstname->setText(settings.value("FirstName", "").toString());
|
ui->pim_firstname->setText(settings.value("FirstName", QString()).toString());
|
||||||
ui->pim_lastname->setText(settings.value("LastName", "").toString());
|
ui->pim_lastname->setText(settings.value("LastName", QString()).toString());
|
||||||
ui->pim_email->setText(settings.value("Email", "").toString());
|
ui->pim_email->setText(settings.value("Email", QString()).toString());
|
||||||
ui->pim_phone->setText(settings.value("Phone", "").toString());
|
ui->pim_phone->setText(settings.value("Phone", QString()).toString());
|
||||||
ui->pim_mobile->setText(settings.value("Mobile", "").toString());
|
ui->pim_mobile->setText(settings.value("Mobile", QString()).toString());
|
||||||
ui->pim_address->setText(settings.value("Address", "").toString());
|
ui->pim_address->setText(settings.value("Address", QString()).toString());
|
||||||
ui->pim_city->setText(settings.value("City", "").toString());
|
ui->pim_city->setText(settings.value("City", QString()).toString());
|
||||||
ui->pim_zip->setText(settings.value("Zip", "").toString());
|
ui->pim_zip->setText(settings.value("Zip", QString()).toString());
|
||||||
ui->pim_state->setText(settings.value("State", "").toString());
|
ui->pim_state->setText(settings.value("State", QString()).toString());
|
||||||
ui->pim_country->setText(settings.value("Country", "").toString());
|
ui->pim_country->setText(settings.value("Country", QString()).toString());
|
||||||
ui->pim_homepage->setText(settings.value("HomePage", "").toString());
|
ui->pim_homepage->setText(settings.value("HomePage", QString()).toString());
|
||||||
ui->pim_special1->setText(settings.value("Special1", "").toString());
|
ui->pim_special1->setText(settings.value("Special1", QString()).toString());
|
||||||
ui->pim_special2->setText(settings.value("Special2", "").toString());
|
ui->pim_special2->setText(settings.value("Special2", QString()).toString());
|
||||||
ui->pim_special3->setText(settings.value("Special3", "").toString());
|
ui->pim_special3->setText(settings.value("Special3", QString()).toString());
|
||||||
settings.endGroup();
|
settings.endGroup();
|
||||||
|
|
||||||
connect(this, SIGNAL(accepted()), this, SLOT(dialogAccepted()));
|
connect(this, SIGNAL(accepted()), this, SLOT(dialogAccepted()));
|
||||||
|
Loading…
Reference in New Issue
Block a user