[kde-doc-english] [kde-baseapps] konqueror/settings/kio: Rewrote the proxy configuration dialog to include missing SOCKS

Dawit Alemayehu adawit at kde.org
Thu Oct 20 06:16:26 UTC 2011


Git commit f90f318f2162df18a08b889d24ae8bbeab3b834c by Dawit Alemayehu.
Committed on 01/08/2011 at 07:44.
Pushed by adawit into branch 'master'.

Rewrote the proxy configuration dialog to include missing SOCKS
proxy entry and make it much simpler to use.

BUG:82352
BUG:115704
BUG:139789
BUG:147340
BUG:164460
BUG:189019
BUG:190149
BUG:190901
BUG:205594
BUG:258196
BUG:283226
FIXED-IN:4.8

REVIEW: 102802

GUI:  Proxy configuration dialog rewrite.

M  +0    -5    konqueror/settings/kio/CMakeLists.txt
D  +0    -251  konqueror/settings/kio/envvarproxy.ui
D  +0    -310  konqueror/settings/kio/kenvvarproxydlg.cpp
D  +0    -71   konqueror/settings/kio/kenvvarproxydlg.h
D  +0    -496  konqueror/settings/kio/kmanualproxydlg.cpp
D  +0    -86   konqueror/settings/kio/kmanualproxydlg.h
M  +410  -215  konqueror/settings/kio/kproxydlg.cpp
M  +30   -18   konqueror/settings/kio/kproxydlg.h
M  +833  -248  konqueror/settings/kio/kproxydlg.ui
D  +0    -79   konqueror/settings/kio/kproxydlgbase.cpp
D  +0    -69   konqueror/settings/kio/kproxydlgbase.h
M  +77   -88   konqueror/settings/kio/ksaveioconfig.cpp
M  +28   -32   konqueror/settings/kio/ksaveioconfig.h
D  +0    -291  konqueror/settings/kio/manualproxy.ui

http://commits.kde.org/kde-baseapps/f90f318f2162df18a08b889d24ae8bbeab3b834c

