[GSoC 2017] Calendar Application: Weekly Report 7

Blog post by AkshayAgarwal007 on Sun, 2017-08-27 03:45

Hello Everyone!

In this post I would be focusing on the work done in the past two weeks.

I worked on Google Calendar integration and general improvements and bug fixes in the Calendar App. I also worked on implementing a relative datetime formatter and general enhancements/bug fixes involving the Haiku locale kit.

Calendar App

Fetching events using Google Calendar API and syncing with the database works now. There are issues with sending JSON data in an http post request, which always results in a parse error in the API response, as a result of which adding/updating events to Google Calendar doesn't work currently. I would be working to fix the same over the next few days. Deleting events from Google Calendar works fine.

Currently there is no DateTimeEdit widget. Time preferences has separate DateEdit and TimeEdit widgets implemented. I would look into incorporating the same or work on a DateTimeEdit widget having a calendar pop-up. Currently I have implemented a temporary solution which provides a Calendar pop-up to select dates and a simple text control where the time can be entered in 24-hour(HH:mm) format. Parsing of the entered text is done using time parser implemented in BTimeFormat, and results into 00:00 in case of error.

I also did some initial work on an Agenda view and improving event notifications, but both of them required a Relative DateTime formatter, so implemented one for Haiku as a part of locale kit.


Calendar Preview:

Calendar-Preview

The toolbar icons are just placeholder icons. Icons for the same are welcome. (Something on this line Day View Mockup ) Also improved icon for the main application icon are welcome.

Event Manager:

Event-Manager


These are two videos I recorded while testing the Google Calendar integration in the app. It shows the entire flow from authorizing the app to access data from Google Calendar to the events being synced and displayed in the app.
https://www.youtube.com/watch?v=UYJ18rEFAMI
https://www.youtube.com/watch?v=qWKNSXoRG8I

Github Repo: AkshayAgarwal007/Calendar

Locale Kit

  • Implemented a Relative DateTime formatter. This takes in a time_t value and gives a formatted string such as '2 hours ago', 'in 2 hours', relative to the current time.
    https://dev.haiku-os.org/ticket/13679
  • <li> Wrote tests for BRelativeDateTimeFormat, fixed bugs in tests for
    BDateFormat/BDateTimeFormat, and added test cases for changes I made in
    BDurationFormat earlier this summer. In the process I got familiar with how
    unit testing is done in Haiku.<br>
    <a href="https://dev.haiku-os.org/ticket/13682">
    https://dev.haiku-os.org/ticket/13682</a><br>
    <a href="https://dev.haiku-os.org/ticket/13684">
    https://dev.haiku-os.org/ticket/13684</a><br>
    <a href="https://dev.haiku-os.org/ticket/13685">
    https://dev.haiku-os.org/ticket/13685</a></li>
        
    <li> I worked on parts of the existing codebase to make use of locale kit
    for doing relative datetime formatting. For e.g the Web+ downloads Window
    doesn't make use of it completely. This is still under progress.<br>
    <a href="https://dev.haiku-os.org/ticket/13686">
    https://dev.haiku-os.org/ticket/13686</a></li>
    

Thanks to PulkoMandy for his help in all the patches I submitted.

Thanks for reading.