All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] kconfig: qconf: Fix find on split mode
@ 2020-06-28 12:04 Mauro Carvalho Chehab
  0 siblings, 0 replies; 10+ messages in thread
From: Mauro Carvalho Chehab @ 2020-06-28 12:04 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Masahiro Yamada, linux-kbuild,
	linux-kernel, Maxim Levitsky

The logic handling find on split mode is currently broken.
Fix it, making it work again as expected.

Reported-by: Maxim Levitsky <mlevitsk@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
---
 scripts/kconfig/qconf.cc | 19 +++++++++----------
 1 file changed, 9 insertions(+), 10 deletions(-)

diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
index c0ac8f7b5f1a..b8f577c6e8aa 100644
--- a/scripts/kconfig/qconf.cc
+++ b/scripts/kconfig/qconf.cc
@@ -1645,22 +1645,21 @@ void ConfigMainWindow::setMenuLink(struct menu *menu)
 			return;
 		list->setRootMenu(parent);
 		break;
-	case symbolMode:
+	case menuMode:
 		if (menu->flags & MENU_ROOT) {
-			configList->setRootMenu(menu);
+			menuList->setRootMenu(menu);
 			configList->clearSelection();
-			list = menuList;
-		} else {
 			list = configList;
+		} else {
+			configList->setRootMenu(menu);
+			configList->clearSelection();
+
 			parent = menu_get_parent_menu(menu->parent);
 			if (!parent)
 				return;
-			item = menuList->findConfigItem(parent);
-			if (item) {
-				item->setSelected(true);
-				menuList->scrollToItem(item);
-			}
-			list->setRootMenu(parent);
+			menuList->setRootMenu(parent);
+
+			list = menuList;
 		}
 		break;
 	case fullMode:
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [PATCH] kconfig: qconf: Fix find on split mode
  2020-06-28 14:42     ` Masahiro Yamada
@ 2020-06-30  3:53       ` Masahiro Yamada
  0 siblings, 0 replies; 10+ messages in thread
From: Masahiro Yamada @ 2020-06-30  3:53 UTC (permalink / raw)
  To: Maxim Levitsky
  Cc: Mauro Carvalho Chehab, Linux Kbuild mailing list,
	Linux Kernel Mailing List

On Sun, Jun 28, 2020 at 11:42 PM Masahiro Yamada <masahiroy@kernel.org> wrote:
>
> On Sun, Jun 28, 2020 at 5:40 PM Maxim Levitsky <mlevitsk@redhat.com> wrote:
> >
> > On Thu, 2020-06-25 at 16:52 +0200, Mauro Carvalho Chehab wrote:
> > > The logic handling find on split mode is currently broken.
> > > Fix it, making it work again as expected.
> >
> > I tested this patch and it works well.
> > There is one really small cosmetic issue:
> >
> > If you select search result, and then select another search result
> > which happens not to update the 'menu', then both the results are
> > selected (that is the old one doesn't clear its selection)
>
> I see this too.
> So, this can be improved somehow...



I dropped this one
because it was superseded by the new version.


-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] kconfig: qconf: Fix find on split mode
  2020-06-28  8:40   ` Maxim Levitsky
@ 2020-06-28 14:42     ` Masahiro Yamada
  2020-06-30  3:53       ` Masahiro Yamada
  0 siblings, 1 reply; 10+ messages in thread
From: Masahiro Yamada @ 2020-06-28 14:42 UTC (permalink / raw)
  To: Maxim Levitsky
  Cc: Mauro Carvalho Chehab, Linux Kbuild mailing list,
	Linux Kernel Mailing List

On Sun, Jun 28, 2020 at 5:40 PM Maxim Levitsky <mlevitsk@redhat.com> wrote:
>
> On Thu, 2020-06-25 at 16:52 +0200, Mauro Carvalho Chehab wrote:
> > The logic handling find on split mode is currently broken.
> > Fix it, making it work again as expected.
>
> I tested this patch and it works well.
> There is one really small cosmetic issue:
>
> If you select search result, and then select another search result
> which happens not to update the 'menu', then both the results are
> selected (that is the old one doesn't clear its selection)

I see this too.
So, this can be improved somehow...



>
> Best regards,
>         Maxim Levitsky
>
> >
> > Reported-by: Maxim Levitsky <mlevitsk@redhat.com>
> > Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
> > ---
> >  scripts/kconfig/qconf.cc | 19 +++++++++----------
> >  1 file changed, 9 insertions(+), 10 deletions(-)
> >
> > diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
> > index c0ac8f7b5f1a..b8f577c6e8aa 100644
> > --- a/scripts/kconfig/qconf.cc
> > +++ b/scripts/kconfig/qconf.cc
> > @@ -1645,22 +1645,21 @@ void ConfigMainWindow::setMenuLink(struct menu *menu)
> >                       return;
> >               list->setRootMenu(parent);
> >               break;
> > -     case symbolMode:
> > +     case menuMode:
> >               if (menu->flags & MENU_ROOT) {
> > -                     configList->setRootMenu(menu);
> > +                     menuList->setRootMenu(menu);
> >                       configList->clearSelection();
> > -                     list = menuList;
> > -             } else {
> >                       list = configList;
> > +             } else {
> > +                     configList->setRootMenu(menu);
> > +                     configList->clearSelection();
> > +
> >                       parent = menu_get_parent_menu(menu->parent);
> >                       if (!parent)
> >                               return;
> > -                     item = menuList->findConfigItem(parent);
> > -                     if (item) {
> > -                             item->setSelected(true);
> > -                             menuList->scrollToItem(item);
> > -                     }
> > -                     list->setRootMenu(parent);
> > +                     menuList->setRootMenu(parent);
> > +
> > +                     list = menuList;
> >               }
> >               break;
> >       case fullMode:
>
>


-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] kconfig: qconf: Fix find on split mode
  2020-06-28 12:18 ` Markus Elfring
