diff options
Diffstat (limited to 'ksplashml')
48 files changed, 139 insertions, 140 deletions
diff --git a/ksplashml/CMakeL10n.txt b/ksplashml/CMakeL10n.txt index 98d1940a8..2e1ad51f1 100644 --- a/ksplashml/CMakeL10n.txt +++ b/ksplashml/CMakeL10n.txt @@ -12,3 +12,17 @@ tde_l10n_create_template( SOURCES *.desktop DESTINATION "${CMAKE_SOURCE_DIR}/translations" ) + +file( + GLOB_RECURSE _themes + RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} + ${CMAKE_CURRENT_SOURCE_DIR}/*Theme.rc +) +list( SORT _themes ) + +tde_l10n_create_template( + CATALOG "desktop_files/ksplash-themes/" + SOURCES_DESKTOP ${_themes} + KEYWORDS Message1 Message2 Message3 Message4 Message5 Message6 Message7 Message8 + DESTINATION "${CMAKE_SOURCE_DIR}/translations" +) diff --git a/ksplashml/kcmksplash/installer.cpp b/ksplashml/kcmksplash/installer.cpp index 7ee681907..7a8b53b57 100644 --- a/ksplashml/kcmksplash/installer.cpp +++ b/ksplashml/kcmksplash/installer.cpp @@ -24,9 +24,9 @@ #include <tdeglobalsettings.h> #include <tdelocale.h> #include <tdemessagebox.h> -#include <kprocess.h> +#include <tdeprocess.h> #include <kpushbutton.h> -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include <ktar.h> #include <ktrader.h> #include <kurldrag.h> @@ -36,8 +36,8 @@ ThemeListBox::ThemeListBox(TQWidget *parent) : TDEListBox(parent) { setAcceptDrops(true); - connect(this, TQT_SIGNAL(mouseButtonPressed(int, TQListBoxItem *, const TQPoint &)), - this, TQT_SLOT(slotMouseButtonPressed(int, TQListBoxItem *, const TQPoint &))); + connect(this, TQ_SIGNAL(mouseButtonPressed(int, TQListBoxItem *, const TQPoint &)), + this, TQ_SLOT(slotMouseButtonPressed(int, TQListBoxItem *, const TQPoint &))); } void ThemeListBox::dragEnterEvent(TQDragEnterEvent* event) @@ -56,7 +56,7 @@ void ThemeListBox::dropEvent(TQDropEvent* event) void ThemeListBox::slotMouseButtonPressed(int button, TQListBoxItem *item, const TQPoint &p) { - if ((button & Qt::LeftButton) == 0) return; + if ((button & TQt::LeftButton) == 0) return; mOldPos = p; mDragFile = TQString::null; int cur = index(item); @@ -66,7 +66,7 @@ void ThemeListBox::slotMouseButtonPressed(int button, TQListBoxItem *item, const void ThemeListBox::mouseMoveEvent(TQMouseEvent *e) { - if (((e->state() & Qt::LeftButton) != 0) && !mDragFile.isEmpty()) + if (((e->state() & TQt::LeftButton) != 0) && !mDragFile.isEmpty()) { int delay = TDEGlobalSettings::dndEventDelay(); TQPoint newPos = e->globalPos(); @@ -100,21 +100,21 @@ SplashInstaller::SplashInstaller (TQWidget *aParent, const char *aName, bool aIn mThemesList = new ThemeListBox(this); mThemesList->setSizePolicy( TQSizePolicy::Preferred, TQSizePolicy::Expanding ); - connect(mThemesList, TQT_SIGNAL(highlighted(int)), TQT_SLOT(slotSetTheme(int))); - connect(mThemesList, TQT_SIGNAL(filesDropped(const KURL::List&)), TQT_SLOT(slotFilesDropped(const KURL::List&))); + connect(mThemesList, TQ_SIGNAL(highlighted(int)), TQ_SLOT(slotSetTheme(int))); + connect(mThemesList, TQ_SIGNAL(filesDropped(const KURL::List&)), TQ_SLOT(slotFilesDropped(const KURL::List&))); leftbox->addWidget(mThemesList); mBtnAdd = new KPushButton( i18n("Add..."), this ); leftbox->addWidget( mBtnAdd ); - connect(mBtnAdd, TQT_SIGNAL(clicked()), TQT_SLOT(slotAdd())); + connect(mBtnAdd, TQ_SIGNAL(clicked()), TQ_SLOT(slotAdd())); mBtnRemove = new KPushButton( i18n("Remove"), this ); leftbox->addWidget( mBtnRemove ); - connect(mBtnRemove, TQT_SIGNAL(clicked()), TQT_SLOT(slotRemove())); + connect(mBtnRemove, TQ_SIGNAL(clicked()), TQ_SLOT(slotRemove())); mBtnTest = new KPushButton( i18n("Test"), this ); leftbox->addWidget( mBtnTest ); - connect(mBtnTest, TQT_SIGNAL(clicked()), TQT_SLOT(slotTest())); + connect(mBtnTest, TQ_SIGNAL(clicked()), TQ_SLOT(slotTest())); TQVBoxLayout* rightbox = new TQVBoxLayout( hbox, KDialog::spacingHint() ); hbox->setStretchFactor( rightbox, 3 ); @@ -123,7 +123,7 @@ SplashInstaller::SplashInstaller (TQWidget *aParent, const char *aName, bool aIn mPreview->setSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Expanding ); mPreview->setFrameStyle(TQFrame::Panel|TQFrame::Sunken); mPreview->setMinimumSize(TQSize(320,240)); - mPreview->setAlignment(Qt::AlignHCenter|Qt::AlignVCenter); + mPreview->setAlignment(TQt::AlignHCenter|TQt::AlignVCenter); rightbox->addWidget(mPreview); rightbox->setStretchFactor( mPreview, 3 ); diff --git a/ksplashml/kcmksplash/installer.h b/ksplashml/kcmksplash/installer.h index 7a46e368b..a88c3f632 100644 --- a/ksplashml/kcmksplash/installer.h +++ b/ksplashml/kcmksplash/installer.h @@ -24,9 +24,9 @@ class ThemeListBox; class SplashInstaller : public TQWidget { - Q_OBJECT + TQ_OBJECT public: - SplashInstaller(TQWidget *parent=0, const char *aName=0, bool aInit=FALSE); + SplashInstaller(TQWidget *parent=0, const char *aName=0, bool aInit=false); ~SplashInstaller(); virtual void load(); @@ -62,7 +62,7 @@ private: class ThemeListBox: public TDEListBox { - Q_OBJECT + TQ_OBJECT public: ThemeListBox(TQWidget *parent); TQMap<TQString, TQString> text2path; diff --git a/ksplashml/kcmksplash/main.cpp b/ksplashml/kcmksplash/main.cpp index f0b5d1f52..0e9972bbe 100644 --- a/ksplashml/kcmksplash/main.cpp +++ b/ksplashml/kcmksplash/main.cpp @@ -19,7 +19,7 @@ #include <tdecmodule.h> #include <kdebug.h> #include <kgenericfactory.h> -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include "installer.h" @@ -59,7 +59,7 @@ KSplashThemeMgr::KSplashThemeMgr( TQWidget *parent, const char *name, const TQSt TQHBoxLayout *box = new TQHBoxLayout(this, 0, 0); box->addWidget(mInstaller); #endif - connect( mInstaller, TQT_SIGNAL(changed(bool)), TQT_SIGNAL(changed(bool)) ); + connect( mInstaller, TQ_SIGNAL(changed(bool)), TQ_SIGNAL(changed(bool)) ); TDEAboutData *about = new TDEAboutData( "kcmksplash" ,I18N_NOOP("TDE splash screen theme manager") ,"0.1" diff --git a/ksplashml/pics/CMakeL10n.txt b/ksplashml/pics/CMakeL10n.txt deleted file mode 100644 index b585ce4af..000000000 --- a/ksplashml/pics/CMakeL10n.txt +++ /dev/null @@ -1,3 +0,0 @@ -##### create translation templates ############## - -tde_l10n_auto_add_subdirectories( ) diff --git a/ksplashml/pics/splash.png b/ksplashml/pics/splash.png Binary files differindex 399c2915a..295e18bed 100644..100755 --- a/ksplashml/pics/splash.png +++ b/ksplashml/pics/splash.png diff --git a/ksplashml/pics/themes/CMakeL10n.txt b/ksplashml/pics/themes/CMakeL10n.txt deleted file mode 100644 index be21a4224..000000000 --- a/ksplashml/pics/themes/CMakeL10n.txt +++ /dev/null @@ -1,15 +0,0 @@ -##### create translation templates ############## - -file( - GLOB_RECURSE _themes - RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} - ${CMAKE_CURRENT_SOURCE_DIR}/*Theme.rc -) -list( SORT _themes ) - -tde_l10n_create_template( - CATALOG "desktop_files/ksplash-themes/" - SOURCES_DESKTOP ${_themes} - KEYWORDS Message1 Message2 Message3 Message4 Message5 Message6 Message7 Message8 - DESTINATION "${CMAKE_SOURCE_DIR}/translations" -) diff --git a/ksplashml/pics/themes/TDE-Classic/Preview.png b/ksplashml/pics/themes/TDE-Classic/Preview.png Binary files differindex 4df2c8ccd..51f9941d1 100644..100755 --- a/ksplashml/pics/themes/TDE-Classic/Preview.png +++ b/ksplashml/pics/themes/TDE-Classic/Preview.png diff --git a/ksplashml/pics/themes/TDE-Classic/splash_active_bar.png b/ksplashml/pics/themes/TDE-Classic/splash_active_bar.png Binary files differindex 747f2c510..bd76dd7ed 100644..100755 --- a/ksplashml/pics/themes/TDE-Classic/splash_active_bar.png +++ b/ksplashml/pics/themes/TDE-Classic/splash_active_bar.png diff --git a/ksplashml/pics/themes/TDE-Classic/splash_inactive_bar.png b/ksplashml/pics/themes/TDE-Classic/splash_inactive_bar.png Binary files differindex 8957dc895..4d0142e3c 100644..100755 --- a/ksplashml/pics/themes/TDE-Classic/splash_inactive_bar.png +++ b/ksplashml/pics/themes/TDE-Classic/splash_inactive_bar.png diff --git a/ksplashml/pics/themes/TDE-Classic/splash_top.png b/ksplashml/pics/themes/TDE-Classic/splash_top.png Binary files differindex 63e047d1d..b61a58d8e 100644..100755 --- a/ksplashml/pics/themes/TDE-Classic/splash_top.png +++ b/ksplashml/pics/themes/TDE-Classic/splash_top.png diff --git a/ksplashml/pics/themes/blue-bend/Preview.png b/ksplashml/pics/themes/blue-bend/Preview.png Binary files differindex 0145181bd..58ff147a7 100644..100755 --- a/ksplashml/pics/themes/blue-bend/Preview.png +++ b/ksplashml/pics/themes/blue-bend/Preview.png diff --git a/ksplashml/pics/themes/blue-bend/splash_active_bar.png b/ksplashml/pics/themes/blue-bend/splash_active_bar.png Binary files differindex 0d39d1b66..b7daf5439 100644..100755 --- a/ksplashml/pics/themes/blue-bend/splash_active_bar.png +++ b/ksplashml/pics/themes/blue-bend/splash_active_bar.png diff --git a/ksplashml/pics/themes/blue-bend/splash_inactive_bar.png b/ksplashml/pics/themes/blue-bend/splash_inactive_bar.png Binary files differindex 047ca9136..9badc1606 100644..100755 --- a/ksplashml/pics/themes/blue-bend/splash_inactive_bar.png +++ b/ksplashml/pics/themes/blue-bend/splash_inactive_bar.png diff --git a/ksplashml/pics/themes/blue-bend/splash_top.png b/ksplashml/pics/themes/blue-bend/splash_top.png Binary files differindex 1dcc548fd..4d51f3765 100644..100755 --- a/ksplashml/pics/themes/blue-bend/splash_top.png +++ b/ksplashml/pics/themes/blue-bend/splash_top.png diff --git a/ksplashml/pics/themes/default/Preview.png b/ksplashml/pics/themes/default/Preview.png Binary files differindex e6a2efc34..91d202b91 100644..100755 --- a/ksplashml/pics/themes/default/Preview.png +++ b/ksplashml/pics/themes/default/Preview.png diff --git a/ksplashml/pics/themes/default/Theme.rc b/ksplashml/pics/themes/default/Theme.rc index b218149ec..223565cae 100644 --- a/ksplashml/pics/themes/default/Theme.rc +++ b/ksplashml/pics/themes/default/Theme.rc @@ -2,7 +2,7 @@ # Refresh KSplash/ML Theme # -[KSplash Theme: Refresh] +[KSplash Theme: Default] Name = Refresh TDE Splash Theme Description = Load Refresh TDE KSplash theme. Version = 1.0 diff --git a/ksplashml/pics/themes/default/splash_active_bar.png b/ksplashml/pics/themes/default/splash_active_bar.png Binary files differindex 2586ec4f3..353bf8e98 100644..100755 --- a/ksplashml/pics/themes/default/splash_active_bar.png +++ b/ksplashml/pics/themes/default/splash_active_bar.png diff --git a/ksplashml/pics/themes/default/splash_bottom.png b/ksplashml/pics/themes/default/splash_bottom.png Binary files differindex bceda5097..67e25ad9e 100644..100755 --- a/ksplashml/pics/themes/default/splash_bottom.png +++ b/ksplashml/pics/themes/default/splash_bottom.png diff --git a/ksplashml/pics/themes/default/splash_inactive_bar.png b/ksplashml/pics/themes/default/splash_inactive_bar.png Binary files differindex 0d4b451cd..19567968f 100644..100755 --- a/ksplashml/pics/themes/default/splash_inactive_bar.png +++ b/ksplashml/pics/themes/default/splash_inactive_bar.png diff --git a/ksplashml/pics/themes/default/splash_top.png b/ksplashml/pics/themes/default/splash_top.png Binary files differindex f9b305b2a..0168be83a 100644..100755 --- a/ksplashml/pics/themes/default/splash_top.png +++ b/ksplashml/pics/themes/default/splash_top.png diff --git a/ksplashml/themeengine/default/themelegacy.cpp b/ksplashml/themeengine/default/themelegacy.cpp index 0e1242120..99a3145f0 100644 --- a/ksplashml/themeengine/default/themelegacy.cpp +++ b/ksplashml/themeengine/default/themelegacy.cpp @@ -15,7 +15,7 @@ #include <kgenericfactory.h> #include <tdeglobalsettings.h> #include <tdelocale.h> -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include <kprogress.h> #include <tqcheckbox.h> @@ -71,7 +71,7 @@ ThemeDefault::ThemeDefault( TQWidget *parent, const char *name, const TQStringLi if( mIconsFlashing ) { mFlashTimer = new TQTimer( this ); - connect( mFlashTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(flash()) ); + connect( mFlashTimer, TQ_SIGNAL(timeout()), this, TQ_SLOT(flash()) ); mFlashPixmap1 = new TQPixmap(); mFlashPixmap2 = new TQPixmap(); @@ -120,19 +120,19 @@ void ThemeDefault::_initUi() if (mActivePixmap->isNull()) { mActivePixmap->resize(200,100); - mActivePixmap->fill(Qt::blue); + mActivePixmap->fill(TQt::blue); } if (mInactivePixmap->isNull()) { mInactivePixmap->resize(200,100); - mInactivePixmap->fill(Qt::black); + mInactivePixmap->fill(TQt::black); } TQPixmap tlimage( _findPicture(TQString("splash_top.png")) ); if (tlimage.isNull()) { tlimage.resize(200,100); - tlimage.fill(Qt::blue); + tlimage.fill(TQt::blue); } TQLabel *top_label = new TQLabel( vbox ); top_label->setPixmap( tlimage ); @@ -147,7 +147,7 @@ void ThemeDefault::_initUi() if (blimage.isNull()) { blimage.resize(200,100); - blimage.fill(Qt::black); + blimage.fill(TQt::black); } TQLabel *bottom_label = new TQLabel( vbox ); bottom_label->setPaletteBackgroundPixmap( blimage ); @@ -158,7 +158,7 @@ void ThemeDefault::_initUi() mLabel->setPaletteForegroundColor( mLabelForeground ); mLabel->setPaletteBackgroundPixmap( blimage ); TQFont f(mLabel->font()); - f.setBold(TRUE); + f.setBold(true); mLabel->setFont(f); mProgressBar = new KProgress( mLabel ); @@ -191,7 +191,7 @@ void ThemeDefault::_initUi() setFixedHeight( mInactivePixmap->height() + top_label->height() + bottom_label->height() ); - const TQRect rect = kapp->desktop()->screenGeometry( mTheme->xineramaScreen() ); + const TQRect rect = tdeApp->desktop()->screenGeometry( mTheme->xineramaScreen() ); // TDEGlobalSettings::splashScreenDesktopGeometry(); cannot be used here. // kdDebug() << "ThemeDefault::_initUi" << rect << endl; @@ -212,7 +212,7 @@ void ThemeDefault::_readSettings() cfg->setGroup( TQString("KSplash Theme: %1").arg(mTheme->theme()) ); mIconsFlashing = cfg->readBoolEntry( "Icons Flashing", true ); - TQColor df(Qt::white); + TQColor df(TQt::white); mLabelForeground = cfg->readColorEntry( "Label Foreground", &df ); TQValueList<int> io_list=cfg->readIntListEntry("Icon Offsets"); if (io_list.size() == MAX_ICONS) diff --git a/ksplashml/themeengine/default/themelegacy.h b/ksplashml/themeengine/default/themelegacy.h index 1f56d05b0..35aa414eb 100644 --- a/ksplashml/themeengine/default/themelegacy.h +++ b/ksplashml/themeengine/default/themelegacy.h @@ -29,7 +29,7 @@ class TQCheckBox; class DefaultConfig: public ThemeEngineConfig { - Q_OBJECT + TQ_OBJECT public: DefaultConfig( TQWidget *, TDEConfig * ); void save(); @@ -41,9 +41,9 @@ protected: * @short Traditional Trinity splash screen. */ class ObjKsTheme; -class KDE_EXPORT ThemeDefault : public ThemeEngine +class TDE_EXPORT ThemeDefault : public ThemeEngine { - Q_OBJECT + TQ_OBJECT public: ThemeDefault( TQWidget *, const char *, const TQStringList& ); virtual ~ThemeDefault(); diff --git a/ksplashml/themeengine/objkstheme.cpp b/ksplashml/themeengine/objkstheme.cpp index 9de990099..d5b072f80 100644 --- a/ksplashml/themeengine/objkstheme.cpp +++ b/ksplashml/themeengine/objkstheme.cpp @@ -15,7 +15,7 @@ #include <kdebug.h> #include <tdeglobal.h> #include <tdelocale.h> -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include <tqcolor.h> #include <tqcursor.h> @@ -32,9 +32,9 @@ ObjKsTheme::ObjKsTheme( const TQString& theme ) :mActiveTheme (theme), mThemeDir("/"), mThemeConfig (0L), mThemePrefix( "Themes/" ), d(0) { // Get Xinerama config. - TDEConfig *config = kapp->config(); + TDEConfig *config = tdeApp->config(); config->setGroup( "Xinerama" ); - TQDesktopWidget *desktop = kapp->desktop(); + TQDesktopWidget *desktop = tdeApp->desktop(); mXineramaScreen = config->readNumEntry("KSplashScreen", desktop->primaryScreen()); // For Xinerama, let's put the mouse on the first head. Otherwise it could appear anywhere! @@ -92,7 +92,7 @@ bool ObjKsTheme::loadThemeRc( const TQString& activeTheme, bool force ) bool ObjKsTheme::loadLocalConfig( const TQString& activeTheme, bool force ) { //kdDebug() << "ObjKsTheme::loadLocalConfig" << endl; - TDEConfig *cfg = kapp->config(); + TDEConfig *cfg = tdeApp->config(); return( loadTDEConfig( cfg, activeTheme, force ) ); } @@ -118,7 +118,7 @@ bool ObjKsTheme::loadTDEConfig( TDEConfig *cfg, const TQString& activeTheme, boo m_icons.append( cfg->readEntry( "Icon1", "filetypes" ) ); m_icons.append( cfg->readEntry( "Icon2", "application-x-executable" ) ); m_icons.append( cfg->readEntry( "Icon3", "key_bindings" ) ); - m_icons.append( cfg->readEntry( "Icon4", "window_list" ) ); + m_icons.append( cfg->readEntry( "Icon4", "window_duplicate" ) ); m_icons.append( cfg->readEntry( "Icon5", "desktop" ) ); m_icons.append( cfg->readEntry( "Icon6", "style" ) ); m_icons.append( cfg->readEntry( "Icon7", "preferences-system" ) ); diff --git a/ksplashml/themeengine/objkstheme.h b/ksplashml/themeengine/objkstheme.h index 8959c5537..7702371f3 100644 --- a/ksplashml/themeengine/objkstheme.h +++ b/ksplashml/themeengine/objkstheme.h @@ -26,9 +26,9 @@ class TDEConfig; * of KSplash completely, and offers a friendlier way * of installing custom splash screens. */ -class KDE_EXPORT ObjKsTheme : public QObject +class TDE_EXPORT ObjKsTheme : public TQObject { - Q_OBJECT + TQ_OBJECT public: explicit ObjKsTheme( const TQString& ); virtual ~ObjKsTheme(); diff --git a/ksplashml/themeengine/redmond/CMakeLists.txt b/ksplashml/themeengine/redmond/CMakeLists.txt index 52bc35732..7284c40be 100644 --- a/ksplashml/themeengine/redmond/CMakeLists.txt +++ b/ksplashml/themeengine/redmond/CMakeLists.txt @@ -25,7 +25,12 @@ link_directories( ##### other data ################################ -install( FILES Theme.rc DESTINATION ${DATA_INSTALL_DIR}/ksplash/Themes/Redmond ) +tde_create_translated_desktop( + SOURCE Theme.rc + DESTINATION ${DATA_INSTALL_DIR}/ksplash/Themes/Redmond + PO_DIR ksplash-themes +) + tde_create_translated_desktop( SOURCE ksplashredmond.desktop DESTINATION ${SERVICES_INSTALL_DIR} diff --git a/ksplashml/themeengine/redmond/Theme.rc b/ksplashml/themeengine/redmond/Theme.rc index 3c5b0687e..a87deedc5 100644 --- a/ksplashml/themeengine/redmond/Theme.rc +++ b/ksplashml/themeengine/redmond/Theme.rc @@ -1,2 +1,5 @@ [KSplash Theme: Redmond] +Name = Redmond Splash Screen +Description = KSplash theme inspired by the Microsoft Windows startup screen. + Engine=Redmond diff --git a/ksplashml/themeengine/redmond/main.cpp b/ksplashml/themeengine/redmond/main.cpp index 7b4a6bb2e..6e910064d 100644 --- a/ksplashml/themeengine/redmond/main.cpp +++ b/ksplashml/themeengine/redmond/main.cpp @@ -10,7 +10,7 @@ * * ***************************************************************************/ -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include <tqlabel.h> #include <tqpixmap.h> diff --git a/ksplashml/themeengine/redmond/previewredmond.cpp b/ksplashml/themeengine/redmond/previewredmond.cpp index 29bfa4b66..5f759686c 100644 --- a/ksplashml/themeengine/redmond/previewredmond.cpp +++ b/ksplashml/themeengine/redmond/previewredmond.cpp @@ -33,10 +33,10 @@ PreviewRedmond::PreviewRedmond( TQWidget* parent ) m_userFont (TQFont( "Arial", 16 )), m_statusFont (TQFont( "Arial", 12, TQFont::Bold )), - m_welcomeColor (Qt::white), - m_welcomeShadowColor (Qt::darkGray), - m_userColor (Qt::darkGray), - m_statusColor (Qt::white), + m_welcomeColor (TQt::white), + m_welcomeShadowColor (TQt::darkGray), + m_userColor (TQt::darkGray), + m_statusColor (TQt::white), m_icon (DesktopIcon("kmenu")), @@ -71,7 +71,7 @@ void PreviewRedmond::_updateCache() TQPainter p; p.begin( &m_cache ); - p.fillRect( rect(), Qt::gray ); + p.fillRect( rect(), TQt::gray ); m_welcomeFont.setItalic( true ); p.setFont( m_welcomeFont ); diff --git a/ksplashml/themeengine/redmond/previewredmond.h b/ksplashml/themeengine/redmond/previewredmond.h index 5fc5558c2..fdaf6418e 100644 --- a/ksplashml/themeengine/redmond/previewredmond.h +++ b/ksplashml/themeengine/redmond/previewredmond.h @@ -27,7 +27,7 @@ */ class PreviewRedmond: public TQWidget { - Q_OBJECT + TQ_OBJECT public: PreviewRedmond( TQWidget* ); diff --git a/ksplashml/themeengine/redmond/themeredmond.cpp b/ksplashml/themeengine/redmond/themeredmond.cpp index b0e81ba72..548e62769 100644 --- a/ksplashml/themeengine/redmond/themeredmond.cpp +++ b/ksplashml/themeengine/redmond/themeredmond.cpp @@ -22,7 +22,7 @@ #include <tdeglobalsettings.h> #include <kiconloader.h> #include <tdelocale.h> -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include <kuser.h> #include <tdeemailsettings.h> @@ -52,7 +52,7 @@ CfgRedmond::CfgRedmond( TQWidget *p, TDEConfig *c ) TQFont defaultUsernameFont( "Arial", 16, TQFont::Bold ); TQFont defaultActionFont( "Arial", 12, TQFont::Bold ); TQColor defaultDarkColor( 3, 47, 156 ); - TQColor defaultWhiteColor( Qt::white ); + TQColor defaultWhiteColor( TQt::white ); TQHBox *hbox = new TQHBox( vbox ); hbox->setFrameStyle( TQFrame::WinPanel ); @@ -86,7 +86,7 @@ ThemeRedmond::ThemeRedmond( TQWidget *parent, const char *name, const TQStringLi void ThemeRedmond::_initUi() { - const TQRect screen = kapp->desktop()->screenGeometry( mTheme->xineramaScreen() ); + const TQRect screen = tdeApp->desktop()->screenGeometry( mTheme->xineramaScreen() ); //TQRect fullScreen = TDEGlobalSettings::desktopGeometry(0L); mImage.resize( screen.width(), screen.height() ); @@ -275,7 +275,7 @@ void ThemeRedmond::_initUi() void ThemeRedmond::paintEvent( TQPaintEvent *pe ) { - const TQRect screen = kapp->desktop()->screenGeometry( mTheme->xineramaScreen() ); + const TQRect screen = tdeApp->desktop()->screenGeometry( mTheme->xineramaScreen() ); TQPainter p; p.begin( this ); @@ -308,7 +308,7 @@ void ThemeRedmond::paintEvent( TQPaintEvent *pe ) void ThemeRedmond::_readSettings() { - const TQRect screen = kapp->desktop()->screenGeometry( mTheme->xineramaScreen() ); + const TQRect screen = tdeApp->desktop()->screenGeometry( mTheme->xineramaScreen() ); //TQRect fullScreen = TDEGlobalSettings::desktopGeometry(0L); if( !mTheme ) @@ -356,7 +356,7 @@ void ThemeRedmond::_readSettings() mActionFont = cfg->readFontEntry( "Action Font", &defaultActionFont ); TQColor defaultDarkColor( 3, 47, 156 ); - TQColor defaultWhiteColor( Qt::white ); + TQColor defaultWhiteColor( TQt::white ); mWelcomeTextColor = cfg->readColorEntry( "Welcome Text Color", &defaultWhiteColor ); mWelcomeTextShadowColor = cfg->readColorEntry( "Welcome Shadow Color", &defaultDarkColor ); diff --git a/ksplashml/themeengine/redmond/themeredmond.h b/ksplashml/themeengine/redmond/themeredmond.h index d68e004da..1fbb7c57a 100644 --- a/ksplashml/themeengine/redmond/themeredmond.h +++ b/ksplashml/themeengine/redmond/themeredmond.h @@ -23,7 +23,7 @@ class TQCheckBox; class CfgRedmond: public ThemeEngineConfig { - Q_OBJECT + TQ_OBJECT public: CfgRedmond( TQWidget *, TDEConfig * ); @@ -39,7 +39,7 @@ protected: class ObjKsTheme; class ThemeRedmond: public ThemeEngine { - Q_OBJECT + TQ_OBJECT public: ThemeRedmond( TQWidget *, const char *, const TQStringList& ); diff --git a/ksplashml/themeengine/standard/CMakeLists.txt b/ksplashml/themeengine/standard/CMakeLists.txt index 8aca3a57e..a2119c5e3 100644 --- a/ksplashml/themeengine/standard/CMakeLists.txt +++ b/ksplashml/themeengine/standard/CMakeLists.txt @@ -26,7 +26,12 @@ link_directories( ##### other data ################################ -install( FILES Theme.rc DESTINATION ${DATA_INSTALL_DIR}/ksplash/Themes/Standard ) +tde_create_translated_desktop( + SOURCE Theme.rc + DESTINATION ${DATA_INSTALL_DIR}/ksplash/Themes/Standard + PO_DIR ksplash-themes +) + tde_create_translated_desktop( SOURCE ksplashstandard.desktop DESTINATION ${SERVICES_INSTALL_DIR} diff --git a/ksplashml/themeengine/standard/Preview.png b/ksplashml/themeengine/standard/Preview.png Binary files differindex b2ce44163..9545b9eac 100644..100755 --- a/ksplashml/themeengine/standard/Preview.png +++ b/ksplashml/themeengine/standard/Preview.png diff --git a/ksplashml/themeengine/standard/Theme.rc b/ksplashml/themeengine/standard/Theme.rc index 2ae13af53..d4e4e5bd7 100644 --- a/ksplashml/themeengine/standard/Theme.rc +++ b/ksplashml/themeengine/standard/Theme.rc @@ -1,2 +1,5 @@ [KSplash Theme: Standard] +Name = Standard Splash Screen +Description = Standard TDE KSplash theme. + Engine=Standard diff --git a/ksplashml/themeengine/standard/pics/Preview.png b/ksplashml/themeengine/standard/pics/Preview.png Binary files differindex 4fb01119e..ec936a18c 100644..100755 --- a/ksplashml/themeengine/standard/pics/Preview.png +++ b/ksplashml/themeengine/standard/pics/Preview.png diff --git a/ksplashml/themeengine/standard/themestandard.cpp b/ksplashml/themeengine/standard/themestandard.cpp index 8fd950eb5..c0fdff594 100644 --- a/ksplashml/themeengine/standard/themestandard.cpp +++ b/ksplashml/themeengine/standard/themestandard.cpp @@ -15,7 +15,7 @@ #include <tdeglobalsettings.h> #include <kiconloader.h> #include <tdelocale.h> -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include <tdeconfig.h> #include <tqdesktopwidget.h> @@ -75,7 +75,7 @@ void ThemeStandard::_initUi() resize( 0, 0 ); } - const TQRect rect = kapp->desktop()->screenGeometry( mTheme->xineramaScreen() ); + const TQRect rect = tdeApp->desktop()->screenGeometry( mTheme->xineramaScreen() ); // TDEGlobalSettings::splashScreenDesktopGeometry(); cannot be used here. move( rect.x() + (rect.width() - size().width())/2, diff --git a/ksplashml/themeengine/standard/themestandard.h b/ksplashml/themeengine/standard/themestandard.h index a1fb61ccf..3e9aabc63 100644 --- a/ksplashml/themeengine/standard/themestandard.h +++ b/ksplashml/themeengine/standard/themestandard.h @@ -42,7 +42,7 @@ */ class ThemeStandard: public ThemeEngine { - Q_OBJECT + TQ_OBJECT public: ThemeStandard( TQWidget *, const char*, const TQStringList& ); //inline const ThemeEngineConfig *config( TQWidget *p, TDEConfig *kc ) { return 0L; } diff --git a/ksplashml/themeengine/standard/wndicon.cpp b/ksplashml/themeengine/standard/wndicon.cpp index 856547895..9f12a5aed 100644 --- a/ksplashml/themeengine/standard/wndicon.cpp +++ b/ksplashml/themeengine/standard/wndicon.cpp @@ -65,12 +65,12 @@ WndIcon::WndIcon( TQPoint p = determinePosition(); mGroundX = mPosX = p.x(); mGroundY = mPosY = p.y(); - move( p + kapp->desktop()->screenGeometry( mXineramaScreen ).topLeft() ); + move( p + tdeApp->desktop()->screenGeometry( mXineramaScreen ).topLeft() ); if( mIconJumping ) { TQTimer *t = new TQTimer( this ); - connect(t, TQT_SIGNAL(timeout()), TQT_SLOT(slotJump())); + connect(t, TQ_SIGNAL(timeout()), TQ_SLOT(slotJump())); t->start( 50, false ); } } @@ -98,7 +98,7 @@ TQPoint WndIcon::determinePosition() int DW, DH, SBH, wid, X, Y, x, y, nSlot, topshift, bottomshift; bottomshift = topshift = 0; - const TQRect srect = kapp->desktop()->screenGeometry( mXineramaScreen ); + const TQRect srect = tdeApp->desktop()->screenGeometry( mXineramaScreen ); // TDEGlobalSettings::splashScreenDesktopGeometry(); cannot be used here. DW = srect.width(); DH = srect.height(); @@ -301,7 +301,7 @@ void WndIcon::slotJump() mPosY = (int)((float)mPosY - mVelocity ); break; } - move( TQPoint( mPosX, mPosY ) + kapp->desktop()->screenGeometry( mXineramaScreen ).topLeft() ); + move( TQPoint( mPosX, mPosY ) + tdeApp->desktop()->screenGeometry( mXineramaScreen ).topLeft() ); } void WndIcon::slotStopJumping() diff --git a/ksplashml/themeengine/standard/wndicon.h b/ksplashml/themeengine/standard/wndicon.h index 5338835a4..62f7d16ab 100644 --- a/ksplashml/themeengine/standard/wndicon.h +++ b/ksplashml/themeengine/standard/wndicon.h @@ -28,7 +28,7 @@ class WndIcon: public TQHBox { - Q_OBJECT + TQ_OBJECT public: enum Position diff --git a/ksplashml/themeengine/standard/wndstatus.cpp b/ksplashml/themeengine/standard/wndstatus.cpp index db397a055..9567a1028 100644 --- a/ksplashml/themeengine/standard/wndstatus.cpp +++ b/ksplashml/themeengine/standard/wndstatus.cpp @@ -46,7 +46,7 @@ WndStatus::WndStatus( TQPalette /*pal*/, setCursor( KCursor::blankCursor() ); setSpacing( 5 ); - const TQRect rect = kapp->desktop()->screenGeometry( xineramaScreen ); + const TQRect rect = tdeApp->desktop()->screenGeometry( xineramaScreen ); // TDEGlobalSettings::splashScreenDesktopGeometry(); cannot be used here. TQLabel *pix = new TQLabel( this ); diff --git a/ksplashml/themeengine/standard/wndstatus.h b/ksplashml/themeengine/standard/wndstatus.h index bc908779d..795181a09 100644 --- a/ksplashml/themeengine/standard/wndstatus.h +++ b/ksplashml/themeengine/standard/wndstatus.h @@ -27,7 +27,7 @@ class KProgress; class WndStatus: public TQHBox { - Q_OBJECT + TQ_OBJECT public: WndStatus( TQPalette, int, // Xinerama screen diff --git a/ksplashml/themeengine/themeengine.cpp b/ksplashml/themeengine/themeengine.cpp index 9a7d3aba5..e7e34866e 100644 --- a/ksplashml/themeengine/themeengine.cpp +++ b/ksplashml/themeengine/themeengine.cpp @@ -44,9 +44,9 @@ ThemeEngine::ThemeEngine( TQWidget *, const char *, const TQStringList& args ) : TQVBox( 0, "wndSplash", (WFlags)(WStyle_Customize|WX11BypassWM) ), d(0), mUseWM(false) { d = new ThemeEnginePrivate; - kapp->installX11EventFilter( this ); - kapp->installEventFilter( this ); - (void)kapp->desktop(); + tdeApp->installX11EventFilter( this ); + tdeApp->installEventFilter( this ); + (void)tdeApp->desktop(); XWindowAttributes rootAttr; XGetWindowAttributes(tqt_xdisplay(), RootWindow(tqt_xdisplay(), tqt_xscreen()), &rootAttr); @@ -77,7 +77,7 @@ ThemeEngine::~ThemeEngine() bool ThemeEngine::eventFilter( TQObject* o, TQEvent* e ) { if( e->type() == TQEvent::Show && o->isWidgetType()) - addSplashWindow( TQT_TQWIDGET( o )); + addSplashWindow( static_cast<TQWidget*>( o )); return false; } @@ -101,13 +101,13 @@ void ThemeEngine::addSplashWindow( TQWidget* w ) XChangeWindowAttributes( tqt_xdisplay(), w->winId(), CWOverrideRedirect, &attrs ); } d->mSplashWindows.prepend( w->winId()); - connect( w, TQT_SIGNAL( destroyed( TQObject* )), TQT_SLOT( splashWindowDestroyed( TQObject* ))); + connect( w, TQ_SIGNAL( destroyed( TQObject* )), TQ_SLOT( splashWindowDestroyed( TQObject* ))); w->raise(); } void ThemeEngine::splashWindowDestroyed( TQObject* obj ) { - d->mSplashWindows.remove( TQT_TQWIDGET( obj )->winId()); + d->mSplashWindows.remove( static_cast<TQWidget*>( obj )->winId()); } bool ThemeEngine::x11Event( XEvent* e ) diff --git a/ksplashml/themeengine/themeengine.h b/ksplashml/themeengine/themeengine.h index fa2f15a65..c1639ac74 100644 --- a/ksplashml/themeengine/themeengine.h +++ b/ksplashml/themeengine/themeengine.h @@ -16,7 +16,7 @@ #include <tqvbox.h> #include <tqwidget.h> -#include <kdemacros.h> +#include <tdemacros.h> class TDEConfig; class ObjKsTheme; @@ -25,9 +25,9 @@ class TQMouseEvent; /** * @short The base for the ThemeEngine's configuration widget. */ -class KDE_EXPORT ThemeEngineConfig: public TQVBox +class TDE_EXPORT ThemeEngineConfig: public TQVBox { - Q_OBJECT + TQ_OBJECT public: ThemeEngineConfig( TQWidget *p, TDEConfig *c ) @@ -48,9 +48,9 @@ protected: * @short Base class for all theme engines. Member functions need to be * overridden by derived classes in order to provide actual functionality. */ -class KDE_EXPORT ThemeEngine: public TQVBox +class TDE_EXPORT ThemeEngine: public TQVBox { - Q_OBJECT + TQ_OBJECT public: ThemeEngine( TQWidget *parent, const char *name, const TQStringList &args ); virtual ~ThemeEngine() = 0; diff --git a/ksplashml/themeengine/unified/themeunified.cpp b/ksplashml/themeengine/unified/themeunified.cpp index 0a2eb6343..26c59f87a 100644 --- a/ksplashml/themeengine/unified/themeunified.cpp +++ b/ksplashml/themeengine/unified/themeunified.cpp @@ -15,7 +15,7 @@ #include <kgenericfactory.h> #include <tdeglobalsettings.h> #include <tdelocale.h> -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include <kprogress.h> #include <tqcheckbox.h> @@ -77,7 +77,7 @@ void ThemeUnified::_initUi() mSysModalDialog->show(); mSysModalDialog->setActiveWindow(); - const TQRect rect = kapp->desktop()->screenGeometry( mTheme->xineramaScreen() ); + const TQRect rect = tdeApp->desktop()->screenGeometry( mTheme->xineramaScreen() ); // Center the dialog TQSize sh = sizeHint(); @@ -97,7 +97,7 @@ void ThemeUnified::_readSettings() cfg->setGroup( TQString("KSplash Theme: %1").arg(mTheme->theme()) ); - TQColor df(Qt::white); + TQColor df(TQt::white); mLabelForeground = cfg->readColorEntry( "Label Foreground", &df ); } diff --git a/ksplashml/themeengine/unified/themeunified.h b/ksplashml/themeengine/unified/themeunified.h index cd6a1d1ca..d002af4b0 100644 --- a/ksplashml/themeengine/unified/themeunified.h +++ b/ksplashml/themeengine/unified/themeunified.h @@ -28,7 +28,7 @@ class TQCheckBox; class UnifiedConfig: public ThemeEngineConfig { - Q_OBJECT + TQ_OBJECT public: UnifiedConfig( TQWidget *, TDEConfig * ); void save(); @@ -40,9 +40,9 @@ protected: * @short Traditional Trinity splash screen. */ class ObjKsTheme; -class KDE_EXPORT ThemeUnified : public ThemeEngine +class TDE_EXPORT ThemeUnified : public ThemeEngine { - Q_OBJECT + TQ_OBJECT public: ThemeUnified( TQWidget *, const char *, const TQStringList& ); virtual ~ThemeUnified(); diff --git a/ksplashml/wndmain.cpp b/ksplashml/wndmain.cpp index c37c6e214..eb0a1472a 100644 --- a/ksplashml/wndmain.cpp +++ b/ksplashml/wndmain.cpp @@ -19,7 +19,7 @@ #include <klibloader.h> #include <tdelocale.h> #include <tdemessagebox.h> -#include <kstandarddirs.h> +#include <tdestandarddirs.h> #include <ktrader.h> #include <twin.h> #include <dcopclient.h> @@ -46,7 +46,7 @@ KSplash::KSplash(const char *name) mSessMgrCalled = false; mTimeToGo = false; - TDEConfig * config = kapp->config(); + TDEConfig * config = tdeApp->config(); slotReadProperties(config); prepareSplashScreen(); @@ -55,27 +55,27 @@ KSplash::KSplash(const char *name) mCurrentAction = mActionList.first(); config->setGroup( "General" ); - if ( config->readBoolEntry( "CloseOnClick", TRUE ) ) + if ( config->readBoolEntry( "CloseOnClick", true ) ) mThemeEngine->installEventFilter( this ); - connect( mThemeEngine, TQT_SIGNAL(destroyed()), this, TQT_SLOT(close()) ); - connect( this, TQT_SIGNAL(stepsChanged(int)), TQT_SLOT(slotUpdateSteps(int)) ); - connect( this, TQT_SIGNAL(progressChanged(int)), TQT_SLOT(slotUpdateProgress(int)) ); + connect( mThemeEngine, TQ_SIGNAL(destroyed()), this, TQ_SLOT(close()) ); + connect( this, TQ_SIGNAL(stepsChanged(int)), TQ_SLOT(slotUpdateSteps(int)) ); + connect( this, TQ_SIGNAL(progressChanged(int)), TQ_SLOT(slotUpdateProgress(int)) ); if( mKsTheme->testing() ) { slotUpdateSteps(7); - TQTimer::singleShot( 1000, this, TQT_SLOT(slotExec())); + TQTimer::singleShot( 1000, this, TQ_SLOT(slotExec())); } else - TQTimer::singleShot( 100, this, TQT_SLOT(initDcop())); + TQTimer::singleShot( 100, this, TQ_SLOT(initDcop())); // Make sure we don't stay up forever. if (!mKsTheme->managedMode()) { close_timer = new TQTimer( this ); - connect( close_timer, TQT_SIGNAL( timeout() ), this, TQT_SLOT( close() ) ); - close_timer->start( 60000, TRUE ); + connect( close_timer, TQ_SIGNAL( timeout() ), this, TQ_SLOT( close() ) ); + close_timer->start( 60000, true ); } } @@ -133,14 +133,14 @@ void KSplash::slotInsertAction( const TQString& pix, const TQString& msg ) void KSplash::slotExec() { - TQTimer::singleShot( 200, this, TQT_SLOT(nextIcon())); + TQTimer::singleShot( 200, this, TQ_SLOT(nextIcon())); } void KSplash::nextIcon() { if( !mCurrentAction || mTimeToGo ) { - TQTimer::singleShot( 1000, this, TQT_SLOT(close())); + TQTimer::singleShot( 1000, this, TQ_SLOT(close())); return; } @@ -155,26 +155,26 @@ void KSplash::nextIcon() } if( mKsTheme->testing() ) - TQTimer::singleShot( 1000, this, TQT_SLOT(nextIcon())); + TQTimer::singleShot( 1000, this, TQ_SLOT(nextIcon())); } void KSplash::initDcop() { - disconnect( kapp->dcopClient(), TQT_SIGNAL( attachFailed(const TQString&) ), kapp, TQT_SLOT( dcopFailure(const TQString&) ) ); + disconnect( tdeApp->dcopClient(), TQ_SIGNAL( attachFailed(const TQString&) ), tdeApp, TQ_SLOT( dcopFailure(const TQString&) ) ); - if ( kapp->dcopClient()->isAttached() ) + if ( tdeApp->dcopClient()->isAttached() ) return; - if ( kapp->dcopClient()->attach() ) + if ( tdeApp->dcopClient()->attach() ) { if(!mKsTheme->managedMode()) upAndRunning( "dcop" ); - kapp->dcopClient()->registerAs( "ksplash", false ); - kapp->dcopClient()->setDefaultObject( objId() ); + tdeApp->dcopClient()->registerAs( "ksplash", false ); + tdeApp->dcopClient()->setDefaultObject( objId() ); } else { - TQTimer::singleShot( 100, this, TQT_SLOT(initDcop()) ); + TQTimer::singleShot( 100, this, TQ_SLOT(initDcop()) ); } } @@ -206,7 +206,7 @@ void KSplash::upAndRunning( TQString s ) firstTime = false; } if ( close_timer->isActive() ) - close_timer->start( 60000, TRUE ); + close_timer->start( 60000, true ); if( s == "dcop" ) { @@ -247,7 +247,7 @@ void KSplash::upAndRunning( TQString s ) //if(!mSessMgrCalled) emit nextIcon(); mTimeToGo = true; close_timer->stop(); - TQTimer::singleShot( 1000, this, TQT_SLOT(close())); + TQTimer::singleShot( 1000, this, TQ_SLOT(close())); } else { @@ -307,15 +307,12 @@ void KSplash::setStartupItemCount( int count ) void KSplash::startupComplete() { mTimeToGo = true; - TQTimer::singleShot( 1000, this, TQT_SLOT(close())); + TQTimer::singleShot( 1000, this, TQ_SLOT(close())); } void KSplash::close() { TQWidget::close(); -#ifdef USE_QT4 - exit(0); -#endif // USE_QT4 } void KSplash::hide() @@ -386,7 +383,7 @@ ThemeEngine *KSplash::_loadThemeEngine( const TQString& pluginName, const TQStri { TQStringList themeTitle; themeTitle << theme; - return static_cast<ThemeEngine *>(TQT_TQWIDGET(factory->create(TQT_TQOBJECT(this), "theme", objName.latin1(), themeTitle))); + return static_cast<ThemeEngine *>(factory->create(this, "theme", objName.latin1(), themeTitle)); } else return 0L; @@ -427,11 +424,11 @@ TQPtrList<Action> KSplash::actionList() bool KSplash::eventFilter( TQObject *o, TQEvent *e ) { - if ( ( e->type() == TQEvent::MouseButtonRelease ) && ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(mThemeEngine) ) ) + if ( ( e->type() == TQEvent::MouseButtonRelease ) && ( o == mThemeEngine ) ) { - TQTimer::singleShot( 0, this, TQT_SLOT(close())); - return TRUE; + TQTimer::singleShot( 0, this, TQ_SLOT(close())); + return true; } else - return FALSE; + return false; } diff --git a/ksplashml/wndmain.h b/ksplashml/wndmain.h index 563598c64..a5ad616b2 100644 --- a/ksplashml/wndmain.h +++ b/ksplashml/wndmain.h @@ -38,7 +38,7 @@ class TDEConfig; class KSplash: public TQWidget, virtual public KSplashIface { - Q_OBJECT + TQ_OBJECT public: @@ -56,17 +56,7 @@ public: ASYNC startupComplete(); ASYNC show(); ASYNC hide(); - - // [FIXME] How can I more easily let Qt know about these slots? moc-tqt perhaps? - // More importantly, how was this code even running under Qt3? - // Was it somehow running the TQWidget::close() slot instead of the KSplash::close() non-slot method? - // Either way it looks like accidental/undefined behaviour to me... -#ifndef Q_MOC_RUN ASYNC close(); -#else // Q_MOC_RUN -public slots: - void close(); -#endif // Q_MOC_RUN signals: void stepsChanged(int); |