Diffstat (limited to 'core/applets/screenshotapplet/screenshot.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/applets/screenshotapplet/screenshot.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/core/applets/screenshotapplet/screenshot.cpp b/core/applets/screenshotapplet/screenshot.cpp index 5d6bce4..20e1c9b 100644 --- a/core/applets/screenshotapplet/screenshot.cpp +++ b/core/applets/screenshotapplet/screenshot.cpp | |||
@@ -278,51 +278,51 @@ ScreenshotControl::ScreenshotControl( QWidget *parent, const char *name ) | |||
278 | saveNamedCheck-> setFocusPolicy ( QWidget::NoFocus ); | 278 | saveNamedCheck-> setFocusPolicy ( QWidget::NoFocus ); |
279 | vbox->addWidget( saveNamedCheck); | 279 | vbox->addWidget( saveNamedCheck); |
280 | 280 | ||
281 | vbox-> addSpacing ( 3 ); | 281 | vbox-> addSpacing ( 3 ); |
282 | 282 | ||
283 | l = new QLabel ( tr( "Save screenshot as..." ), this ); | 283 | l = new QLabel ( tr( "Save screenshot as..." ), this ); |
284 | vbox-> addWidget ( l, AlignCenter ); | 284 | vbox-> addWidget ( l, AlignCenter ); |
285 | 285 | ||
286 | hbox = new QHBoxLayout ( vbox ); | 286 | hbox = new QHBoxLayout ( vbox ); |
287 | 287 | ||
288 | grabItButton = new QPushButton( tr( "File" ), this, "GrabButton" ); | 288 | grabItButton = new QPushButton( tr( "File" ), this, "GrabButton" ); |
289 | grabItButton ->setFocusPolicy( QWidget::TabFocus ); | 289 | grabItButton ->setFocusPolicy( QWidget::TabFocus ); |
290 | hbox-> addWidget ( grabItButton ); | 290 | hbox-> addWidget ( grabItButton ); |
291 | 291 | ||
292 | scapButton = new QPushButton( tr( "Scap" ), this, "ScapButton" ); | 292 | scapButton = new QPushButton( tr( "Scap" ), this, "ScapButton" ); |
293 | scapButton ->setFocusPolicy( QWidget::TabFocus ); | 293 | scapButton ->setFocusPolicy( QWidget::TabFocus ); |
294 | hbox-> addWidget ( scapButton ); | 294 | hbox-> addWidget ( scapButton ); |
295 | 295 | ||
296 | setFixedSize ( sizeHint ( )); | 296 | setFixedSize ( sizeHint ( )); |
297 | setFocusPolicy ( QWidget::NoFocus ); | 297 | setFocusPolicy ( QWidget::NoFocus ); |
298 | 298 | ||
299 | 299 | ||
300 | grabTimer = new QTimer ( this, "grab timer"); | 300 | grabTimer = new QTimer ( this, "grab timer"); |
301 | 301 | ||
302 | connect ( grabTimer, SIGNAL( timeout ( )), this, SLOT( performGrab ( ))); | 302 | connect ( grabTimer, SIGNAL( timeout()), this, SLOT( performGrab())); |
303 | connect ( grabItButton, SIGNAL( clicked ( )), SLOT( slotGrab ( ))); | 303 | connect ( grabItButton, SIGNAL( clicked()), SLOT( slotGrab())); |
304 | connect ( scapButton, SIGNAL( clicked ( )), SLOT( slotScap ( ))); | 304 | connect ( scapButton, SIGNAL( clicked()), SLOT( slotScap())); |
305 | } | 305 | } |
306 | 306 | ||
307 | void ScreenshotControl::slotGrab() | 307 | void ScreenshotControl::slotGrab() |
308 | { | 308 | { |
309 | buttonPushed = 1; | 309 | buttonPushed = 1; |
310 | hide(); | 310 | hide(); |
311 | 311 | ||
312 | setFileName = FALSE; | 312 | setFileName = FALSE; |
313 | if ( saveNamedCheck->isChecked()) { | 313 | if ( saveNamedCheck->isChecked()) { |
314 | setFileName = TRUE; | 314 | setFileName = TRUE; |
315 | InputDialog *fileDlg; | 315 | InputDialog *fileDlg; |
316 | 316 | ||
317 | fileDlg = new InputDialog( 0 , tr("Name of screenshot "), TRUE, 0); | 317 | fileDlg = new InputDialog( 0 , tr("Name of screenshot "), TRUE, 0); |
318 | fileDlg->exec(); | 318 | fileDlg->exec(); |
319 | fileDlg->raise(); | 319 | fileDlg->raise(); |
320 | QString fileName, list; | 320 | QString fileName, list; |
321 | if ( fileDlg->result() == 1 ) { | 321 | if ( fileDlg->result() == 1 ) { |
322 | fileName = fileDlg->LineEdit1->text(); | 322 | fileName = fileDlg->LineEdit1->text(); |
323 | 323 | ||
324 | if (fileName.find("/", 0, TRUE) == -1) | 324 | if (fileName.find("/", 0, TRUE) == -1) |
325 | FileNamePath = QDir::homeDirPath() + "/Documents/image/png/" + fileName; | 325 | FileNamePath = QDir::homeDirPath() + "/Documents/image/png/" + fileName; |
326 | else | 326 | else |
327 | FileNamePath = fileName; | 327 | FileNamePath = fileName; |
328 | 328 | ||