@ 2020-06-28 12:26   ` Mauro Carvalho Chehab
  -1 siblings, 0 replies; 10+ messages in thread
From: Mauro Carvalho Chehab @ 2020-06-28 12:26 UTC (permalink / raw)
  To: Markus Elfring
  Cc: linux-kbuild, linux-media, linux-kernel, kernel-janitors,
	Masahiro Yamada, Maxim Levitsky

Em Sun, 28 Jun 2020 14:18:22 +0200
Markus Elfring <Markus.Elfring@web.de> escreveu:

> > The logic handling find on split mode is currently broken.  
> 
> * Is there a word missing in this change description?
> 
> * Can any information become clearer another bit?
> 
> 
> > Fix it, …  
> 
> Please replace the beginning of this sentence with the tag “Fixes”.
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?id=719fdd32921fb7e3208db8832d32ae1c2d68900f#n183
> 
> Regards,
> Markus

Please ignore this one. I ended re-submitting a previously
merged patch.

Thanks,
Mauro

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] kconfig: qconf: Fix find on split mode
@ 2020-06-28 12:26   ` Mauro Carvalho Chehab
  0 siblings, 0 replies; 10+ messages in thread
From: Mauro Carvalho Chehab @ 2020-06-28 12:26 UTC (permalink / raw)
  To: Markus Elfring
  Cc: linux-kbuild, linux-media, linux-kernel, kernel-janitors,
	Masahiro Yamada, Maxim Levitsky

Em Sun, 28 Jun 2020 14:18:22 +0200
Markus Elfring <Markus.Elfring@web.de> escreveu:

> > The logic handling find on split mode is currently broken.  
> 
> * Is there a word missing in this change description?
> 
> * Can any information become clearer another bit?
> 
> 
> > Fix it, …  
> 
> Please replace the beginning of this sentence with the tag “Fixes”.
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?id=719fdd32921fb7e3208db8832d32ae1c2d68900f#n183
> 
> Regards,
> Markus

Please ignore this one. I ended re-submitting a previously
merged patch.

Thanks,
Mauro

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] kconfig: qconf: Fix find on split mode
@ 2020-06-28 12:18 ` Markus Elfring
  0 siblings, 0 replies; 10+ messages in thread
From: Markus Elfring @ 2020-06-28 12:18 UTC (permalink / raw)
  To: Mauro Carvalho Chehab, linux-kbuild, linux-media
  Cc: linux-kernel, kernel-janitors, Masahiro Yamada, Maxim Levitsky

> The logic handling find on split mode is currently broken.

* Is there a word missing in this change description?

* Can any information become clearer another bit?


> Fix it, …

Please replace the beginning of this sentence with the tag “Fixes”.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?id=719fdd32921fb7e3208db8832d32ae1c2d68900f#n183

Regards,
Markus

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] kconfig: qconf: Fix find on split mode
@ 2020-06-28 12:18 ` Markus Elfring
  0 siblings, 0 replies; 10+ messages in thread
