summaryrefslogtreecommitdiff
path: root/noncore/applets/pcmcia/configdialog.cpp
authormickeyl <mickeyl>2005-06-14 13:15:05 (UTC)
committer mickeyl <mickeyl>2005-06-14 13:15:05 (UTC)
commit7d8d317205a74bc2e23291ab4909472db6694091 (patch) (unidiff)
tree7fdf8d039a30f26316fb57edbe53462d1b38b654 /noncore/applets/pcmcia/configdialog.cpp
parentc1194d42d8456417452b125bd6c2c5048d7bbe02 (diff)
downloadopie-7d8d317205a74bc2e23291ab4909472db6694091.zip
opie-7d8d317205a74bc2e23291ab4909472db6694091.tar.gz
opie-7d8d317205a74bc2e23291ab4909472db6694091.tar.bz2
more work on configuring unsupported cards
Diffstat (limited to 'noncore/applets/pcmcia/configdialog.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/applets/pcmcia/configdialog.cpp32
1 files changed, 25 insertions, 7 deletions
diff --git a/noncore/applets/pcmcia/configdialog.cpp b/noncore/applets/pcmcia/configdialog.cpp
index e161d18..9fcf58c 100644
--- a/noncore/applets/pcmcia/configdialog.cpp
+++ b/noncore/applets/pcmcia/configdialog.cpp
@@ -34,2 +34,3 @@
34#include <opie2/odebug.h> 34#include <opie2/odebug.h>
35#include <opie2/opcmciasystem.h>
35using namespace Opie::Core; 36using namespace Opie::Core;
@@ -40,2 +41,3 @@ using namespace Opie::Core;
40#include <qfile.h> 41#include <qfile.h>
42#include <qgroupbox.h>
41#include <qlabel.h> 43#include <qlabel.h>
@@ -43,7 +45,9 @@ using namespace Opie::Core;
43 45
44ConfigDialog::ConfigDialog( const QString& cardname, QWidget* parent ) 46ConfigDialog::ConfigDialog( const OPcmciaSocket* card, QWidget* parent )
45 :ConfigDialogBase( parent, "pcmcia config dialog", true ) 47 :ConfigDialogBase( parent, "pcmcia config dialog", true )
46{ 48{
47 //setCaption( tr( "Configure %1" ).arg( cardname ) ); 49 gbDetails->setTitle( QString( "Details for '%1'" ).arg( card->identity() ) );
48 txtCardName->setText( cardname ); 50 txtCardName->setText( card->productIdentity().join( " " ) );
51 txtManfid->setText( card->manufacturerIdentity() );
52 txtFunction->setText( card->function() );
49 53
@@ -59,4 +63,4 @@ ConfigDialog::ConfigDialog( const QString& cardname, QWidget* parent )
59 QString name = cfg.readEntry( "name" ); 63 QString name = cfg.readEntry( "name" );
60 odebug << "comparing card '" << cardname << "' with known card '" << name << "'" << oendl; 64 odebug << "comparing card '" << card->name() << "' with known card '" << name << "'" << oendl;
61 if ( cardname == name ) 65 if ( card->name() == name )
62 { 66 {
@@ -66,3 +70,3 @@ ConfigDialog::ConfigDialog( const QString& cardname, QWidget* parent )
66 } 70 }
67 odebug << "preferred action for card '" << cardname << "' seems to be '" << insert << "'" << oendl; 71 odebug << "preferred action for card '" << card->name() << "' seems to be '" << insert << "'" << oendl;
68 72
@@ -74,2 +78,16 @@ ConfigDialog::ConfigDialog( const QString& cardname, QWidget* parent )
74 78
79 if ( !card->isUnsupported() )
80 {
81 odebug << "card is recognized - hiding bindings" << oendl;
82 textBindTo->hide();
83 cbBindTo->hide();
84 return;
85 }
86 else
87 {
88 odebug << "card is unsupported yet - showing possible bindings" << oendl;
89 textBindTo->show();
90 cbBindTo->show();
91 }
92
75 // parse possible bind entries out of /etc/pcmcia/*.conf 93 // parse possible bind entries out of /etc/pcmcia/*.conf
@@ -110,3 +128,3 @@ ConfigDialog::ConfigDialog( const QString& cardname, QWidget* parent )
110 { 128 {
111 odebug << "found device '" << it.key() << "' defined in '" << it.data().latin1() << "'" << oendl; 129 odebug << "found binding '" << it.key() << "' defined in '" << it.data().latin1() << "'" << oendl;
112 cbBindTo->insertItem( it.key() ); 130 cbBindTo->insertItem( it.key() );