diff --git a/konqueror/settings/kio/CMakeLists.txt b/konqueror/settings/kio/CMakeLists.txt
index e5476c9..8ce5182 100644
--- a/konqueror/settings/kio/CMakeLists.txt
+++ b/konqueror/settings/kio/CMakeLists.txt
@@ -11,9 +11,6 @@ set(kcm_kio_PART_SRCS
     kcookiespolicyselectiondlg.cpp
     smbrodlg.cpp
     useragentdlg.cpp
-    kproxydlgbase.cpp
-    kmanualproxydlg.cpp
-    kenvvarproxydlg.cpp
     kproxydlg.cpp
     useragentinfo.cpp
     useragentselectordlg.cpp
@@ -27,8 +24,6 @@ kde4_add_ui_files(kcm_kio_PART_SRCS
     cache.ui
     useragentselectordlg.ui
     useragentdlg.ui
-    manualproxy.ui
-    envvarproxy.ui
     kproxydlg.ui
     kcookiespolicies.ui
     kcookiesmanagement.ui
diff --git a/konqueror/settings/kio/envvarproxy.ui b/konqueror/settings/kio/envvarproxy.ui
deleted file mode 100644
index a09450d..0000000
--- a/konqueror/settings/kio/envvarproxy.ui
+++ /dev/null
@@ -1,251 +0,0 @@
-<ui version="4.0" >
- <class>EnvVarProxyDlgUI</class>
- <widget class="QWidget" name="EnvVarProxyDlgUI" >
-  <property name="geometry" >
-   <rect>
-    <x>0</x>
-    <y>0</y>
-    <width>526</width>
-    <height>296</height>
-   </rect>
-  </property>
-  <layout class="QGridLayout" name="gridLayout" >
-   <item row="0" column="0" >
-    <layout class="QFormLayout" name="formLayout" >
-     <item row="0" column="0" >
-      <widget class="QLabel" name="lbHttp" >
-       <property name="whatsThis" >
-        <string><qt>
-Enter the name of the environment variable, e.g. <b>HTTP_PROXY</b>, used to store the address of the HTTP proxy server.<p>
-Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt automatic discovery of this variable.</p>
-</qt></string>
-       </property>
-       <property name="text" >
-        <string>H&TTP:</string>
-       </property>
-       <property name="alignment" >
-        <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-       </property>
-       <property name="wordWrap" >
-        <bool>false</bool>
-       </property>
-       <property name="buddy" >
-        <cstring>leHttp</cstring>
-       </property>
-      </widget>
-     </item>
-     <item row="0" column="1" >
-      <widget class="KLineEdit" name="leHttp" >
-       <property name="sizePolicy" >
-        <sizepolicy vsizetype="Fixed" hsizetype="Expanding" >
-         <horstretch>0</horstretch>
-         <verstretch>0</verstretch>
-        </sizepolicy>
-       </property>
-       <property name="whatsThis" >
-        <string><qt>
-Enter the name of the environment variable, e.g. <b>HTTP_PROXY</b>, used to store the address of the HTTP proxy server.<p>
-Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt automatic discovery of this variable.</p>
-</qt></string>
-       </property>
-      </widget>
-     </item>
-     <item row="1" column="0" >
-      <widget class="QLabel" name="lbHttps" >
-       <property name="whatsThis" >
-        <string><qt>
-Enter the name of the environment variable, e.g. <b>HTTPS_PROXY</b>, used to store the address of the HTTPS proxy server.<p>
-Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.</p>
-</qt></string>
-       </property>
-       <property name="text" >
-        <string>HTTP&S:</string>
-       </property>
-       <property name="alignment" >
-        <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-       </property>
-       <property name="wordWrap" >
-        <bool>false</bool>
-       </property>
-       <property name="buddy" >
-        <cstring>leHttps</cstring>
-       </property>
-      </widget>
-     </item>
-     <item row="1" column="1" >
-      <widget class="KLineEdit" name="leHttps" >
-       <property name="sizePolicy" >
-        <sizepolicy vsizetype="Fixed" hsizetype="Expanding" >
-         <horstretch>0</horstretch>
-         <verstretch>0</verstretch>
-        </sizepolicy>
-       </property>
-       <property name="whatsThis" >
-        <string><qt>
-Enter the name of the environment variable, e.g. <b>HTTPS_PROXY</b>, used to store the address of the HTTPS proxy server.<p>
-Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.</p>
-</qt></string>
-       </property>
-      </widget>
-     </item>
-     <item row="2" column="0" >
-      <widget class="QLabel" name="lbFtp" >
-       <property name="whatsThis" >
-        <string><qt>
-Enter the name of the environment variable, e.g. <b>FTP_PROXY</b>, used to store the address of the FTP proxy server.<p>
-Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.</p>
-</qt></string>
-       </property>
-       <property name="text" >
-        <string>&FTP:</string>
-       </property>
-       <property name="alignment" >
-        <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-       </property>
-       <property name="wordWrap" >
-        <bool>false</bool>
-       </property>
-       <property name="buddy" >
-        <cstring>leFtp</cstring>
-       </property>
-      </widget>
-     </item>
-     <item row="2" column="1" >
-      <widget class="KLineEdit" name="leFtp" >
-       <property name="sizePolicy" >
-        <sizepolicy vsizetype="Fixed" hsizetype="Expanding" >
-         <horstretch>0</horstretch>
-         <verstretch>0</verstretch>
-        </sizepolicy>
-       </property>
-       <property name="whatsThis" >
-        <string><qt>
-Enter the name of the environment variable, e.g. <b>FTP_PROXY</b>, used to store the address of the FTP proxy server.<p>
-Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.</p>
-</qt></string>
-       </property>
-      </widget>
-     </item>
-     <item row="3" column="0" >
-      <widget class="QLabel" name="lnNoProxy" >
-       <property name="whatsThis" >
-        <string><qt>
-Enter the environment variable, e.g. <b>NO_PROXY</b>, used to store the addresses of sites for which the proxy server should not be used.<p>
-Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.
-</qt></string>
-       </property>
-       <property name="text" >
-        <string>NO &PROXY:</string>
-       </property>
-       <property name="alignment" >
-        <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
-       </property>
-       <property name="wordWrap" >
-        <bool>false</bool>
-       </property>
-       <property name="buddy" >
-        <cstring>leNoProxy</cstring>
-       </property>
-      </widget>
-     </item>
-     <item row="3" column="1" >
-      <widget class="KLineEdit" name="leNoProxy" >
-       <property name="sizePolicy" >
-        <sizepolicy vsizetype="Fixed" hsizetype="Expanding" >
-         <horstretch>0</horstretch>
-         <verstretch>0</verstretch>
-        </sizepolicy>
-       </property>
-       <property name="whatsThis" >
-        <string><qt>
-Enter the environment variable, e.g. <b>NO_PROXY</b>, used to store the addresses of sites for which the proxy server should not be used.<p>
-Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.
-</qt></string>
-       </property>
-      </widget>
-     </item>
-     <item row="4" column="1" >
-      <widget class="QCheckBox" name="cbShowValue" >
-       <property name="text" >
-        <string>Show the &value of the environment variables</string>
-       </property>
-      </widget>
-     </item>
-    </layout>
-   </item>
-   <item row="0" column="1" >
-    <layout class="QVBoxLayout" >
-     <item>
-      <widget class="QPushButton" name="pbVerify" >
-       <property name="whatsThis" >
-        <string><qt>Verify whether or not the environment variable names you supplied are valid. If an environment variable is not found, the associated labels will be <b>highlighted</b> to indicate that they are invalid.</qt></string>
-       </property>
-       <property name="text" >
-        <string>&Verify</string>
-       </property>
-      </widget>
-     </item>
-     <item>
-      <widget class="QPushButton" name="pbDetect" >
-       <property name="whatsThis" >
-        <string><qt>Attempt automatic discovery of the environment variables used for setting system wide proxy information.<p> This feature works by searching for commonly used variable names such as HTTP_PROXY, FTP_PROXY and NO_PROXY.</qt></string>
-       </property>
-       <property name="text" >
-        <string>Auto &Detect</string>
-       </property>
-      </widget>
-     </item>
-     <item>
-      <spacer>
-       <property name="orientation" >
-        <enum>Qt::Vertical</enum>
-       </property>
-       <property name="sizeType" >
-        <enum>QSizePolicy::MinimumExpanding</enum>
-       </property>
-       <property name="sizeHint" stdset="0" >
-        <size>
-         <width>16</width>
-         <height>51</height>
-        </size>
-       </property>
-      </spacer>
-     </item>
-    </layout>
-   </item>
-   <item row="1" column="0" >
-    <spacer>
-     <property name="orientation" >
-      <enum>Qt::Vertical</enum>
-     </property>
-     <property name="sizeType" >
-      <enum>QSizePolicy::MinimumExpanding</enum>
-     </property>
-     <property name="sizeHint" stdset="0" >
-      <size>
-       <width>20</width>
-       <height>20</height>
-      </size>
-     </property>
-    </spacer>
-   </item>
-  </layout>
- </widget>
- <customwidgets>
-  <customwidget>
-   <class>KLineEdit</class>
-   <extends>QLineEdit</extends>
-   <header>klineedit.h</header>
-  </customwidget>
- </customwidgets>
- <tabstops>
-  <tabstop>leHttp</tabstop>
-  <tabstop>leHttps</tabstop>
-  <tabstop>leFtp</tabstop>
-  <tabstop>leNoProxy</tabstop>
-  <tabstop>pbVerify</tabstop>
-  <tabstop>pbDetect</tabstop>
- </tabstops>
- <resources/>
- <connections/>
-</ui>
diff --git a/konqueror/settings/kio/kenvvarproxydlg.cpp b/konqueror/settings/kio/kenvvarproxydlg.cpp
deleted file mode 100644
index ef5c86c..0000000
--- a/konqueror/settings/kio/kenvvarproxydlg.cpp
+++ /dev/null
@@ -1,310 +0,0 @@
-/*
-   kenvvarproxydlg.cpp - Proxy configuration dialog
-
-   Copyright (C) 2001- Dawit Alemayehu <adawit at kde.org>
-
-   This library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU General Public
-   License (GPL) version 2 as published by the Free Software
-   Foundation.
-
-   This library 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
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this library; see the file COPYING.LIB.  If not, write to
-   the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-   Boston, MA 02110-1301, USA.
-*/
-
-// Local
-#include "kenvvarproxydlg.h"
-
-// std
-#include <stdlib.h>
-
-// Qt
-#include <QtGui/QLabel>
-#include <QtGui/QLayout>
-#include <QtGui/QCheckBox>
-#include <QtGui/QPushButton>
-
-// KDE
-#include <kdebug.h>
-#include <klocale.h>
-#include <klineedit.h>
-#include <kmessagebox.h>
-#include <kurl.h>
-
-#define ENV_FTP_PROXY     "FTP_PROXY,ftp_proxy,FTPPROXY,ftpproxy,PROXY,proxy"
-#define ENV_HTTP_PROXY    "HTTP_PROXY,http_proxy,HTTPPROXY,httpproxy,PROXY,proxy"
-#define ENV_HTTPS_PROXY   "HTTPS_PROXY,https_proxy,HTTPSPROXY,httpsproxy,PROXY,proxy"
-#define NO_PROXY          "NO_PROXY,no_proxy"
-
-
-KEnvVarProxyDlg::KEnvVarProxyDlg( QWidget* parent, const char* name )
-                :KProxyDialogBase( parent, name, true,
-                                   i18nc( "@title:window", "Variable Proxy Configuration" ) )
-{
-  mDlg = new EnvVarProxyDlgUI( this );
-  setMainWidget( mDlg );
-  mDlg->leHttp->setMinimumWidth( mDlg->leHttp->fontMetrics().maxWidth() * 20 );
-  init();
-}
-
-KEnvVarProxyDlg::~KEnvVarProxyDlg ()
-{
-}
-
-void KEnvVarProxyDlg::init()
-{
-  m_bHasValidData = false;
-
-  connect( mDlg->cbShowValue, SIGNAL(clicked()), SLOT(showValue()) );
-  connect( mDlg->pbVerify, SIGNAL(clicked()), SLOT(verifyPressed()) );
-  connect( mDlg->pbDetect, SIGNAL(clicked()), SLOT(autoDetectPressed()) );
-}
-
-void KEnvVarProxyDlg::setProxyData( const KProxyData& data )
-{
-  // Setup HTTP Proxy...
-  KUrl u ( data.proxyList["http"] );
-  if (!u.isEmpty() && !u.isValid())
-  {
-    mEnvVarsMap["http"].name = data.proxyList["http"];
-    mEnvVarsMap["http"].value = QString::fromLocal8Bit( getenv(data.proxyList["http"].toLocal8Bit()) );
-  }
-
-  // Setup HTTPS Proxy...
-  u = data.proxyList["https"];
-  if (!u.isEmpty() && !u.isValid())
-  {
-    mEnvVarsMap["https"].name = data.proxyList["https"];
-    mEnvVarsMap["https"].value = QString::fromLocal8Bit( getenv(data.proxyList["https"].toLocal8Bit()) );
-  }
-
-  // Setup FTP Proxy...
-  u = data.proxyList["ftp"];
-  if (!u.isEmpty() && !u.isValid())
-  {
-    mEnvVarsMap["ftp"].name = data.proxyList["ftp"];
-    mEnvVarsMap["ftp"].value = QString::fromLocal8Bit( getenv(data.proxyList["ftp"].toLocal8Bit()) );
-  }
-
-  u = data.noProxyFor.join(",");
-  if (!u.isEmpty() && !u.isValid())
-  {
-    QString noProxy = u.url();
-    mEnvVarsMap["noProxy"].name = noProxy;
-    mEnvVarsMap["noProxy"].value = QString::fromLocal8Bit( getenv(noProxy.toLocal8Bit()) );
-  }
-
-  mDlg->cbShowValue->setChecked( data.showEnvVarValue );
-  showValue();
-}
-
-const KProxyData KEnvVarProxyDlg::data() const
-{
-  KProxyData data;
-
-  if (m_bHasValidData)
-  {
-    data.proxyList["http"] = mEnvVarsMap["http"].name;
-    data.proxyList["https"] = mEnvVarsMap["https"].name;
-    data.proxyList["ftp"] = mEnvVarsMap["ftp"].name;
-    data.noProxyFor = QStringList(mEnvVarsMap["noProxy"].name);
-    data.type = KProtocolManager::EnvVarProxy;
-    data.showEnvVarValue = mDlg->cbShowValue->isChecked();
-  }
-
-  return data;
-}
-
-
-void KEnvVarProxyDlg::verifyPressed()
-{
-  if ( !validate() )
-  {
-    QString msg = i18n("You must specify at least one valid proxy "
-                       "environment variable.");
-
-    QString details = i18n("<qt>Make sure you entered the actual environment "
-                           "variable name rather than its value. For "
-                           "example, if the environment variable is <br /><b>"
-                           "HTTP_PROXY=http://localhost:3128</b><br /> you need "
-                           "to enter <b>HTTP_PROXY</b> here instead of the "
-                           "actual value http://localhost:3128.</qt>");
-
-    KMessageBox::detailedSorry( this, msg, details,
-                                i18nc("@title:window", "Invalid Proxy Setup") );
-  }
-  else
-  {
-    KMessageBox::information( this, i18n("Successfully verified."),
-                                    i18nc("@title:window", "Proxy Setup") );
-  }
-}
-
-void KEnvVarProxyDlg::autoDetectPressed()
-{
-  QString env;
-  QStringList::ConstIterator it;
-
-  bool found = false;
-
-  setHighLight (mDlg->lbHttp, false);
-  setHighLight (mDlg->lbHttps, false);
-  setHighLight (mDlg->lbFtp, false);
-
-  // Detect HTTP proxy settings...
-  QStringList list = QString::fromLatin1(ENV_HTTP_PROXY).split( ',', QString::SkipEmptyParts );
-  for( it = list.constBegin(); it != list.constEnd(); ++it )
-  {
-    env = QString::fromLocal8Bit( getenv( (*it).toLocal8Bit() ) );
-    if ( !env.isEmpty() )
-    {
-      mEnvVarsMap ["http"].name = *it;
-      mEnvVarsMap ["http"].value = env;
-      mDlg->leHttp->setText( (mDlg->cbShowValue->isChecked() ? env : *it) );
-      found = true;
-      break;
-    }
-  }
-
-  // Detect HTTPS proxy settings...
-  list = QString::fromLatin1(ENV_HTTPS_PROXY).split( ',', QString::SkipEmptyParts );
-  for( it = list.constBegin(); it != list.constEnd(); ++it )
-  {
-    env = QString::fromLocal8Bit( getenv( (*it).toLocal8Bit() ) );
-    if ( !env.isEmpty() )
-    {
-      mEnvVarsMap ["https"].name = *it;
-      mEnvVarsMap ["https"].value = env;
-      mDlg->leHttps->setText( (mDlg->cbShowValue->isChecked() ? env : *it) );
-      found = true;
-      break;
-    }
-  }
-
-  // Detect FTP proxy settings...
-  list = QString::fromLatin1(ENV_FTP_PROXY).split( ',', QString::SkipEmptyParts );
-  for(it = list.constBegin(); it != list.constEnd(); ++it )
-  {
-    env = QString::fromLocal8Bit( getenv( (*it).toLocal8Bit() ) );
-    if ( !env.isEmpty() )
-    {
-      mEnvVarsMap ["ftp"].name = *it;
-      mEnvVarsMap ["ftp"].value = env;
-      mDlg->leFtp->setText( (mDlg->cbShowValue->isChecked() ? env : *it) );
-      found = true;
-      break;
-    }
-  }
-
-  // Detect the NO_PROXY settings...
-  list = QString::fromLatin1(NO_PROXY).split (',', QString::SkipEmptyParts );
-  for(it = list.constBegin(); it != list.constEnd(); ++it )
-  {
-    env = QString::fromLocal8Bit( getenv( (*it).toLocal8Bit() ) );
-    if ( !env.isEmpty() )
-    {
-      mEnvVarsMap ["noProxy"].name = *it;
-      mEnvVarsMap ["noProxy"].value = env;
-      mDlg->leNoProxy->setText( (mDlg->cbShowValue->isChecked() ? env : *it) );
-      break;
-    }
-  }
-
-  if ( !found )
-  {
-    QString msg = i18n("Did not detect any environment variables "
-                       "commonly used to set system wide proxy "
-                       "information.");
-
-    QString details = i18n("<qt>To learn about the variable names the "
-                           "automatic detection process searches for, "
-                           "press OK, click on the quick help button "
-                           "on the window title bar of the "
-                           "previous dialog and then click on the "
-                           "\"<b>Auto Detect</b>\" button.</qt>");
-
-    KMessageBox::detailedSorry( this, msg, details,
-                                i18nc("@title:window", "Automatic Proxy Variable Detection") );
-  }
-}
-
-void KEnvVarProxyDlg::showValue()
-{
-  bool enable = mDlg->cbShowValue->isChecked();
-
-  mDlg->leHttp->setReadOnly (enable);
-  mDlg->leHttps->setReadOnly (enable);
-  mDlg->leFtp->setReadOnly (enable);
-  mDlg->leNoProxy->setReadOnly (enable);
-
-  if (enable)
-  {
-    mDlg->leHttp->setText( mEnvVarsMap["http"].value );
-    mDlg->leHttps->setText( mEnvVarsMap["https"].value );
-    mDlg->leFtp->setText( mEnvVarsMap["ftp"].value );
-    mDlg->leNoProxy->setText( mEnvVarsMap["noProxy"].value );
-  }
-  else
-  {
-    mDlg->leHttp->setText( mEnvVarsMap["http"].name );
-    mDlg->leHttps->setText( mEnvVarsMap["https"].name );
-    mDlg->leFtp->setText( mEnvVarsMap["ftp"].name );
-    mDlg->leNoProxy->setText( mEnvVarsMap["noProxy"].name );
-  }
-}
-
-bool KEnvVarProxyDlg::validate()
-{
-  int count = 0;
-
-  QString value = mEnvVarsMap["http"].value;
-  if ( !value.isEmpty() )
-    count++;
-
-  value = mEnvVarsMap["https"].value;
-  if ( !value.isEmpty() )
-    count++;
-
-  value = mEnvVarsMap["ftp"].value;
-  if ( !value.isEmpty() )
-    count++;
-
-  m_bHasValidData = (count > 0);
-
-  return m_bHasValidData;
-}
-
-void KEnvVarProxyDlg::accept()
-{
-  if ( !validate() )
-  {
-    setHighLight (mDlg->lbHttp, true);
-    setHighLight (mDlg->lbHttps, true);
-    setHighLight (mDlg->lbFtp, true);
-
-    QString msg = i18n("You must specify at least one valid proxy "
-                       "environment variable.");
-
-    QString details = i18n("<qt>Make sure you entered the actual environment "
-                           "variable name rather than its value. For "
-                           "example, if the environment variable is <br /><b>"
-                           "HTTP_PROXY=http://localhost:3128</b><br /> you need "
-                           "to enter <b>HTTP_PROXY</b> here instead of the "
-                           "actual value http://localhost:3128.</qt>");
-
-    KMessageBox::detailedError( this, msg, details,
-                                 i18nc("@title:window", "Invalid Proxy Setup") );
-    return;
-  }
-
-  KDialog::accept();
-}
-
-#include "kenvvarproxydlg.moc"
diff --git a/konqueror/settings/kio/kenvvarproxydlg.h b/konqueror/settings/kio/kenvvarproxydlg.h
deleted file mode 100644
index c7d2f5f..0000000
--- a/konqueror/settings/kio/kenvvarproxydlg.h
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
-   kenvvarproxydlg.h - Base dialog box for proxy configuration
-
-   Copyright (C) 2001- Dawit Alemayehu <adawit at kde.org>
-
-   This library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU General Public
-   License (GPL) version 2 as published by the Free Software
-   Foundation.
-
-   This library 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
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this library; see the file COPYING.LIB.  If not, write to
-   the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-   Boston, MA 02110-1301, USA.
-*/
-#ifndef KENVVARPROXYDLG_H
-#define KENVVARPROXYDLG_H
-
-#include <QtCore/QMap>
-
-#include "kproxydlgbase.h"
-#include "ui_envvarproxy.h"
-
-class EnvVarProxyDlgUI : public QWidget, public Ui::EnvVarProxyDlgUI
-{
-public:
-  EnvVarProxyDlgUI( QWidget *parent ) : QWidget( parent ) {
-    setupUi( this );
-  }
-};
-
-
-class KEnvVarProxyDlg : public KProxyDialogBase
-{
-    Q_OBJECT
-
-public:
-    explicit KEnvVarProxyDlg( QWidget* parent = 0, const char* name = 0 );
-    ~KEnvVarProxyDlg();
-
-    virtual const KProxyData data() const;
-    virtual void setProxyData( const KProxyData &data );
-
-protected Q_SLOTS:
-    virtual void accept();
-
-    void showValue();
-    void verifyPressed();
-    void autoDetectPressed();
-
-protected:
-    void init();
-    bool validate();
-    
-private:
-    EnvVarProxyDlgUI* mDlg;
-
-    struct EnvVarPair {
-      QString name;
-      QString value;
-    };
-
-    QMap<QString, EnvVarPair> mEnvVarsMap;
-};
-
-#endif // KENVVARPROXYDLG_H
diff --git a/konqueror/settings/kio/kmanualproxydlg.cpp b/konqueror/settings/kio/kmanualproxydlg.cpp
deleted file mode 100644
index 6760957..0000000
--- a/konqueror/settings/kio/kmanualproxydlg.cpp
+++ /dev/null
@@ -1,496 +0,0 @@
-/*
-   kmanualproxydlg.cpp - Proxy configuration dialog
-
-   Copyright (C) 2001-2004 Dawit Alemayehu <adawit at kde.org>
-
-   This library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU General Public
-   License (GPL) version 2 as published by the Free Software
-   Foundation.
-
-   This library 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
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this library; see the file COPYING.LIB.  If not, write to
-   the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-   Boston, MA 02110-1301, USA.
-*/
-
-// Own
-#include "kmanualproxydlg.h"
-
-// Qt
-#include <QtGui/QCheckBox>
-#include <QtGui/QLabel>
-#include <QtGui/QLayout>
-#include <QtGui/QPushButton>
-
-// KDE
-#include <kdebug.h>
-#include <kiconloader.h>
-#include <kicontheme.h>
-#include <kinputdialog.h>
-#include <kio/ioslave_defaults.h>
-#include <klineedit.h>
-#include <klistwidget.h>
-#include <klocale.h>
-#include <kmessagebox.h>
-#include <knuminput.h>
-#include <kurifilter.h>
-
-
-
-KManualProxyDlg::KManualProxyDlg( QWidget* parent, const char* name )
-                :KProxyDialogBase( parent, name, true,
-                                   i18nc("@title:window", "Manual Proxy Configuration") )
-{
-    mDlg = new ManualProxyDlgUI (this);
-    setMainWidget(mDlg);
-    mDlg->pbCopyDown->setIcon( KIcon("go-down") );
-    QSizePolicy sizePolicy( QSizePolicy::Fixed, QSizePolicy::Fixed );
-    sizePolicy.setHeightForWidth( mDlg->pbCopyDown->sizePolicy().hasHeightForWidth() );
-    mDlg->pbCopyDown->setSizePolicy( sizePolicy );
-
-    init();
-}
-
-void KManualProxyDlg::init()
-{
-    mDlg->sbHttp->setRange( 0, MAX_PORT_VALUE );
-    mDlg->sbHttps->setRange( 0, MAX_PORT_VALUE );
-    mDlg->sbFtp->setRange( 0, MAX_PORT_VALUE );
-
-    connect( mDlg->pbNew, SIGNAL(clicked()), SLOT(newPressed()) );
-    connect( mDlg->pbChange, SIGNAL(clicked()), SLOT(changePressed()) );
-    connect( mDlg->pbDelete, SIGNAL(clicked()), SLOT(deletePressed()) );
-    connect( mDlg->pbDeleteAll, SIGNAL(clicked()), SLOT(deleteAllPressed()) );
-
-    connect( mDlg->lbExceptions, SIGNAL(itemSelectionChanged()), SLOT(updateButtons()) );
-    connect( mDlg->lbExceptions, SIGNAL(itemDoubleClicked(QListWidgetItem*)), SLOT(changePressed()));
-
-    connect( mDlg->cbSameProxy, SIGNAL(toggled(bool)), SLOT(sameProxy(bool)) );
-    connect( mDlg->pbCopyDown, SIGNAL(clicked()), SLOT(copyDown()) );
-
-    connect( mDlg->leHttp, SIGNAL(textChanged(QString)), SLOT(textChanged(QString)) );
-    connect( mDlg->sbHttp, SIGNAL(valueChanged(int)), SLOT(valueChanged(int)) );
-
-    connect( this, SIGNAL(okClicked()), this, SLOT(slotOk()));
-}
-
-void KManualProxyDlg::setProxyData( const KProxyData &data )
-{
-    KUrl url;
-
-    // Set the HTTP proxy...
-    if (!isValidURL(data.proxyList["http"], &url))
-        mDlg->sbHttp->setValue( DEFAULT_PROXY_PORT );
-    else
-    {
-        int port = url.port();
-        if ( port <= 0 )
-            port = DEFAULT_PROXY_PORT;
-
-        url.setPort( -1 );
-        mDlg->leHttp->setText( url.url() );
-        mDlg->sbHttp->setValue( port );
-    }
-
-    bool useSameProxy = (!mDlg->leHttp->text().isEmpty () &&
-                         data.proxyList["http"] == data.proxyList["https"] &&
-                         data.proxyList["http"] == data.proxyList["ftp"]);
-
-    mDlg->cbSameProxy->setChecked ( useSameProxy );
-
-    if ( useSameProxy )
-    {
-      mDlg->leHttps->setText ( mDlg->leHttp->text() );
-      mDlg->leFtp->setText ( mDlg->leHttp->text() );
-      mDlg->sbHttps->setValue( mDlg->sbHttp->value() );
-      mDlg->sbFtp->setValue( mDlg->sbHttp->value() );
-
-      sameProxy ( true );
-    }
-    else
-    {
-      // Set the HTTPS proxy...
-      if( !isValidURL( data.proxyList["https"], &url ) )
-          mDlg->sbHttps->setValue( DEFAULT_PROXY_PORT );
-      else
-      {
-          int port = url.port();
-          if ( port <= 0 )
-              port = DEFAULT_PROXY_PORT;
-
-          url.setPort( -1 );
-          mDlg->leHttps->setText( url.url() );
-          mDlg->sbHttps->setValue( port );
-      }
-
-      // Set the FTP proxy...
-      if( !isValidURL( data.proxyList["ftp"], &url ) )
-          mDlg->sbFtp->setValue( DEFAULT_PROXY_PORT );
-      else
-      {
-          int port = url.port();
-          if ( port <= 0 )
-              port = DEFAULT_PROXY_PORT;
-
-          url.setPort( -1 );
-          mDlg->leFtp->setText( url.url() );
-          mDlg->sbFtp->setValue( port );
-      }
-    }
-
-    QStringList::ConstIterator it = data.noProxyFor.begin();
-    for( ; it != data.noProxyFor.end(); ++it )
-    {
-      // "no_proxy" is a keyword used by the environment variable
-      // based configuration. We ignore it here as it is not applicable...
-      if ((*it).toLower() != "no_proxy" && !(*it).isEmpty())
-      {
-        // Validate the NOPROXYFOR entries and use only hostnames if the entry is
-        // a valid or legitimate URL. NOTE: needed to catch manual manipulation
-        // of the proxy config files...
-        if( isValidURL( *it ) || ((*it).length() >= 3 && (*it).startsWith('.')) )
-          mDlg->lbExceptions->addItem( *it );
-      }
-    }
-
-    mDlg->cbReverseProxy->setChecked( data.useReverseProxy );
-}
-
-const KProxyData KManualProxyDlg::data() const
-{
-    KProxyData data;
-
-    if (!m_bHasValidData)
-      return data;
-
-    data.proxyList["http"] = urlFromInput( mDlg->leHttp, mDlg->sbHttp );
-
-    if ( mDlg->cbSameProxy->isChecked () )
-    {
-        data.proxyList["https"] = data.proxyList["http"];
-        data.proxyList["ftp"] = data.proxyList["http"];
-    }
-    else
-    {
-        data.proxyList["https"] = urlFromInput( mDlg->leHttps, mDlg->sbHttps );
-        data.proxyList["ftp"] = urlFromInput( mDlg->leFtp, mDlg->sbFtp );
-    }
-
-    if ( mDlg->lbExceptions->count() )
-    {
-        for ( int rowIndex = 0 ; rowIndex < mDlg->lbExceptions->count() ; rowIndex++ ) {
-            data.noProxyFor << mDlg->lbExceptions->item(rowIndex)->text();
-        }
-    }
-
-    data.type = KProtocolManager::ManualProxy;
-    data.useReverseProxy = mDlg->cbReverseProxy->isChecked();
-
-    return data;
-}
-
-void KManualProxyDlg::sameProxy( bool enable )
-{
-    mDlg->leHttps->setEnabled (!enable );
-    mDlg->leFtp->setEnabled (!enable );
-    mDlg->sbHttps->setEnabled (!enable );
-    mDlg->sbFtp->setEnabled (!enable );
-    mDlg->pbCopyDown->setEnabled( !enable );
-
-    if (enable)
-    {
-      mOldFtpText = mDlg->leFtp->text();
-      mOldHttpsText = mDlg->leHttps->text();
-
-      mOldFtpPort = mDlg->sbFtp->value();
-      mOldHttpsPort = mDlg->sbHttps->value();
-
-      int port = mDlg->sbHttp->value();
-      QString text = mDlg->leHttp->text();
-
-      mDlg->leFtp->setText (text);
-      mDlg->leHttps->setText (text);
-
-      mDlg->sbFtp->setValue (port);
-      mDlg->sbHttps->setValue (port);
-
-      if (mDlg->lbHttps->font().bold())
-        setHighLight( mDlg->lbHttps, false );
-
-      if (mDlg->lbFtp->font().bold())
-        setHighLight( mDlg->lbFtp, false );
-    }
-    else
-    {
-      mDlg->leFtp->setText (mOldFtpText);
-      mDlg->leHttps->setText (mOldHttpsText);
-
-      mDlg->sbFtp->setValue (mOldFtpPort);
-      mDlg->sbHttps->setValue (mOldHttpsPort);
-    }
-}
-
-bool KManualProxyDlg::validate()
-{
-    KUrl filteredURL;
-    unsigned short count = 0;
-
-    if ( isValidURL( mDlg->leHttp->text(), &filteredURL ) )
-    {
-        mDlg->leHttp->setText( filteredURL.url() );
-        count++;
-    }
-    else
-        setHighLight( mDlg->lbHttp, true );
-
-    if ( !mDlg->cbSameProxy->isChecked () )
-    {
-        if ( isValidURL( mDlg->leHttps->text(), &filteredURL ) )
-        {
-            mDlg->leHttps->setText( filteredURL.url() );
-            count++;
-        }
-        else
-            setHighLight( mDlg->lbHttps, true );
-
-        if ( isValidURL( mDlg->leFtp->text(), &filteredURL ) )
-        {
-            mDlg->leFtp->setText( filteredURL.url() );
-            count++;
-        }
-        else
-            setHighLight( mDlg->lbFtp, true );
-    }
-
-    if ( count == 0 )
-    {
-        showErrorMsg( i18nc("@title:window", "Invalid Proxy Setting"),
-                      i18n("One or more of the specified proxy settings are "
-                           "invalid. The incorrect entries are highlighted.") );
-    }
-
-    return (count > 0);
-}
-
-void KManualProxyDlg::textChanged(const QString& text)
-{
-    if (!mDlg->cbSameProxy->isChecked())
-        return;
-
-    mDlg->leFtp->setText( text );
-    mDlg->leHttps->setText( text );
-}
-
-void KManualProxyDlg::valueChanged(int value)
-{
-    if (!mDlg->cbSameProxy->isChecked())
-        return;
-
-    mDlg->sbFtp->setValue (value);
-    mDlg->sbHttps->setValue (value);
- }
-
-void KManualProxyDlg::copyDown()
-{
-    int action = -1;
-
-    if ( !mDlg->leHttp->text().isEmpty() )
-        action += 4;
-    else if ( !mDlg->leHttps->text().isEmpty() )
-        action += 3;
-
-    switch ( action )
-    {
-      case 3:
-        mDlg->leHttps->setText( mDlg->leHttp->text() );
-        mDlg->sbHttps->setValue( mDlg->sbHttp->value() );
-        mDlg->leFtp->setText( mDlg->leHttp->text() );
-        mDlg->sbFtp->setValue( mDlg->sbHttp->value() );
-        break;
-      case 2:
-        mDlg->leFtp->setText( mDlg->leHttps->text() );
-        mDlg->sbFtp->setValue( mDlg->sbHttps->value() );
-        break;
-      case 1:
-      case 0:
-      default:
-        break;
-    }
-}
-
-void KManualProxyDlg::slotOk()
-{
-    if ( m_bHasValidData || validate() )
-      m_bHasValidData = true;
-}
-
-bool KManualProxyDlg::handleDuplicate( const QString& site )
-{
-    for ( int rowIndex = 0 ; rowIndex < mDlg->lbExceptions->count() ; rowIndex++ )
-    {
-        QListWidgetItem* item = mDlg->lbExceptions->item(rowIndex);
-
-        if ( item->text().lastIndexOf( site ) != -1 &&
-             item != mDlg->lbExceptions->currentItem() )
-        {
-            QString msg = i18n("You entered a duplicate address. "
-                               "Please try again.");
-            QString details = i18n("<qt><center><b>%1</b></center> "
-                                   "is already in the list.</qt>", site);
-            KMessageBox::detailedError( this, msg, details, i18nc("@title:window", "Duplicate Entry") );
-            return true;
-        }
-    }
-    return false;
-}
-
-void KManualProxyDlg::newPressed()
-{
-  QString result;
-  if( getException(result, i18nc("@title:window", "New Exception")) && !handleDuplicate(result) )
-    mDlg->lbExceptions->addItem( result );
-}
-
-void KManualProxyDlg::changePressed()
-{
-  QString result;
-  if( getException( result, i18nc("@title:window", "Change Exception"),
-                    mDlg->lbExceptions->currentItem()->text() ) &&
-      !handleDuplicate( result ) )
-      mDlg->lbExceptions->currentItem()->setText(result);
-}
-
-void KManualProxyDlg::deletePressed()
-{
-    delete mDlg->lbExceptions->takeItem( mDlg->lbExceptions->currentRow() );
-    if(mDlg->lbExceptions->currentItem())
-       mDlg->lbExceptions->currentItem()->setSelected(true);
-    updateButtons();
-}
-
-void KManualProxyDlg::deleteAllPressed()
-{
-    mDlg->lbExceptions->clear();
-    updateButtons();
-}
-
-void KManualProxyDlg::updateButtons()
-{
-    bool hasItems = mDlg->lbExceptions->count() > 0;
-    bool itemSelected = (hasItems && mDlg->lbExceptions->currentItem()!=0);
-
-    mDlg->pbDeleteAll->setEnabled( hasItems );
-    mDlg->pbDelete->setEnabled( itemSelected );
-    mDlg->pbChange->setEnabled( itemSelected );
-}
-
-QString KManualProxyDlg::urlFromInput(const KLineEdit* edit,
-                                      const KIntSpinBox* spin) const
-{
-  if (!edit || edit->text().isEmpty())
-    return QString();
-
-  KUrl u( edit->text() );
-
-  if (spin)
-    u.setPort( spin->value() );
-
-  return u.url();
-}
-
-bool KManualProxyDlg::isValidURL( const QString& _url, KUrl* result ) const
-{
-    KUrl url (_url);
-
-    QStringList filters;
-    filters << "kshorturifilter" << "localdomainurifilter";
-
-    // If the typed URL is malformed, and the filters cannot filter it
-    // then it must be an invalid entry.
-    if( !(url.isValid() && KUriFilter::self()->filterUri(url, filters) &&
-        url.hasHost()) )
-      return false;
-
-    QString host (url.host());
-
-    // We only check for a relevant subset of characters that are
-    // not allowed in <authority> component of a URL.
-    if ( host.contains ('*') || host.contains (' ') || host.contains ('?') )
-      return false;
-
-    if ( result )
-      *result = url;
-
-    return true;
-}
-
-void KManualProxyDlg::showErrorMsg( const QString& caption,
-                                    const QString& message )
-{
-  QString cap( caption );
-  QString msg( message );
-
-  if ( cap.isEmpty() )
-    cap = i18nc("@title:window", "Invalid Entry");
-
-  if ( msg.isEmpty() )
-    msg = i18n("The address you have entered is not valid.");
-
-  QString details = i18n("<qt>Make sure none of the addresses or URLs you "
-                          "specified contain invalid or wildcard characters "
-                          "such as spaces, asterisks (*), or question marks(?).<br /><br />"
-                          "<u>Examples of VALID entries:</u><br />"
-                          "<code>http://mycompany.com, 192.168.10.1, "
-                          "mycompany.com, localhost, http://localhost</code><br /><br />"
-                          "<u>Examples of INVALID entries:</u><br />"
-                          "<code>http://my company.com, http:/mycompany,com "
-                          "file:/localhost</code></qt>");
-
-  KMessageBox::detailedError( this, msg, details, cap );
-}
-
-bool KManualProxyDlg::getException ( QString& result,
-                                     const QString& caption,
-                                     const QString& value )
-{
-    QString label;
-
-    // Specify the appropriate message...
-    if ( mDlg->cbReverseProxy->isChecked() )
-      label = i18n("Enter the URL or address that should use the above proxy "
-                   "settings:");
-    else
-      label = i18n("Enter the address or URL that should be excluded from "
-                   "using the above proxy settings:");
-
-    QString whatsThis = i18n("<qt>Enter a valid address or URL.<br /><br />"
-                            "<b><u>NOTE:</u></b> Wildcard matching such as "
-                            "<code>*.kde.org</code> is not supported. If you want "
-                            "to match any host in the <code>.kde.org</code> domain, "
-                            "e.g. <code>printing.kde.org</code>, then simply enter "
-                            "<code>.kde.org</code>.</qt>");
-
-    bool ok;
-    result = KInputDialog::getText( caption, label, value, &ok, this,
-                                    0, QString(), whatsThis );
-
-    // If the user pressed cancel, do nothing...
-    if (!ok)
-      return false;
-
-    // If the typed URL is malformed, and the filters cannot filter it
-    // then it must be an invalid entry,
-    if( isValidURL(result) || (result.length() >= 3 && result.startsWith('.')))
-      return true;
-
-    showErrorMsg();
-    return false;
-}
-
-#include "kmanualproxydlg.moc"
diff --git a/konqueror/settings/kio/kmanualproxydlg.h b/konqueror/settings/kio/kmanualproxydlg.h
deleted file mode 100644
index 4efa63c..0000000
--- a/konqueror/settings/kio/kmanualproxydlg.h
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
-   kmanualproxydlg.h - Base dialog box for proxy configuration
-
-   Copyright (C) 2001-2004 Dawit Alemayehu <adawit at kde.org>
-
-   This library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU General Public
-   License (GPL) version 2 as published by the Free Software
-   Foundation.
-
-   This library 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
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this library; see the file COPYING.LIB.  If not, write to
-   the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-   Boston, MA 02110-1301, USA.
-*/
-
-#ifndef KMANUALPROXYDLG_H
-#define KMANUALPROXYDLG_H
-
-#include "kproxydlgbase.h"
-#include "ui_manualproxy.h"
-class KIntSpinBox;
-class KLineEdit;
-
-class ManualProxyDlgUI : public QWidget, public Ui::ManualProxyDlgUI
-{
-public:
-  ManualProxyDlgUI( QWidget *parent ) : QWidget( parent ) {
-    setupUi( this );
-  }
-};
-
-
-class KManualProxyDlg : public KProxyDialogBase
-{
-  Q_OBJECT
-  
-public:
-  explicit KManualProxyDlg( QWidget* parent = 0, const char* name = 0 );
-  ~KManualProxyDlg() {}
-  
-  virtual void setProxyData( const KProxyData &data );
-  virtual const KProxyData data() const;
-  
-protected:
-  void init();
-  bool validate();
-  
-protected Q_SLOTS:
-  virtual void slotOk();
-  
-  void copyDown();
-  void sameProxy( bool );
-  void valueChanged (int value);
-  void textChanged (const QString&);
-  
-  void newPressed();
-  void updateButtons();
-  void changePressed();
-  void deletePressed();
-  void deleteAllPressed();
-  
-private:
-  QString urlFromInput( const KLineEdit* edit, const KIntSpinBox* spin ) const;
-  bool isValidURL( const QString&, KUrl* = 0 ) const;
-  bool handleDuplicate( const QString& );
-  bool getException ( QString&, const QString&,
-                      const QString& value = QString() );
-  void showErrorMsg( const QString& caption = QString(),
-                     const QString& message = QString() );
-  
-private:
-  ManualProxyDlgUI* mDlg;
-
-  int mOldFtpPort;
-  int mOldHttpsPort;
-  QString mOldFtpText;
-  QString mOldHttpsText;
-};
-
-#endif // KMANUALPROXYDLG_H
diff --git a/konqueror/settings/kio/kproxydlg.cpp b/konqueror/settings/kio/kproxydlg.cpp
index 2f512ce..2de2e23 100644
--- a/konqueror/settings/kio/kproxydlg.cpp
+++ b/konqueror/settings/kio/kproxydlg.cpp
@@ -1,7 +1,7 @@
 /*
    kproxydlg.cpp - Proxy configuration dialog
 
-   Copyright (C) 2001- Dawit Alemayehu <adawit at kde.org>
+   Copyright (C) 2001, 2011 Dawit Alemayehu <adawit at kde.org>
 
    This library is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public
@@ -22,293 +22,488 @@
 // Own
 #include "kproxydlg.h"
 
-// Qt
-#include <QtCore/QRegExp>
-#include <QtGui/QBoxLayout>
-#include <QtGui/QCheckBox>
-#include <QtGui/QLabel>
-#include <QtGui/QLayout>
-#include <QtGui/QRadioButton>
-#include <QtGui/QTabWidget>
+// Local
+#include "ksaveioconfig.h"
 
 // KDE
 #include <kpluginfactory.h>
 #include <klineedit.h>
 #include <klocale.h>
 #include <kmessagebox.h>
+#include <kurifilter.h>
+#include <kdebug.h>
 
-// Local
-#include "kenvvarproxydlg.h"
-#include "kmanualproxydlg.h"
-#include "ksaveioconfig.h"
+// Qt
+#include <QtGui/QLabel>
+#include <QtGui/QRadioButton>
+#include <QtGui/QLineEdit>
+#include <QtGui/QSpinBox>
 
-K_PLUGIN_FACTORY_DECLARATION(KioConfigFactory)
 
-KProxyDialog::KProxyDialog(QWidget *parent, const QVariantList &args)
-    : KCModule(KioConfigFactory::componentData(), parent)
+#define QL1C(x)         QLatin1Char(x)
+#define QL1S(x)         QLatin1String(x)
+
+#define ENV_HTTP_PROXY    QL1S("HTTP_PROXY,http_proxy,HTTPPROXY,httpproxy,PROXY,proxy")
+#define ENV_HTTPS_PROXY   QL1S("HTTPS_PROXY,https_proxy,HTTPSPROXY,httpsproxy,PROXY,proxy")
+#define ENV_FTP_PROXY     QL1S("FTP_PROXY,ftp_proxy,FTPPROXY,ftpproxy,PROXY,proxy")
+#define ENV_SOCKS_PROXY   QL1S("SOCKS_PROXY,socks_proxy,SOCKSPROXY,socksproxy,PROXY,proxy")
+#define ENV_NO_PROXY      QL1S("NO_PROXY,no_proxy")
+
+K_PLUGIN_FACTORY_DECLARATION (KioConfigFactory)
+
+
+class InputValidator : public QValidator
 {
-  Q_UNUSED(args);
-  mUi.setupUi(this);
+public:
+    State validate(QString& input, int& pos) const {
+        const QChar ch = input.at((pos > 0 ? pos - 1 : pos));
+        if (ch.isSpace())
+            return Invalid;
 
-  // signals and slots connections
-  connect( mUi.rbNoProxy, SIGNAL(toggled(bool)),
-            SLOT(slotUseProxyChanged()) );
+        return Acceptable;
+    }
+};
 
-  connect( mUi.rbAutoDiscover, SIGNAL(toggled(bool)),
-            SLOT(slotChanged()) );
-  connect( mUi.rbAutoScript, SIGNAL(toggled(bool)),
-            SLOT(slotChanged()) );
 
-  connect( mUi.rbPrompt, SIGNAL(toggled(bool)),
-            SLOT(slotChanged()) );
-  connect( mUi.rbPresetLogin, SIGNAL(toggled(bool)),
-            SLOT(slotChanged()) );
+static QString manualProxyToText(const QLineEdit* edit, const QSpinBox* spinBox, const QChar& separator)
+{
+    QString value;
 
-  connect( mUi.cbPersConn, SIGNAL(toggled(bool)),
-            SLOT(slotChanged()) );
+    value = edit->text();
+    value += separator;
+    value +=  QString::number(spinBox->value());
 
-  connect( mUi.location, SIGNAL(textChanged(QString)),
-            SLOT(slotChanged()) );
+    return value;
+}
 
-  connect( mUi.pbEnvSetup, SIGNAL(clicked()), SLOT(setupEnvProxy()) );
-  connect( mUi.pbManSetup, SIGNAL(clicked()), SLOT(setupManProxy()) );
+static void setManualProxyFromText(const QString& value, QLineEdit* edit, QSpinBox* spinBox)
+{
+    if (value.isEmpty())
+        return;
 
+    const QStringList values = value.split(QL1S(" "));
+    edit->setText(values.at(0));
+    bool ok = false;
+    const int num = values.at(1).toInt(&ok);
+    if (ok) {
+        spinBox->setValue(num);
+    }
 }
 
-KProxyDialog::~KProxyDialog()
+static void showSystemProxyUrl(QLineEdit* edit, QString* value)
 {
+    Q_ASSERT(edit);
+    Q_ASSERT(value);
+
+    *value = edit->text();
+    edit->setEnabled(false);
+    const QByteArray envVar(edit->text().toUtf8());
+    edit->setText(QString::fromUtf8(qgetenv(envVar.constData())));
 }
 
-void KProxyDialog::load()
+static bool autoDetectSystemProxy(QLineEdit* edit, const QString& envVarStr)
+{
+    const QStringList envVars = envVarStr.split(QL1S(","), QString::SkipEmptyParts);
+    Q_FOREACH (const QString & envVar, envVars) {
+        const QByteArray envVarUtf8(envVar.toUtf8());
+        if (!qgetenv(envVarUtf8.constData()).isEmpty()) {
+            edit->setText(envVarStr);
+            return true;
+        }
+    }
+    return false;
+}
+
+static void extractProxyUrlFromInput(QString* proxyStr, KProxyDialog::DisplayUrlFlags* flags,
+                                     const QLineEdit* edit, const QSpinBox* spinBox,
+                                     KProxyDialog::DisplayUrlFlag flag = KProxyDialog::HideNone)
 {
-  mDefaultData = false;
+    Q_ASSERT(edit);
+    Q_ASSERT(spinBox);
+    Q_ASSERT(proxyStr);
 
-  KProtocolManager proto;
-  bool useProxy = proto.useProxy();
-  mData.type = proto.proxyType();
-  mData.proxyList["http"] = proto.proxyFor( "http" );
-  mData.proxyList["https"] = proto.proxyFor( "https" );
-  mData.proxyList["ftp"] = proto.proxyFor( "ftp" );
-  mData.proxyList["script"] = proto.proxyConfigScript();
-  mData.useReverseProxy = proto.useReverseProxy();
-  mData.noProxyFor = proto.noProxyFor().split( QRegExp("[',''\t'' ']"), QString::SkipEmptyParts);
+    proxyStr->clear();
 
-  mUi.gbAuth->setEnabled( useProxy );
-  mUi.gbOptions->setEnabled( useProxy );
+    if (flags && !edit->text().contains("://")) {
+        *flags |= flag;
+    }
 
-  mUi.cbPersConn->setChecked( proto.persistentProxyConnection() );
+    KUriFilterData data;
+    data.setData(edit->text());
 
-  if ( !mData.proxyList["script"].isEmpty() )
-    mUi.location->lineEdit()->setText( mData.proxyList["script"] );
+    if (KUriFilter::self()->filterUri(data, QStringList() << QL1S("kshorturifilter"))) {
+        KUrl url = data.uri();
+        const int portNum = (spinBox->value() > 0 ? spinBox->value() : url.port());
+        url.setPort(-1);
 
-  switch ( mData.type )
-  {
-    case KProtocolManager::WPADProxy:
-      mUi.rbAutoDiscover->setChecked( true );
-      break;
-    case KProtocolManager::PACProxy:
-      mUi.rbAutoScript->setChecked( true );
-      break;
-    case KProtocolManager::ManualProxy:
-      mUi.rbManual->setChecked( true );
-      break;
-    case KProtocolManager::EnvVarProxy:
-      mUi.rbEnvVar->setChecked( true );
-      break;
-    case KProtocolManager::NoProxy:
-    default:
-      mUi.rbNoProxy->setChecked( true );
-      break;
-  }
-
-  switch( proto.proxyAuthMode() )
-  {
-    case KProtocolManager::Prompt:
-      mUi.rbPrompt->setChecked( true );
-      break;
-    case KProtocolManager::Automatic:
-      mUi.rbPresetLogin->setChecked( true );
-    default:
-      break;
-  }
+        *proxyStr = url.url();
+        *proxyStr += QL1C(' ');
+        if (portNum > -1) {
+            *proxyStr += QString::number(portNum);
+        }
+    }
 }
 
-void KProxyDialog::save()
+static void setProxyInformation(const QString& value,
+                                int proxyType,
+                                QLineEdit* manEdit,
+                                QLineEdit* sysEdit,
+                                QSpinBox* spinBox ,
+                                KProxyDialog::DisplayUrlFlag flag)
 {
-  bool updateProxyScout = false;
-
-  if (mDefaultData)
-    mData.reset ();
-
-  if ( mUi.rbNoProxy->isChecked() )
-  {
-    KSaveIOConfig::setProxyType( KProtocolManager::NoProxy );
-  }
-  else
-  {
-    if ( mUi.rbAutoDiscover->isChecked() )
-    {
-      KSaveIOConfig::setProxyType( KProtocolManager::WPADProxy );
-      updateProxyScout = true;
+    if (value.isEmpty()) {
+        return;
     }
-    else if ( mUi.rbAutoScript->isChecked() )
-    {
-      KUrl u( mUi.location->lineEdit()->text() );
-
-      if ( !u.isValid() )
-      {
-        showInvalidMessage( i18n("The address of the automatic proxy "
-                                 "configuration script is invalid. Please "
-                                 "correct this problem before proceeding. "
-                                 "Otherwise, your changes will be "
-                                 "ignored.") );
+
+    const bool isSysProxy = (!value.contains(QL1C('.'))
+                             && !value.contains(QL1C(','))
+                             && !value.contains(QL1S("://")));
+
+    if (proxyType == KProtocolManager::EnvVarProxy || isSysProxy) {
+#if defined(Q_OS_LINUX) || defined (Q_OS_UNIX)
+            sysEdit->setText(value);
+#endif
         return;
-      }
-      else
-      {
-        KSaveIOConfig::setProxyType( KProtocolManager::PACProxy );
-        mData.proxyList["script"] = u.url();
-        updateProxyScout = true;
-      }
     }
-    else if ( mUi.rbManual->isChecked() )
-    {
-      if ( mData.type != KProtocolManager::ManualProxy )
-      {
-        // Let's try a bit harder to determine if the previous
-        // proxy setting was indeed a manual proxy
-        KUrl u ( mData.proxyList["http"] );
-        bool validProxy = (u.isValid() && u.port() > 0);
-        u = mData.proxyList["https"];
-        validProxy = validProxy || (u.isValid() && u.port() > 0);
-        u = mData.proxyList["ftp"];
-        validProxy = validProxy || (u.isValid() && u.port() > 0);
-
-        if (!validProxy)
-        {
-          showInvalidMessage();
-          return;
+
+    if (spinBox) {
+        KUrl url;
+        int portNum = -1;
+        const int index = value.lastIndexOf(QL1C(' '));
+
+        if (index > 0) {
+            bool ok = false;
+            portNum = value.mid(index+1).toInt(&ok);
+            if (!ok) {
+                portNum = -1;
+            }
+            url = value.left(index).trimmed();
+        } else {
+            url = value.trimmed();
         }
 
-        mData.type = KProtocolManager::ManualProxy;
-      }
+        if (!url.isValid()) {
+            return;
+        }
 
-      KSaveIOConfig::setProxyType( KProtocolManager::ManualProxy );
-    }
-    else if ( mUi.rbEnvVar->isChecked() )
-    {
-      if ( mData.type != KProtocolManager::EnvVarProxy )
-      {
-        showInvalidMessage();
+        if (portNum == -1 && url.port() > -1) {
+            portNum = url.port();
+        }
+
+        url.setPort(-1);
+        url.setUser(QString());
+        url.setPass(QString());
+        url.setPath(QString());
+
+        manEdit->setText(((KSaveIOConfig::proxyDisplayUrlFlags() & flag) ? url.host(): url.url()));
+        if (spinBox && portNum > -1) {
+            spinBox->setValue(portNum);
+        }
         return;
-      }
+    }
+
+    manEdit->setText(value); // Manual proxy exception...
+}
+
+KProxyDialog::KProxyDialog(QWidget* parent, const QVariantList& args)
+    : KCModule(KioConfigFactory::componentData(), parent)
+{
+    Q_UNUSED(args);
+    mUi.setupUi(this);
+
+    mUi.systemProxyGroupBox->setVisible(false);
+    mUi.manualProxyGroupBox->setVisible(false);
+    mUi.autoDetectButton->setVisible(false);
+    mUi.proxyConfigScriptGroupBox->setVisible(false);
+
+    InputValidator* v = new InputValidator;
+    mUi.proxyScriptUrlRequester->lineEdit()->setValidator(v);
+    mUi.manualProxyHttpEdit->setValidator(v);
+    mUi.manualProxyHttpsEdit->setValidator(v);
+    mUi.manualProxyFtpEdit->setValidator(v);
+    mUi.manualProxySocksEdit->setValidator(v);
+    mUi.manualNoProxyEdit->setValidator(v);
+
+#if defined(Q_OS_LINUX) || defined (Q_OS_UNIX)
+    connect(mUi.systemProxyRadioButton, SIGNAL(toggled(bool)), mUi.systemProxyGroupBox, SLOT(setVisible(bool)));
+#else
+    mUi.autoDetectButton->setVisible(false);
+#endif
+
+    // signals and slots connections
+    connect(mUi.noProxyRadioButton, SIGNAL(clicked()), SLOT(slotChanged()));
+    connect(mUi.autoDiscoverProxyRadioButton, SIGNAL(clicked()), SLOT(slotChanged()));
+    connect(mUi.autoScriptProxyRadioButton, SIGNAL(clicked()), SLOT(slotChanged()));
+    connect(mUi.manualProxyRadioButton, SIGNAL(clicked()), SLOT(slotChanged()));
+    connect(mUi.noProxyRadioButton, SIGNAL(clicked()), SLOT(slotChanged()));
+    connect(mUi.useReverseProxyCheckBox, SIGNAL(clicked()), SLOT(slotChanged()));
+    connect(mUi.useSameProxyCheckBox, SIGNAL(clicked()), SLOT(slotChanged()));
+
+    connect(mUi.proxyScriptUrlRequester, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+
+    connect(mUi.manualProxyHttpEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+    connect(mUi.manualProxyHttpsEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+    connect(mUi.manualProxyFtpEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+    connect(mUi.manualProxySocksEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+    connect(mUi.manualNoProxyEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+
+    connect(mUi.systemProxyHttpEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+    connect(mUi.systemProxyHttpsEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+    connect(mUi.systemProxyFtpEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+    connect(mUi.systemProxySocksEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));
+    connect(mUi.systemNoProxyEdit, SIGNAL(textChanged(QString)), SLOT(slotChanged()));    
+}
+
+KProxyDialog::~KProxyDialog()
+{
+}
+
+void KProxyDialog::load()
+{
+    mProxyMap[QL1S("HttpProxy")] = KProtocolManager::proxyFor(QL1S("http"));
+    mProxyMap[QL1S("HttpsProxy")] = KProtocolManager::proxyFor(QL1S("https"));
+    mProxyMap[QL1S("FtpProxy")] = KProtocolManager::proxyFor(QL1S("ftp"));
+    mProxyMap[QL1S("SocksProxy")] = KProtocolManager::proxyFor(QL1S("socks"));
+    mProxyMap[QL1S("ProxyScript")] = KProtocolManager::proxyConfigScript();
+    mProxyMap[QL1S("NoProxy")] = KProtocolManager::noProxyFor();
+
+    const int proxyType = KProtocolManager::proxyType();
+
+    setProxyInformation(mProxyMap.value(QL1S("HttpProxy")), proxyType, mUi.manualProxyHttpEdit, mUi.systemProxyHttpEdit, mUi.manualProxyHttpSpinBox, HideHttpUrlScheme);
+    setProxyInformation(mProxyMap.value(QL1S("HttpsProxy")), proxyType, mUi.manualProxyHttpsEdit, mUi.systemProxyHttpsEdit, mUi.manualProxyHttpsSpinBox, HideHttpsUrlScheme);
+    setProxyInformation(mProxyMap.value(QL1S("FtpProxy")), proxyType, mUi.manualProxyFtpEdit, mUi.systemProxyFtpEdit, mUi.manualProxyFtpSpinBox, HideFtpUrlScheme);
+    setProxyInformation(mProxyMap.value(QL1S("SocksProxy")), proxyType, mUi.manualProxySocksEdit, mUi.systemProxySocksEdit, mUi.manualProxySocksSpinBox, HideSocksUrlScheme);
+    setProxyInformation(mProxyMap.value(QL1S("NoProxy")), proxyType, mUi.manualNoProxyEdit, mUi.systemNoProxyEdit, 0, HideNone);
+
+    // Check the "Use this proxy server for all protocols" if all the proxy URLs are the same...
+    const QString httpProxy(mUi.manualProxyHttpEdit->text());
+    if (!httpProxy.isEmpty()) {
+        const int httpProxyPort = mUi.manualProxyHttpSpinBox->value();
+        mUi.useSameProxyCheckBox->setChecked(httpProxy == mUi.manualProxyHttpsEdit->text() &&
+                                             httpProxy == mUi.manualProxyFtpEdit->text() &&
+                                             httpProxy == mUi.manualProxySocksEdit->text() &&
+                                             httpProxyPort ==  mUi.manualProxyHttpsSpinBox->value() &&
+                                             httpProxyPort == mUi.manualProxyFtpSpinBox->value() &&
+                                             httpProxyPort == mUi.manualProxySocksSpinBox->value());
+    }
 
-      KSaveIOConfig::setProxyType( KProtocolManager::EnvVarProxy );
+    // Validate and Set the automatic proxy configuration script url.
+    KUrl u (mProxyMap.value(QL1S("ProxyScript")));
+    if (u.isValid() && !u.isEmpty()) {
+        u.setUser (QString());
+        u.setPass (QString());
+        mUi.proxyScriptUrlRequester->setUrl(u);
     }
 
-    if ( mUi.rbPrompt->isChecked() )
-      KSaveIOConfig::setProxyAuthMode( KProtocolManager::Prompt );
-    else if ( mUi.rbPresetLogin->isChecked() )
-      KSaveIOConfig::setProxyAuthMode( KProtocolManager::Automatic );
-  }
+    // Set use reverse proxy checkbox...
+    mUi.useReverseProxyCheckBox->setChecked((!mProxyMap.value(QL1S("NoProxy")).isEmpty()
+                                              && KProtocolManager::useReverseProxy()));
 
-  KSaveIOConfig::setPersistentProxyConnection( mUi.cbPersConn->isChecked() );
+    switch (proxyType) {
+    case KProtocolManager::WPADProxy:
+        mUi.autoDiscoverProxyRadioButton->setChecked(true);
+        break;
+    case KProtocolManager::PACProxy:
+        mUi.autoScriptProxyRadioButton->setChecked(true);
+        break;
+    case KProtocolManager::ManualProxy:
+        mUi.manualProxyRadioButton->setChecked(true);
+        break;
+    case KProtocolManager::EnvVarProxy:
+        mUi.systemProxyRadioButton->setChecked(true);
+        break;
+    case KProtocolManager::NoProxy:
+    default:
+        mUi.noProxyRadioButton->setChecked(true);
+        break;
+    }
+}
+
+void KProxyDialog::save()
+{
+    KProtocolManager::ProxyType proxyType = KProtocolManager::NoProxy;
+    DisplayUrlFlags displayUrlFlags = HideNone;
+
+    if (mUi.manualProxyRadioButton->isChecked()) {
+        proxyType = KProtocolManager::ManualProxy;
+        extractProxyUrlFromInput(&mProxyMap[QL1S("HttpProxy")], &displayUrlFlags, mUi.manualProxyHttpEdit, mUi.manualProxyHttpSpinBox, HideHttpUrlScheme);
+        extractProxyUrlFromInput(&mProxyMap[QL1S("HttpsProxy")], &displayUrlFlags, mUi.manualProxyHttpsEdit, mUi.manualProxyHttpsSpinBox, HideHttpsUrlScheme);
+        extractProxyUrlFromInput(&mProxyMap[QL1S("FtpProxy")], &displayUrlFlags, mUi.manualProxyFtpEdit, mUi.manualProxyFtpSpinBox, HideFtpUrlScheme);
+        extractProxyUrlFromInput(&mProxyMap[QL1S("SocksProxy")], &displayUrlFlags, mUi.manualProxySocksEdit, mUi.manualProxySocksSpinBox, HideSocksUrlScheme);
+        mProxyMap[QL1S("NoProxy")] = mUi.manualNoProxyEdit->text();
+    } else if (mUi.systemProxyRadioButton->isChecked()) {
+        proxyType = KProtocolManager::EnvVarProxy;
+        mProxyMap[QL1S("HttpProxy")] = mUi.systemProxyHttpEdit->text();
+        mProxyMap[QL1S("HttpsProxy")] = mUi.systemProxyHttpsEdit->text();
+        mProxyMap[QL1S("FtpProxy")] = mUi.systemProxyFtpEdit->text();
+        mProxyMap[QL1S("SocksProxy")] = mUi.systemProxySocksEdit->text();
+        mProxyMap[QL1S("NoProxy")] = mUi.systemNoProxyEdit->text();
+    } else if (mUi.autoScriptProxyRadioButton->isChecked()) {
+        proxyType = KProtocolManager::PACProxy;
+        mProxyMap[QL1S("ProxyScript")] = mUi.proxyScriptUrlRequester->text();
+    } else if (mUi.autoDiscoverProxyRadioButton->isChecked()) {
+        proxyType = KProtocolManager::WPADProxy;
+    }
 
-  // Save the common proxy setting...
-  KSaveIOConfig::setProxyFor( "ftp", mData.proxyList["ftp"] );
-  KSaveIOConfig::setProxyFor( "http", mData.proxyList["http"] );
-  KSaveIOConfig::setProxyFor( "https", mData.proxyList["https"] );
+    KSaveIOConfig::setProxyType(proxyType);
+    KSaveIOConfig::setProxyDisplayUrlFlags(displayUrlFlags);
+    KSaveIOConfig::setUseReverseProxy(mUi.useReverseProxyCheckBox->isChecked());
 
-  KSaveIOConfig::setProxyConfigScript( mData.proxyList["script"] );
-  KSaveIOConfig::setUseReverseProxy( mData.useReverseProxy );
-  KSaveIOConfig::setNoProxyFor( mData.noProxyFor.join(",") );
+    // Save the common proxy setting...
+    KSaveIOConfig::setProxyDisplayUrlFlags (displayUrlFlags);
+    KSaveIOConfig::setProxyFor(QL1S("http"), mProxyMap.value(QL1S("HttpProxy")));
+    KSaveIOConfig::setProxyFor(QL1S("https"), mProxyMap.value(QL1S("HttpsProxy")));
+    KSaveIOConfig::setProxyFor(QL1S("ftp"), mProxyMap.value(QL1S("FtpProxy")));
+    KSaveIOConfig::setProxyFor(QL1S("socks"), mProxyMap.value(QL1S("SocksProxy")));
 
+    KSaveIOConfig::setProxyConfigScript (mProxyMap.value(QL1S("ProxyScript")));
+    KSaveIOConfig::setNoProxyFor (mProxyMap.value(QL1S("NoProxy")));
 
-  KSaveIOConfig::updateRunningIOSlaves (this);
-  if ( updateProxyScout )
-    KSaveIOConfig::updateProxyScout( this );
+    KSaveIOConfig::updateRunningIOSlaves (this);
+    if (proxyType == KProtocolManager::PACProxy || proxyType == KProtocolManager::WPADProxy) {
+        KSaveIOConfig::updateProxyScout (this);
+    }
 
-  emit changed( false );
+    emit changed (false);
 }
 
 void KProxyDialog::defaults()
 {
-  mDefaultData = true;
-  mUi.rbNoProxy->setChecked( true );
-  mUi.location->lineEdit()->clear();
-  mUi.cbPersConn->setChecked( false );
+    mUi.noProxyRadioButton->setChecked(true);
+    mUi.proxyScriptUrlRequester->clear();
+
+    mUi.manualProxyHttpEdit->clear();
+    mUi.manualProxyHttpsEdit->clear();
+    mUi.manualProxyFtpEdit->clear();
+    mUi.manualProxySocksEdit->clear();
+    mUi.manualNoProxyEdit->clear();
+
+    mUi.manualProxyHttpSpinBox->setValue(0);
+    mUi.manualProxyHttpsSpinBox->setValue(0);
+    mUi.manualProxyFtpSpinBox->setValue(0);
+    mUi.manualProxySocksSpinBox->setValue(0);
+
+    mUi.systemProxyHttpEdit->clear();
+    mUi.systemProxyHttpsEdit->clear();
+    mUi.systemProxyFtpEdit->clear();
+    mUi.systemProxySocksEdit->clear();
+
+    emit changed (true);
 }
 
-void KProxyDialog::setupManProxy()
+void KProxyDialog::on_autoDetectButton_clicked()
 {
-  KManualProxyDlg dlgManual( this );
-
-  dlgManual.setProxyData( mData );
+    quint8 count = 0;
+    count += (autoDetectSystemProxy(mUi.systemProxyHttpEdit, ENV_HTTP_PROXY) ? 1 : 0);
+    count += (autoDetectSystemProxy(mUi.systemProxyHttpsEdit, ENV_HTTPS_PROXY) ? 1 : 0);
+    count += (autoDetectSystemProxy(mUi.systemProxyFtpEdit, ENV_FTP_PROXY) ? 1 : 0);
+    count += (autoDetectSystemProxy(mUi.systemProxySocksEdit, ENV_SOCKS_PROXY) ? 1 : 0);
+    count += (autoDetectSystemProxy(mUi.systemNoProxyEdit, ENV_NO_PROXY) ? 1 : 0);
+
+    if (count)
+        emit changed (true);
+}
 
-  if ( dlgManual.exec() == QDialog::Accepted )
-  {
-    mData = dlgManual.data();
-    mUi.rbManual->setChecked(true);
-    emit changed( true );
-  }
+void KProxyDialog::on_manualProxyHttpEdit_textChanged(const QString& text)
+{
+    mUi.useSameProxyCheckBox->setEnabled(!text.isEmpty());
 }
 
-void KProxyDialog::setupEnvProxy()
+void KProxyDialog::on_manualNoProxyEdit_textChanged (const QString& text)
 {
-  KEnvVarProxyDlg dlgEnv( this );
+    mUi.useReverseProxyCheckBox->setEnabled(!text.isEmpty());
+}
 
-  dlgEnv.setProxyData( mData );
+void KProxyDialog::on_manualProxyHttpEdit_textEdited(const QString& text)
+{
+    if (!mUi.useSameProxyCheckBox->isChecked()) {
+        return;
+    }
 
-  if ( dlgEnv.exec() == QDialog::Accepted )
-  {
-    mData = dlgEnv.data();
-    mUi.rbEnvVar->setChecked(true);
-    emit changed( true );
-  }
+    mUi.manualProxyHttpsEdit->setText(text);
+    mUi.manualProxyFtpEdit->setText(text);
+    mUi.manualProxySocksEdit->setText(text);
 }
 
-void KProxyDialog::slotChanged()
+void KProxyDialog::on_manualProxyHttpSpinBox_valueChanged (int value)
 {
-  mDefaultData = false;
-  emit changed( true );
+    if (!mUi.useSameProxyCheckBox->isChecked()) {
+        return;
+    }
+
+    mUi.manualProxyHttpsSpinBox->setValue(value);
+    mUi.manualProxyFtpSpinBox->setValue(value);
+    mUi.manualProxySocksSpinBox->setValue(value);
 }
 
-void KProxyDialog::slotUseProxyChanged()
+void KProxyDialog::on_showEnvValueCheckBox_toggled (bool on)
 {
-  mDefaultData = false;
-  bool useProxy = !(mUi.rbNoProxy->isChecked());
-  mUi.gbAuth->setEnabled(useProxy);
-  mUi.gbOptions->setEnabled(useProxy);
-  emit changed( true );
+    if (on) {
+        showSystemProxyUrl(mUi.systemProxyHttpEdit, &mProxyMap[QL1S("EnvVarProxyHttp")]);
+        showSystemProxyUrl(mUi.systemProxyHttpsEdit, &mProxyMap[QL1S("EnvVarProxyHttps")]);
+        showSystemProxyUrl(mUi.systemProxyFtpEdit, &mProxyMap[QL1S("EnvVarProxyFtp")]);
+        showSystemProxyUrl(mUi.systemProxySocksEdit, &mProxyMap[QL1S("EnvVarProxySocks")]);
+        showSystemProxyUrl(mUi.systemNoProxyEdit, &mProxyMap[QL1S("EnvVarNoProxy")]);
+        return;
+    }
+
+    mUi.systemProxyHttpEdit->setText(mProxyMap.take (QL1S("EnvVarProxyHttp")));
+    mUi.systemProxyHttpEdit->setEnabled(true);
+    mUi.systemProxyHttpsEdit->setText(mProxyMap.take (QL1S("EnvVarProxyHttps")));
+    mUi.systemProxyHttpsEdit->setEnabled(true);
+    mUi.systemProxyFtpEdit->setText(mProxyMap.take (QL1S("EnvVarProxyFtp")));
+    mUi.systemProxyFtpEdit->setEnabled(true);
+    mUi.systemProxySocksEdit->setText(mProxyMap.take (QL1S("EnvVarProxySocks")));
+    mUi.systemProxySocksEdit->setEnabled(true);
+    mUi.systemNoProxyEdit->setText(mProxyMap.take (QL1S("EnvVarNoProxy")));
+    mUi.systemNoProxyEdit->setEnabled(true);
 }
 
-QString KProxyDialog::quickHelp() const
+void KProxyDialog::on_useSameProxyCheckBox_clicked(bool on)
 {
-  return i18n( "<h1>Proxy</h1>"
-               "<p>A proxy server is an intermediate program that sits between "
-               "your machine and the Internet and provides services such as "
-               "web page caching and/or filtering.</p>"
-               "<p>Caching proxy servers give you faster access to sites you have "
-               "already visited by locally storing or caching the content of those "
-               "pages; filtering proxy servers, on the other hand, provide the "
-               "ability to block out requests for ads, spam, or anything else you "
-               "want to block.</p>"
-               "<p><u>Note:</u> Some proxy servers provide both services.</p>" );
+    if (on) {
+        mProxyMap[QL1S("ManProxyHttps")] = manualProxyToText (mUi.manualProxyHttpsEdit, mUi.manualProxyHttpsSpinBox, QL1C (' '));
+        mProxyMap[QL1S("ManProxyFtp")] = manualProxyToText (mUi.manualProxyFtpEdit, mUi.manualProxyFtpSpinBox, QL1C (' '));
+        mProxyMap[QL1S("ManProxySocks")] = manualProxyToText (mUi.manualProxySocksEdit, mUi.manualProxySocksSpinBox, QL1C (' '));
+
+        const QString& httpProxy = mUi.manualProxyHttpEdit->text();
+        if (!httpProxy.isEmpty()) {
+            mUi.manualProxyHttpsEdit->setText(httpProxy);
+            mUi.manualProxyFtpEdit->setText(httpProxy);
+            mUi.manualProxySocksEdit->setText(httpProxy);
+        }
+        const int httpProxyPort = mUi.manualProxyHttpSpinBox->value();
+        if (httpProxyPort > 0) {
+            mUi.manualProxyHttpsSpinBox->setValue(httpProxyPort);
+            mUi.manualProxyFtpSpinBox->setValue(httpProxyPort);
+            mUi.manualProxySocksSpinBox->setValue(httpProxyPort);
+        }
+        return;
+    }
+
+    setManualProxyFromText(mProxyMap.take (QL1S("ManProxyHttps")), mUi.manualProxyHttpsEdit, mUi.manualProxyHttpsSpinBox);
+    setManualProxyFromText(mProxyMap.take (QL1S("ManProxyFtp")), mUi.manualProxyFtpEdit, mUi.manualProxyFtpSpinBox);
+    setManualProxyFromText(mProxyMap.take (QL1S("ManProxySocks")), mUi.manualProxySocksEdit, mUi.manualProxySocksSpinBox);
 }
 
-void KProxyDialog::showInvalidMessage( const QString& _msg )
+void KProxyDialog::slotChanged()
 {
-  QString msg;
-
-  if( !_msg.isEmpty() )
-    msg = _msg;
-  else
-    msg = i18n( "<qt>The proxy settings you specified are invalid."
-                "<br /><br />Please click on the <b>Setup...</b> "
-                "button and correct the problem before proceeding; "
-                "otherwise your changes will be ignored.</qt>" );
+    emit changed(true);
+}
 
-  KMessageBox::error( this, msg, i18nc("@title:window", "Invalid Proxy Setup") );
+QString KProxyDialog::quickHelp() const
+{
+    return i18n ("<h1>Proxy</h1>"
+                 "<p>A proxy server is an intermediate program that sits between "
+                 "your machine and the Internet and provides services such as "
+                 "web page caching and/or filtering.</p>"
+                 "<p>Caching proxy servers give you faster access to sites you have "
+                 "already visited by locally storing or caching the content of those "
+                 "pages; filtering proxy servers, on the other hand, provide the "
+                 "ability to block out requests for ads, spam, or anything else you "
+                 "want to block.</p>"
+                 "<p><u>Note:</u> Some proxy servers provide both services.</p>");
 }
 
 #include "kproxydlg.moc"
+
diff --git a/konqueror/settings/kio/kproxydlg.h b/konqueror/settings/kio/kproxydlg.h
index b2cafb8..961663d 100644
--- a/konqueror/settings/kio/kproxydlg.h
+++ b/konqueror/settings/kio/kproxydlg.h
@@ -1,7 +1,7 @@
 /*
    kproxydlg.h - Proxy configuration dialog
 
-   Copyright (C) 2001- Dawit Alemayehu <adawit at kde.org>
+   Copyright (C) 2001, 2011 Dawit Alemayehu <adawit at kde.org>
 
    This library is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public
@@ -23,36 +23,48 @@
 #define KPROXYDLG_H
 
 #include <kcmodule.h>
-#include "kproxydlgbase.h"
 #include "ui_kproxydlg.h"
 
 class KProxyDialog : public KCModule
 {
-  Q_OBJECT
+    Q_OBJECT
 
 public:
-  KProxyDialog(QWidget *parent, const QVariantList &args);
-  ~KProxyDialog();
+    enum DisplayUrlFlag {
+        HideNone = 0x00,
+        HideHttpUrlScheme = 0x01,
+        HideHttpsUrlScheme = 0x02,
+        HideFtpUrlScheme = 0x04,
+        HideSocksUrlScheme = 0x08
+    };
+    Q_DECLARE_FLAGS(DisplayUrlFlags, DisplayUrlFlag)
 
-  virtual void load();
-  virtual void save();
-  virtual void defaults();
-  QString quickHelp() const;
+    KProxyDialog(QWidget* parent, const QVariantList& args);
+    ~KProxyDialog();
+
+    virtual void load();
+    virtual void save();
+    virtual void defaults();
+    QString quickHelp() const;
 
 private Q_SLOTS:
-  void slotChanged();
-  void slotUseProxyChanged();
+    void on_autoDetectButton_clicked();
+    void on_showEnvValueCheckBox_toggled(bool);
+    void on_useSameProxyCheckBox_clicked(bool);
 
-  void setupManProxy();
-  void setupEnvProxy();
+    void on_manualProxyHttpEdit_textChanged(const QString&);
+    void on_manualNoProxyEdit_textChanged(const QString&);    
+    void on_manualProxyHttpEdit_textEdited(const QString&);
+    void on_manualProxyHttpSpinBox_valueChanged(int);
 
-private:
-  void showInvalidMessage( const QString& _msg = QString() );
+    void slotChanged();
 
 private:
-  Ui::KProxyDialogUI mUi;
-  KProxyData mData;
-  bool mDefaultData;
+    Ui::ProxyDialogUI mUi;
+    QStringList mNoProxyForList;
+    QMap<QString, QString> mProxyMap;
 };
 
+Q_DECLARE_OPERATORS_FOR_FLAGS (KProxyDialog::DisplayUrlFlags)
+
 #endif // KPROXYDLG_H
diff --git a/konqueror/settings/kio/kproxydlg.ui b/konqueror/settings/kio/kproxydlg.ui
index 96ff996..bafaa2b 100644
--- a/konqueror/settings/kio/kproxydlg.ui
+++ b/konqueror/settings/kio/kproxydlg.ui
@@ -1,310 +1,688 @@
-<ui version="4.0" >
- <class>KProxyDialogUI</class>
- <widget class="QWidget" name="KProxyDialogUI" >
-  <property name="geometry" >
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>ProxyDialogUI</class>
+ <widget class="QWidget" name="ProxyDialogUI">
+  <property name="geometry">
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>622</width>
-    <height>473</height>
+    <width>513</width>
+    <height>567</height>
    </rect>
   </property>
-  <property name="whatsThis" >
-   <string><qt>
+  <property name="whatsThis">
+   <string><qt>
 Setup proxy configuration.
-<p>
+<p>
 A proxy server is an intermediate machine that sits between your computer and the Internet and provides services such as web page caching and filtering. Caching proxy servers give you faster access to web sites you have already visited by locally storing or caching those pages; filtering proxy servers usually provide the ability to block out requests for ads, spam, or anything else you want to block.
-<p>
+<p>
 If you are uncertain whether or not you need to use a proxy server to connect to the Internet, consult your Internet service provider's setup guide or your system administrator.
-</qt></string>
+</qt></string>
   </property>
-  <layout class="QVBoxLayout" name="verticalLayout_2" >
-   <item>
-    <widget class="QGroupBox" name="gbMain" >
-     <property name="title" >
-      <string/>
+  <layout class="QGridLayout" name="gridLayout">
+   <item row="0" column="0">
+    <widget class="QRadioButton" name="noProxyRadioButton">
+     <property name="whatsThis">
+      <string>Connect to the Internet directly.</string>
+     </property>
+     <property name="text">
+      <string>No Proxy</string>
+     </property>
+     <property name="checked">
+      <bool>true</bool>
+     </property>
+    </widget>
+   </item>
+   <item row="1" column="0" colspan="2">
+    <widget class="QRadioButton" name="autoDiscoverProxyRadioButton">
+     <property name="enabled">
+      <bool>true</bool>
+     </property>
+     <property name="whatsThis">
+      <string><qt>
+Automatically detect and configure the proxy settings.<p>
+Automatic detection is performed using the <b>Web Proxy Auto-Discovery Protocol (WPAD)</b>.<p>
+<b>NOTE:</b> This option might not work properly or not work at all in some UNIX/Linux distributions. If you encounter a problem when using this option, please check the FAQ section at http://konqueror.kde.org.
+</qt></string>
      </property>
-     <property name="flat" >
+     <property name="text">
+      <string>Detect proxy configuration automatically</string>
+     </property>
+    </widget>
+   </item>
+   <item row="2" column="0" colspan="2">
+    <widget class="QRadioButton" name="autoScriptProxyRadioButton">
+     <property name="enabled">
+      <bool>true</bool>
+     </property>
+     <property name="whatsThis">
+      <string>Use the specified proxy script to configure the proxy settings.</string>
+     </property>
+     <property name="text">
+      <string>Use proxy auto configuration URL:</string>
+     </property>
+    </widget>
+   </item>
+   <item row="3" column="0" colspan="4">
+    <widget class="QGroupBox" name="proxyConfigScriptGroupBox">
+     <property name="flat">
       <bool>true</bool>
      </property>
-     <layout class="QVBoxLayout" name="verticalLayout" >
-      <property name="margin" >
+     <layout class="QVBoxLayout" name="verticalLayout_2">
+      <property name="leftMargin">
+       <number>20</number>
+      </property>
+      <property name="topMargin">
+       <number>0</number>
+      </property>
+      <property name="rightMargin">
+       <number>0</number>
+      </property>
+      <property name="bottomMargin">
        <number>0</number>
       </property>
       <item>
-       <widget class="QRadioButton" name="rbNoProxy" >
-        <property name="whatsThis" >
-         <string>Connect to the Internet directly.</string>
+       <widget class="KUrlRequester" name="proxyScriptUrlRequester">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Expanding" vsizetype="Preferred">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
         </property>
-        <property name="text" >
-         <string>Connect to the &Internet directly</string>
+        <property name="whatsThis">
+         <string>Enter the address for the proxy configuration script.</string>
         </property>
-        <property name="checked" >
-         <bool>true</bool>
+       </widget>
+      </item>
+     </layout>
+    </widget>
+   </item>
+   <item row="4" column="0">
+    <widget class="QRadioButton" name="systemProxyRadioButton">
+     <property name="enabled">
+      <bool>true</bool>
+     </property>
+     <property name="sizePolicy">
+      <sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
+       <horstretch>0</horstretch>
+       <verstretch>0</verstretch>
+      </sizepolicy>
+     </property>
+     <property name="whatsThis">
+      <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
+<html><head><meta name="qrichtext" content="1" /><style type="text/css">
+p, li { white-space: pre-wrap; }
+</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;">
+<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Use proxy settings defined on the system.</p>
+<p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Some platforms offer system wide proxy configuration information and selecting this option allows you to use those settings.</p>
+<p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">On Mac platforms</p>
+<p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">On Windows platforms</p>
+<p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">On Unix and Linux platforms, such system proxy settings are usually defined through environment variables. The following environment variables are detected and used when present: <span style=" font-weight:600;">HTTP_PROXY</span>,  <span style=" font-weight:600;">HTTPS_PROXY</span>, <span style=" font-weight:600;">FTP_PROXY</span>, <span style=" font-weight:600;">NO_PROXY.</span></p>
+<p style="-qt-paragraph-type:empty; margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p></body></html></string>
+     </property>
+     <property name="text">
+      <string>Use system proxy configuration:</string>
+     </property>
+    </widget>
+   </item>
+   <item row="4" column="3">
+    <widget class="QPushButton" name="autoDetectButton">
+     <property name="enabled">
+      <bool>false</bool>
+     </property>
+     <property name="whatsThis">
+      <string><qt>Attempt automatic discovery of the environment variables used for setting system wide proxy information.<p> This feature works by searching for commonly used variable names such as HTTP_PROXY, FTP_PROXY and NO_PROXY.</qt></string>
+     </property>
+     <property name="text">
+      <string>Auto D&etect</string>
+     </property>
+    </widget>
+   </item>
+   <item row="5" column="0" colspan="4">
+    <widget class="QGroupBox" name="systemProxyGroupBox">
+     <property name="flat">
+      <bool>true</bool>
+     </property>
+     <layout class="QFormLayout" name="formLayout_2">
+      <property name="leftMargin">
+       <number>20</number>
+      </property>
+      <property name="topMargin">
+       <number>0</number>
+      </property>
+      <property name="rightMargin">
+       <number>0</number>
+      </property>
+      <property name="bottomMargin">
+       <number>0</number>
+      </property>
+      <item row="0" column="0">
+       <widget class="QLabel" name="systemProxyHttpLabel">
+        <property name="whatsThis">
+         <string><qt>
+Enter the name of the environment variable, e.g. <b>HTTP_PROXY</b>, used to store the address of the HTTP proxy server.<p>
+Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt automatic discovery of this variable.</p>
+</qt></string>
+        </property>
+        <property name="text">
+         <string>HTTP Proxy:</string>
+        </property>
+        <property name="wordWrap">
+         <bool>false</bool>
+        </property>
+        <property name="buddy">
+         <cstring>systemProxyHttpEdit</cstring>
         </property>
        </widget>
       </item>
-      <item>
-       <widget class="QRadioButton" name="rbAutoDiscover" >
-        <property name="enabled" >
-         <bool>true</bool>
+      <item row="0" column="1">
+       <widget class="KLineEdit" name="systemProxyHttpEdit">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
+        </property>
+        <property name="whatsThis">
+         <string><qt>
+Enter the name of the environment variable, e.g. <b>HTTP_PROXY</b>, used to store the address of the HTTP proxy server.<p>
+Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt automatic discovery of this variable.</p>
+</qt></string>
         </property>
-        <property name="whatsThis" >
-         <string><qt>
-Automatically detect and configure the proxy settings.<p>
-Automatic detection is performed using the <b>Web Proxy Auto-Discovery Protocol (WPAD)</b>.<p>
-<b>NOTE:</b> This option might not work properly or not work at all in some UNIX/Linux distributions. If you encounter a problem when using this option, please check the FAQ section at http://konqueror.kde.org.
-</qt></string>
+       </widget>
+      </item>
+      <item row="1" column="0">
+       <widget class="QLabel" name="systemProxyHttpsLabel">
+        <property name="whatsThis">
+         <string><qt>
+Enter the name of the environment variable, e.g. <b>HTTPS_PROXY</b>, used to store the address of the HTTPS proxy server.<p>
+Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.</p>
+</qt></string>
         </property>
-        <property name="text" >
-         <string>A&utomatically detect proxy configuration</string>
+        <property name="text">
+         <string>SSL Proxy:</string>
+        </property>
+        <property name="wordWrap">
+         <bool>false</bool>
+        </property>
+        <property name="buddy">
+         <cstring>systemProxyHttpsEdit</cstring>
         </property>
        </widget>
       </item>
-      <item>
-       <layout class="QHBoxLayout" >
-        <property name="margin" >
-         <number>0</number>
+      <item row="1" column="1">
+       <widget class="KLineEdit" name="systemProxyHttpsEdit">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
+        </property>
+        <property name="whatsThis">
+         <string><qt>
+Enter the name of the environment variable, e.g. <b>HTTPS_PROXY</b>, used to store the address of the HTTPS proxy server.<p>
+Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.</p>
+</qt></string>
+        </property>
+       </widget>
+      </item>
+      <item row="2" column="0">
+       <widget class="QLabel" name="systemProxyFtpLabel">
+        <property name="whatsThis">
+         <string><qt>
+Enter the name of the environment variable, e.g. <b>FTP_PROXY</b>, used to store the address of the FTP proxy server.<p>
+Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.</p>
+</qt></string>
+        </property>
+        <property name="text">
+         <string>FTP Proxy:</string>
+        </property>
+        <property name="wordWrap">
+         <bool>false</bool>
+        </property>
+        <property name="buddy">
+         <cstring>systemProxyFtpEdit</cstring>
+        </property>
+       </widget>
+      </item>
+      <item row="2" column="1">
+       <widget class="KLineEdit" name="systemProxyFtpEdit">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
+        </property>
+        <property name="whatsThis">
+         <string><qt>
+Enter the name of the environment variable, e.g. <b>FTP_PROXY</b>, used to store the address of the FTP proxy server.<p>
+Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.</p>
+</qt></string>
+        </property>
+       </widget>
+      </item>
+      <item row="3" column="0">
+       <widget class="QLabel" name="systemProxySocksLabel">
+        <property name="whatsThis">
+         <string><qt>
+Enter the name of the environment variable, e.g. <b>FTP_PROXY</b>, used to store the address of the FTP proxy server.<p>
+Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.</p>
+</qt></string>
+        </property>
+        <property name="text">
+         <string>SOCKS Proxy:</string>
+        </property>
+        <property name="wordWrap">
+         <bool>false</bool>
+        </property>
+        <property name="buddy">
+         <cstring>systemProxySocksEdit</cstring>
+        </property>
+       </widget>
+      </item>
+      <item row="3" column="1">
+       <widget class="KLineEdit" name="systemProxySocksEdit">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
+        </property>
+        <property name="whatsThis">
+         <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
+<html><head><meta name="qrichtext" content="1" /><style type="text/css">
+p, li { white-space: pre-wrap; }
+</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;">
+<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Enter the name of the environment variable, e.g. <span style=" font-weight:600;">SOCKS_PROXY</span>, used to store the address of the FTP proxy server.</p>
+<p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Alternatively, you can click on the <span style=" font-weight:600;">&quot;Auto Detect&quot;</span> button to attempt an automatic discovery of this variable.</p></body></html></string>
+        </property>
+       </widget>
+      </item>
+      <item row="4" column="0">
+       <widget class="QLabel" name="sysNoProxyLabel">
+        <property name="whatsThis">
+         <string><qt>
+Enter the environment variable, e.g. <b>NO_PROXY</b>, used to store the addresses of sites for which the proxy server should not be used.<p>
+Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.
+</qt></string>
+        </property>
+        <property name="text">
+         <string>Exceptions:</string>
+        </property>
+        <property name="wordWrap">
+         <bool>false</bool>
+        </property>
+        <property name="buddy">
+         <cstring>systemNoProxyEdit</cstring>
         </property>
+       </widget>
+      </item>
+      <item row="4" column="1">
+       <widget class="KLineEdit" name="systemNoProxyEdit">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
+        </property>
+        <property name="whatsThis">
+         <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
+<html><head><meta name="qrichtext" content="1" /><style type="text/css">
+p, li { white-space: pre-wrap; }
+</style></head><body style=" font-family:'Bitstream Vera Sans'; font-size:9pt; font-weight:400; font-style:normal;">
+<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Enter the environment variable, e.g. <span style=" font-weight:600;">NO_PROXY</span>, used to store the addresses of sites for which the above proxy settings should not be used.</p>
+<p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Alternatively, you can click on the <span style=" font-weight:600;">&quot;Auto Detect&quot;</span> button to attempt an automatic discovery of this variable. </p></body></html></string>
+        </property>
+       </widget>
+      </item>
+      <item row="5" column="1">
+       <widget class="QCheckBox" name="showEnvValueCheckBox">
+        <property name="text">
+         <string>Show the &value of the environment variables</string>
+        </property>
+       </widget>
+      </item>
+     </layout>
+    </widget>
+   </item>
+   <item row="6" column="0" colspan="2">
+    <widget class="QRadioButton" name="manualProxyRadioButton">
+     <property name="enabled">
+      <bool>true</bool>
+     </property>
+     <property name="sizePolicy">
+      <sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
+       <horstretch>0</horstretch>
+       <verstretch>0</verstretch>
+      </sizepolicy>
+     </property>
+     <property name="whatsThis">
+      <string>Manually enter proxy server configuration information.</string>
+     </property>
+     <property name="text">
+      <string>Use manually specified proxy configuration:</string>
+     </property>
+    </widget>
+   </item>
+   <item row="7" column="0" colspan="4">
+    <widget class="QGroupBox" name="manualProxyGroupBox">
+     <property name="title">
+      <string/>
+     </property>
+     <property name="flat">
+      <bool>true</bool>
+     </property>
+     <layout class="QFormLayout" name="formLayout">
+      <property name="fieldGrowthPolicy">
+       <enum>QFormLayout::ExpandingFieldsGrow</enum>
+      </property>
+      <property name="leftMargin">
+       <number>20</number>
+      </property>
+      <property name="topMargin">
+       <number>0</number>
+      </property>
+      <property name="rightMargin">
+       <number>0</number>
+      </property>
+      <property name="bottomMargin">
+       <number>0</number>
+      </property>
+      <item row="0" column="0">
+       <widget class="QLabel" name="manualProxyHttpEditLabel">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
+        </property>
+        <property name="text">
+         <string>HTTP Proxy:</string>
+        </property>
+        <property name="wordWrap">
+         <bool>false</bool>
+        </property>
+        <property name="buddy">
+         <cstring>manualProxyHttpEdit</cstring>
+        </property>
+       </widget>
+      </item>
+      <item row="0" column="1">
+       <layout class="QHBoxLayout" name="horizontalLayout_4">
         <item>
-         <widget class="QRadioButton" name="rbAutoScript" >
-          <property name="enabled" >
-           <bool>true</bool>
+         <widget class="KLineEdit" name="manualProxyHttpEdit">
+          <property name="whatsThis">
+           <string>Enter the address of the HTTP proxy server.</string>
           </property>
-          <property name="whatsThis" >
-           <string>Use the specified proxy script URL to configure the proxy settings.</string>
+         </widget>
+        </item>
+        <item>
+         <widget class="QLabel" name="manualProxyHttpSpinBoxLabel">
+          <property name="text">
+           <string>Port:</string>
           </property>
-          <property name="text" >
-           <string>U&se proxy configuration URL:</string>
+          <property name="buddy">
+           <cstring>manualProxyHttpSpinBox</cstring>
           </property>
          </widget>
         </item>
         <item>
-         <widget class="KUrlRequester" name="location" >
-          <property name="enabled" >
-           <bool>false</bool>
+         <widget class="KIntSpinBox" name="manualProxyHttpSpinBox">
+          <property name="maximumSize">
+           <size>
+            <width>32767</width>
+            <height>32767</height>
+           </size>
           </property>
-          <property name="sizePolicy" >
-           <sizepolicy vsizetype="Preferred" hsizetype="Expanding" >
-            <horstretch>0</horstretch>
-            <verstretch>0</verstretch>
-           </sizepolicy>
+          <property name="whatsThis">
+           <string>Enter the port number of the HTTP proxy server. Default is 8080. Another common value is 3128.</string>
           </property>
-          <property name="whatsThis" >
-           <string>Enter the address for the proxy configuration script.</string>
+          <property name="maximum">
+           <number>65536</number>
           </property>
          </widget>
         </item>
        </layout>
       </item>
-      <item>
-       <layout class="QHBoxLayout" >
-        <property name="margin" >
-         <number>0</number>
+      <item row="1" column="1">
+       <widget class="QCheckBox" name="useSameProxyCheckBox">
+        <property name="enabled">
+         <bool>false</bool>
         </property>
+        <property name="text">
+         <string>Use this proxy server for a&ll protocols</string>
+        </property>
+       </widget>
+      </item>
+      <item row="2" column="0">
+       <widget class="QLabel" name="manualProxyHttpsEditLabel">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
+        </property>
+        <property name="text">
+         <string>SSL Proxy:</string>
+        </property>
+        <property name="wordWrap">
+         <bool>false</bool>
+        </property>
+        <property name="buddy">
+         <cstring>manualProxyHttpsEdit</cstring>
+        </property>
+       </widget>
+      </item>
+      <item row="2" column="1">
+       <layout class="QHBoxLayout" name="horizontalLayout_3">
         <item>
-         <widget class="QRadioButton" name="rbEnvVar" >
-          <property name="enabled" >
-           <bool>true</bool>
-          </property>
-          <property name="sizePolicy" >
-           <sizepolicy vsizetype="Fixed" hsizetype="MinimumExpanding" >
-            <horstretch>0</horstretch>
-            <verstretch>0</verstretch>
-           </sizepolicy>
+         <widget class="KLineEdit" name="manualProxyHttpsEdit">
+          <property name="whatsThis">
+           <string>Enter the address of the HTTPS proxy server.</string>
           </property>
-          <property name="whatsThis" >
-           <string><qt>
-Use environment variables to configure the proxy settings.<p>
-Environment variables such as <b>HTTP_PROXY</b> and <b>NO_PROXY</b> are usually used in multi-user UNIX installations, where both graphical and non-graphical applications need to share the same proxy configuration information.
-</qt></string>
+         </widget>
+        </item>
+        <item>
+         <widget class="QLabel" name="manualProxyHttpsSpinBoxLabel">
+          <property name="text">
+           <string>Port:</string>
           </property>
-          <property name="text" >
-           <string>Use preset proxy environment &variables</string>
+          <property name="buddy">
+           <cstring>manualProxyHttpsSpinBox</cstring>
           </property>
          </widget>
         </item>
         <item>
-         <widget class="QPushButton" name="pbEnvSetup" >
-          <property name="enabled" >
-           <bool>true</bool>
+         <widget class="KIntSpinBox" name="manualProxyHttpsSpinBox">
+          <property name="whatsThis">
+           <string>Enter the port number of the HTTP proxy server. Default is 8080. Another common value is 3128.</string>
           </property>
-          <property name="whatsThis" >
-           <string>Show the proxy environment variable configuration dialog.</string>
-          </property>
-          <property name="text" >
-           <string>Setup...</string>
+          <property name="maximum">
+           <number>65536</number>
           </property>
          </widget>
         </item>
        </layout>
       </item>
-      <item>
-       <layout class="QHBoxLayout" >
-        <property name="margin" >
-         <number>0</number>
+      <item row="3" column="0">
+       <widget class="QLabel" name="manualProxyFtpEditLabel">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
+        </property>
+        <property name="text">
+         <string>FTP Proxy:</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="wordWrap">
+         <bool>false</bool>
+        </property>
+        <property name="buddy">
+         <cstring>manualProxyFtpEdit</cstring>
         </property>
+       </widget>
+      </item>
+      <item row="3" column="1">
+       <layout class="QHBoxLayout" name="horizontalLayout_2">
         <item>
-         <widget class="QRadioButton" name="rbManual" >
-          <property name="enabled" >
-           <bool>true</bool>
-          </property>
-          <property name="sizePolicy" >
-           <sizepolicy vsizetype="Fixed" hsizetype="MinimumExpanding" >
-            <horstretch>0</horstretch>
-            <verstretch>0</verstretch>
-           </sizepolicy>
+         <widget class="KLineEdit" name="manualProxyFtpEdit">
+          <property name="whatsThis">
+           <string>Enter the address of the FTP proxy server.</string>
           </property>
-          <property name="whatsThis" >
-           <string>Manually enter proxy server configuration information.</string>
+         </widget>
+        </item>
+        <item>
+         <widget class="QLabel" name="manualProxyFtpSpinBoxLabel">
+          <property name="text">
+           <string>Port:</string>
           </property>
-          <property name="text" >
-           <string>&Manually specify the proxy settings</string>
+          <property name="buddy">
+           <cstring>manualProxyFtpSpinBox</cstring>
           </property>
          </widget>
         </item>
         <item>
-         <widget class="QPushButton" name="pbManSetup" >
-          <property name="enabled" >
-           <bool>true</bool>
-          </property>
-          <property name="whatsThis" >
-           <string>Show the manual proxy configuration dialog.</string>
+         <widget class="KIntSpinBox" name="manualProxyFtpSpinBox">
+          <property name="whatsThis">
+           <string>Enter the port number of the FTP proxy server. Default 8080. Another common value is 3128.</string>
           </property>
-          <property name="text" >
-           <string>Setup...</string>
+          <property name="maximum">
+           <number>65536</number>
           </property>
          </widget>
         </item>
        </layout>
       </item>
-     </layout>
-    </widget>
-   </item>
-   <item>
-    <widget class="QGroupBox" name="gbAuth" >
-     <property name="enabled" >
-      <bool>false</bool>
-     </property>
-     <property name="title" >
-      <string>Authori&zation</string>
-     </property>
-     <layout class="QVBoxLayout" >
-      <item>
-       <widget class="QRadioButton" name="rbPrompt" >
-        <property name="whatsThis" >
-         <string>Prompt for login information whenever it is required.</string>
+      <item row="4" column="0">
+       <widget class="QLabel" name="manualProxySocksEditLabel">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Fixed" vsizetype="Preferred">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
         </property>
-        <property name="text" >
-         <string>Prompt as &needed</string>
+        <property name="text">
+         <string>SOCKS Proxy:</string>
         </property>
-        <property name="checked" >
-         <bool>true</bool>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="buddy">
+         <cstring>manualProxySocksEdit</cstring>
         </property>
        </widget>
       </item>
-      <item>
-       <layout class="QGridLayout" >
-        <property name="margin" >
-         <number>0</number>
-        </property>
-        <item row="0" column="0" >
-         <widget class="QRadioButton" name="rbPresetLogin" >
-          <property name="enabled" >
-           <bool>false</bool>
-          </property>
-          <property name="toolTip" >
-           <string>Use this login information.</string>
-          </property>
-          <property name="whatsThis" >
-           <string>Use information specified here to login into proxy servers as needed.</string>
-          </property>
-          <property name="text" >
-           <string>Username:</string>
-          </property>
-         </widget>
-        </item>
-        <item row="0" column="1" >
-         <widget class="KLineEdit" name="leUsername" >
-          <property name="enabled" >
-           <bool>false</bool>
-          </property>
-          <property name="whatsThis" >
-           <string>Login name.</string>
+      <item row="4" column="1">
+       <layout class="QHBoxLayout" name="horizontalLayout">
+        <item>
+         <widget class="KLineEdit" name="manualProxySocksEdit">
+          <property name="whatsThis">
+           <string>Enter the address of the SOCKS proxy server.</string>
           </property>
          </widget>
         </item>
-        <item row="0" column="2" >
-         <widget class="QLabel" name="lbPassword" >
-          <property name="enabled" >
-           <bool>false</bool>
-          </property>
-          <property name="whatsThis" >
-           <string>Login password.</string>
-          </property>
-          <property name="text" >
-           <string>Password:</string>
-          </property>
-          <property name="alignment" >
-           <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        <item>
+         <widget class="QLabel" name="manualProxySocksSpinBoxLabel">
+          <property name="text">
+           <string>Port:</string>
           </property>
-          <property name="wordWrap" >
-           <bool>false</bool>
+          <property name="buddy">
+           <cstring>manualProxySocksSpinBox</cstring>
           </property>
          </widget>
         </item>
-        <item row="0" column="3" >
-         <widget class="KLineEdit" name="lePassword" >
-          <property name="enabled" >
-           <bool>false</bool>
-          </property>
-          <property name="whatsThis" >
-           <string>Login password.</string>
+        <item>
+         <widget class="KIntSpinBox" name="manualProxySocksSpinBox">
+          <property name="whatsThis">
+           <string>Enter the port number of the FTP proxy server. Default 8080. Another common value is 3128.</string>
           </property>
-          <property name="echoMode" >
-           <enum>QLineEdit::Password</enum>
+          <property name="maximum">
+           <number>65536</number>
           </property>
          </widget>
         </item>
        </layout>
       </item>
-     </layout>
-    </widget>
-   </item>
-   <item>
-    <widget class="QGroupBox" name="gbOptions" >
-     <property name="enabled" >
-      <bool>false</bool>
-     </property>
-     <property name="title" >
-      <string>O&ptions</string>
-     </property>
-     <layout class="QVBoxLayout" >
-      <item>
-       <widget class="QCheckBox" name="cbPersConn" >
-        <property name="whatsThis" >
-         <string><qt>
-Use persistent proxy connection.<p>
-Although a persistent proxy connection is faster, note that it only works correctly with proxies that are fully HTTP 1.1 compliant. Do <b>not</b> use this option in combination with non-HTTP 1.1 compliant proxy servers such as JunkBuster and WWWOfle.
-</qt></string>
+      <item row="5" column="0">
+       <widget class="QLabel" name="manNoProxyLabel">
+        <property name="whatsThis">
+         <string><qt>
+Enter the environment variable, e.g. <b>NO_PROXY</b>, used to store the addresses of sites for which the proxy server should not be used.<p>
+Alternatively, you can click on the <b>"Auto Detect"</b> button to attempt an automatic discovery of this variable.
+</qt></string>
+        </property>
+        <property name="text">
+         <string>Exceptions:</string>
+        </property>
+        <property name="alignment">
+         <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+        </property>
+        <property name="wordWrap">
+         <bool>false</bool>
+        </property>
+        <property name="buddy">
+         <cstring>manualNoProxyEdit</cstring>
+        </property>
+       </widget>
+      </item>
+      <item row="5" column="1">
+       <widget class="KLineEdit" name="manualNoProxyEdit">
+        <property name="sizePolicy">
+         <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
+          <horstretch>0</horstretch>
+          <verstretch>0</verstretch>
+         </sizepolicy>
         </property>
-        <property name="text" >
-         <string>Use persistent connections to proxy</string>
+        <property name="whatsThis">
+         <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
+<html><head><meta name="qrichtext" content="1" /><style type="text/css">
+p, li { white-space: pre-wrap; }
+</style></head><body style=" font-family:'Bitstream Vera Sans'; font-size:9pt; font-weight:400; font-style:normal;">
+<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Enter a comma separated list of hostnames or ip addresses that should be excluded from using the above proxy settings.</span></p>
+<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans Serif';"></p>
+<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">If you want to exclude all hosts for a given domian, then simply enter the hostname preceeded by a dot. For example, to exclude all hostnames for </span><span style=" font-family:'Sans Serif'; font-style:italic;">kde.org</span><span style=" font-family:'Sans Serif';">, enter </span><span style=" font-family:'Sans Serif'; font-style:italic;">.kde.org</span><span style=" font-family:'Sans Serif';">. Wildcard characters such as '*' or '?' are not supported and will have no effect. </span></p>
+<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans Serif';"></p>
+<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Additionally, you can also enter IP addresses, e.g. 127.0.0.1 and IP addresses with a subnet, e.g. 192.168.0.1/24.</span></p>
+<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans Serif';"></p></body></html></string>
+        </property>
+       </widget>
+      </item>
+      <item row="6" column="1">
+       <widget class="QCheckBox" name="useReverseProxyCheckBox">
+        <property name="enabled">
+         <bool>false</bool>
+        </property>
+        <property name="whatsThis">
+         <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
+<html><head><meta name="qrichtext" content="1" /><style type="text/css">
+p, li { white-space: pre-wrap; }
+</style></head><body style=" font-family:'Bitstream Vera Sans'; font-size:9pt; font-weight:400; font-style:normal;">
+<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Check this box if you want the above proxy settings to apply only to the addresses listed in the <span style=" font-style:italic;">Exceptions</span> list.</p></body></html></string>
+        </property>
+        <property name="text">
+         <string>Use proxy settings only for addresses in the Exceptions list</string>
         </property>
        </widget>
       </item>
      </layout>
     </widget>
    </item>
-   <item>
-    <spacer>
-     <property name="orientation" >
+   <item row="8" column="2">
+    <spacer name="verticalSpacer">
+     <property name="orientation">
       <enum>Qt::Vertical</enum>
      </property>
-     <property name="sizeHint" stdset="0" >
+     <property name="sizeType">
+      <enum>QSizePolicy::MinimumExpanding</enum>
+     </property>
+     <property name="sizeHint" stdset="0">
       <size>
-       <width>369</width>
-       <height>16</height>
+       <width>20</width>
+       <height>42</height>
       </size>
      </property>
     </spacer>
@@ -318,78 +696,285 @@ Although a persistent proxy connection is faster, note that it only works correc
    <header>klineedit.h</header>
   </customwidget>
   <customwidget>
+   <class>KIntSpinBox</class>
+   <extends>QSpinBox</extends>
+   <header>knuminput.h</header>
+  </customwidget>
+  <customwidget>
    <class>KUrlRequester</class>
    <extends>QFrame</extends>
    <header>kurlrequester.h</header>
    <container>1</container>
   </customwidget>
  </customwidgets>
+ <tabstops>
+  <tabstop>noProxyRadioButton</tabstop>
+  <tabstop>autoDiscoverProxyRadioButton</tabstop>
+  <tabstop>autoScriptProxyRadioButton</tabstop>
+  <tabstop>proxyScriptUrlRequester</tabstop>
+  <tabstop>systemProxyRadioButton</tabstop>
+  <tabstop>autoDetectButton</tabstop>
+  <tabstop>systemProxyHttpEdit</tabstop>
+  <tabstop>systemProxyHttpsEdit</tabstop>
+  <tabstop>systemProxyFtpEdit</tabstop>
+  <tabstop>systemProxySocksEdit</tabstop>
+  <tabstop>systemNoProxyEdit</tabstop>
+  <tabstop>showEnvValueCheckBox</tabstop>
+  <tabstop>manualProxyRadioButton</tabstop>
+  <tabstop>manualProxyHttpEdit</tabstop>
+  <tabstop>manualProxyHttpSpinBox</tabstop>
+  <tabstop>useSameProxyCheckBox</tabstop>
+  <tabstop>manualProxyHttpsEdit</tabstop>
+  <tabstop>manualProxyHttpsSpinBox</tabstop>
+  <tabstop>manualProxyFtpEdit</tabstop>
+  <tabstop>manualProxyFtpSpinBox</tabstop>
+  <tabstop>manualProxySocksEdit</tabstop>
+  <tabstop>manualProxySocksSpinBox</tabstop>
+  <tabstop>manualNoProxyEdit</tabstop>
+  <tabstop>useReverseProxyCheckBox</tabstop>
+ </tabstops>
  <includes>
-  <include location="local" >kpushbutton.h</include>
+  <include location="local">kpushbutton.h</include>
  </includes>
  <resources/>
  <connections>
   <connection>
-   <sender>rbPresetLogin</sender>
+   <sender>systemProxyRadioButton</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>systemProxyGroupBox</receiver>
+   <slot>setVisible(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>97</x>
+     <y>121</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>23</x>
+     <y>150</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>manualProxyRadioButton</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>manualProxyGroupBox</receiver>
+   <slot>setVisible(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>76</x>
+     <y>304</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>18</x>
+     <y>333</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>useSameProxyCheckBox</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>manualProxyHttpsEdit</receiver>
+   <slot>setDisabled(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>249</x>
+     <y>370</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>250</x>
+     <y>384</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>useSameProxyCheckBox</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>manualProxyFtpEdit</receiver>
+   <slot>setDisabled(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>218</x>
+     <y>364</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>215</x>
+     <y>414</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>useSameProxyCheckBox</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>manualProxySocksEdit</receiver>
+   <slot>setDisabled(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>191</x>
+     <y>362</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>187</x>
+     <y>440</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>showEnvValueCheckBox</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>systemNoProxyEdit</receiver>
+   <slot>setDisabled(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>352</x>
+     <y>282</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>353</x>
+     <y>259</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>showEnvValueCheckBox</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>systemProxySocksEdit</receiver>
+   <slot>setDisabled(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>275</x>
+     <y>278</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>273</x>
+     <y>231</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>showEnvValueCheckBox</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>systemProxyFtpEdit</receiver>
+   <slot>setDisabled(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>299</x>
+     <y>279</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>299</x>
+     <y>206</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>showEnvValueCheckBox</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>systemProxyHttpsEdit</receiver>
+   <slot>setDisabled(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>349</x>
+     <y>280</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>336</x>
+     <y>185</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>showEnvValueCheckBox</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>systemProxyHttpEdit</receiver>
+   <slot>setDisabled(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>272</x>
+     <y>279</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>236</x>
+     <y>156</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>autoScriptProxyRadioButton</sender>
+   <signal>toggled(bool)</signal>
+   <receiver>proxyConfigScriptGroupBox</receiver>
+   <slot>setVisible(bool)</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>120</x>
+     <y>63</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>120</x>
+     <y>79</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>systemProxyRadioButton</sender>
    <signal>toggled(bool)</signal>
-   <receiver>leUsername</receiver>
-   <slot>setEnabled(bool)</slot>
+   <receiver>autoDetectButton</receiver>
+   <slot>setVisible(bool)</slot>
    <hints>
-    <hint type="sourcelabel" >
-     <x>20</x>
-     <y>20</y>
+    <hint type="sourcelabel">
+     <x>186</x>
+     <y>119</y>
     </hint>
-    <hint type="destinationlabel" >
-     <x>20</x>
-     <y>20</y>
+    <hint type="destinationlabel">
+     <x>433</x>
+     <y>124</y>
     </hint>
    </hints>
   </connection>
   <connection>
-   <sender>rbPresetLogin</sender>
+   <sender>useSameProxyCheckBox</sender>
    <signal>toggled(bool)</signal>
-   <receiver>lePassword</receiver>
-   <slot>setEnabled(bool)</slot>
+   <receiver>manualProxyHttpsSpinBox</receiver>
+   <slot>setDisabled(bool)</slot>
    <hints>
-    <hint type="sourcelabel" >
-     <x>20</x>
-     <y>20</y>
+    <hint type="sourcelabel">
+     <x>155</x>
+     <y>361</y>
     </hint>
-    <hint type="destinationlabel" >
-     <x>20</x>
-     <y>20</y>
+    <hint type="destinationlabel">
+     <x>464</x>
+     <y>385</y>
     </hint>
    </hints>
   </connection>
   <connection>
-   <sender>rbPresetLogin</sender>
+   <sender>useSameProxyCheckBox</sender>
    <signal>toggled(bool)</signal>
-   <receiver>lbPassword</receiver>
-   <slot>setEnabled(bool)</slot>
+   <receiver>manualProxyFtpSpinBox</receiver>
+   <slot>setDisabled(bool)</slot>
    <hints>
-    <hint type="sourcelabel" >
-     <x>20</x>
-     <y>20</y>
+    <hint type="sourcelabel">
+     <x>139</x>
+     <y>364</y>
     </hint>
-    <hint type="destinationlabel" >
-     <x>20</x>
-     <y>20</y>
+    <hint type="destinationlabel">
+     <x>451</x>
+     <y>421</y>
     </hint>
    </hints>
   </connection>
   <connection>
-   <sender>rbAutoScript</sender>
+   <sender>useSameProxyCheckBox</sender>
    <signal>toggled(bool)</signal>
-   <receiver>location</receiver>
-   <slot>setEnabled(bool)</slot>
+   <receiver>manualProxySocksSpinBox</receiver>
+   <slot>setDisabled(bool)</slot>
    <hints>
-    <hint type="sourcelabel" >
-     <x>20</x>
-     <y>20</y>
+    <hint type="sourcelabel">
+     <x>157</x>
+     <y>363</y>
     </hint>
-    <hint type="destinationlabel" >
-     <x>20</x>
-     <y>20</y>
+    <hint type="destinationlabel">
+     <x>438</x>
+     <y>449</y>
     </hint>
    </hints>
   </connection>
diff --git a/konqueror/settings/kio/kproxydlgbase.cpp b/konqueror/settings/kio/kproxydlgbase.cpp
deleted file mode 100644
index 9933698..0000000
--- a/konqueror/settings/kio/kproxydlgbase.cpp
+++ /dev/null
@@ -1,79 +0,0 @@
- /*
-   kproxydlgbase.h - Base dialog box for proxy configuration
-
-   Copyright (C) 2001- Dawit Alemayehu <adawit at kde.org>
-
-   This library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU General Public
-   License (GPL) version 2 as published by the Free Software
-   Foundation.
-
-   This library 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
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this library; see the file COPYING.LIB.  If not, write to
-   the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-   Boston, MA 02110-1301, USA.
-*/
-
-#include "kproxydlgbase.h"
-
-KProxyData::KProxyData()
-{
-  init ();
-}
-
-KProxyData::KProxyData(const KProxyData &data)
-{
-  (*this) = data;
-}
-
-KProxyData& KProxyData::operator=( const KProxyData &data )
-{
-  useReverseProxy = data.useReverseProxy;
-  showEnvVarValue = data.showEnvVarValue;
-  noProxyFor = data.noProxyFor;
-  proxyList = data.proxyList;
-  type = data.type;
-
-  return (*this);
-}
-
-void KProxyData::reset()
-{
-  init();
-}
-
-void KProxyData::init()
-{
-  proxyList.clear();
-  noProxyFor.clear();
-  useReverseProxy = false;
-  showEnvVarValue = false;
-}
-
-
-KProxyDialogBase::KProxyDialogBase( QWidget* parent, const char* name,
-                                    bool modal, const QString &caption )
-  : KDialog( parent )
-{
-  setObjectName( name );
-  setModal( modal );
-  setCaption( caption );
-  setButtons( Ok|Cancel );
-
-  m_bHasValidData = false;
-}
-
-void KProxyDialogBase::setHighLight (QWidget* widget, bool highlight)
-{
-  if (!widget)
-    return;
-
-  QFont f = widget->font();
-  f.setBold( highlight );
-  widget->setFont( f );
-}
diff --git a/konqueror/settings/kio/kproxydlgbase.h b/konqueror/settings/kio/kproxydlgbase.h
deleted file mode 100644
index 2047b90..0000000
--- a/konqueror/settings/kio/kproxydlgbase.h
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
-   kproxydlgbase.h - Base dialog box for proxy configuration
-
-   Copyright (C) 2001- Dawit Alemayehu <adawit at kde.org>
-
-   This library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU General Public
-   License (GPL) version 2 as published by the Free Software
-   Foundation.
-
-   This library 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
-   Library General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this library; see the file COPYING.LIB.  If not, write to
-   the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-   Boston, MA 02110-1301, USA.
-*/
-
-#ifndef KPROXYDLGBASE_H
-#define KPROXYDLGBASE_H
-
-#include <QtCore/QMap>
-
-#include <QtCore/QStringList>
-
-#include <kdialog.h>
-#include <kprotocolmanager.h>
-
-class KProxyData
-{
-public:
-  KProxyData();
-  KProxyData( const KProxyData &data );
-
-  void reset ();
-  KProxyData& operator=( const KProxyData &data );
-
-  bool useReverseProxy;
-  bool showEnvVarValue;
-  QStringList noProxyFor;
-  KProtocolManager::ProxyType type;
-  QMap<QString, QString> proxyList;
-
-private:
-  void init();
-};
-
-
-class KProxyDialogBase : public KDialog
-{
-public:
-  explicit KProxyDialogBase( QWidget* parent = 0, const char* name = 0,
-                    bool modal = false, const QString &caption = QString());
-
-  virtual ~KProxyDialogBase() {}
-
-  virtual const KProxyData data() const=0;
-
-  virtual void setProxyData (const KProxyData&)=0;
-
-protected:
-  void setHighLight (QWidget* widget = 0, bool highlight = false);
-  bool m_bHasValidData;
-};
-
-#endif // KPROXYDLGBASE_H
diff --git a/konqueror/settings/kio/ksaveioconfig.cpp b/konqueror/settings/kio/ksaveioconfig.cpp
index 62852fa..7d08d24 100644
--- a/konqueror/settings/kio/ksaveioconfig.cpp
+++ b/konqueror/settings/kio/ksaveioconfig.cpp
@@ -26,9 +26,10 @@
 // KDE
 #include <kconfig.h>
 #include <klocale.h>
+#include <kdebug.h>
 #include <kmessagebox.h>
-#include <kio/ioslave_defaults.h>
 #include <kconfiggroup.h>
+#include <kio/ioslave_defaults.h>
 
 class KSaveIOConfigPrivate
 {
@@ -42,7 +43,8 @@ public:
 
 K_GLOBAL_STATIC(KSaveIOConfigPrivate, d)
 
-KSaveIOConfigPrivate::KSaveIOConfigPrivate (): config(0), http_config(0)
+KSaveIOConfigPrivate::KSaveIOConfigPrivate ()
+                     : config(0), http_config(0)
 {
 }
 
@@ -68,6 +70,19 @@ static KConfig* http_config()
   return d->http_config;
 }
 
+int KSaveIOConfig::proxyDisplayUrlFlags()
+{
+    KConfigGroup cfg (config(), QString());
+    return cfg.readEntry("ProxyUrlDisplayFlags", 0);
+}
+
+void KSaveIOConfig::setProxyDisplayUrlFlags (int flags)
+{
+    KConfigGroup cfg (config(), QString());
+    cfg.writeEntry("ProxyUrlDisplayFlags", flags);
+    cfg.sync();
+}
+
 void KSaveIOConfig::reparseConfiguration ()
 {
   delete d->config;
@@ -78,170 +93,144 @@ void KSaveIOConfig::reparseConfiguration ()
 
 void KSaveIOConfig::setReadTimeout( int _timeout )
 {
-  KConfig* cfg = config();
-  cfg->group("").writeEntry("ReadTimeout", qMax(MIN_TIMEOUT_VALUE,_timeout));
-  cfg->sync();
+  KConfigGroup cfg (config(), QString());
+  cfg.writeEntry("ReadTimeout", qMax(MIN_TIMEOUT_VALUE,_timeout));
+  cfg.sync();
 }
 
 void KSaveIOConfig::setConnectTimeout( int _timeout )
 {
-  KConfig* cfg = config();
-  cfg->group("").writeEntry("ConnectTimeout", qMax(MIN_TIMEOUT_VALUE,_timeout));
-  cfg->sync();
+  KConfigGroup cfg (config(), QString());
+  cfg.writeEntry("ConnectTimeout", qMax(MIN_TIMEOUT_VALUE,_timeout));
+  cfg.sync();
 }
 
 void KSaveIOConfig::setProxyConnectTimeout( int _timeout )
 {
-  KConfig* cfg = config();
-  cfg->group("").writeEntry("ProxyConnectTimeout", qMax(MIN_TIMEOUT_VALUE,_timeout));
-  cfg->sync();
+  KConfigGroup cfg (config(), QString());
+  cfg.writeEntry("ProxyConnectTimeout", qMax(MIN_TIMEOUT_VALUE,_timeout));
+  cfg.sync();
 }
 
 void KSaveIOConfig::setResponseTimeout( int _timeout )
 {
-  KConfig* cfg = config();
-  cfg->group("").writeEntry("ResponseTimeout", qMax(MIN_TIMEOUT_VALUE,_timeout));
-  cfg->sync();
+  KConfigGroup cfg (config(), QString());
+  cfg.writeEntry("ResponseTimeout", qMax(MIN_TIMEOUT_VALUE,_timeout));
+  cfg.sync();
 }
 
 
 void KSaveIOConfig::setMarkPartial( bool _mode )
 {
-  KConfig* cfg = config();
-  cfg->group("").writeEntry( "MarkPartial", _mode );
-  cfg->sync();
+  KConfigGroup cfg (config(), QString());
+  cfg.writeEntry( "MarkPartial", _mode );
+  cfg.sync();
 }
 
 void KSaveIOConfig::setMinimumKeepSize( int _size )
 {
-  KConfig* cfg = config();
-  cfg->group("").writeEntry( "MinimumKeepSize", _size );
-  cfg->sync();
+  KConfigGroup cfg (config(), QString());
+  cfg.writeEntry( "MinimumKeepSize", _size );
+  cfg.sync();
 }
 
 void KSaveIOConfig::setAutoResume( bool _mode )
 {
-  KConfig* cfg = config();
-  cfg->group("").writeEntry( "AutoResume", _mode );
-  cfg->sync();
+  KConfigGroup cfg (config(), QString());
+  cfg.writeEntry( "AutoResume", _mode );
+  cfg.sync();
 }
 
 void KSaveIOConfig::setUseCache( bool _mode )
 {
-  KConfig* cfg = http_config();
-  cfg->group("").writeEntry( "UseCache", _mode );
-  cfg->sync();
+  KConfigGroup cfg (http_config(), QString());
+  cfg.writeEntry( "UseCache", _mode );
+  cfg.sync();
 }
 
 void KSaveIOConfig::setMaxCacheSize( int cache_size )
 {
-  KConfig* cfg = http_config();
-  cfg->group("").writeEntry( "MaxCacheSize", cache_size );
-  cfg->sync();
+  KConfigGroup cfg (http_config(), QString());
+  cfg.writeEntry( "MaxCacheSize", cache_size );
+  cfg.sync();
 }
 
 void KSaveIOConfig::setCacheControl(KIO::CacheControl policy)
 {
-  KConfig* cfg = http_config();
+  KConfigGroup cfg (http_config(), QString());
   QString tmp = KIO::getCacheControlString(policy);
-  cfg->group("").writeEntry("cache", tmp);
-  cfg->sync();
+  cfg.writeEntry("cache", tmp);
+  cfg.sync();
 }
 
 void KSaveIOConfig::setMaxCacheAge( int cache_age )
 {
-  KConfig* cfg = http_config();
-  cfg->group("").writeEntry( "MaxCacheAge", cache_age );
-  cfg->sync();
+  KConfigGroup cfg (http_config(), QString());
+  cfg.writeEntry( "MaxCacheAge", cache_age );
+  cfg.sync();
 }
 
 void KSaveIOConfig::setUseReverseProxy( bool mode )
 {
-  KConfig* cfg = config();
-  cfg->group("Proxy Settings").writeEntry("ReversedException", mode);
-  cfg->sync();
+  KConfigGroup cfg (config(), "Proxy Settings");
+  cfg.writeEntry("ReversedException", mode);
+  cfg.sync();
 }
 
 void KSaveIOConfig::setProxyType(KProtocolManager::ProxyType type)
 {
-  KConfig* cfg = config();
-  cfg->group("Proxy Settings").writeEntry( "ProxyType", static_cast<int>(type) );
-  cfg->sync();
-}
-
-void KSaveIOConfig::setProxyAuthMode(KProtocolManager::ProxyAuthMode mode)
-{
-  KConfig* cfg = config();
-  cfg->group("Proxy Settings").writeEntry( "AuthMode", static_cast<int>(mode) );
-  cfg->sync();
+  KConfigGroup cfg (config(), "Proxy Settings");
+  cfg.writeEntry("ProxyType", static_cast<int>(type));
+  cfg.sync();
 }
 
 void KSaveIOConfig::setNoProxyFor( const QString& _noproxy )
 {
-  KConfig* cfg = config();
-  cfg->group("Proxy Settings").writeEntry( "NoProxyFor", _noproxy );
-  cfg->sync();
+  KConfigGroup cfg (config(), "Proxy Settings");
+  cfg.writeEntry("NoProxyFor", _noproxy);
+  cfg.sync();
 }
 
 void KSaveIOConfig::setProxyFor( const QString& protocol,
                                  const QString& _proxy )
 {
-  KConfig* cfg = config();
-  cfg->group("Proxy Settings").writeEntry( protocol.toLower() + "Proxy", _proxy );
-  cfg->sync();
+  KConfigGroup cfg (config(), "Proxy Settings");
+  cfg.writeEntry(protocol.toLower() + "Proxy", _proxy);
+  cfg.sync();
 }
 
 void KSaveIOConfig::setProxyConfigScript( const QString& _url )
 {
-  KConfig* cfg = config();
-  cfg->group("Proxy Settings").writeEntry( "Proxy Config Script", _url );
-  cfg->sync();
-}
-
-void KSaveIOConfig::setPersistentProxyConnection( bool enable )
-{
-  KConfig* cfg = config();
-  cfg->group("").writeEntry( "PersistentProxyConnection", enable );
-  cfg->sync();
-}
-
-void KSaveIOConfig::setPersistentConnections( bool enable )
-{
-  KConfig* cfg = config();
-  cfg->group("").writeEntry( "PersistentConnections", enable );
-  cfg->sync();
+  KConfigGroup cfg (config(), "Proxy Settings");
+  cfg.writeEntry("Proxy Config Script", _url);
+  cfg.sync();
 }
 
 void KSaveIOConfig::updateRunningIOSlaves (QWidget *parent)
 {
   // Inform all running io-slaves about the changes...
   // if we cannot update, ioslaves inform the end user...
-  QDBusMessage message =
-          QDBusMessage::createSignal("/KIO/Scheduler", "org.kde.KIO.Scheduler", "reparseSlaveConfiguration");
+  QDBusMessage message = QDBusMessage::createSignal("/KIO/Scheduler", "org.kde.KIO.Scheduler", "reparseSlaveConfiguration");
   message << QString();
   if (!QDBusConnection::sessionBus().send(message))
   {
-    QString caption = i18nc("@title:window", "Update Failed");
-    QString message = i18n("You have to restart the running applications "
-                           "for these changes to take effect.");
-    KMessageBox::information (parent, message, caption);
-    return;
+    KMessageBox::information (parent,
+                              i18n("You have to restart the running applications "
+                                   "for these changes to take effect."),
+                              i18nc("@title:window", "Update Failed"));
   }
 }
 
 void KSaveIOConfig::updateProxyScout( QWidget * parent )
 {
-  // Inform the proxyscout kded module about changes
-  // if we cannot update, ioslaves inform the end user...
-    QDBusInterface kded("org.kde.kded", "/modules/proxyscout", "org.kde.KPAC.ProxyScout");
-    QDBusReply<void> reply = kded.call( "reset" );
+  // Inform the proxyscout kded module about changes if we cannot update,
+  // ioslaves inform the end user...
+  QDBusInterface kded("org.kde.kded", "/modules/proxyscout", "org.kde.KPAC.ProxyScout");
+  QDBusReply<void> reply = kded.call("reset");
   if (!reply.isValid())
   {
-    QString caption = i18nc("@title:window", "Update Failed");
-    QString message = i18n("You have to restart KDE "
-                           "for these changes to take effect.");
-    KMessageBox::information (parent, message, caption);
-    return;
+    KMessageBox::information (parent,
+                              i18n("You have to restart KDE for these changes to take effect."),
+                              i18nc("@title:window", "Update Failed"));
   }
 }
-
diff --git a/konqueror/settings/kio/ksaveioconfig.h b/konqueror/settings/kio/ksaveioconfig.h
index e895c2c..2318198 100644
--- a/konqueror/settings/kio/ksaveioconfig.h
+++ b/konqueror/settings/kio/ksaveioconfig.h
@@ -26,60 +26,56 @@ class QWidget;
 
 namespace KSaveIOConfig
 {
-  /* Reload config file (kioslaverc) */
-  void reparseConfiguration();
+int proxyDisplayUrlFlags();
+void setProxyDisplayUrlFlags (int);
 
-  /** Timeout Settings */
-  void setReadTimeout( int );
+/* Reload config file (kioslaverc) */
+void reparseConfiguration();
 
-  void setConnectTimeout( int );
+/** Timeout Settings */
+void setReadTimeout (int);
 
-  void setProxyConnectTimeout( int );
+void setConnectTimeout (int);
 
-  void setResponseTimeout( int );
+void setProxyConnectTimeout (int);
 
+void setResponseTimeout (int);
 
-  /** Cache Settings */
-  void setMaxCacheAge( int );
 
-  void setUseCache( bool );
+/** Cache Settings */
+void setMaxCacheAge (int);
 
-  void setMaxCacheSize( int );
+void setUseCache (bool);
 
-  void setCacheControl( KIO::CacheControl );
+void setMaxCacheSize (int);
 
+void setCacheControl (KIO::CacheControl);
 
-  /** Proxy Settings */
-  void setUseReverseProxy( bool );
 
-  void setProxyType( KProtocolManager::ProxyType );
+/** Proxy Settings */
+void setUseReverseProxy (bool);
 
-  void setProxyAuthMode( KProtocolManager::ProxyAuthMode );
+void setProxyType (KProtocolManager::ProxyType);
 
-  void setProxyConfigScript( const QString&  );
+void setProxyConfigScript (const QString&);
 
-  void setProxyFor( const QString&, const QString&  );
+void setProxyFor (const QString&, const QString&);
 
-  void setNoProxyFor( const QString& );
+void setNoProxyFor (const QString&);
 
 
-  /** Miscellaneous Settings */
-  void setMarkPartial( bool );
+/** Miscellaneous Settings */
+void setMarkPartial (bool);
 
-  void setMinimumKeepSize( int );
+void setMinimumKeepSize (int);
 
-  void setAutoResume( bool );
+void setAutoResume (bool);
 
-  void setPersistentConnections( bool );
+/** Update all running io-slaves */
+void updateRunningIOSlaves (QWidget* parent = 0L);
 
-  void setPersistentProxyConnection( bool );
-
-
-  /** Update all running io-slaves */
-  void updateRunningIOSlaves (QWidget * parent = 0L);
-
-  /** Update proxy scout */
-  void updateProxyScout( QWidget * parent = 0L );
+/** Update proxy scout */
+void updateProxyScout (QWidget* parent = 0L);
 }
 
 #endif
diff --git a/konqueror/settings/kio/manualproxy.ui b/konqueror/settings/kio/manualproxy.ui
deleted file mode 100644
index c69047f..0000000
--- a/konqueror/settings/kio/manualproxy.ui
+++ /dev/null
@@ -1,291 +0,0 @@
-<ui version="4.0" >
- <class>ManualProxyDlgUI</class>
- <widget class="QWidget" name="ManualProxyDlgUI" >
-  <property name="geometry" >
-   <rect>
-    <x>0</x>
-    <y>0</y>
-    <width>488</width>
-    <height>390</height>
-   </rect>
-  </property>
-  <layout class="QVBoxLayout" >
-   <item>
-    <widget class="QGroupBox" name="gbServers" >
-     <property name="title" >
-      <string>Ser&vers</string>
-     </property>
-     <layout class="QGridLayout" >
-      <item row="2" column="0" >
-       <widget class="QLabel" name="lbFtp" >
-        <property name="sizePolicy" >
-         <sizepolicy vsizetype="Preferred" hsizetype="Fixed" >
-          <horstretch>0</horstretch>
-          <verstretch>0</verstretch>
-         </sizepolicy>
-        </property>
-        <property name="text" >
-         <string>&FTP:</string>
-        </property>
-        <property name="wordWrap" >
-         <bool>false</bool>
-        </property>
-        <property name="buddy" >
-         <cstring>leFtp</cstring>
-        </property>
-       </widget>
-      </item>
-      <item row="1" column="0" >
-       <widget class="QLabel" name="lbHttps" >
-        <property name="sizePolicy" >
-         <sizepolicy vsizetype="Preferred" hsizetype="Fixed" >
-          <horstretch>0</horstretch>
-          <verstretch>0</verstretch>
-         </sizepolicy>
-        </property>
-        <property name="text" >
-         <string>HTTP&S:</string>
-        </property>
-        <property name="wordWrap" >
-         <bool>false</bool>
-        </property>
-        <property name="buddy" >
-         <cstring>leHttps</cstring>
-        </property>
-       </widget>
-      </item>
-      <item row="0" column="0" >
-       <widget class="QLabel" name="lbHttp" >
-        <property name="sizePolicy" >
-         <sizepolicy vsizetype="Preferred" hsizetype="Fixed" >
-          <horstretch>0</horstretch>
-          <verstretch>0</verstretch>
-         </sizepolicy>
-        </property>
-        <property name="text" >
-         <string>H&TTP:</string>
-        </property>
-        <property name="wordWrap" >
-         <bool>false</bool>
-        </property>
-        <property name="buddy" >
-         <cstring>leHttp</cstring>
-        </property>
-       </widget>
-      </item>
-      <item row="0" column="1" >
-       <widget class="KLineEdit" name="leHttp" >
-        <property name="whatsThis" >
-         <string>Enter the address of the HTTP proxy server.</string>
-        </property>
-       </widget>
-      </item>
-      <item row="1" column="1" >
-       <widget class="KLineEdit" name="leHttps" >
-        <property name="whatsThis" >
-         <string>Enter the address of the HTTPS proxy server.</string>
-        </property>
-       </widget>
-      </item>
-      <item row="2" column="1" >
-       <widget class="KLineEdit" name="leFtp" >
-        <property name="whatsThis" >
-         <string>Enter the address of the FTP proxy server.</string>
-        </property>
-       </widget>
-      </item>
-      <item row="2" column="2" >
-       <widget class="KIntSpinBox" name="sbFtp" >
-        <property name="whatsThis" >
-         <string>Enter the port number of the FTP proxy server. Default 8080. Another common value is 3128.</string>
-        </property>
-        <property name="maximum" >
-         <number>65536</number>
-        </property>
-       </widget>
-      </item>
-      <item row="1" column="2" >
-       <widget class="KIntSpinBox" name="sbHttps" >
-        <property name="whatsThis" >
-         <string>Enter the port number of the HTTP proxy server. Default is 8080. Another common value is 3128.</string>
-        </property>
-        <property name="maximum" >
-         <number>65536</number>
-        </property>
-       </widget>
-      </item>
-      <item row="0" column="2" >
-       <widget class="KIntSpinBox" name="sbHttp" >
-        <property name="maximumSize" >
-         <size>
-          <width>32767</width>
-          <height>32767</height>
-         </size>
-        </property>
-        <property name="whatsThis" >
-         <string>Enter the port number of the HTTP proxy server. Default is 8080. Another common value is 3128.</string>
-        </property>
-        <property name="maximum" >
-         <number>65536</number>
-        </property>
-       </widget>
-      </item>
-      <item row="3" column="1" colspan="2" >
-       <widget class="QCheckBox" name="cbSameProxy" >
-        <property name="text" >
-         <string>&Use the same proxy server for all protocols</string>
-        </property>
-       </widget>
-      </item>
-      <item row="0" column="3" >
-       <widget class="QPushButton" name="pbCopyDown" >
-        <property name="text" >
-         <string/>
-        </property>
-       </widget>
-      </item>
-     </layout>
-    </widget>
-   </item>
-   <item>
-    <widget class="QGroupBox" name="gbExceptions" >
-     <property name="title" >
-      <string>E&xceptions</string>
-     </property>
-     <layout class="QVBoxLayout" >
-      <item>
-       <widget class="QCheckBox" name="cbReverseProxy" >
-        <property name="whatsThis" >
-         <string><qt>
-Reverse the use of the exception list. Checking this box will result in the proxy servers being used only when the requested URL matches one of the addresses listed here.<p>This feature is useful if all you want or need is to use a proxy server  for a few specific sites.<p>If you have more complex requirements you might want to use a configuration script.
-</qt></string>
-        </property>
-        <property name="text" >
-         <string>Use proxy only for entries in this list</string>
-        </property>
-       </widget>
-      </item>
-      <item>
-       <layout class="QGridLayout" >
-        <property name="leftMargin" >
-         <number>0</number>
-        </property>
-        <property name="topMargin" >
-         <number>0</number>
-        </property>
-        <property name="rightMargin" >
-         <number>0</number>
-        </property>
-        <property name="bottomMargin" >
-         <number>0</number>
-        </property>
-        <item row="3" column="1" >
-         <widget class="QPushButton" name="pbDeleteAll" >
-          <property name="enabled" >
-           <bool>false</bool>
-          </property>
-          <property name="whatsThis" >
-           <string>Remove all proxy exception addresses from the list.</string>
-          </property>
-          <property name="text" >
-           <string>D&elete All</string>
-          </property>
-         </widget>
-        </item>
-        <item row="2" column="1" >
-         <widget class="QPushButton" name="pbDelete" >
-          <property name="enabled" >
-           <bool>false</bool>
-          </property>
-          <property name="whatsThis" >
-           <string>Remove the selected proxy exception address from the list.</string>
-          </property>
-          <property name="text" >
-           <string>De&lete</string>
-          </property>
-         </widget>
-        </item>
-        <item row="0" column="1" >
-         <widget class="QPushButton" name="pbNew" >
-          <property name="whatsThis" >
-           <string>Add new proxy exception address to the list.</string>
-          </property>
-          <property name="text" >
-           <string>&New...</string>
-          </property>
-         </widget>
-        </item>
-        <item row="1" column="1" >
-         <widget class="QPushButton" name="pbChange" >
-          <property name="enabled" >
-           <bool>false</bool>
-          </property>
-          <property name="whatsThis" >
-           <string>Change the selected proxy exception address.</string>
-          </property>
-          <property name="text" >
-           <string>C&hange...</string>
-          </property>
-         </widget>
-        </item>
-        <item row="4" column="1" >
-         <spacer>
-          <property name="orientation" >
-           <enum>Qt::Vertical</enum>
-          </property>
-          <property name="sizeType" >
-           <enum>QSizePolicy::Expanding</enum>
-          </property>
-          <property name="sizeHint" >
-           <size>
-            <width>20</width>
-            <height>114</height>
-           </size>
-          </property>
-         </spacer>
-        </item>
-        <item rowspan="5" row="0" column="0" >
-         <widget class="KListWidget" name="lbExceptions" />
-        </item>
-       </layout>
-      </item>
-     </layout>
-    </widget>
-   </item>
-  </layout>
- </widget>
- <customwidgets>
-  <customwidget>
-   <class>KIntSpinBox</class>
-   <extends>QSpinBox</extends>
-   <header>knuminput.h</header>
-  </customwidget>
-  <customwidget>
-   <class>KLineEdit</class>
-   <extends>QLineEdit</extends>
-   <header>klineedit.h</header>
-  </customwidget>
-  <customwidget>
-   <class>KListWidget</class>
-   <extends>QListWidget</extends>
-   <header>klistwidget.h</header>
-  </customwidget>
- </customwidgets>
- <tabstops>
-  <tabstop>leHttp</tabstop>
-  <tabstop>sbHttp</tabstop>
-  <tabstop>leHttps</tabstop>
-  <tabstop>sbHttps</tabstop>
-  <tabstop>leFtp</tabstop>
-  <tabstop>sbFtp</tabstop>
-  <tabstop>cbSameProxy</tabstop>
-  <tabstop>pbCopyDown</tabstop>
-  <tabstop>cbReverseProxy</tabstop>
-  <tabstop>pbNew</tabstop>
-  <tabstop>pbChange</tabstop>
-  <tabstop>pbDelete</tabstop>
-  <tabstop>pbDeleteAll</tabstop>
- </tabstops>
- <resources/>
- <connections/>
-</ui>


More information about the kde-doc-english mailing list