diff options
Diffstat (limited to 'kcontrol/performance')
-rw-r--r-- | kcontrol/performance/Makefile.am | 20 | ||||
-rw-r--r-- | kcontrol/performance/kcmkonqyperformance.desktop | 207 | ||||
-rw-r--r-- | kcontrol/performance/kcmperformance.cpp | 126 | ||||
-rw-r--r-- | kcontrol/performance/kcmperformance.desktop | 215 | ||||
-rw-r--r-- | kcontrol/performance/kcmperformance.h | 61 | ||||
-rw-r--r-- | kcontrol/performance/konqueror.cpp | 147 | ||||
-rw-r--r-- | kcontrol/performance/konqueror.h | 46 | ||||
-rw-r--r-- | kcontrol/performance/konqueror_ui.ui | 155 | ||||
-rw-r--r-- | kcontrol/performance/system.cpp | 80 | ||||
-rw-r--r-- | kcontrol/performance/system.h | 44 | ||||
-rw-r--r-- | kcontrol/performance/system_ui.ui | 69 |
11 files changed, 1170 insertions, 0 deletions
diff --git a/kcontrol/performance/Makefile.am b/kcontrol/performance/Makefile.am new file mode 100644 index 000000000..5ae59d89e --- /dev/null +++ b/kcontrol/performance/Makefile.am @@ -0,0 +1,20 @@ +kde_module_LTLIBRARIES = kcm_performance.la + +kcm_performance_la_SOURCES = kcmperformance.cpp konqueror.cpp konqueror_ui.ui system.cpp system_ui.ui +kcm_performance_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined +kcm_performance_la_LIBADD = -lkdeui +AM_CPPFLAGS= $(all_includes) + +METASOURCES = AUTO + +noinst_HEADERS = konqueror.h system.h + +messages: rc.cpp + $(XGETTEXT) *.cpp -o $(podir)/kcmperformance.pot + +xdg_apps_DATA = kcmperformance.desktop + +kcmperformance_hidden_data_DATA = kcmkonqyperformance.desktop +kcmperformance_hidden_datadir = $(kde_appsdir)/.hidden + +EXTRA_DIST = $(xdg_apps_DATA) diff --git a/kcontrol/performance/kcmkonqyperformance.desktop b/kcontrol/performance/kcmkonqyperformance.desktop new file mode 100644 index 000000000..32ca6873e --- /dev/null +++ b/kcontrol/performance/kcmkonqyperformance.desktop @@ -0,0 +1,207 @@ +[Desktop Entry] +Icon=launch +Type=Application +Exec=kcmshell kcmkonqyperformance + + +X-KDE-Library=performance +X-KDE-FactoryName=konqueror +X-KDE-ParentApp=kcontrol + +Name=Performance +Name[af]=Werkverrigting +Name[ar]=الأداء +Name[az]=Keyfiyyət +Name[be]=Хуткасць працы +Name[bg]=Производителност +Name[bn]=কার্যকারীতা +Name[bs]=Performanse +Name[ca]=Rendiment +Name[cs]=Výkon +Name[csb]=Spòrosc +Name[cy]=Perfformiad +Name[da]=Ydelse +Name[de]=Leistung +Name[el]=Απόδοση +Name[eo]=Potenco +Name[es]=Rendimiento +Name[et]=Jõudlus +Name[eu]=Performantzia +Name[fa]=کارایی +Name[fi]=Suorituskyky +Name[fy]=Prestaasje +Name[ga]=Feidhmiúchán +Name[gl]=Rendemento +Name[he]=ביצועים +Name[hi]=परफार्मेंस +Name[hr]=Performanse +Name[hu]=Teljesítmény +Name[is]=Afköst +Name[it]=Prestazioni +Name[ja]=パフォーマンス +Name[ka]=წარმადობა +Name[kk]=Жылдамдылығы +Name[km]=ដំណើរការ +Name[ko]=성능 +Name[lt]=Veikimo sparta +Name[lv]=Veiktspēja +Name[mk]=Перформанси +Name[mn]=Чадал +Name[ms]=Prestasi +Name[mt]=Effiċjenza +Name[nb]=Ytelse +Name[nds]=Leisten +Name[ne]=सम्पादन +Name[nl]=Prestatie +Name[nn]=Yting +Name[pa]=ਪਰਦਰਸ਼ਨ +Name[pl]=Wydajność +Name[pt_BR]=Perfomance +Name[ro]=Performanță +Name[ru]=Быстродействие +Name[rw]=Ugukora neza +Name[se]=Buktu +Name[sk]=Výkon +Name[sl]=Zmogljivost +Name[sr]=Перформансе +Name[sr@Latn]=Performanse +Name[sv]=Prestanda +Name[ta]=செயல்திறன் +Name[tg]=Амалкард +Name[th]=ประสิทธิภาพ +Name[tr]=Performans +Name[tt]=Citezlek +Name[uk]=Швидкодія +Name[uz]=Unumdorlik +Name[uz@cyrillic]=Унумдорлик +Name[vi]=Hiệu năng +Name[wa]=Fé kine +Name[zh_CN]=性能 +Name[zh_TW]=偏好設定 + +Comment=Configure settings that can improve Konqueror performance +Comment[af]=Stel instellings op wat Konqueror se werkverrigting kan verhoog +Comment[ar]=إعداد تعيينات تحسّن إداء Konqueror +Comment[be]=Настаўленне параметраў, якія могуць павялічыць хуткасць працы Konqueror +Comment[bg]=Настройване производителността на браузъра +Comment[bn]=কনকরার-এর কার্যকারীতা বর্ধন করতে পারে এমন সব সেটিংস কনফিগার করুন +Comment[bs]=Postavke koje mogu unaprijediti performanse Konquerora +Comment[ca]=Configura les opcions per a millorar el rendiment del Konqueror +Comment[cs]=Zde můžete vylepšit výkon aplikace Konqueror +Comment[csb]=Kònfigùracëjô nastôwów Konquerora jaczé nają cësk na spòrosc +Comment[cy]=Ffurfweddu gosodiadau sy'n gallu gwella perfformiad Konqueror +Comment[da]=Indstil opsætning for at forbedre Konquerors ydelse +Comment[de]=Einstellungen vornehmen, die Konquerors Leistungsfähigkeit erhöhen können +Comment[el]=Αλλάξτε ρυθμίσεις που μπορεί να βελτιώσουν την απόδοση του Konqueror +Comment[eo]=Agordo de Konkeranto por plibonigi la potencon +Comment[es]=Configuraciones que pueden mejorar el rendimiento de Konqueror +Comment[et]=Siin saad seadistada, kuidas Konqueror kõigega paremini toime tuleks +Comment[eu]=Konfiguratu Konquerorren performantzia hobe dezaketen ezarpenak +Comment[fa]=پیکربندی تنظیماتی که کارایی Konqueror را بهبود میبخشد. +Comment[fi]=Muokkaa Konquerorin suorituskykyyn liittyviä asetuksia +Comment[fr]=Amélioration des performances de Konqueror +Comment[fy]=Hjir kinne jo ynstellings kieze die de prestaasje fan Konqueror ferbetterje +Comment[ga]=Cumraigh socruithe a chuirfidh feabhas ar fheidhmiúchán Konqueror +Comment[gl]=Configurar as opcións que poden mellorar o rendemento de Konqueror +Comment[he]=הגדר הגדרות העשויות לשפר את ביצועי Konqueror +Comment[hi]=विन्यास कॉन्फ़िगर करें ताकि कॉन्करर का कार्य बेहतर हो सके +Comment[hr]=Konfiguriranje postavki koje mogu poboljšati performanse Konquerora +Comment[hu]=A Konqueror böngésző teljesítményét befolyásoló paraméterek beállítása +Comment[is]=Stillingar Konqueror er varða afköst +Comment[it]=Configura le impostazioni che possono migliorare le prestazioni di Konqueror +Comment[ja]=Konqueror のパフォーマンスを改善 +Comment[ka]=Konqueror-ის სისწრაფეზე მოქმედი პარამეტრების კონფიგურაცია +Comment[kk]=Konqueror жылдамдығын арттыратын параметрлерді баптау +Comment[km]=កំណត់រចនាសម្ព័ន្ធការកំណត់ ដែលអាចបង្កើនដំណើរការ Konqueror +Comment[ko]=Konqueror 성능 향상 설정 +Comment[lt]=Konfigūruokite nustatymus, kurie gali įtakoti Konqueror veikimo spartą +Comment[lv]=Šeit Jūs varat konfigurēt Iekarotāja parametrus, kas ietekmē tā veiktspēju +Comment[mk]=Конфигурирајте ги поставувањата што може да ги\nподобрат перформансите на Konqueror +Comment[mn]=Конкюрор вэб-Хөтөчийн самбар сайжруулалтыг тохируулах +Comment[ms]=Konfigur seting yang meningkatkan prestasi Konqueror +Comment[mt]=Ikkonfigura setings li jistgħu itejbu l-veloċità ta' Konqueror +Comment[nb]=Tilpass innstillinger som kan forbedre Konquerors ytelse +Comment[nds]=Mit disse Instellen kannst Du de Leisten vun Konqueror verbetern +Comment[ne]=कन्क्वेरर सम्पादन सुधार गर्न सक्ने सेटिङ कन्फिगर गर्नुहोस् +Comment[nl]=Hier kunt u instellingen kiezen die de prestaties van Konqueror verbeteren +Comment[nn]=Innstillingar som kan forbetra ytinga til Konqueror +Comment[pa]=ਸੰਰਚਨਾ ਸੈਟ ਕਰੋ, ਜਿਸ ਨਾਲ ਕੋਨਕਿਉਰਰ ਦਾ ਪਰਦਰਸ਼ਨ ਵਧਿਆ ਹੋ ਸਕੇ +Comment[pl]=Konfiguracja ustawień Konquerora mających wpływ na wydajność +Comment[pt]=Configuração das opções que podem aumentar a performance do Konqueror +Comment[pt_BR]=Configurações que podem aumentar a performance do Konqueror +Comment[ro]=Configurează setări care pot îmbunătăți performanța Konqueror +Comment[ru]=Настройка параметров, которые влияют на быстродействие Konqueror +Comment[rw]=Kuboneza amagenamiterere ashobora kuvugurura imikorere ya Konqueror +Comment[se]=Heivet Konqueror:a vai das šaddá buoret buvttu +Comment[sk]=Nastavenie, ktoré môže vylepšiť výkon prehliadača Konqueror +Comment[sl]=Nastavitve, ki izboljšajo delovanje Konquerorja +Comment[sr]=Подешавање поставки које могу да побољшају Konqueror-ове перформансе +Comment[sr@Latn]=Podešavanje postavki koje mogu da poboljšaju Konqueror-ove performanse +Comment[sv]=Anpassa inställningar som kan förbättra Konquerors prestanda +Comment[ta]=கான்கொரர் செயல்திறனை அதிகப்படுத்த அமைப்புகளை வடிவமை +Comment[tg]= Танзимоте ки метавонанд амалкарди Konqueror-ро беҳбуд бахшанд, танзим кунед +Comment[th]=ปรับแต่งตั้งค่าที่จะช่วยให้คอนเควอร์เรอร์มีประสิทธิภาพดีขึ้น +Comment[tr]=Konqueror'un performansını artıracak ayarlamaları yap +Comment[tt]=Konqueror citezlegen arttıra ala torğan köyläwlär +Comment[uk]=Тут можна налаштувати швидкодію Konqueror +Comment[uz]=Konqueror unumdorligini oshirishi mumkin boʻlgan moslamalarni moslash +Comment[uz@cyrillic]=Konqueror унумдорлигини ошириши мумкин бўлган мосламаларни мослаш +Comment[vi]=Các thiết lập nâng cao khả năng của Konqueror +Comment[wa]=Tchuzes d' apontiaedje ki plèt improuver Konqueror +Comment[zh_CN]=配置提高 Konqueror 性能的设置 +Comment[zh_TW]=可增進 Konqueror 效能的設定 + +Keywords=konqueror,reuse,preloading +Keywords[ar]=كونكيورر,اعادة استخدام,تحميل تمهيدي +Keywords[az]=konqueror,yenidən işlətmə,önyükləmə +Keywords[be]=Папярэдняя загрузка,konqueror,reuse,preloading +Keywords[bg]=предварително, зареждане, използване, повторно, konqueror, reuse, preloading +Keywords[ca]=konqueror,torna a emprar,carrega prèviament +Keywords[cs]=konqueror,využití,preload +Keywords[csb]=konqueror,brëkòwanié znowa,wstãpné wczëtanié +Keywords[cy]=konqueror,ailddefnyddio,cynlwytho +Keywords[da]=konqueror,genbrug,forudindlæsning +Keywords[de]=konqueror,wiederverwenden +Keywords[el]=konqueror,επαναχρησιμοποίηση,προφόρτωση +Keywords[eo]=konkeranto,antaŭŝarĝi +Keywords[et]=konqueror,taaskasutamine,eellaadimine +Keywords[eu]=konqueror,berrerabili,prekargatu +Keywords[fa]=konqueror، استفادۀ مجدد، پیشبارگذاری +Keywords[fi]=konqueror,reuse,esilataus +Keywords[fr]=konqueror,réutilisation,préchargement +Keywords[fy]=konqueror,hergebûk,foarútlade +Keywords[ga]=konqueror,athúsáid,réamhluchtú +Keywords[gl]=konqueror,reuso,precarga +Keywords[he]=konqueror,שימוש חוזר,טעינה מוקדמת, reuse,preloading,מחדש, שוב +Keywords[hi]=कॉन्करर,फिर से उपयोग,प्रि-लोडिंग +Keywords[hr]=konqueror,reuse,preloading,ponovna upotreba,prethodno učitavanje +Keywords[hu]=konqueror,ujrafelhasználás,előtöltés +Keywords[it]=konqueror,riutilizzo,precaricamento,prestazioni,preloading +Keywords[ja]=konqueror,再使用,事前読み込み +Keywords[km]=konqueror,ប្រើឡើងវិញ,ប្រុងប្រៀបផ្ទុក +Keywords[lv]=iekarotājs,reuse,priekšielāde +Keywords[mk]=konqueror,reuse,preloading,користи,повторно користи,предвчитување +Keywords[mn]=Конкюрор,reuse,preloading +Keywords[nb]=konqueror,gjenbruk,forhåndslasting +Keywords[nds]=Konqueror,wedder bruken,vörladen +Keywords[ne]=विजय/प्राप्ति, पुन: प्रयोग, पूर्व-लोडिङ +Keywords[nl]=konqueror,hergebruik,preloading +Keywords[nn]=Konqueror,gjenbruk,førehandslasting +Keywords[pa]=konqueror,reuse,preloading, ਕੋਨਕਿਉਰਰ, ਮੁੜ ਲੋਡ +Keywords[pl]=konqueror,ponowne użycie,wstępne wczytywanie +Keywords[pt]=konqueror,reutilização,pré-carregamento +Keywords[pt_BR]=konqueror,reuso,pré-carregamento +Keywords[ro]=konqueror,reutilizare,preîncărcare +Keywords[rw]=Konqueror,kongera gukoresha,gutangizambere +Keywords[sl]=konqueror,recikliranje,prednalaganje +Keywords[sr]=konqueror,reuse,preloading,поново коришћење,преучитавање +Keywords[sr@Latn]=konqueror,reuse,preloading,ponovo korišćenje,preučitavanje +Keywords[sv]=konqueror,återanvändning,förladdning +Keywords[ta]=கான்கொரர்,திரும்ப பயன்படுத்து,முன்ஏற்றுதல் +Keywords[th]=คอนเควอร์เรอร์,นำมาใช้ใหม่,เตรียมโหลดไว้ก่อน +Keywords[tr]=konqueror,yeniden kullanım,ön yükleme +Keywords[uk]=konqueror,повторне використання,попереднє завантаження +Keywords[vi]=konqueror,tái sử dụng,tải về sẵn trước +Keywords[zh_CN]=konqueror,reuse,preloading,再利用,预加载 +Keywords[zh_TW]=konqueror,reuse,preloading,重用,預先載入 + diff --git a/kcontrol/performance/kcmperformance.cpp b/kcontrol/performance/kcmperformance.cpp new file mode 100644 index 000000000..be4b57387 --- /dev/null +++ b/kcontrol/performance/kcmperformance.cpp @@ -0,0 +1,126 @@ +/* + * Copyright (c) 2003 Lubos Lunak <l.lunak@kde.org> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#include <qlayout.h> +#include <qtabwidget.h> + +#include <klocale.h> +#include <kdialog.h> + +#include "kcmperformance.h" +#include "konqueror.h" +#include "system.h" + +extern "C" +{ + KDE_EXPORT KCModule* create_performance( QWidget* parent_P, const char* name_P ) + { + return new KCMPerformance::Config( parent_P, name_P ); + } + + KDE_EXPORT KCModule* create_konqueror( QWidget* parent_P, const char* name_P ) + { + return new KCMPerformance::KonquerorConfig( parent_P, name_P ); + } +} + +namespace KCMPerformance +{ + +Config::Config( QWidget* parent_P, const char* ) + : KCModule( parent_P, "kcmperformance" ) + { + setQuickHelp( i18n( "<h1>KDE Performance</h1>" + " You can configure settings that improve KDE performance here." )); + + QVBoxLayout *topLayout = new QVBoxLayout( this ); + QTabWidget* tabs = new QTabWidget( this ); + konqueror_widget = new Konqueror( tabs ); + konqueror_widget->layout()->setMargin( KDialog::marginHint() ); + connect( konqueror_widget, SIGNAL( changed()), SLOT( changed())); + tabs->addTab( konqueror_widget, i18n( "Konqueror" )); + system_widget = new SystemWidget( tabs ); + system_widget->layout()->setMargin( KDialog::marginHint() ); + connect( system_widget, SIGNAL( changed()), SLOT( changed())); + tabs->addTab( system_widget, i18n( "System" )); + topLayout->add( tabs ); + load(); + } + +void Config::load() + { + load( false ); + } + +void Config::load( bool useDefaults) + { + konqueror_widget->load( useDefaults ); + system_widget->load( useDefaults ); + emit changed( useDefaults ); + } + +void Config::save() + { + konqueror_widget->save(); + system_widget->save(); + } + +void Config::defaults() + { + load( true ); + } + +KonquerorConfig::KonquerorConfig( QWidget* parent_P, const char* ) + : KCModule( parent_P, "kcmperformance" ) + { + setQuickHelp( i18n( "<h1>Konqueror Performance</h1>" + " You can configure several settings that improve Konqueror performance here." + " These include options for reusing already running instances" + " and for keeping instances preloaded." )); + + QVBoxLayout *topLayout = new QVBoxLayout( this ); + widget = new Konqueror( this ); + connect( widget, SIGNAL( changed()), SLOT( changed())); + topLayout->add( widget ); + load(); + } + +void KonquerorConfig::load() + { + load( false ); + } + +void KonquerorConfig::load(bool useDefaults) + { + widget->load( useDefaults ); + emit changed( useDefaults ); + } + +void KonquerorConfig::save() + { + widget->save(); + } + +void KonquerorConfig::defaults() + { + load( true ); + } + +} // namespace + +#include "kcmperformance.moc" diff --git a/kcontrol/performance/kcmperformance.desktop b/kcontrol/performance/kcmperformance.desktop new file mode 100644 index 000000000..bcc60face --- /dev/null +++ b/kcontrol/performance/kcmperformance.desktop @@ -0,0 +1,215 @@ +[Desktop Entry] +Icon=launch +Type=Application +Exec=kcmshell kcmperformance + + +X-KDE-Library=performance +X-KDE-FactoryName=performance +X-KDE-ParentApp=kcontrol + +Name=KDE Performance +Name[af]=KDE Werkverrigting +Name[ar]=إداء KDE +Name[az]=KDE Keyfiyyəti +Name[be]=Хуткасць працы KDE +Name[bg]=Производителност +Name[bn]=কে.ডি.ই. কার্যকারীতা +Name[bs]=KDE performanse +Name[ca]=Rendiment del KDE +Name[cs]=Výkon KDE +Name[csb]=Spòrosc KDE +Name[cy]=Perfformiad KDE +Name[da]=KDE's ydelse +Name[de]=KDE-Leistung +Name[el]=Απόδοση του KDE +Name[eo]=KDEa potenco +Name[es]=Rendimiento de KDE +Name[et]=KDE jõudlus +Name[eu]=KDEren performantzia +Name[fa]=کارایی KDE +Name[fi]=Suorituskyky +Name[fr]=Performance de KDE +Name[fy]=KDE-prestaasjes +Name[ga]=Feidhmiúchán KDE +Name[gl]=Rendemento de KDE +Name[he]=ביצועי KDE +Name[hi]=केडीई परफार्मेंस +Name[hr]=KDE performanse +Name[hu]=Teljesítményhangolás +Name[is]=Afkastastillingar KDE +Name[it]=Prestazioni di KDE +Name[ja]=KDE パフォーマンス +Name[ka]=KDE-ს წარმადობა +Name[kk]=KDE жылдамдығы +Name[km]=ដំណើរការរបស់ KDE +Name[ko]=KDE 성능 +Name[lt]=KDE našumas +Name[lv]=KDE Veiktspēja +Name[mk]=Перформанси на KDE +Name[mn]=КДЭ-Удирдлагын самбар +Name[ms]=Prestasi KDE +Name[mt]=Effiċjenza KDE +Name[nb]=KDE-ytelse +Name[nds]=KDE-Leisten +Name[ne]=KDE सम्पादन +Name[nl]=KDE-prestaties +Name[nn]=KDE-yting +Name[pa]=KDE ਪਰਦਰਸ਼ਨ +Name[pl]=Wydajność KDE +Name[pt]=Performance do KDE +Name[pt_BR]=Performance do KDE +Name[ro]=Performanță KDE +Name[ru]=Быстродействие +Name[rw]=Imikorere ya KDE +Name[se]=KDE-buktu +Name[sk]=Výkon KDE +Name[sl]=Zmogljivost KDE +Name[sr]=KDE перформансе +Name[sr@Latn]=KDE performanse +Name[sv]=KDE-prestanda +Name[ta]=KDE செயல்திறன் +Name[tg]=Амалкарди KDE +Name[th]=ประสิทธิภาพของ KDE +Name[tr]=KDE Performansı +Name[tt]=KDE Citezlege +Name[uk]=Швидкодія KDE +Name[uz]=KDE unumdorligi +Name[uz@cyrillic]=KDE унумдорлиги +Name[vi]=Hiệu năng KDE +Name[wa]=Improuver KDE +Name[zh_CN]=KDE 性能 +Name[zh_TW]=KDE 效能 + +Comment=Configure settings that can improve KDE performance +Comment[af]=Stel instellings op wat KDE se werkverrigting kan verhoog +Comment[ar]=إعداد تعيينات تحسّن إداء KDE +Comment[be]=Настаўленне параметраў, якія могуць павялічыць хуткасць працы KDE +Comment[bg]=Настройване производителността на системата +Comment[bn]=কে.ডি.ই-এর কার্যকারীতা বর্ধন করতে পারে এমন সব সেটিংস কনফিগার করুন +Comment[bs]=Postavke koje mogu unaprijediti performanse KDEa +Comment[ca]=Configura les opcions per a millorar el rendiment del KDE +Comment[cs]=Nastavení vylepšující výkon KDE +Comment[csb]=Kònfigùracëjô nastôwów Konquerora jaczé nają cësk na spòrosc KDE +Comment[cy]=Ffurfweddu gosodiadau sy'n gallu gwella perfformiad KDE +Comment[da]=Indstil opsætning for at forbedre KDE's ydelse +Comment[de]=Einstellungen vornehmen, die die Leistungsfähigkeit von KDE erhöhen können +Comment[el]=Αλλάξτε ρυθμίσεις που μπορεί να βελτιώσουν την απόδοση του KDE +Comment[eo]=Agordo de plibonigo de la KDEa potenco +Comment[es]=Configura opciones que pueden mejorar el rendimiento de KDE +Comment[et]=Siin saad seadistada, kuidas KDE kõigega paremini toime tuleks +Comment[eu]=Konfiguratu Konquerorren performantzia hobe dezaketen ezarpenak +Comment[fa]=پیکربندی تنظیماتی که کارایی KDE را بهبود میبخشد +Comment[fi]=Muokkaa KDE:n suorituskykyyn liittyviä asetuksia +Comment[fr]=Configuration de paramètres qui peuvent améliorer les performances de KDE +Comment[fy]=Hjir kinne jo ynstellings kiezen die de prestaasje fan KDE kinne ferbetterje +Comment[ga]=Cumraigh socruithe a chuirfidh feabhas ar fheidhmiúchán KDE +Comment[gl]=Configuración das opcións que poden mellorar o rendemento de KDE +Comment[he]=הגדר הגדרות שעשויות לשפר את ביצועי KDE +Comment[hi]=विन्यास कॉन्फ़िगर करें ताकि केडीई का कार्य बेहतर हो सके +Comment[hr]=Konfiguriranje postavi koje mogu poboljšati performanse KDE-a +Comment[hu]=A KDE teljesítményét befolyásoló paraméterek beállítása +Comment[is]=Stillingar sem varða afköst KDE +Comment[it]=Configura le impostazioni che possono migliorare le prestazioni di KDE +Comment[ja]=KDE のパフォーマンスを改善 +Comment[ka]=KDE-ს სისწრაფეზე მოქმედი პარამეტრების კონფიგურაცია +Comment[kk]=KDE жылдамдығын арттыратын параметрлерді баптау +Comment[km]=កំណត់រចនាសម្ព័ន្ធការកំណត់ដែលអាចបង្កើនដំណើរការរបស់ KDE +Comment[ko]=KDE 성능 향상 설정 +Comment[lt]=Konfigūruoti nustatymus, kurie gali pagerinti KDE veikimo spartą +Comment[lv]=Konfigurē parametrus, kas ietekmē Iekarotāja veiktspēju +Comment[mk]=Конфигурирајте ги поставувањата што може да ги подобрат перформансите на KDE +Comment[mn]=Comment=КДЭ чадал сайжруулалтыг тохируулах +Comment[ms]=Konfigur seting yang boleh meningkatkan prestasi KDE +Comment[mt]=Ikkonfigura setings li jistgħu itejbu l-veloċità ta' KDE +Comment[nb]=Innstillinger som kan forbedre KDEs ytelse +Comment[nds]=Mit disse Instellen kannst Du de Leisten vun KDE verbetern +Comment[ne]=KDE सम्पादन सुधार गर्न सक्ने सेटिङ कन्फिगर गर्नुहोस् +Comment[nl]=Hier kunt u instellingen kiezen die de prestaties van KDE kunnen verbeteren +Comment[nn]=Innstillingar som kan forbetra ytinga til KDE +Comment[pa]=ਸੰਰਚਨਾ ਸੈਟ ਕਰੋ, ਜਿਸ ਨਾਲ KDE ਦਾ ਪਰਦਰਸ਼ਨ ਵਧਿਆ ਹੋ ਸਕਦਾ ਹੈ +Comment[pl]=Konfiguracja ustawień, które mogą mieć wpływ na wydajność KDE +Comment[pt]=Configura as opções que podem aumentar a performance do KDE +Comment[pt_BR]=Configurações que podem aumentar a performance do KDE +Comment[ro]=Configurează setări care pot îmbunătăți performanța Konqueror +Comment[ru]=Настройка параметров, которые могут повлиять на быстродействие KDE +Comment[rw]=Kuboneza amagenamiterere ashobora kuvugurura imikorere ya KDE +Comment[se]=Heivehusat mat buoridit KDE:a buvttu +Comment[sk]=Nastavenie, ktoré môže vylepšiť výkon KDE +Comment[sl]=Nastavite možnosti za pohitritev KDE +Comment[sr]=Подешавање поставки које могу да побољшају перформансе KDE-а +Comment[sr@Latn]=Podešavanje postavki koje mogu da poboljšaju performanse KDE-a +Comment[sv]=Anpassa inställningar som kan förbättra KDE:s prestanda +Comment[ta]=KDE செயல்திறனை அதிகப்படுத்தும் அமைப்புகளை அமை +Comment[tg]= Танзимоте ки метавонанд амалкарди KDE-ро беҳбуд бахшанд, танзим кунед +Comment[th]=ปรับแต่งตั้งค่าที่จะช่วยปรับประสิทธิภาพของ KDE +Comment[tr]=KDE'nin performansını artıracak ayarlamaları yap +Comment[tt]=KDE citezlegen arttıra ala torğan köyläwlär +Comment[uk]=Налаштування параметрів для покращання швидкодії KDE +Comment[uz]=KDE unumdorligini oshirishi mumkin boʻlgan moslamalarni moslash +Comment[uz@cyrillic]=KDE унумдорлигини ошириши мумкин бўлган мосламаларни мослаш +Comment[vi]=Các thiết lập nâng cao khả năng của Konqueror +Comment[wa]=Tchuzes d' apontiaedje ki plèt improuver KDE +Comment[zh_CN]=配置提高 KDE 性能的设置 +Comment[zh_TW]=可增進 KDE 效能的設定 + +Keywords=performance,speed,memory,improve +Keywords[ar]=performance,speed,memory,improve,أداء,سرعة,ذاكرة,تحسين +Keywords[be]=Хуткасць працы,Прадукцыйнасць,Хуткасць,Памяць,Палепшыць,Паляпшэнне,performance,speed,memory,improve +Keywords[bg]=производителност, памет, скорост, подобряване, подобрение, performance, speed, memory, improve +Keywords[ca]=rendiment,velocitat,memòria,millora +Keywords[cs]=výkon,rychlost,paměť,zlepšení +Keywords[csb]=spòrosc, chùtkòsc, pamiãc,zlepszenié +Keywords[cy]=perfformiad,cyflymder,cof,gwella +Keywords[da]=ydelse,hastighed,hukommelse,forbedre +Keywords[de]=leistung,geschwindigkeit,speichern,optimieren +Keywords[el]=απόδοση,ταχύτητα,μνήμη,βελτίωση +Keywords[eo]=potenco,rapideco,memoro,plibonigo,plibonigi +Keywords[es]=rendimiento,velocidad,memoria,mejora +Keywords[et]=jõudlus,kiirus,mälu,parandamine +Keywords[eu]=performantzia,abiadura,memoria,hobetu +Keywords[fa]=کارایی، سرعت، حافظه، بهبود +Keywords[fi]=suorituskyky, nopeus, muisti, parannus +Keywords[fr]=performances,vitesse,mémoire,améliorer +Keywords[fy]=fluggens,prestaasjes,ûnthâld,ferbetterje +Keywords[ga]=oibriú,luas,cuimhne,feabhsaigh,feabhsú +Keywords[gl]=rendemento,velocidade,memoria,mellora +Keywords[he]=ביצועים,מהירות,זיכרון,שפר, performance,speed,memory,improve +Keywords[hi]=परफार्मेंस,गति,मेमोरी,बेहतर +Keywords[hr]=performance,speed,memory,improve,performanse,brzina,memorija,unaprijediti +Keywords[hu]=teljesítmény,sebesség,memória,hangolás +Keywords[it]=prestazioni,velocità,memoria,migliora +Keywords[ja]=パフォーマンス,速度,メモリ,改善 +Keywords[km]=ដំណើរការ,ល្បឿន,សតិ,បង្កើន +Keywords[lt]=performance,speed,memory,improve,veikimas,greitis,atmintis,pagerinti +Keywords[lv]=veiktspēja,ātrums,atmiņa,uzlabot +Keywords[mk]=performance,speed,memory,improve,перформанси,брзина,меморија,подобри +Keywords[mn]=чадал,хурд,санах ой,сайжруулалт +Keywords[nb]=ytelse,hastighet,minne,forbedre +Keywords[nds]=Leisten,performance,Gauheit,Spieker,verbetern +Keywords[ne]=सम्पादन,गति, स्मृति, सुधार +Keywords[nl]=snelheid,prestaties,geheugen,verbeteren +Keywords[nn]=yting,fart,minne,forbetra +Keywords[pa]=performance,speed,memory,improve, ਪਰਦਰਸ਼ਨ, ਗਤੀ, ਮੈਮੋਰੀ, ਸੁਧਾਰ +Keywords[pl]=wydajność,szybkość,pamięć,polepszenie +Keywords[pt]=performance,velocidade,memória,melhorar +Keywords[pt_BR]=performance,velocidade,memória,aumento +Keywords[ro]=performanță,viteză,memorie,îmbunătățire +Keywords[rw]=imikorere,umuvuduko,umwanyabubiko,kuvugurura +Keywords[se]=buktu,leahttu,muitu,buoridit +Keywords[sl]=zmogljivost,hitrost,pomnilnik,izboljšanje +Keywords[sr]=performance,speed,memory,improve,перформансе,брзина,меморија,унапређивање,унапреди +Keywords[sr@Latn]=performance,speed,memory,improve,performanse,brzina,memorija,unapređivanje,unapredi +Keywords[sv]=prestanda,hastighet,minne,förbättra +Keywords[ta]=செயல்திறன்,வேகம்,நினைவகம்,முன்னேற்றம் +Keywords[th]=ประสิทธิภาพ,ความเร็ว,หน่วยความจำ,ปรับปรุง +Keywords[tr]=performans,hız,bellek,geliştirme +Keywords[uk]=швидкодія,швидкість,пам'ять,покращення +Keywords[uz]=unumdorlik,tezlik,xotira,oshirish +Keywords[uz@cyrillic]=унумдорлик,тезлик,хотира,ошириш +Keywords[vi]=hiệu năng,tốc độ,bộ nhớ,nâng cao +Keywords[wa]=improuver,fé kine,roedeu,memwere,improuver,amidrer +Keywords[zh_CN]=performance,speed,memory,improve,性能,速度,内存,提高 +Keywords[zh_TW]=performance,speed,memory,improve,效能,速度,記憶體,增進 + +Categories=Qt;KDE;X-KDE-settings-components; diff --git a/kcontrol/performance/kcmperformance.h b/kcontrol/performance/kcmperformance.h new file mode 100644 index 000000000..13c3f9465 --- /dev/null +++ b/kcontrol/performance/kcmperformance.h @@ -0,0 +1,61 @@ +/* + * Copyright (c) 2003 Lubos Lunak <l.lunak@kde.org> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#ifndef _KCM_PERFORMANCE_H +#define _KCM_PERFORMANCE_H + +#include <kcmodule.h> + +namespace KCMPerformance +{ + +class Konqueror; +class SystemWidget; + +class Config + : public KCModule + { + Q_OBJECT + public: + Config( QWidget* parent_P, const char* name_P ); + virtual void load(); + virtual void load( bool useDefaults ); + virtual void save(); + virtual void defaults(); + private: + Konqueror* konqueror_widget; + SystemWidget* system_widget; + }; + +class KonquerorConfig + : public KCModule + { + Q_OBJECT + public: + KonquerorConfig( QWidget* parent_P, const char* name_P ); + virtual void load(); + virtual void load( bool useDefaults ); + virtual void save(); + virtual void defaults(); + private: + Konqueror* widget; + }; + +} // namespace + +#endif diff --git a/kcontrol/performance/konqueror.cpp b/kcontrol/performance/konqueror.cpp new file mode 100644 index 000000000..02dde4cce --- /dev/null +++ b/kcontrol/performance/konqueror.cpp @@ -0,0 +1,147 @@ +/* + * Copyright (c) 2003 Lubos Lunak <l.lunak@kde.org> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#include "konqueror.h" + +#include <dcopref.h> +#include <kconfig.h> +#include <qwhatsthis.h> +#include <qradiobutton.h> +#include <qspinbox.h> +#include <qlabel.h> +#include <qcheckbox.h> +#include <klocale.h> + +namespace KCMPerformance +{ + +Konqueror::Konqueror( QWidget* parent_P ) + : Konqueror_ui( parent_P ) + { + QWhatsThis::add( rb_never_reuse, + i18n( "Disables the minimization of memory usage and allows you " + "to make each browsing activity independent from the others" )); + QWhatsThis::add( rb_file_browsing_reuse, + i18n( "With this option activated, only one instance of Konqueror " + "used for file browsing will exist in the memory of your computer " + "at any moment, " + "no matter how many file browsing windows you open, " + "thus reducing resource requirements." + "<p>Be aware that this also means that, if something goes wrong, " + "all your file browsing windows will be closed simultaneously" )); + QWhatsThis::add( rb_always_reuse, + i18n( "With this option activated, only one instance of Konqueror " + "will exist in the memory of your computer at any moment, " + "no matter how many browsing windows you open, " + "thus reducing resource requirements." + "<p>Be aware that this also means that, if something goes wrong, " + "all your browsing windows will be closed simultaneously." )); + connect( rb_never_reuse, SIGNAL( clicked()), SIGNAL( changed())); + connect( rb_file_browsing_reuse, SIGNAL( clicked()), SIGNAL( changed())); + connect( rb_always_reuse, SIGNAL( clicked()), SIGNAL( changed())); + rb_file_browsing_reuse->setChecked( true ); + + QString tmp = + i18n( "If non-zero, this option allows keeping Konqueror instances " + "in memory after all their windows have been closed, up to the " + "number specified in this option." + "<p>When a new Konqueror instance is needed, one of these preloaded " + "instances will be reused instead, improving responsiveness at " + "the expense of the memory required by the preloaded instances." ); + QWhatsThis::add( sb_preload_count, tmp ); + QWhatsThis::add( lb_preload_count, tmp ); + QWhatsThis::add( cb_preload_on_startup, + i18n( "If enabled, an instance of Konqueror will be preloaded after the ordinary KDE " + "startup sequence." + "<p>This will make the first Konqueror window open faster, but " + "at the expense of longer KDE startup times (but you will be able to work " + "while it is loading, so you may not even notice that it is taking longer)." )); + QWhatsThis::add( cb_always_have_preloaded, + i18n( "If enabled, KDE will always try to have one preloaded Konqueror instance ready; " + "preloading a new instance in the background whenever there is not one available, " + "so that windows will always open quickly." + "<p><b>Warning:</b> In some cases, it is actually possible that this will " + "reduce perceived performance." )); + connect( sb_preload_count, SIGNAL( valueChanged( int )), SLOT( preload_count_changed( int ))); + connect( sb_preload_count, SIGNAL( valueChanged( int )), SIGNAL( changed())); + connect( cb_preload_on_startup, SIGNAL( clicked()), SIGNAL( changed())); + connect( cb_always_have_preloaded, SIGNAL( clicked()), SIGNAL( changed())); + defaults(); + } + +void Konqueror::preload_count_changed( int count ) + { + cb_preload_on_startup->setEnabled( count >= 1 ); + // forcing preloading with count == 1 can often do more harm than good, because + // if there's one konqy preloaded, and the user requests "starting" new konqueror, + // the preloaded instance will be used, new one will be preloaded, and if the user soon + // "quits" konqueror, one of the instances will have to be terminated + cb_always_have_preloaded->setEnabled( count >= 2 ); + } + +void Konqueror::load( bool useDefaults ) + { + KConfig cfg( "konquerorrc", true ); + cfg.setReadDefaults( useDefaults ); + cfg.setGroup( "Reusing" ); + allowed_parts = cfg.readEntry( "SafeParts", "SAFE" ); + if( allowed_parts == "ALL" ) + rb_always_reuse->setChecked( true ); + else if( allowed_parts.isEmpty()) + rb_never_reuse->setChecked( true ); + else + rb_file_browsing_reuse->setChecked( true ); + sb_preload_count->setValue( cfg.readNumEntry( "MaxPreloadCount", 1 )); + cb_always_have_preloaded->setChecked( cfg.readBoolEntry( "AlwaysHavePreloaded", false )); + cb_preload_on_startup->setChecked( cfg.readBoolEntry( "PreloadOnStartup", false )); + } + +void Konqueror::save() + { + KConfig cfg( "konquerorrc" ); + cfg.setGroup( "Reusing" ); + if( rb_always_reuse->isChecked()) + allowed_parts = "ALL"; + else if( rb_never_reuse->isChecked()) + allowed_parts = ""; + else + { + if( allowed_parts.isEmpty() || allowed_parts == "ALL" ) + allowed_parts = "SAFE"; + // else - keep allowed_parts as read from the file, as the user may have modified the list there + } + cfg.writeEntry( "SafeParts", allowed_parts ); + int count = sb_preload_count->value(); + cfg.writeEntry( "MaxPreloadCount", count ); + cfg.writeEntry( "PreloadOnStartup", cb_preload_on_startup->isChecked() && count >= 1 ); + cfg.writeEntry( "AlwaysHavePreloaded", cb_always_have_preloaded->isChecked() && count >= 2 ); + cfg.sync(); + DCOPRef ref1( "konqueror*", "KonquerorIface" ); + ref1.send( "reparseConfiguration()" ); + DCOPRef ref2( "kded", "konqy_preloader" ); + ref2.send( "reconfigure()" ); + } + +void Konqueror::defaults() + { + load( true ); + } + +} // namespace + +#include "konqueror.moc" diff --git a/kcontrol/performance/konqueror.h b/kcontrol/performance/konqueror.h new file mode 100644 index 000000000..bc17d2e4e --- /dev/null +++ b/kcontrol/performance/konqueror.h @@ -0,0 +1,46 @@ +/* + * Copyright (c) 2003 Lubos Lunak <l.lunak@kde.org> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#ifndef _KCM_PERF_KONQUEROR_H +#define _KCM_PERF_KONQUEROR_H + +#include "konqueror_ui.h" + +namespace KCMPerformance +{ + +class Konqueror + : public Konqueror_ui + { + Q_OBJECT + public: + Konqueror( QWidget* parent_P = NULL ); + void load(bool useDefaults); + void save(); + void defaults(); + signals: + void changed(); + private slots: + void preload_count_changed( int ); + private: + QString allowed_parts; + }; + +} // namespace + +#endif diff --git a/kcontrol/performance/konqueror_ui.ui b/kcontrol/performance/konqueror_ui.ui new file mode 100644 index 000000000..3ace0b5db --- /dev/null +++ b/kcontrol/performance/konqueror_ui.ui @@ -0,0 +1,155 @@ +<!DOCTYPE UI><UI version="3.1" stdsetdef="1"> +<class>KCMPerformance::Konqueror_ui</class> +<widget class="QWidget"> + <property name="name"> + <cstring>Konqueror_ui</cstring> + </property> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>600</width> + <height>480</height> + </rect> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <property name="margin"> + <number>0</number> + </property> + <widget class="QButtonGroup"> + <property name="name"> + <cstring>reuse_group</cstring> + </property> + <property name="title"> + <string>Minimize Memory Usage</string> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QRadioButton"> + <property name="name"> + <cstring>rb_never_reuse</cstring> + </property> + <property name="text"> + <string>&Never</string> + </property> + </widget> + <widget class="QRadioButton"> + <property name="name"> + <cstring>rb_file_browsing_reuse</cstring> + </property> + <property name="text"> + <string>For &file browsing only (recommended)</string> + </property> + </widget> + <widget class="QRadioButton"> + <property name="name"> + <cstring>rb_always_reuse</cstring> + </property> + <property name="text"> + <string>Alwa&ys (use with care)</string> + </property> + </widget> + </vbox> + </widget> + <widget class="QGroupBox"> + <property name="name"> + <cstring>groupBox1</cstring> + </property> + <property name="title"> + <string>Preloading</string> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QLayoutWidget"> + <property name="name"> + <cstring>layout2</cstring> + </property> + <hbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QLabel"> + <property name="name"> + <cstring>lb_preload_count</cstring> + </property> + <property name="text"> + <string>Maximum number of instances kept &preloaded:</string> + </property> + <property name="buddy" stdset="0"> + <cstring>sb_preload_count</cstring> + </property> + </widget> + <widget class="QSpinBox"> + <property name="name"> + <cstring>sb_preload_count</cstring> + </property> + </widget> + <spacer> + <property name="name"> + <cstring>spacer2</cstring> + </property> + <property name="orientation"> + <enum>Horizontal</enum> + </property> + <property name="sizeType"> + <enum>Expanding</enum> + </property> + <property name="sizeHint"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </hbox> + </widget> + <widget class="QCheckBox"> + <property name="name"> + <cstring>cb_preload_on_startup</cstring> + </property> + <property name="text"> + <string>Preload an instance after KDE startup</string> + </property> + </widget> + <widget class="QCheckBox"> + <property name="name"> + <cstring>cb_always_have_preloaded</cstring> + </property> + <property name="text"> + <string>Always try to have at least one preloaded instance</string> + </property> + </widget> + </vbox> + </widget> + <spacer> + <property name="name"> + <cstring>spacer1</cstring> + </property> + <property name="orientation"> + <enum>Vertical</enum> + </property> + <property name="sizeType"> + <enum>Expanding</enum> + </property> + <property name="sizeHint"> + <size> + <width>20</width> + <height>160</height> + </size> + </property> + </spacer> + </vbox> +</widget> +<includes> + <include location="local" impldecl="in implementation">kdialog.h</include> +</includes> +<layoutdefaults spacing="3" margin="6"/> +<layoutfunctions spacing="KDialog::spacingHint" margin="KDialog::marginHint"/> +</UI> diff --git a/kcontrol/performance/system.cpp b/kcontrol/performance/system.cpp new file mode 100644 index 000000000..97b5c5709 --- /dev/null +++ b/kcontrol/performance/system.cpp @@ -0,0 +1,80 @@ +/* + * Copyright (c) 2004 Lubos Lunak <l.lunak@kde.org> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#include "system.h" + +#include <kconfig.h> +#include <qwhatsthis.h> +#include <qcheckbox.h> +#include <qlabel.h> +#include <klocale.h> + +namespace KCMPerformance +{ + +SystemWidget::SystemWidget( QWidget* parent_P ) + : System_ui( parent_P ) + { + QString tmp = + i18n( "<p>During startup KDE needs to perform a check of its system configuration" + " (mimetypes, installed applications, etc.), and in case the configuration" + " has changed since the last time, the system configuration cache (KSyCoCa)" + " needs to be updated.</p>" + "<p>This option delays the check, which avoid scanning all directories containing" + " files describing the system during KDE startup, thus" + " making KDE startup faster. However, in the rare case the system configuration" + " has changed since the last time, and the change is needed before this" + " delayed check takes place, this option may lead to various problems" + " (missing applications in the K Menu, reports from applications about missing" + " required mimetypes, etc.).</p>" + "<p>Changes of system configuration mostly happen by (un)installing applications." + " It is therefore recommended to turn this option temporarily off while" + " (un)installing applications.</p>" + "<p>For this reason, usage of this option is not recommended. The KDE crash" + " handler will refuse to provide backtrace for the bugreport with this option" + " turned on (you will need to reproduce it again with this option turned off," + " or turn on the developer mode for the crash handler).</p>" ); + QWhatsThis::add( cb_disable_kbuildsycoca, tmp ); + QWhatsThis::add( label_kbuildsycoca, tmp ); + connect( cb_disable_kbuildsycoca, SIGNAL( clicked()), SIGNAL( changed())); + defaults(); + } + +void SystemWidget::load(bool useDefaults ) + { + KConfig cfg( "kdedrc", true ); + cfg.setReadDefaults( useDefaults ); + cfg.setGroup( "General" ); + cb_disable_kbuildsycoca->setChecked( cfg.readBoolEntry( "DelayedCheck", false )); + } + +void SystemWidget::save() + { + KConfig cfg( "kdedrc" ); + cfg.setGroup( "General" ); + cfg.writeEntry( "DelayedCheck", cb_disable_kbuildsycoca->isChecked()); + } + +void SystemWidget::defaults() + { + load( true ); + } + +} // namespace + +#include "system.moc" diff --git a/kcontrol/performance/system.h b/kcontrol/performance/system.h new file mode 100644 index 000000000..d788b2073 --- /dev/null +++ b/kcontrol/performance/system.h @@ -0,0 +1,44 @@ +/* + * Copyright (c) 2004 Lubos Lunak <l.lunak@kde.org> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +#ifndef _KCM_PERF_SYSTEM_H +#define _KCM_PERF_SYSTEM_H + +#include <kcmodule.h> + +#include "system_ui.h" + +namespace KCMPerformance +{ + +class SystemWidget + : public System_ui + { + Q_OBJECT + public: + SystemWidget( QWidget* parent_P = NULL ); + void load( bool useDefaults ); + void save(); + void defaults(); + signals: + void changed(); + }; + +} // namespace + +#endif diff --git a/kcontrol/performance/system_ui.ui b/kcontrol/performance/system_ui.ui new file mode 100644 index 000000000..a8d0e7956 --- /dev/null +++ b/kcontrol/performance/system_ui.ui @@ -0,0 +1,69 @@ +<!DOCTYPE UI><UI version="3.3" stdsetdef="1"> +<class>System_ui</class> +<widget class="QWidget"> + <property name="name"> + <cstring>System_ui</cstring> + </property> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>600</width> + <height>480</height> + </rect> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QGroupBox"> + <property name="name"> + <cstring>gb_</cstring> + </property> + <property name="title"> + <string>System Configuration</string> + </property> + <vbox> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <widget class="QCheckBox"> + <property name="name"> + <cstring>cb_disable_kbuildsycoca</cstring> + </property> + <property name="text"> + <string>Disable &system configuration startup check</string> + </property> + </widget> + <widget class="QLabel"> + <property name="name"> + <cstring>label_kbuildsycoca</cstring> + </property> + <property name="text"> + <string><b>WARNING:</b> This option may in rare cases lead to various problems. Consult the What's This? (Shift+F1) help for details.</string> + </property> + </widget> + </vbox> + </widget> + <spacer> + <property name="name"> + <cstring>spacer1</cstring> + </property> + <property name="orientation"> + <enum>Vertical</enum> + </property> + <property name="sizeType"> + <enum>Expanding</enum> + </property> + <property name="sizeHint"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </vbox> +</widget> +<layoutdefaults spacing="6" margin="11"/> +<layoutfunctions spacing="KDialog::spacingHint" margin="KDialog::marginHint"/> +</UI> |