Bug 109738 - Preferred Applications does not change https and unknown gconf keys
Preferred Applications does not change https and unknown gconf keys
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: control-center (Show other bugs)
rawhide
All Linux
high Severity medium
: ---
: ---
Assigned To: Jonathan Blandford
David Lawrence
:
: 117286 131670 134087 (view as bug list)
Depends On:
Blocks: FC3Target 131589
  Show dependency treegraph
 
Reported: 2003-11-11 10:30 EST by Gregory R. Kramer
Modified: 2013-04-02 00:20 EDT (History)
10 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-10-08 09:44:36 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
Set https keys when user chooses preferred browser. Also fix typo in key name "need-terminal". (4.81 KB, patch)
2003-12-20 18:55 EST, Ray Strode
no flags Details | Diff
control-center-2.5.3-preferred.patch (11.03 KB, patch)
2004-03-08 14:17 EST, Warren Togami
no flags Details | Diff
control-center-2.5.4-http-https-unknown-for-upstream.patch (4.31 KB, patch)
2004-03-18 00:29 EST, Warren Togami
no flags Details | Diff
control-center-2.5.4-fedora-apps.patch (2.54 KB, patch)
2004-03-18 00:31 EST, Warren Togami
no flags Details | Diff
control-center-2.5.4-fedora-apps.patch (3.00 KB, patch)
2004-03-18 04:54 EST, Warren Togami
no flags Details | Diff
control-center-2.5.4-setbrowsers-for-upstream.patch (5.38 KB, patch)
2004-03-18 04:56 EST, Warren Togami
no flags Details | Diff

  None (edit)
Description Gregory R. Kramer 2003-11-11 10:30:28 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4.1)
Gecko/20031030 Epiphany/1.0.4

Description of problem:
Using the GNOME control panel Preferred-Applications dialog I had
previously set my preferred web browser to Epiphany. I then received
an email in Evolution that included an https link, and I clicked on
the link. Evolution launches Mozilla instead of Epiphany to view the
website. I went back to the control panel and Epiphany is still
selected as the preferred web browser. Mozilla shouldn't have been
launched to view the link.

Version-Release number of selected component (if applicable):
evolution-1.4.5-7

How reproducible:
Always

Steps to Reproduce:
1. Use the GNOME control panel: Preferred-Applications to select
Epiphany as your preferred web browser.
2. Open Evolution and send yourself an email with a link to
https://www.53.com (just an example, this works for any https site I
have tried).
3. Receive the email and click on the link to open it in a browser
4. Watch Mozilla open the website instead of Epiphany.
    

Actual Results:  Mozilla launches to display the website.

Expected Results:  Epiphany should have launched to view the website.

Additional info:

Evolution honors the preferred web browser application for http links.
It just seems to default to mozilla when the link is to an https site.
Additionally, I have tried manually opening the https sites in
Epiphany and they display correctly.
Comment 1 Jeremy Katz 2003-11-11 11:17:04 EST
Confusingly, there's also a separate https entry in Preferences->File
Types and Programs that you have to set as well...
Comment 2 Gregory R. Kramer 2003-11-11 15:01:45 EST
Found another weird behavior. I have chosen Epiphany as my default web
browser via Preferences->Preferred Applications. If I then look under
Preferences->File Types and Programs it also now lists Epiphany.
However, if I double click on an file ending in .html under Nautilus,
it opens Mozilla to view the document. 
Comment 3 Warren Togami 2003-12-11 00:38:09 EST
The problem is that control-center's
gnome-default-applications-properties program sets only the http gconf
key, while there is also a https and unknown key that should be set. 
Other applications like htmlview use the unknown key.

/desktop/gnome/url-handlers/http/command
  This key is set
/desktop/gnome/url-handlers/https/command
/desktop/gnome/url-handlers/unknown/command
  But these two are not set

control-center-2.4.0/capplets/default-applications
  The relevant code is within this directory.  Changing it to edit all
