summaryrefslogtreecommitdiff
authorzecke <zecke>2004-03-14 17:00:46 (UTC)
committer zecke <zecke>2004-03-14 17:00:46 (UTC)
commit52169e2469a1edcca986e9f0404c3ca815d5833b (patch) (side-by-side diff)
tree9c6651125f29fe63df33fe56b352d3288b2ea8df
parent59106c8ffcf25181925281c519a2b49d6835ef9e (diff)
downloadopie-52169e2469a1edcca986e9f0404c3ca815d5833b.zip
opie-52169e2469a1edcca986e9f0404c3ca815d5833b.tar.gz
opie-52169e2469a1edcca986e9f0404c3ca815d5833b.tar.bz2
Change Signature of Signals to obey namespace
Make example compile
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--libopie2/examples/opieui/osplitter_example/osplitter_example.cpp1
-rw-r--r--libopie2/examples/opieui/owidgetstack_example/owidgetstack_example.cpp1
-rw-r--r--libopie2/opiecore/oprocess.h12
-rw-r--r--libopie2/opienet/opcap.h2
-rw-r--r--libopie2/opieui/opopupmenu.h2
-rw-r--r--libopie2/opieui/otimepicker.h3
-rw-r--r--libopie2/opieui/oversatileview.h48
7 files changed, 34 insertions, 35 deletions
diff --git a/libopie2/examples/opieui/osplitter_example/osplitter_example.cpp b/libopie2/examples/opieui/osplitter_example/osplitter_example.cpp
index 4a1468d..07c7e51 100644
--- a/libopie2/examples/opieui/osplitter_example/osplitter_example.cpp
+++ b/libopie2/examples/opieui/osplitter_example/osplitter_example.cpp
@@ -1,33 +1,34 @@
#include "osplitter_example.h"
/* OPIE */
#include <opie2/osplitter.h>
#include <opie2/ofileselector.h>
#include <qpe/qpeapplication.h>
#include <opie2/oapplicationfactory.h>
/* QT*/
#include <qdir.h>
#include <qlayout.h>
using namespace Opie::Ui;
+using namespace Opie::Core;
OPIE_EXPORT_APP( OApplicationFactory<OSplitterExample> )
OSplitterExample::OSplitterExample( QWidget *w,const char* n,WFlags f )
: QWidget( w, n, f ){
QVBoxLayout * lay = new QVBoxLayout(this);
OSplitter * splitter = new OSplitter( Horizontal, this );
lay->addWidget( splitter );
OFileSelector *selector = new OFileSelector( splitter, OFileSelector::FileSelector,
OFileSelector::Normal, QDir::homeDirPath(),
QString::null );
splitter->addWidget( selector, "zoom", tr("Selector 1") );
selector = new OFileSelector( splitter, OFileSelector::FileSelector, OFileSelector::Normal,
QDir::homeDirPath(), QString::null );
splitter->addWidget( selector, "zoom", tr("Selector 2") );
}
diff --git a/libopie2/examples/opieui/owidgetstack_example/owidgetstack_example.cpp b/libopie2/examples/opieui/owidgetstack_example/owidgetstack_example.cpp
index 50cc11b..272e42b 100644
--- a/libopie2/examples/opieui/owidgetstack_example/owidgetstack_example.cpp
+++ b/libopie2/examples/opieui/owidgetstack_example/owidgetstack_example.cpp
@@ -1,69 +1,70 @@
/*
* You may use, modify and distribute this example without any limitation
*/
#include "owidgetstack_example.h"
/* OPIE */
#include <opie2/oapplicationfactory.h>
#include <opie2/owidgetstack.h>
#include <qpe/resource.h>
/* QT */
#include <qaction.h>
#include <qtoolbar.h>
#include <qpopupmenu.h>
#include <qmenubar.h>
#include <qlayout.h>
#include <qlabel.h>
#include <qpushbutton.h>
#include <qsignalmapper.h>
+using namespace Opie::Core;
using namespace Opie::Ui;
OPIE_EXPORT_APP( OApplicationFactory<StackExample> )
StackExample::StackExample( QWidget* parent, const char* name, WFlags fl )
: QMainWindow( parent, name, fl )
{
m_stack = new OWidgetStack( this );
setCentralWidget( m_stack );
/* nice Signal Mapper ;) */
QSignalMapper *sm = new QSignalMapper(this);
connect(sm, SIGNAL(mapped(int) ), m_stack, SLOT(raiseWidget(int)) );
/* toolbar first but this should be known from the other examples */
setToolBarsMovable( false );
/* only a menubar here */
QToolBar* holder = new QToolBar( this );
holder->setHorizontalStretchable( true );
QMenuBar *bar = new QMenuBar( holder );
QPopupMenu *menu = new QPopupMenu( this );
QAction* a = new QAction( tr("Show MainWidget"), Resource::loadPixmap("zoom"),
QString::null, 0, this, 0 );
sm->setMapping(a, 1 );
connect(a, SIGNAL(activated() ),
sm, SLOT(map() ) );
a->addTo( menu );
a = new QAction( tr("Show Details Small"), Resource::loadPixmap("zoom"),
QString::null, 0, this, 0 );
sm->setMapping(a, 2 );
connect(a, SIGNAL(activated() ),
sm, SLOT(map() ) );
a->addTo( menu );
a = new QAction( tr("Show Details More"), Resource::loadPixmap("zoom"),
QString::null, 0, this, 0 );
sm->setMapping(a, 3 );
connect(a, SIGNAL(activated() ),
sm, SLOT(map() ) );
a->addTo( menu );
a = new QAction( tr("Show Details All"), Resource::loadPixmap("zoom"),
QString::null, 0, this, 0 );
sm->setMapping(a, 4 );
diff --git a/libopie2/opiecore/oprocess.h b/libopie2/opiecore/oprocess.h
index eb56b03..e23f98c 100644
--- a/libopie2/opiecore/oprocess.h
+++ b/libopie2/opiecore/oprocess.h
@@ -56,98 +56,98 @@ class OProcessPrivate;
*
* @sect General usage and features
*
*This class allows a KDE and OPIE application to start child processes without having
*to worry about UN*X signal handling issues and zombie process reaping.
*
*@see KProcIO
*
*Basically, this class distinguishes three different ways of running
*child processes:
*
*@li OProcess::DontCare -- The child process is invoked and both the child
*process and the parent process continue concurrently.
*
*Starting a DontCare child process means that the application is
*not interested in any notification to determine whether the
*child process has already exited or not.
*
*@li OProcess::NotifyOnExit -- The child process is invoked and both the
*child and the parent process run concurrently.
*
*When the child process exits, the OProcess instance
*corresponding to it emits the Qt signal @ref processExited().
*
*Since this signal is @em not emitted from within a UN*X
*signal handler, arbitrary function calls can be made.
*
*Be aware: When the OProcess objects gets destructed, the child
*process will be killed if it is still running!
*This means in particular, that you cannot use a OProcess on the stack
*with OProcess::NotifyOnExit.
*
*@li OProcess::Block -- The child process starts and the parent process
*is suspended until the child process exits. (@em Really not recommended
*for programs with a GUI.)
*
*OProcess also provides several functions for determining the exit status
*and the pid of the child process it represents.
*
*Furthermore it is possible to supply command-line arguments to the process
*in a clean fashion (no null -- terminated stringlists and such...)
*
*A small usage example:
*<pre>
*OProcess *proc = new OProcess;
*
**proc << "my_executable";
**proc << "These" << "are" << "the" << "command" << "line" << "args";
- *QApplication::connect(proc, SIGNAL(processExited(OProcess *)),
- * pointer_to_my_object, SLOT(my_objects_slot(OProcess *)));
+ *QApplication::connect(proc, SIGNAL(processExited(Opie::Core::OProcess *)),
+ * pointer_to_my_object, SLOT(my_objects_slot(Opie::Core::OProcess *)));
*proc->start();
*</pre>
*
*This will start "my_executable" with the commandline arguments "These"...
*
*When the child process exits, the respective Qt signal will be emitted.
*
*@sect Communication with the child process
*
*OProcess supports communication with the child process through
*stdin/stdout/stderr.
*
*The following functions are provided for getting data from the child
*process or sending data to the child's stdin (For more information,
*have a look at the documentation of each function):
*
*@li bool @ref writeStdin(char *buffer, int buflen);
*@li -- Transmit data to the child process's stdin.
*
*@li bool @ref closeStdin();
*@li -- Closes the child process's stdin (which causes it to see an feof(stdin)).
*Returns false if you try to close stdin for a process that has been started
*without a communication channel to stdin.
*
*@li bool @ref closeStdout();
*@li -- Closes the child process's stdout.
*Returns false if you try to close stdout for a process that has been started
*without a communication channel to stdout.
*
*@li bool @ref closeStderr();
*@li -- Closes the child process's stderr.
*Returns false if you try to close stderr for a process that has been started
*without a communication channel to stderr.
*
*
*@sect QT signals:
*
*@li void @ref receivedStdout(OProcess *proc, char *buffer, int buflen);
*@li void @ref receivedStderr(OProcess *proc, char *buffer, int buflen);
*@li -- Indicates that new data has arrived from either the
*child process's stdout or stderr.
*
*@li void @ref wroteStdin(OProcess *proc);
*@li -- Indicates that all data that has been sent to the child process
*by a prior call to @ref writeStdin() has actually been transmitted to the
*client .
*
*@author Christian Czezakte e9025461@student.tuwien.ac.at
@@ -435,154 +435,154 @@ public:
* Changes the current working directory (CWD) of the process
* to be started.
* This function must be called before starting the process.
*/
void setWorkingDirectory( const QString &dir );
/**
* Specify whether to start the command via a shell or directly.
* The default is to start the command directly.
* If @p useShell is true @p shell will be used as shell, or
* if shell is empty, the standard shell is used.
* @p quote A flag indicating whether to quote the arguments.
*
* When using a shell, the caller should make sure that all filenames etc.
* are properly quoted when passed as argument.
* @see quote()
*/
void setUseShell( bool useShell, const char *shell = 0 );
/**
* This function can be used to quote an argument string such that
* the shell processes it properly. This is e. g. necessary for
* user-provided file names which may contain spaces or quotes.
* It also prevents expansion of wild cards and environment variables.
*/
static QString quote( const QString &arg );
/**
* Detaches OProcess from child process. All communication is closed.
* No exit notification is emitted any more for the child process.
* Deleting the OProcess will no longer kill the child process.
* Note that the current process remains the parent process of the
* child process.
*/
void detach();
/**
* @return the PID of @a process, or -1 if the process is not running
*/
static int processPID( const QString& process );
signals:
/**
* Emitted after the process has terminated when
* the process was run in the @p NotifyOnExit (==default option to
* @ref start()) or the @ref Block mode.
**/
- void processExited( OProcess *proc );
+ void processExited( Opie::Core::OProcess *proc );
/**
* Emitted, when output from the child process has
* been received on stdout.
*
* To actually get
* these signals, the respective communication link (stdout/stderr)
* has to be turned on in @ref start().
*
* @param buffer The data received.
* @param buflen The number of bytes that are available.
*
* You should copy the information contained in @p buffer to your private
* data structures before returning from this slot.
**/
- void receivedStdout( OProcess *proc, char *buffer, int buflen );
+ void receivedStdout( Opie::Core::OProcess *proc, char *buffer, int buflen );
/**
* Emitted when output from the child process has
* been received on stdout.
*
* To actually get these signals, the respective communications link
* (stdout/stderr) has to be turned on in @ref start() and the
* @p NoRead flag should have been passed.
*
* You will need to explicitly call resume() after your call to start()
* to begin processing data from the child process's stdout. This is
* to ensure that this signal is not emitted when no one is connected
* to it, otherwise this signal will not be emitted.
*
* The data still has to be read from file descriptor @p fd.
**/
void receivedStdout( int fd, int &len );
/**
* Emitted, when output from the child process has
* been received on stderr.
* To actually get
* these signals, the respective communication link (stdout/stderr)
* has to be turned on in @ref start().
*
* @param buffer The data received.
* @param buflen The number of bytes that are available.
*
* You should copy the information contained in @p buffer to your private
* data structures before returning from this slot.
*/
- void receivedStderr( OProcess *proc, char *buffer, int buflen );
+ void receivedStderr( Opie::Core::OProcess *proc, char *buffer, int buflen );
/**
* Emitted after all the data that has been
* specified by a prior call to @ref writeStdin() has actually been
* written to the child process.
**/
- void wroteStdin( OProcess *proc );
+ void wroteStdin( Opie::Core::OProcess *proc );
protected slots:
/**
* This slot gets activated when data from the child's stdout arrives.
* It usually calls "childOutput"
*/
void slotChildOutput( int fdno );
/**
* This slot gets activated when data from the child's stderr arrives.
* It usually calls "childError"
*/
void slotChildError( int fdno );
/*
Slot functions for capturing stdout and stderr of the child
*/
/**
* Called when another bulk of data can be sent to the child's
* stdin. If there is no more data to be sent to stdin currently
* available, this function must disable the QSocketNotifier "innot".
*/
void slotSendData( int dummy );
protected:
/**
* Sets up the environment according to the data passed via
* setEnvironment(...)
*/
void setupEnvironment();
/**
* The list of the process' command line arguments. The first entry
* in this list is the executable itself.
*/
QValueList<QCString> arguments;
/**
* How to run the process (Block, NotifyOnExit, DontCare). You should
* not modify this data member directly from derived classes.
*/
RunMode run_mode;
/**
* true if the process is currently running. You should not
* modify this data member directly from derived classes. For
* reading the value of this data member, please use "isRunning()"
* since "runs" will probably be made private in later versions
diff --git a/libopie2/opienet/opcap.h b/libopie2/opienet/opcap.h
index dc609a3..72a78de 100644
--- a/libopie2/opienet/opcap.h
+++ b/libopie2/opienet/opcap.h
@@ -653,69 +653,69 @@ class OPacketCapturer : public QObject
* @returns the next @ref OPacket from the packet capturer.
* @note If blocking mode is true then this call might block.
*/
OPacket* next();
/**
* @returns the next @ref OPacket from the packet capturer, if
* one arrives within @a time milliseconds.
*/
OPacket* next( int time );
/**
* Open the packet capturer to capture packets in live-mode from @a interface.
*/
bool open( const QString& interface );
/**
* Open the packet capturer to capture packets in offline-mode from @a file.
*/
bool open( const QFile& file );
/**
* Open a prerecorded tcpdump compatible capture file for use with @ref dump()
*/
bool openDumpFile( const QString& filename );
/**
* @returns true if the packet capturer is open
*/
bool isOpen() const;
/**
* @returns the snapshot length of this packet capturer
*/
int snapShot() const;
/**
* @returns true if the input capture file has a different byte-order
* than the byte-order of the running system.
*/
bool swapped() const;
/**
* @returns the libpcap version string used to write the input capture file.
*/
QString version() const;
/**
* @returns the packet statistic database.
* @see QMap
*/
const QMap<QString,int>& statistics() const;
signals:
/**
* This signal is emitted, when a packet has been received.
*/
- void receivedPacket( OPacket* );
+ void receivedPacket( Opie::Net::OPacket* );
protected slots:
void readyToReceive();
protected:
QString _name; // devicename
bool _open; // check this before doing pcap calls
pcap_t* _pch; // pcap library handle
pcap_dumper_t* _pcd; // pcap dumper handle
QSocketNotifier* _sn; // socket notifier for main loop
mutable char _errbuf[PCAP_ERRBUF_SIZE]; // holds error strings from libpcap
QMap<QString, int> _stats; // statistics;
class Private; // Private Forward declaration
Private *d; // if we need to add data
};
}
}
#endif // OPCAP_H
diff --git a/libopie2/opieui/opopupmenu.h b/libopie2/opieui/opopupmenu.h
index 419a954..294edcc 100644
--- a/libopie2/opieui/opopupmenu.h
+++ b/libopie2/opieui/opopupmenu.h
@@ -189,76 +189,76 @@ public:
* Defaults to off.
* @since 3.1
*/
void setKeyboardShortcutsExecute(bool enable);
/**
* Obsolete method provided for backwards compatibility only. Use the
* normal constructor and insertTitle instead.
*/
OPopupMenu(const QString &title, QWidget *parent=0, const char *name=0);
/**
* Obsolete method provided for backwards compatibility only. Use
* insertTitle and changeTitle instead.
*/
void setTitle(const QString &title);
/**
* Returns the context menu associated with this menu
* @since 3.2
*/
QPopupMenu* contextMenu();
/**
* Hides the context menu if shown
* @since 3.2
*/
void cancelContextMenuShow();
/**
* Returns the OPopupMenu associated with the current context menu
* @since 3.2
*/
static OPopupMenu* contextMenuFocus();
/**
* returns the ID of the menuitem associated with the current context menu
* @since 3.2
*/
static int contextMenuFocusItem();
signals:
/**
* connect to this signal to be notified when a context menu is about to be shown
* @param menu The menu that the context menu is about to be shown for
* @param menuItem The menu item that the context menu is currently on
* @param ctxMenu The context menu itself
* @since 3.2
*/
- void aboutToShowContextMenu(OPopupMenu* menu, int menuItem, QPopupMenu* ctxMenu);
+ void aboutToShowContextMenu(Opie::Ui::OPopupMenu* menu, int menuItem, QPopupMenu* ctxMenu);
protected:
virtual void closeEvent(QCloseEvent *);
virtual void keyPressEvent(QKeyEvent* e);
virtual bool eventFilter(QObject* obj, QEvent* event);
virtual void hideEvent(QHideEvent*);
virtual void virtual_hook( int id, void* data );
protected slots:
/// @since 3.1
QString underlineText(const QString& text, uint length);
/// @since 3.1
void resetKeyboardVars(bool noMatches = false);
void itemHighlighted(int whichItem);
void showCtxMenu(QPoint pos);
void ctxMenuHiding();
private:
class OPopupMenuPrivate;
OPopupMenuPrivate *d;
};
}
}
#endif
diff --git a/libopie2/opieui/otimepicker.h b/libopie2/opieui/otimepicker.h
index 01bb557..fb20781 100644
--- a/libopie2/opieui/otimepicker.h
+++ b/libopie2/opieui/otimepicker.h
@@ -80,53 +80,50 @@ private:
private slots:
void slotHour(bool b);
void slotMinute(bool b);
signals:
/**
* gets emitted when the time got changed by the user
*/
void timeChanged(const QTime &);
};
/**
*
* @short A small dialog to pick a time
* @version 1.0
* @author Stefan Eilers
*
**/
class OTimePickerDialog: public OTimePickerDialogBase
{
Q_OBJECT
public:
OTimePickerDialog ( QWidget* parent = 0, const char* name = NULL, WFlags fl = 0 );
~OTimePickerDialog() { };
QTime time()const;
public slots:
void setTime( const QTime& time );
void setHour( const QString& hour );
void setMinute( const QString& minute );
private:
OTimePicker *m_timePicker;
QTime m_time;
class Private;
Private* d;
};
}
}
/* for Qt2 */
#if ( QT_VERSION-0 >= 0x030000 )
#error "Fix the UI File to use namespaces"
-#else
-typedef Opie::Ui::OTimePicker OUIOTimePicker;
#endif
#endif
-
diff --git a/libopie2/opieui/oversatileview.h b/libopie2/opieui/oversatileview.h
index 61b61db..8cba65c 100644
--- a/libopie2/opieui/oversatileview.h
+++ b/libopie2/opieui/oversatileview.h
@@ -102,298 +102,298 @@ class OVersatileView : public QWidgetStack
int _viewmode;
bool _synchronization;
mutable int _warningpolicy;
OListView* _listview;
QIconView* _iconview;
QPixmap _treeleaf;
QPixmap _treeopened;
QPixmap _treeclosed;
QPixmap _iconleaf;
QPixmap _iconopened;
QPixmap _iconclosed;
QPopupMenu* _contextmenu;
int _iconstyle;
int _treestyle;
private slots:
void contextMenuRequested( QListViewItem*, const QPoint&, int );
void contextMenuRequested( QIconViewItem*, const QPoint& );
// type converting signal forwarders
void selectionChanged( QListViewItem * );
void currentChanged( QListViewItem * );
void clicked( QListViewItem * );
void pressed( QListViewItem * );
void doubleClicked( QListViewItem * );
void returnPressed( QListViewItem * );
void onItem( QListViewItem * );
void selectionChanged( QIconViewItem * );
void currentChanged( QIconViewItem * );
void clicked( QIconViewItem * );
void pressed( QIconViewItem * );
void doubleClicked( QIconViewItem * );
void returnPressed( QIconViewItem * );
void onItem( QIconViewItem * );
void expanded( QListViewItem * item ); // QListView
void collapsed( QListViewItem * item ); // QListView
signals:
- void contextMenuRequested( OVersatileViewItem * item, const QPoint& pos, int col );
+ void contextMenuRequested( Opie::Ui::OVersatileViewItem * item, const QPoint& pos, int col );
/*#ifndef QT_NO_DRAGANDDROP
void dropped( QDropEvent *e, const QValueList<QIconDragItem> &lst ); // QIconView
#endif
void itemRenamed( OVersatileViewItem *item, const QString & ); // QIconView
void itemRenamed( OVersatileViewItem *item ); // QIconView
*/
//==============================================================================================//
// "Derived" API - Case 1: Methods existing either only in QListView or only in QIconView
//==============================================================================================//
public:
/*
enum Arrangement { // QIconView
LeftToRight = 0,
TopToBottom
};
enum ResizeMode { // QIconView
Fixed = 0,
Adjust
};
enum ItemTextPos { // QIconView
Bottom = 0,
Right
};
*/
//
// only in QListView
//
int treeStepSize() const; // QListView
virtual void setTreeStepSize( int ); // QListView
QHeader * header() const; // QListView
virtual int addColumn( const QString &label, int size = -1); // QListView
virtual int addColumn( const QIconSet& iconset, const QString &label, int size = -1); // QListView
void removeColumn( int index ); // #### make virtual in next major release! // QListView
virtual void setColumnText( int column, const QString &label ); // QListView
virtual void setColumnText( int column, const QIconSet& iconset, const QString &label ); // QListView
QString columnText( int column ) const; // QListView
virtual void setColumnWidth( int column, int width ); // QListView
int columnWidth( int column ) const; // QListView
enum WidthMode { Manual, Maximum }; // QListView
virtual void setColumnWidthMode( int column, WidthMode ); // QListView
WidthMode columnWidthMode( int column ) const; // QListView
int columns() const; // QListView
virtual void setColumnAlignment( int, int ); // QListView
int columnAlignment( int ) const; // QListView
OVersatileViewItem * itemAt( const QPoint & screenPos ) const; // QListView
QRect itemRect( const OVersatileViewItem * ) const; // QListView
int itemPos( const OVersatileViewItem * ); // QListView
bool isSelected( const OVersatileViewItem * ) const; // QListView // also in QIconViewItem but not in QIconView *shrug*
virtual void setMultiSelection( bool enable ); // QListView
bool isMultiSelection() const; // QListView
OVersatileViewItem * selectedItem() const; // QListView
virtual void setOpen( OVersatileViewItem *, bool ); // QListView
bool isOpen( const OVersatileViewItem * ) const; // QListView
OVersatileViewItem * firstChild() const; // QListView
int childCount() const; // QListView
virtual void setAllColumnsShowFocus( bool ); // QListView
bool allColumnsShowFocus() const; // QListView
virtual void setItemMargin( int ); // QListView
int itemMargin() const; // QListView
virtual void setRootIsDecorated( bool ); // QListView
bool rootIsDecorated() const; // QListView
void setShowSortIndicator( bool show ); // QListView
bool showSortIndicator() const; // QListView
int index( const OVersatileViewItem *item ) const; // QIconView
public slots:
void triggerUpdate(); // QListView
signals:
- void expanded( OVersatileViewItem *item ); // QListView
- void collapsed( OVersatileViewItem *item ); // QListView
+ void expanded( Opie::Ui::OVersatileViewItem *item ); // QListView
+ void collapsed( Opie::Ui::OVersatileViewItem *item ); // QListView
//
// only in QIconView
//
public:
uint count() const; // QIconView
OVersatileViewItem *firstItem() const; // QIconView
OVersatileViewItem *lastItem() const; // QIconView
OVersatileViewItem *findItem( const QPoint &pos ) const; // QIconView
OVersatileViewItem *findItem( const QString &text ) const; // QIconView
OVersatileViewItem* findFirstVisibleItem( const QRect &r ) const; // QIconView
OVersatileViewItem* findLastVisibleItem( const QRect &r ) const; // QIconView
virtual void setGridX( int rx ); // QIconView
virtual void setGridY( int ry ); // QIconView
int gridX() const; // QIconView
int gridY() const; // QIconView
virtual void setSpacing( int sp ); // QIconView
int spacing() const; // QIconView
virtual void setItemTextPos( QIconView::ItemTextPos pos ); // QIconView
QIconView::ItemTextPos itemTextPos() const; // QIconView
virtual void setItemTextBackground( const QBrush &b ); // QIconView
QBrush itemTextBackground() const; // QIconView
virtual void setArrangement( QIconView::Arrangement am ); // QIconView
QIconView::Arrangement arrangement() const; // QIconView
virtual void setResizeMode( QIconView::ResizeMode am ); // QIconView
QIconView::ResizeMode resizeMode() const; // QIconView
virtual void setMaxItemWidth( int w ); // QIconView
int maxItemWidth() const; // QIconView
virtual void setMaxItemTextLength( int w ); // QIconView
int maxItemTextLength() const; // QIconView
virtual void setAutoArrange( bool b ); // QIconView
bool autoArrange() const; // QIconView
virtual void setShowToolTips( bool b ); // QIconView
bool showToolTips() const; // QIconView
bool sorting() const; // QIconView
bool sortDirection() const; // QIconView
virtual void setItemsMovable( bool b ); // QIconView
bool itemsMovable() const; // QIconView
virtual void setWordWrapIconText( bool b ); // QIconView
bool wordWrapIconText() const; // QIconView
public slots:
virtual void arrangeItemsInGrid( const QSize &grid, bool update = TRUE ); // QIconView
virtual void arrangeItemsInGrid( bool update = TRUE ); // QIconView
virtual void updateContents(); // QIconView
signals:
/*#ifndef QT_NO_DRAGANDDROP
void dropped( QDropEvent *e, const QValueList<QIconDragItem> &lst ); // QIconView
#endif
*/
void moved(); // QIconView
- void itemRenamed( OVersatileViewItem *item, const QString & ); // QIconView
- void itemRenamed( OVersatileViewItem *item ); // QIconView
+ void itemRenamed( Opie::Ui::OVersatileViewItem *item, const QString & ); // QIconView
+ void itemRenamed( Opie::Ui::OVersatileViewItem *item ); // QIconView
//==============================================================================================//
// "Derived" API - Case 2: Methods existing in QListView and QIconView with the same signatures
//==============================================================================================//
public:
enum SelectionMode {
Single = 0,
Multi,
Extended,
NoSelection
};
virtual void clear();
virtual void setFont( const QFont & );
virtual void setPalette( const QPalette & );
virtual void takeItem( OVersatileViewItem * );
void setSelectionMode( SelectionMode mode );
SelectionMode selectionMode() const;
virtual void selectAll( bool select );
virtual void clearSelection();
virtual void invertSelection();
void ensureItemVisible( const OVersatileViewItem * );
virtual void repaintItem( const OVersatileViewItem * ) const;
virtual void setCurrentItem( OVersatileViewItem * );
OVersatileViewItem * currentItem() const;
// bool eventFilter( QObject * o, QEvent * ); // use QWidgetStack implementation
// QSize minimumSizeHint() const; // use QWidgetStack implementation
// QSizePolicy sizePolicy() const; // use QWidgetStack implementation
// QSize sizeHint() const; // use QWidgetStack implementation
signals:
void selectionChanged();
- void selectionChanged( OVersatileViewItem * );
- void currentChanged( OVersatileViewItem * );
- void clicked( OVersatileViewItem * );
- void pressed( OVersatileViewItem * );
+ void selectionChanged( Opie::Ui::OVersatileViewItem * );
+ void currentChanged( Opie::Ui::OVersatileViewItem * );
+ void clicked( Opie::Ui::OVersatileViewItem * );
+ void pressed( Opie::Ui::OVersatileViewItem * );
- void doubleClicked( OVersatileViewItem * );
- void returnPressed( OVersatileViewItem * );
+ void doubleClicked( Opie::Ui::OVersatileViewItem * );
+ void returnPressed( Opie::Ui::OVersatileViewItem * );
- void onItem( OVersatileViewItem * );
+ void onItem( Opie::Ui::OVersatileViewItem * );
void onViewport();
//==============================================================================================//
// "Derived" API - Case 2: Methods existing in QListView and QIconView with differing signatures
//==============================================================================================//
/*
public:
virtual void insertItem( OVersatileViewItem * ); // QListView
virtual void insertItem( OVersatileViewItem *item, OVersatileViewItem *after = 0L ); // QIconView
virtual void setSelected( OVersatileViewItem *, bool ); // QListView
virtual void setSelected( OVersatileViewItem *item, bool s, bool cb = FALSE ); // QIconView
virtual void setSorting( int column, bool increasing = TRUE ); // QListView
void setSorting( bool sort, bool ascending = TRUE ); // QIconView
void sort(); // #### make virtual in next major release // QListView
virtual void sort( bool ascending = TRUE ); // QIconView
*/
signals:
- void clicked( OVersatileViewItem *, const QPoint &, int ); // QListView
- void clicked( OVersatileViewItem *, const QPoint & ); // QIconView
+ void clicked( Opie::Ui::OVersatileViewItem *, const QPoint &, int ); // QListView
+ void clicked( Opie::Ui::OVersatileViewItem *, const QPoint & ); // QIconView
- void pressed( OVersatileViewItem *, const QPoint &, int ); // QListView
- void pressed( OVersatileViewItem *, const QPoint & ); // QIconView
+ void pressed( Opie::Ui::OVersatileViewItem *, const QPoint &, int ); // QListView
+ void pressed( Opie::Ui::OVersatileViewItem *, const QPoint & ); // QIconView
- void rightButtonClicked( OVersatileViewItem* item, const QPoint& pos ); // QIconView
- void rightButtonClicked( OVersatileViewItem *, const QPoint&, int ); // QListView
+ void rightButtonClicked( Opie::Ui::OVersatileViewItem* item, const QPoint& pos ); // QIconView
+ void rightButtonClicked( Opie::Ui::OVersatileViewItem *, const QPoint&, int ); // QListView
- void rightButtonPressed( OVersatileViewItem* item, const QPoint& pos ); // QIconView
- void rightButtonPressed( OVersatileViewItem *, const QPoint&, int ); // QListView
+ void rightButtonPressed( Opie::Ui::OVersatileViewItem* item, const QPoint& pos ); // QIconView
+ void rightButtonPressed( Opie::Ui::OVersatileViewItem *, const QPoint&, int ); // QListView
- void mouseButtonPressed( int, OVersatileViewItem *, const QPoint& , int ); // QListView
- void mouseButtonPressed( int button, OVersatileViewItem* item, const QPoint& pos ); // QIconView
+ void mouseButtonPressed( int, Opie::Ui::OVersatileViewItem *, const QPoint& , int ); // QListView
+ void mouseButtonPressed( int button, Opie::Ui::OVersatileViewItem* item, const QPoint& pos ); // QIconView
- void mouseButtonClicked( int, OVersatileViewItem *, const QPoint&, int ); // QListView
- void mouseButtonClicked( int button, OVersatileViewItem* item, const QPoint& pos ); // QIconView
+ void mouseButtonClicked( int, Opie::Ui::OVersatileViewItem *, const QPoint&, int ); // QListView
+ void mouseButtonClicked( int button, Opie::Ui::OVersatileViewItem* item, const QPoint& pos ); // QIconView
};
}
}
#endif