summaryrefslogtreecommitdiff
path: root/noncore
Unidiff
Diffstat (limited to 'noncore') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/opietooth/manager/scandialog.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/noncore/net/opietooth/manager/scandialog.cpp b/noncore/net/opietooth/manager/scandialog.cpp
index e81b2ee..b0ffbb3 100644
--- a/noncore/net/opietooth/manager/scandialog.cpp
+++ b/noncore/net/opietooth/manager/scandialog.cpp
@@ -60,24 +60,24 @@ namespace OpieTooth {
60 60
61 61
62 progress = new QProgressBar(privateLayoutWidget, "progbar"); 62 progress = new QProgressBar(privateLayoutWidget, "progbar");
63 progress->setTotalSteps(20); 63 progress->setTotalSteps(20);
64 64
65 65
66 QFrame *buttonFrame = new QFrame(Frame7, ""); 66 QFrame *buttonFrame = new QFrame(Frame7, "");
67 67
68 StartButton = new QPushButton( buttonFrame, "StartButton" ); 68 StartButton = new QPushButton( buttonFrame, "StartButton" );
69 StartButton->setText( tr( "Start" ) ); 69 StartButton->setText( tr( "Start" ) );
70 70
71 StopButton = new QPushButton( buttonFrame, "StopButton" ); 71 StopButton = new QPushButton( buttonFrame, "StopButton" );
72 StopButton->setText( tr( "Cancel" ) ); 72 StopButton->setText( tr( "Cancel" ) );
73 73
74 74
75 QHBoxLayout *buttonLayout = new QHBoxLayout(buttonFrame); 75 QHBoxLayout *buttonLayout = new QHBoxLayout(buttonFrame);
76 buttonLayout->addWidget(StartButton); 76 buttonLayout->addWidget(StartButton);
77 buttonLayout->addWidget(StopButton); 77 buttonLayout->addWidget(StopButton);
78 78
79 ListView1 = new QListView( privateLayoutWidget, "ListView1" ); 79 ListView1 = new QListView( privateLayoutWidget, "ListView1" );
80 80
81 ListView1->addColumn( tr( "Add" ) ); 81 ListView1->addColumn( tr( "Add" ) );
82 ListView1->addColumn( tr( "Device Name" ) ); 82 ListView1->addColumn( tr( "Device Name" ) );
83 //ListView1->addColumn( tr( "Type" ) ); 83 //ListView1->addColumn( tr( "Type" ) );
@@ -93,30 +93,30 @@ namespace OpieTooth {
93 connect( (QObject*)localDevice, SIGNAL( foundDevices( const QString& , RemoteDevices::ValueList ) ), 93 connect( (QObject*)localDevice, SIGNAL( foundDevices( const QString& , RemoteDevices::ValueList ) ),
94 this, SLOT(fillList(const QString& , RemoteDevices::ValueList ) ) ) ; 94 this, SLOT(fillList(const QString& , RemoteDevices::ValueList ) ) ) ;
95 progressStat = 0; 95 progressStat = 0;
96 } 96 }
97 97
98// hack, make cleaner later 98// hack, make cleaner later
99 void ScanDialog::progressTimer(int maxSeconds) { 99 void ScanDialog::progressTimer() {
100 100
101 progressStat++; 101 progressStat++;
102 if (progressStat++ < maxSeconds) { 102 if (progressStat++ < 20) {
103 QTimer::singleShot( 1000, this, SLOT(progressTimer ) ); 103 QTimer::singleShot( 1000, this, SLOT(progressTimer() ) );
104 } 104 }
105 105
106 } 106 }
107 107
108 void ScanDialog::startSearch() { 108 void ScanDialog::startSearch() {
109 progress->setProgress(0); 109 progress->setProgress(0);
110 progressStat = 0; 110 progressStat = 0;
111 111
112 progressTimer(20); 112 progressTimer();
113 // when finished, it emmite foundDevices() 113 // when finished, it emmite foundDevices()
114 // checken ob initialisiert , qcop ans applet. 114 // checken ob initialisiert , qcop ans applet.
115 localDevice->searchDevices(); 115 localDevice->searchDevices();
116 progress->setProgress(20); 116
117 } 117 }
118 118
119 void ScanDialog::stopSearch() { 119 void ScanDialog::stopSearch() {
120 120
121 } 121 }
122 122