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 725765 - Install .desktop file and basic desktop integration
Install .desktop file and basic desktop integration
Status: RESOLVED FIXED
Product: california
Classification: Other
Component: build
master
Other Linux
: High normal
: 0.2.0
Assigned To: California Maintainers
California Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-03-06 01:11 UTC by Jim Nelson
Modified: 2014-04-16 15:16 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Jim Nelson 2014-03-06 01:11:27 UTC
Create a california.desktop file and install it in the proper place.  Bonus points if it's marked for translation.

In addition to the usual benefits of registering a .desktop file, this should also allow the user to choose California as their default calendar application in System Settings -> Default Applications -> Details.
Comment 1 Federico Bruni 2014-03-23 10:15:07 UTC
I've created it manually as ~/.local/share/applications/california.desktop and set it as default with:

$ xdg-mime default california.desktop text/calendar
$ update-desktop-database

Then I wanted to set it as default for gnome-shell calendar:
$ gsettings set org.gnome.desktop.default-applications.office.calendar exec california

However, the button "Open calendar" doesn't show up. It used to some time ago when I tested gnome-calendar.. Don't know what's wrong.
Comment 2 Federico Bruni 2014-03-25 09:50:01 UTC
Today I've checked on my computer at work, where I had installed gnome-calendar.
The Open calendar link was present on my gnome-shell calendar, but it didn't work when I clicked on it *after I've set the exec value to 'california'* (it used to work when it was set to 'gnome-calendar').

I think that it tried to open gnome-calendar, despite the setting, and it failed.
So I disinstalled gnome-calendar (I compiled it some months ago) and the Open calendar link disappeared from the gnome-shell calendar. Interesting.

So maybe org.gnome.desktop.default-applications.office.calendar is not the right schema?
Oh, just found on dconf-editor:

Schema: org.gnome.desktop.default-applications.office.calendar
"Default calendar application DEPRECATED: This key is deprecated and ignored. The preferred calendar application is the application handling the text/calendar mime type."

So it should be ok. Why the Open calendar link disappeared?
Comment 3 Federico Bruni 2014-03-25 10:33:16 UTC
As soon as I recompile gnome-calendar, the Open calendar link shows up again.
And it opens correctly if I set the schema above to 'gnome-calendar'.

Well, now the note about the deprecation of the schema above is puzzling me..
Comment 4 Jim Nelson 2014-03-27 19:07:58 UTC
I haven't had a chance to look into these issues so I can't comment on them in relation to California.  I know that with Geary and Shotwell, we simply install a .desktop file with the right MIME associations and all kinds of desktop integration begins to work.

My suggestion to you (if you want to continue looking into this) is to use gnome-calendar's .desktop file, altering it to fit California, and install that.  Also go to System Settings -> Details -> Default Applications and ensure California is available there.

Finally, know that California does no command-line processing and so it can't accept associated files (i.e. .ics files or URLs for online calendars).  This will also be required to integrate California with the desktop.
Comment 5 Federico Bruni 2014-03-27 19:19:15 UTC
I had already adapted gnome-calendar's desktop file, this way:

[Desktop Entry]
Name=California
Comment=Access and manage calendar
Comment[it]=Accedi e gestisci il calendario
Exec=california
Icon=x-office-calendar
Terminal=false
Type=Application
StartupNotify=true
OnlyShowIn=GNOME;
Categories=GNOME;GTK;Utility;Core;
MimeType=text/calendar;

California is listed in System Settings>Details>Default Applications.
But the Open calendar link in gnome-shell calendar is not available when California is set as default.
Comment 6 Federico Bruni 2014-04-08 11:39:57 UTC
I had the chance to test this on a new system installation.
In this case California is set as calendar application in Gnome preferences, the Open calendar _is_ still present but it launches Evolution.

IIRC Evolution was not installed on my old PC. Which could explain the problem described before.

How can I set California in gnome-shell? (I've tried also the deprecated setting in dconf, but it didn't work)
Comment 7 Jim Nelson 2014-04-09 22:28:17 UTC
I haven't had a chance to investigate this, but definitely getting this solved should be considered part of this ticket.  I've changed the title to reflect this.
Comment 8 Jim Nelson 2014-04-16 01:25:55 UTC
Pushed to master, commit 51c951

A couple of notes:

* Federico, I got this to work with GNOME Shell's calendar by restarting the shell after selecting California as the default calendar.  If that doesn't work, you might try logging out and logging back in.  If the problem persists, please file a ticket.

* I investigated having California integrate with Unity's calendar indicator (in the top-right corner) but it appears that indicator is hardwired to use Evolution.  I've requested this be changed: https://bugs.launchpad.net/ubuntu/+source/unity/+bug/1308296
Comment 9 Federico Bruni 2014-04-16 06:48:04 UTC
I've compiled the latest version from git, but it doesn't work here (debian unstable, gnome 3.8.4).

I believe that also in GNOME shell the calendar is hardwired to use Evolution.
Here's what I've found:

- if Evolution is not installed, the Open calendar button in gnome-shell doesn't appear.
- if Evolution is installed, the Open calendar button appears but it launches Evolution, even if California is set as default application for calendar in the Gnome preferences.
Comment 10 Federico Bruni 2014-04-16 15:16:14 UTC
entered a new issue:
https://bugzilla.gnome.org/show_bug.cgi?id=728349