#include <kdialog.h>
#include <tdelocale.h>

/****************************************************************************
** Form implementation generated from reading ui file 'notifiermoduleview.ui'
**
** Created by: The TQt user interface compiler (TQt 3.5.0)
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/

#include "notifiermoduleview.h"

#include <ntqvariant.h>
#include <kcombobox.h>
#include <kpushbutton.h>
#include <tdelistbox.h>
#include <ntqpushbutton.h>
#include <ntqlabel.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>

/*
 *  Constructs a NotifierModuleView as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 */
NotifierModuleView::NotifierModuleView( TQWidget* parent, const char* name, WFlags fl )
    : TQWidget( parent, name, fl )
{
    if ( !name )
	setName( "NotifierModuleView" );
    NotifierModuleViewLayout = new TQGridLayout( this, 1, 1, 11, 6, "NotifierModuleViewLayout"); 

    layout4 = new TQVBoxLayout( 0, 0, 6, "layout4"); 

    layout2 = new TQHBoxLayout( 0, 0, 6, "layout2"); 

    mediumType = new TQLabel( this, "mediumType" );
    mediumType->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)5, 0, 0, mediumType->sizePolicy().hasHeightForWidth() ) );
    layout2->addWidget( mediumType );

    mimetypesCombo = new KComboBox( false, this, "mimetypesCombo" );
    mimetypesCombo->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)3, (TQSizePolicy::SizeType)0, 0, 0, mimetypesCombo->sizePolicy().hasHeightForWidth() ) );
    layout2->addWidget( mimetypesCombo );
    layout4->addLayout( layout2 );

    layout3 = new TQGridLayout( 0, 1, 1, 0, 6, "layout3"); 

    layout1 = new TQVBoxLayout( 0, 0, 6, "layout1"); 

    addButton = new KPushButton( this, "addButton" );
    layout1->addWidget( addButton );

    deleteButton = new KPushButton( this, "deleteButton" );
    layout1->addWidget( deleteButton );

    editButton = new KPushButton( this, "editButton" );
    layout1->addWidget( editButton );

    toggleAutoButton = new KPushButton( this, "toggleAutoButton" );
    layout1->addWidget( toggleAutoButton );

    layout3->addLayout( layout1, 0, 1 );
    buttonSpacer = new TQSpacerItem( 70, 101, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    layout3->addItem( buttonSpacer, 1, 1 );

    actionsList = new TDEListBox( this, "actionsList" );

    layout3->addMultiCellWidget( actionsList, 0, 1, 0, 0 );
    layout4->addLayout( layout3 );

    NotifierModuleViewLayout->addLayout( layout4, 0, 0 );
    languageChange();
    resize( TQSize(600, 480).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );
}

/*
 *  Destroys the object and frees any allocated resources
 */
NotifierModuleView::~NotifierModuleView()
{
    // no need to delete child widgets, TQt does it all for us
}

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void NotifierModuleView::languageChange()
{
    mediumType->setText( tr2i18n( "Medium types:" ) );
    TQWhatsThis::add( mimetypesCombo, tr2i18n( "Here is the list of the available types of medium which can be monitored. You can filter the available actions by selecting a type of medium. If you want to see all the actions, select \"All Mime Types\"." ) );
    addButton->setText( tr2i18n( "&Add..." ) );
    TQWhatsThis::add( addButton, tr2i18n( "Click here to add an action." ) );
    deleteButton->setText( tr2i18n( "&Delete" ) );
    TQWhatsThis::add( deleteButton, tr2i18n( "Click here to delete the selected action if possible." ) );
    editButton->setText( tr2i18n( "&Edit..." ) );
    TQWhatsThis::add( editButton, tr2i18n( "Click here to edit the selected action if possible." ) );
    toggleAutoButton->setText( tr2i18n( "&Toggle as Auto Action" ) );
    TQWhatsThis::add( toggleAutoButton, tr2i18n( "Click here to perform this action automatically on detection of the selected medium type (this option is disabled when \"All Mime Types\" is selected)." ) );
    TQWhatsThis::add( actionsList, tr2i18n( "Here is the list of the available actions. You can modify them by using the buttons on your right." ) );
}

/****************************************************************************
** NotifierModuleView meta object code from reading C++ file 'notifiermoduleview.h'
**
** Created by: The TQt Meta Object Compiler version 26 (TQt 3.5.0)
** WARNING! All changes made in this file will be lost!
*****************************************************************************/

#undef TQT_NO_COMPAT
#include "notifiermoduleview.h"
#include <ntqmetaobject.h>
#include <ntqapplication.h>

#include <private/qucomextra_p.h>
#if !defined(Q_MOC_OUTPUT_REVISION) || (Q_MOC_OUTPUT_REVISION != 26)
#error "This file was generated using the moc from 3.5.0. It"
#error "cannot be used with the include files from this version of TQt."
#error "(The moc has changed too much.)"
#endif

const char *NotifierModuleView::className() const
{
    return "NotifierModuleView";
}

TQMetaObject *NotifierModuleView::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_NotifierModuleView( "NotifierModuleView", &NotifierModuleView::staticMetaObject );

#ifndef TQT_NO_TRANSLATION
TQString NotifierModuleView::tr( const char *s, const char *c )
{
    if ( tqApp )
	return tqApp->translate( "NotifierModuleView", s, c, TQApplication::DefaultCodec );
    else
	return TQString::fromLatin1( s );
}
#ifndef TQT_NO_TRANSLATION_UTF8
TQString NotifierModuleView::trUtf8( const char *s, const char *c )
{
    if ( tqApp )
	return tqApp->translate( "NotifierModuleView", s, c, TQApplication::UnicodeUTF8 );
    else
	return TQString::fromUtf8( s );
}
#endif // TQT_NO_TRANSLATION_UTF8

#endif // TQT_NO_TRANSLATION

TQMetaObject* NotifierModuleView::staticMetaObject()
{
    if ( metaObj ) {
	return metaObj;
}
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->lock();
    if ( metaObj ) {
	if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
	return metaObj;
    }
#endif // TQT_THREAD_SUPPORT
    TQMetaObject* parentObject = TQWidget::staticMetaObject();
    static const TQUMethod slot_0 = {"languageChange", 0, 0 };
    static const TQMetaData slot_tbl[] = {
	{ "languageChange()", &slot_0, TQMetaData::Protected }
    };
    metaObj = TQMetaObject::new_metaobject(
	"NotifierModuleView", parentObject,
	slot_tbl, 1,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_NotifierModuleView.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

void* NotifierModuleView::tqt_cast( const char* clname )
{
    if ( !qstrcmp( clname, "NotifierModuleView" ) )
	return this;
    return TQWidget::tqt_cast( clname );
}

bool NotifierModuleView::tqt_invoke( int _id, TQUObject* _o )
{
    switch ( _id - staticMetaObject()->slotOffset() ) {
    case 0: languageChange(); break;
    default:
	return TQWidget::tqt_invoke( _id, _o );
    }
    return true;
}

bool NotifierModuleView::tqt_emit( int _id, TQUObject* _o )
{
    return TQWidget::tqt_emit(_id,_o);
}
#ifndef TQT_NO_PROPERTIES

bool NotifierModuleView::tqt_property( int id, int f, TQVariant* v)
{
    return TQWidget::tqt_property( id, f, v);
}

bool NotifierModuleView::tqt_static_property( TQObject* , int , int , TQVariant* ){ return false; }
#endif // TQT_NO_PROPERTIES
