aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/calendar-model.c
Commit message (Collapse)AuthorAgeFilesLines
* *gui/calendar-model.c: added a preliminary change to have AssignedJesse Pavel2000-11-281-3/+13
| | | | | | To-Do items have a corresponding icon. svn path=/trunk/; revision=6686
* The icon column is not editable!Federico Mena Quintero2000-11-221-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-21 Federico Mena Quintero <federico@helixcode.com> * gui/calendar-model.c (calendar_model_is_cell_editable): The icon column is not editable! * gui/calendar-commands.c (todo_properties_changed): Removed. (time_format_changed): Removed. (colors_changed): Removed. * gui/calendar-commands.h: * gui/prop.c (prop_apply): * gui/calendar-commands.c (init_calendar): Removed the old to-do list crap. * gui/gncal-todo.[ch]: Removed obsolete files. * gui/Makefile.am (evolution_calendar_SOURCES): Removed gncal-todo.[ch]. * gui/gnome-cal.c (gnome_calendar_todo_properties_changed): Removed. (gnome_calendar_time_format_changed): Removed. (gnome_calendar_colors_changed): Removed. svn path=/trunk/; revision=6635
* Clear the rdate and exrule lists from the component if we are setting aFederico Mena Quintero2000-11-131-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-11-12 Federico Mena Quintero <federico@helixcode.com> * gui/event-editor.c (recur_to_comp_object): Clear the rdate and exrule lists from the component if we are setting a simple recurrence. (recur_to_comp_object): Set the exdate list here instead of in dialog_to_comp_object(). (preview_recur): New function to tag the recurrence preview calendar based on the information from the dialog box. (fill_exception_widgets): Fill the exception widgets here; moved over from fill_widgets(). (fill_recurrence_widgets): Call preview_recur(). Also, call fill_exception_widgets() first of all. (recurrence_type_toggled_cb): Call preview_recur(). (recur_interval_selection_done_cb): Likewise. (recur_ending_selection_done_cb): Likewise. (recurrence_exception_add_cb): Likewise. (recurrence_exception_modify_cb): Likewise. (recurrence_exception_delete_cb): Likewise. (date_changed_cb): Likewise. (recur_interval_value_changed_cb): Likewise, new function. * gui/tag-calendar.[ch]: New files with utilities for tagging calendars. mark.[ch] should go away some day. * gui/tag-calendar.c (tag_calendar): Moved over from gnome_calendar_tag_calendar(). Take in a CalClient instead of a GnomeCalendar. Added API docs. (tag_calendar_by_comp): New function to tag a calendar based on a single calendar component instead of a whole client. * gui/gnome-cal.c (initial_load): Use tag_calendar_by_client(). (obj_updated_cb): Likewise. (obj_removed_cb): Likewise. (gnome_calendar_on_date_navigator_date_range_changed): Likewise. (editor_closed_cb): Free the closure. (destroy_editor_cb): Renamed from free_uid(). Do not free the UID; just unref the event editor. Our destroy handler to it will free things properly. This will also cause the corresponding calendar client to be unrefed. (editor_closed_cb): Use a flag on the GnomeCalendar to decide whether to remove the editor from the hash table. This is sort of icky. * gui/calendar-model.c (obj_updated_cb): If the object is new, we have to use e_table_model_row_inserted(), not row_changed(). Thanks to JP Rosevear for reporting this. * gui/Makefile.am (evolution_calendar_SOURCES): Added tag-calendar.[ch] to the list of sources. svn path=/trunk/; revision=6547
* use cal_component_has_alarms().Damon Chaplin2000-10-201-15/+1
| | | | | | | | | 2000-10-20 Damon Chaplin <damon@helixcode.com> * gui/calendar-model.c (calendar_model_value_at): use cal_component_has_alarms(). svn path=/trunk/; revision=6075
* updated to support RDATE end times or durations. Note that if you have twoDamon Chaplin2000-09-301-65/+184
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-09-29 Damon Chaplin <damon@helixcode.com> * cal-util/cal-recur.c: updated to support RDATE end times or durations. Note that if you have two RDATEs with the same start times, but with different end dates/durations set, the results are unpredictable. So the event editor dialog should check for this. * gui/e-week-view-main-item.c (e_week_view_main_item_draw_day): make strftime() strings translatable, and changed the formats a bit. * NOTE: someone needs to check print.c to make sure strftime strings are OK for i18n. * gui/e-day-view.h: Changed EDayViewDateFormat enum. We now try to include the weekday if possible. Also changed EDayView struct so we store the month & weekdays with the longest names rather than the actual widths. This helps i18n. * gui/e-day-view.c (e_day_view_recalc_cell_sizes): used _() for strftime strings, tried to see if weekday fits, and rearranged a bit to make i18n easier. * gui/e-day-view-top-item.c (e_day_view_top_item_draw): used _() for strftime strings, and updated to use new formats. * gui/calendar-model.c: added use_24_hour_format boolean to CalendarModelPrivate so we can display dates in 12-hour format if requested. This meant adding a CalendarModel argument to a few functions. Also added get/set functions to set use_24_hour_format. I suppose ideally we should have an ECellDate renderer and this option should go there. svn path=/trunk/; revision=5646
* Removed an unused variable.Federico Mena Quintero2000-09-141-3/+0
| | | | | | | | | 2000-09-13 Federico Mena Quintero <federico@helixcode.com> * gui/calendar-model.c (obj_updated_cb): Removed an unused variable. svn path=/trunk/; revision=5411
* See if the new object matches the type of objects we were told to dealFederico Mena Quintero2000-09-141-0/+31
| | | | | | | | | | 2000-09-13 Federico Mena Quintero <federico@helixcode.com> * gui/calendar-model.c (obj_updated_cb): See if the new object matches the type of objects we were told to deal with. (load_objects): Likewise. svn path=/trunk/; revision=5410
* Relying on the status field is somewhat faulty since it is related toJP Rosevear2000-09-111-8/+1
| | | | | | | | | 2000-09-10 JP Rosevear <jpr@helixcode.com> * gui/calendar-model.c (get_is_complete): Relying on the status field is somewhat faulty since it is related to group scheduling svn path=/trunk/; revision=5308
* changed to use EDateEdit.Damon Chaplin2000-09-111-32/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-09-11 Damon Chaplin <damon@helixcode.com> * gui/dialogs/task-editor.c: changed to use EDateEdit. * gui/dialogs/task-editor-dialog.glade: added "None" option to Classification option menu, and used custom widgets for the date entries so we can use EDateEdit widgets. * gui/event-editor.c: changed to use EDateEdit. Note that this needs to be fixed at some point to handle invalid dates, i.e. when e_date_edit_get_time returns -1. * gui/calendar-model.c (ensure_task_complete): (ensure_task_not_complete): new functions to set the related properties to make sure a task is marked as complete on not, i.e. "Date Completed" "Status" and "Percent" properties. 2000-09-08 Damon Chaplin <damon@helixcode.com> * gui/calendar-model.c (get_is_complete): use the status field rather than the completed date, as it is more reliable. (get_is_overdue): use get_is_complete(). (calendar_model_mark_task_complete): check if it is already complete, and if so don't update it. * cal-util/cal-component.c (cal_component_get_status): (cal_component_set_status): added functions to support the STATUS property. Also added the property to CalComponentPrivate and set it to NULL in free_icalcomponent(). Someone should check my code as I've mainly done a Cut & Paste job. svn path=/trunk/; revision=5305
* Use new cal_component_has_recurrences convenience functionJP Rosevear2000-09-061-9/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-09-06 JP Rosevear <jpr@helixcode.com> * gui/e-day-view-main-item.c (e_day_view_main_item_draw_day_event): Use new cal_component_has_recurrences convenience function * gui/e-week-view.c (e_week_view_show_popup_menu): ditto * gui/e-week-view-event-item.c (e_week_view_event_item_draw_icons): ditto * gui/calendar-model.c (calendar_model_value_at): ditto (calendar_model_value_at): ditto * gui/e-day-view.c (e_day_view_on_event_click): ditto (e_day_view_on_event_right_click): ditto (e_day_view_on_top_canvas_motion): ditto (e_day_view_on_top_canvas_motion): ditto (e_day_view_on_main_canvas_motion): ditto (e_day_view_on_main_canvas_motion): ditto (e_day_view_reshape_day_event): ditto * gui/e-day-view-top-item.c (e_day_view_top_item_draw_long_event): ditto * gui/e-day-view.c (e_day_view_on_long_event_click): ditto svn path=/trunk/; revision=5220
* No need to spit a warning if removal fails. (event_editor_destroy): FreeFederico Mena Quintero2000-09-011-2/+4
| | | | | | | | | | | | | | | | | | | | | | | 2000-08-31 Federico Mena Quintero <federico@helixcode.com> * gui/event-editor.c (file_delete_cb): No need to spit a warning if removal fails. (event_editor_destroy): Free the exception clist data. Unref the calendar client here. (close_dialog): Just call gtk_object_destroy() on the event editor; the destroy handler will free everything else. * cal-client/cal-client.c (cal_client_object_exists): Removed function; this is not useful because we operate asynchronously. * gui/e-day-view.c (e_day_view_on_delete_appointment): No need to spit a warning if removal fails. * gui/e-week-view.c (e_week_view_on_delete_appointment): Likewise. * gui/calendar-model.c (calendar_model_delete_task): Likewise. svn path=/trunk/; revision=5155
* New function. We need this from code that dynamically updates from aFederico Mena Quintero2000-08-291-3/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-08-28 Federico Mena Quintero <federico@helixcode.com> * cal-client/cal-client.c (cal_client_is_loaded): New function. We need this from code that dynamically updates from a client and could not have connected to the "cal_loaded" signal right after the client was created. * gui/calendar-model.c (load_objects): Do not try to load the objects if the client has not been loaded yet. (cal_loaded_cb): Check the status value. * gui/calendar-model.h (CalendarModel): Declare the private structure here so that gdb will give me love. * pcs/cal-factory.h (CalFactory): Likewise. * pcs/cal.h (Cal): Likewise. * cal-client/cal-listener.h (CalListener): Likewise. * cal-client/cal-client.h (CalClient): Likewise. * pcs/cal-backend.h (CalBackend): This no longer has a private structure, so remove it. * cal-util/Makefile.am (libcal_util_la_SOURCES): Removed the vCalendar and old iCalendar cruft. (libcal_utilinclude_HEADERS): Likewise. Removed the obsolete iCalendar test program. svn path=/trunk/; revision=5091
* We no longer need time_from_icaltimetype as libical has the API for thisJP Rosevear2000-08-291-3/+3
| | | | | | | | | | | | | | | | | | | | 2000-08-28 JP Rosevear <jpr@helixcode.com> * cal-util/timeutil.h: We no longer need time_from_icaltimetype as libical has the API for this * cal-util/timeutil.c: ditto * cal-util/cal-recur.c: Replace time_from_icaltimetype with icaltime_as_timet * gui/calendar-model.c: ditto * gui/event-editor.c: ditto * gui/gnome-cal.c: ditto svn path=/trunk/; revision=5090
* Uncomment debug code.JP Rosevear2000-08-261-0/+22
| | | | | | | | | | | | | 2000-08-25 JP Rosevear <jpr@helixcode.com> * gui/e-calendar-table.c (e_calendar_table_init): Uncomment debug code. * gui/calendar-model.c (set_complete): Set the completed date to the current date (calendar_model_set_value_at): Handle complete field svn path=/trunk/; revision=5044
* Don't attempt to free this if its null (calendar_model_duplicate_value):JP Rosevear2000-08-261-4/+5
| | | | | | | | | | | | | | | | | | | 2000-08-25 JP Rosevear <jpr@helixcode.com> * gui/calendar-model.c (get_is_complete): Don't attempt to free this if its null (calendar_model_duplicate_value): Implement for summary field value (calendar_model_initialize_value): Remove debug code * gui/e-calendar-table.c: Correct etable init xml (create_column): Pass the id to e_table_header_add_column rather than a hard coded one (e_calendar_table_init): Make sure summary column isn't added twice. Add an alarms column, else etable won't work with columns who have an ID higher than that svn path=/trunk/; revision=5040
* Update for libical 0.19JP Rosevear2000-08-251-3/+3
| | | | | | | | 2000-08-24 JP Rosevear <jpr@helixcode.com> * Update for libical 0.19 svn path=/trunk/; revision=5024
* Handle summary field (calendar_model_value_is_empty): dittoJP Rosevear2000-08-241-0/+5
| | | | | | | | | | | 2000-08-24 JP Rosevear <jpr@helixcode.com> * gui/calendar-model.c (calendar_model_initialize_value): Handle summary field (calendar_model_value_is_empty): ditto (calendar_model_free_value): ditto svn path=/trunk/; revision=5001
* Updated function. (calendar_model_free_value): Updated function.Federico Mena Quintero2000-08-221-343/+217
| | | | | | | | | | | | | | | | | | 2000-08-21 Federico Mena Quintero <federico@helixcode.com> * gui/calendar-model.c (calendar_model_duplicate_value): Updated function. (calendar_model_free_value): Updated function. (calendar_model_initialize_value): Updated function. (calendar_model_value_is_empty): Updated function. (remove_object): Updated function. (obj_updated_cb): Updated function. (calendar_model_get_cal_client): Added inline docs. (calendar_model_delete_task): Updated. (calendar_model_mark_task_complete): Updated. (calendar_model_get_cal_object): Updated. svn path=/trunk/; revision=4910
* New function. (parse_time): Moved over from the old set_time_t(). ThisFederico Mena Quintero2000-08-221-196/+284
| | | | | | | | | | | | | | | | | | 2000-08-21 Federico Mena Quintero <federico@helixcode.com> * gui/calendar-model.c (set_categories): New function. (parse_time): Moved over from the old set_time_t(). This just parses the time and leaves the warning dialog for the caller. (set_datetime): New function. (set_geo): Updated old function. (set_percent): Updated old function. (set_priority): Updated old function. (set_summary): New function. (set_url): New function. (calendar_model_set_value_at): Updated function. (calendar_model_is_cell_editable): Updated function. svn path=/trunk/; revision=4907
* Sync - FedericoFederico Mena Quintero2000-08-131-11/+8
| | | | svn path=/trunk/; revision=4789
* Sync - FedericoFederico Mena Quintero2000-08-121-1/+28
| | | | svn path=/trunk/; revision=4769
* Generate a prettier string for the geographical position.Federico Mena Quintero2000-08-121-75/+332
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-08-11 Federico Mena Quintero <federico@helixcode.com> * gui/calendar-model.c (get_geo): Generate a prettier string for the geographical position. (get_classification): New function. (get_categories): New function. (get_completed): New function. (get_dtend): New function. (get_dtstart): New function. (get_due): New function. (get_percent): New function. (get_priority): New function. (get_summary): New function. (get_transparency): New function. (get_url): New function. (get_has_alarms): New function. (get_has_recurrences): New function. (get_is_complete): New function. (get_is_overdue): New function. * cal-util/cal-component.c (scan_property): Handle the GEO property. (free_icalcomponent): Likewise. (cal_component_get_geo): Likewise. (cal_component_set_geo): Likewise. (cal_component_free_geo): Likewise. (cal_component_set_exdate_list): Removed incorrect assertion. (cal_component_set_exrule_list): Removed incorrect assertion. (cal_component_get_next_alarm): Oops, this had not been implemented at all. (cal_component_has_rdates): New function. (cal_component_has_rrules): New function. * cal-util/cal-component.h (CalComponentField): Added the GEO property. svn path=/trunk/; revision=4763
* Handle the PERCENT-COMPLETE property. (free_icalcomponent): Likewise.Federico Mena Quintero2000-08-121-11/+10
| | | | | | | | | | | | | | | | | | | | | 2000-08-11 Federico Mena Quintero <federico@helixcode.com> * cal-util/cal-component.c (scan_property): Handle the PERCENT-COMPLETE property. (free_icalcomponent): Likewise. (cal_component_get_percent): Likewise. (cal_component_set_percent): Likewise. (cal_component_free_percent): Likewise. (scan_property): Handle the PRIORITY property. (free_icalcomponent): Likewise. (cal_component_get_priority): Likewise. (cal_component_set_priority): Likewise. (cal_component_free_priority): Likewise. * cal-util/cal-component.h (CalComponentField): New enumeration with the list of fields we support for ETable. svn path=/trunk/; revision=4745
* updated to match the new ETableModel append_row. This meant we could alsoDamon Chaplin2000-08-031-62/+16
| | | | | | | | | | 2000-08-03 Damon Chaplin <damon@helixcode.com> * gui/calendar-model.c (calendar_model_append_row): updated to match the new ETableModel append_row. This meant we could also get rid of the row_being_added and idle_id hack. svn path=/trunk/; revision=4499
* Emit "model_pre_change" signals as appropriate.Christopher James Lahey2000-08-031-0/+3
| | | | | | | | | 2000-08-02 Christopher James Lahey <clahey@helixcode.com> * gui/calendar-model.c: Emit "model_pre_change" signals as appropriate. svn path=/trunk/; revision=4493
* Solaris compile fix. OK on Linux too.Matthew Loper2000-07-271-0/+3
| | | | svn path=/trunk/; revision=4368
* new ECalendarTable to show an ETable view for Todo/Event items.Damon Chaplin2000-07-261-61/+583
| | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-07-25 Damon Chaplin <damon@helixcode.com> * gui/e-calendar-table.[hc]: new ECalendarTable to show an ETable view for Todo/Event items. * gui/task-assigned-to.xpm: * gui/task-recurring.xpm: * gui/task-assigned.xpm: * gui/task.xpm: new pixmaps (all the same at present) to go in the icon column of the ETable. * gui/event-editor.c: hid the silly 'Calendar' labels on the GnomeDateEdits and hid the times when you select 'All day event'. Also adjusted the time_t's so that when an all day event finishes on say midnight 13th May, we show 12th May in the dialog, since it implicitly includes all of that day up to midnight. * gui/dialogs/task-editor-dialog.glade: * gui/dialogs/task-editor.[hc]: unfinished dialog to edit tasks. * gui/gncal-todo.c: temporary hack so that we can use the simple dialog with our new ETable. svn path=/trunk/; revision=4323
* Calculate height including if clip_height is set to -1.Christopher James Lahey2000-06-271-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * widgets/e-text/e-text.c: Calculate height including if clip_height is set to -1. From addressbook/ChangeLog: 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * contact-editor/e-contact-editor-categories.c, addressbook/gui/component/e-cardlist-model.c: Added value_to_string handlers. * demo/addressbook-widget.c, demo/demo.c: Removed usage of "x" and "y" arguments. * addressbook/gui/component/addressbook.c: Activated Click To Add and set the click to add message. * addressbook/gui/component/e-addressbook-model.c: Added value_to_string and append_row handlers. * addressbook/gui/component/e-select-names.c: Added a column. From calendar/ChangeLog: 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * gui/calendar-model.c: Added an #ifdefed value_to_string handler assignment. From camel/ChangeLog: 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * providers/mbox/camel-mbox-summary.c: Added debugging information. From composer/ChangeLog: 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added e-msg-composer-select-file.h for make distcheck. From e-util/ChangeLog: 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added e-canvas-vbox.c and e-canvas-vbox.h. * e-canvas-vbox.c, e-canvas-vbox.h: New canvas object to act like a vbox using the reflow system. From mail/ChangeLog: 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * message-list.c: Added a value_to_string handler. From shell/ChangeLog: 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * glade/Makefile.am: Added EXTRA_DIST for make distcheck. From widgets/e-table/ChangeLog: 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added e-table-click-to-add.c, e-table-click-to-add.h, e-table-one.c, and e-table-one.h. * e-table-click-to-add.c, e-table-click-to-add.h: A new canvas item that represents a single row that sometimes exists. It's for adding new rows to your table. * e-table-example-1.c, e-table-example-2.c, e-table-size-test.c, test-check.c, test-cols.c, test-table.c: Added value_to_string handlers. * e-table-group-container.c: Use value_to_string to make grouping not crash for non string columns. Made some changes to work properly in an ECanvasVbox. * e-table-group-leaf.c, e-table-item.c: Made some changes to work properly in an ECanvasVbox. * e-table-model.c, e-table-model.h: Added append_row and value_to_string methods. * e-table-one.c, e-table-one.h: Given a source ETableModel, this provides a single row model that uses the initialize_value, duplicate_value, free_value, and value_is_empty methods of the original source to implement set_value and value_at (and proxies most of the other methods.) This is used for ETableClickToAdd. * e-table-simple.c, e-table-simple.h: Added append_row and value_to_string handlers. append_row uses a GtkArg instead of a parameter to e_table_simple_new. * e-table-subset.c: Added append_row and value_to_string handlers. * e-table.c, e-table.h: Use a vbox containing an ETableClickToAdd and an ETableItem instead of an ETableItem directly. Only show the ETableClickToAdd if the top level of the xml SPEC has the attribute click-to-add set to some non-zero integer. (click-to-add="1"). Add a "click_to_add_message" argument. * e-tree-model.c: Add a commented out value_to_string handler. From widgets/meeting-time-sel/ChangeLog: 2000-06-26 Christopher James Lahey <clahey@helixcode.com> * Makefile.am: Added the include path to top_srcdir. svn path=/trunk/; revision=3744
* Sync again - FedericoFederico Mena Quintero2000-06-271-24/+298
| | | | svn path=/trunk/; revision=3742
* Sync - FedericoFederico Mena Quintero2000-06-231-5/+206
| | | | svn path=/trunk/; revision=3693
* #ifdef'ed out references to functions which don't exist yet, so evolutionDamon Chaplin2000-06-161-0/+2
| | | | | | | | | | 2000-06-16 Damon Chaplin <damon@helixcode.com> * gui/calendar-model.c (calendar_model_class_init): #ifdef'ed out references to functions which don't exist yet, so evolution still compiles. svn path=/trunk/; revision=3594
* Doh, sync - FedericoFederico Mena Quintero2000-06-161-25/+120
| | | | svn path=/trunk/; revision=3593
* Added the array of objects and the hash table of UID->array index.Federico Mena Quintero2000-06-131-0/+482
2000-06-13 Federico Mena Quintero <federico@helixcode.com> * gui/calendar-model.c (CalendarModelPrivate): Added the array of objects and the hash table of UID->array index. (calendar_model_row_count): Return the length directly from the array instead of asking the Wombat. (calendar_model_value_at): Implemented. (calendar_model_new): Create an empty model. We provide a new setter function now. (calendar_model_construct): Removed function. (calendar_model_set_cal_client): New function to set the calendar client and object type at any time. This lets us reuse a calendar model object. * cal-util/calobj.h (iCalObjectField): Just report whether the object has alarms; not every single alarm. svn path=/trunk/; revision=3547