summaryrefslogtreecommitdiff
authorllornkcor <llornkcor>2002-11-16 15:13:23 (UTC)
committer llornkcor <llornkcor>2002-11-16 15:13:23 (UTC)
commit1fde54b44ba888094fc47201567ea9454857f5a1 (patch) (unidiff)
tree955a367a304554a0adc8193a193b31c996a15bf0
parent91b18bba79406b6ff54ca7f1360035eceefee378 (diff)
downloadopie-1fde54b44ba888094fc47201567ea9454857f5a1.zip
opie-1fde54b44ba888094fc47201567ea9454857f5a1.tar.gz
opie-1fde54b44ba888094fc47201567ea9454857f5a1.tar.bz2
fix for filename paths
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/applets/screenshotapplet/screenshot.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/core/applets/screenshotapplet/screenshot.cpp b/core/applets/screenshotapplet/screenshot.cpp
index 98f2c9e..266d6d8 100644
--- a/core/applets/screenshotapplet/screenshot.cpp
+++ b/core/applets/screenshotapplet/screenshot.cpp
@@ -139,48 +139,50 @@ ScreenshotControl::ScreenshotControl( QWidget *parent, const char *name )
139 connect( grabItButton, SIGNAL(released()), SLOT(slotGrab()) ); 139 connect( grabItButton, SIGNAL(released()), SLOT(slotGrab()) );
140 connect( scapButton, SIGNAL(released()), SLOT(slotScap()) ); 140 connect( scapButton, SIGNAL(released()), SLOT(slotScap()) );
141 connect(saveNamedCheck, SIGNAL(toggled( bool)), this, SLOT( nameScreenshot(bool)) ); 141 connect(saveNamedCheck, SIGNAL(toggled( bool)), this, SLOT( nameScreenshot(bool)) );
142} 142}
143 143
144void ScreenshotControl::slotGrab() { 144void ScreenshotControl::slotGrab() {
145// qDebug("SlotGrab"); 145// qDebug("SlotGrab");
146 buttonPushed=1; 146 buttonPushed=1;
147 hide(); 147 hide();
148 setFileName=FALSE; 148 setFileName=FALSE;
149 if( saveNamedCheck->isChecked()) { 149 if( saveNamedCheck->isChecked()) {
150 setFileName=TRUE; 150 setFileName=TRUE;
151// qDebug("checked"); 151// qDebug("checked");
152 InputDialog *fileDlg; 152 InputDialog *fileDlg;
153 153
154 fileDlg = new InputDialog( 0 ,tr("Name of screenshot "),TRUE, 0); 154 fileDlg = new InputDialog( 0 ,tr("Name of screenshot "),TRUE, 0);
155 fileDlg->exec(); 155 fileDlg->exec();
156 fileDlg->raise(); 156 fileDlg->raise();
157 QString fileName,list; 157 QString fileName,list;
158 if( fileDlg->result() == 1 ) { 158 if( fileDlg->result() == 1 ) {
159 fileName = fileDlg->LineEdit1->text(); 159 fileName = fileDlg->LineEdit1->text();
160 160
161 if(fileName.find("/",0,TRUE)==-1) 161 if(fileName.find("/",0,TRUE)==-1)
162 FileNamePath = QDir::homeDirPath()+"/Documents/image/png/"+fileName; 162 FileNamePath = QDir::homeDirPath()+"/Documents/image/png/"+fileName;
163 else
164 FileNamePath = fileName;
163// qDebug(fileName); 165// qDebug(fileName);
164 166
165 } 167 }
166 delete fileDlg; 168 delete fileDlg;
167 } 169 }
168 if ( delaySpin->value() ) { 170 if ( delaySpin->value() ) {
169 grabTimer->start( delaySpin->value() * 1000, true ); 171 grabTimer->start( delaySpin->value() * 1000, true );
170 } else { 172 } else {
171 show(); 173 show();
172 } 174 }
173} 175}
174 176
175void ScreenshotControl::slotScap() { 177void ScreenshotControl::slotScap() {
176 buttonPushed=2; 178 buttonPushed=2;
177 hide(); 179 hide();
178 if ( delaySpin->value() ) { 180 if ( delaySpin->value() ) {
179 grabTimer->start( delaySpin->value() * 1000, true ); 181 grabTimer->start( delaySpin->value() * 1000, true );
180 } else { 182 } else {
181 show(); 183 show();
182 } 184 }
183} 185}
184 186
185 187
186void ScreenshotControl::grabTimerDone() { 188void ScreenshotControl::grabTimerDone() {