Commit Graph
140 Commits
Author SHA1 Message Date
Georges Basile Stavracas Neto 1aecd1043d application: Add 'open-event' action
This will be used by the search engine to open
events.
2019-04-29 17:08:53 -03:00
Georges Basile Stavracas Neto 3baa71f07d application: Reorganize file a bit 2019-04-29 17:08:53 -03:00
Georges Basile Stavracas Neto 0c3a16b688 application: Turn it into a DzlApplication
This is required for Dazzle resources to be registered
correctly.
2019-04-29 17:08:52 -03:00
Georges Basile Stavracas Neto 08eed8338e application: Trivial style cleanup 2019-04-29 17:08:40 -03:00
Georges Basile Stavracas Neto ab1c0b6ca4 utils: Rename gcal_clear_datetime to gcal_clear_date_time
To keep it consistent with the rest of the API.
2019-04-26 13:27:37 -03:00
Georges Basile Stavracas Neto b280001487 shell-search-provider: Receive a GcalContext
And use the system timezone from the context, instead
of the manager.
2019-04-26 13:19:29 -03:00
Georges Basile Stavracas Neto 073fc961c1 view: Turn 'active-date' into a GDateTime property
Drop the bomb!
2019-04-26 13:04:37 -03:00
Georges Basile Stavracas Neto da3a903d1e application: Delay context initialization 2019-04-25 16:30:58 -03:00
Georges Basile Stavracas Neto 09cb142a5b application: Remove unused variable 2019-04-25 16:30:58 -03:00
Georges Basile Stavracas Neto aa82567f98 application: Use GDateTime instead of icaltime 2019-04-25 16:30:57 -03:00
Georges Basile Stavracas Neto c5b5023508 application: Move time format to GcalContext
It finally found its place under the sun.
2019-04-25 16:30:57 -03:00
Georges Basile Stavracas Neto 0f1de0c2ca application: Remove gcal_application_get_manager()
GcalManager is handled by GcalContext now, and as such, there's
no need to expose this wrapper around it anymore.
2019-04-25 16:30:56 -03:00
Georges Basile Stavracas Neto 01fdf79e6a Use weather service from GcalContext
All those properties were a waste compared to storing it
into the context.
2019-04-25 16:30:56 -03:00
Georges Basile Stavracas Neto 1297ad695b application: Remove gcal_application_get_clock()
That moved to GcalContext, and now that all pieces who
used it have access to the context, we can just use it.
2019-04-25 16:30:55 -03:00
Georges Basile Stavracas Neto 8366d22cf0 application: Move night light monitor to GcalContext 2019-04-25 16:30:55 -03:00
Georges Basile Stavracas Neto 14c6544b95 night-light-monitor: Receive a context 2019-04-25 16:30:53 -03:00
Georges Basile Stavracas Neto b98801a621 window: Receive the context
Instead of the manager. This adds multiple lines retrieving
the manager from the context, but throughout the course of
this rework, they will probably be simplified.
2019-04-25 16:30:53 -03:00
Georges Basile Stavracas Neto beeecdf6b3 application: Use the GcalContext internally
Most was left as it is, such as the "manager" property.
2019-04-24 12:55:20 -03:00
Ralph Plawetzki 3f42719ebe Repair application icon
Fixes #306
2018-11-05 23:46:16 +00:00
Georges Basile Stavracas Neto af095fce48 application: Free icaltimetype with g_free
g_date_time_unref is reserved to GDateTime pointers.
2018-07-31 12:35:56 -03:00
Georges Basile Stavracas Neto 474ce8b9da application: Integrate with Night Light
This is mostly a nice touch of integration for when
using the Night Light feature. It can be disabled by
switching the 'follow-night-light' dconf key to false,
but no user interface widgetry was added.
2018-07-29 00:54:02 -03:00
Georges Basile Stavracas Neto 89e80e688b appmenu: Remove "New Event" entry
The "New Event" menu item is confusing and misleading, since
it is contextless item that has a context-aware action. The
result varies depending on which view you are, but this is in
no way communicated.

So just remove that, and all the GcalWindow API that is not
used anymore altogether.
2018-07-29 00:54:02 -03:00
Georges Basile Stavracas Neto cfa8794313 manager: Move GcalClock to GcalApplication
GcalManager is basically an object that is shared
among classes that need to modify calendars, while
GcalClock is just a wall clock implementation.

Move it to GcalApplication, so that objects without
access to GcalManager can still access the clock.
2018-05-04 21:37:53 -03:00
Georges Basile Stavracas Neto 503191377f application: More code style cleanup and reorganization 2018-01-30 01:30:59 -02:00
Georges Basile Stavracas Neto f698981aa8 application: Improve order of statup
This commit makes sure that logging is set before
actually logging anything. It also sychronizes the
application startup with the manager startup.
2018-01-28 12:39:13 -02:00
Georges Basile Stavracas Neto b936759e5c project: Make time format a first-class citizen
The current code deals with 12/24h clock formats almost like
a workaround of the issue. This commit adds proper support to
different clock formats.
2018-01-28 02:30:55 -02:00
Georges Basile Stavracas Neto 0bfc6fe291 shell-search-provider: Rework property initialization 2018-01-28 00:13:15 -02:00
Georges Basile Stavracas Neto 5a651b01f8 window: Rework property initialization
There is a clear chain of properties that must be respected
in order to make Calendar initialize properly:

 1. GcalManager, since it provider access to the settings
 2. The initial date
 3. GcalWeatherService, that depends on settings and the initial date
