Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

Ir Class Reference

The Ir class implements basic support for sending objects over an infrared communication link. More...

#include </home/clem/local/src/opie/library/ir.h>

Collaboration diagram for Ir:

Collaboration graph
[legend]
List of all members.

Signals

void done (Ir *)

Public Member Functions

 Ir (QObject *parent=0, const char *name=0)
void send (const QString &filename, const QString &description, const QString &mimetype=QString::null)
void send (const DocLnk &doc, const QString &description)

Static Public Member Functions

static bool supported ()

Private Slots

void obexMessage (const QCString &msg, const QByteArray &data)

Private Attributes

QString filename
QCopChannelch

Detailed Description

The Ir class implements basic support for sending objects over an infrared communication link.

Both DocLnk objects and files can be sent to another device via the infrared link using the send() function. When the send has completed the done() signal is emitted.

The supported() function returns whether the device supports infrared communication or not.

Definition at line 29 of file ir.h.


Constructor & Destructor Documentation

Ir::Ir QObject *  parent = 0,
const char *  name = 0
 

Constructs an Ir object. The parent and name classes are the standard QObject parameters.

Definition at line 46 of file ir.cpp.

References ch, and obexMessage().


Member Function Documentation

Ir::done Ir ir  )  [signal]
 

This signal is emitted by ir, when the send comand has been processed.

Referenced by obexMessage().

void Ir::obexMessage const QCString msg,
const QByteArray data
[private, slot]
 

For internal use only.

Definition at line 106 of file ir.cpp.

References done(), filename, IO_ReadOnly, and stream.

Referenced by Ir().

void Ir::send const DocLnk doc,
const QString description
 

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Uses the DocLnk::file() and DocLnk::type() of doc.

See also:
done()

Definition at line 93 of file ir.cpp.

References AppLnk::file(), send(), and AppLnk::type().

void Ir::send const QString fn,
const QString description,
const QString mimetype = QString::null
 

Sends the object in file fn over the infrared link. The description is used in the text shown to the user while sending is in progress. The optional mimetype parameter specifies the mimetype of the object. If this parameter is not set, it is determined by the the filename's suffix.

See also:
done()

Definition at line 76 of file ir.cpp.

References filename, and QString::isEmpty().

Referenced by AddressbookWindow::appMessage(), DateBook::beamEvent(), LnkProperties::beamLnk(), QtRec::doBeam(), AdvancedFm::doBeam(), send(), PIconView::slotBeam(), NotesControl::slotBeamButton(), mainWindowWidget::slotItemBeam(), and AddressbookWindow::slotItemBeam().

bool Ir::supported  )  [static]
 

Returns TRUE if the system supports infrared communication; otherwise returns FALSE.

Definition at line 60 of file ir.cpp.

References QCopChannel::isRegistered().

Referenced by QtRec::doBeam(), AdvancedFm::doBeam(), Opie::OPimMainWindow::initBars(), DateBookWeekLstEvent::mousePressEvent(), DatebookAlldayDisp::mousePressEvent(), DateBookDayWidget::mousePressEvent(), IrdaApplet::mousePressEvent(), PMainWindow::setupActions(), AdvancedFm::showFileMenu(), QtRec::showListMenu(), and NotesControl::slotBeamButton().


Member Data Documentation

QCopChannel* Ir::ch [private]
 

Definition at line 47 of file ir.h.

Referenced by Ir().

QString Ir::filename [private]
 

Definition at line 46 of file ir.h.

Referenced by obexMessage(), and send().


The documentation for this class was generated from the following files:
Generated on Sat Nov 5 17:36:33 2005 for OPIE by  doxygen 1.4.2