three keys will require some code refactoring.
Comment 4 Ray Strode 2003-12-20 18:55:55 EST
Created attachment 96656 [details]
Set https keys when user chooses preferred browser.  Also fix typo in key name "need-terminal".
Comment 5 Warren Togami 2003-12-21 02:55:01 EST
Given that the current default for the three keys are:
http     htmlview %s
https    htmlview %s
unknown  mozilla "%s"

htmlview reads the unknown key in order to choose a browser.  It seems
that the intent of unknown was a catch all for any protocol that uses
a browser.  For this reason I believe unknown should also be set, but
Red Hat and Gnome can decide.
Comment 6 Warren Togami 2004-03-08 14:17:15 EST
Created attachment 98379 [details]
control-center-2.5.3-preferred.patch

* Fixes drop down menu options
* Fixes s/needs_terminal/need-terminal/ typo
* Changes http, https, and unknown keys rather than just http key

BuildRequires: eel2-devel is also missing from the spec.

Let me know and I will apply & build into fc2.
Comment 7 Warren Togami 2004-03-09 00:42:27 EST
http://bugzilla.gnome.org/show_bug.cgi?id=136612
Upstream
Comment 8 Warren Togami 2004-03-17 06:08:51 EST
Alex just pointed out that gnome-vfs2 uses needs_terminal rather than
need-terminal.  So this actually has been a typo in our default gconf
schema all this time rather than control-center.  I will redo this
patch when I wake up in a few hours.
Comment 9 Warren Togami 2004-03-17 22:13:42 EST
Downloaded all latest GNOME sources from CVS.  "needs_terminal" is
only used in control-center and once in gnome-vfs.

find -type f -name '*.c' -exec grep -H needs_terminal {} \;
./gnome-vfs/libgnomevfs/gnome-vfs-private-utils.c:      path =
g_strconcat (GCONF_URL_HANDLER_PATH, scheme, "/needs_terminal", NULL);
./gnome-control-center/capplets/default-applications/gnome-default-applications-properties.c:#define
DEFAULT_APPS_KEY_BROWSER_NEEDS_TERM
DEFAULT_APPS_KEY_BROWSER_PATH"/needs_terminal"
./gnome-control-center/capplets/default-applications/gnome-default-applications-properties.c:#define
DEFAULT_APPS_KEY_MAILER_NEEDS_TERM
DEFAULT_APPS_KEY_MAILER_PATH"/needs_terminal"
./gnome-control-center/capplets/file-types/service-edit-dialog.c:    
                  = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON
(WID ("needs_terminal_toggle")));
./gnome-control-center/capplets/file-types/service-edit-dialog.c:    
          gtk_widget_set_sensitive (WID ("needs_terminal_toggle"), TRUE);
./gnome-control-center/capplets/file-types/service-edit-dialog.c:    
          gtk_widget_set_sensitive (WID ("needs_terminal_toggle"), FALSE);
./gnome-control-center/capplets/file-types/service-edit-dialog.c:    
  gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (WID
("needs_terminal_toggle")),
./gnome-control-center/capplets/file-types/mime-edit-dialog.c:       
  gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (WID
("needs_terminal_toggle")),
./gnome-control-center/capplets/file-types/mime-edit-dialog.c:       
          GTK_TOGGLE_BUTTON (glade_xml_get_widget (glade,
"needs_terminal_toggle")));
./gnome-control-center/capplets/file-types/mime-edit-dialog.c: 
gtk_widget_set_sensitive (WID ("needs_terminal_toggle"),
dialog->p->custom_action);
./gnome-control-center/capplets/file-types/mime-category-edit-dialog.c:
        gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (WID
("needs_terminal_toggle")),
./gnome-control-center/capplets/file-types/mime-category-edit-dialog.c:
gtk_widget_set_sensitive (WID ("needs_terminal_toggle"),
dialog->p->custom_action && !dialog->p->use_cat_dfl);



find -type f -name '*.c' -exec grep -H need-terminal {} \;
./gnome-control-center/capplets/file-types/service-info.c:      tmp =
get_key_name (info, "need-terminal");


grep -r "need-terminal"
/etc/gconf/schemas/desktop_gnome_url_handlers.schemas | wc -l
18
rpm -qf desktop_gnome_url_handlers.schemas
gnome-vfs2-2.5.91-1

Given that all of our default gconf schemas from GNOME 2.0 until today
have had "need-terminal", I believe it would be best to change the one
reference in gnome-vfs2 and control-center to match that schema rather
than change the default schema.  If the schema is changed, then
millions of existing users would confusingly have both keys.  I am
rewriting the patches now.
Comment 10 Warren Togami 2004-03-18 00:29:43 EST
Created attachment 98639 [details]
control-center-2.5.4-http-https-unknown-for-upstream.patch

This patch is targeted for eventual upstream inclusion.
* Changes needs_terminal to match need-terminal of the default gconf schema
* set http, https, and unknown keys when you choose a browser.
Comment 11 Warren Togami 2004-03-18 00:31:42 EST
Created attachment 98640 [details]
control-center-2.5.4-fedora-apps.patch

Fedora specific patch not suitable for upstream.
Comment 12 Warren Togami 2004-03-18 04:54:20 EST
Created attachment 98645 [details]
control-center-2.5.4-fedora-apps.patch

* Cleaned up Fedora specific applications for the choosers.
Comment 13 Warren Togami 2004-03-18 04:56:54 EST
Created attachment 98646 [details]
control-center-2.5.4-setbrowsers-for-upstream.patch

After further discussion with Alex, we have decided it would be best to instead
change the default schema and use needs_terminal everywhere.

* Fixes two other typos to needs-terminal
* Sets http, https, about, and unknown to the preferred browser.
Comment 14 Warren Togami 2004-03-18 05:55:28 EST
alexl reviewed and now checked in.  Bug #118614 gnome-vfs2 schema
should be published simultaneously in order for this to work 100%.
Comment 15 Jonathan Blandford 2004-09-03 17:40:02 EDT
Need to get this in by FC3
Comment 16 Dams 2004-09-18 09:12:35 EDT
The default keys in fedora core test2 seems to be "epiphany %s" for
both http and https. Which just doesnt work when epiphany isnt
installed (and actually, i've upgraded the system and it wasnt
installed). When you use gnome-default-applications-properties to
modify your setting, it only modifies the http gconf key, so that
https links are opened(?!) with epiphany..

If it can help, we already had this problem in fc2 test2 release:
http://bugzilla.gnome.org/show_bug.cgi?id=123487
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=105740

By the way, the default key for MUA with g-d-a-p is "evolution-1.6 %s"
which just doesnt exists. Should I fill a separated bug report for
this one or can this be done with a new version of the same patches ?
Comment 17 Warren Togami 2004-09-18 15:53:44 EDT
The default keys IIRC are not a problem of control-center, which only
EDITS those keys.  You need to submit a patch for the default schema,
I believe it is in gnome-vfs2 but I could be mistaken.
Comment 18 Zack Cerza 2004-09-24 12:47:39 EDT
*** Bug 131670 has been marked as a duplicate of this bug. ***
Comment 19 Bill Nottingham 2004-09-29 17:17:20 EDT
*** Bug 134087 has been marked as a duplicate of this bug. ***
Comment 20 Bill Nottingham 2004-09-29 17:17:26 EDT
*** Bug 117286 has been marked as a duplicate of this bug. ***
Comment 21 Warren Togami 2004-10-02 02:57:37 EDT
Comment on attachment 98645 [details]
control-center-2.5.4-fedora-apps.patch

This patch has been updated and exists in our existing control-center package.
Comment 22 Warren Togami 2004-10-02 02:59:12 EDT
Comment on attachment 98646 [details]
control-center-2.5.4-setbrowsers-for-upstream.patch

Why was this patch removed from control-center?  Strangely I'm unable to find
the cvs checkin that backed it out.
Comment 23 Warren Togami 2004-10-02 03:00:46 EDT
I didn't realize this was backed out.  Easy enough to fix again.  Want
me to do it?
Comment 24 Alexander Larsson 2004-10-08 09:44:36 EDT
warren fixed this in rawhide.

Note You need to log in before you can comment on or make changes to this bug.