diff --git a/kcmkwin/kwinrules/CMakeLists.txt b/kcmkwin/kwinrules/CMakeLists.txt index 4f7029eeac..695fc8bad4 100644 --- a/kcmkwin/kwinrules/CMakeLists.txt +++ b/kcmkwin/kwinrules/CMakeLists.txt @@ -7,7 +7,8 @@ ADD_DEFINITIONS(-DKCMRULES) ########### next target ############### set(kwinrules_SRCS ruleswidget.cpp ruleslist.cpp kwinsrc.cpp detectwidget.cpp) -kde4_add_ui3_files(kwinrules_SRCS ruleswidgetbase.ui ruleslistbase.ui detectwidgetbase.ui editshortcutbase.ui ) +kde4_add_ui_files(kwinrules_SRCS ruleslistbase.ui detectwidgetbase.ui) +kde4_add_ui3_files(kwinrules_SRCS ruleswidgetbase.ui editshortcutbase.ui ) set(kwin_rules_dialog_KDEINIT_SRCS main.cpp ${kwinrules_SRCS}) diff --git a/kcmkwin/kwinrules/detectwidget.cpp b/kcmkwin/kwinrules/detectwidget.cpp index eafa8582b0..bd3f371dbf 100644 --- a/kcmkwin/kwinrules/detectwidget.cpp +++ b/kcmkwin/kwinrules/detectwidget.cpp @@ -40,8 +40,8 @@ namespace KWin { -DetectWidget::DetectWidget( QWidget* parent, const char* name ) -: DetectWidgetBase( parent, name ) +DetectWidget::DetectWidget( QWidget* parent ) +: DetectWidgetBase( parent ) { } diff --git a/kcmkwin/kwinrules/detectwidget.h b/kcmkwin/kwinrules/detectwidget.h index eabd3144f0..f844288656 100644 --- a/kcmkwin/kwinrules/detectwidget.h +++ b/kcmkwin/kwinrules/detectwidget.h @@ -20,7 +20,7 @@ #ifndef __DETECTWIDGET_H__ #define __DETECTWIDGET_H__ -#include "detectwidgetbase.h" +#include "ui_detectwidgetbase.h" #include #include @@ -33,12 +33,21 @@ namespace KWin { +class DetectWidgetBase : public QWidget, public Ui::DetectWidgetBase +{ +public: + DetectWidgetBase( QWidget *parent ) : QWidget( parent ) { + setupUi( this ); + } +}; + + class DetectWidget : public DetectWidgetBase { Q_OBJECT public: - DetectWidget( QWidget* parent = NULL, const char* name = NULL ); + DetectWidget( QWidget* parent = NULL ); }; class DetectDialog diff --git a/kcmkwin/kwinrules/detectwidgetbase.ui b/kcmkwin/kwinrules/detectwidgetbase.ui index d40ed18b8f..bcf683e076 100644 --- a/kcmkwin/kwinrules/detectwidgetbase.ui +++ b/kcmkwin/kwinrules/detectwidgetbase.ui @@ -1,218 +1,232 @@ - -KWin::DetectWidgetBase - - - DetectWidgetBase + + + + + KWin::DetectWidgetBase + + + + 0 + 0 + 523 + 325 + - - - 0 - 0 - 523 - 325 - - - - - unnamed - - - 0 - - - - spacer1 - - - Qt::Vertical - - - Expanding - - - - 20 - 40 - - + + + 0 + + + + + + 20 + 40 + + + + Expanding + + + Qt::Vertical + - - - textLabel11 - - - Extra role: - + + + + + Extra role: + + + false + - - - textLabel1 - - - Class: - + + + + + Class: + + + false + - - - textLabel3 - - - Role: - + + + + + Role: + + + false + - - - type_label - - - - + + + + + + + + false + - - - textLabel8 - - - Title: - + + + + + Title: + + + false + - - - class_label - - - - + + + + + + + + false + - - - role_label - - - - + + + + + + + + false + - - - title_label - - - - + + + + + + + + false + - - - machine_label - - - - + + + + + + + + false + - - - textLabel4 - - - Type: - + + + + + Type: + + + false + - - - extrarole_label - - - - + + + + + + + + false + - - - textLabel13 - - - Machine: - + + + + + Machine: + + + false + - - - line1 - - - HLine - - - Sunken - - - Qt::Horizontal - + + + + + QFrame::HLine + + + QFrame::Sunken + - - - textLabel9 - - - Information About Selected Window - + + + + + Information About Selected Window + + + false + - - - buttonGroup1 + + + + + + + + + 0 - - - - - - unnamed + + + + Use window &class (whole application) - - - use_class - - - Use window &class (whole application) - - - true - - - For selecting all windows belonging to a specific application, selecting only window class should usually work. - - - - - use_role - - - Use window class and window &role (specific window) - - - For selecting a specific window in an application, both window class and window role should be selected. Window class will determine the application, and window role the specific window in the application; many applications do not provide useful window roles though. - - - - - use_whole_class - - - Use &whole window class (specific window) - - - With some (non-KDE) applications whole window class can be sufficient for selecting a specific window in an application, as they set whole window class to contain both application and window role. - - - - - match_title - - - Match also window &title - - - + + true + + + For selecting all windows belonging to a specific application, selecting only window class should usually work. + + + + + + + Use window class and window &role (specific window) + + + For selecting a specific window in an application, both window class and window role should be selected. Window class will determine the application, and window role the specific window in the application; many applications do not provide useful window roles though. + + + + + + + Use &whole window class (specific window) + + + With some (non-KDE) applications whole window class can be sufficient for selecting a specific window in an application, as they set whole window class to contain both application and window role. + + + + + + + Match also window &title + + + + - - - - - + + + + + + qPixmapFromMimeSource + diff --git a/kcmkwin/kwinrules/ruleslist.cpp b/kcmkwin/kwinrules/ruleslist.cpp index b3aa5c79c2..7a8130a56a 100644 --- a/kcmkwin/kwinrules/ruleslist.cpp +++ b/kcmkwin/kwinrules/ruleslist.cpp @@ -28,8 +28,8 @@ namespace KWin { -KCMRulesList::KCMRulesList( QWidget* parent, const char* name ) -: KCMRulesListBase( parent, name ) +KCMRulesList::KCMRulesList( QWidget* parent) +: KCMRulesListBase( parent) { // connect both current/selected, so that current==selected (stupid QListBox :( ) connect( rules_listbox, SIGNAL( currentChanged( Q3ListBoxItem* )), diff --git a/kcmkwin/kwinrules/ruleslist.h b/kcmkwin/kwinrules/ruleslist.h index b5a8595647..4ab3a43530 100644 --- a/kcmkwin/kwinrules/ruleslist.h +++ b/kcmkwin/kwinrules/ruleslist.h @@ -20,7 +20,7 @@ #ifndef __RULESLIST_H__ #define __RULESLIST_H__ -#include "ruleslistbase.h" +#include "ui_ruleslistbase.h" @@ -31,12 +31,21 @@ class Q3ListBoxItem; namespace KWin { +class KCMRulesListBase : public QWidget, public Ui::KCMRulesListBase +{ +public: + KCMRulesListBase( QWidget *parent ) : QWidget( parent ) { + setupUi( this ); + } +}; + + class KCMRulesList : public KCMRulesListBase { Q_OBJECT public: - KCMRulesList( QWidget* parent = NULL, const char* name = NULL ); + KCMRulesList( QWidget* parent = NULL ); virtual ~KCMRulesList(); void load(); void save(); diff --git a/kcmkwin/kwinrules/ruleslistbase.ui b/kcmkwin/kwinrules/ruleslistbase.ui index 1df3eef173..2bd4cd1dce 100644 --- a/kcmkwin/kwinrules/ruleslistbase.ui +++ b/kcmkwin/kwinrules/ruleslistbase.ui @@ -1,95 +1,91 @@ - -KWin::KCMRulesListBase - - - KCMRulesListBase + + + + + KWin::KCMRulesListBase + + + + 0 + 0 + 600 + 480 + - - - 0 - 0 - 600 - 480 - - - - - unnamed - - - 0 - - - - rules_listbox - + + + 0 + + + + + + + + &New... + - - - new_button - - - &New... - + + + + + &Modify... + - - - modify_button - - - &Modify... - + + + + + Delete + + + + - - - delete_button - - - Delete - - - - + + + + + Move &Up + - - - moveup_button - - - Move &Up - + + + + + Move &Down + - - - movedown_button - - - Move &Down - - - - - spacer1 - - - Vertical - - - Expanding - - - - 20 - 294 - - + + + + + + 20 + 294 + + + + Expanding + + + Vertical + - - - - - - kdialog.h - - - + + + + + + qPixmapFromMimeSource + + + K3ListBox + Q3ListBox +
k3listbox.h
+
+
+ + kdialog.h + +