summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/CMakeLists.txt2
-rw-r--r--src/mainwindow.cpp3
-rw-r--r--src/networkaccessmanager.cpp44
-rw-r--r--src/password.ui69
-rw-r--r--src/passworddialog.ui111
-rw-r--r--src/proxy.ui100
6 files changed, 122 insertions, 207 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 88224670..585702f2 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -24,7 +24,7 @@ KDE4_ADD_UI_FILES( rekonq_SRCS
cookies.ui
cookiesexceptions.ui
history.ui
- passworddialog.ui
+ password.ui
proxy.ui
settings_general.ui
settings_fonts.ui
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 54c5ab77..ef0a3951 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -37,9 +37,6 @@
#include "mainview.h"
#include "bookmarks.h"
-// UI Includes
-#include "ui_passworddialog.h"
-
// KDE Includes
#include <KUrl>
#include <KStatusBar>
diff --git a/src/networkaccessmanager.cpp b/src/networkaccessmanager.cpp
index 26078ed6..1d9f2a78 100644
--- a/src/networkaccessmanager.cpp
+++ b/src/networkaccessmanager.cpp
@@ -31,7 +31,7 @@
#include "rekonq.h"
// Ui Includes
-#include "ui_passworddialog.h"
+#include "ui_password.h"
#include "ui_proxy.h"
// KDE Includes
@@ -99,24 +99,25 @@ void NetworkAccessManager::authenticationRequired(QNetworkReply *reply, QAuthent
{
MainWindow *mainWindow = Application::instance()->mainWindow();
- QDialog dialog(mainWindow);
- dialog.setWindowFlags(Qt::Sheet);
+ KDialog dialog(mainWindow,Qt::Sheet);
- Ui::PasswordDialog passwordDialog;
- passwordDialog.setupUi(&dialog);
+ Ui::passwordWidget passwordWidget;
+ passwordWidget.setupUi(&dialog);
- passwordDialog.iconLabel->setText(QString());
- passwordDialog.iconLabel->setPixmap(mainWindow->style()->standardIcon(QStyle::SP_MessageBoxQuestion, 0, mainWindow).pixmap(32, 32));
+ dialog.setButtons( KDialog::Ok | KDialog::Cancel );
+
+ passwordWidget.iconLabel->setText(QString());
+ passwordWidget.iconLabel->setPixmap(mainWindow->style()->standardIcon(QStyle::SP_MessageBoxQuestion, 0, mainWindow).pixmap(32, 32));
QString introMessage = i18n("<qt>Enter username and password for ") +
Qt::escape(reply->url().toString()) + i18n(" at ") + Qt::escape(reply->url().toString()) + "</qt>";
- passwordDialog.introLabel->setText(introMessage);
- passwordDialog.introLabel->setWordWrap(true);
+ passwordWidget.introLabel->setText(introMessage);
+ passwordWidget.introLabel->setWordWrap(true);
if (dialog.exec() == QDialog::Accepted)
{
- auth->setUser(passwordDialog.userNameLineEdit->text());
- auth->setPassword(passwordDialog.passwordLineEdit->text());
+ auth->setUser(passwordWidget.userNameLineEdit->text());
+ auth->setPassword(passwordWidget.passwordLineEdit->text());
}
}
@@ -124,23 +125,24 @@ void NetworkAccessManager::proxyAuthenticationRequired(const QNetworkProxy &prox
{
MainWindow *mainWindow = Application::instance()->mainWindow();
- QDialog dialog(mainWindow);
- dialog.setWindowFlags(Qt::Sheet);
+ KDialog dialog(mainWindow, Qt::Sheet);
+
+ Ui::proxyWidget proxyWdg;
+ proxyWdg.setupUi(&dialog);
- Ui::ProxyDialog proxyDialog;
- proxyDialog.setupUi(&dialog);
+ dialog.setButtons( KDialog::Ok | KDialog::Cancel );
- proxyDialog.iconLabel->setText(QString());
- proxyDialog.iconLabel->setPixmap(mainWindow->style()->standardIcon(QStyle::SP_MessageBoxQuestion, 0, mainWindow).pixmap(32, 32));
+ proxyWdg.iconLabel->setText(QString());
+ proxyWdg.iconLabel->setPixmap(mainWindow->style()->standardIcon(QStyle::SP_MessageBoxQuestion, 0, mainWindow).pixmap(32, 32));
QString introMessage = i18n("<qt>Connect to proxy ") + Qt::escape(proxy.hostName()) + i18n(" using:</qt>");
- proxyDialog.introLabel->setText(introMessage);
- proxyDialog.introLabel->setWordWrap(true);
+ proxyWdg.introLabel->setText(introMessage);
+ proxyWdg.introLabel->setWordWrap(true);
if (dialog.exec() == QDialog::Accepted)
{
- auth->setUser(proxyDialog.userNameLineEdit->text());
- auth->setPassword(proxyDialog.passwordLineEdit->text());
+ auth->setUser(proxyWdg.userNameLineEdit->text());
+ auth->setPassword(proxyWdg.passwordLineEdit->text());
}
}
diff --git a/src/password.ui b/src/password.ui
new file mode 100644
index 00000000..028e1683
--- /dev/null
+++ b/src/password.ui
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>passwordWidget</class>
+ <widget class="QWidget" name="passwordWidget">
+ <property name="geometry">
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>343</width>
+ <height>193</height>
+ </rect>
+ </property>
+ <property name="windowTitle">
+ <string>Form</string>
+ </property>
+ <layout class="QGridLayout" name="gridLayout">
+ <item row="0" column="0" colspan="2">
+ <layout class="QHBoxLayout">
+ <item>
+ <widget class="QLabel" name="iconLabel">
+ <property name="text">
+ <string>DUMMY ICON</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLabel" name="introLabel">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="MinimumExpanding" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="text">
+ <string>INTRO TEXT DUMMY</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </item>
+ <item row="1" column="0">
+ <widget class="QLabel" name="label">
+ <property name="text">
+ <string>Username:</string>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="1">
+ <widget class="QLineEdit" name="userNameLineEdit"/>
+ </item>
+ <item row="2" column="0">
+ <widget class="QLabel" name="lblPassword">
+ <property name="text">
+ <string>Password:</string>
+ </property>
+ </widget>
+ </item>
+ <item row="2" column="1">
+ <widget class="QLineEdit" name="passwordLineEdit">
+ <property name="echoMode">
+ <enum>QLineEdit::Password</enum>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ <resources/>
+ <connections/>
+</ui>
diff --git a/src/passworddialog.ui b/src/passworddialog.ui
deleted file mode 100644
index 7c166586..00000000
--- a/src/passworddialog.ui
+++ /dev/null
@@ -1,111 +0,0 @@
-<ui version="4.0" >
- <class>PasswordDialog</class>
- <widget class="QDialog" name="PasswordDialog" >
- <property name="geometry" >
- <rect>
- <x>0</x>
- <y>0</y>
- <width>399</width>
- <height>148</height>
- </rect>
- </property>
- <property name="windowTitle" >
- <string>Authentication Required</string>
- </property>
- <layout class="QGridLayout" name="gridLayout" >
- <item row="0" column="0" colspan="2" >
- <layout class="QHBoxLayout" >
- <item>
- <widget class="QLabel" name="iconLabel" >
- <property name="text" >
- <string>DUMMY ICON</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QLabel" name="introLabel" >
- <property name="sizePolicy" >
- <sizepolicy vsizetype="MinimumExpanding" hsizetype="MinimumExpanding" >
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- <property name="text" >
- <string>INTRO TEXT DUMMY</string>
- </property>
- </widget>
- </item>
- </layout>
- </item>
- <item row="1" column="0" >
- <widget class="QLabel" name="label" >
- <property name="text" >
- <string>Username:</string>
- </property>
- </widget>
- </item>
- <item row="1" column="1" >
- <widget class="QLineEdit" name="userNameLineEdit" />
- </item>
- <item row="2" column="0" >
- <widget class="QLabel" name="lblPassword" >
- <property name="text" >
- <string>Password:</string>
- </property>
- </widget>
- </item>
- <item row="2" column="1" >
- <widget class="QLineEdit" name="passwordLineEdit" >
- <property name="echoMode" >
- <enum>QLineEdit::Password</enum>
- </property>
- </widget>
- </item>
- <item row="3" column="0" colspan="2" >
- <widget class="QDialogButtonBox" name="buttonBox" >
- <property name="orientation" >
- <enum>Qt::Horizontal</enum>
- </property>
- <property name="standardButtons" >
- <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
- </property>
- </widget>
- </item>
- </layout>
- </widget>
- <resources/>
- <connections>
- <connection>
- <sender>buttonBox</sender>
- <signal>accepted()</signal>
- <receiver>PasswordDialog</receiver>
- <slot>accept()</slot>
- <hints>
- <hint type="sourcelabel" >
- <x>248</x>
- <y>254</y>
- </hint>
- <hint type="destinationlabel" >
- <x>157</x>
- <y>274</y>
- </hint>
- </hints>
- </connection>
- <connection>
- <sender>buttonBox</sender>
- <signal>rejected()</signal>
- <receiver>PasswordDialog</receiver>
- <slot>reject()</slot>
- <hints>
- <hint type="sourcelabel" >
- <x>316</x>
- <y>260</y>
- </hint>
- <hint type="destinationlabel" >
- <x>286</x>
- <y>274</y>
- </hint>
- </hints>
- </connection>
- </connections>
-</ui>
diff --git a/src/proxy.ui b/src/proxy.ui
index 62a8be62..e7440862 100644
--- a/src/proxy.ui
+++ b/src/proxy.ui
@@ -1,104 +1,62 @@
-<ui version="4.0" >
- <class>ProxyDialog</class>
- <widget class="QDialog" name="ProxyDialog" >
- <property name="geometry" >
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>proxyWidget</class>
+ <widget class="QWidget" name="proxyWidget">
+ <property name="geometry">
<rect>
<x>0</x>
<y>0</y>
- <width>369</width>
- <height>144</height>
+ <width>264</width>
+ <height>153</height>
</rect>
</property>
- <property name="windowTitle" >
- <string>Proxy Authentication</string>
+ <property name="windowTitle">
+ <string>Form</string>
</property>
- <layout class="QGridLayout" name="gridLayout" >
- <item row="0" column="0" >
- <widget class="QLabel" name="iconLabel" >
- <property name="text" >
+ <layout class="QGridLayout" name="gridLayout">
+ <item row="0" column="0">
+ <widget class="QLabel" name="iconLabel">
+ <property name="text">
<string>ICON</string>
</property>
</widget>
</item>
- <item row="0" column="1" colspan="2" >
- <widget class="QLabel" name="introLabel" >
- <property name="text" >
+ <item row="0" column="1" colspan="2">
+ <widget class="QLabel" name="introLabel">
+ <property name="text">
<string>Connect to proxy</string>
</property>
- <property name="wordWrap" >
+ <property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
- <item row="1" column="0" colspan="2" >
- <widget class="QLabel" name="usernameLabel" >
- <property name="text" >
+ <item row="1" column="0" colspan="2">
+ <widget class="QLabel" name="usernameLabel">
+ <property name="text">
<string>Username:</string>
</property>
</widget>
</item>
- <item row="1" column="2" >
- <widget class="QLineEdit" name="userNameLineEdit" />
+ <item row="1" column="2">
+ <widget class="QLineEdit" name="userNameLineEdit"/>
</item>
- <item row="2" column="0" colspan="2" >
- <widget class="QLabel" name="passwordLabel" >
- <property name="text" >
+ <item row="2" column="0" colspan="2">
+ <widget class="QLabel" name="passwordLabel">
+ <property name="text">
<string>Password:</string>
</property>
</widget>
</item>
- <item row="2" column="2" >
- <widget class="QLineEdit" name="passwordLineEdit" >
- <property name="echoMode" >
+ <item row="2" column="2">
+ <widget class="QLineEdit" name="passwordLineEdit">
+ <property name="echoMode">
<enum>QLineEdit::Password</enum>
</property>
</widget>
</item>
- <item row="3" column="0" colspan="3" >
- <widget class="QDialogButtonBox" name="buttonBox" >
- <property name="orientation" >
- <enum>Qt::Horizontal</enum>
- </property>
- <property name="standardButtons" >
- <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
- </property>
- </widget>
- </item>
</layout>
</widget>
<resources/>
- <connections>
- <connection>
- <sender>buttonBox</sender>
- <signal>accepted()</signal>
- <receiver>ProxyDialog</receiver>
- <slot>accept()</slot>
- <hints>
- <hint type="sourcelabel" >
- <x>248</x>
- <y>254</y>
- </hint>
- <hint type="destinationlabel" >
- <x>157</x>
- <y>274</y>
- </hint>
- </hints>
- </connection>
- <connection>
- <sender>buttonBox</sender>
- <signal>rejected()</signal>
- <receiver>ProxyDialog</receiver>
- <slot>reject()</slot>
- <hints>
- <hint type="sourcelabel" >
- <x>316</x>
- <y>260</y>
- </hint>
- <hint type="destinationlabel" >
- <x>286</x>
- <y>274</y>
- </hint>
- </hints>
- </connection>
- </connections>
+ <connections/>
</ui>