[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: extragear/base/konq-plugins/uachanger
From: Laurent Montel <montel () kde ! org>
Date: 2008-04-08 6:49:05
Message-ID: 1207637345.249587.19860.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 794630 by mlaurent:
Now we can change ua in webkitkde too
M +2 -1 CMakeLists.txt
M +6 -5 uachangerplugin.cpp
M +2 -3 uachangerplugin.h
--- trunk/extragear/base/konq-plugins/uachanger/CMakeLists.txt #794629:794630
@@ -11,7 +11,7 @@
-target_link_libraries(uachangerplugin ${KDE4_KHTML_LIBS} )
+target_link_libraries(uachangerplugin ${KDE4_KPARTS_LIBS} )
install(TARGETS uachangerplugin DESTINATION ${PLUGIN_INSTALL_DIR} )
@@ -19,3 +19,4 @@
########### install files ###############
install( FILES uachangerplugin.rc uachangerplugin.desktop DESTINATION \
${DATA_INSTALL_DIR}/khtml/kpartplugins ) +install( FILES uachangerplugin.rc \
uachangerplugin.desktop DESTINATION \
${DATA_INSTALL_DIR}/webkitpart/kpartplugins )
--- trunk/extragear/base/konq-plugins/uachanger/uachangerplugin.cpp #794629:794630
@@ -36,7 +36,8 @@
#include <kservice.h>
#include <kcomponentdata.h>
#include <kmenu.h>
-#include <khtml_part.h>
+#include <KConfigGroup>
+#include <kparts/part.h>
#include <kgenericfactory.h>
#include <kprotocolmanager.h>
#include <kaboutdata.h>
@@ -68,11 +69,11 @@
m_pUAMenu->setEnabled ( false );
- if ( parent && parent->inherits( "KHTMLPart" ) )
+ if ( parent )
{
- m_part = static_cast<KHTMLPart*>(parent);
- connect( m_part, SIGNAL(started(KIO::Job*)), this,
- SLOT(slotStarted(KIO::Job*)) );
+ m_part = qobject_cast<KParts::ReadOnlyPart *>(parent );
+ connect( m_part, SIGNAL(started(KIO::Job*)), this,
+ SLOT(slotStarted(KIO::Job*)) );
}
}
--- trunk/extragear/base/konq-plugins/uachanger/uachangerplugin.h #794629:794630
@@ -29,7 +29,6 @@
#include <klibloader.h>
#include <kparts/plugin.h>
-class KHTMLPart;
class KActionMenu;
class KConfig;
@@ -52,7 +51,7 @@
void parseDescFiles();
void updateIOSlaves();
- void slotConfigure();
+ void slotConfigure();
void slotAboutToShow();
void slotApplyToDomain();
void slotItemSelected(int);
@@ -71,7 +70,7 @@
bool m_bApplyToDomain;
bool m_bSettingsLoaded;
- KHTMLPart* m_part;
+ KParts::ReadOnlyPart* m_part;
KActionMenu* m_pUAMenu;
KConfig* m_config;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic