Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 364765 - Update toolbar items to GtkToolItem.
Summary: Update toolbar items to GtkToolItem.
Status: CLOSED DUPLICATE of bug 46025
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.8   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Arun Thondapu CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 340067
  Show dependency tree
 
Reported: 2011-11-24 16:20 EST by Alexander Kurtakov CLA
Modified: 2012-03-22 06:03 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Kurtakov CLA 2011-11-24 16:20:07 EST
Implementation is using gtk 2.4 apis only. The ugly part is that dropdown is implemented in a weird way because GtkMenuToolButton has been added in gtk 2.6.
One less gtk 2.24 deprecation warning.

This patch is a bit bigger as it is basically redoing the native part to use the GtkToolItem which is there since gtk 2.4. The drop-down aka GtkMenuToolItem has been added in gtk 2.6 that's why it is reimplemented here.
Commit/patch http://fedorapeople.org/gitweb?p=akurtakov/public_git/eclipse.platform.swt.git;a=commit;h=900294e8219cc962a3db85a61f3c96dfba51efd0
Comment 1 Silenio Quarti CLA 2011-11-29 14:32:57 EST
There is another bug with similar changes. Arun, please link these bugs.
Comment 2 Alexander Kurtakov CLA 2011-12-02 02:54:20 EST
I haven't succeeded in finding this bug. I agree this is a big change to the way tool items are implemented and I'm definetelye interested to see/incorporate any improvements.
Comment 3 Arun Thondapu CLA 2011-12-02 03:23:10 EST
Bug 46026 has similar changes, I haven't looked at all the changes here yet but we'll probably need to merge the changes in both the bugs.
Comment 4 Arun Thondapu CLA 2011-12-02 03:24:49 EST
(In reply to comment #3)
> Bug 46026 has similar changes, I haven't looked at all the changes here yet but
> we'll probably need to merge the changes in both the bugs.

I'm sorry, that must read bug 46025.
Comment 5 Alexander Kurtakov CLA 2012-01-20 14:55:53 EST
I'm really not sure whether my approach is better to in regards to the DROP_DOWN.
In the other patch it's done with native calls for gtk 2.6 and emulated for 2.4. 
As it looks like the patch in bug 46025 has been put to deeper review I would be more than happy to drop mine and do other changes if needed if SWT developers decide to not spend time reviewing similar changes again.
The rest of the changes are pretty much the same.
In short patch in bug 46025 is a bit outdated but reviewed few times, while mine is more uptodate but unreviewed and I don't have native gtk dropdown support for gtk newer than 2.6.
Please give an advice how do you want to proceed.
Comment 6 Arun Thondapu CLA 2012-01-21 14:41:08 EST
(In reply to comment #5)
> Please give an advice how do you want to proceed.

Hi Alex, I'm actually looking at changes from both the patches and trying to see if we can merge code from both and get a working version.

Thanks!
Comment 7 Arun Thondapu CLA 2012-02-22 06:08:25 EST
Alex,

I went through both the patches as referred in comment 6 and I have mostly picked up changes from the older patch as apart from using GtkToolItem APIs, it has more changes to handle the WRAP style for Toolbar using the GTK overflow menu.

In my opinion, this bug can be closed as duplicate of bug 46025. Let me know if you're fine with that.

Thanks!
Comment 8 Alexander Kurtakov CLA 2012-02-22 06:57:09 EST
I don't mind it at all as soon as we get the deprecations away for GTK3. Whatever patch is used is better than current situation and I'm not at all in love with my code in this case :).
Comment 9 Alexander Kurtakov CLA 2012-03-21 17:54:02 EDT
Any news on that one? Will it make for Juno?
Comment 10 Arun Thondapu CLA 2012-03-22 06:01:52 EDT
(In reply to comment #9)
> Any news on that one? Will it make for Juno?

Most likely, targeted for M7. Current changes are in this branch - http://git.eclipse.org/c/platform/eclipse.platform.swt.git/log/?h=bug46025
Will be merged into master after the few pending problems are fixed.

Thanks!
Comment 11 Arun Thondapu CLA 2012-03-22 06:03:26 EDT

*** This bug has been marked as a duplicate of bug 46025 ***