Home | All Classes | Main Classes | Annotated | Grouped Classes | Functions |

# qmotifdialog.h

This is the verbatim text of the qmotifdialog.h include file. It is provided only for illustration; the copyright remains with Trolltech.

    #ifndef QMOTIFDIALOG_H
    #define QMOTIFDIALOG_H

    #include <qdialog.h>
    #include <X11/Intrinsic.h>
    #include <Xm/Xm.h>

    class QMotifWidget;
    class QMotifDialogPrivate;

    class QMotifDialog : public QDialog
    {
        Q_OBJECT

    public:
        enum DialogType {
    	Prompt,
    	Selection,
    	Command,
    	FileSelection,
    	Template,
    	Error,
    	Information,
    	Message,
    	Question,
    	Warning,
    	Working
        };

        QMotifDialog( DialogType dialogtype, Widget parent = NULL,
                      ArgList args = NULL, Cardinal argcount = 0,
    		  const char *name = 0, bool modal = FALSE, WFlags flags = 0 );
        QMotifDialog( Widget = NULL, ArgList = NULL, Cardinal = 0,
    		  const char * = 0, bool = FALSE, WFlags = 0 );
        virtual ~QMotifDialog();

        Widget shell() const;
        Widget dialog() const;

        void show();
        void hide();

        static void acceptCallback( Widget, XtPointer, XtPointer );
        static void rejectCallback( Widget, XtPointer, XtPointer );

    public slots:
        void accept();
        void reject();

    protected:
        bool event( QEvent * );

    private:
        QMotifDialogPrivate *d;

        void realize( Widget );
        void insertChild( Widget );
        void deleteChild( Widget );

        friend void qmotif_dialog_realize( Widget, XtValueMask *, XSetWindowAttributes *);
        friend void qmotif_dialog_insert_child( Widget );
        friend void qmotif_dialog_delete_child( Widget );
        friend void qmotif_dialog_change_managed( Widget );
    };

    #endif // QMOTIFDIALOG_H