From 33bde816008f483c2cc4b2f375f2f7abec2dfae6 Mon Sep 17 00:00:00 2001 From: Stefan Hundhammer Date: Thu, 9 Jul 2020 18:38:25 +0200 Subject: [PATCH 1/6] Added menu bar --- SOURCECONF.cmake | 2 + src/YQMenuBar.cc | 213 +++++++++++++++++++++++++++++++++++++++++ src/YQMenuBar.h | 134 ++++++++++++++++++++++++++ src/YQWidgetFactory.cc | 10 ++ src/YQWidgetFactory.h | 2 + 5 files changed, 361 insertions(+) create mode 100644 src/YQMenuBar.cc create mode 100644 src/YQMenuBar.h diff --git a/SOURCECONF.cmake b/SOURCECONF.cmake index 95d07c41..a0879c9d 100644 --- a/SOURCECONF.cmake +++ b/SOURCECONF.cmake @@ -38,6 +38,7 @@ SET( ${TARGETLIB}_SOURCES YQLayoutBox.cc YQLogView.cc YQMainWinDock.cc + YQMenuBar.cc YQMenuButton.cc YQMultiLineEdit.cc YQMultiProgressMeter.cc @@ -107,6 +108,7 @@ SET( ${TARGETLIB}_HEADERS YQLayoutBox.h YQLogView.h YQMainWinDock.h + YQMenuBar.h YQMenuButton.h YQMultiLineEdit.h YQMultiProgressMeter.h diff --git a/src/YQMenuBar.cc b/src/YQMenuBar.cc new file mode 100644 index 00000000..9eabc6c3 --- /dev/null +++ b/src/YQMenuBar.cc @@ -0,0 +1,213 @@ +/* + Copyright (C) 2020 SUSE LLC + This library is free software; you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) version 3.0 of the License. This library + 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 Lesser General Public + License for more details. You should have received a copy of the GNU + Lesser General Public License along with this library; if not, write + to the Free Software Foundation, Inc., 51 Franklin Street, Fifth + Floor, Boston, MA 02110-1301 USA +*/ + + +/*-/ + + File: YQMenuBar.cc + + Author: Stefan Hundhammer + +/-*/ + + +#include +#include +#define YUILogComponent "qt-ui" +#include + +#include "utf8.h" +#include "YQUI.h" +#include "YQMenuBar.h" +#include "YQSignalBlocker.h" +#include + +using std::string; + + + +YQMenuBar::YQMenuBar( YWidget * parent ) + : QMenuBar( (QWidget *) parent->widgetRep() ) + , YMenuBar( parent ) + , _selectedItem( 0 ) +{ + setWidgetRep( this ); +} + + +YQMenuBar::~YQMenuBar() +{ + // NOP +} + + +void +YQMenuBar::rebuildMenuTree() +{ + // + // Delete any previous menus + // (in case the menu items got replaced) + // + + QMenuBar::clear(); + _actionMap.clear(); + _selectedItem = 0; + + + // + // Create toplevel menus + // + + for ( YItemIterator it = itemsBegin(); it != itemsEnd(); ++it ) + { + YItem * item = *it; + + if ( ! item->hasChildren() ) + YUI_THROW( YUIException( "YQMenuBar: Only menus allowed on toplevel." ) ); + + QMenu * menu = addMenu( fromUTF8( item->label() )); + YUI_CHECK_NEW( menu ); + + connect( menu, &pclass(menu)::triggered, + this, &pclass(this)::menuEntryActivated ); + + // Recursively add menu content + rebuildMenuTree( menu, item->childrenBegin(), item->childrenEnd() ); + } +} + + +void +YQMenuBar::rebuildMenuTree( QMenu * parentMenu, YItemIterator begin, YItemIterator end ) +{ + for ( YItemIterator it = begin; it != end; ++it ) + { + YItem * item = *it; + QIcon icon; + + if ( item->hasIconName() ) + icon = YQUI::ui()->loadIcon( item->iconName() ); + + if ( item->hasChildren() ) + { + QMenu * subMenu = parentMenu->addMenu( fromUTF8( item->label() )); + + if ( ! icon.isNull() ) + subMenu->setIcon( icon ); + + connect( subMenu, &pclass(subMenu)::triggered, + this, &pclass(this)::menuEntryActivated ); + + rebuildMenuTree( subMenu, item->childrenBegin(), item->childrenEnd() ); + } + else // No children - leaf entry + { + // item->index() is guaranteed to be unique within this YMenuBar's items, + // so it can easily be used as unique ID in all Q3PopupMenus that belong + // to this YQMenuBar. + + QAction * action = parentMenu->addAction( fromUTF8( item->label() ) ); + _actionMap[ action ] = item; + + if ( ! icon.isNull() ) + action->setIcon( icon ); + } + } +} + + +void +YQMenuBar::menuEntryActivated( QAction * action ) +{ + if ( _actionMap.contains( action ) ) + _selectedItem = _actionMap[ action ]; + + if ( _selectedItem ) + { + yuiDebug() << "Selected menu entry \"" << fromUTF8( _selectedItem->label() ) << "\"" << endl; + + /* + * Defer the real returnNow() until all popup related events have been + * processed. This took me some hours to figure out; obviously + * exit_loop() doesn't have any effect as long as there are still + * popups open. So be it - use a zero timer to perform the real + * returnNow() later. + */ + + /* + * the 100 delay is a ugly dirty workaround + */ + QTimer::singleShot( 100, this, SLOT( returnNow() ) ); + } + else + { + yuiError() << "Unknown action \"" << action->text() << "\"" << endl; + } +} + + +void +YQMenuBar::returnNow() +{ + if ( _selectedItem ) + { + YQUI::ui()->sendEvent( new YMenuEvent( _selectedItem ) ); + _selectedItem = 0; + } +} + + + +void +YQMenuBar::setEnabled( bool enabled ) +{ + YWidget::setEnabled( enabled ); +} + + +int YQMenuBar::preferredWidth() +{ + return sizeHint().width(); +} + + +int YQMenuBar::preferredHeight() +{ + return sizeHint().height(); +} + + +void +YQMenuBar::setSize( int newWidth, int newHeight ) +{ + QWidget::resize( newWidth, newHeight ); +} + + +bool +YQMenuBar::setKeyboardFocus() +{ + QWidget::setFocus(); + + return true; +} + + +void +YQMenuBar::activateItem( YMenuItem * item ) +{ + if ( item ) + YQUI::ui()->sendEvent( new YMenuEvent( item ) ); +} diff --git a/src/YQMenuBar.h b/src/YQMenuBar.h new file mode 100644 index 00000000..4c8999aa --- /dev/null +++ b/src/YQMenuBar.h @@ -0,0 +1,134 @@ +/* + Copyright (C) 2020 SUSE LLC + This library is free software; you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation; either version 2.1 of the + License, or (at your option) version 3.0 of the License. This library + 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 Lesser General Public + License for more details. You should have received a copy of the GNU + Lesser General Public License along with this library; if not, write + to the Free Software Foundation, Inc., 51 Franklin Street, Fifth + Floor, Boston, MA 02110-1301 USA +*/ + + +/*-/ + + File: YQMenuBar.h + + Author: Stefan Hundhammer + +/-*/ + + +#ifndef YQMenuBar_h +#define YQMenuBar_h + +#include +#include +#include + +class QAction; +class QPushButton; +class QMenu; + +class YQMenuBar : public QMenuBar, public YMenuBar +{ + Q_OBJECT + +public: + /** + * Constructor. + **/ + YQMenuBar( YWidget * parent ); + + /** + * Destructor. + **/ + virtual ~YQMenuBar(); + + /** + * Rebuild the displayed menu tree from the internally stored YMenuItems. + * + * Implemented from YMenuBar. + **/ + virtual void rebuildMenuTree(); + + /** + * Set enabled / disabled state. + * + * Reimplemented from YWidget. + **/ + virtual void setEnabled( bool enabled ); + + /** + * Preferred width of the widget. + * + * Reimplemented from YWidget. + **/ + virtual int preferredWidth(); + + /** + * Preferred height of the widget. + * + * Reimplemented from YWidget. + **/ + virtual int preferredHeight(); + + /** + * Set the new size of the widget. + * + * Reimplemented from YWidget. + **/ + virtual void setSize( int newWidth, int newHeight ); + + /** + * Accept the keyboard focus. + **/ + virtual bool setKeyboardFocus(); + + /** + * Activate the item selected in the tree. Can be used in tests to simulate + * user input. + * + * Derived classes are required to implement this. + **/ + virtual void activateItem( YMenuItem * item ); + + +protected slots: + + /** + * Triggered when any menu item is activated. + **/ + void menuEntryActivated( QAction * menuItem ); + + /** + * Triggered via menuEntryActivated() by zero timer to get back in sync + * with the Qt event loop. + **/ + void returnNow(); + + +protected: + + /** + * Recursively insert menu items into 'menu' from iterator 'begin' to + * iterator 'end'. + **/ + void rebuildMenuTree( QMenu * menu, + YItemIterator begin, + YItemIterator end ); + + + // + // Data members + // + + YItem * _selectedItem; + QMap _actionMap; +}; + +#endif // YQMenuBar_h diff --git a/src/YQWidgetFactory.cc b/src/YQWidgetFactory.cc index 7f4c2b9c..da8edb9e 100644 --- a/src/YQWidgetFactory.cc +++ b/src/YQWidgetFactory.cc @@ -251,6 +251,16 @@ YQWidgetFactory::createMenuButton( YWidget * parent, const string & label ) } +YQMenuBar * +YQWidgetFactory::createMenuBar( YWidget * parent ) +{ + YQMenuBar * menuBar = new YQMenuBar( parent ); + YUI_CHECK_NEW( menuBar ); + + return menuBar; +} + + YQMultiLineEdit * YQWidgetFactory::createMultiLineEdit( YWidget * parent, const string & label ) { diff --git a/src/YQWidgetFactory.h b/src/YQWidgetFactory.h index 97afc802..a04e993d 100644 --- a/src/YQWidgetFactory.h +++ b/src/YQWidgetFactory.h @@ -44,6 +44,7 @@ #include "YQLabel.h" #include "YQLayoutBox.h" #include "YQLogView.h" +#include "YQMenuBar.h" #include "YQMenuButton.h" #include "YQMultiLineEdit.h" #include "YQMultiSelectionBox.h" @@ -148,6 +149,7 @@ class YQWidgetFactory: public YWidgetFactory virtual YQItemSelector * createItemSelector ( YWidget * parent, bool enforceSingleSelection = true ); virtual YQCustomStatusItemSelector * createCustomStatusItemSelector ( YWidget * parent, const YItemCustomStatusVector & customStates ); + virtual YQMenuBar * createMenuBar ( YWidget * parent ); protected: From a156c9dfa818b34ca65661cb2326178935c0cd69 Mon Sep 17 00:00:00 2001 From: Stefan Hundhammer Date: Mon, 13 Jul 2020 15:36:54 +0200 Subject: [PATCH 2/6] Consistency and support for menu separators --- src/YQMenuBar.cc | 28 ++++++++++++----------- src/YQMenuBar.h | 4 ++-- src/YQMenuButton.cc | 54 ++++++++++++++++++++++----------------------- src/YQMenuButton.h | 8 +++---- 4 files changed, 47 insertions(+), 47 deletions(-) diff --git a/src/YQMenuBar.cc b/src/YQMenuBar.cc index 9eabc6c3..8351a2e4 100644 --- a/src/YQMenuBar.cc +++ b/src/YQMenuBar.cc @@ -72,12 +72,13 @@ YQMenuBar::rebuildMenuTree() for ( YItemIterator it = itemsBegin(); it != itemsEnd(); ++it ) { - YItem * item = *it; + YMenuItem * item = dynamic_cast( *it ); + YUI_CHECK_PTR( item ); - if ( ! item->hasChildren() ) + if ( ! item->isMenu() ) YUI_THROW( YUIException( "YQMenuBar: Only menus allowed on toplevel." ) ); - QMenu * menu = addMenu( fromUTF8( item->label() )); + QMenu * menu = QMenuBar::addMenu( fromUTF8( item->label() )); YUI_CHECK_NEW( menu ); connect( menu, &pclass(menu)::triggered, @@ -94,13 +95,18 @@ YQMenuBar::rebuildMenuTree( QMenu * parentMenu, YItemIterator begin, YItemIterat { for ( YItemIterator it = begin; it != end; ++it ) { - YItem * item = *it; - QIcon icon; + YMenuItem * item = dynamic_cast( *it ); + YUI_CHECK_PTR( item ); + QIcon icon; if ( item->hasIconName() ) icon = YQUI::ui()->loadIcon( item->iconName() ); - if ( item->hasChildren() ) + if ( item->isSeparator() ) + { + parentMenu->addSeparator(); + } + else if ( item->isMenu() ) { QMenu * subMenu = parentMenu->addMenu( fromUTF8( item->label() )); @@ -112,12 +118,8 @@ YQMenuBar::rebuildMenuTree( QMenu * parentMenu, YItemIterator begin, YItemIterat rebuildMenuTree( subMenu, item->childrenBegin(), item->childrenEnd() ); } - else // No children - leaf entry + else // Plain menu item (leaf item) { - // item->index() is guaranteed to be unique within this YMenuBar's items, - // so it can easily be used as unique ID in all Q3PopupMenus that belong - // to this YQMenuBar. - QAction * action = parentMenu->addAction( fromUTF8( item->label() ) ); _actionMap[ action ] = item; @@ -136,7 +138,7 @@ YQMenuBar::menuEntryActivated( QAction * action ) if ( _selectedItem ) { - yuiDebug() << "Selected menu entry \"" << fromUTF8( _selectedItem->label() ) << "\"" << endl; + // yuiDebug() << "Selected menu entry \"" << fromUTF8( _selectedItem->label() ) << "\"" << endl; /* * Defer the real returnNow() until all popup related events have been @@ -147,7 +149,7 @@ YQMenuBar::menuEntryActivated( QAction * action ) */ /* - * the 100 delay is a ugly dirty workaround + * The 100 delay is a ugly dirty workaround. */ QTimer::singleShot( 100, this, SLOT( returnNow() ) ); } diff --git a/src/YQMenuBar.h b/src/YQMenuBar.h index 4c8999aa..90a54fc0 100644 --- a/src/YQMenuBar.h +++ b/src/YQMenuBar.h @@ -127,8 +127,8 @@ protected slots: // Data members // - YItem * _selectedItem; - QMap _actionMap; + YMenuItem * _selectedItem; + QMap _actionMap; }; #endif // YQMenuBar_h diff --git a/src/YQMenuButton.cc b/src/YQMenuButton.cc index c3e1e480..cf987089 100644 --- a/src/YQMenuButton.cc +++ b/src/YQMenuButton.cc @@ -47,7 +47,6 @@ YQMenuButton::YQMenuButton( YWidget * parent, { setWidgetRep( this ); _qt_button = new QPushButton( fromUTF8( label ), this ); - // _qt_button->setMinimumSize( 2,2 ); _qt_button->move( YQButtonBorder, YQButtonBorder ); setMinimumSize( _qt_button->minimumSize() + 2 * QSize( YQButtonBorder, YQButtonBorder ) ); @@ -76,9 +75,13 @@ YQMenuButton::rebuildMenuTree() // (in case the menu items got replaced) // + _actionMap.clear(); + _selectedItem = 0; + if ( _qt_button->menu() ) delete _qt_button->menu(); + // // Create toplevel menu // @@ -104,59 +107,55 @@ YQMenuButton::rebuildMenuTree( QMenu * parentMenu, YItemIterator begin, YItemIte { for ( YItemIterator it = begin; it != end; ++it ) { - YItem * item = *it; + YMenuItem * item = dynamic_cast( *it ); + YUI_CHECK_PTR( item ); QIcon icon; if ( item->hasIconName() ) - { icon = YQUI::ui()->loadIcon( item->iconName() ); - } - if ( item->hasChildren() ) + if ( item->isSeparator() ) + { + parentMenu->addSeparator(); + } + else if ( item->isMenu() ) { - QMenu * subMenu; + QMenu * subMenu = parentMenu->addMenu( fromUTF8( item->label() )); - if ( icon.isNull() ) - subMenu = parentMenu->addMenu( fromUTF8( item->label() )); - else - subMenu = parentMenu->addMenu( icon, fromUTF8( item->label() )); + if ( ! icon.isNull() ) + subMenu->setIcon( icon ); connect( subMenu, &pclass(subMenu)::triggered, this, &pclass(this)::menuEntryActivated ); rebuildMenuTree( subMenu, item->childrenBegin(), item->childrenEnd() ); } - else // No children - leaf entry + else // Plain menu item (leaf item) { // item->index() is guaranteed to be unique within this YMenuButton's items, // so it can easily be used as unique ID in all Q3PopupMenus that belong // to this YQMenuButton. - QAction *act; + QAction * action = parentMenu->addAction( fromUTF8( item->label() ) ); + _actionMap[ action ] = item; - if ( icon.isNull() ) - act = parentMenu->addAction( fromUTF8( item->label() ) ); - else - act = parentMenu->addAction( icon, fromUTF8( item->label() ) ); - - _serials[act] = item->index(); + if ( ! icon.isNull() ) + action->setIcon( icon ); } } } void -YQMenuButton::menuEntryActivated( QAction* action ) +YQMenuButton::menuEntryActivated( QAction * action ) { - int serialNo = -1; - if ( _serials.contains( action ) ) - serialNo = _serials[action]; - - // yuiDebug() << "Selected menu entry #" << menu_item_index << endl; - _selectedItem = findMenuItem( serialNo ); + if ( _actionMap.contains( action ) ) + _selectedItem = _actionMap[ action ]; if ( _selectedItem ) { + // yuiDebug() << "Selected menu entry \"" << fromUTF8( _selectedItem->label() ) << "\"" << endl; + /* * Defer the real returnNow() until all popup related events have been * processed. This took me some hours to figure out; obviously @@ -166,13 +165,13 @@ YQMenuButton::menuEntryActivated( QAction* action ) */ /* - * the 100 delay is a ugly dirty workaround + * The 100 delay is a ugly dirty workaround. */ QTimer::singleShot( 100, this, SLOT( returnNow() ) ); } else { - yuiError() << "No menu item with serial no. " << serialNo << endl; + yuiError() << "Unknown action \"" << action->text() << "\"" << endl; } } @@ -188,7 +187,6 @@ YQMenuButton::returnNow() } - void YQMenuButton::setEnabled( bool enabled ) { diff --git a/src/YQMenuButton.h b/src/YQMenuButton.h index 51601c83..887a9551 100644 --- a/src/YQMenuButton.h +++ b/src/YQMenuButton.h @@ -28,7 +28,7 @@ #include #include -#include +#include class QAction; class QPushButton; @@ -130,9 +130,9 @@ protected slots: // Data members // - YMenuItem * _selectedItem; - QPushButton * _qt_button; - QHash _serials; + QPushButton * _qt_button; + YMenuItem * _selectedItem; + QMap _actionMap; }; #endif // YQMenuButton_h From 95f606ce95f40a4ba90810be32cb1d22695a6a3f Mon Sep 17 00:00:00 2001 From: Stefan Hundhammer Date: Tue, 14 Jul 2020 10:47:23 +0200 Subject: [PATCH 3/6] Fixed outdated old e-mail address --- src/QY2CharValidator.cc | 2 +- src/QY2CharValidator.h | 2 +- src/QY2ComboTabWidget.cc | 2 +- src/QY2ComboTabWidget.h | 2 +- src/QY2DiskUsageList.cc | 2 +- src/QY2DiskUsageList.h | 2 +- src/QY2ListView.cc | 2 +- src/QY2ListView.h | 2 +- src/YQAlignment.cc | 2 +- src/YQAlignment.h | 2 +- src/YQApplication.cc | 2 +- src/YQApplication.h | 2 +- src/YQBarGraph.cc | 2 +- src/YQBarGraph.h | 2 +- src/YQButtonBox.cc | 2 +- src/YQButtonBox.h | 2 +- src/YQCheckBox.cc | 2 +- src/YQCheckBox.h | 2 +- src/YQCheckBoxFrame.cc | 2 +- src/YQCheckBoxFrame.h | 2 +- src/YQComboBox.cc | 2 +- src/YQComboBox.h | 2 +- src/YQDateField.cc | 2 +- src/YQDateField.h | 2 +- src/YQDialog.cc | 2 +- src/YQDialog.h | 2 +- src/YQDownloadProgress.cc | 2 +- src/YQDownloadProgress.h | 2 +- src/YQDumbTab.cc | 2 +- src/YQDumbTab.h | 2 +- src/YQEmpty.cc | 2 +- src/YQEmpty.h | 2 +- src/YQFrame.cc | 2 +- src/YQFrame.h | 2 +- src/YQGenericButton.cc | 2 +- src/YQGenericButton.h | 2 +- src/YQImage.cc | 2 +- src/YQImage.h | 2 +- src/YQInputField.cc | 2 +- src/YQInputField.h | 2 +- src/YQIntField.cc | 2 +- src/YQIntField.h | 2 +- src/YQLabel.cc | 2 +- src/YQLabel.h | 2 +- src/YQLayoutBox.cc | 2 +- src/YQLayoutBox.h | 2 +- src/YQLogView.cc | 2 +- src/YQLogView.h | 2 +- src/YQMainWinDock.cc | 2 +- src/YQMainWinDock.h | 2 +- src/YQMenuButton.cc | 2 +- src/YQMenuButton.h | 2 +- src/YQMultiLineEdit.cc | 2 +- src/YQMultiLineEdit.h | 2 +- src/YQMultiProgressMeter.cc | 2 +- src/YQMultiProgressMeter.h | 2 +- src/YQMultiSelectionBox.cc | 2 +- src/YQMultiSelectionBox.h | 2 +- src/YQOptionalWidgetFactory.cc | 2 +- src/YQOptionalWidgetFactory.h | 2 +- src/YQPartitionSplitter.cc | 2 +- src/YQPartitionSplitter.h | 2 +- src/YQProgressBar.cc | 2 +- src/YQProgressBar.h | 2 +- src/YQPushButton.cc | 2 +- src/YQPushButton.h | 2 +- src/YQRadioButton.cc | 2 +- src/YQRadioButton.h | 2 +- src/YQRadioButtonGroup.cc | 2 +- src/YQRadioButtonGroup.h | 2 +- src/YQReplacePoint.cc | 2 +- src/YQReplacePoint.h | 2 +- src/YQRichText.cc | 2 +- src/YQRichText.h | 2 +- src/YQSelectionBox.cc | 2 +- src/YQSelectionBox.h | 2 +- src/YQSignalBlocker.cc | 2 +- src/YQSignalBlocker.h | 2 +- src/YQSlider.cc | 2 +- src/YQSlider.h | 2 +- src/YQSpacing.cc | 2 +- src/YQSpacing.h | 2 +- src/YQSquash.cc | 2 +- src/YQSquash.h | 2 +- src/YQTable.cc | 2 +- src/YQTable.h | 2 +- src/YQTimeField.cc | 2 +- src/YQTimeField.h | 2 +- src/YQTimezoneSelector.h | 2 +- src/YQTree.cc | 2 +- src/YQTree.h | 2 +- src/YQUI.cc | 2 +- src/YQUI.h | 2 +- src/YQUI_builtins.cc | 2 +- src/YQWidgetCaption.cc | 2 +- src/YQWidgetCaption.h | 2 +- src/YQWidgetFactory.cc | 2 +- src/YQWidgetFactory.h | 2 +- src/YQWizard.cc | 2 +- src/YQWizard.h | 2 +- src/YQWizardButton.cc | 2 +- src/YQWizardButton.h | 2 +- src/YQi18n.h | 2 +- src/utf8.h | 2 +- 104 files changed, 104 insertions(+), 104 deletions(-) diff --git a/src/QY2CharValidator.cc b/src/QY2CharValidator.cc index 93379e97..b6c35dca 100644 --- a/src/QY2CharValidator.cc +++ b/src/QY2CharValidator.cc @@ -18,7 +18,7 @@ File: QY2CharValidator.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer This is a pure Qt object - it can be used independently of YaST2. diff --git a/src/QY2CharValidator.h b/src/QY2CharValidator.h index a29133f1..f3716547 100644 --- a/src/QY2CharValidator.h +++ b/src/QY2CharValidator.h @@ -18,7 +18,7 @@ File: QY2CharValidator.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer This is a pure Qt object - it can be used independently of YaST2. diff --git a/src/QY2ComboTabWidget.cc b/src/QY2ComboTabWidget.cc index 5ea71e8c..ac127e28 100644 --- a/src/QY2ComboTabWidget.cc +++ b/src/QY2ComboTabWidget.cc @@ -18,7 +18,7 @@ File: QY2ComboTabWidget.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer This is a pure Qt widget - it can be used independently of YaST2. diff --git a/src/QY2ComboTabWidget.h b/src/QY2ComboTabWidget.h index 634c6030..4a25729a 100644 --- a/src/QY2ComboTabWidget.h +++ b/src/QY2ComboTabWidget.h @@ -18,7 +18,7 @@ File: QY2ComboTabWidget.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer This is a pure Qt widget - it can be used independently of YaST2. diff --git a/src/QY2DiskUsageList.cc b/src/QY2DiskUsageList.cc index 30b05696..e84bc545 100644 --- a/src/QY2DiskUsageList.cc +++ b/src/QY2DiskUsageList.cc @@ -18,7 +18,7 @@ File: QY2DiskUsageList.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer Textdomain "qt" diff --git a/src/QY2DiskUsageList.h b/src/QY2DiskUsageList.h index 96712264..b58517aa 100644 --- a/src/QY2DiskUsageList.h +++ b/src/QY2DiskUsageList.h @@ -18,7 +18,7 @@ File: QY2DiskUsageList.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer This is a pure Qt widget - it can be used independently of YaST2. diff --git a/src/QY2ListView.cc b/src/QY2ListView.cc index 48cf9ebb..adb70780 100644 --- a/src/QY2ListView.cc +++ b/src/QY2ListView.cc @@ -18,7 +18,7 @@ File: QY2ListView.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer This is a pure Qt widget - it can be used independently of YaST2. diff --git a/src/QY2ListView.h b/src/QY2ListView.h index cf0e524a..e03b462a 100644 --- a/src/QY2ListView.h +++ b/src/QY2ListView.h @@ -18,7 +18,7 @@ File: QY2ListView.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer This is a pure Qt widget - it can be used independently of YaST2. diff --git a/src/YQAlignment.cc b/src/YQAlignment.cc index 54c394cb..b230a5e8 100644 --- a/src/YQAlignment.cc +++ b/src/YQAlignment.cc @@ -18,7 +18,7 @@ File: YQAlignment.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQAlignment.h b/src/YQAlignment.h index 053a35d0..5680d10c 100644 --- a/src/YQAlignment.h +++ b/src/YQAlignment.h @@ -18,7 +18,7 @@ File: YQAlignment.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQApplication.cc b/src/YQApplication.cc index 938137a6..e00db242 100644 --- a/src/YQApplication.cc +++ b/src/YQApplication.cc @@ -18,7 +18,7 @@ File: YQApplication.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer Textdomain "qt" /-*/ diff --git a/src/YQApplication.h b/src/YQApplication.h index f123c4f9..bada284d 100644 --- a/src/YQApplication.h +++ b/src/YQApplication.h @@ -18,7 +18,7 @@ File: YQApplication.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQBarGraph.cc b/src/YQBarGraph.cc index 96319283..7ac6c39e 100644 --- a/src/YQBarGraph.cc +++ b/src/YQBarGraph.cc @@ -18,7 +18,7 @@ File: YQBarGraph.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQBarGraph.h b/src/YQBarGraph.h index 3690bfa9..bd81f33c 100644 --- a/src/YQBarGraph.h +++ b/src/YQBarGraph.h @@ -18,7 +18,7 @@ File: YQBarGraph.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQButtonBox.cc b/src/YQButtonBox.cc index 14102401..4e35f214 100644 --- a/src/YQButtonBox.cc +++ b/src/YQButtonBox.cc @@ -18,7 +18,7 @@ File: YQButtonBox.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQButtonBox.h b/src/YQButtonBox.h index 70a4a77d..baee9463 100644 --- a/src/YQButtonBox.h +++ b/src/YQButtonBox.h @@ -18,7 +18,7 @@ File: YQButtonBox.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQCheckBox.cc b/src/YQCheckBox.cc index 74f39507..ad831515 100644 --- a/src/YQCheckBox.cc +++ b/src/YQCheckBox.cc @@ -18,7 +18,7 @@ File: YQCheckBox.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQCheckBox.h b/src/YQCheckBox.h index 414f8596..26977026 100644 --- a/src/YQCheckBox.h +++ b/src/YQCheckBox.h @@ -18,7 +18,7 @@ File: YQCheckBox.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQCheckBoxFrame.cc b/src/YQCheckBoxFrame.cc index 783af219..75b2685b 100644 --- a/src/YQCheckBoxFrame.cc +++ b/src/YQCheckBoxFrame.cc @@ -18,7 +18,7 @@ File: YQCheckBoxFrame.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQCheckBoxFrame.h b/src/YQCheckBoxFrame.h index a539e515..55354391 100644 --- a/src/YQCheckBoxFrame.h +++ b/src/YQCheckBoxFrame.h @@ -18,7 +18,7 @@ File: YQCheckBoxFrame.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQComboBox.cc b/src/YQComboBox.cc index ca36b80e..3439e473 100644 --- a/src/YQComboBox.cc +++ b/src/YQComboBox.cc @@ -18,7 +18,7 @@ File: YQComboBox.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQComboBox.h b/src/YQComboBox.h index e865864e..7d6dfd00 100644 --- a/src/YQComboBox.h +++ b/src/YQComboBox.h @@ -18,7 +18,7 @@ File: YQComboBox.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQDateField.cc b/src/YQDateField.cc index 76a0974f..7264ae8d 100644 --- a/src/YQDateField.cc +++ b/src/YQDateField.cc @@ -18,7 +18,7 @@ File: YQDateField.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQDateField.h b/src/YQDateField.h index 55d01807..75a9e298 100644 --- a/src/YQDateField.h +++ b/src/YQDateField.h @@ -18,7 +18,7 @@ File: YQDateField.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQDialog.cc b/src/YQDialog.cc index 30d0cffd..7f147a76 100644 --- a/src/YQDialog.cc +++ b/src/YQDialog.cc @@ -18,7 +18,7 @@ File: YQDialog.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer Textdomain "qt" diff --git a/src/YQDialog.h b/src/YQDialog.h index b0202fec..f3bbee15 100644 --- a/src/YQDialog.h +++ b/src/YQDialog.h @@ -18,7 +18,7 @@ File: YQDialog.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQDownloadProgress.cc b/src/YQDownloadProgress.cc index 141711e4..e2b03d77 100644 --- a/src/YQDownloadProgress.cc +++ b/src/YQDownloadProgress.cc @@ -18,7 +18,7 @@ File: YQLogView.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQDownloadProgress.h b/src/YQDownloadProgress.h index dccf413b..8846c13f 100644 --- a/src/YQDownloadProgress.h +++ b/src/YQDownloadProgress.h @@ -18,7 +18,7 @@ File: YQDownloadProgress.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQDumbTab.cc b/src/YQDumbTab.cc index 96dad119..48e620d9 100644 --- a/src/YQDumbTab.cc +++ b/src/YQDumbTab.cc @@ -18,7 +18,7 @@ File: YQDumbTab.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQDumbTab.h b/src/YQDumbTab.h index e8be69da..e83cd648 100644 --- a/src/YQDumbTab.h +++ b/src/YQDumbTab.h @@ -18,7 +18,7 @@ File: YQDumbTab.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQEmpty.cc b/src/YQEmpty.cc index 536b132e..1acbaf19 100644 --- a/src/YQEmpty.cc +++ b/src/YQEmpty.cc @@ -18,7 +18,7 @@ File: YQEmpty.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQEmpty.h b/src/YQEmpty.h index 1c80e95b..8441e241 100644 --- a/src/YQEmpty.h +++ b/src/YQEmpty.h @@ -18,7 +18,7 @@ File: YQEmpty.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQFrame.cc b/src/YQFrame.cc index 8a53a473..d5f1f514 100644 --- a/src/YQFrame.cc +++ b/src/YQFrame.cc @@ -18,7 +18,7 @@ File: YQFrame.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQFrame.h b/src/YQFrame.h index f0ecc472..a466fe2c 100644 --- a/src/YQFrame.h +++ b/src/YQFrame.h @@ -18,7 +18,7 @@ File: YQFrame.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQGenericButton.cc b/src/YQGenericButton.cc index 923dbb65..119d2ad3 100644 --- a/src/YQGenericButton.cc +++ b/src/YQGenericButton.cc @@ -18,7 +18,7 @@ File: YQGenericButton.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQGenericButton.h b/src/YQGenericButton.h index aac584e0..6c38ce98 100644 --- a/src/YQGenericButton.h +++ b/src/YQGenericButton.h @@ -18,7 +18,7 @@ File: YQGenericButton.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQImage.cc b/src/YQImage.cc index 51fe4576..6ff0bb2d 100644 --- a/src/YQImage.cc +++ b/src/YQImage.cc @@ -18,7 +18,7 @@ File: YQImage.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQImage.h b/src/YQImage.h index a3ca814f..3b967eeb 100644 --- a/src/YQImage.h +++ b/src/YQImage.h @@ -18,7 +18,7 @@ File: YQImage.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQInputField.cc b/src/YQInputField.cc index 3fa8ad78..b0ff5dfa 100644 --- a/src/YQInputField.cc +++ b/src/YQInputField.cc @@ -18,7 +18,7 @@ File: YQInputField.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer Textdomain "qt" diff --git a/src/YQInputField.h b/src/YQInputField.h index aca92b5d..8dbde7f7 100644 --- a/src/YQInputField.h +++ b/src/YQInputField.h @@ -18,7 +18,7 @@ File: YQInputField.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQIntField.cc b/src/YQIntField.cc index 7ed716c5..e6963c4a 100644 --- a/src/YQIntField.cc +++ b/src/YQIntField.cc @@ -18,7 +18,7 @@ File: YQIntField.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQIntField.h b/src/YQIntField.h index 445c5236..097abe69 100644 --- a/src/YQIntField.h +++ b/src/YQIntField.h @@ -18,7 +18,7 @@ File: YQIntField.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQLabel.cc b/src/YQLabel.cc index c98ec115..471a41cb 100644 --- a/src/YQLabel.cc +++ b/src/YQLabel.cc @@ -18,7 +18,7 @@ File: YQLabel.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQLabel.h b/src/YQLabel.h index 2ca4c9cd..80dc9989 100644 --- a/src/YQLabel.h +++ b/src/YQLabel.h @@ -18,7 +18,7 @@ File: YQLabel.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQLayoutBox.cc b/src/YQLayoutBox.cc index 56825b7f..2eea68f2 100644 --- a/src/YQLayoutBox.cc +++ b/src/YQLayoutBox.cc @@ -18,7 +18,7 @@ File: YQLayoutBox.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQLayoutBox.h b/src/YQLayoutBox.h index 42cf37c2..e9477eb1 100644 --- a/src/YQLayoutBox.h +++ b/src/YQLayoutBox.h @@ -18,7 +18,7 @@ File: YQLayoutBox.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQLogView.cc b/src/YQLogView.cc index 0ba7b0f7..5b9ccacd 100644 --- a/src/YQLogView.cc +++ b/src/YQLogView.cc @@ -18,7 +18,7 @@ File: YQLogView.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQLogView.h b/src/YQLogView.h index 36975704..086ac136 100644 --- a/src/YQLogView.h +++ b/src/YQLogView.h @@ -18,7 +18,7 @@ File: YQLogView.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMainWinDock.cc b/src/YQMainWinDock.cc index 52cff2dd..d0f84682 100644 --- a/src/YQMainWinDock.cc +++ b/src/YQMainWinDock.cc @@ -18,7 +18,7 @@ File: YQMainWinDock.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMainWinDock.h b/src/YQMainWinDock.h index 6c47c449..fecca222 100644 --- a/src/YQMainWinDock.h +++ b/src/YQMainWinDock.h @@ -18,7 +18,7 @@ File: YQMainWinDock.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMenuButton.cc b/src/YQMenuButton.cc index cf987089..1173a633 100644 --- a/src/YQMenuButton.cc +++ b/src/YQMenuButton.cc @@ -18,7 +18,7 @@ File: YQMenuButton.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMenuButton.h b/src/YQMenuButton.h index 887a9551..5aa57087 100644 --- a/src/YQMenuButton.h +++ b/src/YQMenuButton.h @@ -18,7 +18,7 @@ File: YQMenuButton.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMultiLineEdit.cc b/src/YQMultiLineEdit.cc index f746adc8..54322a45 100644 --- a/src/YQMultiLineEdit.cc +++ b/src/YQMultiLineEdit.cc @@ -18,7 +18,7 @@ File: YQMultiLineEdit.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMultiLineEdit.h b/src/YQMultiLineEdit.h index 6a37b2ef..4a32c217 100644 --- a/src/YQMultiLineEdit.h +++ b/src/YQMultiLineEdit.h @@ -18,7 +18,7 @@ File: YQMultiLineEdit.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMultiProgressMeter.cc b/src/YQMultiProgressMeter.cc index 1041941e..ec32a724 100644 --- a/src/YQMultiProgressMeter.cc +++ b/src/YQMultiProgressMeter.cc @@ -18,7 +18,7 @@ File: YQMultiProgressMeter.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMultiProgressMeter.h b/src/YQMultiProgressMeter.h index bfc79981..43b6b65f 100644 --- a/src/YQMultiProgressMeter.h +++ b/src/YQMultiProgressMeter.h @@ -18,7 +18,7 @@ File: YQMultiProgressMeter.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMultiSelectionBox.cc b/src/YQMultiSelectionBox.cc index 870734f3..24d2686d 100644 --- a/src/YQMultiSelectionBox.cc +++ b/src/YQMultiSelectionBox.cc @@ -18,7 +18,7 @@ File: YQMultiSelectionBox.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQMultiSelectionBox.h b/src/YQMultiSelectionBox.h index 65ee5d1f..dbd3710d 100644 --- a/src/YQMultiSelectionBox.h +++ b/src/YQMultiSelectionBox.h @@ -18,7 +18,7 @@ File: YQMultiSelectionBox.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQOptionalWidgetFactory.cc b/src/YQOptionalWidgetFactory.cc index 39f8ad87..3644fedc 100644 --- a/src/YQOptionalWidgetFactory.cc +++ b/src/YQOptionalWidgetFactory.cc @@ -18,7 +18,7 @@ File: YQOptionalWidgetFactory.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQOptionalWidgetFactory.h b/src/YQOptionalWidgetFactory.h index 0c29b486..7877b5de 100644 --- a/src/YQOptionalWidgetFactory.h +++ b/src/YQOptionalWidgetFactory.h @@ -18,7 +18,7 @@ File: YQOptionalWidgetFactory.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQPartitionSplitter.cc b/src/YQPartitionSplitter.cc index 00332925..8ebf32b8 100644 --- a/src/YQPartitionSplitter.cc +++ b/src/YQPartitionSplitter.cc @@ -18,7 +18,7 @@ File: YQPartitionSplitter.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQPartitionSplitter.h b/src/YQPartitionSplitter.h index 4e946a40..87d23086 100644 --- a/src/YQPartitionSplitter.h +++ b/src/YQPartitionSplitter.h @@ -18,7 +18,7 @@ File: YQPartitionSplitter.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQProgressBar.cc b/src/YQProgressBar.cc index 616a9399..67a9de4b 100644 --- a/src/YQProgressBar.cc +++ b/src/YQProgressBar.cc @@ -18,7 +18,7 @@ File: YQProgressBar.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQProgressBar.h b/src/YQProgressBar.h index 75bf5a7a..ee144eb5 100644 --- a/src/YQProgressBar.h +++ b/src/YQProgressBar.h @@ -18,7 +18,7 @@ File: YQProgressBar.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQPushButton.cc b/src/YQPushButton.cc index 3fbe9d1c..cc7d8d7e 100644 --- a/src/YQPushButton.cc +++ b/src/YQPushButton.cc @@ -18,7 +18,7 @@ File: YQPushButton.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQPushButton.h b/src/YQPushButton.h index 6f6902e7..06223b95 100644 --- a/src/YQPushButton.h +++ b/src/YQPushButton.h @@ -18,7 +18,7 @@ File: YQPushButton.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQRadioButton.cc b/src/YQRadioButton.cc index 992c45cf..b394d483 100644 --- a/src/YQRadioButton.cc +++ b/src/YQRadioButton.cc @@ -18,7 +18,7 @@ File: YQRadioButton.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQRadioButton.h b/src/YQRadioButton.h index 55dac1a1..373ac188 100644 --- a/src/YQRadioButton.h +++ b/src/YQRadioButton.h @@ -18,7 +18,7 @@ File: YQRadioButton.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQRadioButtonGroup.cc b/src/YQRadioButtonGroup.cc index 99686b7e..26e6f65a 100644 --- a/src/YQRadioButtonGroup.cc +++ b/src/YQRadioButtonGroup.cc @@ -18,7 +18,7 @@ File: YQRadioButtonGroup.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQRadioButtonGroup.h b/src/YQRadioButtonGroup.h index c7a53739..fdf5832e 100644 --- a/src/YQRadioButtonGroup.h +++ b/src/YQRadioButtonGroup.h @@ -18,7 +18,7 @@ File: YQRadioButtonGroup.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQReplacePoint.cc b/src/YQReplacePoint.cc index 8c2e5dae..4baf8e50 100644 --- a/src/YQReplacePoint.cc +++ b/src/YQReplacePoint.cc @@ -18,7 +18,7 @@ File: YQReplacePoint.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQReplacePoint.h b/src/YQReplacePoint.h index a273c808..99948973 100644 --- a/src/YQReplacePoint.h +++ b/src/YQReplacePoint.h @@ -18,7 +18,7 @@ File: YQReplacePoint.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQRichText.cc b/src/YQRichText.cc index f7031ce5..6c8ed4ad 100644 --- a/src/YQRichText.cc +++ b/src/YQRichText.cc @@ -19,7 +19,7 @@ File: YQRichText.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQRichText.h b/src/YQRichText.h index 93656e28..b69b977b 100644 --- a/src/YQRichText.h +++ b/src/YQRichText.h @@ -19,7 +19,7 @@ File: YQRichText.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSelectionBox.cc b/src/YQSelectionBox.cc index f324ff66..342c0adf 100644 --- a/src/YQSelectionBox.cc +++ b/src/YQSelectionBox.cc @@ -18,7 +18,7 @@ File: YQSelectionBox.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSelectionBox.h b/src/YQSelectionBox.h index 7d9b6fdd..f79ac4c6 100644 --- a/src/YQSelectionBox.h +++ b/src/YQSelectionBox.h @@ -18,7 +18,7 @@ File: YQSelectionBox.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSignalBlocker.cc b/src/YQSignalBlocker.cc index 82422509..37a2f1c8 100644 --- a/src/YQSignalBlocker.cc +++ b/src/YQSignalBlocker.cc @@ -18,7 +18,7 @@ File: YQSignalBlocker.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSignalBlocker.h b/src/YQSignalBlocker.h index 4a9c655a..468c33b0 100644 --- a/src/YQSignalBlocker.h +++ b/src/YQSignalBlocker.h @@ -18,7 +18,7 @@ File: YQSignalBlocker.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSlider.cc b/src/YQSlider.cc index d34a9903..4ba966bd 100644 --- a/src/YQSlider.cc +++ b/src/YQSlider.cc @@ -18,7 +18,7 @@ File: YQSlider.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSlider.h b/src/YQSlider.h index 6fbf05c2..f4da0131 100644 --- a/src/YQSlider.h +++ b/src/YQSlider.h @@ -18,7 +18,7 @@ File: YQSlider.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSpacing.cc b/src/YQSpacing.cc index e73fd401..ab878497 100644 --- a/src/YQSpacing.cc +++ b/src/YQSpacing.cc @@ -18,7 +18,7 @@ File: YQSpacing.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSpacing.h b/src/YQSpacing.h index a4901274..49c4c0fa 100644 --- a/src/YQSpacing.h +++ b/src/YQSpacing.h @@ -18,7 +18,7 @@ File: YQSpacing.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSquash.cc b/src/YQSquash.cc index eda834cd..fcf903d8 100644 --- a/src/YQSquash.cc +++ b/src/YQSquash.cc @@ -18,7 +18,7 @@ File: YQSquash.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQSquash.h b/src/YQSquash.h index ed5b3c52..35f16aba 100644 --- a/src/YQSquash.h +++ b/src/YQSquash.h @@ -18,7 +18,7 @@ File: YQSquash.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQTable.cc b/src/YQTable.cc index 5d3f1130..01ef1963 100644 --- a/src/YQTable.cc +++ b/src/YQTable.cc @@ -18,7 +18,7 @@ File: YQTable.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQTable.h b/src/YQTable.h index 228df7ba..97309842 100644 --- a/src/YQTable.h +++ b/src/YQTable.h @@ -18,7 +18,7 @@ File: YQTable.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQTimeField.cc b/src/YQTimeField.cc index e4b1446c..a7f1541d 100644 --- a/src/YQTimeField.cc +++ b/src/YQTimeField.cc @@ -18,7 +18,7 @@ File: YQTimeField.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQTimeField.h b/src/YQTimeField.h index dd95be86..046edd1f 100644 --- a/src/YQTimeField.h +++ b/src/YQTimeField.h @@ -18,7 +18,7 @@ File: YQTimeField.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQTimezoneSelector.h b/src/YQTimezoneSelector.h index 79b23057..20f30158 100644 --- a/src/YQTimezoneSelector.h +++ b/src/YQTimezoneSelector.h @@ -18,7 +18,7 @@ File: YQTimezoneSelector.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQTree.cc b/src/YQTree.cc index 0d533739..19d21929 100644 --- a/src/YQTree.cc +++ b/src/YQTree.cc @@ -18,7 +18,7 @@ File: YQTree.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQTree.h b/src/YQTree.h index c408aadf..5c63d2c9 100644 --- a/src/YQTree.h +++ b/src/YQTree.h @@ -18,7 +18,7 @@ File: YQTree.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQUI.cc b/src/YQUI.cc index af252d61..0baacaaf 100644 --- a/src/YQUI.cc +++ b/src/YQUI.cc @@ -18,7 +18,7 @@ File: YQUI.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer Textdomain "qt" diff --git a/src/YQUI.h b/src/YQUI.h index 65e86f3a..8d43c8c6 100644 --- a/src/YQUI.h +++ b/src/YQUI.h @@ -18,7 +18,7 @@ File: YQUI.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQUI_builtins.cc b/src/YQUI_builtins.cc index 4f8e7509..f86067aa 100644 --- a/src/YQUI_builtins.cc +++ b/src/YQUI_builtins.cc @@ -18,7 +18,7 @@ File: YUIQt_builtins.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer Textdomain "qt" diff --git a/src/YQWidgetCaption.cc b/src/YQWidgetCaption.cc index 56d089b9..f354a23d 100644 --- a/src/YQWidgetCaption.cc +++ b/src/YQWidgetCaption.cc @@ -18,7 +18,7 @@ File: YQWidgetCaption.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQWidgetCaption.h b/src/YQWidgetCaption.h index e30194c2..075d72f6 100644 --- a/src/YQWidgetCaption.h +++ b/src/YQWidgetCaption.h @@ -18,7 +18,7 @@ File: YQWidgetCaption.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQWidgetFactory.cc b/src/YQWidgetFactory.cc index da8edb9e..7c2348a6 100644 --- a/src/YQWidgetFactory.cc +++ b/src/YQWidgetFactory.cc @@ -18,7 +18,7 @@ File: YQWidgetFactory.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQWidgetFactory.h b/src/YQWidgetFactory.h index a04e993d..011f2eb6 100644 --- a/src/YQWidgetFactory.h +++ b/src/YQWidgetFactory.h @@ -18,7 +18,7 @@ File: YQWidgetFactory.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQWizard.cc b/src/YQWizard.cc index ac10a83d..2492fd3f 100644 --- a/src/YQWizard.cc +++ b/src/YQWizard.cc @@ -18,7 +18,7 @@ File: YQWizard.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer Textdomain "qt" diff --git a/src/YQWizard.h b/src/YQWizard.h index ab4ed05d..620f116d 100644 --- a/src/YQWizard.h +++ b/src/YQWizard.h @@ -18,7 +18,7 @@ File: YQWizard.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQWizardButton.cc b/src/YQWizardButton.cc index 982fc7b7..e6500836 100644 --- a/src/YQWizardButton.cc +++ b/src/YQWizardButton.cc @@ -18,7 +18,7 @@ File: YQWizardButton.cc - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQWizardButton.h b/src/YQWizardButton.h index 9060a372..a6fcb0c1 100644 --- a/src/YQWizardButton.h +++ b/src/YQWizardButton.h @@ -18,7 +18,7 @@ File: YQWizardButton.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/YQi18n.h b/src/YQi18n.h index 56ad19a1..c70f1484 100644 --- a/src/YQi18n.h +++ b/src/YQi18n.h @@ -18,7 +18,7 @@ File: YQi18n.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ diff --git a/src/utf8.h b/src/utf8.h index 392a08b1..f578cc45 100644 --- a/src/utf8.h +++ b/src/utf8.h @@ -18,7 +18,7 @@ File: utf8.h - Author: Stefan Hundhammer + Author: Stefan Hundhammer /-*/ From c28fb6438c5f550e3198f3123b6a24cfb0080211 Mon Sep 17 00:00:00 2001 From: Stefan Hundhammer Date: Tue, 14 Jul 2020 12:07:34 +0200 Subject: [PATCH 4/6] Added support for enabling / disabling menu items --- src/YQMenuBar.cc | 29 +++++++++++++++++++++++++++-- src/YQMenuBar.h | 15 ++++++++++----- src/YQMenuButton.cc | 34 +++++++++++++++++++++++++++++++--- src/YQMenuButton.h | 14 ++++++++++---- 4 files changed, 78 insertions(+), 14 deletions(-) diff --git a/src/YQMenuBar.cc b/src/YQMenuBar.cc index 8351a2e4..e120b1dd 100644 --- a/src/YQMenuBar.cc +++ b/src/YQMenuBar.cc @@ -79,7 +79,7 @@ YQMenuBar::rebuildMenuTree() YUI_THROW( YUIException( "YQMenuBar: Only menus allowed on toplevel." ) ); QMenu * menu = QMenuBar::addMenu( fromUTF8( item->label() )); - YUI_CHECK_NEW( menu ); + item->setUiItem( menu ); connect( menu, &pclass(menu)::triggered, this, &pclass(this)::menuEntryActivated ); @@ -109,10 +109,11 @@ YQMenuBar::rebuildMenuTree( QMenu * parentMenu, YItemIterator begin, YItemIterat else if ( item->isMenu() ) { QMenu * subMenu = parentMenu->addMenu( fromUTF8( item->label() )); + item->setUiItem( subMenu ); if ( ! icon.isNull() ) subMenu->setIcon( icon ); - + connect( subMenu, &pclass(subMenu)::triggered, this, &pclass(this)::menuEntryActivated ); @@ -121,6 +122,7 @@ YQMenuBar::rebuildMenuTree( QMenu * parentMenu, YItemIterator begin, YItemIterat else // Plain menu item (leaf item) { QAction * action = parentMenu->addAction( fromUTF8( item->label() ) ); + item->setUiItem( action ); _actionMap[ action ] = item; if ( ! icon.isNull() ) @@ -171,6 +173,29 @@ YQMenuBar::returnNow() } +void +YQMenuBar::setItemEnabled( YMenuItem * item, bool enabled ) +{ + QObject * qObj = static_cast( item->uiItem() ); + + if ( qObj ) + { + QMenu * menu = qobject_cast( qObj ); + + if ( menu ) + menu->setEnabled( enabled ); + else + { + QAction * action = qobject_cast( qObj ); + + if ( action ) + action->setEnabled( enabled ); + } + } + + YMenuWidget::setItemEnabled( item, enabled ); +} + void YQMenuBar::setEnabled( bool enabled ) diff --git a/src/YQMenuBar.h b/src/YQMenuBar.h index 90a54fc0..0592ef51 100644 --- a/src/YQMenuBar.h +++ b/src/YQMenuBar.h @@ -90,11 +90,16 @@ class YQMenuBar : public QMenuBar, public YMenuBar virtual bool setKeyboardFocus(); /** - * Activate the item selected in the tree. Can be used in tests to simulate - * user input. - * - * Derived classes are required to implement this. - **/ + * Enable or disable an item. + * + * Reimplemented from YMenuWidget. + **/ + virtual void setItemEnabled( YMenuItem * item, bool enabled ); + + /** + * Activate the item selected in the tree. Can be used in tests to simulate + * user input. + **/ virtual void activateItem( YMenuItem * item ); diff --git a/src/YQMenuButton.cc b/src/YQMenuButton.cc index 1173a633..e78bc1a6 100644 --- a/src/YQMenuButton.cc +++ b/src/YQMenuButton.cc @@ -1,5 +1,6 @@ /* Copyright (C) 2000-2012 Novell, Inc + Copyright (C) 2020 SUSE LLC This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the @@ -23,10 +24,11 @@ /-*/ -#include +#include #include -#include -#include +#include +#include + #define YUILogComponent "qt-ui" #include @@ -121,6 +123,7 @@ YQMenuButton::rebuildMenuTree( QMenu * parentMenu, YItemIterator begin, YItemIte else if ( item->isMenu() ) { QMenu * subMenu = parentMenu->addMenu( fromUTF8( item->label() )); + item->setUiItem( subMenu ); if ( ! icon.isNull() ) subMenu->setIcon( icon ); @@ -137,6 +140,7 @@ YQMenuButton::rebuildMenuTree( QMenu * parentMenu, YItemIterator begin, YItemIte // to this YQMenuButton. QAction * action = parentMenu->addAction( fromUTF8( item->label() ) ); + item->setUiItem( action ); _actionMap[ action ] = item; if ( ! icon.isNull() ) @@ -187,6 +191,30 @@ YQMenuButton::returnNow() } +void +YQMenuButton::setItemEnabled( YMenuItem * item, bool enabled ) +{ + QObject * qObj = static_cast( item->uiItem() ); + + if ( qObj ) + { + QMenu * menu = qobject_cast( qObj ); + + if ( menu ) + menu->setEnabled( enabled ); + else + { + QAction * action = qobject_cast( qObj ); + + if ( action ) + action->setEnabled( enabled ); + } + } + + YMenuWidget::setItemEnabled( item, enabled ); +} + + void YQMenuButton::setEnabled( bool enabled ) { diff --git a/src/YQMenuButton.h b/src/YQMenuButton.h index 5aa57087..e9ee747a 100644 --- a/src/YQMenuButton.h +++ b/src/YQMenuButton.h @@ -98,12 +98,18 @@ class YQMenuButton : public QWidget, public YMenuButton virtual bool setKeyboardFocus(); /** - * Activate the item selected in the tree. Can be used in tests to simulate user input. - * - * Derived classes are required to implement this. - **/ + * Enable or disable an item. + * + * Reimplemented from YMenuWidget. + **/ + virtual void setItemEnabled( YMenuItem * item, bool enabled ); + + /** + * Activate the item selected in the tree. Can be used in tests to simulate user input. + **/ virtual void activateItem( YMenuItem * item ); + protected slots: /** From dcb9705c6223f274dd709f86881d94cca83a3440 Mon Sep 17 00:00:00 2001 From: Stefan Hundhammer Date: Thu, 16 Jul 2020 14:23:38 +0200 Subject: [PATCH 5/6] Code review fixes --- src/YQContextMenu.cc | 2 +- src/YQMenuBar.cc | 2 +- src/YQMenuButton.cc | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/YQContextMenu.cc b/src/YQContextMenu.cc index 8d6c032c..6626c198 100644 --- a/src/YQContextMenu.cc +++ b/src/YQContextMenu.cc @@ -169,7 +169,7 @@ YQContextMenu::menuEntryActivated( QAction* action ) */ /* - * the 100 delay is a ugly dirty workaround + * The 100 delay is an ugly dirty workaround. */ _suppressCancelEvent = true; QTimer::singleShot( 100, this, SLOT( returnNow() ) ); diff --git a/src/YQMenuBar.cc b/src/YQMenuBar.cc index e120b1dd..e7b9a31d 100644 --- a/src/YQMenuBar.cc +++ b/src/YQMenuBar.cc @@ -151,7 +151,7 @@ YQMenuBar::menuEntryActivated( QAction * action ) */ /* - * The 100 delay is a ugly dirty workaround. + * The 100 delay is an ugly dirty workaround. */ QTimer::singleShot( 100, this, SLOT( returnNow() ) ); } diff --git a/src/YQMenuButton.cc b/src/YQMenuButton.cc index e78bc1a6..a1778b21 100644 --- a/src/YQMenuButton.cc +++ b/src/YQMenuButton.cc @@ -169,7 +169,7 @@ YQMenuButton::menuEntryActivated( QAction * action ) */ /* - * The 100 delay is a ugly dirty workaround. + * The 100 delay is an ugly dirty workaround. */ QTimer::singleShot( 100, this, SLOT( returnNow() ) ); } From 81ce41d449d141875fe26f885d0cf70ab7c2dcb6 Mon Sep 17 00:00:00 2001 From: Stefan Hundhammer Date: Tue, 11 Aug 2020 15:53:09 +0200 Subject: [PATCH 6/6] SO bump, version bump, change log --- VERSION.cmake | 4 ++-- package/libyui-qt-doc.spec | 4 ++-- package/libyui-qt.changes | 7 +++++++ package/libyui-qt.spec | 4 ++-- 4 files changed, 13 insertions(+), 6 deletions(-) diff --git a/VERSION.cmake b/VERSION.cmake index 55b040d9..7890f9c1 100644 --- a/VERSION.cmake +++ b/VERSION.cmake @@ -1,11 +1,11 @@ SET(VERSION_MAJOR "2") -SET(VERSION_MINOR "53") +SET(VERSION_MINOR "54") SET(VERSION_PATCH "0") SET( VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}${GIT_SHA1_VERSION}" ) ##### This is needed for the libyui-qt core ONLY. ##### These will be overridden from exports in LibyuiConfig.cmake -SET( SONAME_MAJOR "12" ) +SET( SONAME_MAJOR "13" ) SET( SONAME_MINOR "0" ) SET( SONAME_PATCH "0" ) SET( SONAME "${SONAME_MAJOR}.${SONAME_MINOR}.${SONAME_PATCH}" ) diff --git a/package/libyui-qt-doc.spec b/package/libyui-qt-doc.spec index 88cb0534..0635d04b 100644 --- a/package/libyui-qt-doc.spec +++ b/package/libyui-qt-doc.spec @@ -17,11 +17,11 @@ %define parent libyui-qt -%define so_version 12 +%define so_version 13 Name: %{parent}-doc # DO NOT manually bump the version here; instead, use rake version:bump -Version: 2.53.0 +Version: 2.54.0 Release: 0 Source: %{parent}-%{version}.tar.bz2 diff --git a/package/libyui-qt.changes b/package/libyui-qt.changes index e6111f25..ec75055c 100644 --- a/package/libyui-qt.changes +++ b/package/libyui-qt.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Tue Aug 11 13:52:19 UTC 2020 - Stefan Hundhammer + +- Added MenuBar widget (bsc#1175115) +- Bumped SO version to 13 +- 2.54.0 + ------------------------------------------------------------------- Thu Jun 4 11:58:01 UTC 2020 - Stefan Hundhammer diff --git a/package/libyui-qt.spec b/package/libyui-qt.spec index 08c6fef6..b5d0b040 100644 --- a/package/libyui-qt.spec +++ b/package/libyui-qt.spec @@ -18,11 +18,11 @@ Name: libyui-qt # DO NOT manually bump the version here; instead, use rake version:bump -Version: 2.53.0 +Version: 2.54.0 Release: 0 Source: %{name}-%{version}.tar.bz2 -%define so_version 12 +%define so_version 13 %define bin_name %{name}%{so_version} BuildRequires: boost-devel