Main Page | Class List | File List | Class Members | File Members | Related Pages

KWebSnap Class Reference

This is the main class for KWebSnap. More...

#include <kwebsnap.h>

List of all members.

Public Slots

virtual void slotHelp ()
virtual void slotConfig ()
virtual void slotQuit ()
virtual void slotAbout ()
virtual void slotStop ()
virtual void slotStart ()
virtual void slotOnTimer ()
virtual void slotSnapshot ()
virtual void slotSnapSend ()

Signals

void timeLeft (int n)
void timeout ()
void start ()
void stop ()
void message (const QString &msg, int type=Configuration::Normal)
void error (const QString &msg)

Public Member Functions

 KWebSnap (QWidget *parent=0, const char *name=0)
 ~KWebSnap ()

Protected Member Functions

virtual bool queryClose ()


Detailed Description

This is the main class for KWebSnap.

If FTP transfer is used in the Configuration, it uses the FtpControl member to establish the connection with an ftp server, and transfer images. It uses the Conifg() method to access the configuration settings, and then applies them.

Definition at line 56 of file kwebsnap.h.


Constructor & Destructor Documentation

KWebSnap::KWebSnap QWidget *  parent = 0,
const char *  name = 0
 

Default constructor.

Parameters:
parent parent widget
name the name of the widget

Definition at line 51 of file kwebsnap.cpp.

References Grabber::capture(), Config(), error(), message(), KWebSnapWidget::setStop(), slotAbout(), slotConfig(), slotHelp(), slotQuit(), slotSnapshot(), slotStart(), slotStop(), start(), stop(), and timeLeft().

KWebSnap::~KWebSnap  ) 
 

Default destructor.

Definition at line 125 of file kwebsnap.cpp.


Member Function Documentation

void KWebSnap::error const QString &  msg  )  [signal]
 

This signal is emitted when an error occured.

Referenced by KWebSnap(), and slotSnapSend().

void KWebSnap::message const QString &  msg,
int  type = Configuration::Normal
[signal]
 

This signal is emitted at some important events, to broadcast what happenned.

Referenced by KWebSnap(), slotStart(), and slotStop().

bool KWebSnap::queryClose  )  [protected, virtual]
 

Displays the messagebox about closing of the main dialog.

Definition at line 350 of file kwebsnap.cpp.

void KWebSnap::slotAbout  )  [virtual, slot]
 

About button slot. Displays the AboutDlg dialog.

Definition at line 211 of file kwebsnap.cpp.

Referenced by KWebSnap().

void KWebSnap::slotConfig  )  [virtual, slot]
 

Configure button slot. Displays the ConfigDialog dialog. If the dialog returns OK, then we may have to open the log file.

Definition at line 177 of file kwebsnap.cpp.

References ConfigDialog::updateConfiguration(), and ConfigDialog::updateDialog().

Referenced by KWebSnap().

void KWebSnap::slotHelp  )  [virtual, slot]
 

Help button slot. Displays the help dialog.

Definition at line 170 of file kwebsnap.cpp.

Referenced by KWebSnap().

void KWebSnap::slotOnTimer  )  [virtual, slot]
 

Slot for the seconds timer. If seconds is < 16, then we emit the timeLeft(int) singal. If seconds is 0, then we should snap and send.

Definition at line 314 of file kwebsnap.cpp.

References Configuration::Capture, CaptureConfig::CaptureDelay, Config(), slotSnapSend(), timeLeft(), and timeout().

Referenced by slotStart(), and slotStop().

void KWebSnap::slotQuit  )  [virtual, slot]
 

Quit button slot. Disconnects if necessary, and then calls doQuit().

Definition at line 199 of file kwebsnap.cpp.

References Config(), Configuration::Ftp, slotStop(), stop(), FtpConfig::UseFtp, and FtpConfig::UseOffline.

Referenced by KWebSnap().

void KWebSnap::slotSnapSend  )  [virtual, slot]
 

Snap and Send Slot. It takes a screenshot of desktop with slotSnapshot(). FtpControl then transfer them if needed.

Definition at line 331 of file kwebsnap.cpp.

References Config(), error(), Configuration::Ftp, FtpControl::sendFiles(), slotSnapshot(), FtpConfig::UseFtp, and Configuration::validate().

Referenced by slotOnTimer().

void KWebSnap::slotSnapshot  )  [virtual, slot]
 

Slot for taking a screenshot of the desktop. It takes the screenshot of the desktop and sets the preview label to the screenshot. Saves the main and thumb images to file as indicated by the Configuration settings.

Definition at line 146 of file kwebsnap.cpp.

References Grabber::capture(), and Grabber::saveFiles().

Referenced by KWebSnap(), and slotSnapSend().

void KWebSnap::slotStart  )  [virtual, slot]
 

Start button slot. Inits the ftp connection. Connects timer signals.

Definition at line 255 of file kwebsnap.cpp.

References Configuration::Capture, CaptureConfig::CaptureDelay, Config(), Configuration::Ftp, message(), KWebSnapWidget::setConfig(), KWebSnapWidget::setStart(), KWebSnapWidget::setStop(), slotOnTimer(), start(), timeout(), FtpConfig::UseFtp, WWWConfig::UseWWW, Configuration::validate(), and Configuration::WWW.

Referenced by KWebSnap().

void KWebSnap::slotStop  )  [virtual, slot]
 

Slot for stop button. If the timer is active, it is stopped. Timer connections are disconnected. If needed FTP used, FtpControl is stopped.

Definition at line 217 of file kwebsnap.cpp.

References Config(), Configuration::Ftp, message(), FtpControl::sendOffline(), KWebSnapWidget::setConfig(), KWebSnapWidget::setStart(), KWebSnapWidget::setStop(), slotOnTimer(), stop(), FtpControl::stop(), timeout(), FtpConfig::UseFtp, FtpConfig::UseOffline, WWWConfig::UseWWW, and Configuration::WWW.

Referenced by KWebSnap(), and slotQuit().

void KWebSnap::start  )  [signal]
 

This signal is emitted when the user clicks start.

Referenced by KWebSnap(), and slotStart().

void KWebSnap::stop  )  [signal]
 

This signal is emitted when the user clicks stop, and we are done with everything.

Referenced by KWebSnap(), slotQuit(), and slotStop().

void KWebSnap::timeLeft int  n  )  [signal]
 

This signal is emitted when there are between 1 - 16 seconds remaining before a screenshot is taken. It emits the number of seconds remaining.

Referenced by KWebSnap(), and slotOnTimer().

void KWebSnap::timeout  )  [signal]
 

This slot is emitted when the capture timer times out

Referenced by slotOnTimer(), slotStart(), and slotStop().


The documentation for this class was generated from the following files:
Generated on Mon Sep 5 12:52:34 2005 for kwebsnap.kdevelop by  doxygen 1.3.9.1