Hello community,

here is the log from the commit of package libyui-ncurses-rest-api for 
openSUSE:Factory checked in at 2020-12-01 14:21:32
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/libyui-ncurses-rest-api (Old)
 and      /work/SRC/openSUSE:Factory/.libyui-ncurses-rest-api.new.5913 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "libyui-ncurses-rest-api"

Tue Dec  1 14:21:32 2020 rev:7 rq:851780 version:0.2.3

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/libyui-ncurses-rest-api/libyui-ncurses-rest-api.changes
  2020-10-18 16:21:28.248492146 +0200
+++ 
/work/SRC/openSUSE:Factory/.libyui-ncurses-rest-api.new.5913/libyui-ncurses-rest-api.changes
        2020-12-01 14:21:33.917514043 +0100
@@ -1,0 +2,6 @@
+Fri Nov 27 10:41:59 UTC 2020 - Rodion Iafarov <[email protected]>
+
+- Create structure to move handlers to separate classes (bsc#1132247)
+- 0.2.3
+
+-------------------------------------------------------------------

Old:
----
  libyui-ncurses-rest-api-0.2.2.tar.bz2

New:
----
  libyui-ncurses-rest-api-0.2.3.tar.bz2

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ libyui-ncurses-rest-api.spec ++++++
--- /var/tmp/diff_new_pack.VcHL0v/_old  2020-12-01 14:21:34.313514471 +0100
+++ /var/tmp/diff_new_pack.VcHL0v/_new  2020-12-01 14:21:34.321514480 +0100
@@ -21,7 +21,7 @@
 %define libyui_devel_version libyui-devel >= 3.8.0
 
 Name:           libyui-ncurses-rest-api
-Version:        0.2.2
+Version:        0.2.3
 Release:        0
 Summary:        Libyui - The REST API plugin for the Ncurses frontend
 License:        LGPL-2.1-only OR LGPL-3.0-only

++++++ libyui-ncurses-rest-api-0.2.2.tar.bz2 -> 
libyui-ncurses-rest-api-0.2.3.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libyui-ncurses-rest-api-0.2.2/SOURCECONF.cmake 
new/libyui-ncurses-rest-api-0.2.3/SOURCECONF.cmake
--- old/libyui-ncurses-rest-api-0.2.2/SOURCECONF.cmake  2020-10-09 
16:53:03.000000000 +0200
+++ new/libyui-ncurses-rest-api-0.2.3/SOURCECONF.cmake  2020-11-30 
09:55:44.000000000 +0100
@@ -1,6 +1,7 @@
 SET( ${TARGETLIB}_SOURCES
  YNCHttpUI.cc
  YNCHttpWidgetsActionHandler.cc
+ YNCWidgetActionHandler.cc
  NCHttpWidgetFactory.cc
  NCHttpDialog.cc
 )
@@ -8,6 +9,7 @@
 SET( ${TARGETLIB}_HEADERS
  YNCHttpUI.h
  YNCHttpWidgetsActionHandler.h
+ YNCWidgetActionHandler.h
  NCHttpDialog.h
  NCHttpWidgetFactory.h
 )
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libyui-ncurses-rest-api-0.2.2/VERSION.cmake 
new/libyui-ncurses-rest-api-0.2.3/VERSION.cmake
--- old/libyui-ncurses-rest-api-0.2.2/VERSION.cmake     2020-10-09 
16:53:03.000000000 +0200
+++ new/libyui-ncurses-rest-api-0.2.3/VERSION.cmake     2020-11-30 
09:55:44.000000000 +0100
@@ -1,6 +1,6 @@
 SET( VERSION_MAJOR "0")
 SET( VERSION_MINOR "2" )
-SET( VERSION_PATCH "2" )
+SET( VERSION_PATCH "3" )
 SET( VERSION 
"${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}${GIT_SHA1_VERSION}" )
 
 ##### This is need for the libyui core ONLY.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/libyui-ncurses-rest-api-0.2.2/package/libyui-ncurses-rest-api.changes 
new/libyui-ncurses-rest-api-0.2.3/package/libyui-ncurses-rest-api.changes
--- old/libyui-ncurses-rest-api-0.2.2/package/libyui-ncurses-rest-api.changes   
2020-10-09 16:53:03.000000000 +0200
+++ new/libyui-ncurses-rest-api-0.2.3/package/libyui-ncurses-rest-api.changes   
2020-11-30 09:55:44.000000000 +0100
@@ -1,4 +1,10 @@
 -------------------------------------------------------------------
+Fri Nov 27 10:41:59 UTC 2020 - Rodion Iafarov <[email protected]>
+
+- Create structure to move handlers to separate classes (bsc#1132247)
+- 0.2.3
+
+-------------------------------------------------------------------
 Fri Oct  9 13:32:34 UTC 2020 - José Iván López González <[email protected]>
 
 - Use new parent lib SO version libyui.so.14 (bsc#1176402).
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/libyui-ncurses-rest-api-0.2.2/package/libyui-ncurses-rest-api.spec 
new/libyui-ncurses-rest-api-0.2.3/package/libyui-ncurses-rest-api.spec
--- old/libyui-ncurses-rest-api-0.2.2/package/libyui-ncurses-rest-api.spec      
2020-10-09 16:53:03.000000000 +0200
+++ new/libyui-ncurses-rest-api-0.2.3/package/libyui-ncurses-rest-api.spec      
2020-11-30 09:55:44.000000000 +0100
@@ -21,7 +21,7 @@
 %define libyui_devel_version libyui-devel >= 3.8.0
 
 Name:           libyui-ncurses-rest-api
-Version:        0.2.2
+Version:        0.2.3
 Release:        0
 Summary:        Libyui - The REST API plugin for the Ncurses frontend
 License:        LGPL-2.1-only OR LGPL-3.0-only
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/libyui-ncurses-rest-api-0.2.2/src/YNCHttpWidgetsActionHandler.cc 
new/libyui-ncurses-rest-api-0.2.3/src/YNCHttpWidgetsActionHandler.cc
--- old/libyui-ncurses-rest-api-0.2.2/src/YNCHttpWidgetsActionHandler.cc        
2020-10-09 16:53:03.000000000 +0200
+++ new/libyui-ncurses-rest-api-0.2.3/src/YNCHttpWidgetsActionHandler.cc        
2020-11-30 09:55:44.000000000 +0100
@@ -22,32 +22,11 @@
 
 #include "YNCHttpWidgetsActionHandler.h"
 
-void YNCHttpWidgetsActionHandler::activate_widget( YCheckBoxFrame * widget )
-{
-    activate_nc_widget( widget );
-}
-
-void YNCHttpWidgetsActionHandler::activate_widget( YComboBox * widget )
-{
-    activate_nc_widget( widget );
-}
-
-void YNCHttpWidgetsActionHandler::activate_widget( YDateField * widget )
-{
-    activate_nc_widget( widget );
-}
-
-void YNCHttpWidgetsActionHandler::activate_widget( YSelectionBox * widget )
-{
-    activate_nc_widget( widget );
-}
-
-void YNCHttpWidgetsActionHandler::activate_widget( YTimeField * widget )
-{
-    activate_nc_widget( widget );
-}
+#include "YNCWidgetActionHandler.h"
 
-void YNCHttpWidgetsActionHandler::activate_widget ( YMultiSelectionBox * 
widget, YItem * item )
-{
-    activate_nc_widget( widget, item );
+YWidgetActionHandler* YNCHttpWidgetsActionHandler::get_widget_handler() {
+    if( !widget_action_handler ){
+        widget_action_handler = new YNCWidgetActionHandler();
+    }
+    return widget_action_handler;
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/libyui-ncurses-rest-api-0.2.2/src/YNCHttpWidgetsActionHandler.h 
new/libyui-ncurses-rest-api-0.2.3/src/YNCHttpWidgetsActionHandler.h
--- old/libyui-ncurses-rest-api-0.2.2/src/YNCHttpWidgetsActionHandler.h 
2020-10-09 16:53:03.000000000 +0200
+++ new/libyui-ncurses-rest-api-0.2.3/src/YNCHttpWidgetsActionHandler.h 
2020-11-30 09:55:44.000000000 +0100
@@ -17,15 +17,7 @@
 #ifndef YNCHttpWidgetsActionHandler_h
 #define YNCHttpWidgetsActionHandler_h
 
-#include <iostream>
-#include <functional>
-#include <yui/YEvent.h>
-
 #include "YHttpWidgetsActionHandler.h"
-#include "YNCHttpUI.h"
-#include "YMenuItem.h"
-
-#include "NCWidget.h"
 
 class YNCHttpWidgetsActionHandler : public YHttpWidgetsActionHandler
 {
@@ -36,37 +28,7 @@
     virtual ~YNCHttpWidgetsActionHandler() {}
 
 protected:
-
-    virtual void activate_widget( YCheckBoxFrame * widget );
-    virtual void activate_widget( YComboBox * widget );
-    virtual void activate_widget( YDateField * widget );
-    virtual void activate_widget( YSelectionBox * widget );
-    virtual void activate_widget( YTimeField * widget );
-
-    virtual void activate_widget ( YMultiSelectionBox * widget, YItem * item );
-
-private:
-
-    template<typename T>
-    void activate_nc_widget( T * widget ) {
-        if( widget->notify() && dynamic_cast<NCWidget*>( widget ) )
-        {
-            NCursesEvent event = NCursesEvent::Activated;
-            event.widget = dynamic_cast<NCWidget*>( widget );
-            YNCHttpUI::ui()->sendEvent( event );
-        }
-    }
-
-    template<typename T, typename I>
-    void activate_nc_widget( T * widget , I * item) {
-        if( widget->notify() && dynamic_cast<NCWidget*>( widget ) )
-        {
-            NCursesEvent event( NCursesEvent::menu );
-            event.selection = (YMenuItem *) item;
-            event.widget = dynamic_cast<NCWidget*>( widget );
-            YNCHttpUI::ui()->sendEvent( event );
-        }
-    }
+    virtual YWidgetActionHandler* get_widget_handler();
 
 };
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/libyui-ncurses-rest-api-0.2.2/src/YNCWidgetActionHandler.cc 
new/libyui-ncurses-rest-api-0.2.3/src/YNCWidgetActionHandler.cc
--- old/libyui-ncurses-rest-api-0.2.2/src/YNCWidgetActionHandler.cc     
1970-01-01 01:00:00.000000000 +0100
+++ new/libyui-ncurses-rest-api-0.2.3/src/YNCWidgetActionHandler.cc     
2020-11-30 09:55:44.000000000 +0100
@@ -0,0 +1,47 @@
+/*
+  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
+*/
+
+#include "YNCWidgetActionHandler.h"
+
+void YNCWidgetActionHandler::activate_widget( YCheckBoxFrame * widget )
+{
+    activate_nc_widget( widget );
+}
+
+void YNCWidgetActionHandler::activate_widget( YComboBox * widget )
+{
+    activate_nc_widget( widget );
+}
+
+void YNCWidgetActionHandler::activate_widget( YDateField * widget )
+{
+    activate_nc_widget( widget );
+}
+
+void YNCWidgetActionHandler::activate_widget( YSelectionBox * widget )
+{
+    activate_nc_widget( widget );
+}
+
+void YNCWidgetActionHandler::activate_widget( YTimeField * widget )
+{
+    activate_nc_widget( widget );
+}
+
+void YNCWidgetActionHandler::activate_widget ( YMultiSelectionBox * widget, 
YItem * item )
+{
+    activate_nc_widget( widget, item );
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/libyui-ncurses-rest-api-0.2.2/src/YNCWidgetActionHandler.h 
new/libyui-ncurses-rest-api-0.2.3/src/YNCWidgetActionHandler.h
--- old/libyui-ncurses-rest-api-0.2.2/src/YNCWidgetActionHandler.h      
1970-01-01 01:00:00.000000000 +0100
+++ new/libyui-ncurses-rest-api-0.2.3/src/YNCWidgetActionHandler.h      
2020-11-30 09:55:44.000000000 +0100
@@ -0,0 +1,69 @@
+/*
+  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
+*/
+
+#ifndef YNCWidgetActionHandler_h
+#define YNCWidgetActionHandler_h
+
+#include <iostream>
+#include <functional>
+#include <microhttpd.h>
+#include <sstream>
+#include <yui/YEvent.h>
+
+#include "YNCHttpUI.h"
+#include "YWidgetActionHandler.h"
+
+#include <boost/algorithm/string.hpp>
+
+class YNCWidgetActionHandler : public YWidgetActionHandler
+{
+
+protected:
+
+    virtual void activate_widget( YCheckBoxFrame * widget );
+    virtual void activate_widget( YComboBox * widget );
+    virtual void activate_widget( YDateField * widget );
+    virtual void activate_widget( YSelectionBox * widget );
+    virtual void activate_widget( YTimeField * widget );
+
+    virtual void activate_widget ( YMultiSelectionBox * widget, YItem * item );
+
+private:
+
+    template<typename T>
+    void activate_nc_widget( T * widget ) {
+        if( widget->notify() && dynamic_cast<NCWidget*>( widget ) )
+        {
+            NCursesEvent event = NCursesEvent::Activated;
+            event.widget = dynamic_cast<NCWidget*>( widget );
+            YNCHttpUI::ui()->sendEvent( event );
+        }
+    }
+
+    template<typename T, typename I>
+    void activate_nc_widget( T * widget , I * item) {
+        if( widget->notify() && dynamic_cast<NCWidget*>( widget ) )
+        {
+            NCursesEvent event( NCursesEvent::menu );
+            event.selection = (YMenuItem *) item;
+            event.widget = dynamic_cast<NCWidget*>( widget );
+            YNCHttpUI::ui()->sendEvent( event );
+        }
+    }
+
+};
+
+#endif //YNCWidgetActionHandler_h
_______________________________________________
openSUSE Commits mailing list -- [email protected]
To unsubscribe, email [email protected]
List Netiquette: https://en.opensuse.org/openSUSE:Mailing_list_netiquette
List Archives: 
https://lists.opensuse.org/archives/list/[email protected]

Reply via email to