Bug 93317 - "Document has been modified" Dialog does not have the focus on GTK3.
Summary: "Document has been modified" Dialog does not have the focus on GTK3.
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: UI (show other bugs)
Version:
(earliest affected)
5.0.1.2 release
Hardware: x86-64 (AMD64) Linux (All)
: medium minor
Assignee: Caolán McNamara
URL:
Whiteboard: target:5.1.0 target:5.0.4
Keywords:
Depends on:
Blocks:
 
Reported: 2015-08-10 08:57 UTC by chrys87@web.de
Modified: 2016-10-25 19:20 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description chrys87@web.de 2015-08-10 08:57:31 UTC
Hi,

I m currently using the Libre Office 5.0 release with GTK3 backend on my Arch Linux machine. 
I found a problem with focusing the ""The document "XYZ" has been modified. Do you want to save your changes?" Dialog.

Reproduce:
1. Open Libreoffice wint GTK3
2. Type "hello world"
3. Try to close the application

after doing that a dialog appears ""The document "XYZ" has been modified. Do you want to save your changes?"

result:
this dialog doesnt have the focus and is not focusable with the keyboard (tab, ctrl + tab)

expect:
the dialog should focused and i could navigate with the keyboard.

In earlier versions of LO this dialog was focused.
Comment 1 chrys87@web.de 2015-08-28 11:41:06 UTC
Here some additional information:

this seems only to happen if i try to close lo with alt + F4.
if i Press the X in the window bar, the "Document has been modified" dialog has the focus.
if i press alt + F4 the "Document has been modified" does not have the focus and you are not able to focus it with the keyboard.

I can also see this in the most current 5.0.1 version.
Comment 2 Buovjaga 2015-09-24 06:04:42 UTC
(In reply to chrys87@web.de from comment #1)
> Here some additional information:
> 
> this seems only to happen if i try to close lo with alt + F4.
> if i Press the X in the window bar, the "Document has been modified" dialog
> has the focus.
> if i press alt + F4 the "Document has been modified" does not have the focus
> and you are not able to focus it with the keyboard.
> 
> I can also see this in the most current 5.0.1 version.

Reproduced.

Arch Linux 64-bit, Gnome3, LibO 5.0.1
Comment 3 Caolán McNamara 2015-11-12 14:38:56 UTC
ctrl+q also sets the focus to the dialog, so its only the alt+f4 that denies it. So perhaps its alt key handling.
Comment 4 Commit Notification 2015-11-12 16:07:18 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=82abd23f3ee1900b7579e5a0afa23581d5836f01

Resolves: tdf#93317 Modified Document Dialog misses focus on Gtk3

It will be available in 5.1.0.

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

Affected users are encouraged to test the fix and report feedback.
Comment 5 Caolán McNamara 2015-11-12 16:09:49 UTC
simplest thing seems to be to use totop for all dialogs in order to get that to call gtk_widget_present. Backport to 5-0 as https://gerrit.libreoffice.org/#/c/19933/
Comment 6 Commit Notification 2015-11-12 22:02:11 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-5-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=5a1d267a1ed7557db3fe4c73bc0749c885f0ebef&h=libreoffice-5-0

Resolves: tdf#93317 Modified Document Dialog misses focus on Gtk3

It will be available in 5.0.4.

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

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