All users were logged out of Bugzilla on October 13th, 2018

[gtk2] XIM: focus problem

RESOLVED DUPLICATE of bug 176514

Status

()

RESOLVED DUPLICATE of bug 176514
16 years ago
16 years ago

People

(Reporter: masaki.katakai, Assigned: masaki.katakai)

Tracking

Trunk
x86
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

16 years ago
I'm using Mozilla GTK2 on GNOME2.0 on Solaris. There are some
problem in focus management when I'm using candidate window
(lookup choice region) in current XIM codes.

For example, ATOK12 does not work well with candidate window.
Preedit drawing and committing text do not work just after
candidate window is invoked.

1. enable IME
2. input some characters
3. hit space, space
   candidate window is invoked
   The candidate window grabs input focus
4. hit return key
   current candidate should be committed

But always the preedit string disappears.

Usually, in step 3, candidate window grabs an input focus
from Mozilla window, which means gFocusWindow is set to
NULL. However, IME needs to send preedit draw and commit
to the widget. Currently, IM_preedit_changed_cb() and
IM_commit_cb() are using only gFocusWindow but needs to
look for the last focused window when gFocusWindow is NULL.
(Assignee)

Comment 1

16 years ago
Created attachment 112137 [details] [diff] [review]
patch
(Assignee)

Comment 2

16 years ago
China team, can anyone take this bug? I attached the proposed patch.

Comment 3

16 years ago
taking
Assignee: jaggernaut → robin.lu
(Assignee)

Comment 4

16 years ago
Taking to myself.

I found another problem for focusing because current
implementation creates ic even for eWindowType_popup.

1. compile with USE_XIM
2. start Mozilla
3. create two tabs
4. browse a page that will auto-reload e.g. my.yahoo.com
5. browse a page that has input form field on 2nd tab
6. turn conversion mode on on the input field
7. try to input something

At reloading happens on the 1st tab, input can not be
continued on the 2nd tab. Because gtk_im_context_reset()
is called at destroy of 1st tab's ic. we create ic for
eWindowType_popup, there are many ic-s created for one
browser shell.

We should do this for dialog and toplevel.

Assignee: robin.lu → katakai
Summary: [gtk2] XIM: focus problem with candidate window → [gtk2] XIM: focus problem
(Assignee)

Comment 5

16 years ago
Created attachment 115706 [details] [diff] [review]
2nd patch

- provide gIMEFocusWindow as last-focused-window for ic
  this is needed to send input event from candidate window
  while Mozilla does not have input focus 
- create im_context at the first focus
  moved creation codes to SetFocus() from NativeCreate()
- ic_context creation will happen per shell - dialog and toplevel
these are the same with gtk1.2 IM codes.
(Assignee)

Updated

16 years ago
Attachment #112137 - Attachment is obsolete: true
(Assignee)

Updated

16 years ago
Attachment #115706 - Flags: review?(blizzard)
(Assignee)

Updated

16 years ago
Attachment #115706 - Flags: review?(blizzard)
(Assignee)

Comment 6

16 years ago
I should work on this as bug 176514.

*** This bug has been marked as a duplicate of 176514 ***
Status: NEW → RESOLVED
Last Resolved: 16 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.