diff options
Diffstat (limited to 'konq-plugins/babelfish/plugin_babelfish.cpp')
-rw-r--r-- | konq-plugins/babelfish/plugin_babelfish.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/konq-plugins/babelfish/plugin_babelfish.cpp b/konq-plugins/babelfish/plugin_babelfish.cpp index bf2e7da..4d1a61b 100644 --- a/konq-plugins/babelfish/plugin_babelfish.cpp +++ b/konq-plugins/babelfish/plugin_babelfish.cpp @@ -34,9 +34,9 @@ typedef KGenericFactory<PluginBabelFish> BabelFishFactory; static const KAboutData aboutdata("babelfish", I18N_NOOP("Translate Web Page") , "1.0" ); K_EXPORT_COMPONENT_FACTORY( libbabelfishplugin, BabelFishFactory( &aboutdata ) ) -PluginBabelFish::PluginBabelFish( TQObject* tqparent, const char* name, +PluginBabelFish::PluginBabelFish( TQObject* parent, const char* name, const TQStringList & ) - : Plugin( tqparent, name ) + : Plugin( parent, name ) { setInstance(BabelFishFactory::instance()); @@ -178,9 +178,9 @@ PluginBabelFish::PluginBabelFish( TQObject* tqparent, const char* name, m_menu->setEnabled( true ); // TODO: we could also support plain text viewers... - if ( tqparent && tqparent->inherits( "KHTMLPart" ) ) + if ( parent && parent->inherits( "KHTMLPart" ) ) { - KParts::ReadOnlyPart* part = static_cast<KParts::ReadOnlyPart *>(tqparent); + KParts::ReadOnlyPart* part = static_cast<KParts::ReadOnlyPart *>(parent); connect( part, TQT_SIGNAL(started(KIO::Job*)), this, TQT_SLOT(slotStarted(KIO::Job*)) ); } @@ -193,9 +193,9 @@ PluginBabelFish::~PluginBabelFish() void PluginBabelFish::slotStarted( KIO::Job* ) { - if ( tqparent()->inherits("KHTMLPart") && + if ( parent()->inherits("KHTMLPart") && // Babelfish wants http URLs only. No https. - static_cast<KParts::ReadOnlyPart *>(tqparent())->url().protocol().lower() == "http" ) + static_cast<KParts::ReadOnlyPart *>(parent())->url().protocol().lower() == "http" ) { m_menu->setEnabled( true ); } @@ -211,8 +211,8 @@ void PluginBabelFish::translateURL() if ( !sender() ) return; - // The tqparent is assumed to be a KHTMLPart - if ( !tqparent()->inherits("KHTMLPart") ) + // The parent is assumed to be a KHTMLPart + if ( !parent()->inherits("KHTMLPart") ) { TQString title = i18n( "Cannot Translate Source" ); TQString text = i18n( "Only web pages can be translated using " @@ -227,7 +227,7 @@ void PluginBabelFish::translateURL() TQString engine = cfg.readEntry( TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender()))->name(), "babelfish" ); // Get URL - KHTMLPart *part = dynamic_cast<KHTMLPart *>(tqparent()); + KHTMLPart *part = dynamic_cast<KHTMLPart *>(parent()); if ( !part ) return; |