From: Markus Elfring @ 2020-06-28 12:18 UTC (permalink / raw)
  To: Mauro Carvalho Chehab, linux-kbuild, linux-media
  Cc: linux-kernel, kernel-janitors, Masahiro Yamada, Maxim Levitsky

> The logic handling find on split mode is currently broken.

* Is there a word missing in this change description?

* Can any information become clearer another bit?


> Fix it, …

Please replace the beginning of this sentence with the tag “Fixes”.
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?id=719fdd32921fb7e3208db8832d32ae1c2d68900f#n183

Regards,
Markus

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] kconfig: qconf: Fix find on split mode
  2020-06-25 14:52 ` [PATCH] kconfig: qconf: Fix find on split mode Mauro Carvalho Chehab
  2020-06-28  2:17   ` Masahiro Yamada
@ 2020-06-28  8:40   ` Maxim Levitsky
  2020-06-28 14:42     ` Masahiro Yamada
  1 sibling, 1 reply; 10+ messages in thread
From: Maxim Levitsky @ 2020-06-28  8:40 UTC (permalink / raw)
  To: Mauro Carvalho Chehab, Masahiro Yamada; +Cc: linux-kbuild, linux-kernel

On Thu, 2020-06-25 at 16:52 +0200, Mauro Carvalho Chehab wrote:
> The logic handling find on split mode is currently broken.
> Fix it, making it work again as expected.

I tested this patch and it works well.
There is one really small cosmetic issue:

If you select search result, and then select another search result
which happens not to update the 'menu', then both the results are
selected (that is the old one doesn't clear its selection)

Best regards,
	Maxim Levitsky

> 
> Reported-by: Maxim Levitsky <mlevitsk@redhat.com>
> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
> ---
>  scripts/kconfig/qconf.cc | 19 +++++++++----------
>  1 file changed, 9 insertions(+), 10 deletions(-)
> 
> diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
> index c0ac8f7b5f1a..b8f577c6e8aa 100644
> --- a/scripts/kconfig/qconf.cc
> +++ b/scripts/kconfig/qconf.cc
> @@ -1645,22 +1645,21 @@ void ConfigMainWindow::setMenuLink(struct menu *menu)
>  			return;
>  		list->setRootMenu(parent);
>  		break;
> -	case symbolMode:
> +	case menuMode:
>  		if (menu->flags & MENU_ROOT) {
> -			configList->setRootMenu(menu);
> +			menuList->setRootMenu(menu);
>  			configList->clearSelection();
> -			list = menuList;
> -		} else {
>  			list = configList;
> +		} else {
> +			configList->setRootMenu(menu);
> +			configList->clearSelection();
> +
>  			parent = menu_get_parent_menu(menu->parent);
>  			if (!parent)
>  				return;
> -			item = menuList->findConfigItem(parent);
> -			if (item) {
> -				item->setSelected(true);
> -				menuList->scrollToItem(item);
> -			}
> -			list->setRootMenu(parent);
> +			menuList->setRootMenu(parent);
> +
> +			list = menuList;
>  		}
>  		break;
>  	case fullMode:



^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] kconfig: qconf: Fix find on split mode
  2020-06-25 14:52 ` [PATCH] kconfig: qconf: Fix find on split mode Mauro Carvalho Chehab
@ 2020-06-28  2:17   ` Masahiro Yamada
  2020-06-28  8:40   ` Maxim Levitsky
  1 sibling, 0 replies; 10+ messages in thread
From: Masahiro Yamada @ 2020-06-28  2:17 UTC (permalink / raw)
  To: Mauro Carvalho Chehab
  Cc: Linux Kbuild mailing list, Linux Kernel Mailing List, Maxim Levitsky

On Thu, Jun 25, 2020 at 11:53 PM Mauro Carvalho Chehab
<mchehab+huawei@kernel.org> wrote:
>
> The logic handling find on split mode is currently broken.
> Fix it, making it work again as expected.
>
> Reported-by: Maxim Levitsky <mlevitsk@redhat.com>
> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
> ---


Applied to linux-kbuild.
Thanks.


>  scripts/kconfig/qconf.cc | 19 +++++++++----------
>  1 file changed, 9 insertions(+), 10 deletions(-)
>
> diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
> index c0ac8f7b5f1a..b8f577c6e8aa 100644
> --- a/scripts/kconfig/qconf.cc
> +++ b/scripts/kconfig/qconf.cc
> @@ -1645,22 +1645,21 @@ void ConfigMainWindow::setMenuLink(struct menu *menu)
>                         return;
>                 list->setRootMenu(parent);
>                 break;
> -       case symbolMode:
> +       case menuMode:
>                 if (menu->flags & MENU_ROOT) {
> -                       configList->setRootMenu(menu);
> +                       menuList->setRootMenu(menu);
>                         configList->clearSelection();
> -                       list = menuList;
> -               } else {
>                         list = configList;
> +               } else {
> +                       configList->setRootMenu(menu);
> +                       configList->clearSelection();
> +
>                         parent = menu_get_parent_menu(menu->parent);
>                         if (!parent)
>                                 return;
> -                       item = menuList->findConfigItem(parent);
> -                       if (item) {
> -                               item->setSelected(true);
> -                               menuList->scrollToItem(item);
> -                       }
> -                       list->setRootMenu(parent);
> +                       menuList->setRootMenu(parent);
> +
> +                       list = menuList;
>                 }
>                 break;
>         case fullMode:
> --
> 2.26.2
>
>


-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH] kconfig: qconf: Fix find on split mode
  2020-06-25 13:42 Search function in xconfig is partially broken after recent changes Mauro Carvalho Chehab
@ 2020-06-25 14:52 ` Mauro Carvalho Chehab
  2020-06-28  2:17   ` Masahiro Yamada
  2020-06-28  8:40   ` Maxim Levitsky
  0 siblings, 2 replies; 10+ messages in thread
