summaryrefslogtreecommitdiffstats
path: root/parts/filecreate/addglobaldlg.cpp
diff options
context:
space:
mode:
authortoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
committertoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
commit114a878c64ce6f8223cfd22d76a20eb16d177e5e (patch)
treeacaf47eb0fa12142d3896416a69e74cbf5a72242 /parts/filecreate/addglobaldlg.cpp
downloadtdevelop-114a878c64ce6f8223cfd22d76a20eb16d177e5e.tar.gz
tdevelop-114a878c64ce6f8223cfd22d76a20eb16d177e5e.zip
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'parts/filecreate/addglobaldlg.cpp')
-rw-r--r--parts/filecreate/addglobaldlg.cpp106
1 files changed, 106 insertions, 0 deletions
diff --git a/parts/filecreate/addglobaldlg.cpp b/parts/filecreate/addglobaldlg.cpp
new file mode 100644
index 00000000..0757d220
--- /dev/null
+++ b/parts/filecreate/addglobaldlg.cpp
@@ -0,0 +1,106 @@
+#include <klocale.h>
+/****************************************************************************
+** Form implementation generated from reading ui file './addglobaldlg.ui'
+**
+** Created: Сбт Лют 8 20:51:03 2003
+** by: The User Interface Compiler ($Id$)
+**
+** WARNING! All changes made in this file will be lost!
+****************************************************************************/
+
+#include "addglobaldlg.h"
+
+#include <qvariant.h>
+#include <qheader.h>
+#include <qlistview.h>
+#include <qpushbutton.h>
+#include <qlayout.h>
+#include <qtooltip.h>
+#include <qwhatsthis.h>
+
+#include <klocale.h>
+
+/*
+ * Constructs a AddGlobalDlg as a child of 'parent', with the
+ * name 'name' and widget flags set to 'f'.
+ *
+ * The dialog will by default be modeless, unless you set 'modal' to
+ * TRUE to construct a modal dialog.
+ */
+AddGlobalDlg::AddGlobalDlg( QWidget* parent, const char* name, bool modal, WFlags fl )
+ : QDialog( parent, name, modal, fl )
+
+{
+ if ( !name )
+ setName( "AddGlobalDlg" );
+ setSizeGripEnabled( TRUE );
+ AddGlobalDlgLayout = new QGridLayout( this, 1, 1, 11, 6, "AddGlobalDlgLayout");
+
+ Layout1 = new QHBoxLayout( 0, 0, 6, "Layout1");
+
+ buttonHelp = new KPushButton( this, "buttonHelp" );
+ buttonHelp->setAutoDefault( TRUE );
+ Layout1->addWidget( buttonHelp );
+ QSpacerItem* spacer = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum );
+ Layout1->addItem( spacer );
+
+ buttonOk = new KPushButton( this, "buttonOk" );
+ buttonOk->setAutoDefault( TRUE );
+ buttonOk->setDefault( TRUE );
+ Layout1->addWidget( buttonOk );
+
+ buttonCancel = new KPushButton( this, "buttonCancel" );
+ buttonCancel->setAutoDefault( TRUE );
+ Layout1->addWidget( buttonCancel );
+
+ AddGlobalDlgLayout->addLayout( Layout1, 1, 0 );
+
+ fcglobal_view = new QListView( this, "fcglobal_view" );
+ fcglobal_view->addColumn( i18n( "Type Extension" ) );
+ fcglobal_view->addColumn( i18n( "Type Name" ) );
+ fcglobal_view->addColumn( i18n( "Template Location" ) );
+ fcglobal_view->addColumn( i18n( "Icon" ) );
+ fcglobal_view->addColumn( i18n( "Description" ) );
+ fcglobal_view->setResizePolicy( QListView::AutoOne );
+ fcglobal_view->setAllColumnsShowFocus( TRUE );
+ fcglobal_view->setRootIsDecorated( TRUE );
+ fcglobal_view->setResizeMode( QListView::AllColumns );
+
+ AddGlobalDlgLayout->addWidget( fcglobal_view, 0, 0 );
+ languageChange();
+ resize( QSize(511, 282).expandedTo(minimumSizeHint()) );
+
+ // signals and slots connections
+ connect( buttonOk, SIGNAL( clicked() ), this, SLOT( accept() ) );
+ connect( buttonCancel, SIGNAL( clicked() ), this, SLOT( reject() ) );
+}
+
+/*
+ * Destroys the object and frees any allocated resources
+ */
+AddGlobalDlg::~AddGlobalDlg()
+{
+ // no need to delete child widgets, Qt does it all for us
+}
+
+/*
+ * Sets the strings of the subwidgets using the current
+ * language.
+ */
+void AddGlobalDlg::languageChange()
+{
+ setCaption( i18n( "Select Global File Types" ) );
+ buttonHelp->setGuiItem( KStdGuiItem::help() );
+ buttonHelp->setAccel( QKeySequence( tr2i18n( "F1" ) ) );
+ buttonOk->setGuiItem( KStdGuiItem::ok() );
+ buttonOk->setAccel( QKeySequence( QString::null ) );
+ buttonCancel->setGuiItem( KStdGuiItem::cancel() );
+ buttonCancel->setAccel( QKeySequence( QString::null ) );
+ fcglobal_view->header()->setLabel( 0, i18n( "Type extension:" ) );
+ fcglobal_view->header()->setLabel( 1, i18n( "Type name:" ) );
+ fcglobal_view->header()->setLabel( 2, i18n( "Template location:" ) );
+ fcglobal_view->header()->setLabel( 3, i18n( "Icon:" ) );
+ fcglobal_view->header()->setLabel( 4, i18n( "Description:" ) );
+}
+
+#include "addglobaldlg.moc"