2018-01-27 21:46:15 -02:00
Georges Basile Stavracas Neto 5a0844c127 application: Remove conditional include
We always generate the config file nowadays.
2018-01-27 21:26:33 -02:00
Georges Basile Stavracas Neto 737181c655 application: Use g_auto* to simplify code 2018-01-27 21:11:08 -02:00
Georges Basile Stavracas Neto 499db7bfd4 weather: Rework weather management
This commit brings a few changes that I was too lazy to
split in different commits:

 * Remove a few useless arguments in the GcalWeatherService API
 * Move the weather management code from GcalWindow to GcalWeatherSettings
 * A few style changes
2018-01-27 20:36:29 -02:00
Akbar Hashmi 4048296314 application: Add --quit commandline argument
Overview: Clicking the close button in gnome-calendar doesn't always close all the instances of the application. The window is closed, but an instance of gnome-calendar is still running as a gapplication-service, which was probably run by gnome-shell search provider.

The two changes made were as follows:

1) added the argument quit to GOptionEntry
2) added the definition of quit to gcal_application_command_line
2017-12-19 07:41:40 +05:30
Florian Brosch 91ec4990ab weather: Use shorter timeouts if local weather info is invalid 2017-12-11 21:38:06 -02:00
Florian Brosch 5475df20c6 weather: Set check-interval-renew to 3h. 2017-12-11 21:34:22 -02:00
Florian Brosch 2a0a6064aa weather: Rename check-interval to check-interval-renew.
In preparation for check-interval-new.
2017-12-11 21:33:47 -02:00
Florian Brosch d1ee082142 weather: Re-use old weather predictions on errors 2017-12-11 21:32:00 -02:00
Florian Brosch eb3e4a4078 Synchronise weather on application.sync. 2017-12-11 21:29:33 -02:00
Florian Brosch 2cbdba9a95 weather: Display service attributions in AboutDialog.
Note that this injects strings we can't translate.
2017-12-11 21:29:33 -02:00
Florian Brosch 950a2cda8f weather: Pin weather services to applications. 2017-12-11 21:25:16 -02:00
Georges Basile Stavracas Neto a3d1bfcfc5 application: load custom css files
So that theme maintainers can drop their CSS here,
and make Calendar look beautiful everywhere.
2017-11-19 13:42:11 -02:00
Georges Basile Stavracas Neto 36a39e6c5c window: simplify constructor
We don't need to pass information that can easily be
retrieved by the GSettings instance from GcalManager.
2017-09-07 13:21:09 -03:00
Georges Basile Stavracas Neto a0b6bdb04a application: move GSettings object to GcalManager
The first outcome of the test suite. This separation does
not make much sense now, and GcalManager is basically a
holder for all data types.

This commit moves the GSettings to the GcalManager instance
of the application. Of course, in the future, the plan is to
split GcalManager nicely.
2017-09-07 12:52:49 -03:00
Georges Basile Stavracas Neto 110c6be7c8 application: style fixes 2017-09-07 12:08:11 -03:00
Mohammed Sadiq 24a2e97df2 application: handle command line options right
Commandline arguments are now handled by the primary instance of the
application. And so outputs for --help, and --version are shown there.
Not where the application is invoked.

So hook to handle-local-options so that the arguments are parsed locally,
and sent unparsed ones to primary instance in case it is required.

As a side effect, the arguments passed to --date and --uuid are not updated
in the primary instance on subsequent runs (ie, when the primary instance
is already up and running). So check the commandline arguments as they
arrives rather than saving them to a variable, which won't then be updated.

https://bugzilla.gnome.org/show_bug.cgi?id=773152
2017-09-07 11:45:12 -03:00
Georges Basile Stavracas Neto f25a7b0dd8 application: only override log handler with --debug 2017-05-16 15:01:11 -03:00
Mohammed Sadiq 9ed375cd99 application: fix setting active-date logic
https://bugzilla.gnome.org/show_bug.cgi?id=782192
2017-05-06 12:25:16 -03:00
Georges Basile Stavracas Neto d1a24d8adb application: cleanup code 2017-03-17 10:35:56 -03:00
Georges Basile Stavracas Neto 478db350e3 project: intrument functions
Add the newly added macros to provide useful tracing
information.
2017-03-17 10:14:25 -03:00
Georges Basile Stavracas Neto d5825bbd35 project: override log domains
This way, we can have more useful debug spils.
2017-03-17 10:14:25 -03:00
Mohammed Sadiq 1449233382 application: cleanup finalize method
Calendar now segfaults due to faling function
gtk_style_context_remove_provider_for_screen in application finalize method.

As application finalize method is called only when the application closes,
there isn't any hard requirement to cleanup every trailings. Operating
System shall take care of that.

So removing the failing functions so as to not segfault on exit anymore.

https://bugzilla.gnome.org/show_bug.cgi?id=773871
2017-02-09 11:20:49 -02:00