summaryrefslogtreecommitdiffstats
path: root/parts/astyle/astyle_part.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'parts/astyle/astyle_part.cpp')
-rw-r--r--parts/astyle/astyle_part.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/parts/astyle/astyle_part.cpp b/parts/astyle/astyle_part.cpp
index f5b5e2e7..df911cc1 100644
--- a/parts/astyle/astyle_part.cpp
+++ b/parts/astyle/astyle_part.cpp
@@ -33,7 +33,7 @@
#include "astyle_widget.h"
#include "astyle_adaptor.h"
-static const KDevPluginInfo data("kdevastyle");
+static const KDevPluginInfo pluginData("kdevastyle");
namespace {
const char* defaultFormatExtensions = "*.cpp *.h *.hpp,*.c *.h,*.cxx *.hxx,*.c++ *.h++,*.cc *.hh,*.C *.H,*.diff ,*.inl,*.java,*.moc,*.patch,*.tlh,*.xpm";
@@ -41,22 +41,22 @@ namespace {
typedef KDevGenericFactory<AStylePart> AStyleFactory;
-K_EXPORT_COMPONENT_FACTORY( libkdevastyle, AStyleFactory( data ) )
+K_EXPORT_COMPONENT_FACTORY( libkdevastyle, AStyleFactory( pluginData ) )
AStylePart::AStylePart(TQObject *parent, const char *name, const TQStringList &)
- : KDevSourceFormatter(&data, parent, name ? name : "AStylePart")
+ : KDevSourceFormatter(&pluginData, parent, name ? name : "AStylePart")
{
setInstance(AStyleFactory::instance());
setXMLFile("kdevpart_astyle.rc");
- formatTextAction = new TDEAction(i18n("&Reformat Source"), 0, this, TQT_SLOT(beautifySource()), actionCollection(), "edit_astyle");
+ formatTextAction = new TDEAction(i18n("&Reformat Source"), 0, this, TQ_SLOT(beautifySource()), actionCollection(), "edit_astyle");
formatTextAction->setEnabled(false);
formatTextAction->setToolTip(i18n("Reformat source"));
formatTextAction->setWhatsThis(i18n("<b>Reformat source</b><p>Source reformatting functionality using <b>astyle</b> library. "
"Also available in <b>New Class</b> and <b>Subclassing</b> wizards."));
- formatFileAction = new TDEAction(i18n("Format files"), 0, this, TQT_SLOT(formatFilesSelect()), actionCollection(), "tools_astyle");
+ formatFileAction = new TDEAction(i18n("Format files"), 0, this, TQ_SLOT(formatFilesSelect()), actionCollection(), "tools_astyle");
formatFileAction->setEnabled(false);
formatFileAction->setToolTip(i18n("Format files"));
formatFileAction->setWhatsThis(i18n("<b>Fomat files</b><p>Formatting functionality using <b>astyle</b> library. "
@@ -68,11 +68,11 @@ AStylePart::AStylePart(TQObject *parent, const char *name, const TQStringList &)
m_configProxy->createProjectConfigPage(i18n("Formatting"), PROJECTDOC_OPTIONS, info()->icon());
- connect(m_configProxy, TQT_SIGNAL(insertConfigWidget(const KDialogBase* ,TQWidget*,unsigned int)), this, TQT_SLOT(insertConfigWidget(const KDialogBase*,TQWidget*,unsigned int)));
+ connect(m_configProxy, TQ_SIGNAL(insertConfigWidget(const KDialogBase* ,TQWidget*,unsigned int)), this, TQ_SLOT(insertConfigWidget(const KDialogBase*,TQWidget*,unsigned int)));
- connect(partController(), TQT_SIGNAL(activePartChanged(KParts::Part*)), this, TQT_SLOT(activePartChanged(KParts::Part*)));
+ connect(partController(), TQ_SIGNAL(activePartChanged(KParts::Part*)), this, TQ_SLOT(activePartChanged(KParts::Part*)));
- connect( core(), TQT_SIGNAL(contextMenu(TQPopupMenu *, const Context *)), this, TQT_SLOT(contextMenu(TQPopupMenu *, const Context *)) );
+ connect( core(), TQ_SIGNAL(contextMenu(TQPopupMenu *, const Context *)), this, TQ_SLOT(contextMenu(TQPopupMenu *, const Context *)) );
loadGlobal();
//use the globals first, project level will override later..
@@ -88,7 +88,7 @@ AStylePart::AStylePart(TQObject *parent, const char *name, const TQStringList &)
void AStylePart::loadGlobal()
{
// kdDebug(9009) << "Load global"<<endl;
- TDEConfig *config = kapp->config();
+ TDEConfig *config = tdeApp->config();
config->setGroup("AStyle");
TQString options = config->readEntry("Options","BlockBreak=0,BlockBreakAll=0,BlockIfElse=0,Brackets=Break,BracketsCloseHeaders=0,FStyle=UserDefined,Fill=Tabs,FillCount=4,FillEmptyLines=0,FillForce=0,IndentBlocks=0,IndentBrackets=0,IndentCases=0,IndentClasses=1,IndentLabels=1,IndentNamespaces=1,IndentPreprocessors=0,IndentSwitches=1,KeepBlocks=1,KeepStatements=1,MaxStatement=40,MinConditional=-1,PadOperators=0,PadParenthesesIn=1,PadParenthesesOut=1,PadParenthesesUn=1,");
m_globalExtensions=TQStringList::split(",",config->readEntry("Extensions",defaultFormatExtensions));
@@ -123,7 +123,7 @@ void AStylePart::saveGlobal()
// kdDebug(9009) << "project before: " <<iter.key() << "="<< iter.data() << endl;
// }
- TDEConfig *config = kapp->config();
+ TDEConfig *config = tdeApp->config();
config->setGroup("AStyle");
config->writeEntry("Options",options);
config->writeEntry("Extensions",m_globalExtensions.join(","));
@@ -249,13 +249,13 @@ void AStylePart::insertConfigWidget(const KDialogBase *dlg, TQWidget *page, unsi
case GLOBALDOC_OPTIONS:
{
AStyleWidget *w = new AStyleWidget(this, true, page, "astyle config widget");
- connect(dlg, TQT_SIGNAL(okClicked()), w, TQT_SLOT(accept()));
+ connect(dlg, TQ_SIGNAL(okClicked()), w, TQ_SLOT(accept()));
break;
}
case PROJECTDOC_OPTIONS:
{
AStyleWidget *w = new AStyleWidget(this, false, page, "astyle config widget");
- connect(dlg, TQT_SIGNAL(okClicked()), w, TQT_SLOT(accept()));
+ connect(dlg, TQ_SIGNAL(okClicked()), w, TQ_SLOT(accept()));
break;
}
}
@@ -399,7 +399,7 @@ void AStylePart::contextMenu(TQPopupMenu *popup, const Context *context)
if (context->hasType( Context::EditorContext ))
{
popup->insertSeparator();
- int id = popup->insertItem( i18n("Format selection"), this, TQT_SLOT(beautifySource()) );
+ int id = popup->insertItem( i18n("Format selection"), this, TQ_SLOT(beautifySource()) );
popup->TQMenuData::setWhatsThis(id, i18n("<b>Format</b><p>Formats the current selection, if possible"));
}
else if ( context->hasType( Context::FileContext )){
@@ -407,7 +407,7 @@ void AStylePart::contextMenu(TQPopupMenu *popup, const Context *context)
m_urls = ctx->urls();
popup->insertSeparator();
- int id = popup->insertItem( i18n("Format files"), this, TQT_SLOT(formatFiles()) );
+ int id = popup->insertItem( i18n("Format files"), this, TQ_SLOT(formatFiles()) );
popup->TQMenuData::setWhatsThis(id, i18n("<b>Format files</b><p>Formats selected files if possible"));
}