From: Mauro Carvalho Chehab @ 2020-06-25 14:52 UTC (permalink / raw)
  To: Masahiro Yamada
  Cc: Mauro Carvalho Chehab, linux-kbuild, linux-kernel, Maxim Levitsky

The logic handling find on split mode is currently broken.
Fix it, making it work again as expected.

Reported-by: Maxim Levitsky <mlevitsk@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
---
 scripts/kconfig/qconf.cc | 19 +++++++++----------
 1 file changed, 9 insertions(+), 10 deletions(-)

diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
index c0ac8f7b5f1a..b8f577c6e8aa 100644
--- a/scripts/kconfig/qconf.cc
+++ b/scripts/kconfig/qconf.cc
@@ -1645,22 +1645,21 @@ void ConfigMainWindow::setMenuLink(struct menu *menu)
 			return;
 		list->setRootMenu(parent);
 		break;
-	case symbolMode:
+	case menuMode:
 		if (menu->flags & MENU_ROOT) {
-			configList->setRootMenu(menu);
+			menuList->setRootMenu(menu);
 			configList->clearSelection();
-			list = menuList;
-		} else {
 			list = configList;
+		} else {
+			configList->setRootMenu(menu);
+			configList->clearSelection();
+
 			parent = menu_get_parent_menu(menu->parent);
 			if (!parent)
 				return;
-			item = menuList->findConfigItem(parent);
-			if (item) {
-				item->setSelected(true);
-				menuList->scrollToItem(item);
-			}
-			list->setRootMenu(parent);
+			menuList->setRootMenu(parent);
+
+			list = menuList;
 		}
 		break;
 	case fullMode:
-- 
2.26.2



^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2020-06-30  3:54 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-28 12:04 [PATCH] kconfig: qconf: Fix find on split mode Mauro Carvalho Chehab
  -- strict thread matches above, loose matches on Subject: below --
2020-06-28 12:18 Markus Elfring
2020-06-28 12:18 ` Markus Elfring
2020-06-28 12:26 ` Mauro Carvalho Chehab
2020-06-28 12:26   ` Mauro Carvalho Chehab
2020-06-25 13:42 Search function in xconfig is partially broken after recent changes Mauro Carvalho Chehab
2020-06-25 14:52 ` [PATCH] kconfig: qconf: Fix find on split mode Mauro Carvalho Chehab
2020-06-28  2:17   ` Masahiro Yamada
2020-06-28  8:40   ` Maxim Levitsky
2020-06-28 14:42     ` Masahiro Yamada
2020-06-30  3:53       ` Masahiro Yamada

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.