~emersion/goguma-dev

This thread contains a patchset. You're looking at the original emails, but you may wish to use the patch review UI. Review patch
2

[PATCH] Order buffer members in a case-insensitive order

Details
Message ID
<20220902120837.7225-1-delthas@dille.cc>
DKIM signature
pass
Download raw message
Patch: +1 -1
Previously, we would list nicks with an uppercase initial letter before
those with a lowercase nick.

This changes the logic so that we sort nicks in a case-insensitive
manner. There are no case insensitive compare functions in the Flutter
stdlib so we have to do a toLowerCase comparison. This is only run once
when opening buffer details so it should be OK wrt performance.
---
 lib/page/buffer_details.dart | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/page/buffer_details.dart b/lib/page/buffer_details.dart
index 760ebbd..29abc05 100644
--- a/lib/page/buffer_details.dart
+++ b/lib/page/buffer_details.dart
@@ -86,7 +86,7 @@ class _BufferDetailsPageState extends State<BufferDetailsPage> {
			if (i != j) {
				return i - j;
			}
			return a.nickname.compareTo(b.nickname);
			return a.nickname.toLowerCase().compareTo(b.nickname.toLowerCase());
		});

		setState(() {

base-commit: c98e7ac19013c4b331ddc87da62c20e0f1cdf506
-- 
2.17.1
Details
Message ID
<sYZNnIVlpbNuX166Jhpp4WwuWCOWgFdHxpVpUlIQztOLKRBYIf9Y6eoOjZ-3BdqscT0XUQCY2cN2hTXKPScLdN_4uufFc4gd_iPsUah0pBU=@emersion.fr>
In-Reply-To
<20220902120837.7225-1-delthas@dille.cc> (view parent)
DKIM signature
pass
Download raw message
Can we do the same for buffers as well?

lib/models.dart:352:                    return a.name.compareTo(b.name);
Details
Message ID
<KgGKQt0NhIckRnTSQLVCb1Wu0HLFA4jopKW04Mvj3McznJLiBxmunRyi5NuPAdClG4H5jilfyiGIGN_CWT1A2XR8FQl_8CHoLtEFwLq-rc4=@emersion.fr>
In-Reply-To
<sYZNnIVlpbNuX166Jhpp4WwuWCOWgFdHxpVpUlIQztOLKRBYIf9Y6eoOjZ-3BdqscT0XUQCY2cN2hTXKPScLdN_4uufFc4gd_iPsUah0pBU=@emersion.fr> (view parent)
DKIM signature
pass
Download raw message
On Friday, September 2nd, 2022 at 15:35, Simon Ser <contact@emersion.fr> wrote:

> Can we do the same for buffers as well?
> 
> lib/models.dart:352: return a.name.compareTo(b.name);

Pushed with that call updated as well, thanks.
Reply to thread Export thread (mbox)