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

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

#include "kmenubase.h"

#include <ntqvariant.h>
#include <kcombobox.h>
#include <ntqpushbutton.h>
#include <ntqframe.h>
#include <ntqlabel.h>
#include <ntqtoolbutton.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>
#include <ntqimage.h>
#include <ntqpixmap.h>

#include "kmenubase.ui.h"
static const unsigned char image0_data[] = { 
    0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d,
    0x49, 0x48, 0x44, 0x52, 0x00, 0x00, 0x00, 0x5a, 0x00, 0x00, 0x00, 0x18,
    0x08, 0x06, 0x00, 0x00, 0x00, 0x7a, 0x38, 0xea, 0x65, 0x00, 0x00, 0x01,
    0x22, 0x49, 0x44, 0x41, 0x54, 0x68, 0x81, 0xed, 0x98, 0x61, 0x0e, 0x83,
    0x20, 0x0c, 0x85, 0xc7, 0xe2, 0xa9, 0x3c, 0x00, 0x87, 0xe6, 0x00, 0x5c,
    0x0b, 0x7f, 0x75, 0x41, 0x52, 0xea, 0x43, 0xa5, 0x32, 0xec, 0x97, 0x2c,
    0x51, 0x2c, 0xf5, 0xf9, 0x6c, 0x28, 0xd3, 0xc5, 0x18, 0x3f, 0x46, 0x7f,
    0xbe, 0x4f, 0x0b, 0x78, 0x0b, 0x66, 0xb4, 0x12, 0x66, 0xb4, 0x12, 0x66,
    0xb4, 0x12, 0xcb, 0xd3, 0x02, 0xb4, 0x59, 0x43, 0x48, 0xd2, 0xf5, 0xe8,
    0xbd, 0x93, 0xe2, 0xe8, 0x3a, 0x9a, 0x93, 0xe2, 0xad, 0xa2, 0x1b, 0x39,
    0x7a, 0x51, 0x35, 0x5e, 0x57, 0xd1, 0x79, 0x45, 0x92, 0x69, 0x5c, 0x95,
    0x4a, 0xf1, 0x6b, 0x08, 0x89, 0x9b, 0x23, 0xe5, 0xf9, 0x55, 0xf4, 0x1a,
    0x42, 0xa2, 0x5f, 0xbb, 0xfc, 0xbe, 0x70, 0x9a, 0x9e, 0xd0, 0xc9, 0x99,
    0x8e, 0xb2, 0x5b, 0x3a, 0xa2, 0xf7, 0x2e, 0x7a, 0xef, 0x46, 0x34, 0xfb,
    0xdf, 0x39, 0x5c, 0x3a, 0x72, 0xd3, 0xf3, 0x46, 0x81, 0x1c, 0x73, 0xf3,
    0x90, 0xb1, 0x72, 0xfc, 0xac, 0x36, 0xee, 0xfc, 0x2a, 0x52, 0x21, 0x72,
    0xe3, 0x74, 0x6f, 0xd1, 0xe8, 0xb3, 0xa2, 0xa5, 0x79, 0x52, 0x3e, 0x3a,
    0xe7, 0xc6, 0xb9, 0xfb, 0xf4, 0x34, 0xf4, 0x6e, 0x76, 0x46, 0x23, 0xcd,
    0xa1, 0x8c, 0xe7, 0x8c, 0xc9, 0x73, 0x21, 0x39, 0x50, 0xb1, 0x08, 0xb9,
    0x9e, 0x1e, 0xe6, 0x23, 0x5b, 0x39, 0x8e, 0x05, 0x0d, 0x44, 0xe2, 0xf2,
    0xf1, 0xab, 0xb9, 0x66, 0xe3, 0xf4, 0x3e, 0xba, 0x5c, 0x0e, 0x46, 0x6b,
    0xa0, 0x3d, 0xf4, 0xd4, 0xfa, 0x09, 0x82, 0xb8, 0x46, 0x97, 0x06, 0xb6,
    0x54, 0x69, 0xf9, 0xa0, 0xb5, 0x7d, 0x27, 0x17, 0x87, 0xbe, 0xb8, 0x9a,
    0xb6, 0x3b, 0x97, 0x0d, 0xa9, 0xc1, 0xb5, 0xc4, 0xba, 0x59, 0xbf, 0x47,
    0x23, 0x46, 0x4b, 0x3d, 0xe9, 0xee, 0xbf, 0xe0, 0x53, 0x1a, 0x3d, 0xe2,
    0x0e, 0x64, 0xba, 0x6f, 0x1d, 0xa3, 0xf5, 0x0a, 0x62, 0xca, 0x8a, 0x1e,
    0x91, 0xe9, 0x2a, 0x7a, 0x54, 0xcc, 0x68, 0x25, 0xcc, 0x68, 0x25, 0xcc,
    0x68, 0x25, 0x36, 0xf1, 0x0e, 0x05, 0x8b, 0xc1, 0xbc, 0xdf, 0x31, 0x00,
    0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae, 0x42, 0x60, 0x82
};


/*
 *  Constructs a KMenuBase as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 *
 *  The qdialog will by default be modeless, unless you set 'modal' to
 *  true to construct a modal qdialog.
 */
