[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdebase/knetattach
From:       Kévin Ottens <ervin () ipsquad ! net>
Date:       2004-12-15 21:03:11
Message-ID: 20041215210311.3F6001BA59 () office ! kde ! org
[Download RAW message or body]

CVS commit by ervin: 

Text on the second page is now displayed correctly, even for recent connections.

BUG: 95171


  M +1 -0      knetattach.ui   1.8
  M +17 -5     knetattach.ui.h   1.7


--- kdebase/knetattach/knetattach.ui  #1.7:1.8
@@ -385,4 +385,5 @@
     <function access="private" returnType="bool">doConnectionTest( const KURL &amp; \
                url )</function>
     <function access="private" returnType="bool">updateForProtocol( const QString \
&amp; protocol )</function> +    <function access="private" \
returnType="void">setInformationText( const QString &amp; type )</function>  \
</functions>  <layoutdefaults spacing="6" margin="11"/>

--- kdebase/knetattach/knetattach.ui.h  #1.6:1.7
@@ -33,4 +33,17 @@ void KNetAttach::init()
 }
 
+void KNetAttach::setInformationText( const QString &type )
+{
+    QString text = "Enter a name for this <i>%1</i> as well as a server address, \
port and folder path to use and press the <b>Save & Connect</b> button."; +    
+    if (type=="WebFolder") {
+        _informationText->setText(text .arg("WebFolder"));
+    } else if (type=="Fish") {
+        _informationText->setText(text .arg("Secure shell connection"));
+    } else if (type=="SMB") {
+        text = "Enter a name for this <i>%1</i> as well as a server address and \
folder path to use and press the <b>Save & Connect</b> button."; +        \
_informationText->setText(text.arg("Microsoft® Windows® network drive")); +    }
+}
 
 void KNetAttach::showPage( QWidget *page )
@@ -39,18 +52,16 @@ void KNetAttach::showPage( QWidget *page
     } else if (page == _folderParameters) {
         _host->setFocus();
-        QString text = "Enter a name for this <i>%1</i> as well as a server address, \
port and folder path to use and press the <b>Save & Connect</b> button.";  \
_connectionName->setFocus();  
         if (_webfolder->isChecked()) {
-            _informationText->setText(text .arg("WebFolder"));
+            setInformationText("WebFolder");
             updateForProtocol("WebFolder");
             _port->setValue(80);
         } else if (_fish->isChecked()) {
-            _informationText->setText(text.arg("Secure shell connection"));
+            setInformationText("Fish");
             updateForProtocol("Fish");
             _port->setValue(22);
         } else if (_smb->isChecked()) {
-            text = "Enter a name for this <i>%1</i> as well as a server address and \
                folder path to use and press the <b>Save & Connect</b> button.";
-             _informationText->setText(text.arg("Microsoft® Windows® network \
drive")); +            setInformationText("SMB");
             updateForProtocol("SMB");
         } else { //if (_recent->isChecked()) {
@@ -73,4 +84,5 @@ void KNetAttach::showPage( QWidget *page
             recent.setGroup(_recentConnectionName->currentText());
             _type = recent.readEntry("Type");
+            setInformationText(_type);
             if (!updateForProtocol(_type)) {
                 // FIXME: handle error


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic