Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 411452 - [GTK3] Search dialogue isn't "reusable" when using export SWT_GTK3=1
Summary: [GTK3] Search dialogue isn't "reusable" when using export SWT_GTK3=1
Status: VERIFIED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.3   Edit
Hardware: PC Linux
: P3 major (vote)
Target Milestone: 4.4 M2   Edit
Assignee: Alexander Kurtakov CLA
QA Contact: Arun Thondapu CLA
URL:
Whiteboard:
Keywords:
: 408266 (view as bug list)
Depends on:
Blocks: 340067
  Show dependency tree
 
Reported: 2013-06-23 20:13 EDT by David Williams CLA
Modified: 2020-05-25 04:47 EDT (History)
5 users (show)

See Also:
Silenio_Quarti: review+


Attachments
log showing "gtk errors" while using search dialog (35.14 KB, text/plain)
2013-06-23 20:13 EDT, David Williams CLA
no flags Details
Proposed fix (1011 bytes, patch)
2013-08-15 11:11 EDT, Alexander Kurtakov CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Williams CLA 2013-06-23 20:13:55 EDT
Created attachment 232679 [details]
log showing "gtk errors" while using search dialog

I tried using 
export SWT_GTK3=1
for a while, but found that "global file search" does not work well with that enabled. 

It works the first time, but subsequent searches searches with same options, no matter what I try. Will work (once) again, if I restart Eclipse. 

Details, 

Select package explorer, then Search (with "File" dialogue ... haven't tried other types). Fill in something like "antrun" and search through all "pom.xml" in workspace. Click 'Search' button, the dialog goes away, and matching files are displayed as expected. 

Now, try a section time, say search for "abc" in any file, click 'Search'. First notice the Search Dialog does not go away (is not dismissed, or closed) and the original "antrun" search (on  pom.xml files) is redisplayed (you can see search results being refreshed, as though repeating the search, but with old values). 

Log has "gtk" errors in it related to "tree items" ... hence might be related to other GTK3 bugs ... hard to tell.
Comment 1 Arun Thondapu CLA 2013-06-25 10:59:45 EDT
Just tested with 4.3 RC4 and was able to reproduce the bug with the exact same stack trace in the log... will try to debug.
Comment 2 Alexander Kurtakov CLA 2013-08-14 12:01:07 EDT
*** Bug 408266 has been marked as a duplicate of this bug. ***
Comment 3 Alexander Kurtakov CLA 2013-08-15 11:11:36 EDT
Created attachment 234461 [details]
Proposed fix
Comment 4 Alexander Kurtakov CLA 2013-08-15 11:14:31 EDT
The proposed fix disconnects the model from the view which seems to fix the problem. It also seems to cause no troubles on gtk 2.x so I would rather not guard it for gtk 3.x unless needed.
Comment 5 Silenio Quarti CLA 2013-08-16 09:50:49 EDT
The fix looks fine. Is it necessary on Table.removeAll() as well?
Comment 6 Alexander Kurtakov CLA 2013-08-16 09:58:37 EDT
(In reply to comment #5)
> The fix looks fine. Is it necessary on Table.removeAll() as well?

I don't think so because Table doesn't rely on gtk_tree_model_get to retrieve the index while Tree does and that's where things are going out of sync.
Comment 8 Alexander Kurtakov CLA 2013-08-20 08:03:49 EDT
Mark as fixed.