summaryrefslogtreecommitdiffstats
path: root/khtml/khtml_settings.cc
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-07 03:45:53 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-07 03:45:53 +0000
commit10308be19ef7fa44699562cc75946e7ea1fdf6b9 (patch)
tree4bc444c00a79e88105f2cfce5b6209994c413ca0 /khtml/khtml_settings.cc
parent307136d8eef0ba133b78ceee8e901138d4c996a1 (diff)
downloadtdelibs-10308be19ef7fa44699562cc75946e7ea1fdf6b9.tar.gz
tdelibs-10308be19ef7fa44699562cc75946e7ea1fdf6b9.zip
Revert automated changes
Sorry guys, they are just not ready for prime time Work will continue as always git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1212479 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'khtml/khtml_settings.cc')
-rw-r--r--khtml/khtml_settings.cc62
1 files changed, 31 insertions, 31 deletions
diff --git a/khtml/khtml_settings.cc b/khtml/khtml_settings.cc
index 5401bc300..8e1c0f934 100644
--- a/khtml/khtml_settings.cc
+++ b/khtml/khtml_settings.cc
@@ -40,7 +40,7 @@ struct KPerDomainSettings {
bool m_bEnablePlugins : 1;
// don't forget to maintain the bitfields as the enums grow
KHTMLSettings::KJSWindowOpenPolicy m_windowOpenPolicy : 2;
- KHTMLSettings::KJSWindowtqStatusPolicy m_windowtqStatusPolicy : 1;
+ KHTMLSettings::KJSWindowStatusPolicy m_windowStatusPolicy : 1;
KHTMLSettings::KJSWindowFocusPolicy m_windowFocusPolicy : 1;
KHTMLSettings::KJSWindowMovePolicy m_windowMovePolicy : 1;
KHTMLSettings::KJSWindowResizePolicy m_windowResizePolicy : 1;
@@ -52,7 +52,7 @@ struct KPerDomainSettings {
kdDebug() << " m_bEnableJavaScript: " << m_bEnableJavaScript << endl;
kdDebug() << " m_bEnablePlugins: " << m_bEnablePlugins << endl;
kdDebug() << " m_windowOpenPolicy: " << m_windowOpenPolicy << endl;
- kdDebug() << " m_windowtqStatusPolicy: " << m_windowtqStatusPolicy << endl;
+ kdDebug() << " m_windowStatusPolicy: " << m_windowStatusPolicy << endl;
kdDebug() << " m_windowFocusPolicy: " << m_windowFocusPolicy << endl;
kdDebug() << " m_windowMovePolicy: " << m_windowMovePolicy << endl;
kdDebug() << " m_windowResizePolicy: " << m_windowResizePolicy << endl;
@@ -121,7 +121,7 @@ static KPerDomainSettings &setup_per_domain_policy(
kdWarning() << "setup_per_domain_policy: domain is empty" << endl;
}
const TQString ldomain = domain.lower();
- PolicyMap::iterator it = d->domainPolicy.tqfind(ldomain);
+ PolicyMap::iterator it = d->domainPolicy.find(ldomain);
if (it == d->domainPolicy.end()) {
// simply copy global domain settings (they should have been initialized
// by this time)
@@ -138,9 +138,9 @@ KHTMLSettings::KJavaScriptAdvice KHTMLSettings::strToAdvice(const TQString& _str
if (!_str)
ret = KJavaScriptDunno;
- if (_str.lower() == TQString::tqfromLatin1("accept"))
+ if (_str.lower() == TQString::fromLatin1("accept"))
ret = KJavaScriptAccept;
- else if (_str.lower() == TQString::tqfromLatin1("reject"))
+ else if (_str.lower() == TQString::fromLatin1("reject"))
ret = KJavaScriptReject;
return ret;
@@ -161,7 +161,7 @@ void KHTMLSettings::splitDomainAdvice(const TQString& configStr, TQString &domai
KJavaScriptAdvice &javaAdvice, KJavaScriptAdvice& javaScriptAdvice)
{
TQString tmp(configStr);
- int splitIndex = tmp.tqfind(':');
+ int splitIndex = tmp.find(':');
if ( splitIndex == -1)
{
domain = configStr.lower();
@@ -172,7 +172,7 @@ void KHTMLSettings::splitDomainAdvice(const TQString& configStr, TQString &domai
{
domain = tmp.left(splitIndex).lower();
TQString adviceString = tmp.mid( splitIndex+1, tmp.length() );
- int splitIndex2 = adviceString.tqfind( ':' );
+ int splitIndex2 = adviceString.find( ':' );
if( splitIndex2 == -1 ) {
// Java advice only
javaAdvice = strToAdvice( adviceString );
@@ -189,63 +189,63 @@ void KHTMLSettings::splitDomainAdvice(const TQString& configStr, TQString &domai
void KHTMLSettings::readDomainSettings(KConfig *config, bool reset,
bool global, KPerDomainSettings &pd_settings) {
TQString jsPrefix = global ? TQString::null
- : TQString::tqfromLatin1("javascript.");
+ : TQString::fromLatin1("javascript.");
TQString javaPrefix = global ? TQString::null
- : TQString::tqfromLatin1("java.");
+ : TQString::fromLatin1("java.");
TQString pluginsPrefix = global ? TQString::null
- : TQString::tqfromLatin1("plugins.");
+ : TQString::fromLatin1("plugins.");
// The setting for Java
- TQString key = javaPrefix + TQString::tqfromLatin1("EnableJava");
+ TQString key = javaPrefix + TQString::fromLatin1("EnableJava");
if ( (global && reset) || config->hasKey( key ) )
pd_settings.m_bEnableJava = config->readBoolEntry( key, false );
else if ( !global )
pd_settings.m_bEnableJava = d->global.m_bEnableJava;
// The setting for Plugins
- key = pluginsPrefix + TQString::tqfromLatin1("EnablePlugins");
+ key = pluginsPrefix + TQString::fromLatin1("EnablePlugins");
if ( (global && reset) || config->hasKey( key ) )
pd_settings.m_bEnablePlugins = config->readBoolEntry( key, true );
else if ( !global )
pd_settings.m_bEnablePlugins = d->global.m_bEnablePlugins;
// The setting for JavaScript
- key = jsPrefix + TQString::tqfromLatin1("EnableJavaScript");
+ key = jsPrefix + TQString::fromLatin1("EnableJavaScript");
if ( (global && reset) || config->hasKey( key ) )
pd_settings.m_bEnableJavaScript = config->readBoolEntry( key, true );
else if ( !global )
pd_settings.m_bEnableJavaScript = d->global.m_bEnableJavaScript;
// window property policies
- key = jsPrefix + TQString::tqfromLatin1("WindowOpenPolicy");
+ key = jsPrefix + TQString::fromLatin1("WindowOpenPolicy");
if ( (global && reset) || config->hasKey( key ) )
pd_settings.m_windowOpenPolicy = (KJSWindowOpenPolicy)
config->readUnsignedNumEntry( key, KJSWindowOpenSmart );
else if ( !global )
pd_settings.m_windowOpenPolicy = d->global.m_windowOpenPolicy;
- key = jsPrefix + TQString::tqfromLatin1("WindowMovePolicy");
+ key = jsPrefix + TQString::fromLatin1("WindowMovePolicy");
if ( (global && reset) || config->hasKey( key ) )
pd_settings.m_windowMovePolicy = (KJSWindowMovePolicy)
config->readUnsignedNumEntry( key, KJSWindowMoveAllow );
else if ( !global )
pd_settings.m_windowMovePolicy = d->global.m_windowMovePolicy;
- key = jsPrefix + TQString::tqfromLatin1("WindowResizePolicy");
+ key = jsPrefix + TQString::fromLatin1("WindowResizePolicy");
if ( (global && reset) || config->hasKey( key ) )
pd_settings.m_windowResizePolicy = (KJSWindowResizePolicy)
config->readUnsignedNumEntry( key, KJSWindowResizeAllow );
else if ( !global )
pd_settings.m_windowResizePolicy = d->global.m_windowResizePolicy;
- key = jsPrefix + TQString::tqfromLatin1("WindowtqStatusPolicy");
+ key = jsPrefix + TQString::fromLatin1("WindowStatusPolicy");
if ( (global && reset) || config->hasKey( key ) )
- pd_settings.m_windowtqStatusPolicy = (KJSWindowtqStatusPolicy)
- config->readUnsignedNumEntry( key, KJSWindowtqStatusAllow );
+ pd_settings.m_windowStatusPolicy = (KJSWindowStatusPolicy)
+ config->readUnsignedNumEntry( key, KJSWindowStatusAllow );
else if ( !global )
- pd_settings.m_windowtqStatusPolicy = d->global.m_windowtqStatusPolicy;
+ pd_settings.m_windowStatusPolicy = d->global.m_windowStatusPolicy;
- key = jsPrefix + TQString::tqfromLatin1("WindowFocusPolicy");
+ key = jsPrefix + TQString::fromLatin1("WindowFocusPolicy");
if ( (global && reset) || config->hasKey( key ) )
pd_settings.m_windowFocusPolicy = (KJSWindowFocusPolicy)
config->readUnsignedNumEntry( key, KJSWindowFocusAllow );
@@ -508,7 +508,7 @@ void KHTMLSettings::init( KConfig * config, bool reset )
const TQStringList::ConstIterator itEnd = dl.end();
for (; it != itEnd; ++it) {
const TQString domain = (*it).lower();
- TQMap<TQString,int>::Iterator pos = domainList.tqfind(domain);
+ TQMap<TQString,int>::Iterator pos = domainList.find(domain);
if (pos == notfound) domainList.insert(domain,0);
}/*next it*/
}
@@ -611,7 +611,7 @@ void KHTMLSettings::init( KConfig * config, bool reset )
{
TQCString javaPolicy = adviceToStr( it.data() );
TQCString javaScriptPolicy = adviceToStr( KJavaScriptDunno );
- domainConfig.append(TQString::tqfromLatin1("%1:%2:%3").arg(it.key()).arg(javaPolicy).arg(javaScriptPolicy));
+ domainConfig.append(TQString::fromLatin1("%1:%2:%3").arg(it.key()).arg(javaPolicy).arg(javaScriptPolicy));
}
config->writeEntry( "JavaDomainSettings", domainConfig );
}
@@ -624,7 +624,7 @@ void KHTMLSettings::init( KConfig * config, bool reset )
{
TQCString javaPolicy = adviceToStr( KJavaScriptDunno );
TQCString javaScriptPolicy = adviceToStr( it.data() );
- domainConfig.append(TQString::tqfromLatin1("%1:%2:%3").arg(it.key()).arg(javaPolicy).arg(javaScriptPolicy));
+ domainConfig.append(TQString::fromLatin1("%1:%2:%3").arg(it.key()).arg(javaPolicy).arg(javaScriptPolicy));
}
config->writeEntry( "ECMADomainSettings", domainConfig );
}
@@ -656,7 +656,7 @@ static const KPerDomainSettings &lookup_hostname_policy(
const PolicyMap::const_iterator notfound = d->domainPolicy.end();
// First check whether there is a perfect match.
- PolicyMap::const_iterator it = d->domainPolicy.tqfind(hostname);
+ PolicyMap::const_iterator it = d->domainPolicy.find(hostname);
if( it != notfound ) {
#ifdef DEBUG_SETTINGS
kdDebug() << "perfect match" << endl;
@@ -670,9 +670,9 @@ static const KPerDomainSettings &lookup_hostname_policy(
// there's no dots left.
TQString host_part = hostname;
int dot_idx = -1;
- while( (dot_idx = host_part.tqfind(TQChar('.'))) >= 0 ) {
+ while( (dot_idx = host_part.find(TQChar('.'))) >= 0 ) {
host_part.remove(0,dot_idx);
- it = d->domainPolicy.tqfind(host_part);
+ it = d->domainPolicy.find(host_part);
Q_ASSERT(notfound == d->domainPolicy.end());
if( it != notfound ) {
#ifdef DEBUG_SETTINGS
@@ -822,9 +822,9 @@ KHTMLSettings::KJSWindowResizePolicy KHTMLSettings::windowResizePolicy(
return lookup_hostname_policy(d,hostname.lower()).m_windowResizePolicy;
}
-KHTMLSettings::KJSWindowtqStatusPolicy KHTMLSettings::windowtqStatusPolicy(
+KHTMLSettings::KJSWindowStatusPolicy KHTMLSettings::windowStatusPolicy(
const TQString& hostname) const {
- return lookup_hostname_policy(d,hostname.lower()).m_windowtqStatusPolicy;
+ return lookup_hostname_policy(d,hostname.lower()).m_windowStatusPolicy;
}
KHTMLSettings::KJSWindowFocusPolicy KHTMLSettings::windowFocusPolicy(
@@ -887,8 +887,8 @@ const TQString &KHTMLSettings::availableFamilies()
const TQStringList::Iterator fEnd = families.end();
for ( ; f != fEnd; ++f ) {
- (*f).tqreplace( foundryExp, "");
- if (!s.tqcontains(*f))
+ (*f).replace( foundryExp, "");
+ if (!s.contains(*f))
s << *f;
}
s.sort();