KMenuBase::KMenuBase( TQWidget* parent, const char* name, bool modal, WFlags fl )
    : TQDialog( parent, name, modal, fl )
{
    TQImage img;
    img.loadFromData( image0_data, sizeof( image0_data ), "PNG" );
    image0 = img;
    if ( !name )
	setName( "KMenu" );

    TQWidget* privateLayoutWidget = new TQWidget( this, "m_search" );
    privateLayoutWidget->setGeometry( TQRect( 20, 40, 190, 54 ) );
    m_search = new TQHBoxLayout( privateLayoutWidget, 0, 0, "m_search"); 

    m_searchFrame = new TQFrame( privateLayoutWidget, "m_searchFrame" );
    m_searchFrame->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)0, 0, 0, m_searchFrame->sizePolicy().hasHeightForWidth() ) );
    m_searchFrame->setMinimumSize( TQSize( 0, 52 ) );
    m_searchFrame->setMaximumSize( TQSize( 32767, 52 ) );
    m_searchFrame->setFrameShape( TQFrame::StyledPanel );
    m_searchFrame->setFrameShadow( TQFrame::Raised );
    m_searchFrame->setLineWidth( 0 );
    m_searchFrameLayout = new TQHBoxLayout( m_searchFrame, 11, 6, "m_searchFrameLayout"); 

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

    m_searchLabel = new TQLabel( m_searchFrame, "m_searchLabel" );
    m_searchLabel->setBackgroundOrigin( TQLabel::ParentOrigin );
    TQFont m_searchLabel_font(  m_searchLabel->font() );
    m_searchLabel_font.setPointSize( 14 );
    m_searchLabel->setFont( m_searchLabel_font ); 
    layout18->addWidget( m_searchLabel );

    m_kcommand = new KHistoryCombo( m_searchFrame, "m_kcommand" );
    m_kcommand->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)0, 0, 0, m_kcommand->sizePolicy().hasHeightForWidth() ) );
    layout18->addWidget( m_kcommand );

    m_searchPixmap = new TQLabel( m_searchFrame, "m_searchPixmap" );
    m_searchPixmap->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, m_searchPixmap->sizePolicy().hasHeightForWidth() ) );
    m_searchPixmap->setMinimumSize( TQSize( 32, 32 ) );
    m_searchPixmap->setMaximumSize( TQSize( 32, 32 ) );
    m_searchPixmap->setBackgroundMode( TQLabel::PaletteBackground );
    m_searchPixmap->setBackgroundOrigin( TQLabel::ParentOrigin );
    m_searchPixmap->setScaledContents( true );
    layout18->addWidget( m_searchPixmap );
    m_searchFrameLayout->addLayout( layout18 );
    m_search->addWidget( m_searchFrame );
    spacer5_2 = new TQSpacerItem( 16, 20, TQSizePolicy::Preferred, TQSizePolicy::Minimum );
    m_search->addItem( spacer5_2 );

    TQWidget* privateLayoutWidget_2 = new TQWidget( this, "m_footer" );
    privateLayoutWidget_2->setGeometry( TQRect( 20, 110, 407, 34 ) );
    m_footer = new TQHBoxLayout( privateLayoutWidget_2, 4, 4, "m_footer"); 

    m_userInfo = new TQLabel( privateLayoutWidget_2, "m_userInfo" );
    m_userInfo->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)3, (TQSizePolicy::SizeType)0, 0, 0, m_userInfo->sizePolicy().hasHeightForWidth() ) );
    m_footer->addWidget( m_userInfo );
    spacer13_2 = new TQSpacerItem( 10, 20, TQSizePolicy::MinimumExpanding, TQSizePolicy::Minimum );
    m_footer->addItem( spacer13_2 );

    m_branding = new TQToolButton( privateLayoutWidget_2, "m_branding" );
    m_branding->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)4, (TQSizePolicy::SizeType)4, 0, 0, m_branding->sizePolicy().hasHeightForWidth() ) );
    m_branding->setMaximumSize( TQSize( 90, 24 ) );
    m_branding->setIconSet( TQIconSet( image0 ) );
    m_branding->setUsesBigPixmap( true );
    m_branding->setAutoRaise( true );
    m_footer->addWidget( m_branding );
    spacer13 = new TQSpacerItem( 14, 20, TQSizePolicy::Fixed, TQSizePolicy::Minimum );
    m_footer->addItem( spacer13 );
    languageChange();
    resize( TQSize(723, 580).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );
    init();
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void KMenuBase::languageChange()
{
    setCaption( tr2i18n( "KMenu" ) );
    m_searchLabel->setText( tr2i18n( "Search:" ) );
    m_userInfo->setText( tr2i18n( "User&nbsp;<b>user</b>&nbsp;on&nbsp;<b>host</b>" ) );
    m_branding->setText( TQString::null );
}

/****************************************************************************
** KMenuBase meta object code from reading C++ file 'kmenubase.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 "kmenubase.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 *KMenuBase::className() const
{
    return "KMenuBase";
}

TQMetaObject *KMenuBase::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_KMenuBase( "KMenuBase", &KMenuBase::staticMetaObject );

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

#endif // TQT_NO_TRANSLATION

TQMetaObject* KMenuBase::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 = TQDialog::staticMetaObject();
    static const TQUMethod slot_0 = {"languageChange", 0, 0 };
    static const TQMetaData slot_tbl[] = {
	{ "languageChange()", &slot_0, TQMetaData::Protected }
    };
    metaObj = TQMetaObject::new_metaobject(
	"KMenuBase", parentObject,
	slot_tbl, 1,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_KMenuBase.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

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

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

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

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

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