After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 642706 - No way to select the default entry
No way to select the default entry
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: GtkAppChooser
3.0.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
Cosimo Cecchi
Depends on:
Blocks:
 
 
Reported: 2011-02-18 19:19 UTC by Bastien Nocera
Modified: 2011-09-10 06:01 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
appchooserbutton: add API to show the default application on top (8.47 KB, patch)
2011-02-21 21:06 UTC, Cosimo Cecchi
none Details | Review
appchooserbutton: add API to show the default application on top (8.67 KB, patch)
2011-02-21 21:11 UTC, Cosimo Cecchi
none Details | Review
GtkAppChooserButton: Add a way to include the default app (21.95 KB, patch)
2011-09-10 05:42 UTC, Matthias Clasen
committed Details | Review

Description Bastien Nocera 2011-02-18 19:19:08 UTC
When using GtkAppChooserButton in control-center's info panel, I have no way to select which application should be the "selected by default" application, which means that instead of seeing the default application for a particular mime-type, we see the last used application for it.
Comment 1 Bastien Nocera 2011-02-18 19:26:17 UTC
This is what I had to do in the info panel:
http://git.gnome.org/browse/gnome-control-center/commit/?id=f05f6307d72974ff22e1fddd0e83747794d5783a
Comment 2 Cosimo Cecchi 2011-02-21 21:06:15 UTC
Created attachment 181518 [details] [review]
appchooserbutton: add API to show the default application on top
Comment 3 Cosimo Cecchi 2011-02-21 21:06:49 UTC
The attached patch should work for your use case.
Comment 4 Cosimo Cecchi 2011-02-21 21:11:31 UTC
Created attachment 181519 [details] [review]
appchooserbutton: add API to show the default application on top

Better patch, with some leaks fixed.
Comment 5 Matthias Clasen 2011-05-02 14:16:49 UTC
Is this about showing the default app, or about selecting it initially ?

I think we need some documentation additions about the topic of what gets shown, and what gets selected initially. That should also talk about last-used vs default. Would probably be ok in the long desc of GtkAppChooser or GtkAppChooserWidget.
Comment 6 Bastien Nocera 2011-05-03 11:59:29 UTC
(In reply to comment #5)
> Is this about showing the default app, or about selecting it initially ?

The default app is shown, but it's possible that the default app wouldn't be the default selected one, as it might not be the "last used" one.

> I think we need some documentation additions about the topic of what gets
> shown, and what gets selected initially. That should also talk about last-used
> vs default. Would probably be ok in the long desc of GtkAppChooser or
> GtkAppChooserWidget.

Definitely. I also don't like the name for the new function/properties, as it makes it look like the default application wouldn't be shown if the property was enabled.
Comment 7 Matthias Clasen 2011-09-10 05:42:32 UTC
The following fix has been pushed:
f9379ad GtkAppChooserButton: Add a way to include the default app
Comment 8 Matthias Clasen 2011-09-10 05:42:35 UTC
Created attachment 196161 [details] [review]
GtkAppChooserButton: Add a way to include the default app

This is necessary to use an app chooser button for selecting
default apps in the control center. Also, beef up the docs
for this widget family.
Comment 9 Matthias Clasen 2011-09-10 06:01:27 UTC
Filed bug 658693 to bring this back to the control-center side.