Bug 154565 - Typing with Alt + Down List open replaces entry when hovered over
Summary: Typing with Alt + Down List open replaces entry when hovered over
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.3.7.2 release
Hardware: All Linux (All)
: medium normal
Assignee: Caolán McNamara
URL:
Whiteboard: target:7.6.0 target:7.5.3
Keywords: bibisected, bisected, regression
Depends on:
Blocks: GTK3
  Show dependency treegraph
 
Reported: 2023-04-02 13:25 UTC by Leona Go.
Modified: 2023-04-13 08:48 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Sample Document (9.49 KB, application/vnd.oasis.opendocument.spreadsheet)
2023-04-02 16:12 UTC, Rainer Bielefeld Retired
Details
Video recording of my reproducing the bug (110.51 KB, video/webm)
2023-04-02 23:27 UTC, Leona Go.
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Leona Go. 2023-04-02 13:25:15 UTC
Description:
The Alt + Down list is a useful tool to see which entries already exist in the column. When the mouse hovers over the list, Calc may silently disregard what you enter with your keyboard.

Steps to Reproduce:
1.Prepare a column by typing eg. a enter b enter c enter d in the first few rows
2.with the cell below selected, move your mouse pointer a short distance further down
3.Press Alt + Down, a list should appear under your pointer
4.Press a different letter to the one under your mouse
5. Press enter

Actual Results:
The cell contains the letter that was under your mouse

Expected Results:
The cell contains the letter I just entered


Reproducible: Always


User Profile Reset: No

Additional Info:
Version: 7.3.7.2
Build ID: 30(Build:2)
CPU threads: 4; OS: Linux 6.1; UI render: default; VCL: gtk3
Locale: de-DE (de_DE.UTF-8); UI: en-US
Calc: threaded

System: Laptop with touchpad
OS: Fedora Linux with gnome desktop
Comment 1 Rainer Bielefeld Retired 2023-04-02 16:12:53 UTC
Created attachment 186411 [details]
Sample Document

NOT reproducible with Installation of Version: 7.5.0.1 (X86_64)  
Build ID: 77cd3d7ad4445740a0c6cf977992dafd8ebad8df
CPU threads: 12; OS: Windows 10.0 Build 19044; 
UI render: default; VCL: win – Locale: de-DE (de_DE); UI: de-DE
Calc: threaded |  Elementary (SVG)  Theme  |  Normal UserProfile  

0. I have a column with a .... z
1. Click "d" in B4
2. <alt+downarrow>
   » List appears and shows a ... z (with scroll slider)
3. Move mouse pointer to "e" on list
  » "e" highlighted
4. Type "k"
  » "k" highlighted
5. <Enter>
  » "k" replaces "d" in B4
    That's what I expected

Also not reproducible with 7.0.0.1
Comment 2 ady 2023-04-02 20:44:47 UTC
This should only happen if after you move the selection with the keyboard or by typing a selection, you just (accidentally) move the mouse towards a different selection before hitting [ENTER]. Otherwise, no repro with 7.3.1.3 under Windows.
Comment 3 Leona Go. 2023-04-02 23:27:28 UTC
Created attachment 186422 [details]
Video recording of my reproducing the bug

I've compared with 7.0 and 7.5 on a windows system. Can't reproduce it there. Could be a bug specific to linux or to gtk3.
Anyway, I took a brief video
Comment 4 raal 2023-04-03 18:06:34 UTC
Confirm with Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 8e97ef854fb225dac37185c1911894b7d206fa8d
CPU threads: 4; OS: Linux 5.19; UI render: default; VCL: gtk3
Locale: cs-CZ (cs_CZ.UTF-8); UI: en-US
Calc: threaded

nor reproducible with Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 8e97ef854fb225dac37185c1911894b7d206fa8d
CPU threads: 4; OS: Linux 5.19; UI render: default; VCL: x11
Locale: cs-CZ (cs_CZ.UTF-8); UI: en-US
Calc: threaded
Comment 5 raal 2023-04-03 18:56:38 UTC
This seems to have begun at the below commit in bibisect repository/OS XXXX.
Adding Cc: to Caolán McNamara ; Could you possibly take a look at this one?
Thanks
 ae0e3286d974aa6ccfa132c5e4dbfe0621f260db is the first bad commit
commit ae0e3286d974aa6ccfa132c5e4dbfe0621f260db
Author: Jenkins Build User <tdf@pollux.tdf>
Date:   Tue Jun 16 09:46:15 2020 +0200

    source 83bacd2fd26fa4f772b467bbb2e1f903f3f388b6

96365: use hover-selection for filterlist dropdown | https://gerrit.libreoffice.org/c/core/+/96365
Comment 6 Caolán McNamara 2023-04-03 19:18:30 UTC
looks like the hover causes the entry under the mouse to be selected during the dropdown, tricky
Comment 7 Caolán McNamara 2023-04-04 08:56:03 UTC
in gtk gtk_tree_view_search_activate hides the search before activating the row. I feel its unintentional that hiding the search generates a mouse enter for the treelist underneath which then selects the row under the mouse before as a side effect before the activate row goes through
Comment 8 Caolán McNamara 2023-04-04 09:27:35 UTC
I think I can see a hacky route out of this dilemma
Comment 9 Commit Notification 2023-04-04 18:42:23 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/55d5648958f9d453688bba50706323c8deb30478

tdf#154565 ignore unwanted crossing event from search to treeview on "enter"

It will be available in 7.6.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 10 Caolán McNamara 2023-04-04 18:43:24 UTC
works for me in trunk, backport to 7-5 in gerrit
Comment 11 Commit Notification 2023-04-13 08:48:09 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-7-5":

https://git.libreoffice.org/core/commit/97105666430c3df41337e105a809c2e6109878a8

tdf#154565 ignore unwanted crossing event from search to treeview on "enter"

It will be available in 7.5.3.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.