aboutsummaryrefslogtreecommitdiffstats
path: root/internal/debug
ModeNameSize
-rw-r--r--api.go5556logstatsplainblame
-rw-r--r--flags.go3582logstatsplainblame
-rw-r--r--trace.go1762logstatsplainblame
-rw-r--r--trace_fallback.go1104logstatsplainblame
8bb9e5167b0219b48ab3e8062080d3740b0a'>a11y/calendar/ea-day-view-cell.c8
-rw-r--r--a11y/calendar/ea-day-view-main-item.c62
-rw-r--r--a11y/calendar/ea-day-view.c14
-rw-r--r--a11y/calendar/ea-gnome-calendar.c2
-rw-r--r--a11y/calendar/ea-jump-button.c6
-rw-r--r--a11y/calendar/ea-week-view-cell.c16
-rw-r--r--a11y/calendar/ea-week-view-main-item.c72
-rw-r--r--a11y/calendar/ea-week-view.c4
-rw-r--r--a11y/e-table/gal-a11y-e-cell-popup.c14
-rw-r--r--a11y/e-table/gal-a11y-e-cell-registry.c8
-rw-r--r--a11y/e-table/gal-a11y-e-cell-text.c28
-rw-r--r--a11y/e-table/gal-a11y-e-cell-toggle.c10
-rw-r--r--a11y/e-table/gal-a11y-e-cell-tree.c8
-rw-r--r--a11y/e-table/gal-a11y-e-cell-vbox.c12
-rw-r--r--a11y/e-table/gal-a11y-e-cell-vbox.h6
-rw-r--r--a11y/e-table/gal-a11y-e-cell.c46
-rw-r--r--a11y/e-table/gal-a11y-e-cell.h6
-rw-r--r--a11y/e-table/gal-a11y-e-table-click-to-add-factory.c6
-rw-r--r--a11y/e-table/gal-a11y-e-table-click-to-add.c18
-rw-r--r--a11y/e-table/gal-a11y-e-table-column-header.c6
-rw-r--r--a11y/e-table/gal-a11y-e-table-factory.c8
-rw-r--r--a11y/e-table/gal-a11y-e-table-item-factory.c8
-rw-r--r--a11y/e-table/gal-a11y-e-table-item.c62
-rw-r--r--a11y/e-table/gal-a11y-e-table.c14
-rw-r--r--a11y/e-table/gal-a11y-e-tree-factory.c6
-rw-r--r--a11y/e-table/gal-a11y-e-tree.c6
-rw-r--r--a11y/e-text/gal-a11y-e-text-factory.c8
-rw-r--r--a11y/e-text/gal-a11y-e-text.c20
-rw-r--r--a11y/ea-factory.h2
-rw-r--r--a11y/gal-a11y-factory.h2
-rw-r--r--a11y/gal-a11y-util.c2
-rw-r--r--a11y/widgets/ea-calendar-cell.c12
-rw-r--r--a11y/widgets/ea-calendar-item.c62
-rw-r--r--a11y/widgets/ea-combo-button.c4
-rw-r--r--a11y/widgets/ea-expander.c2
-rw-r--r--addressbook/conduit/address-conduit.c300
-rw-r--r--addressbook/gui/component/addressbook-component.c26
-rw-r--r--addressbook/gui/component/addressbook-config.c34
-rw-r--r--addressbook/gui/component/addressbook-migrate.c70
-rw-r--r--addressbook/gui/component/addressbook-migrate.h2
-rw-r--r--addressbook/gui/component/addressbook-view.c122
-rw-r--r--addressbook/gui/component/addressbook-view.h4
-rw-r--r--addressbook/gui/component/addressbook.c14
-rw-r--r--addressbook/gui/component/autocompletion-config.c4
-rw-r--r--addressbook/gui/component/openldap-extract.h12
-rw-r--r--addressbook/gui/contact-editor/e-contact-editor-address.c8
-rw-r--r--addressbook/gui/contact-editor/e-contact-editor-fullname.c10
-rw-r--r--addressbook/gui/contact-editor/e-contact-editor-fullname.h2
-rw-r--r--addressbook/gui/contact-editor/e-contact-editor-im.c10
-rw-r--r--addressbook/gui/contact-editor/e-contact-editor-im.h2
-rw-r--r--addressbook/gui/contact-editor/e-contact-editor.c120
-rw-r--r--addressbook/gui/contact-editor/e-contact-editor.h6
-rw-r--r--addressbook/gui/contact-editor/e-contact-quick-add.c32
-rw-r--r--addressbook/gui/contact-editor/e-contact-quick-add.h6
-rw-r--r--addressbook/gui/contact-editor/eab-editor.c14
-rw-r--r--addressbook/gui/contact-list-editor/e-contact-list-editor.c48
-rw-r--r--addressbook/gui/contact-list-editor/e-contact-list-model.c4
-rw-r--r--addressbook/gui/merging/eab-contact-compare.c32
-rw-r--r--addressbook/gui/merging/eab-contact-compare.h4
-rw-r--r--addressbook/gui/merging/eab-contact-merging.c52
-rw-r--r--addressbook/gui/widgets/e-addressbook-model.c8
-rw-r--r--addressbook/gui/widgets/e-addressbook-reflow-adapter.c10
-rw-r--r--addressbook/gui/widgets/e-addressbook-table-adapter.c8
-rw-r--r--addressbook/gui/widgets/e-addressbook-view.c100
-rw-r--r--addressbook/gui/widgets/e-addressbook-view.h2
-rw-r--r--addressbook/gui/widgets/e-minicard-label.c18
-rw-r--r--addressbook/gui/widgets/e-minicard-label.h2
-rw-r--r--addressbook/gui/widgets/e-minicard-view-widget.c14
-rw-r--r--addressbook/gui/widgets/e-minicard-view.c32
-rw-r--r--addressbook/gui/widgets/e-minicard-view.h2
-rw-r--r--addressbook/gui/widgets/e-minicard.c70
-rw-r--r--addressbook/gui/widgets/e-minicard.h6
-rw-r--r--addressbook/gui/widgets/eab-contact-display.c60
-rw-r--r--addressbook/gui/widgets/eab-contact-display.h2
-rw-r--r--addressbook/gui/widgets/eab-gui-util.c76
-rw-r--r--addressbook/gui/widgets/eab-menu.c10
-rw-r--r--addressbook/gui/widgets/eab-menu.h2
-rw-r--r--addressbook/gui/widgets/eab-popup-control.c8
-rw-r--r--addressbook/gui/widgets/eab-popup-control.h6
-rw-r--r--addressbook/gui/widgets/eab-popup.c10
-rw-r--r--addressbook/gui/widgets/eab-popup.h14
-rw-r--r--addressbook/gui/widgets/eab-vcard-control.c12
-rw-r--r--addressbook/gui/widgets/gal-view-minicard.c2
-rw-r--r--addressbook/gui/widgets/test-reflow.c6
-rw-r--r--addressbook/importers/evolution-csv-importer.c86
-rw-r--r--addressbook/importers/evolution-ldif-importer.c18
-rw-r--r--addressbook/importers/evolution-vcard-importer.c22
-rw-r--r--addressbook/printing/e-contact-print-style-editor.c4
-rw-r--r--addressbook/printing/e-contact-print-style-editor.h2
-rw-r--r--addressbook/printing/e-contact-print-types.h2
-rw-r--r--addressbook/printing/e-contact-print.c18
-rw-r--r--addressbook/printing/e-contact-print.h2
-rw-r--r--addressbook/printing/test-contact-print-style-editor.c10
-rw-r--r--addressbook/printing/test-print.c10
-rw-r--r--addressbook/tools/evolution-addressbook-export-list-cards.c2
-rw-r--r--addressbook/util/eab-book-util.c30
-rw-r--r--addressbook/util/eab-book-util.h4
-rw-r--r--calendar/common/authentication.c10
-rw-r--r--calendar/common/authentication.h8
-rw-r--r--calendar/conduits/calendar/calendar-conduit.c390
-rw-r--r--calendar/conduits/common/libecalendar-common-conduit.c32
-rw-r--r--calendar/conduits/memo/memo-conduit.c230
-rw-r--r--calendar/conduits/todo/todo-conduit.c282
-rw-r--r--calendar/gui/alarm-notify/alarm-notify-dialog.c90
-rw-r--r--calendar/gui/alarm-notify/alarm-notify-dialog.h4
-rw-r--r--calendar/gui/alarm-notify/alarm-notify.c76
-rw-r--r--calendar/gui/alarm-notify/alarm-notify.h2
-rw-r--r--calendar/gui/alarm-notify/alarm-queue.c248
-rw-r--r--calendar/gui/alarm-notify/alarm.c10
-rw-r--r--calendar/gui/alarm-notify/config-data.c30
-rw-r--r--calendar/gui/alarm-notify/notify-main.c4
-rw-r--r--calendar/gui/cal-search-bar.c92
-rw-r--r--calendar/gui/calendar-commands.c2
-rw-r--r--calendar/gui/calendar-component.c276
-rw-r--r--calendar/gui/calendar-config.c178
-rw-r--r--calendar/gui/calendar-config.h2
-rw-r--r--calendar/gui/calendar-view-factory.c8
-rw-r--r--calendar/gui/calendar-view.c12
-rw-r--r--calendar/gui/comp-editor-factory.c24
-rw-r--r--calendar/gui/comp-util.c38
-rw-r--r--calendar/gui/dialogs/alarm-dialog.c54
-rw-r--r--calendar/gui/dialogs/alarm-list-dialog.c22
-rw-r--r--calendar/gui/dialogs/cal-attachment-select-file.c38
-rw-r--r--calendar/gui/dialogs/cal-prefs-dialog.c22
-rw-r--r--calendar/gui/dialogs/cal-prefs-dialog.h8
-rw-r--r--calendar/gui/dialogs/calendar-setup.c22
-rw-r--r--calendar/gui/dialogs/cancel-comp.c14
-rw-r--r--calendar/gui/dialogs/changed-comp.c16
-rw-r--r--calendar/gui/dialogs/comp-editor-page.c48
-rw-r--r--calendar/gui/dialogs/comp-editor-util.c30
-rw-r--r--calendar/gui/dialogs/comp-editor.c348
-rw-r--r--calendar/gui/dialogs/comp-editor.h2
-rw-r--r--calendar/gui/dialogs/delete-comp.c34
-rw-r--r--calendar/gui/dialogs/delete-error.c16
-rw-r--r--calendar/gui/dialogs/e-delegate-dialog.c16
-rw-r--r--calendar/gui/dialogs/e-send-options-utils.c84
-rw-r--r--calendar/gui/dialogs/e-send-options-utils.h2
-rw-r--r--calendar/gui/dialogs/event-editor.c156
-rw-r--r--calendar/gui/dialogs/event-page.c518
-rw-r--r--calendar/gui/dialogs/memo-editor.c30
-rw-r--r--calendar/gui/dialogs/memo-page.c146
-rw-r--r--calendar/gui/dialogs/recur-comp.c6
-rw-r--r--calendar/gui/dialogs/recurrence-page.c136
-rw-r--r--calendar/gui/dialogs/save-comp.c4
-rw-r--r--calendar/gui/dialogs/schedule-page.c64
-rw-r--r--calendar/gui/dialogs/select-source-dialog.c4
-rw-r--r--calendar/gui/dialogs/send-comp.c14
-rw-r--r--calendar/gui/dialogs/task-details-page.c42
-rw-r--r--calendar/gui/dialogs/task-editor.c116
-rw-r--r--calendar/gui/dialogs/task-page.c288
-rw-r--r--calendar/gui/e-alarm-list.c22
-rw-r--r--calendar/gui/e-cal-component-memo-preview.c40
-rw-r--r--calendar/gui/e-cal-component-preview.c38
-rw-r--r--calendar/gui/e-cal-list-view-config.c58
-rw-r--r--calendar/gui/e-cal-list-view-config.h10
-rw-r--r--calendar/gui/e-cal-list-view.c14
-rw-r--r--calendar/gui/e-cal-list-view.h8
-rw-r--r--calendar/gui/e-cal-menu.c16
-rw-r--r--calendar/gui/e-cal-menu.h2
-rw-r--r--calendar/gui/e-cal-model-calendar.c8
-rw-r--r--calendar/gui/e-cal-model-memos.c2
-rw-r--r--calendar/gui/e-cal-model-tasks.c42
-rw-r--r--calendar/gui/e-cal-model.c130
-rw-r--r--calendar/gui/e-cal-popup.c124
-rw-r--r--calendar/gui/e-cal-popup.h20
-rw-r--r--calendar/gui/e-calendar-table-config.c60
-rw-r--r--calendar/gui/e-calendar-table-config.h10
-rw-r--r--calendar/gui/e-calendar-table.c82
-rw-r--r--calendar/gui/e-calendar-table.h10
-rw-r--r--calendar/gui/e-calendar-view.c198
-rw-r--r--calendar/gui/e-calendar-view.h16
-rw-r--r--calendar/gui/e-cell-date-edit-config.c76
-rw-r--r--calendar/gui/e-cell-date-edit-config.h10
-rw-r--r--calendar/gui/e-cell-date-edit-text.c4
-rw-r--r--calendar/gui/e-comp-editor-registry.c22
-rw-r--r--calendar/gui/e-date-edit-config.c62
-rw-r--r--calendar/gui/e-date-edit-config.h10
-rw-r--r--calendar/gui/e-day-view-config.c128
-rw-r--r--calendar/gui/e-day-view-config.h10
-rw-r--r--calendar/gui/e-day-view-layout.c4
-rw-r--r--calendar/gui/e-day-view-layout.h8
-rw-r--r--calendar/gui/e-day-view-main-item.c156
-rw-r--r--calendar/gui/e-day-view-main-item.h8
-rw-r--r--calendar/gui/e-day-view-time-item.c22
-rw-r--r--calendar/gui/e-day-view-time-item.h8
-rw-r--r--calendar/gui/e-day-view-top-item.c34
-rw-r--r--calendar/gui/e-day-view-top-item.h8
-rw-r--r--calendar/gui/e-day-view.c328
-rw-r--r--calendar/gui/e-day-view.h10
-rw-r--r--calendar/gui/e-itip-control.c286
-rw-r--r--calendar/gui/e-itip-control.h2
-rw-r--r--calendar/gui/e-meeting-attendee.c226
-rw-r--r--calendar/gui/e-meeting-attendee.h2
-rw-r--r--calendar/gui/e-meeting-list-view.c144
-rw-r--r--calendar/gui/e-meeting-list-view.h2
-rw-r--r--calendar/gui/e-meeting-store.c194
-rw-r--r--calendar/gui/e-meeting-store.h2
-rw-r--r--calendar/gui/e-meeting-time-sel-item.c28
-rw-r--r--calendar/gui/e-meeting-time-sel-item.h8
-rw-r--r--calendar/gui/e-meeting-time-sel.c116
-rw-r--r--calendar/gui/e-meeting-time-sel.h14
-rw-r--r--calendar/gui/e-memo-table-config.c54
-rw-r--r--calendar/gui/e-memo-table-config.h10
-rw-r--r--calendar/gui/e-memo-table.c66
-rw-r--r--calendar/gui/e-memo-table.h8
-rw-r--r--calendar/gui/e-memos.c118
-rw-r--r--calendar/gui/e-mini-calendar-config.c52
-rw-r--r--calendar/gui/e-mini-calendar-config.h10
-rw-r--r--calendar/gui/e-select-names-editable.c26
-rw-r--r--calendar/gui/e-select-names-editable.h2
-rw-r--r--calendar/gui/e-select-names-renderer.c14
-rw-r--r--calendar/gui/e-select-names-renderer.h10
-rw-r--r--calendar/gui/e-tasks.c172
-rw-r--r--calendar/gui/e-timezone-entry.c14
-rw-r--r--calendar/gui/e-timezone-entry.h4
-rw-r--r--calendar/gui/e-week-view-config.c82
-rw-r--r--calendar/gui/e-week-view-config.h10
-rw-r--r--calendar/gui/e-week-view-event-item.c56
-rw-r--r--calendar/gui/e-week-view-event-item.h8
-rw-r--r--calendar/gui/e-week-view-layout.h8
-rw-r--r--calendar/gui/e-week-view-main-item.c38
-rw-r--r--calendar/gui/e-week-view-main-item.h8
-rw-r--r--calendar/gui/e-week-view-titles-item.c10
-rw-r--r--calendar/gui/e-week-view-titles-item.h8
-rw-r--r--calendar/gui/e-week-view.c200
-rw-r--r--calendar/gui/e-week-view.h14
-rw-r--r--calendar/gui/gnome-cal.c346
-rw-r--r--calendar/gui/gnome-cal.h2
-rw-r--r--calendar/gui/goto.c28
-rw-r--r--calendar/gui/itip-bonobo-control.c36
-rw-r--r--calendar/gui/itip-bonobo-control.h2
-rw-r--r--calendar/gui/itip-utils.c320
-rw-r--r--calendar/gui/itip-utils.h4
-rw-r--r--calendar/gui/main.c4
-rw-r--r--calendar/gui/memos-component.c208
-rw-r--r--calendar/gui/migration.c172
-rw-r--r--calendar/gui/misc.c4
-rw-r--r--calendar/gui/print.c126
-rw-r--r--calendar/gui/tag-calendar.c10
-rw-r--r--calendar/gui/tasks-component.c226
-rw-r--r--calendar/gui/tasks-control.c34
-rw-r--r--calendar/gui/weekday-picker.c30
-rw-r--r--calendar/importers/icalendar-importer.c8
-rw-r--r--composer/e-msg-composer-hdrs.c414
-rw-r--r--composer/e-msg-composer-hdrs.h8
-rw-r--r--composer/e-msg-composer-select-file.c26
-rw-r--r--composer/e-msg-composer.c1498
-rw-r--r--composer/e-msg-composer.h4
-rw-r--r--composer/evolution-composer.c30
-rw-r--r--composer/listener.c18
-rw-r--r--composer/listener.h4
-rw-r--r--e-util/e-bconf-map.c116
-rw-r--r--e-util/e-bit-array.c20
-rw-r--r--e-util/e-bit-array.h2
-rw-r--r--e-util/e-categories-config.c10
-rw-r--r--e-util/e-config-listener.c2
-rw-r--r--e-util/e-config.c88
-rw-r--r--e-util/e-config.h40
-rw-r--r--e-util/e-corba-utils.c2
-rw-r--r--e-util/e-corba-utils.h2
-rw-r--r--e-util/e-cursor.c6
-rw-r--r--e-util/e-dialog-utils.c30
-rw-r--r--e-util/e-dialog-widgets.c218
-rw-r--r--e-util/e-error.c32
-rw-r--r--e-util/e-event.c36
-rw-r--r--e-util/e-event.h26
-rw-r--r--e-util/e-folder-map.c54
-rw-r--r--e-util/e-fsutils.c12
-rw-r--r--e-util/e-gui-utils.c2
-rw-r--r--e-util/e-html-utils.h2
-rw-r--r--e-util/e-icon-factory.c20
-rw-r--r--e-util/e-import.c48
-rw-r--r--e-util/e-import.h22
-rw-r--r--e-util/e-menu.c42
-rw-r--r--e-util/e-menu.h38
-rw-r--r--e-util/e-mktemp.c36
-rw-r--r--e-util/e-pilot-map.c86
-rw-r--r--e-util/e-pilot-util.c12
-rw-r--r--e-util/e-plugin.c114
-rw-r--r--e-util/e-plugin.h42
-rw-r--r--e-util/e-popup.c38
-rw-r--r--e-util/e-popup.h24
-rw-r--r--e-util/e-print.c10
-rw-r--r--e-util/e-print.h2
-rw-r--r--e-util/e-profile-event.c12
-rw-r--r--e-util/e-request.c22
-rw-r--r--e-util/e-signature-list.c114
-rw-r--r--e-util/e-signature-list.h4
-rw-r--r--e-util/e-signature.c84
-rw-r--r--e-util/e-signature.h6
-rw-r--r--e-util/e-sorter-array.c2
-rw-r--r--e-util/e-sorter-array.h2
-rw-r--r--e-util/e-sorter.c2
-rw-r--r--e-util/e-sorter.h6
-rw-r--r--e-util/e-text-event-processor-emacs-like.c20
-rw-r--r--e-util/e-text-event-processor-emacs-like.h4
-rw-r--r--e-util/e-text-event-processor-types.h4
-rw-r--r--e-util/e-text-event-processor.c2
-rw-r--r--e-util/e-text-event-processor.h2
-rw-r--r--e-util/e-util-private.h2
-rw-r--r--e-util/e-util.c42
-rw-r--r--e-util/e-util.h2
-rw-r--r--e-util/e-win32-reloc.c6
-rw-r--r--e-util/e-xml-utils.c4
-rw-r--r--e-util/e-xml-utils.h2
-rw-r--r--filter/filter-code.c14
-rw-r--r--filter/filter-code.h4
-rw-r--r--filter/filter-colour.c16
-rw-r--r--filter/filter-colour.h6
-rw-r--r--filter/filter-datespec.c102
-rw-r--r--filter/filter-datespec.h6
-rw-r--r--filter/filter-element.c52
-rw-r--r--filter/filter-element.h10
-rw-r--r--filter/filter-file.c66
-rw-r--r--filter/filter-file.h6
-rw-r--r--filter/filter-input.c90
-rw-r--r--filter/filter-input.h6
-rw-r--r--filter/filter-int.c54
-rw-r--r--filter/filter-int.h6
-rw-r--r--filter/filter-label.c34
-rw-r--r--filter/filter-label.h6
-rw-r--r--filter/filter-option.c78
-rw-r--r--filter/filter-option.h8
-rw-r--r--filter/filter-part.c152
-rw-r--r--filter/filter-part.h6
-rw-r--r--filter/filter-rule.c230
-rw-r--r--filter/filter-rule.h16
-rw-r--r--filter/rule-context.c252
-rw-r--r--filter/rule-context.h8
-rw-r--r--filter/rule-editor.c198
-rw-r--r--filter/rule-editor.h20
-rw-r--r--iconv-detect.c26
-rw-r--r--mail/e-searching-tokenizer.c78
-rw-r--r--mail/e-searching-tokenizer.h8
-rw-r--r--mail/em-account-editor.c88
-rw-r--r--mail/em-account-prefs.c150
-rw-r--r--mail/em-account-prefs.h16
-rw-r--r--mail/em-composer-prefs.c290
-rw-r--r--mail/em-composer-prefs.h26
-rw-r--r--mail/em-composer-utils.c474
-rw-r--r--mail/em-config.c8
-rw-r--r--mail/em-event.c14
-rw-r--r--mail/em-event.h2
-rw-r--r--mail/em-filter-context.c72
-rw-r--r--mail/em-filter-context.h2
-rw-r--r--mail/em-filter-editor.c30
-rw-r--r--mail/em-filter-folder-element.c46
-rw-r--r--mail/em-filter-folder-element.h2
-rw-r--r--mail/em-filter-rule.c136
-rw-r--r--mail/em-filter-rule.h2
-rw-r--r--mail/em-filter-source-element.c88
-rw-r--r--mail/em-folder-browser.c218
-rw-r--r--mail/em-folder-properties.c42
-rw-r--r--mail/em-folder-selection-button.c76
-rw-r--r--mail/em-folder-selection-button.h6
-rw-r--r--mail/em-folder-selection.c8
-rw-r--r--mail/em-folder-selector.c92
-rw-r--r--mail/em-folder-selector.h8
-rw-r--r--mail/em-folder-tree-model.c334
-rw-r--r--mail/em-folder-tree-model.h18
-rw-r--r--mail/em-folder-tree.c490
-rw-r--r--mail/em-folder-tree.h2
-rw-r--r--mail/em-folder-utils.c170
-rw-r--r--mail/em-folder-view.c296
-rw-r--r--mail/em-folder-view.h6
-rw-r--r--mail/em-format-hook.c4
-rw-r--r--mail/em-format-hook.h6
-rw-r--r--mail/em-format-html-display.c176
-rw-r--r--mail/em-format-html.c178
-rw-r--r--mail/em-format-html.h50
-rw-r--r--mail/em-format-quote.c102
-rw-r--r--mail/em-format.c220
-rw-r--r--mail/em-format.h68
-rw-r--r--mail/em-html-stream.c8
-rw-r--r--mail/em-html-stream.h2
-rw-r--r--mail/em-icon-stream.c10
-rw-r--r--mail/em-inline-filter.c26
-rw-r--r--mail/em-junk-hook.c50
-rw-r--r--mail/em-mailer-prefs.c388
-rw-r--r--mail/em-mailer-prefs.h24
-rw-r--r--mail/em-menu.c30
-rw-r--r--mail/em-message-browser.c42
-rw-r--r--mail/em-migrate.c642
-rw-r--r--mail/em-popup.c116
-rw-r--r--mail/em-popup.h38
-rw-r--r--mail/em-search-context.c12
-rw-r--r--mail/em-stripsig-filter.c26
-rw-r--r--mail/em-stripsig-filter.h4
-rw-r--r--mail/em-subscribe-editor.c50
-rw-r--r--mail/em-sync-stream.c12
-rw-r--r--mail/em-sync-stream.h2
-rw-r--r--mail/em-utils.c312
-rw-r--r--mail/em-vfolder-context.c12
-rw-r--r--mail/em-vfolder-context.h2
-rw-r--r--mail/em-vfolder-editor.c22
-rw-r--r--mail/em-vfolder-editor.h2
-rw-r--r--mail/em-vfolder-rule.c142
-rw-r--r--mail/em-vfolder-rule.h2
-rw-r--r--mail/em-vfs-stream.c12
-rw-r--r--mail/importers/elm-importer.c10
-rw-r--r--mail/importers/evolution-mbox-importer.c4
-rw-r--r--mail/importers/mail-importer.c26
-rw-r--r--mail/importers/pine-importer.c16
-rw-r--r--mail/mail-autofilter.c68
-rw-r--r--mail/mail-component-factory.c4
-rw-r--r--mail/mail-component.c178
-rw-r--r--mail/mail-component.h4
-rw-r--r--mail/mail-config-factory.c8
-rw-r--r--mail/mail-config.c340
-rw-r--r--mail/mail-crypto.c4
-rw-r--r--mail/mail-folder-cache.c98
-rw-r--r--mail/mail-folder-cache.h6
-rw-r--r--mail/mail-mt.c52
-rw-r--r--mail/mail-ops.c288
-rw-r--r--mail/mail-ops.h8
-rw-r--r--mail/mail-send-recv.c146
-rw-r--r--mail/mail-session.c110
-rw-r--r--mail/mail-session.h2
-rw-r--r--mail/mail-signature-editor.c104
-rw-r--r--mail/mail-tools.c74
-rw-r--r--mail/mail-tools.h8
-rw-r--r--mail/mail-types.h6
-rw-r--r--mail/mail-vfolder.c78
-rw-r--r--mail/message-list.c566
-rw-r--r--mail/message-list.h20
-rw-r--r--mail/message-tag-editor.c20
-rw-r--r--mail/message-tag-editor.h6
-rw-r--r--mail/message-tag-followup.c86
-rw-r--r--mail/message-tag-followup.h10
-rw-r--r--plugins/addressbook-file/addressbook-file.c12
-rw-r--r--plugins/attachment-reminder/attachment-reminder.c12
-rw-r--r--plugins/audio-inline/audio-inline.c12
-rw-r--r--plugins/backup-restore/backup-restore.c56
-rw-r--r--plugins/backup-restore/backup.c36
-rw-r--r--plugins/bbdb/bbdb.c28
-rw-r--r--plugins/bbdb/bbdb.h2
-rw-r--r--plugins/bbdb/gaimbuddies.c14
-rw-r--r--plugins/bogo-junk-plugin/bf-junk-filter.c4
-rw-r--r--plugins/caldav/caldav-source.c86
-rw-r--r--plugins/calendar-file/calendar-file.c4
-rw-r--r--plugins/calendar-http/calendar-http.c10
-rw-r--r--plugins/copy-tool/copy-tool.c2
-rw-r--r--plugins/default-mailer/default-mailer.c8
-rw-r--r--plugins/default-source/default-source.c26
-rw-r--r--plugins/exchange-operations/exchange-account-setup.c122
-rw-r--r--plugins/exchange-operations/exchange-calendar.c56
-rw-r--r--plugins/exchange-operations/exchange-change-password.c2
-rw-r--r--plugins/exchange-operations/exchange-config-listener.c192
-rw-r--r--plugins/exchange-operations/exchange-config-listener.h4
-rw-r--r--plugins/exchange-operations/exchange-contacts.c64
-rw-r--r--plugins/exchange-operations/exchange-delegates-user.c44
-rw-r--r--plugins/exchange-operations/exchange-delegates-user.h4
-rw-r--r--plugins/exchange-operations/exchange-delegates.c22
-rw-r--r--plugins/exchange-operations/exchange-folder-permission.c8
-rw-r--r--plugins/exchange-operations/exchange-folder-size-display.c10
-rw-r--r--plugins/exchange-operations/exchange-folder-subscription.c14
-rw-r--r--plugins/exchange-operations/exchange-folder.c40
-rw-r--r--plugins/exchange-operations/exchange-mail-send-options.c62
-rw-r--r--plugins/exchange-operations/exchange-operations.c34
-rw-r--r--plugins/exchange-operations/exchange-permissions-dialog.c12
-rw-r--r--plugins/exchange-operations/exchange-send-options.c114
-rw-r--r--plugins/exchange-operations/exchange-send-options.h2
-rw-r--r--plugins/external-editor/external-editor.c8
-rw-r--r--plugins/face/face.c4
-rw-r--r--plugins/folder-unsubscribe/folder-unsubscribe.c20
-rw-r--r--plugins/google-account-setup/google-source.c90
-rw-r--r--plugins/groupwise-account-setup/camel-gw-listener.c264
-rw-r--r--plugins/groupwise-account-setup/camel-gw-listener.h8
-rw-r--r--plugins/groupwise-account-setup/groupwise-account-setup.c8
-rw-r--r--plugins/groupwise-features/addressbook-groupwise.c12
-rw-r--r--plugins/groupwise-features/install-shared.c20
-rw-r--r--plugins/groupwise-features/junk-mail-settings.c34
-rw-r--r--plugins/groupwise-features/junk-settings.c64
-rw-r--r--plugins/groupwise-features/junk-settings.h10
-rw-r--r--plugins/groupwise-features/mail-retract.c12
-rw-r--r--plugins/groupwise-features/mail-send-options.c28
-rw-r--r--plugins/groupwise-features/mail-send-options.h6
-rw-r--r--plugins/groupwise-features/process-meeting.c22
-rw-r--r--plugins/groupwise-features/proxy-login.c98
-rw-r--r--plugins/groupwise-features/proxy-login.h2
-rw-r--r--plugins/groupwise-features/proxy.c190
-rw-r--r--plugins/groupwise-features/proxy.h2
-rw-r--r--plugins/groupwise-features/send-options.c130
-rw-r--r--plugins/groupwise-features/share-folder-common.c120
-rw-r--r--plugins/groupwise-features/share-folder.c102
-rw-r--r--plugins/groupwise-features/share-folder.h12
-rw-r--r--plugins/groupwise-features/status-track.c20
-rw-r--r--plugins/hula-account-setup/camel-hula-listener.c176
-rw-r--r--plugins/hula-account-setup/camel-hula-listener.h8
-rw-r--r--plugins/hula-account-setup/hula-account-setup.c8
-rw-r--r--plugins/imap-features/imap-headers.c40
-rw-r--r--plugins/import-ics-attachments/icsimporter.c30
-rw-r--r--plugins/ipod-sync/evolution-ipod-sync.c8
-rw-r--r--plugins/ipod-sync/ical-format.c6
-rw-r--r--plugins/ipod-sync/ipod-sync.c14
-rw-r--r--plugins/ipod-sync/ipod.c26
-rw-r--r--plugins/ipod-sync/sync.c66
-rw-r--r--plugins/itip-formatter/itip-formatter.c400
-rw-r--r--plugins/itip-formatter/itip-view.c492
-rw-r--r--plugins/itip-formatter/itip-view.h6
-rw-r--r--plugins/mail-account-disable/mail-account-disable.c6
-rw-r--r--plugins/mail-notification/mail-notification.c32
-rw-r--r--plugins/mail-remote/client.c12
-rw-r--r--plugins/mail-remote/em-message-stream.c4
-rw-r--r--plugins/mail-remote/evolution-mail-folder.c4
-rw-r--r--plugins/mail-remote/evolution-mail-folderlistener.c2
-rw-r--r--plugins/mail-remote/evolution-mail-messageiterator.c2
-rw-r--r--plugins/mail-remote/evolution-mail-messagestream.c2
-rw-r--r--plugins/mail-remote/evolution-mail-session.c2
-rw-r--r--plugins/mail-remote/evolution-mail-sessionlistener.c2
-rw-r--r--plugins/mail-remote/evolution-mail-store.c2
-rw-r--r--plugins/mail-remote/evolution-mail-storelistener.c2
-rw-r--r--plugins/mail-to-task/mail-to-task.c42
-rw-r--r--plugins/mailing-list-actions/mailing-list-actions.c14
-rw-r--r--plugins/mark-all-read/mark-all-read.c38
-rw-r--r--plugins/mark-calendar-offline/mark-calendar-offline.c6
-rw-r--r--plugins/mono/mono-plugin.c4
-rw-r--r--plugins/new-mail-notify/new-mail-notify.c38
-rw-r--r--plugins/plugin-manager/plugin-manager.c12
-rw-r--r--plugins/prefer-plain/prefer-plain.c4
-rw-r--r--plugins/print-message/print-message.c8
-rw-r--r--plugins/publish-calendar/publish-calendar.c12
-rw-r--r--plugins/publish-calendar/publish-format-fb.c12
-rw-r--r--plugins/publish-calendar/publish-format-ical.c10
-rw-r--r--plugins/publish-calendar/publish-location.c8
-rw-r--r--plugins/publish-calendar/url-editor-dialog.c4
-rw-r--r--plugins/sa-junk-plugin/em-junk-filter.c100
-rw-r--r--plugins/save-attachments/save-attachments.c10
-rw-r--r--plugins/save-calendar/csv-format.c82
-rw-r--r--plugins/save-calendar/ical-format.c22
-rw-r--r--plugins/save-calendar/rdf-format.c24
-rw-r--r--plugins/save-calendar/save-calendar.c38
-rw-r--r--plugins/select-one-source/mark-calendar-offline.c6
-rw-r--r--plugins/select-one-source/select-one-source.c6
-rw-r--r--plugins/startup-wizard/startup-wizard.c20
-rw-r--r--plugins/subject-thread/subject-thread.c8
-rw-r--r--plugins/tnef-attachments/tnef-plugin.c264
-rw-r--r--shell/e-component-registry.c2
-rw-r--r--shell/e-config-upgrade.c4
-rw-r--r--shell/e-corba-config-page.c6
-rw-r--r--shell/e-history.c2
-rw-r--r--shell/e-shell-folder-title-bar.c36
-rw-r--r--shell/e-shell-importer.c32
-rw-r--r--shell/e-shell-nm-glib.c6
-rw-r--r--shell/e-shell-nm.c46
-rw-r--r--shell/e-shell-settings-dialog.c22
-rw-r--r--shell/e-shell-utils.c6
-rw-r--r--shell/e-shell-window-commands.c14
-rw-r--r--shell/e-shell-window.c26
-rw-r--r--shell/e-shell.c110
-rw-r--r--shell/e-sidebar.c40
-rw-r--r--shell/e-user-creatable-items-handler.c22
-rw-r--r--shell/es-event.c16
-rw-r--r--shell/es-menu.c12
-rw-r--r--shell/evolution-component.c2
-rw-r--r--shell/evolution-config-control.c2
-rw-r--r--shell/evolution-listener.c2
-rw-r--r--shell/evolution-shell-component-utils.c6
-rw-r--r--shell/importer/evolution-importer-client.c20
-rw-r--r--shell/importer/evolution-importer-listener.c8
-rw-r--r--shell/importer/evolution-importer-listener.h2
-rw-r--r--shell/importer/evolution-importer.c4
-rw-r--r--shell/importer/evolution-importer.h4
-rw-r--r--shell/importer/evolution-intelligent-importer.c16
-rw-r--r--shell/importer/intelligent.c54
-rw-r--r--shell/main.c28
-rw-r--r--shell/test/evolution-test-component.c6
-rw-r--r--smime/gui/cert-trust-dialog.c4
-rw-r--r--smime/gui/certificate-manager.c22
-rw-r--r--smime/gui/certificate-viewer.c8
-rw-r--r--smime/gui/e-cert-selector.c12
-rw-r--r--smime/lib/e-asn1-object.c26
-rw-r--r--smime/lib/e-asn1-object.h4
-rw-r--r--smime/lib/e-cert-db.c124
-rw-r--r--smime/lib/e-cert-trust.c52
-rw-r--r--smime/lib/e-cert-trust.h24
-rw-r--r--smime/lib/e-cert.c80
-rw-r--r--smime/lib/e-pkcs12.c44
-rw-r--r--tools/killev.c2
-rw-r--r--widgets/e-timezone-dialog/e-timezone-dialog.c34
-rw-r--r--widgets/menus/gal-define-views-dialog.c18
-rw-r--r--widgets/menus/gal-define-views-dialog.h2
-rw-r--r--widgets/menus/gal-define-views-model.c4
-rw-r--r--widgets/menus/gal-define-views-model.h2
-rw-r--r--widgets/menus/gal-view-collection.c4
-rw-r--r--widgets/menus/gal-view-collection.h2
-rw-r--r--widgets/menus/gal-view-etable.c2
-rw-r--r--widgets/menus/gal-view-etable.h2
-rw-r--r--widgets/menus/gal-view-factory-etable.h2
-rw-r--r--widgets/menus/gal-view-factory.c4
-rw-r--r--widgets/menus/gal-view-factory.h2
-rw-r--r--widgets/menus/gal-view-instance-save-as-dialog.c8
-rw-r--r--widgets/menus/gal-view-instance-save-as-dialog.h2
-rw-r--r--widgets/menus/gal-view-instance.c18
-rw-r--r--widgets/menus/gal-view-instance.h2
-rw-r--r--widgets/menus/gal-view-menus.c14
-rw-r--r--widgets/menus/gal-view-new-dialog.c12
-rw-r--r--widgets/menus/gal-view-new-dialog.h4
-rw-r--r--widgets/menus/gal-view.c10
-rw-r--r--widgets/menus/gal-view.h2
-rw-r--r--widgets/misc/e-activity-handler.c2
-rw-r--r--widgets/misc/e-attachment-bar.c352
-rw-r--r--widgets/misc/e-attachment-bar.h4
-rw-r--r--widgets/misc/e-attachment.c156
-rw-r--r--widgets/misc/e-attachment.h2
-rw-r--r--widgets/misc/e-calendar-item.c74
-rw-r--r--widgets/misc/e-calendar-item.h12
-rw-r--r--widgets/misc/e-calendar.h8
-rw-r--r--widgets/misc/e-canvas-background.c14
-rw-r--r--widgets/misc/e-canvas-background.h2
-rw-r--r--widgets/misc/e-canvas-utils.c14
-rw-r--r--widgets/misc/e-canvas-utils.h2
-rw-r--r--widgets/misc/e-canvas-vbox.c20
-rw-r--r--widgets/misc/e-canvas-vbox.h4
-rw-r--r--widgets/misc/e-canvas.c4
-rw-r--r--widgets/misc/e-canvas.h2
-rw-r--r--widgets/misc/e-cell-date-edit.c12
-rw-r--r--widgets/misc/e-cell-percent.c6
-rw-r--r--widgets/misc/e-cell-renderer-combo.c8
-rw-r--r--widgets/misc/e-cell-renderer-combo.h2
-rw-r--r--widgets/misc/e-charset-picker.c100
-rw-r--r--widgets/misc/e-colors.h2
-rw-r--r--widgets/misc/e-combo-button.c36
-rw-r--r--widgets/misc/e-combo-cell-editable.c52
-rw-r--r--widgets/misc/e-combo-cell-editable.h2
-rw-r--r--widgets/misc/e-config-page.h2
-rw-r--r--widgets/misc/e-cursors.h2
-rw-r--r--widgets/misc/e-dateedit.c26
-rw-r--r--widgets/misc/e-dateedit.h4
-rw-r--r--widgets/misc/e-dropdown-button.c8
-rw-r--r--widgets/misc/e-expander.c18
-rw-r--r--widgets/misc/e-filter-bar.c228
-rw-r--r--widgets/misc/e-filter-bar.h10
-rw-r--r--widgets/misc/e-gui-utils.c2
-rw-r--r--widgets/misc/e-gui-utils.h2
-rw-r--r--widgets/misc/e-hsv-utils.c10
-rw-r--r--widgets/misc/e-hsv-utils.h2
-rw-r--r--widgets/misc/e-icon-entry.c10
-rw-r--r--widgets/misc/e-icon-entry.h2
-rw-r--r--widgets/misc/e-image-chooser.c4
-rw-r--r--widgets/misc/e-image-chooser.h2
-rw-r--r--widgets/misc/e-info-label.c20
-rw-r--r--widgets/misc/e-map.c50
-rw-r--r--widgets/misc/e-multi-config-dialog.c16
-rw-r--r--widgets/misc/e-pilot-settings.c20
-rw-r--r--widgets/misc/e-popup-menu.c10
-rw-r--r--widgets/misc/e-popup-menu.h2
-rw-r--r--widgets/misc/e-printable.c10
-rw-r--r--widgets/misc/e-printable.h2
-rw-r--r--widgets/misc/e-reflow-model.c8
-rw-r--r--widgets/misc/e-reflow-model.h4
-rw-r--r--widgets/misc/e-reflow.c78
-rw-r--r--widgets/misc/e-reflow.h6
-rw-r--r--widgets/misc/e-search-bar.c216
-rw-r--r--widgets/misc/e-search-bar.h8
-rw-r--r--widgets/misc/e-selection-model-array.c24
-rw-r--r--widgets/misc/e-selection-model-array.h2
-rw-r--r--widgets/misc/e-selection-model-simple.c2
-rw-r--r--widgets/misc/e-selection-model-simple.h2
-rw-r--r--widgets/misc/e-selection-model.c28
-rw-r--r--widgets/misc/e-selection-model.h2
-rw-r--r--widgets/misc/e-send-options.c138
-rw-r--r--widgets/misc/e-send-options.h4
-rw-r--r--widgets/misc/e-spinner.c12
-rw-r--r--widgets/misc/e-spinner.h2
-rw-r--r--widgets/misc/e-task-bar.c6
-rw-r--r--widgets/misc/e-task-bar.h2
-rw-r--r--widgets/misc/e-task-widget.c6
-rw-r--r--widgets/misc/e-unicode.c14
-rw-r--r--widgets/misc/e-url-entry.c14
-rw-r--r--widgets/misc/test-color.c2
-rw-r--r--widgets/misc/test-dropdown-button.c2
-rw-r--r--widgets/table/e-cell-checkbox.c16
-rw-r--r--widgets/table/e-cell-combo.c18
-rw-r--r--widgets/table/e-cell-combo.h2
-rw-r--r--widgets/table/e-cell-date.c6
-rw-r--r--widgets/table/e-cell-date.h2
-rw-r--r--widgets/table/e-cell-float.c8
-rw-r--r--widgets/table/e-cell-hbox.c20
-rw-r--r--widgets/table/e-cell-hbox.h4
-rw-r--r--widgets/table/e-cell-number.c6
-rw-r--r--widgets/table/e-cell-number.h2
-rw-r--r--widgets/table/e-cell-pixbuf.c16
-rw-r--r--widgets/table/e-cell-popup.c18
-rw-r--r--widgets/table/e-cell-progress.c22
-rw-r--r--widgets/table/e-cell-progress.h2
-rw-r--r--widgets/table/e-cell-size.c6
-rw-r--r--widgets/table/e-cell-spin-button.c274
-rw-r--r--widgets/table/e-cell-spin-button.h12
-rw-r--r--widgets/table/e-cell-text.c172
-rw-r--r--widgets/table/e-cell-text.h4
-rw-r--r--widgets/table/e-cell-toggle.c32
-rw-r--r--widgets/table/e-cell-toggle.h2
-rw-r--r--widgets/table/e-cell-tree.c48
-rw-r--r--widgets/table/e-cell-tree.h2
-rw-r--r--widgets/table/e-cell-vbox.c24
-rw-r--r--widgets/table/e-cell-vbox.h2
-rw-r--r--widgets/table/e-cell.c18
-rw-r--r--widgets/table/e-cell.h6
-rw-r--r--widgets/table/e-table-click-to-add.c26
-rw-r--r--widgets/table/e-table-click-to-add.h4
-rw-r--r--widgets/table/e-table-col-dnd.h2
-rw-r--r--widgets/table/e-table-col.c28
-rw-r--r--widgets/table/e-table-col.h2
-rw-r--r--widgets/table/e-table-column-specification.c4
-rw-r--r--widgets/table/e-table-column-specification.h2
-rw-r--r--widgets/table/e-table-column.c20
-rw-r--r--widgets/table/e-table-config-field.h2
-rw-r--r--widgets/table/e-table-config.c162
-rw-r--r--widgets/table/e-table-config.h4
-rw-r--r--widgets/table/e-table-defines.h2
-rw-r--r--widgets/table/e-table-example-1.c16
-rw-r--r--widgets/table/e-table-example-2.c12
-rw-r--r--widgets/table/e-table-extras.h2
-rw-r--r--widgets/table/e-table-field-chooser-dialog.c6
-rw-r--r--widgets/table/e-table-field-chooser-dialog.h4
-rw-r--r--widgets/table/e-table-field-chooser-item.c32
-rw-r--r--widgets/table/e-table-field-chooser-item.h2
-rw-r--r--widgets/table/e-table-field-chooser.c8
-rw-r--r--widgets/table/e-table-field-chooser.h4
-rw-r--r--widgets/table/e-table-group-container.c76
-rw-r--r--widgets/table/e-table-group-container.h2
-rw-r--r--widgets/table/e-table-group-leaf.c2
-rw-r--r--widgets/table/e-table-group-leaf.h4
-rw-r--r--widgets/table/e-table-group.h6
-rw-r--r--widgets/table/e-table-header-item.c168
-rw-r--r--widgets/table/e-table-header-item.h6
-rw-r--r--widgets/table/e-table-header-utils.c10
-rw-r--r--widgets/table/e-table-header-utils.h2
-rw-r--r--widgets/table/e-table-header.c70
-rw-r--r--widgets/table/e-table-header.h4
-rw-r--r--widgets/table/e-table-item.c242
-rw-r--r--widgets/table/e-table-item.h10
-rw-r--r--widgets/table/e-table-memory-callbacks.c12
-rw-r--r--widgets/table/e-table-memory-callbacks.h2
-rw-r--r--widgets/table/e-table-memory-store.c14
-rw-r--r--widgets/table/e-table-memory-store.h2
-rw-r--r--widgets/table/e-table-memory.c70
-rw-r--r--widgets/table/e-table-memory.h2
-rw-r--r--widgets/table/e-table-model.c48
-rw-r--r--widgets/table/e-table-model.h4
-rw-r--r--widgets/table/e-table-one.c14
-rw-r--r--widgets/table/e-table-one.h4
-rw-r--r--widgets/table/e-table-scrolled.h2
-rw-r--r--widgets/table/e-table-search.c12
-rw-r--r--widgets/table/e-table-search.h2
-rw-r--r--widgets/table/e-table-selection-model.c10
-rw-r--r--widgets/table/e-table-selection-model.h2
-rw-r--r--widgets/table/e-table-simple.c10
-rw-r--r--widgets/table/e-table-simple.h4
-rw-r--r--widgets/table/e-table-size-test.c12
-rw-r--r--widgets/table/e-table-sort-info.c20
-rw-r--r--widgets/table/e-table-sort-info.h6
-rw-r--r--widgets/table/e-table-sorted-variable.h4
-rw-r--r--widgets/table/e-table-sorted.c2
-rw-r--r--widgets/table/e-table-sorted.h4
-rw-r--r--widgets/table/e-table-sorter.c8
-rw-r--r--widgets/table/e-table-sorter.h2
-rw-r--r--widgets/table/e-table-sorting-utils.c2
-rw-r--r--widgets/table/e-table-sorting-utils.h2
-rw-r--r--widgets/table/e-table-specification.c30
-rw-r--r--widgets/table/e-table-specification.h2
-rw-r--r--widgets/table/e-table-state.c18
-rw-r--r--widgets/table/e-table-state.h2
-rw-r--r--widgets/table/e-table-subset-variable.c12
-rw-r--r--widgets/table/e-table-subset-variable.h4
-rw-r--r--widgets/table/e-table-subset.c4
-rw-r--r--widgets/table/e-table-subset.h2
-rw-r--r--widgets/table/e-table-tooltip.h2
-rw-r--r--widgets/table/e-table-tree.h2
-rw-r--r--widgets/table/e-table-utils.h2
-rw-r--r--widgets/table/e-table-without.c4
-rw-r--r--widgets/table/e-table-without.h4
-rw-r--r--widgets/table/e-table.c148
-rw-r--r--widgets/table/e-table.h8
-rw-r--r--widgets/table/e-tree-memory-callbacks.c14
-rw-r--r--widgets/table/e-tree-memory-callbacks.h4
-rw-r--r--widgets/table/e-tree-memory.c86
-rw-r--r--widgets/table/e-tree-memory.h2
-rw-r--r--widgets/table/e-tree-model.c346
-rw-r--r--widgets/table/e-tree-model.h4
-rw-r--r--widgets/table/e-tree-scrolled.h2
-rw-r--r--widgets/table/e-tree-selection-model.c22
-rw-r--r--widgets/table/e-tree-selection-model.h2
-rw-r--r--widgets/table/e-tree-simple.c34
-rw-r--r--widgets/table/e-tree-simple.h2
-rw-r--r--widgets/table/e-tree-sorted-variable.c4
-rw-r--r--widgets/table/e-tree-sorted-variable.h4
-rw-r--r--widgets/table/e-tree-sorted.c18
-rw-r--r--widgets/table/e-tree-sorted.h2
-rw-r--r--widgets/table/e-tree-table-adapter.c34
-rw-r--r--widgets/table/e-tree-table-adapter.h2
-rw-r--r--widgets/table/e-tree.c60
-rw-r--r--widgets/table/e-tree.h6
-rw-r--r--widgets/table/table-test.h2
-rw-r--r--widgets/table/test-check.c12
-rw-r--r--widgets/table/test-cols.c18
-rw-r--r--widgets/text/e-text-model-repos.c4
-rw-r--r--widgets/text/e-text-model-repos.h4
-rw-r--r--widgets/text/e-text-model-test.c6
-rw-r--r--widgets/text/e-text-model.c18
-rw-r--r--widgets/text/e-text-model.h2
-rw-r--r--widgets/text/e-text-test.c4
-rw-r--r--widgets/text/e-text.c186
-rw-r--r--widgets/text/e-text.h4
816 files changed, 18135 insertions, 18131 deletions
diff --git a/ChangeLog b/ChangeLog
index 121b26c70d..70f7fecaca 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2007-11-14 Matthew Barnes <mbarnes@redhat.com>
+
+ ** Remove trailing whitespace from source code.
+
2007-11-10 Michael Monreal <mmonreal@svn.gnome.org>
** Fix for bug #209425
diff --git a/a11y/addressbook/ea-addressbook-view.c b/a11y/addressbook/ea-addressbook-view.c
index 67b4c6318d..62981ebca1 100644
--- a/a11y/addressbook/ea-addressbook-view.c
+++ b/a11y/addressbook/ea-addressbook-view.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* ea-addressbook-view.c
* Copyright (C) 2000 Ximian, Inc.
*
@@ -103,7 +103,7 @@ ea_ab_view_get_description (AtkObject *accessible)
return _("evolution addressbook");
}
-AtkObject*
+AtkObject*
ea_ab_view_new (GObject *obj)
{
GObject *object;
diff --git a/a11y/addressbook/ea-addressbook-view.h b/a11y/addressbook/ea-addressbook-view.h
index d1498d98c1..2fe13ca2c2 100644
--- a/a11y/addressbook/ea-addressbook-view.h
+++ b/a11y/addressbook/ea-addressbook-view.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* ea-addressbook_view.h
* Copyright (C) 2000 Ximian, Inc.
*
diff --git a/a11y/addressbook/ea-minicard-view.c b/a11y/addressbook/ea-minicard-view.c
index c6b7d4b029..52f923eb24 100644
--- a/a11y/addressbook/ea-minicard-view.c
+++ b/a11y/addressbook/ea-minicard-view.c
@@ -1,8 +1,8 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* ea-minicard-view.c
* Copyright (C) 2000 Ximian, Inc.
- * Author: Leon Zhang < leon.zhang@sun.com>
+ * Author: Leon Zhang < leon.zhang@sun.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
@@ -90,13 +90,13 @@ ea_minicard_view_get_type (void)
(GInterfaceFinalizeFunc) NULL,
NULL
};
-
+
static const GInterfaceInfo atk_action_info = {
(GInterfaceInitFunc) atk_action_interface_init,
(GInterfaceFinalizeFunc) NULL,
NULL
};
-
+
/*
* Figure out the size of the class and instance
* we are run-time deriving from (GailWidget, in this case) */
@@ -115,7 +115,7 @@ ea_minicard_view_get_type (void)
&atk_selection_info);
g_type_add_interface_static (type, ATK_TYPE_ACTION,
&atk_action_info);
-
+
}
return type;
@@ -150,7 +150,7 @@ ea_minicard_view_get_name (AtkObject *accessible)
if (!reflow)
return NULL;
-
+
/* Get the current name of minicard view*/
card_view = E_MINICARD_VIEW (reflow);
g_object_get (card_view->adapter, "book", &book, NULL);
@@ -179,7 +179,7 @@ ea_minicard_view_get_description (AtkObject *accessible)
return _("evolution addressbook");
}
-AtkObject*
+AtkObject*
ea_minicard_view_new (GObject *obj)
{
GObject *object;
@@ -197,18 +197,18 @@ static gint
ea_minicard_view_get_n_children (AtkObject *accessible)
{
EReflow *reflow;
-
+
gint child_num = 0;
-
+
g_return_val_if_fail (EA_IS_MINICARD_VIEW (accessible), -1);
-
+
reflow = E_REFLOW (atk_gobject_accessible_get_object (ATK_GOBJECT_ACCESSIBLE(accessible)));
if (!reflow)
return -1;
-
+
child_num = reflow->count;
-
+
return child_num;
}
@@ -216,7 +216,7 @@ static AtkStateSet *ea_minicard_view_ref_state_set (AtkObject *obj)
{
AtkStateSet *state_set = NULL;
GObject *gobj = NULL;
-
+
state_set = ATK_OBJECT_CLASS (parent_class)->ref_state_set (obj);
if( !state_set )
state_set = atk_state_set_new ();
@@ -224,7 +224,7 @@ static AtkStateSet *ea_minicard_view_ref_state_set (AtkObject *obj)
gobj = atk_gobject_accessible_get_object (ATK_GOBJECT_ACCESSIBLE (obj));
if( !gobj )
return state_set;
-
+
atk_state_set_add_state (state_set, ATK_STATE_ENABLED);
atk_state_set_add_state (state_set, ATK_STATE_SENSITIVE);
atk_state_set_add_state (state_set, ATK_STATE_SHOWING);
@@ -241,11 +241,11 @@ ea_minicard_view_ref_child (AtkObject *accessible, gint index)
EMinicard *card = NULL;
g_return_val_if_fail (EA_IS_MINICARD_VIEW (accessible), NULL);
-
+
child_num = atk_object_get_n_accessible_children (accessible);
if (child_num <= 0 || index < 0 || index >= child_num)
return NULL;
-
+
reflow = E_REFLOW (atk_gobject_accessible_get_object (ATK_GOBJECT_ACCESSIBLE (accessible)));
if (!reflow)
return NULL;
@@ -282,13 +282,13 @@ selection_interface_add_selection (AtkSelection *selection, gint i)
{
AtkGObjectAccessible *atk_gobj= NULL;
EReflow *reflow = NULL;
-
+
atk_gobj = ATK_GOBJECT_ACCESSIBLE (selection);
reflow = E_REFLOW (atk_gobject_accessible_get_object (atk_gobj));
-
+
if (!reflow)
return FALSE;
-
+
selection_interface_clear_selection (selection);
e_selection_model_select_single_row (reflow->selection, i);
@@ -306,9 +306,9 @@ selection_interface_clear_selection (AtkSelection *selection)
if( !reflow )
return FALSE;
-
+
e_selection_model_clear (reflow->selection);
-
+
return TRUE;
}
@@ -329,7 +329,7 @@ selection_interface_get_selection_count (AtkSelection *selection)
if (!reflow )
return FALSE;
-
+
return e_selection_model_selected_count (reflow->selection);
}
@@ -417,4 +417,4 @@ atk_action_interface_get_name (AtkAction *iface, gint i)
return action_name[i];
}
-
+
diff --git a/a11y/addressbook/ea-minicard-view.h b/a11y/addressbook/ea-minicard-view.h
index c0046e0e61..01f73c1494 100644
--- a/a11y/addressbook/ea-minicard-view.h
+++ b/a11y/addressbook/ea-minicard-view.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* ea-minicard-view.h
* Copyright (C) 2000 Ximian, Inc.
* Author: Leon Zhang <leon.zhang@sun.com> Sun Microsystem Inc., 2003
diff --git a/a11y/addressbook/ea-minicard.c b/a11y/addressbook/ea-minicard.c
index 8d4e41082b..888b7423de 100644
--- a/a11y/addressbook/ea-minicard.c
+++ b/a11y/addressbook/ea-minicard.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* ea-minicard.c
* Copyright (C) 2000 Ximian, Inc.
*
@@ -79,7 +79,7 @@ ea_minicard_get_type (void)
/*
* Figure out the size of the class and instance
- * we are run-time deriving from (GailWidget, in this case)
+ * we are run-time deriving from (GailWidget, in this case)
*/
factory = atk_registry_get_factory (atk_get_default_registry (),
@@ -93,7 +93,7 @@ ea_minicard_get_type (void)
type = g_type_register_static ( derived_atk_type,
"EaMinicard", &tinfo, 0);
g_type_add_interface_static (type, ATK_TYPE_ACTION,
- &atk_action_info);
+ &atk_action_info);
}
return type;
@@ -114,14 +114,14 @@ ea_minicard_class_init (EaMinicardClass *klass)
}
/*
- * we access the main content of current minicard, including
+ * we access the main content of current minicard, including
* header text, label(field, field name)
*/
static G_CONST_RETURN gchar*
ea_minicard_get_name (AtkObject *accessible)
{
#define BUFFERSIZE 500
-
+
static gchar name[BUFFERSIZE];
GString *new_str = g_string_new (NULL);
gchar *string;
@@ -130,7 +130,7 @@ ea_minicard_get_name (AtkObject *accessible)
g_return_val_if_fail (EA_IS_MINICARD(accessible), NULL);
memset (name, '\0', BUFFERSIZE);
- card = E_MINICARD(atk_gobject_accessible_get_object
+ card = E_MINICARD(atk_gobject_accessible_get_object
(ATK_GOBJECT_ACCESSIBLE(accessible)));
if (!card)
return NULL;
@@ -140,7 +140,7 @@ ea_minicard_get_name (AtkObject *accessible)
if (e_contact_get (card->contact, E_CONTACT_IS_LIST))
g_string_append (new_str, _("Contact List: "));
else g_string_append (new_str, _("Contact: "));
-
+
/* get header of current card */
g_string_append (new_str, string);
g_free (string);
@@ -168,7 +168,7 @@ ea_minicard_get_description (AtkObject *accessible)
return _("evolution minicard");
}
-AtkObject*
+AtkObject*
ea_minicard_new (GObject *obj)
{
GObject *object;
@@ -267,7 +267,7 @@ atk_action_interface_get_name (AtkAction *iface, gint i)
{
if( i >= G_N_ELEMENTS (action_name) || i < 0)
return NULL;
-
+
return action_name[i];
}
-
+
diff --git a/a11y/addressbook/ea-minicard.h b/a11y/addressbook/ea-minicard.h
index bb184762e4..e745a6acff 100644
--- a/a11y/addressbook/ea-minicard.h
+++ b/a11y/addressbook/ea-minicard.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* ea-minicard.h
* Copyright (C) 2000 Ximian, Inc.
*
@@ -16,7 +16,7 @@
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
- *
+ *
* Author: Leon Zhang <leon.zhang@sun.com> Sun Microsystem Inc., 2003
*/
#ifndef __EA_MINICARD_H__
diff --git a/a11y/calendar/ea-cal-view-event.c b/a11y/calendar/ea-cal-view-event.c
index 9f7e694597..a85ce348c6 100644
--- a/a11y/calendar/ea-cal-view-event.c
+++ b/a11y/calendar/ea-cal-view-event.c
@@ -114,7 +114,7 @@ ea_cal_view_event_get_type (void)
g_type_add_interface_static (type, ATK_TYPE_ACTION,
&atk_action_info);
-
+
}
return type;
@@ -164,7 +164,7 @@ static void ea_cal_view_finalize (GObject *object)
}
#endif
-AtkObject*
+AtkObject*
ea_cal_view_event_new (GObject *obj)
{
AtkObject *atk_obj = NULL;
@@ -262,21 +262,21 @@ ea_cal_view_event_get_name (AtkObject *accessible)
alarm_string = recur_string = meeting_string = "";
if (event && event->comp_data) {
- if (e_cal_util_component_has_alarms (event->comp_data->icalcomp))
+ if (e_cal_util_component_has_alarms (event->comp_data->icalcomp))
alarm_string = _("It has alarms.");
- if (e_cal_util_component_has_recurrences (event->comp_data->icalcomp))
+ if (e_cal_util_component_has_recurrences (event->comp_data->icalcomp))
recur_string = _("It has recurrences.");
- if (e_cal_util_component_has_organizer (event->comp_data->icalcomp))
+ if (e_cal_util_component_has_organizer (event->comp_data->icalcomp))
meeting_string = _("It is a meeting.");
-
+
}
summary = icalcomponent_get_summary (event->comp_data->icalcomp);
- if (summary)
+ if (summary)
summary_string = g_strdup_printf (_("Calendar Event: Summary is %s."), summary);
- else
+ else
summary_string = g_strdup (_("Calendar Event: It has no summary."));
name_string = g_strdup_printf ("%s %s %s %s", summary_string, alarm_string, recur_string, meeting_string);
@@ -410,7 +410,7 @@ ea_cal_view_event_ref_state_set (AtkObject *accessible)
/* Atk Component Interface */
-static void
+static void
atk_component_interface_init (AtkComponentIface *iface)
{
g_return_if_fail (iface != NULL);
@@ -418,7 +418,7 @@ atk_component_interface_init (AtkComponentIface *iface)
iface->get_extents = ea_cal_view_get_extents;
}
-static void
+static void
ea_cal_view_get_extents (AtkComponent *component,
gint *x,
gint *y,
diff --git a/a11y/calendar/ea-cal-view.c b/a11y/calendar/ea-cal-view.c
index ad52976ca1..9ce7a11fc8 100644
--- a/a11y/calendar/ea-cal-view.c
+++ b/a11y/calendar/ea-cal-view.c
@@ -118,7 +118,7 @@ ea_cal_view_class_init (EaCalViewClass *klass)
class->initialize = ea_cal_view_real_initialize;
}
-AtkObject*
+AtkObject*
ea_cal_view_new (GtkWidget *widget)
{
GObject *object;
@@ -169,7 +169,7 @@ ea_cal_view_real_initialize (AtkObject *accessible, gpointer data)
accessible);
}
-static AtkObject*
+static AtkObject*
ea_cal_view_get_parent (AtkObject *accessible)
{
ECalendarView *cal_view;
diff --git a/a11y/calendar/ea-calendar-helpers.c b/a11y/calendar/ea-calendar-helpers.c
index caf1913829..aff9f0c771 100644
--- a/a11y/calendar/ea-calendar-helpers.c
+++ b/a11y/calendar/ea-calendar-helpers.c
@@ -36,7 +36,7 @@
* ea_calendar_helpers_get_accessible_for
* @canvas_item: the canvas item for a event or a jump button
* @returns: the atk object for the canvas_item
- *
+ *
**/
AtkObject *
ea_calendar_helpers_get_accessible_for (GnomeCanvasItem *canvas_item)
@@ -71,7 +71,7 @@ ea_calendar_helpers_get_accessible_for (GnomeCanvasItem *canvas_item)
* @returns: the cal view widget if exists
*
* Get the cal view widget contains the canvas_item.
- *
+ *
**/
ECalendarView *
ea_calendar_helpers_get_cal_view_from (GnomeCanvasItem *canvas_item)
diff --git a/a11y/calendar/ea-calendar.c b/a11y/calendar/ea-calendar.c
index 8c2167fac5..be9c48d594 100644
--- a/a11y/calendar/ea-calendar.c
+++ b/a11y/calendar/ea-calendar.c
@@ -107,7 +107,7 @@ e_day_view_a11y_init (void)
EA_SET_FACTORY (e_day_view_get_type(), ea_day_view);
}
-void
+void
e_day_view_main_item_a11y_init (void)
{
EA_SET_FACTORY (e_day_view_main_item_get_type (), ea_day_view_main_item);
@@ -119,7 +119,7 @@ e_week_view_a11y_init (void)
EA_SET_FACTORY (e_week_view_get_type(), ea_week_view);
}
-void
+void
e_week_view_main_item_a11y_init (void)
{
EA_SET_FACTORY (e_week_view_main_item_get_type (), ea_week_view_main_item);
diff --git a/a11y/calendar/ea-day-view-cell.c b/a11y/calendar/ea-day-view-cell.c
index b32dc4d0f0..ec1718225a 100644
--- a/a11y/calendar/ea-day-view-cell.c
+++ b/a11y/calendar/ea-day-view-cell.c
@@ -166,7 +166,7 @@ ea_day_view_cell_class_init (EaDayViewCellClass *klass)
class->get_index_in_parent = ea_day_view_cell_get_index_in_parent;
}
-AtkObject*
+AtkObject*
ea_day_view_cell_new (GObject *obj)
{
gpointer object;
@@ -263,7 +263,7 @@ ea_day_view_cell_ref_state_set (AtkObject *obj)
if (x + width < parent_x || x > parent_x + parent_width ||
y + height < parent_y || y > parent_y + parent_height)
- /* the cell is out of the main canvas */
+ /* the cell is out of the main canvas */
;
else
atk_state_set_add_state (state_set, ATK_STATE_VISIBLE);
@@ -312,7 +312,7 @@ ea_day_view_cell_get_index_in_parent (AtkObject *accessible)
/* Atk Component Interface */
-static void
+static void
atk_component_interface_init (AtkComponentIface *iface)
{
g_return_if_fail (iface != NULL);
@@ -321,7 +321,7 @@ atk_component_interface_init (AtkComponentIface *iface)
iface->grab_focus = component_interface_grab_focus;
}
-static void
+static void
component_interface_get_extents (AtkComponent *component,
gint *x, gint *y, gint *width, gint *height,
AtkCoordType coord_type)
diff --git a/a11y/calendar/ea-day-view-main-item.c b/a11y/calendar/ea-day-view-main-item.c
index 1889b9cf17..658df70cd2 100644
--- a/a11y/calendar/ea-day-view-main-item.c
+++ b/a11y/calendar/ea-day-view-main-item.c
@@ -63,7 +63,7 @@ static gint table_interface_get_column_at_index (AtkTable *table,
static gint table_interface_get_row_at_index (AtkTable *table,
gint index);
static AtkObject* table_interface_ref_at (AtkTable *table,
- gint row,
+ gint row,
gint column);
static gint table_interface_get_n_rows (AtkTable *table);
static gint table_interface_get_n_columns (AtkTable *table);
@@ -229,7 +229,7 @@ ea_day_view_main_item_class_init (EaDayViewMainItemClass *klass)
class->get_index_in_parent = ea_day_view_main_item_get_index_in_parent;
}
-AtkObject*
+AtkObject*
ea_day_view_main_item_new (GObject *obj)
{
AtkObject *accessible;
@@ -451,7 +451,7 @@ ea_day_view_main_item_time_change_cb (EDayView *day_view, gpointer data)
"active-descendant-changed",
item_cell);
g_signal_emit_by_name (data, "selection_changed");
-
+
atk_focus_tracker_notify (item_cell);
g_object_unref (item_cell);
}
@@ -618,7 +618,7 @@ ea_day_view_main_item_destory_cell_data (EaDayViewMainItem *ea_main_item)
/* Atk Component Interface */
-static void
+static void
atk_component_interface_init (AtkComponentIface *iface)
{
g_return_if_fail (iface != NULL);
@@ -626,7 +626,7 @@ atk_component_interface_init (AtkComponentIface *iface)
iface->get_extents = component_interface_get_extents;
}
-static void
+static void
component_interface_get_extents (AtkComponent *component,
gint *x, gint *y, gint *width, gint *height,
AtkCoordType coord_type)
@@ -654,7 +654,7 @@ component_interface_get_extents (AtkComponent *component,
/* atk table interface */
-static void
+static void
atk_table_interface_init (AtkTableIface *iface)
{
g_return_if_fail (iface != NULL);
@@ -687,9 +687,9 @@ atk_table_interface_init (AtkTableIface *iface)
iface->get_column_description = table_interface_get_column_description;
}
-static AtkObject*
+static AtkObject*
table_interface_ref_at (AtkTable *table,
- gint row,
+ gint row,
gint column)
{
gint index;
@@ -700,7 +700,7 @@ table_interface_ref_at (AtkTable *table,
return ea_day_view_main_item_ref_child (ATK_OBJECT (ea_main_item), index);
}
-static gint
+static gint
table_interface_get_n_rows (AtkTable *table)
{
AtkGObjectAccessible *atk_gobj;
@@ -720,7 +720,7 @@ table_interface_get_n_rows (AtkTable *table)
return day_view->rows;
}
-static gint
+static gint
table_interface_get_n_columns (AtkTable *table)
{
AtkGObjectAccessible *atk_gobj;
@@ -787,7 +787,7 @@ table_interface_get_column_extent_at (AtkTable *table,
return width;
}
-static gint
+static gint
table_interface_get_row_extent_at (AtkTable *table,
gint row,
gint column)
@@ -808,7 +808,7 @@ table_interface_get_row_extent_at (AtkTable *table,
return height;
}
-static gboolean
+static gboolean
table_interface_is_row_selected (AtkTable *table,
gint row)
{
@@ -838,16 +838,16 @@ table_interface_is_row_selected (AtkTable *table,
return FALSE;
}
-static gboolean
-table_interface_is_selected (AtkTable *table,
- gint row,
+static gboolean
+table_interface_is_selected (AtkTable *table,
+ gint row,
gint column)
{
return table_interface_is_row_selected (table, row) &&
table_interface_is_column_selected (table, column);
}
-static gboolean
+static gboolean
table_interface_is_column_selected (AtkTable *table,
gint column)
{
@@ -871,7 +871,7 @@ table_interface_is_column_selected (AtkTable *table,
return FALSE;
}
-static gint
+static gint
table_interface_get_selected_rows (AtkTable *table,
gint **rows_selected)
{
@@ -912,7 +912,7 @@ table_interface_get_selected_rows (AtkTable *table,
return n_rows;
}
-static gint
+static gint
table_interface_get_selected_columns (AtkTable *table,
gint **columns_selected)
{
@@ -946,8 +946,8 @@ table_interface_get_selected_columns (AtkTable *table,
return n_columns;
}
-static gboolean
-table_interface_add_row_selection (AtkTable *table,
+static gboolean
+table_interface_add_row_selection (AtkTable *table,
gint row)
{
AtkGObjectAccessible *atk_gobj;
@@ -979,15 +979,15 @@ table_interface_add_row_selection (AtkTable *table,
return TRUE;
}
-static gboolean
-table_interface_remove_row_selection (AtkTable *table,
+static gboolean
+table_interface_remove_row_selection (AtkTable *table,
gint row)
{
return FALSE;
}
-static gboolean
-table_interface_add_column_selection (AtkTable *table,
+static gboolean
+table_interface_add_column_selection (AtkTable *table,
gint column)
{
AtkGObjectAccessible *atk_gobj;
@@ -1016,24 +1016,24 @@ table_interface_add_column_selection (AtkTable *table,
return TRUE;
}
-static gboolean
-table_interface_remove_column_selection (AtkTable *table,
+static gboolean
+table_interface_remove_column_selection (AtkTable *table,
gint column)
{
/* FIXME: NOT IMPLEMENTED */
return FALSE;
}
-static AtkObject*
-table_interface_get_row_header (AtkTable *table,
+static AtkObject*
+table_interface_get_row_header (AtkTable *table,
gint row)
{
/* FIXME: NOT IMPLEMENTED */
return NULL;
}
-static AtkObject*
-table_interface_get_column_header (AtkTable *table,
+static AtkObject*
+table_interface_get_column_header (AtkTable *table,
gint in_col)
{
/* FIXME: NOT IMPLEMENTED */
@@ -1202,7 +1202,7 @@ selection_interface_clear_selection (AtkSelection *selection)
return TRUE;
}
-static AtkObject*
+static AtkObject*
selection_interface_ref_selection (AtkSelection *selection, gint i)
{
gint count;
diff --git a/a11y/calendar/ea-day-view.c b/a11y/calendar/ea-day-view.c
index 8a397c8fe2..66537c0f3f 100644
--- a/a11y/calendar/ea-day-view.c
+++ b/a11y/calendar/ea-day-view.c
@@ -100,7 +100,7 @@ ea_day_view_class_init (EaDayViewClass *klass)
class->ref_child = ea_day_view_ref_child;
}
-AtkObject*
+AtkObject*
ea_day_view_new (GtkWidget *widget)
{
GObject *object;
@@ -146,24 +146,24 @@ ea_day_view_get_name (AtkObject *accessible)
/* the child main item is always there */
--n_events;
if (n_events >= 1)
- /* To translators: Here, "It" is either like "Work Week View: July
+ /* To translators: Here, "It" is either like "Work Week View: July
10th - July 14th, 2006." or "Day View: Thursday July 13th, 2006." */
event_str = g_strdup_printf (ngettext ("It has %d event.", "It has %d events.", n_events), n_events);
else
- /* To translators: Here, "It" is either like "Work Week View: July
+ /* To translators: Here, "It" is either like "Work Week View: July
10th - July 14th, 2006." or "Day View: Thursday July 13th, 2006." */
event_str = g_strdup (_("It has no events."));
view_type = gnome_calendar_get_view (gcal);
if (view_type == GNOME_CAL_WORK_WEEK_VIEW)
- /* To translators: First %s is the week, for example "July 10th -
- July 14th, 2006". Second %s is the number of events in this work
+ /* To translators: First %s is the week, for example "July 10th -
+ July 14th, 2006". Second %s is the number of events in this work
week, for example "It has %d event/events." or "It has no events." */
name_str = g_strdup_printf (_("Work Week View: %s. %s"),
label_text, event_str);
else
- /* To translators: First %s is the day, for example "Thursday July
- 13th, 2006". Second %s is the number of events on this day, for
+ /* To translators: First %s is the day, for example "Thursday July
+ 13th, 2006". Second %s is the number of events on this day, for
example "It has %d event/events." or "It has no events." */
name_str = g_strdup_printf (_("Day View: %s. %s"),
label_text, event_str);
diff --git a/a11y/calendar/ea-gnome-calendar.c b/a11y/calendar/ea-gnome-calendar.c
index 509d515f2d..6de483f952 100644
--- a/a11y/calendar/ea-gnome-calendar.c
+++ b/a11y/calendar/ea-gnome-calendar.c
@@ -100,7 +100,7 @@ ea_gnome_calendar_class_init (EaGnomeCalendarClass *klass)
class->ref_child = ea_gnome_calendar_ref_child;
}
-AtkObject*
+AtkObject*
ea_gnome_calendar_new (GtkWidget *widget)
{
GObject *object;
diff --git a/a11y/calendar/ea-jump-button.c b/a11y/calendar/ea-jump-button.c
index 45dcc3fe06..2d239091a9 100644
--- a/a11y/calendar/ea-jump-button.c
+++ b/a11y/calendar/ea-jump-button.c
@@ -110,7 +110,7 @@ ea_jump_button_class_init (EaJumpButtonClass *klass)
class->get_description = ea_jump_button_get_description;
}
-AtkObject*
+AtkObject*
ea_jump_button_new (GObject *obj)
{
AtkObject *atk_obj = NULL;
@@ -197,7 +197,7 @@ jump_button_do_action (AtkAction *action,
return_value = FALSE;
break;
}
- return return_value;
+ return return_value;
}
static gint
@@ -222,5 +222,5 @@ jump_button_get_keybinding (AtkAction *action,
default:
break;
}
- return return_value;
+ return return_value;
}
diff --git a/a11y/calendar/ea-week-view-cell.c b/a11y/calendar/ea-week-view-cell.c
index b557812f4b..0ee410b5f5 100644
--- a/a11y/calendar/ea-week-view-cell.c
+++ b/a11y/calendar/ea-week-view-cell.c
@@ -167,7 +167,7 @@ ea_week_view_cell_class_init (EaWeekViewCellClass *klass)
}
-AtkObject*
+AtkObject*
ea_week_view_cell_new (GObject *obj)
{
gpointer object;
@@ -232,7 +232,7 @@ ea_week_view_cell_get_name (AtkObject *accessible)
new_column = cell->column + start_day;
new_row = cell->row;
}
-
+
column_label = atk_table_get_column_description (ATK_TABLE (ea_main_item),
new_column);
row_label = atk_table_get_row_description (ATK_TABLE (ea_main_item),
@@ -275,7 +275,7 @@ ea_week_view_cell_ref_state_set (AtkObject *obj)
if (x + width < parent_x || x > parent_x + parent_width ||
y + height < parent_y || y > parent_y + parent_height)
- /* the cell is out of the main canvas */
+ /* the cell is out of the main canvas */
;
else
atk_state_set_add_state (state_set, ATK_STATE_VISIBLE);
@@ -324,7 +324,7 @@ ea_week_view_cell_get_index_in_parent (AtkObject *accessible)
/* Atk Component Interface */
-static void
+static void
atk_component_interface_init (AtkComponentIface *iface)
{
g_return_if_fail (iface != NULL);
@@ -333,7 +333,7 @@ atk_component_interface_init (AtkComponentIface *iface)
iface->grab_focus = component_interface_grab_focus;
}
-static void
+static void
component_interface_get_extents (AtkComponent *component,
gint *x, gint *y, gint *width, gint *height,
AtkCoordType coord_type)
@@ -391,7 +391,7 @@ component_interface_get_extents (AtkComponent *component,
*y += week_view->row_offsets[cell->row*2]- scroll_y;
}
} else {
- if (start_day < 3) {
+ if (start_day < 3) {
if (cell->column < 3) {
*height = week_view->row_heights[cell->column*2]*2;
*width = week_view->col_widths[0];
@@ -438,8 +438,8 @@ component_interface_get_extents (AtkComponent *component,
*y += week_view->row_offsets[(cell->column - 1)*2]- scroll_y;
} else {
*height = week_view->row_heights[(cell->column)*2]*2;
- *width = week_view->col_widths[0];
- *x += week_view->col_offsets[0] - scroll_x;
+ *width = week_view->col_widths[0];
+ *x += week_view->col_offsets[0] - scroll_x;
*y += week_view->row_offsets[cell->column*2]- scroll_y;
}
} else {
diff --git a/a11y/calendar/ea-week-view-main-item.c b/a11y/calendar/ea-week-view-main-item.c
index 17220fd185..01c6f0236e 100644
--- a/a11y/calendar/ea-week-view-main-item.c
+++ b/a11y/calendar/ea-week-view-main-item.c
@@ -64,7 +64,7 @@ static gint table_interface_get_column_at_index (AtkTable *table,
static gint table_interface_get_row_at_index (AtkTable *table,
gint index);
static AtkObject* table_interface_ref_at (AtkTable *table,
- gint row,
+ gint row,
gint column);
static gint table_interface_get_n_rows (AtkTable *table);
static gint table_interface_get_n_columns (AtkTable *table);
@@ -183,7 +183,7 @@ ea_week_view_main_item_get_type (void)
(GInterfaceFinalizeFunc) NULL,
NULL
};
-
+
/*
* Figure out the size of the class and instance
@@ -230,7 +230,7 @@ ea_week_view_main_item_class_init (EaWeekViewMainItemClass *klass)
class->get_index_in_parent = ea_week_view_main_item_get_index_in_parent;
}
-AtkObject*
+AtkObject*
ea_week_view_main_item_new (GObject *obj)
{
AtkObject *accessible;
@@ -318,10 +318,10 @@ ea_week_view_main_item_get_n_children (AtkObject *accessible)
main_item = E_WEEK_VIEW_MAIN_ITEM (g_obj);
week_view = main_item->week_view;
-
+
if (week_view->multi_week_view)
return 7 * week_view->weeks_shown;
- else
+ else
return 7;
}
@@ -593,7 +593,7 @@ ea_week_view_main_item_destory_cell_data (EaWeekViewMainItem *ea_main_item)
/* Atk Component Interface */
-static void
+static void
atk_component_interface_init (AtkComponentIface *iface)
{
g_return_if_fail (iface != NULL);
@@ -601,7 +601,7 @@ atk_component_interface_init (AtkComponentIface *iface)
iface->get_extents = component_interface_get_extents;
}
-static void
+static void
component_interface_get_extents (AtkComponent *component,
gint *x, gint *y, gint *width, gint *height,
AtkCoordType coord_type)
@@ -629,7 +629,7 @@ component_interface_get_extents (AtkComponent *component,
/* atk table interface */
-static void
+static void
atk_table_interface_init (AtkTableIface *iface)
{
g_return_if_fail (iface != NULL);
@@ -662,9 +662,9 @@ atk_table_interface_init (AtkTableIface *iface)
iface->get_column_description = table_interface_get_column_description;
}
-static AtkObject*
+static AtkObject*
table_interface_ref_at (AtkTable *table,
- gint row,
+ gint row,
gint column)
{
gint index;
@@ -675,7 +675,7 @@ table_interface_ref_at (AtkTable *table,
return ea_week_view_main_item_ref_child (ATK_OBJECT (ea_main_item), index);
}
-static gint
+static gint
table_interface_get_n_rows (AtkTable *table)
{
AtkGObjectAccessible *atk_gobj;
@@ -695,7 +695,7 @@ table_interface_get_n_rows (AtkTable *table)
return week_view->weeks_shown;
}
-static gint
+static gint
table_interface_get_n_columns (AtkTable *table)
{
AtkGObjectAccessible *atk_gobj;
@@ -757,7 +757,7 @@ table_interface_get_column_extent_at (AtkTable *table,
return width;
}
-static gint
+static gint
table_interface_get_row_extent_at (AtkTable *table,
gint row,
gint column)
@@ -778,7 +778,7 @@ table_interface_get_row_extent_at (AtkTable *table,
return height;
}
-static gboolean
+static gboolean
table_interface_is_row_selected (AtkTable *table,
gint row)
{
@@ -808,15 +808,15 @@ table_interface_is_row_selected (AtkTable *table,
return TRUE;
}
-static gboolean
-table_interface_is_selected (AtkTable *table,
- gint row,
+static gboolean
+table_interface_is_selected (AtkTable *table,
+ gint row,
gint column)
{
return table_interface_is_row_selected (table, row) && table_interface_is_column_selected(table, column);
}
-static gboolean
+static gboolean
table_interface_is_column_selected (AtkTable *table,
gint column)
{
@@ -846,7 +846,7 @@ table_interface_is_column_selected (AtkTable *table,
}
}
-static gint
+static gint
table_interface_get_selected_rows (AtkTable *table,
gint **rows_selected)
{
@@ -881,7 +881,7 @@ table_interface_get_selected_rows (AtkTable *table,
return n_rows;
}
-static gint
+static gint
table_interface_get_selected_columns (AtkTable *table,
gint **columns_selected)
{
@@ -911,7 +911,7 @@ table_interface_get_selected_columns (AtkTable *table,
}
if (n_columns > 0 && start_column != -1 && columns_selected) {
gint index;
-
+
*columns_selected = (gint *) g_malloc (n_columns * sizeof (gint));
for (index = 0; index < n_columns; ++index)
(*columns_selected)[index] = start_column + index;
@@ -919,8 +919,8 @@ table_interface_get_selected_columns (AtkTable *table,
return n_columns;
}
-static gboolean
-table_interface_add_row_selection (AtkTable *table,
+static gboolean
+table_interface_add_row_selection (AtkTable *table,
gint row)
{
AtkGObjectAccessible *atk_gobj;
@@ -946,15 +946,15 @@ table_interface_add_row_selection (AtkTable *table,
return TRUE;
}
-static gboolean
-table_interface_remove_row_selection (AtkTable *table,
+static gboolean
+table_interface_remove_row_selection (AtkTable *table,
gint row)
{
return FALSE;
}
-static gboolean
-table_interface_add_column_selection (AtkTable *table,
+static gboolean
+table_interface_add_column_selection (AtkTable *table,
gint column)
{
AtkGObjectAccessible *atk_gobj;
@@ -980,24 +980,24 @@ table_interface_add_column_selection (AtkTable *table,
return TRUE;
}
-static gboolean
-table_interface_remove_column_selection (AtkTable *table,
+static gboolean
+table_interface_remove_column_selection (AtkTable *table,
gint column)
{
/* FIXME: NOT IMPLEMENTED */
return FALSE;
}
-static AtkObject*
-table_interface_get_row_header (AtkTable *table,
+static AtkObject*
+table_interface_get_row_header (AtkTable *table,
gint row)
{
/* FIXME: NOT IMPLEMENTED */
return NULL;
}
-static AtkObject*
-table_interface_get_column_header (AtkTable *table,
+static AtkObject*
+table_interface_get_column_header (AtkTable *table,
gint in_col)
{
/* FIXME: NOT IMPLEMENTED */
@@ -1061,7 +1061,7 @@ table_interface_get_column_description (AtkTable *table,
default:
break;
}
-
+
ea_cell_table_set_column_label (cell_data, in_col, buffer);
description = ea_cell_table_get_column_label (cell_data, in_col);
}
@@ -1179,7 +1179,7 @@ selection_interface_clear_selection (AtkSelection *selection)
return TRUE;
}
-static AtkObject*
+static AtkObject*
selection_interface_ref_selection (AtkSelection *selection, gint i)
{
gint count;
@@ -1244,7 +1244,7 @@ selection_interface_is_child_selected (AtkSelection *selection, gint i)
if ((week_view->selection_start_day <= i)&&(week_view->selection_end_day >= i))
return TRUE;
- else
+ else
return FALSE;
}
diff --git a/a11y/calendar/ea-week-view.c b/a11y/calendar/ea-week-view.c
index fb2ce7bdab..c1f1debc2b 100644
--- a/a11y/calendar/ea-week-view.c
+++ b/a11y/calendar/ea-week-view.c
@@ -101,7 +101,7 @@ ea_week_view_class_init (EaWeekViewClass *klass)
class->ref_child = ea_week_view_ref_child;
}
-AtkObject*
+AtkObject*
ea_week_view_new (GtkWidget *widget)
{
GObject *object;
@@ -273,7 +273,7 @@ ea_week_view_ref_child (AtkObject *accessible, gint index)
/* index == 0 is the main item */
atk_object = atk_gobject_accessible_for_object (G_OBJECT (week_view->main_canvas_item));
g_object_ref (atk_object);
- } else
+ } else
for (event_index = 0; event_index < max_count; ++event_index) {
EWeekViewEvent *event;
EWeekViewEventSpan *span;
diff --git a/a11y/e-table/gal-a11y-e-cell-popup.c b/a11y/e-table/gal-a11y-e-cell-popup.c
index 64e11bcf98..c0110e9dba 100644
--- a/a11y/e-table/gal-a11y-e-cell-popup.c
+++ b/a11y/e-table/gal-a11y-e-cell-popup.c
@@ -43,11 +43,11 @@ static void popup_cell_action (GalA11yECell *cell);
/**
* gal_a11y_e_cell_popup_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yECellPopup class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yECellPopup class.
**/
GType
@@ -99,7 +99,7 @@ gal_a11y_e_cell_popup_new (ETableItem *item,
if (popupcell && popupcell->popup_cell_view)
child_view = popupcell->popup_cell_view->child_view;
-
+
if (child_view && child_view->ecell) {
a11y = gal_a11y_e_cell_registry_get_object (NULL,
item,
@@ -120,7 +120,7 @@ gal_a11y_e_cell_popup_new (ETableItem *item,
}
g_return_val_if_fail (a11y != NULL, NULL);
cell = GAL_A11Y_E_CELL(a11y);
- gal_a11y_e_cell_add_action (cell,
+ gal_a11y_e_cell_add_action (cell,
_("popup"), /* action name*/
_("popup a child"), /* action description */
"<Alt>Down", /* action keybinding */
@@ -136,12 +136,12 @@ popup_cell_action (GalA11yECell *cell)
gint finished;
GdkEvent event;
- event.key.type = GDK_KEY_PRESS;
+ event.key.type = GDK_KEY_PRESS;
event.key.window = GTK_LAYOUT(GNOME_CANVAS_ITEM(cell->item)->canvas)->bin_window;;
event.key.send_event = TRUE;
event.key.time = GDK_CURRENT_TIME;
event.key.state = GDK_MOD1_MASK;
event.key.keyval = GDK_Down;
-
+
g_signal_emit_by_name (cell->item, "event", &event, &finished);
}
diff --git a/a11y/e-table/gal-a11y-e-cell-registry.c b/a11y/e-table/gal-a11y-e-cell-registry.c
index 9557ec5464..72ff48e33f 100644
--- a/a11y/e-table/gal-a11y-e-cell-registry.c
+++ b/a11y/e-table/gal-a11y-e-cell-registry.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Christopher James Lahey <clahey@ximian.com>
*
* Copyright (C) 2002 Ximian, Inc.
@@ -51,11 +51,11 @@ gal_a11y_e_cell_registry_init (GalA11yECellRegistry *registry)
/**
* gal_a11y_e_cell_registry_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yECellRegistry class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yECellRegistry class.
**/
GType
diff --git a/a11y/e-table/gal-a11y-e-cell-text.c b/a11y/e-table/gal-a11y-e-cell-text.c
index baee1c3cbc..696127ae3b 100644
--- a/a11y/e-table/gal-a11y-e-cell-text.c
+++ b/a11y/e-table/gal-a11y-e-cell-text.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Christopher James Lahey <clahey@ximian.com>
*
* Copyright (C) 2002 Ximian, Inc.
@@ -193,7 +193,7 @@ ect_get_caret_offset (AtkText *text)
gchar *full_text = e_cell_text_get_text_by_view (gaec->cell_view, gaec->model_col, gaec->row);
end = g_utf8_pointer_to_offset (full_text, full_text + end);
g_free (full_text);
-
+
return end;
}
else
@@ -261,7 +261,7 @@ ect_get_offset_at_point (AtkText *text,
}
-static gint
+static gint
ect_get_n_selections (AtkText *text)
{
GalA11yECell *gaec = GAL_A11Y_E_CELL (text);
@@ -344,7 +344,7 @@ ect_add_selection (AtkText *text,
real_start = MIN (start_offset, end_offset);
real_end = MAX (start_offset, end_offset);
-
+
real_start = MIN (MAX (0, real_start), len);
real_end = MIN (MAX (0, real_end), len);
@@ -376,7 +376,7 @@ ect_remove_selection (AtkText *text,
gaec->view_col, gaec->row,
&selection_start,
&selection_end)
- && selection_start != selection_end
+ && selection_start != selection_end
&& e_cell_text_set_selection (gaec->cell_view,
gaec->view_col, gaec->row,
selection_end, selection_end)) {
@@ -418,7 +418,7 @@ ect_set_caret_offset (AtkText *text,
offset = len;
else
offset = MIN (MAX (0, offset), len);
-
+
offset = g_utf8_offset_to_pointer (full_text, offset) - full_text;
g_free (full_text);
@@ -598,7 +598,7 @@ ect_class_init (GalA11yECellTextClass *klass)
{
AtkObjectClass *a11y = ATK_OBJECT_CLASS (klass);
GObjectClass *object_class = G_OBJECT_CLASS (klass);
-
+
parent_class = g_type_class_ref (PARENT_TYPE);
a11y->get_name = ect_get_name;
object_class->dispose = ect_dispose;
@@ -619,11 +619,11 @@ ect_action_init (GalA11yECellText *a11y)
/**
* gal_a11y_e_cell_text_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yECellText class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yECellText class.
**/
GType
@@ -670,7 +670,7 @@ static void
cell_text_destroyed (gpointer data)
{
g_return_if_fail (GAL_A11Y_IS_E_CELL_TEXT (data));
-
+
g_object_unref (data);
}
@@ -685,7 +685,7 @@ gal_a11y_e_cell_text_new (ETableItem *item,
AtkObject *a11y;
GalA11yECell *gaec;
GalA11yECellText *gaet;
- ECellText *ect;
+ ECellText *ect;
a11y = g_object_new (gal_a11y_e_cell_text_get_type (), NULL);
@@ -701,9 +701,9 @@ gal_a11y_e_cell_text_new (ETableItem *item,
/* will be unrefed in cell_text_destroyed */
g_object_ref (a11y);
- gaet->inserted_id = g_signal_connect (E_CELL_TEXT (((ECellView *)cell_view)->ecell),
+ gaet->inserted_id = g_signal_connect (E_CELL_TEXT (((ECellView *)cell_view)->ecell),
"text_inserted", G_CALLBACK (ect_text_inserted_cb), a11y);
- gaet->deleted_id = g_signal_connect (E_CELL_TEXT (((ECellView *)cell_view)->ecell),
+ gaet->deleted_id = g_signal_connect (E_CELL_TEXT (((ECellView *)cell_view)->ecell),
"text_deleted", G_CALLBACK (ect_text_deleted_cb), a11y);
g_object_weak_ref (G_OBJECT (((ECellView *)cell_view)->ecell),
diff --git a/a11y/e-table/gal-a11y-e-cell-toggle.c b/a11y/e-table/gal-a11y-e-cell-toggle.c
index 6d1bbfd45e..8f994adeae 100644
--- a/a11y/e-table/gal-a11y-e-cell-toggle.c
+++ b/a11y/e-table/gal-a11y-e-cell-toggle.c
@@ -47,18 +47,18 @@ gal_a11y_e_cell_toggle_get_type (void)
NULL, /* instance init */
NULL /* value table */
};
-
+
type = g_type_register_static (GAL_A11Y_TYPE_E_CELL,
"GalA11yECellToggle", &tinfo, 0);
gal_a11y_e_cell_type_add_action_interface (type);
-
+
}
return type;
}
-static void
+static void
gal_a11y_e_cell_toggle_class_init (GalA11yECellToggleClass *klass)
{
GObjectClass *object_class = G_OBJECT_CLASS (klass);
@@ -118,7 +118,7 @@ model_change_cb (ETableModel *etm,
}
-AtkObject*
+AtkObject*
gal_a11y_e_cell_toggle_new (ETableItem *item,
ECellView *cell_view,
AtkObject *parent,
@@ -147,7 +147,7 @@ gal_a11y_e_cell_toggle_new (ETableItem *item,
view_col,
row);
- gal_a11y_e_cell_add_action (cell,
+ gal_a11y_e_cell_add_action (cell,
_("toggle"), /* action name*/
_("toggle the cell"), /* action description */
NULL, /* action keybinding */
diff --git a/a11y/e-table/gal-a11y-e-cell-tree.c b/a11y/e-table/gal-a11y-e-cell-tree.c
index abc0c67ddb..a4b68b89ab 100644
--- a/a11y/e-table/gal-a11y-e-cell-tree.c
+++ b/a11y/e-table/gal-a11y-e-cell-tree.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Tim Wo <tim.wo@sun.com>, Sun Microsystem Inc. 2003.
*
* Copyright (C) 2002 Ximian, Inc.
@@ -89,7 +89,7 @@ ectr_do_action_expand (AtkAction *action)
ETreePath node;
ETreeModel *tree_model;
ETreeTableAdapter *tree_table_adapter;
-
+
a11y = GAL_A11Y_E_CELL (action);
table_model = a11y->item->table_model;
node = e_table_model_value_at (table_model, -1, a11y->row);
@@ -112,7 +112,7 @@ ectr_do_action_collapse (AtkAction *action)
ETreePath node;
ETreeModel *tree_model;
ETreeTableAdapter *tree_table_adapter;
-
+
a11y = GAL_A11Y_E_CELL (action);
table_model = a11y->item->table_model;
node = e_table_model_value_at (table_model, -1, a11y->row);
@@ -178,7 +178,7 @@ gal_a11y_e_cell_tree_new (ETableItem *item,
ETreePath node;
ETreeModel *tree_model;
ETreeTableAdapter *tree_table_adapter;
-
+
ECellView *subcell_view;
subcell_view = e_cell_tree_view_get_subcell_view (cell_view);
diff --git a/a11y/e-table/gal-a11y-e-cell-vbox.c b/a11y/e-table/gal-a11y-e-cell-vbox.c
index caed5d4fc2..268dc51691 100644
--- a/a11y/e-table/gal-a11y-e-cell-vbox.c
+++ b/a11y/e-table/gal-a11y-e-cell-vbox.c
@@ -46,7 +46,7 @@ subcell_destroyed (gpointer data)
GalA11yECell *cell;
AtkObject *parent;
GalA11yECellVbox *gaev;
-
+
g_return_if_fail (GAL_A11Y_IS_E_CELL (data));
cell = GAL_A11Y_E_CELL (data);
@@ -199,9 +199,9 @@ gal_a11y_e_cell_vbox_get_type (void)
AtkObject *gal_a11y_e_cell_vbox_new (ETableItem *item,
ECellView *cell_view,
- AtkObject *parent,
- int model_col,
- int view_col,
+ AtkObject *parent,
+ int model_col,
+ int view_col,
int row)
{
AtkObject *a11y;
@@ -210,13 +210,13 @@ AtkObject *gal_a11y_e_cell_vbox_new (ETableItem *item,
ECellVboxView *ecvv;
a11y = g_object_new (gal_a11y_e_cell_vbox_get_type (), NULL);
-
+
gal_a11y_e_cell_construct (a11y, item, cell_view, parent, model_col, view_col, row);
gaec = GAL_A11Y_E_CELL (a11y);
gaev = GAL_A11Y_E_CELL_VBOX (a11y);
ecvv = (ECellVboxView *) (gaec->cell_view);
- gaev->a11y_subcell_count = ecvv->subcell_view_count;
+ gaev->a11y_subcell_count = ecvv->subcell_view_count;
gaev->a11y_subcells = g_malloc0 (sizeof(AtkObject *)*gaev->a11y_subcell_count);
return a11y;
}
diff --git a/a11y/e-table/gal-a11y-e-cell-vbox.h b/a11y/e-table/gal-a11y-e-cell-vbox.h
index 121db71671..32a199c05a 100644
--- a/a11y/e-table/gal-a11y-e-cell-vbox.h
+++ b/a11y/e-table/gal-a11y-e-cell-vbox.h
@@ -53,9 +53,9 @@ struct _GalA11yECellVboxClass
GType gal_a11y_e_cell_vbox_get_type (void);
AtkObject *gal_a11y_e_cell_vbox_new (ETableItem *item,
ECellView *cell_view,
- AtkObject *parent,
- int model_col,
- int view_col,
+ AtkObject *parent,
+ int model_col,
+ int view_col,
int row);
#ifdef __cplusplus
diff --git a/a11y/e-table/gal-a11y-e-cell.c b/a11y/e-table/gal-a11y-e-cell.c
index c19622d2b5..f6372eedc4 100644
--- a/a11y/e-table/gal-a11y-e-cell.c
+++ b/a11y/e-table/gal-a11y-e-cell.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Christopher James Lahey <clahey@ximian.com>
*
* Copyright (C) 2002 Ximian, Inc.
@@ -42,9 +42,9 @@ unref_cell (gpointer user_data, GObject *obj_loc)
a11y->cell_view = NULL;
g_object_unref (a11y);
}
-#endif
+#endif
-static gboolean
+static gboolean
is_valid (AtkObject *cell)
{
GalA11yECell *a11y = GAL_A11Y_E_CELL (cell);
@@ -113,7 +113,7 @@ gal_a11y_e_cell_ref_state_set (AtkObject *accessible)
GalA11yECell *cell = GAL_A11Y_E_CELL (accessible);
g_return_val_if_fail (cell->state_set, NULL);
-
+
g_object_ref(cell->state_set);
return cell->state_set;
@@ -193,10 +193,10 @@ gal_a11y_e_cell_grab_focus (AtkComponent *component)
a11yTableItem = GAL_A11Y_E_TABLE_ITEM (a11y->parent);
index = atk_object_get_index_in_parent (ATK_OBJECT (a11y));
-
+
atk_selection_clear_selection (ATK_SELECTION (a11yTableItem));
atk_selection_add_selection (ATK_SELECTION (a11yTableItem), index);
-
+
gtk_widget_grab_focus (GTK_WIDGET (GNOME_CANVAS_ITEM (a11y->item)->canvas));
toplevel = gtk_widget_get_toplevel (GTK_WIDGET (GNOME_CANVAS_ITEM (a11y->item)->canvas));
if (toplevel && GTK_WIDGET_TOPLEVEL (toplevel))
@@ -256,7 +256,7 @@ _gal_a11y_e_cell_get_action_info (GalA11yECell *cell,
gint index)
{
GList *list_node;
-
+
g_return_val_if_fail (GAL_A11Y_IS_E_CELL (cell), NULL);
if (cell->action_list == NULL)
return NULL;
@@ -290,7 +290,7 @@ gal_a11y_e_cell_add_action ( GalA11yECell * cell,
ActionInfo *info;
g_return_val_if_fail (GAL_A11Y_IS_E_CELL (cell), FALSE);
info = g_new (ActionInfo, 1);
-
+
if (action_name != NULL)
info->name = g_strdup (action_name);
else
@@ -333,7 +333,7 @@ gal_a11y_e_cell_remove_action_by_name (GalA11yECell *cell,
{
GList *list_node;
gboolean action_found= FALSE;
-
+
g_return_val_if_fail (GAL_A11Y_IS_E_CELL (cell), FALSE);
for (list_node = cell->action_list; list_node && !action_found;
list_node = list_node->next) {
@@ -366,7 +366,7 @@ gal_a11y_e_cell_action_get_name (AtkAction *action,
{
GalA11yECell *cell = GAL_A11Y_E_CELL(action);
ActionInfo *info = _gal_a11y_e_cell_get_action_info (cell, index);
-
+
if (info == NULL)
return NULL;
return info->name;
@@ -391,7 +391,7 @@ gal_a11y_e_cell_action_set_description (AtkAction *action,
{
GalA11yECell *cell = GAL_A11Y_E_CELL(action);
ActionInfo *info = _gal_a11y_e_cell_get_action_info (cell, index);
-
+
if (info == NULL)
return FALSE;
g_free (info->description);
@@ -410,7 +410,7 @@ gal_a11y_e_cell_action_get_keybinding (AtkAction *action,
return info->keybinding;
}
-
+
static gboolean
idle_do_action (gpointer data)
{
@@ -424,7 +424,7 @@ idle_do_action (gpointer data)
cell->action_idle_handler = 0;
cell->action_func (cell);
g_object_unref (cell);
-
+
return FALSE;
}
@@ -454,7 +454,7 @@ static void
gal_a11y_e_cell_atk_action_interface_init (AtkActionIface *iface)
{
g_return_if_fail (iface != NULL);
-
+
iface->get_n_actions = gal_a11y_e_cell_action_get_n_actions;
iface->do_action = gal_a11y_e_cell_action_do_action;
iface->get_name = gal_a11y_e_cell_action_get_name;
@@ -484,17 +484,17 @@ gal_a11y_e_cell_add_state (GalA11yECell *cell,
{
if (!atk_state_set_contains_state (cell->state_set, state_type)) {
gboolean rc;
-
+
rc = atk_state_set_add_state (cell->state_set, state_type);
/*
* The signal should only be generated if the value changed,
* not when the cell is set up. So states that are set
* initially should pass FALSE as the emit_signal argument.
*/
-
+
if (emit_signal) {
atk_object_notify_state_change (ATK_OBJECT (cell), state_type, TRUE);
- /* If state_type is ATK_STATE_VISIBLE, additional
+ /* If state_type is ATK_STATE_VISIBLE, additional
notification */
if (state_type == ATK_STATE_VISIBLE)
g_signal_emit_by_name (cell, "visible_data_changed");
@@ -513,7 +513,7 @@ gal_a11y_e_cell_remove_state (GalA11yECell *cell,
{
if (atk_state_set_contains_state (cell->state_set, state_type)) {
gboolean rc;
-
+
rc = atk_state_set_remove_state (cell->state_set, state_type);
/*
* The signal should only be generated if the value changed,
@@ -536,11 +536,11 @@ gal_a11y_e_cell_remove_state (GalA11yECell *cell,
/**
* gal_a11y_e_cell_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yECell class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yECell class.
**/
GType
@@ -616,14 +616,14 @@ gal_a11y_e_cell_construct (AtkObject *object,
ATK_OBJECT (a11y) ->role = ATK_ROLE_TABLE_CELL;
if (item)
- g_object_ref (G_OBJECT (item));
+ g_object_ref (G_OBJECT (item));
#if 0
if (parent)
g_object_ref (parent);
if (cell_view)
- g_object_ref (G_OBJECT (cell_view));
+ g_object_ref (G_OBJECT (cell_view));
#endif
diff --git a/a11y/e-table/gal-a11y-e-cell.h b/a11y/e-table/gal-a11y-e-cell.h
index b3f5ef3277..48da764102 100644
--- a/a11y/e-table/gal-a11y-e-cell.h
+++ b/a11y/e-table/gal-a11y-e-cell.h
@@ -74,16 +74,16 @@ void gal_a11y_e_cell_construct (AtkObject *object,
int row);
void gal_a11y_e_cell_type_add_action_interface (GType type);
-
+
gboolean gal_a11y_e_cell_add_action (GalA11yECell *cell,
const gchar *action_name,
const gchar *action_description,
const gchar *action_keybinding,
ACTION_FUNC action_func);
-
+
gboolean gal_a11y_e_cell_remove_action (GalA11yECell *cell,
gint action_id);
-
+
gboolean gal_a11y_e_cell_remove_action_by_name (GalA11yECell *cell,
const gchar *action_name);
diff --git a/a11y/e-table/gal-a11y-e-table-click-to-add-factory.c b/a11y/e-table/gal-a11y-e-table-click-to-add-factory.c
index ab98b4a10b..2dfa2cb1c4 100644
--- a/a11y/e-table/gal-a11y-e-table-click-to-add-factory.c
+++ b/a11y/e-table/gal-a11y-e-table-click-to-add-factory.c
@@ -57,11 +57,11 @@ gal_a11y_e_table_click_to_add_factory_init (GalA11yETableClickToAddFactory *fact
/**
* gal_a11y_e_table_factory_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yETableFactory class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yETableFactory class.
**/
GType
diff --git a/a11y/e-table/gal-a11y-e-table-click-to-add.c b/a11y/e-table/gal-a11y-e-table-click-to-add.c
index 819946cbbb..a4905971de 100644
--- a/a11y/e-table/gal-a11y-e-table-click-to-add.c
+++ b/a11y/e-table/gal-a11y-e-table-click-to-add.c
@@ -70,14 +70,14 @@ idle_do_action (gpointer data)
event.x = 0;
event.y = 0;
-
+
event.type = GDK_BUTTON_PRESS;
event.window = GTK_LAYOUT(GNOME_CANVAS_ITEM(etcta)->canvas)->bin_window;
event.button = 1;
event.send_event = TRUE;
event.time = GDK_CURRENT_TIME;
event.axes = NULL;
-
+
g_signal_emit_by_name (etcta, "event", &event, &finished);
return FALSE;
@@ -97,7 +97,7 @@ static void
atk_action_interface_init (AtkActionIface *iface)
{
g_return_if_fail (iface != NULL);
-
+
iface->do_action = etcta_do_action;
iface->get_n_actions = etcta_get_n_actions;
iface->get_description = etcta_get_description;
@@ -184,11 +184,11 @@ etcta_init (GalA11yETableClickToAdd *a11y)
/**
* gal_a11y_e_table_click_to_add_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yETableClickToAdd class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yETableClickToAdd class.
**/
GType
@@ -222,9 +222,9 @@ gal_a11y_e_table_click_to_add_get_type (void)
parent_type = atk_object_factory_get_accessible_type (factory);
type = gal_a11y_type_register_static_with_private (PARENT_TYPE,
- "GalA11yETableClickToAdd", &info, 0,
+ "GalA11yETableClickToAdd", &info, 0,
sizeof(GalA11yETableClickToAddPrivate), &priv_offset);
-
+
g_type_add_interface_static (type, ATK_TYPE_ACTION, &atk_action_info);
}
@@ -238,7 +238,7 @@ etcta_event (GnomeCanvasItem *item, GdkEvent *e, gpointer data)
ETableClickToAdd *etcta = E_TABLE_CLICK_TO_ADD (item);
GalA11yETableClickToAdd *a11y;
GalA11yETableClickToAddPrivate *priv;
-
+
g_return_val_if_fail (item, TRUE);
g_return_val_if_fail (GAL_A11Y_IS_E_TABLE_CLICK_TO_ADD(data), FALSE);
diff --git a/a11y/e-table/gal-a11y-e-table-column-header.c b/a11y/e-table/gal-a11y-e-table-column-header.c
index 3303978a65..5f060e9cde 100644
--- a/a11y/e-table/gal-a11y-e-table-column-header.c
+++ b/a11y/e-table/gal-a11y-e-table-column-header.c
@@ -54,7 +54,7 @@ static void
gal_a11y_e_table_column_header_dispose (GObject *object)
{
GalA11yETableColumnHeader *a11y = GAL_A11Y_E_TABLE_COLUMN_HEADER (object);
- GalA11yETableColumnHeaderPrivate *priv = GET_PRIVATE (a11y);
+ GalA11yETableColumnHeaderPrivate *priv = GET_PRIVATE (a11y);
if (priv->state_set) {
g_object_unref (priv->state_set);
@@ -63,7 +63,7 @@ gal_a11y_e_table_column_header_dispose (GObject *object)
if (parent_class->dispose)
parent_class->dispose (object);
-
+
}
static void
@@ -108,7 +108,7 @@ gal_a11y_e_table_column_header_do_action (AtkAction *action,
}
else if (E_IS_TABLE (widget))
ethi = E_TABLE_HEADER_ITEM (E_TABLE (widget)->header_item);
- else
+ else
break;
ethi_change_sort_state (ethi, col);
default:
diff --git a/a11y/e-table/gal-a11y-e-table-factory.c b/a11y/e-table/gal-a11y-e-table-factory.c
index 8e207716ce..384dd40ed4 100644
--- a/a11y/e-table/gal-a11y-e-table-factory.c
+++ b/a11y/e-table/gal-a11y-e-table-factory.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Christopher James Lahey <clahey@ximian.com>
*
* Copyright (C) 2002 Ximian, Inc.
@@ -51,11 +51,11 @@ gal_a11y_e_table_factory_init (GalA11yETableFactory *factory)
/**
* gal_a11y_e_table_factory_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yETableFactory class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yETableFactory class.
**/
GType
diff --git a/a11y/e-table/gal-a11y-e-table-item-factory.c b/a11y/e-table/gal-a11y-e-table-item-factory.c
index 959de7e718..7841490e77 100644
--- a/a11y/e-table/gal-a11y-e-table-item-factory.c
+++ b/a11y/e-table/gal-a11y-e-table-item-factory.c
@@ -34,7 +34,7 @@ gal_a11y_e_table_item_factory_create_accessible (GObject *obj)
g_return_val_if_fail (E_IS_TABLE_ITEM(obj), NULL);
accessible = gal_a11y_e_table_item_new (E_TABLE_ITEM (obj));
-
+
return accessible;
}
@@ -56,11 +56,11 @@ gal_a11y_e_table_item_factory_init (GalA11yETableItemFactory *factory)
/**
* gal_a11y_e_table_factory_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yETableFactory class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yETableFactory class.
**/
GType
diff --git a/a11y/e-table/gal-a11y-e-table-item.c b/a11y/e-table/gal-a11y-e-table-item.c
index c11be59787..65c9b4ba22 100644
--- a/a11y/e-table/gal-a11y-e-table-item.c
+++ b/a11y/e-table/gal-a11y-e-table-item.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Christopher James Lahey <clahey@ximian.com>
* Bolian Yin <bolian.yin@sun.com>
*
@@ -176,7 +176,7 @@ eti_a11y_reset_focus_object (GalA11yETableItem *a11y, ETableItem *item, gboolean
} else
g_object_set_data (G_OBJECT (a11y), "gail-focus-object", NULL);
- if (notify && cell)
+ if (notify && cell)
atk_focus_tracker_notify (cell);
}
@@ -251,7 +251,7 @@ eti_get_extents (AtkComponent *component,
parent = ATK_OBJECT (component)->accessible_parent;
if (parent && ATK_IS_COMPONENT (parent))
- atk_component_get_extents (ATK_COMPONENT (parent), x, y,
+ atk_component_get_extents (ATK_COMPONENT (parent), x, y,
width, height,
coord_type);
@@ -313,7 +313,7 @@ cell_destroyed (gpointer data)
g_return_if_fail (cell->item && G_IS_OBJECT (cell->item));
if (cell->item) {
- g_object_unref (cell->item);
+ g_object_unref (cell->item);
cell->item = NULL;
}
@@ -354,7 +354,7 @@ eti_ref_at (AtkTable *table, gint row, gint column)
(GWeakNotify) cell_destroyed,
ret);
/* if current cell is focused, add FOCUSED state */
- if (e_selection_model_cursor_row (item->selection) == GAL_A11Y_E_CELL (ret)->row &&
+ if (e_selection_model_cursor_row (item->selection) == GAL_A11Y_E_CELL (ret)->row &&
e_selection_model_cursor_col (item->selection) == GAL_A11Y_E_CELL (ret)->model_col)
gal_a11y_e_cell_add_state (GAL_A11Y_E_CELL (ret), ATK_STATE_FOCUSED, FALSE);
} else
@@ -439,7 +439,7 @@ eti_get_column_extent_at (AtkTable *table,
return -1;
e_table_item_get_cell_geometry (item,
- &row,
+ &row,
&column,
NULL,
NULL,
@@ -462,7 +462,7 @@ eti_get_row_extent_at (AtkTable *table,
return -1;
e_table_item_get_cell_geometry (item,
- &row,
+ &row,
&column,
NULL,
NULL,
@@ -537,7 +537,7 @@ eti_get_summary (AtkTable *table)
return NULL;
}
-static gboolean
+static gboolean
table_is_row_selected (AtkTable *table, gint row)
{
ETableItem *item;
@@ -556,7 +556,7 @@ table_is_row_selected (AtkTable *table, gint row)
return e_selection_model_is_row_selected(item->selection, view_to_model_row (item, row));
}
-static gboolean
+static gboolean
table_is_selected (AtkTable *table, gint row, gint column)
{
return table_is_row_selected (table, row);
@@ -591,7 +591,7 @@ table_get_selected_rows (AtkTable *table, gint **rows_selected)
return n_selected;
}
-static gboolean
+static gboolean
table_add_row_selection (AtkTable *table, gint row)
{
ETableItem *item;
@@ -608,7 +608,7 @@ table_add_row_selection (AtkTable *table, gint row)
return TRUE;
}
-static gboolean
+static gboolean
table_remove_row_selection (AtkTable *table, gint row)
{
ETableItem *item;
@@ -662,7 +662,7 @@ eti_atk_component_iface_init (AtkComponentIface *iface)
}
static void
-eti_rows_inserted (ETableModel * model, int row, int count,
+eti_rows_inserted (ETableModel * model, int row, int count,
AtkObject * table_item)
{
gint n_cols,n_rows,i,j;
@@ -676,11 +676,11 @@ eti_rows_inserted (ETableModel * model, int row, int count,
n_rows = atk_table_get_n_rows (ATK_TABLE(table_item));
old_nrows = GET_PRIVATE(item_a11y)->rows;
-
+
g_return_if_fail (n_cols > 0 && n_rows > 0);
g_return_if_fail (old_nrows == n_rows - count);
- GET_PRIVATE(table_item)->rows = n_rows;
+ GET_PRIVATE(table_item)->rows = n_rows;
g_signal_emit_by_name (table_item, "row-inserted", row,
count, NULL);
@@ -697,12 +697,12 @@ eti_rows_inserted (ETableModel * model, int row, int count,
}
static void
-eti_rows_deleted (ETableModel * model, int row, int count,
+eti_rows_deleted (ETableModel * model, int row, int count,
AtkObject * table_item)
{
gint i,j, n_rows, n_cols, old_nrows;
ETableItem *item = E_TABLE_ITEM (atk_gobject_accessible_get_object (ATK_GOBJECT_ACCESSIBLE (table_item)));
-
+
n_rows = atk_table_get_n_rows (ATK_TABLE(table_item));
n_cols = atk_table_get_n_columns (ATK_TABLE(table_item));
@@ -748,7 +748,7 @@ enum {
ETI_HEADER_NEW_ADDED,
ETI_HEADER_REMOVED,
};
-
+
/*
* 1. Check what actually happened: column reorder, remove or add
* 2. Update cache
@@ -757,17 +757,17 @@ enum {
static void
eti_header_structure_changed (ETableHeader *eth, AtkObject *a11y)
{
-
+
gboolean reorder_found=FALSE, added_found=FALSE, removed_found=FALSE;
GalA11yETableItem * a11y_item;
ETableCol ** cols, **prev_cols;
GalA11yETableItemPrivate *priv;
gint *state = NULL, *prev_state = NULL, *reorder = NULL;
gint i,j,n_rows,n_cols, prev_n_cols;
-
+
a11y_item = GAL_A11Y_E_TABLE_ITEM (a11y);
priv = GET_PRIVATE (a11y_item);
-
+
/* Assume rows do not changed. */
n_rows = priv->rows;
@@ -776,9 +776,9 @@ eti_header_structure_changed (ETableHeader *eth, AtkObject *a11y)
cols = e_table_header_get_columns (eth);
n_cols = eth->col_count;
-
+
g_return_if_fail (cols && prev_cols && n_cols > 0);
-
+
/* Init to ETI_HEADER_UNCHANGED. */
state = g_malloc0 (sizeof (gint) * n_cols);
prev_state = g_malloc0 (sizeof (gint) * prev_n_cols);
@@ -799,7 +799,7 @@ eti_header_structure_changed (ETableHeader *eth, AtkObject *a11y)
break;
}
}
-
+
/* cols[i] is new added column. */
if ( j == prev_n_cols ) {
added_found = TRUE;
@@ -812,7 +812,7 @@ eti_header_structure_changed (ETableHeader *eth, AtkObject *a11y)
for (j = 0 ; j < n_cols && cols[j]; j ++)
if ( prev_cols [j] == cols[i] )
break;
-
+
/* Removed columns found. */
if ( j == n_cols ) {
removed_found = TRUE;
@@ -861,7 +861,7 @@ eti_header_structure_changed (ETableHeader *eth, AtkObject *a11y)
static void
-eti_real_initialize (AtkObject *obj,
+eti_real_initialize (AtkObject *obj,
gpointer data)
{
ETableItem * eti;
@@ -940,11 +940,11 @@ static void eti_a11y_cursor_changed_cb (ESelectionModel *selection,
/**
* gal_a11y_e_table_item_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yETableItem class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yETableItem class.
**/
GType
@@ -1029,7 +1029,7 @@ gal_a11y_e_table_item_new (ETableItem *item)
GET_PRIVATE (a11y)->cols = item->cols;
GET_PRIVATE (a11y)->rows = item->rows;
- GET_PRIVATE (a11y)->columns = e_table_header_get_columns (item->header);
+ GET_PRIVATE (a11y)->columns = e_table_header_get_columns (item->header);
if ( GET_PRIVATE (a11y)->columns == NULL)
return NULL;
@@ -1058,7 +1058,7 @@ gal_a11y_e_table_item_new (ETableItem *item)
accessible->role = ATK_ROLE_TREE_TABLE;
} else if (E_IS_TABLE (GET_PRIVATE (a11y)->widget)) {
accessible->role = ATK_ROLE_TABLE;
- }
+ }
}
if (item)
@@ -1181,7 +1181,7 @@ eti_a11y_cursor_changed_cb (ESelectionModel *selection,
g_return_if_fail (GAL_A11Y_IS_E_TABLE_ITEM (a11y));
- if (atk_state_set_contains_state (priv->state_set, ATK_STATE_DEFUNCT))
+ if (atk_state_set_contains_state (priv->state_set, ATK_STATE_DEFUNCT))
return;
item = E_TABLE_ITEM (eti_a11y_get_gobject (ATK_OBJECT (a11y)));
diff --git a/a11y/e-table/gal-a11y-e-table.c b/a11y/e-table/gal-a11y-e-table.c
index 56cfdbd2f0..056b95775f 100644
--- a/a11y/e-table/gal-a11y-e-table.c
+++ b/a11y/e-table/gal-a11y-e-table.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Christopher James Lahey <clahey@ximian.com>
*
* Copyright (C) 2002 Ximian, Inc.
@@ -67,7 +67,7 @@ eti_get_accessible (ETableItem *eti, AtkObject *parent)
return a11y;
}
-static gboolean
+static gboolean
init_child_item (GalA11yETable *a11y)
{
ETable *table;
@@ -123,7 +123,7 @@ et_get_n_children (AtkObject *accessible)
n = g_list_length (etgc->children);
}
}
-
+
if (et && et->use_click_to_add && et->click_to_add) {
n++;
}
@@ -212,11 +212,11 @@ et_init (GalA11yETable *a11y)
/**
* gal_a11y_e_table_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yETable class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yETable class.
**/
GType
@@ -282,7 +282,7 @@ gal_a11y_e_table_new (GObject *widget)
return ATK_OBJECT (a11y);
}
-void
+void
gal_a11y_e_table_init (void)
{
if (atk_get_root ())
diff --git a/a11y/e-table/gal-a11y-e-tree-factory.c b/a11y/e-table/gal-a11y-e-tree-factory.c
index d5c7f80669..031220d46a 100644
--- a/a11y/e-table/gal-a11y-e-tree-factory.c
+++ b/a11y/e-table/gal-a11y-e-tree-factory.c
@@ -49,11 +49,11 @@ gal_a11y_e_tree_factory_init (GalA11yETreeFactory *factory)
/**
* gal_a11y_e_tree_factory_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yETreeFactory class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yETreeFactory class.
**/
GType
diff --git a/a11y/e-table/gal-a11y-e-tree.c b/a11y/e-table/gal-a11y-e-tree.c
index 6ad507a4f3..72738ec011 100644
--- a/a11y/e-table/gal-a11y-e-tree.c
+++ b/a11y/e-table/gal-a11y-e-tree.c
@@ -106,11 +106,11 @@ et_init (GalA11yETree *a11y)
/**
* gal_a11y_e_tree_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yETree class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yETree class.
**/
GType
diff --git a/a11y/e-text/gal-a11y-e-text-factory.c b/a11y/e-text/gal-a11y-e-text-factory.c
index 732bc57af4..e124e6eb72 100644
--- a/a11y/e-text/gal-a11y-e-text-factory.c
+++ b/a11y/e-text/gal-a11y-e-text-factory.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Christopher James Lahey <clahey@ximian.com>
*
* Copyright (C) 2002 Ximian, Inc.
@@ -54,11 +54,11 @@ gal_a11y_e_text_factory_init (GalA11yETextFactory *factory)
/**
* gal_a11y_e_text_factory_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yETextFactory class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yETextFactory class.
**/
GType
diff --git a/a11y/e-text/gal-a11y-e-text.c b/a11y/e-text/gal-a11y-e-text.c
index f1a06b73dc..91628572e2 100644
--- a/a11y/e-text/gal-a11y-e-text.c
+++ b/a11y/e-text/gal-a11y-e-text.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Christopher James Lahey <clahey@ximian.com>
*
* Copyright (C) 2002 Ximian, Inc.
@@ -71,7 +71,7 @@ et_get_extents (AtkComponent *component,
if (width)
*width = real_width;
- if (height)
+ if (height)
*height = real_height;
}
@@ -195,7 +195,7 @@ find_sentence_start (const char *text,
char *at_offset;
gunichar ch;
int i;
-
+
offset = find_word_start (text, begin_offset, step);
len = g_utf8_strlen (text, -1);
@@ -645,7 +645,7 @@ et_get_offset_at_point (AtkText *text,
}
-static gint
+static gint
et_get_n_selections (AtkText *text)
{
EText *etext = E_TEXT (atk_gobject_accessible_get_object (ATK_GOBJECT_ACCESSIBLE (text)));
@@ -742,7 +742,7 @@ et_remove_selection (AtkText *text,
g_return_val_if_fail (E_IS_TEXT (obj), FALSE);
etext = E_TEXT (obj);
- if (selection_num == 0
+ if (selection_num == 0
&& etext->selection_start != etext->selection_end) {
etext->selection_end = etext->selection_start;
g_signal_emit_by_name (ATK_OBJECT(text), "text_selection_changed");
@@ -786,7 +786,7 @@ et_set_caret_offset (AtkText *text,
g_return_val_if_fail (E_IS_TEXT (obj), FALSE);
etext = E_TEXT (obj);
-
+
if (offset < -1)
return FALSE;
else {
@@ -1021,7 +1021,7 @@ et_real_initialize (AtkObject *obj,
if (etext->tep)
g_signal_connect_after (etext->tep, "command",
(GCallback) _et_command_cb, obj);
-
+
obj->role = ATK_ROLE_TEXT;
}
@@ -1050,11 +1050,11 @@ et_init (GalA11yEText *a11y)
/**
* gal_a11y_e_text_get_type:
- * @void:
- *
+ * @void:
+ *
* Registers the &GalA11yEText class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the &GalA11yEText class.
**/
GType
diff --git a/a11y/ea-factory.h b/a11y/ea-factory.h
index 3ce14976fe..eff20f7f45 100644
--- a/a11y/ea-factory.h
+++ b/a11y/ea-factory.h
@@ -16,7 +16,7 @@
*
* You should have received a copy of the GNU General Public
* License along with this program; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin Street, Fifth
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth
* Floor, Boston, MA 02110-1301, USA.
*
* Author: Bolian Yin <bolian.yin@sun.com> Sun Microsystem Inc., 2003
diff --git a/a11y/gal-a11y-factory.h b/a11y/gal-a11y-factory.h
index 6cbfa99aaf..744af71173 100644
--- a/a11y/gal-a11y-factory.h
+++ b/a11y/gal-a11y-factory.h
@@ -22,7 +22,7 @@
* Authors:
* Gilbert Fang <gilbert.fang@sun.com>, Sun Microsystem Inc. 2003.
*
- * This file is mainly from the gailfactory.h of GAIL.
+ * This file is mainly from the gailfactory.h of GAIL.
*/
#ifndef _GAL_A11Y_FACTORY_H__
diff --git a/a11y/gal-a11y-util.c b/a11y/gal-a11y-util.c
index 29a9dbc37d..0d35653445 100644
--- a/a11y/gal-a11y-util.c
+++ b/a11y/gal-a11y-util.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
- * Authors:
+ * Authors:
* Christopher James Lahey <clahey@ximian.com>
*
* Copyright (C) 2002 Ximian, Inc.
diff --git a/a11y/widgets/ea-calendar-cell.c b/a11y/widgets/ea-calendar-cell.c
index 0ec6f6ce8b..30a06ef426 100644
--- a/a11y/widgets/ea-calendar-cell.c
+++ b/a11y/widgets/ea-calendar-cell.c
@@ -180,7 +180,7 @@ ea_calendar_cell_init (EaCalendarCell *a11y)
atk_state_set_add_state (a11y->state_set, ATK_STATE_FOCUSABLE);
}
-AtkObject*
+AtkObject*
ea_calendar_cell_new (GObject *obj)
{
gpointer object;
@@ -298,12 +298,12 @@ ea_calendar_cell_ref_state_set (AtkObject *accessible)
g_object_ref(atk_cell->state_set);
return atk_cell->state_set;
-
+
}
/* Atk Component Interface */
-static void
+static void
atk_component_interface_init (AtkComponentIface *iface)
{
g_return_if_fail (iface != NULL);
@@ -312,7 +312,7 @@ atk_component_interface_init (AtkComponentIface *iface)
iface->grab_focus = component_interface_grab_focus;
}
-static void
+static void
component_interface_get_extents (AtkComponent *component,
gint *x, gint *y, gint *width, gint *height,
AtkCoordType coord_type)
@@ -375,10 +375,10 @@ component_interface_grab_focus (AtkComponent *component)
calitem = E_CALENDAR_ITEM (g_obj);
index = atk_object_get_index_in_parent (ATK_OBJECT (a11y));
-
+
atk_selection_clear_selection (ATK_SELECTION (ea_calitem));
atk_selection_add_selection (ATK_SELECTION (ea_calitem), index);
-
+
gtk_widget_grab_focus (GTK_WIDGET (GNOME_CANVAS_ITEM (calitem)->canvas));
toplevel = gtk_widget_get_toplevel (GTK_WIDGET (GNOME_CANVAS_ITEM (calitem)->canvas));
if (toplevel && GTK_WIDGET_TOPLEVEL (toplevel))
diff --git a/a11y/widgets/ea-calendar-item.c b/a11y/widgets/ea-calendar-item.c
index 9def176376..585eba796d 100644
--- a/a11y/widgets/ea-calendar-item.c
+++ b/a11y/widgets/ea-calendar-item.c
@@ -57,7 +57,7 @@ static gint table_interface_get_column_at_index (AtkTable *table,
static gint table_interface_get_row_at_index (AtkTable *table,
gint index);
static AtkObject* table_interface_ref_at (AtkTable *table,
- gint row,
+ gint row,
gint column);
static gint table_interface_get_n_rows (AtkTable *table);
static gint table_interface_get_n_columns (AtkTable *table);
@@ -128,7 +128,7 @@ static gboolean ea_calendar_item_get_row_label (EaCalendarItem *ea_calitem,
static gboolean e_calendar_item_get_offset_for_date (ECalendarItem *calitem,
gint year, gint month, gint day,
gint *offset);
-static void ea_calendar_set_focus_object (EaCalendarItem *ea_calitem,
+static void ea_calendar_set_focus_object (EaCalendarItem *ea_calitem,
AtkObject *item_cell);
#ifdef ACC_DEBUG
@@ -212,7 +212,7 @@ ea_calendar_item_class_init (EaCalendarItemClass *klass)
class->ref_child = ea_calendar_item_ref_child;
}
-AtkObject*
+AtkObject*
ea_calendar_item_new (GObject *obj)
{
gpointer object;
@@ -303,7 +303,7 @@ ea_calendar_item_get_name (AtkObject *accessible)
day_end.tm_isdst = -1;
e_utf8_strftime (buffer_end, sizeof (buffer_end), _("%d %B %Y"), &day_end);
- name_str = g_strdup_printf (_("Calendar: from %s to %s"), buffer_start, buffer_end);
+ name_str = g_strdup_printf (_("Calendar: from %s to %s"), buffer_start, buffer_end);
}
#if 0
@@ -354,7 +354,7 @@ ea_calendar_item_ref_state_set (AtkObject *accessible)
atk_state_set_add_state (state_set, ATK_STATE_ENABLED);
atk_state_set_add_state (state_set, ATK_STATE_SENSITIVE);
-
+
return state_set;
}
@@ -439,7 +439,7 @@ ea_calendar_item_ref_child (AtkObject *accessible, gint index)
/* atk table interface */
-static void
+static void
atk_table_interface_init (AtkTableIface *iface)
{
g_return_if_fail (iface != NULL);
@@ -472,9 +472,9 @@ atk_table_interface_init (AtkTableIface *iface)
iface->get_column_description = table_interface_get_column_description;
}
-static AtkObject*
+static AtkObject*
table_interface_ref_at (AtkTable *table,
- gint row,
+ gint row,
gint column)
{
gint index;
@@ -484,7 +484,7 @@ table_interface_ref_at (AtkTable *table,
return ea_calendar_item_ref_child (ATK_OBJECT (ea_calitem), index);
}
-static gint
+static gint
table_interface_get_n_rows (AtkTable *table)
{
AtkGObjectAccessible *atk_gobj;
@@ -501,7 +501,7 @@ table_interface_get_n_rows (AtkTable *table)
return (n_children - 1) / EA_CALENDAR_COLUMN_NUM + 1;
}
-static gint
+static gint
table_interface_get_n_columns (AtkTable *table)
{
AtkGObjectAccessible *atk_gobj;
@@ -592,7 +592,7 @@ table_interface_get_column_extent_at (AtkTable *table,
return calitem->cell_width;
}
-static gint
+static gint
table_interface_get_row_extent_at (AtkTable *table,
gint row, gint column)
{
@@ -611,7 +611,7 @@ table_interface_get_row_extent_at (AtkTable *table,
}
/* any day in the row is selected, the row is selected */
-static gboolean
+static gboolean
table_interface_is_row_selected (AtkTable *table,
gint row)
{
@@ -661,9 +661,9 @@ table_interface_is_row_selected (AtkTable *table,
return FALSE;
}
-static gboolean
-table_interface_is_selected (AtkTable *table,
- gint row,
+static gboolean
+table_interface_is_selected (AtkTable *table,
+ gint row,
gint column)
{
AtkGObjectAccessible *atk_gobj;
@@ -710,14 +710,14 @@ table_interface_is_selected (AtkTable *table,
return FALSE;
}
-static gboolean
+static gboolean
table_interface_is_column_selected (AtkTable *table,
gint column)
{
return FALSE;
}
-static gint
+static gint
table_interface_get_selected_rows (AtkTable *table,
gint **rows_selected)
{
@@ -725,7 +725,7 @@ table_interface_get_selected_rows (AtkTable *table,
return -1;
}
-static gint
+static gint
table_interface_get_selected_columns (AtkTable *table,
gint **columns_selected)
{
@@ -733,45 +733,45 @@ table_interface_get_selected_columns (AtkTable *table,
return -1;
}
-static gboolean
-table_interface_add_row_selection (AtkTable *table,
+static gboolean
+table_interface_add_row_selection (AtkTable *table,
gint row)
{
return FALSE;
}
-static gboolean
-table_interface_remove_row_selection (AtkTable *table,
+static gboolean
+table_interface_remove_row_selection (AtkTable *table,
gint row)
{
return FALSE;
}
-static gboolean
-table_interface_add_column_selection (AtkTable *table,
+static gboolean
+table_interface_add_column_selection (AtkTable *table,
gint column)
{
return FALSE;
}
-static gboolean
-table_interface_remove_column_selection (AtkTable *table,
+static gboolean
+table_interface_remove_column_selection (AtkTable *table,
gint column)
{
/* FIXME: NOT IMPLEMENTED */
return FALSE;
}
-static AtkObject*
-table_interface_get_row_header (AtkTable *table,
+static AtkObject*
+table_interface_get_row_header (AtkTable *table,
gint row)
{
/* FIXME: NOT IMPLEMENTED */
return NULL;
}
-static AtkObject*
-table_interface_get_column_header (AtkTable *table,
+static AtkObject*
+table_interface_get_column_header (AtkTable *table,
gint in_col)
{
/* FIXME: NOT IMPLEMENTED */
@@ -920,7 +920,7 @@ selection_interface_clear_selection (AtkSelection *selection)
return TRUE;
}
-static AtkObject*
+static AtkObject*
selection_interface_ref_selection (AtkSelection *selection, gint i)
{
GObject *g_obj;
diff --git a/a11y/widgets/ea-combo-button.c b/a11y/widgets/ea-combo-button.c
index aad60c3023..8a90700f41 100644
--- a/a11y/widgets/ea-combo-button.c
+++ b/a11y/widgets/ea-combo-button.c
@@ -16,7 +16,7 @@ static GType parent_type;
/*Action IDs */
enum {
ACTIVATE_DEFAULT,
- POPUP_MENU,
+ POPUP_MENU,
LAST_ACTION
};
@@ -89,7 +89,7 @@ ea_combo_button_get_n_actions (AtkAction *action)
static void
atk_action_interface_init (AtkActionIface *iface)
{
- g_return_if_fail (iface != NULL);
+ g_return_if_fail (iface != NULL);
iface->do_action = ea_combo_button_do_action;
iface->get_n_actions = ea_combo_button_get_n_actions;
diff --git a/a11y/widgets/ea-expander.c b/a11y/widgets/ea-expander.c
index ebf0b67d1f..db174c37cb 100644
--- a/a11y/widgets/ea-expander.c
+++ b/a11y/widgets/ea-expander.c
@@ -134,7 +134,7 @@ ea_expander_get_type (void)
(GInterfaceFinalizeFunc) NULL,
NULL
};
-
+
factory = atk_registry_get_factory (atk_get_default_registry (), GTK_TYPE_BIN);
parent_type = atk_object_factory_get_accessible_type (factory);
g_type_query (parent_type, &query);
diff --git a/addressbook/conduit/address-conduit.c b/addressbook/conduit/address-conduit.c
index f430696999..24fe81d644 100644
--- a/addressbook/conduit/address-conduit.c
+++ b/addressbook/conduit/address-conduit.c
@@ -4,7 +4,7 @@
* Copyright (C) 1998 Free Software Foundation
* Copyright (C) 2000 Ximian, Inc.
*
- * Authors: Eskil Heyn Olsen <deity@eskil.dk>
+ * Authors: Eskil Heyn Olsen <deity@eskil.dk>
* JP Rosevear <jpr@ximian.com>
*
* This program is free software; you can redistribute it and/or
@@ -58,7 +58,7 @@ void conduit_destroy_gpilot_conduit (GnomePilotConduit*);
#define LOG(x) x
#else
#define LOG(x)
-#endif
+#endif
#define WARN g_warning
#define INFO g_message
@@ -132,7 +132,7 @@ struct _EAddrLocalRecord {
static void
-addrconduit_destroy_record (EAddrLocalRecord *local)
+addrconduit_destroy_record (EAddrLocalRecord *local)
{
g_object_unref (local->contact);
free_Address (local->addr);
@@ -154,7 +154,7 @@ struct _EAddrConduitCfg {
};
static EAddrConduitCfg *
-addrconduit_load_configuration (guint32 pilot_id)
+addrconduit_load_configuration (guint32 pilot_id)
{
EAddrConduitCfg *c;
GnomePilotConduitManagement *management;
@@ -162,7 +162,7 @@ addrconduit_load_configuration (guint32 pilot_id)
gchar *address, prefix[256];
g_snprintf (prefix, 255, "/gnome-pilot.d/e-address-conduit/Pilot_%u/",
pilot_id);
-
+
c = g_new0 (EAddrConduitCfg,1);
g_assert (c != NULL);
@@ -192,7 +192,7 @@ addrconduit_load_configuration (guint32 pilot_id)
c->source_list = NULL;
}
}
-
+
c->secret = gnome_config_get_bool ("secret=FALSE");
address = gnome_config_get_string ("default_address=business");
if (!strcmp (address, "business"))
@@ -210,7 +210,7 @@ addrconduit_load_configuration (guint32 pilot_id)
}
static void
-addrconduit_save_configuration (EAddrConduitCfg *c)
+addrconduit_save_configuration (EAddrConduitCfg *c)
{
gchar prefix[256];
@@ -241,7 +241,7 @@ addrconduit_save_configuration (EAddrConduitCfg *c)
}
static EAddrConduitCfg*
-addrconduit_dupe_configuration (EAddrConduitCfg *c)
+addrconduit_dupe_configuration (EAddrConduitCfg *c)
{
EAddrConduitCfg *retval;
@@ -251,7 +251,7 @@ addrconduit_dupe_configuration (EAddrConduitCfg *c)
retval->sync_type = c->sync_type;
retval->pilot_id = c->pilot_id;
- if (c->source_list)
+ if (c->source_list)
retval->source_list = g_object_ref (c->source_list);
if (c->source)
retval->source = g_object_ref (c->source);
@@ -262,8 +262,8 @@ addrconduit_dupe_configuration (EAddrConduitCfg *c)
return retval;
}
-static void
-addrconduit_destroy_configuration (EAddrConduitCfg *c)
+static void
+addrconduit_destroy_configuration (EAddrConduitCfg *c)
{
g_return_if_fail (c != NULL);
@@ -279,17 +279,17 @@ struct _EAddrConduitGui {
};
static EAddrConduitGui *
-e_addr_gui_new (EPilotSettings *ps)
+e_addr_gui_new (EPilotSettings *ps)
{
EAddrConduitGui *gui;
GtkWidget *lbl, *menu;
gint rows, i;
static const char *items[] = {"Business", "Home", "Other", NULL};
-
+
g_return_val_if_fail (ps != NULL, NULL);
g_return_val_if_fail (E_IS_PILOT_SETTINGS (ps), NULL);
- gtk_table_resize (GTK_TABLE (ps), E_PILOT_SETTINGS_TABLE_ROWS + 1,
+ gtk_table_resize (GTK_TABLE (ps), E_PILOT_SETTINGS_TABLE_ROWS + 1,
E_PILOT_SETTINGS_TABLE_COLS);
gui = g_new0 (EAddrConduitGui, 1);
@@ -304,7 +304,7 @@ e_addr_gui_new (EPilotSettings *ps)
item = gtk_menu_item_new_with_label (items[i]);
gtk_widget_show (item);
-
+
gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
}
gtk_widget_show (menu);
@@ -313,7 +313,7 @@ e_addr_gui_new (EPilotSettings *ps)
gtk_table_attach_defaults (GTK_TABLE (ps), gui->default_address, 1, 2, rows, rows + 1);
gtk_widget_show (lbl);
gtk_widget_show (gui->default_address);
-
+
return gui;
}
@@ -325,28 +325,28 @@ static const int default_address_map[] = {
};
static void
-e_addr_gui_fill_widgets (EAddrConduitGui *gui, EAddrConduitCfg *cfg)
+e_addr_gui_fill_widgets (EAddrConduitGui *gui, EAddrConduitCfg *cfg)
{
g_return_if_fail (gui != NULL);
g_return_if_fail (cfg != NULL);
- e_dialog_option_menu_set (gui->default_address,
- cfg->default_address,
+ e_dialog_option_menu_set (gui->default_address,
+ cfg->default_address,
default_address_map);
}
static void
-e_addr_gui_fill_config (EAddrConduitGui *gui, EAddrConduitCfg *cfg)
+e_addr_gui_fill_config (EAddrConduitGui *gui, EAddrConduitCfg *cfg)
{
g_return_if_fail (gui != NULL);
g_return_if_fail (cfg != NULL);
- cfg->default_address = e_dialog_option_menu_get (gui->default_address,
+ cfg->default_address = e_dialog_option_menu_get (gui->default_address,
default_address_map);
}
static void
-e_addr_gui_destroy (EAddrConduitGui *gui)
+e_addr_gui_destroy (EAddrConduitGui *gui)
{
g_free (gui);
}
@@ -359,7 +359,7 @@ struct _EAddrConduitContext {
EAddrConduitCfg *new_cfg;
EAddrConduitGui *gui;
GtkWidget *ps;
-
+
struct AddressAppInfo ai;
EBook *ebook;
@@ -372,7 +372,7 @@ struct _EAddrConduitContext {
};
static EAddrConduitContext *
-e_addr_context_new (guint32 pilot_id)
+e_addr_context_new (guint32 pilot_id)
{
EAddrConduitContext *ctxt = g_new0 (EAddrConduitContext, 1);
@@ -394,7 +394,7 @@ static void
e_addr_context_destroy (EAddrConduitContext *ctxt)
{
GList *l;
-
+
g_return_if_fail (ctxt != NULL);
if (ctxt->cfg != NULL)
@@ -403,7 +403,7 @@ e_addr_context_destroy (EAddrConduitContext *ctxt)
addrconduit_destroy_configuration (ctxt->new_cfg);
if (ctxt->gui != NULL)
e_addr_gui_destroy (ctxt->gui);
-
+
if (ctxt->ebook != NULL)
g_object_unref (ctxt->ebook);
@@ -412,13 +412,13 @@ e_addr_context_destroy (EAddrConduitContext *ctxt)
g_object_unref (l->data);
g_list_free (ctxt->cards);
}
-
+
if (ctxt->changed_hash != NULL)
g_hash_table_destroy (ctxt->changed_hash);
-
+
if (ctxt->changed != NULL)
e_book_free_change_list (ctxt->changed);
-
+
if (ctxt->locals != NULL) {
for (l = ctxt->locals; l != NULL; l = l->next)
addrconduit_destroy_record (l->data);
@@ -501,28 +501,28 @@ static char *print_remote (GnomePilotRecord *remote)
/* Utility routines */
static char *
-map_name (EAddrConduitContext *ctxt)
+map_name (EAddrConduitContext *ctxt)
{
char *filename = NULL;
-
+
filename = g_strdup_printf ("%s/.evolution/addressbook/local/system/pilot-map-%d.xml", g_get_home_dir (), ctxt->cfg->pilot_id);
-
+
return filename;
}
static GList *
-next_changed_item (EAddrConduitContext *ctxt, GList *changes)
+next_changed_item (EAddrConduitContext *ctxt, GList *changes)
{
EBookChange *ebc;
GList *l;
-
- for (l = changes; l != NULL; l = l->next) {
+
+ for (l = changes; l != NULL; l = l->next) {
ebc = l->data;
-
+
if (g_hash_table_lookup (ctxt->changed_hash, e_contact_get_const (ebc->contact, E_CONTACT_UID)))
return l;
}
-
+
return NULL;
}
@@ -531,7 +531,7 @@ get_next_mail (EContactField *field)
{
if (field == NULL)
return E_CONTACT_EMAIL_1;
-
+
switch (*field) {
case E_CONTACT_EMAIL_1:
return E_CONTACT_EMAIL_2;
@@ -549,7 +549,7 @@ get_next_home (EContactField *field)
{
if (field == NULL)
return E_CONTACT_PHONE_HOME;
-
+
switch (*field) {
case E_CONTACT_PHONE_HOME:
return E_CONTACT_PHONE_HOME_2;
@@ -565,7 +565,7 @@ get_next_work (EContactField *field)
{
if (field == NULL)
return E_CONTACT_PHONE_BUSINESS;
-
+
switch (*field) {
case E_CONTACT_PHONE_BUSINESS:
return E_CONTACT_PHONE_BUSINESS_2;
@@ -581,7 +581,7 @@ get_next_fax (EContactField *field)
{
if (field == NULL)
return E_CONTACT_PHONE_BUSINESS_FAX;
-
+
switch (*field) {
case E_CONTACT_PHONE_BUSINESS_FAX:
return E_CONTACT_PHONE_HOME_FAX;
@@ -639,7 +639,7 @@ get_next_init (EContactField *next_mail,
EContactField *next_main,
EContactField *next_pager,
EContactField *next_mobile)
-{
+{
*next_mail = get_next_mail (NULL);
*next_home = get_next_home (NULL);
*next_work = get_next_work (NULL);
@@ -655,13 +655,13 @@ is_next_done (EContactField field)
{
if (field == E_CONTACT_FIELD_LAST)
return TRUE;
-
+
return FALSE;
}
static gboolean
-is_syncable (EAddrConduitContext *ctxt, EAddrLocalRecord *local)
-{
+is_syncable (EAddrConduitContext *ctxt, EAddrLocalRecord *local)
+{
EContactField next_mail, next_home, next_work, next_fax;
EContactField next_other, next_main, next_pager, next_mobile;
gboolean syncable = TRUE;
@@ -670,15 +670,15 @@ is_syncable (EAddrConduitContext *ctxt, EAddrLocalRecord *local)
/* See if there are fields we can't sync or not in priority order */
get_next_init (&next_mail, &next_home, &next_work, &next_fax,
&next_other, &next_main, &next_pager, &next_mobile);
-
+
for (i = entryPhone1; i <= entryPhone5 && syncable; i++) {
int phonelabel = local->addr->phoneLabel[i - entryPhone1];
const char *phone_str = local->addr->entry[i];
gboolean empty = !(phone_str && *phone_str);
-
+
if (empty)
continue;
-
+
for ( ; priority_label[l] != -1; l++)
if (phonelabel == priority_label[l])
break;
@@ -687,7 +687,7 @@ is_syncable (EAddrConduitContext *ctxt, EAddrLocalRecord *local)
syncable = FALSE;
continue;
}
-
+
if (phonelabel == LABEL_EMAIL) {
if (is_next_done (next_mail) || next_mail != priority[l]) {
syncable = FALSE;
@@ -746,12 +746,12 @@ static void
set_contact_text (EContact *contact, EContactField field, struct Address address, int entry)
{
char *text = NULL;
-
+
if (address.entry[entry])
text = e_pilot_utf8_from_pchar (address.entry[entry]);
e_contact_set (contact, field, text);
-
+
g_free (text);
}
@@ -761,11 +761,11 @@ get_entry_text (struct Address address, int entry)
if (address.entry[entry])
return e_pilot_utf8_from_pchar (address.entry[entry]);
- return NULL;
+ return NULL;
}
static void
-clear_entry_text (struct Address address, int field)
+clear_entry_text (struct Address address, int field)
{
if (address.entry[field]) {
free (address.entry[field]);
@@ -782,16 +782,16 @@ compute_status (EAddrConduitContext *ctxt, EAddrLocalRecord *local, const char *
local->local.secret = FALSE;
ebc = g_hash_table_lookup (ctxt->changed_hash, uid);
-
+
if (ebc == NULL) {
local->local.attr = GnomePilotRecordNothing;
return;
}
-
+
switch (ebc->change_type) {
case E_BOOK_CHANGE_CARD_ADDED:
local->local.attr = GnomePilotRecordNew;
- break;
+ break;
case E_BOOK_CHANGE_CARD_MODIFIED:
local->local.attr = GnomePilotRecordModified;
break;
@@ -811,9 +811,9 @@ local_record_to_pilot_record (EAddrLocalRecord *local,
#else
static char record[0xffff];
#endif
-
+
g_assert (local->addr != NULL );
-
+
LOG (g_message ( "local_record_to_pilot_record\n" ));
memset (&p, 0, sizeof (GnomePilotRecord));
@@ -844,7 +844,7 @@ local_record_to_pilot_record (EAddrLocalRecord *local,
p.record = (unsigned char *)record;
p.length = pack_Address (local->addr, p.record, 0xffff);
#endif
- return p;
+ return p;
}
static void
@@ -855,7 +855,7 @@ local_record_from_ecard (EAddrLocalRecord *local, EContact *contact, EAddrCondui
EContactField field;
gboolean syncable;
int i;
-
+
g_return_if_fail (local != NULL);
g_return_if_fail (contact != NULL);
@@ -867,7 +867,7 @@ local_record_from_ecard (EAddrLocalRecord *local, EContact *contact, EAddrCondui
local->addr = g_new0 (struct Address, 1);
/* Handle the fields and category we don't sync by making sure
- * we don't overwrite them
+ * we don't overwrite them
*/
if (local->local.ID != 0) {
struct Address addr;
@@ -882,14 +882,14 @@ local_record_from_ecard (EAddrLocalRecord *local, EContact *contact, EAddrCondui
#else
char record[0xffff];
#endif
-
- if (dlp_ReadRecordById (ctxt->dbi->pilot_socket,
+
+ if (dlp_ReadRecordById (ctxt->dbi->pilot_socket,
ctxt->dbi->db_handle,
#ifdef PILOT_LINK_0_12
- local->local.ID, record,
+ local->local.ID, record,
NULL, NULL, &cat) > 0) {
#else
- local->local.ID, &record,
+ local->local.ID, &record,
NULL, NULL, NULL, &cat) > 0) {
#endif
local->local.category = cat;
@@ -901,14 +901,14 @@ local_record_from_ecard (EAddrLocalRecord *local, EContact *contact, EAddrCondui
#endif
for (i = 0; i < 5; i++) {
if (addr.entry[entryPhone1 + i])
- local->addr->entry[entryPhone1 + i] =
+ local->addr->entry[entryPhone1 + i] =
strdup (addr.entry[entryPhone1 + i]);
local->addr->phoneLabel[i] = addr.phoneLabel[i];
}
local->addr->showPhone = addr.showPhone;
for (i = 0; i < 4; i++) {
if (addr.entry[entryCustom1 + i])
- local->addr->entry[entryCustom1 + i] =
+ local->addr->entry[entryCustom1 + i] =
strdup (addr.entry[entryCustom1 + i]);
}
free_Address (&addr);
@@ -922,7 +922,7 @@ local_record_from_ecard (EAddrLocalRecord *local, EContact *contact, EAddrCondui
local->addr->entry[entryLastname] = e_pilot_utf8_to_pchar (e_contact_get_const (contact, E_CONTACT_FAMILY_NAME));
local->addr->entry[entryCompany] = e_pilot_utf8_to_pchar (e_contact_get_const (contact, E_CONTACT_ORG));
local->addr->entry[entryTitle] = e_pilot_utf8_to_pchar (e_contact_get_const (contact, E_CONTACT_TITLE));
-
+
/* See if the default has something in it */
if ((address = e_contact_get (contact, ctxt->cfg->default_address))) {
field = ctxt->cfg->default_address;
@@ -933,12 +933,12 @@ local_record_from_ecard (EAddrLocalRecord *local, EContact *contact, EAddrCondui
break;
}
}
-
+
if (address) {
char *add;
-
+
/* If the address has 2 lines, make sure both get added */
- if (address->ext != NULL &&
+ if (address->ext != NULL &&
strlen (address->ext) > 0) {
add = g_strconcat (address->street, "\n", address->ext, NULL);
LOG (g_warning ("Address has two lines: [%s]\n", add));
@@ -949,28 +949,28 @@ local_record_from_ecard (EAddrLocalRecord *local, EContact *contact, EAddrCondui
}
local->addr->entry[entryAddress] = e_pilot_utf8_to_pchar (add);
g_free (add);
-
+
local->addr->entry[entryCity] = e_pilot_utf8_to_pchar (address->locality);
local->addr->entry[entryState] = e_pilot_utf8_to_pchar (address->region);
local->addr->entry[entryZip] = e_pilot_utf8_to_pchar (address->code);
local->addr->entry[entryCountry] = e_pilot_utf8_to_pchar (address->country);
-
+
e_contact_address_free (address);
}
-
+
/* Phone numbers */
/* See if everything is syncable */
syncable = is_syncable (ctxt, local);
-
+
if (syncable) {
INFO ("Syncable");
/* Sync by priority */
- for (i = 0, phone = entryPhone1;
+ for (i = 0, phone = entryPhone1;
priority[i] != E_CONTACT_FIELD_LAST && phone <= entryPhone5; i++) {
const char *phone_str;
-
+
phone_str = e_contact_get_const (contact, priority[i]);
if (phone_str && *phone_str) {
clear_entry_text (*local->addr, phone);
@@ -994,7 +994,7 @@ local_record_from_ecard (EAddrLocalRecord *local, EContact *contact, EAddrCondui
for (i = entryPhone1; i <= entryPhone5; i++) {
int phonelabel = local->addr->phoneLabel[i - entryPhone1];
const char *phone_str = NULL;
-
+
if (phonelabel == LABEL_EMAIL && !is_next_done (next_mail)) {
phone_str = e_contact_get_const (contact, next_mail);
next_mail = get_next_mail (&next_mail);
@@ -1020,19 +1020,19 @@ local_record_from_ecard (EAddrLocalRecord *local, EContact *contact, EAddrCondui
phone_str = e_contact_get_const (contact, next_mobile);
next_mobile = get_next_mobile (&next_mobile);
}
-
+
if (phone_str && *phone_str) {
clear_entry_text (*local->addr, i);
local->addr->entry[i] = e_pilot_utf8_to_pchar (phone_str);
}
}
}
-
+
/* Note */
local->addr->entry[entryNote] = e_pilot_utf8_to_pchar (e_contact_get_const (contact, E_CONTACT_NOTE));
}
-static void
+static void
local_record_from_uid (EAddrLocalRecord *local,
const char *uid,
EAddrConduitContext *ctxt)
@@ -1040,12 +1040,12 @@ local_record_from_uid (EAddrLocalRecord *local,
EContact *contact = NULL;
const char *cuid;
GList *l;
-
+
g_assert (local != NULL);
for (l = ctxt->cards; l != NULL; l = l->next) {
contact = l->data;
-
+
/* FIXME Do we need to check for the empty string? */
if ((cuid = e_contact_get_const (contact, E_CONTACT_UID)) && !strcmp (cuid, uid))
break;
@@ -1107,15 +1107,15 @@ ecard_from_remote_record(EAddrConduitContext *ctxt,
name = e_contact_name_new ();
name->given = get_entry_text (address, entryFirstname);
name->family = get_entry_text (address, entryLastname);
-
+
full_name = e_contact_name_to_string (name);
e_contact_set (contact, E_CONTACT_FULL_NAME, full_name);
e_contact_name_free (name);
-
+
/* File As */
if (!full_name || !*full_name)
set_contact_text (contact, E_CONTACT_FILE_AS, address, entryCompany);
-
+
g_free (full_name);
/* Title and Company */
@@ -1136,10 +1136,10 @@ ecard_from_remote_record(EAddrConduitContext *ctxt,
}
}
}
-
+
if (mailing_address == -1)
mailing_address = ctxt->cfg->default_address;
-
+
eaddress = g_new0 (EContactAddress, 1);
txt = get_entry_text (address, entryAddress);
@@ -1149,17 +1149,17 @@ ecard_from_remote_record(EAddrConduitContext *ctxt,
} else {
find = NULL;
}
-
+
eaddress->street = txt;
eaddress->ext = find != NULL ? g_strdup (find) : g_strdup ("");
eaddress->locality = get_entry_text (address, entryCity);
eaddress->region = get_entry_text (address, entryState);
eaddress->country = get_entry_text (address, entryCountry);
eaddress->code = get_entry_text (address, entryZip);
-
+
e_contact_set (contact, mailing_address, eaddress);
e_contact_address_free (eaddress);
-
+
/* Phone numbers */
get_next_init (&next_mail, &next_home, &next_work, &next_fax,
&next_other, &next_main, &next_pager, &next_mobile);
@@ -1167,7 +1167,7 @@ ecard_from_remote_record(EAddrConduitContext *ctxt,
for (i = entryPhone1; i <= entryPhone5; i++) {
int phonelabel = address.phoneLabel[i - entryPhone1];
char *phonenum = get_entry_text (address, i);
-
+
if (phonelabel == LABEL_EMAIL && !is_next_done (next_mail)) {
e_contact_set (contact, next_mail, phonenum);
next_mail = get_next_mail (&next_mail);
@@ -1193,7 +1193,7 @@ ecard_from_remote_record(EAddrConduitContext *ctxt,
e_contact_set (contact, next_mobile, phonenum);
next_mobile = get_next_mobile (&next_mobile);
}
-
+
g_free (phonenum);
}
@@ -1211,8 +1211,8 @@ check_for_slow_setting (GnomePilotConduit *c, EAddrConduitContext *ctxt)
GnomePilotConduitStandard *conduit = GNOME_PILOT_CONDUIT_STANDARD (c);
int map_count;
const char *uri;
-
- map_count = g_hash_table_size (ctxt->map->pid_map);
+
+ map_count = g_hash_table_size (ctxt->map->pid_map);
if (map_count == 0)
gnome_pilot_conduit_standard_set_slow (conduit, TRUE);
@@ -1233,7 +1233,7 @@ check_for_slow_setting (GnomePilotConduit *c, EAddrConduitContext *ctxt)
}
static void
-addressbook_authenticate (EBook *book,
+addressbook_authenticate (EBook *book,
gpointer data)
{
gchar *auth;
@@ -1253,16 +1253,16 @@ addressbook_authenticate (EBook *book,
if (auth && !strcmp ("plain/password", auth))
user = (gchar *)e_source_get_property (source, "user");
- else
+ else
user = (gchar *)e_source_get_property (source, "email_addr");
if (!user)
- user = "";
+ user = "";
str_uri = e_source_get_uri (source);
- e_uri = e_uri_new (str_uri);
+ e_uri = e_uri_new (str_uri);
pass_key = e_uri_to_string (e_uri, FALSE);
e_uri_free (e_uri);
-
+
passwd = e_passwords_get_password (component_name, pass_key);
if (passwd)
passwd = "";
@@ -1303,7 +1303,7 @@ pre_sync (GnomePilotConduit *conduit,
/* g_message ("Addressbook Conduit v.%s", CONDUIT_VERSION); */
ctxt->dbi = dbi;
-
+
if (ctxt->cfg->source) {
ctxt->ebook = e_book_new (ctxt->cfg->source, NULL);
} else {
@@ -1312,13 +1312,13 @@ pre_sync (GnomePilotConduit *conduit,
auth = (gchar *)e_source_get_property (ctxt->cfg->source, "auth");
if (auth) {
LOG (g_message ("contacts needs authentication\n"));
- g_signal_connect (ctxt->ebook, "auth_required",
+ g_signal_connect (ctxt->ebook, "auth_required",
G_CALLBACK (addressbook_authenticate), ctxt->cfg->source);
}
if (!ctxt->ebook || !e_book_open (ctxt->ebook, TRUE, NULL)) {
WARN(_("Could not load addressbook"));
gnome_pilot_conduit_error (conduit, _("Could not load addressbook"));
-
+
return -1;
}
@@ -1332,26 +1332,26 @@ pre_sync (GnomePilotConduit *conduit,
LOG (g_warning ("Failed to get EBookQuery"));
return -1;
}
-
+
if (!e_book_get_contacts (ctxt->ebook, query, &ctxt->cards, NULL)) {
LOG (g_warning ("Failed to get Contacts"));
e_book_query_unref (query);
return -1;
}
-
+
e_book_query_unref (query);
-
+
/* Count and hash the changes */
change_id = g_strdup_printf ("pilot-sync-evolution-addressbook-%d", ctxt->cfg->pilot_id);
if (!e_book_get_changes (ctxt->ebook, change_id, &ctxt->changed, NULL))
return -1;
ctxt->changed_hash = g_hash_table_new (g_str_hash, g_str_equal);
- g_free (change_id);
+ g_free (change_id);
for (l = ctxt->changed; l != NULL; l = l->next) {
EBookChange *ebc = l->data;
const char *uid;
-
+
uid = e_contact_get_const (ebc->contact, E_CONTACT_UID);
if (!e_pilot_map_uid_is_archived (ctxt->map, uid)) {
@@ -1372,7 +1372,7 @@ pre_sync (GnomePilotConduit *conduit,
e_pilot_map_remove_by_uid (ctxt->map, uid);
}
}
-
+
/* Set the count information */
num_records = g_list_length (ctxt->cards);
gnome_pilot_conduit_sync_abs_set_num_local_records(abs_conduit, num_records);
@@ -1385,14 +1385,14 @@ pre_sync (GnomePilotConduit *conduit,
if(buffer == NULL){
return pi_set_error(dbi->pilot_socket, PI_ERR_GENERIC_MEMORY);
}
-
+
len = dlp_ReadAppBlock (dbi->pilot_socket, dbi->db_handle, 0,
DLP_BUF_SIZE, buffer);
#else
buf = (unsigned char*)g_malloc (0xffff);
len = dlp_ReadAppBlock (dbi->pilot_socket, dbi->db_handle, 0,
(unsigned char *)buf, 0xffff);
-#endif
+#endif
if (len < 0) {
WARN (_("Could not read pilot's Address application block"));
WARN ("dlp_ReadAppBlock(...) = %d", len);
@@ -1422,7 +1422,7 @@ post_sync (GnomePilotConduit *conduit,
{
GList *changed;
gchar *filename, *change_id;
-
+
LOG (g_message ( "post_sync: Address Conduit v.%s", CONDUIT_VERSION ));
g_free (ctxt->cfg->last_uri);
@@ -1435,14 +1435,14 @@ post_sync (GnomePilotConduit *conduit,
/* FIX ME ugly hack - our changes musn't count, this does introduce
* a race condition if anyone changes a record elsewhere during sycnc
- */
+ */
change_id = g_strdup_printf ("pilot-sync-evolution-addressbook-%d", ctxt->cfg->pilot_id);
if (e_book_get_changes (ctxt->ebook, change_id, &changed, NULL))
e_book_free_change_list (changed);
g_free (change_id);
LOG (g_message ( "---------------------------------------------------------\n" ));
-
+
return 0;
}
@@ -1453,7 +1453,7 @@ set_pilot_id (GnomePilotConduitSyncAbs *conduit,
EAddrConduitContext *ctxt)
{
LOG (g_message ( "set_pilot_id: setting to %d\n", ID ));
-
+
e_pilot_map_insert (ctxt->map, ID, e_contact_get_const (local->contact, E_CONTACT_UID), FALSE);
return 0;
@@ -1465,12 +1465,12 @@ set_status_cleared (GnomePilotConduitSyncAbs *conduit,
EAddrConduitContext *ctxt)
{
const char *uid;
-
+
LOG (g_message ( "set_status_cleared: clearing status\n" ));
-
+
if ((uid = e_contact_get_const (local->contact, E_CONTACT_UID)))
g_hash_table_remove (ctxt->changed_hash, uid);
-
+
return 0;
}
@@ -1489,7 +1489,7 @@ for_each (GnomePilotConduitSyncAbs *conduit,
cards = ctxt->cards;
count = 0;
-
+
if (cards != NULL) {
LOG (g_message ( "iterating over %d records", g_list_length (cards) ));
@@ -1536,17 +1536,17 @@ for_each_modified (GnomePilotConduitSyncAbs *conduit,
if (*local == NULL) {
LOG (g_message ( "for_each_modified beginning\n" ));
-
+
iterator = ctxt->changed;
-
+
count = 0;
-
+
iterator = next_changed_item (ctxt, iterator);
if (iterator != NULL) {
EBookChange *ebc = iterator->data;
-
+
LOG (g_message ( "iterating over %d records", g_hash_table_size (ctxt->changed_hash)));
-
+
*local = g_new0 (EAddrLocalRecord, 1);
local_record_from_ecard (*local, ebc->contact, ctxt);
ctxt->locals = g_list_prepend (ctxt->locals, *local);
@@ -1597,12 +1597,12 @@ compare (GnomePilotConduitSyncAbs *conduit,
if (remote->length != local_pilot.length
|| memcmp (local_pilot.record, remote->record, remote->length))
retval = 1;
-
+
if (retval == 0)
LOG (g_message ( " equal" ));
else
LOG (g_message ( " not equal" ));
-
+
return retval;
}
@@ -1613,18 +1613,18 @@ add_record (GnomePilotConduitSyncAbs *conduit,
{
EContact *contact;
int retval = 0;
-
+
g_return_val_if_fail (remote != NULL, -1);
LOG (g_message ( "add_record: adding %s to desktop\n", print_remote (remote) ));
contact = ecard_from_remote_record (ctxt, remote, NULL);
-
+
/* add the ecard to the server */
if (!e_book_add_contact (ctxt->ebook, contact, NULL)) {
WARN ("add_record: failed to add card to ebook\n");
g_object_unref (contact);
-
+
return -1;
}
@@ -1645,7 +1645,7 @@ replace_record (GnomePilotConduitSyncAbs *conduit,
EBookChange *ebc;
char *old_id;
int retval = 0;
-
+
g_return_val_if_fail (remote != NULL, -1);
LOG (g_message ("replace_record: replace %s with %s\n",
@@ -1653,7 +1653,7 @@ replace_record (GnomePilotConduitSyncAbs *conduit,
old_id = e_contact_get (local->contact, E_CONTACT_UID);
ebc = g_hash_table_lookup (ctxt->changed_hash, old_id);
-
+
new_contact = ecard_from_remote_record (ctxt, remote, local->contact);
g_object_unref (local->contact);
local->contact = new_contact;
@@ -1664,20 +1664,20 @@ replace_record (GnomePilotConduitSyncAbs *conduit,
return -1;
}
-
+
} else {
if (!e_book_commit_contact (ctxt->ebook, local->contact, NULL)) {
WARN (G_STRLOC ": failed to commit card\n");
return -1;
- }
+ }
}
/* Adding a record causes wombat to assign a new uid so we must tidy */
if (ebc && ebc->change_type == E_BOOK_CHANGE_CARD_DELETED) {
const char *uid = e_contact_get_const (local->contact, E_CONTACT_UID);
gboolean arch;
-
+
arch = e_pilot_map_uid_is_archived (ctxt->map, uid);
e_pilot_map_insert (ctxt->map, remote->ID, uid, arch);
@@ -1702,7 +1702,7 @@ delete_record (GnomePilotConduitSyncAbs *conduit,
{
GError *error = NULL;
int retval = 0;
-
+
g_return_val_if_fail (local != NULL, -1);
g_return_val_if_fail (local->contact != NULL, -1);
@@ -1715,7 +1715,7 @@ delete_record (GnomePilotConduitSyncAbs *conduit,
retval = -1;
}
-
+
return retval;
}
@@ -1726,13 +1726,13 @@ archive_record (GnomePilotConduitSyncAbs *conduit,
EAddrConduitContext *ctxt)
{
int retval = 0;
-
+
g_return_val_if_fail (local != NULL, -1);
LOG (g_message ( "archive_record: %s\n", archive ? "yes" : "no" ));
e_pilot_map_insert (ctxt->map, local->local.ID, e_contact_get_const (local->contact, E_CONTACT_UID), archive);
-
+
return retval;
}
@@ -1743,24 +1743,24 @@ match (GnomePilotConduitSyncAbs *conduit,
EAddrConduitContext *ctxt)
{
const char *uid;
-
+
LOG (g_message ("match: looking for local copy of %s\n",
print_remote (remote)));
-
+
g_return_val_if_fail (local != NULL, -1);
g_return_val_if_fail (remote != NULL, -1);
*local = NULL;
uid = e_pilot_map_lookup_uid (ctxt->map, remote->ID, TRUE);
-
+
if (!uid)
return 0;
LOG (g_message ( " matched\n" ));
-
+
*local = g_new0 (EAddrLocalRecord, 1);
local_record_from_uid (*local, uid, ctxt);
-
+
return 0;
}
@@ -1785,9 +1785,9 @@ prepare (GnomePilotConduitSyncAbs *conduit,
EAddrConduitContext *ctxt)
{
LOG (g_message ( "prepare: encoding local %s\n", print_local (local) ));
-
+
*remote = local_record_to_pilot_record (local, ctxt);
-
+
return 0;
}
@@ -1810,7 +1810,7 @@ create_settings_window (GnomePilotConduit *conduit,
EAddrConduitContext *ctxt)
{
LOG (g_message ( "create_settings_window" ));
-
+
if (!ctxt->cfg->source_list)
return -1;
@@ -1821,14 +1821,14 @@ create_settings_window (GnomePilotConduit *conduit,
gtk_widget_show (ctxt->ps);
fill_widgets (ctxt);
-
+
return 0;
}
static void
display_settings (GnomePilotConduit *conduit, EAddrConduitContext *ctxt)
{
LOG (g_message ( "display_settings" ));
-
+
fill_widgets (ctxt);
}
@@ -1903,10 +1903,10 @@ conduit_get_gpilot_conduit (guint32 pilot_id)
void
conduit_destroy_gpilot_conduit (GnomePilotConduit *conduit)
-{
+{
EAddrConduitContext *ctxt;
- ctxt = gtk_object_get_data (GTK_OBJECT (conduit),
+ ctxt = gtk_object_get_data (GTK_OBJECT (conduit),
"addrconduit_context");
e_addr_context_destroy (ctxt);
diff --git a/addressbook/gui/component/addressbook-component.c b/addressbook/gui/component/addressbook-component.c
index a010fafafb..57de2505c4 100644
--- a/addressbook/gui/component/addressbook-component.c
+++ b/addressbook/gui/component/addressbook-component.c
@@ -101,7 +101,7 @@ ensure_sources (AddressbookComponent *component)
group = E_SOURCE_GROUP (g->data);
- /* compare only file:// part. If user home dir name changes we do not want to create
+ /* compare only file:// part. If user home dir name changes we do not want to create
one more group */
if (!on_this_computer && !strncmp (base_uri_proto, e_source_group_peek_base_uri (group), 7))
@@ -132,7 +132,7 @@ ensure_sources (AddressbookComponent *component)
homedir name changes */
if (strcmp (base_uri_proto, e_source_group_peek_base_uri (on_this_computer))) {
e_source_group_set_base_uri (on_this_computer, base_uri_proto);
-
+
/* *sigh* . We shouldn't need this sync call here as set_base_uri
call results in synching to gconf, but that happens in idle loop
and too late to prevent user seeing "Can not Open ... because of invalid uri" error.*/
@@ -176,7 +176,7 @@ view_destroyed_cb (gpointer data, GObject *where_the_object_was)
AddressbookComponent *addressbook_component = data;
AddressbookComponentPrivate *priv;
GList *l;
-
+
priv = addressbook_component->priv;
for (l = priv->views; l; l = l->next) {
@@ -285,7 +285,7 @@ impl_requestCreateItem (PortableServer_Servant servant,
CORBA_Environment *ev)
{
EBook *book;
- GConfClient *gconf_client;
+ GConfClient *gconf_client;
ESourceList *source_list;
char *uid;
@@ -345,9 +345,9 @@ impl_handleURI (PortableServer_Servant servant,
l = g_list_last (priv->views);
if (!l)
return;
-
+
view = l->data;
-
+
if (!strncmp (uri, "contacts:", 9)) {
EUri *euri = e_uri_new (uri);
const char *p;
@@ -358,17 +358,17 @@ impl_handleURI (PortableServer_Servant servant,
if (p) {
while (*p) {
len = strcspn (p, "=&");
-
+
/* If it's malformed, give up. */
if (p[len] != '=')
break;
-
+
header = (char *) p;
header[len] = '\0';
p += len + 1;
-
+
clen = strcspn (p, "&");
-
+
content = g_strndup (p, clen);
if (!g_ascii_strcasecmp (header, "source-uid")) {
@@ -386,15 +386,15 @@ impl_handleURI (PortableServer_Servant servant,
p += 4;
}
}
-
+
addressbook_view_edit_contact (view, src_uid, contact_uid);
-
+
g_free (src_uid);
g_free (contact_uid);
}
e_uri_free (euri);
}
-
+
}
static void
diff --git a/addressbook/gui/component/addressbook-config.c b/addressbook/gui/component/addressbook-config.c
index c40a32ce0a..2f8b63b76c 100644
--- a/addressbook/gui/component/addressbook-config.c
+++ b/addressbook/gui/component/addressbook-config.c
@@ -110,7 +110,7 @@ struct _AddressbookSourceDialog {
/* info page fields */
GtkWidget *host;
GtkWidget *auth_optionmenu;
- AddressbookLDAPAuthType auth;
+ AddressbookLDAPAuthType auth;
GtkWidget *auth_principal;
/* connecting page fields */
@@ -285,7 +285,7 @@ addressbook_ldap_auth (GtkWidget *window, LDAP *ldap)
ldap_error = ldap_simple_bind_s (ldap, NULL, NULL);
if (LDAP_SUCCESS != ldap_error)
e_error_run ((GtkWindow *) window, "addressbook:ldap-auth", NULL);
-
+
return ldap_error;
}
@@ -305,7 +305,7 @@ addressbook_root_dse_query (AddressbookSourceDialog *dialog, LDAP *ldap,
attrs, 0, NULL, NULL, &timeout, LDAP_NO_LIMIT, resp);
if (LDAP_SUCCESS != ldap_error)
e_error_run (GTK_WINDOW (dialog->window), "addressbook:ldap-search-base", NULL);
-
+
return ldap_error;
}
@@ -530,7 +530,7 @@ eabc_general_type(EConfig *ec, EConfigItem *item, struct _GtkWidget *parent, str
label = gtk_label_new_with_mnemonic(_("_Type:"));
gtk_box_pack_start((GtkBox *)w, label, FALSE, FALSE, 0);
- dropdown = (GtkComboBox *)gtk_combo_box_new();
+ dropdown = (GtkComboBox *)gtk_combo_box_new();
cell = gtk_cell_renderer_text_new();
store = gtk_list_store_new(2, G_TYPE_STRING, G_TYPE_POINTER);
i = 0;
@@ -567,14 +567,14 @@ name_changed_cb(GtkWidget *w, AddressbookSourceDialog *sdialog)
e_source_set_name (sdialog->source, gtk_entry_get_text (GTK_ENTRY (sdialog->display_name)));
}
-static void
+static void
offline_status_changed_cb (GtkWidget *widget, AddressbookSourceDialog *sdialog)
{
if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)))
e_source_set_property (sdialog->source, "offline_sync", "1");
- else
- e_source_set_property (sdialog->source, "offline_sync", "0");
-
+ else
+ e_source_set_property (sdialog->source, "offline_sync", "0");
+
}
static GtkWidget *
@@ -609,7 +609,7 @@ eabc_general_name(EConfig *ec, EConfigItem *item, struct _GtkWidget *parent, str
gtk_widget_set_sensitive (GTK_WIDGET(sdialog->display_name), FALSE);
}
}
-
+
g_object_unref(gui);
return w;
@@ -623,17 +623,17 @@ eabc_general_offline(EConfig *ec, EConfigItem *item, struct _GtkWidget *parent,
GtkWidget *offline_setting;
const char *offline_sync;
gboolean is_local_book;
-
+
is_local_book = g_str_has_prefix (e_source_group_peek_base_uri (sdialog->source_group), "file:");
offline_sync = e_source_get_property (sdialog->source, "offline_sync");
- if (old)
+ if (old)
return old;
else {
offline_setting = gtk_check_button_new_with_label (N_("Copy book content locally for offline operation"));
gtk_widget_show (offline_setting);
gtk_container_add (GTK_CONTAINER (parent), offline_setting);
g_signal_connect (offline_setting, "toggled", G_CALLBACK (offline_status_changed_cb), sdialog);
-
+
}
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (offline_setting), (offline_sync && g_str_equal (offline_sync, "1")) ? TRUE : FALSE);
if (is_local_book)
@@ -644,12 +644,12 @@ eabc_general_offline(EConfig *ec, EConfigItem *item, struct _GtkWidget *parent,
#ifdef HAVE_LDAP
static gchar *
-form_ldap_search_filter (GtkWidget *w)
+form_ldap_search_filter (GtkWidget *w)
{
gchar *filter;
const gchar *search_filter = gtk_entry_get_text ((GtkEntry *) w);
- /* this function can be used to format the search filter entered */
+ /* this function can be used to format the search filter entered */
if ((strlen (search_filter) !=0) && *search_filter != '(' && *(search_filter + (strlen (search_filter-1))) != ')')
filter = g_strdup_printf ("(%s)", search_filter);
else
@@ -657,7 +657,7 @@ form_ldap_search_filter (GtkWidget *w)
return filter;
}
-
+
static void
url_changed(AddressbookSourceDialog *sdialog)
{
@@ -737,7 +737,7 @@ eabc_general_host(EConfig *ec, EConfigItem *item, struct _GtkWidget *parent, str
gtk_entry_set_text((GtkEntry *)sdialog->host, lud && lud->lud_host ? lud->lud_host : "");
g_signal_connect (sdialog->host, "changed", G_CALLBACK (host_changed_cb), sdialog);
- sdialog->port_combo = glade_xml_get_widget (gui, "port-combo");
+ sdialog->port_combo = glade_xml_get_widget (gui, "port-combo");
sprintf(port, "%u", lud && lud->lud_port? lud->lud_port : LDAP_PORT);
gtk_entry_set_text (GTK_ENTRY (GTK_COMBO (sdialog->port_combo)->entry), port);
g_signal_connect (GTK_COMBO(sdialog->port_combo)->entry, "changed", G_CALLBACK (port_entry_changed_cb), sdialog);
@@ -813,7 +813,7 @@ eabc_general_auth(EConfig *ec, EConfigItem *item, struct _GtkWidget *parent, str
sdialog->auth_optionmenu = glade_xml_get_widget (gui, "auth-optionmenu");
tmp = e_source_get_property(sdialog->source, "auth");
sdialog->auth = tmp ? ldap_parse_auth(tmp) : ADDRESSBOOK_LDAP_AUTH_NONE;
- gtk_option_menu_set_history (GTK_OPTION_MENU(sdialog->auth_optionmenu), sdialog->auth);
+ gtk_option_menu_set_history (GTK_OPTION_MENU(sdialog->auth_optionmenu), sdialog->auth);
g_signal_connect(sdialog->auth_optionmenu, "changed", G_CALLBACK(auth_optionmenu_changed_cb), sdialog);
sdialog->auth_principal = glade_xml_get_widget (gui, "auth-entry");
diff --git a/addressbook/gui/component/addressbook-migrate.c b/addressbook/gui/component/addressbook-migrate.c
index 249cdf7a12..1974ada536 100644
--- a/addressbook/gui/component/addressbook-migrate.c
+++ b/addressbook/gui/component/addressbook-migrate.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* Copyright (C) 2004, Novell, Inc.
*
* This program is free software; you can redistribute it and/or
@@ -73,28 +73,28 @@ setup_progress_dialog (MigrationContext *context)
gtk_window_set_title (GTK_WINDOW (context->window), _("Migrating..."));
gtk_window_set_modal (GTK_WINDOW (context->window), TRUE);
gtk_container_set_border_width (GTK_CONTAINER (context->window), 6);
-
+
vbox = gtk_vbox_new (FALSE, 6);
gtk_widget_show (vbox);
gtk_container_add (GTK_CONTAINER (context->window), vbox);
-
+
context->label = gtk_label_new ("");
gtk_label_set_line_wrap (GTK_LABEL (context->label), TRUE);
gtk_widget_show (context->label);
gtk_box_pack_start_defaults (GTK_BOX (vbox), context->label);
-
+
hbox = gtk_hbox_new (FALSE, 6);
gtk_widget_show (hbox);
gtk_box_pack_start_defaults (GTK_BOX (vbox), hbox);
-
+
context->folder_label = gtk_label_new ("");
gtk_widget_show (context->folder_label);
gtk_box_pack_start_defaults (GTK_BOX (hbox), context->folder_label);
-
+
context->progress = gtk_progress_bar_new ();
gtk_widget_show (context->progress);
gtk_box_pack_start_defaults (GTK_BOX (hbox), context->progress);
-
+
gtk_widget_show (context->window);
}
@@ -121,13 +121,13 @@ static void
dialog_set_folder_name (MigrationContext *context, const char *folder_name)
{
char *text;
-
+
text = g_strdup_printf (_("Migrating `%s':"), folder_name);
gtk_label_set_text (GTK_LABEL (context->folder_label), text);
g_free (text);
-
+
gtk_progress_bar_set_fraction (GTK_PROGRESS_BAR (context->progress), 0.0);
-
+
while (gtk_events_pending ())
gtk_main_iteration ();
@@ -140,12 +140,12 @@ static void
dialog_set_progress (MigrationContext *context, double percent)
{
char text[5];
-
+
snprintf (text, sizeof (text), "%d%%", (int) (percent * 100.0f));
-
+
gtk_progress_bar_set_fraction (GTK_PROGRESS_BAR (context->progress), percent);
gtk_progress_bar_set_text (GTK_PROGRESS_BAR (context->progress), text);
-
+
while (gtk_events_pending ())
gtk_main_iteration ();
@@ -229,7 +229,7 @@ migrate_contacts (MigrationContext *context, EBook *old_book, EBook *new_book)
/* both books are loaded, start the actual migration */
e_book_get_contacts (old_book, query, &contacts, NULL);
- e_book_query_unref (query);
+ e_book_query_unref (query);
num_contacts = g_list_length (contacts);
for (l = contacts; l; l = l->next) {
@@ -334,7 +334,7 @@ migrate_contacts (MigrationContext *context, EBook *old_book, EBook *new_book)
params = e_vcard_attribute_get_params (a);
if (!params)
e_vcard_attribute_add_param_with_value (a,
- e_vcard_attribute_param_new (EVC_TYPE),
+ e_vcard_attribute_param_new (EVC_TYPE),
"OTHER");
if (v && v->data) {
@@ -973,7 +973,7 @@ migrate_company_phone_for_local_folders (MigrationContext *context, ESourceGroup
}
attr = next_attr;
-
+
if (converted)
break;
}
@@ -1004,10 +1004,10 @@ migrate_pilot_data (const char *old_path, const char *new_path)
const char *ext;
char *filename;
GDir *dir;
-
+
if (!(dir = g_dir_open (old_path, 0, NULL)))
return;
-
+
while ((dent = g_dir_read_name (dir))) {
if ((!strncmp (dent, "pilot-map-", 10) &&
((ext = strrchr (dent, '.')) && !strcmp (ext, ".xml"))) ||
@@ -1018,13 +1018,13 @@ migrate_pilot_data (const char *old_path, const char *new_path)
size_t nread, nwritten;
int fd0, fd1;
ssize_t n;
-
+
filename = g_build_filename (old_path, dent, NULL);
if ((fd0 = g_open (filename, O_RDONLY | O_BINARY, 0)) == -1) {
g_free (filename);
continue;
}
-
+
g_free (filename);
filename = g_build_filename (new_path, dent, NULL);
if ((fd1 = g_open (filename, O_WRONLY | O_CREAT | O_TRUNC | O_BINARY, 0666)) == -1) {
@@ -1032,30 +1032,30 @@ migrate_pilot_data (const char *old_path, const char *new_path)
close (fd0);
continue;
}
-
+
do {
do {
n = read (fd0, inbuf, sizeof (inbuf));
} while (n == -1 && errno == EINTR);
-
+
if (n < 1)
break;
-
+
nread = n;
nwritten = 0;
do {
do {
n = write (fd1, inbuf + nwritten, nread - nwritten);
} while (n == -1 && errno == EINTR);
-
+
if (n > 0)
nwritten += n;
} while (nwritten < nread && n != -1);
-
+
if (n == -1)
break;
} while (1);
-
+
if (n != -1)
n = fsync (fd1);
@@ -1063,13 +1063,13 @@ migrate_pilot_data (const char *old_path, const char *new_path)
g_warning ("Failed to migrate %s: %s", dent, strerror (errno));
g_unlink (filename);
}
-
+
close (fd0);
close (fd1);
g_free (filename);
}
}
-
+
g_dir_close (dir);
}
@@ -1077,7 +1077,7 @@ static MigrationContext*
migration_context_new (AddressbookComponent *component)
{
MigrationContext *context = g_new (MigrationContext, 1);
-
+
/* set up the mapping from old uris to new uids */
context->folder_uid_map = g_hash_table_new_full (g_str_hash, g_str_equal, (GDestroyNotify)g_free, (GDestroyNotify)g_free);
@@ -1122,12 +1122,12 @@ addressbook_migrate (AddressbookComponent *component, int major, int minor, int
further decomposition will happen below. */
&& (minor < 5 || (minor == 5 && revision <= 10)))
need_dialog = TRUE;
-
+
if (need_dialog)
setup_progress_dialog (context);
if (major == 1) {
-
+
if (minor < 5 || (minor == 5 && revision <= 2)) {
/* initialize our dialog */
dialog_set_label (context,
@@ -1160,13 +1160,13 @@ addressbook_migrate (AddressbookComponent *component, int major, int minor, int
migrate_company_phone_for_local_folders (context, on_this_computer);
}
-
+
if (minor < 5 || (minor == 5 && revision <= 10)) {
char *old_path, *new_path;
-
+
dialog_set_label (context, _("Evolution's Palm Sync changelog and map files have changed.\n\n"
"Please be patient while Evolution migrates your Pilot Sync data..."));
-
+
old_path = g_build_filename (g_get_home_dir (), "evolution", "local", "Contacts", NULL);
new_path = g_build_filename (addressbook_component_peek_base_directory (component),
"addressbook", "local", "system", NULL);
@@ -1204,7 +1204,7 @@ addressbook_migrate (AddressbookComponent *component, int major, int minor, int
g_object_unref (on_ldap_servers);
if (personal_source)
g_object_unref (personal_source);
-
+
migration_context_free (context);
diff --git a/addressbook/gui/component/addressbook-migrate.h b/addressbook/gui/component/addressbook-migrate.h
index 07d261a205..0ec738399f 100644
--- a/addressbook/gui/component/addressbook-migrate.h
+++ b/addressbook/gui/component/addressbook-migrate.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* Copyright (C) 2004, Novell, Inc.
*
* This program is free software; you can redistribute it and/or
diff --git a/addressbook/gui/component/addressbook-view.c b/addressbook/gui/component/addressbook-view.c
index 8fcf39cc29..75c3f2f221 100644
--- a/addressbook/gui/component/addressbook-view.c
+++ b/addressbook/gui/component/addressbook-view.c
@@ -155,11 +155,11 @@ save_all_contacts_cb (BonoboUIComponent *uih, void *user_data, const char *path)
{
AddressbookView *view = (AddressbookView *) user_data;
EABView *v = get_current_view (view);
-
+
if (v)
eab_view_save_as (v, TRUE);
}
-
+
static void
save_contact_cb (BonoboUIComponent *uih, void *user_data, const char *path)
{
@@ -274,7 +274,7 @@ copy_all_contacts_to_cb (BonoboUIComponent *uih, void *user_data, const char *pa
AddressbookView *view = (AddressbookView *) user_data;
EABView *v = get_current_view (view);
- if (v)
+ if (v)
eab_view_copy_to_folder (v, TRUE);
}
@@ -292,7 +292,7 @@ move_all_contacts_to_cb (BonoboUIComponent *uih, void *user_data, const char *pa
{
AddressbookView *view = (AddressbookView *) user_data;
EABView *v = get_current_view (view);
- if (v)
+ if (v)
eab_view_move_to_folder (v, TRUE);
}
@@ -335,11 +335,11 @@ delete_addressbook_folder (AddressbookView *view)
GtkWindow *toplevel;
selected_source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (priv->selector));
- if (!selected_source)
+ if (!selected_source)
return;
toplevel = (GtkWindow *) gtk_widget_get_toplevel (priv->notebook);
- if (e_error_run (toplevel, "addressbook:ask-delete-addressbook",
+ if (e_error_run (toplevel, "addressbook:ask-delete-addressbook",
e_source_peek_name(selected_source)) != GTK_RESPONSE_YES)
return;
@@ -351,9 +351,9 @@ delete_addressbook_folder (AddressbookView *view)
selected_source))
e_source_selector_unselect_source (E_SOURCE_SELECTOR (priv->selector),
selected_source);
-
+
e_source_group_remove_source (e_source_peek_group (selected_source), selected_source);
-
+
e_source_list_sync (priv->source_list, NULL);
}
else {
@@ -408,7 +408,7 @@ edit_addressbook_folder (AddressbookView *view)
}
gtk_window_present (GTK_WINDOW (closure->editor));
-
+
}
static void
@@ -425,10 +425,10 @@ rename_addressbook_folder (AddressbookView *view)
{
AddressbookViewPrivate *priv = view->priv;
ESource *source;
- const char *old_name;
+ const char *old_name;
char *prompt, *new_name;
gboolean done = FALSE;
-
+
source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (priv->selector));
old_name = e_source_peek_name(source);
prompt = g_strdup_printf (_("Rename the \"%s\" folder to:"), old_name);
@@ -449,7 +449,7 @@ rename_addressbook_folder (AddressbookView *view)
}
}
g_free (new_name);
-
+
}
static void
@@ -466,7 +466,7 @@ folder_can_delete (AddressbookView *view)
AddressbookViewPrivate *priv = view->priv;
ESource *source ;
const char *source_uri;
-
+
source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (priv->selector));
if(source) {
source_uri = e_source_peek_relative_uri (source);
@@ -622,7 +622,7 @@ static EPixmap pixmaps [] = {
E_PIXMAP ("/commands/ContactsPrint", "document-print", E_ICON_SIZE_MENU),
E_PIXMAP ("/commands/ContactsPrintPreview", "document-print-preview", E_ICON_SIZE_MENU),
E_PIXMAP ("/commands/ContactsSaveAsVCard", "document-save-as", E_ICON_SIZE_MENU),
- E_PIXMAP ("/commands/ContactsSendContactToOther", "mail-forward", E_ICON_SIZE_MENU),
+ E_PIXMAP ("/commands/ContactsSendContactToOther", "mail-forward", E_ICON_SIZE_MENU),
E_PIXMAP ("/commands/ContactsSendMessageToContact", "mail-message-new", E_ICON_SIZE_MENU),
E_PIXMAP ("/commands/FolderCopy", "edit-copy", E_ICON_SIZE_MENU),
E_PIXMAP ("/commands/FolderDelete", "edit-delete", E_ICON_SIZE_MENU),
@@ -651,7 +651,7 @@ control_activate (BonoboControl *control,
bonobo_ui_component_add_verb_list_with_data (
uic, verbs, view);
-
+
bonobo_ui_component_freeze (uic, NULL);
xmlfile = g_build_filename (EVOLUTION_UIDIR,
@@ -676,8 +676,8 @@ control_activate (BonoboControl *control,
}
static void
-control_activate_cb (BonoboControl *control,
- gboolean activate,
+control_activate_cb (BonoboControl *control,
+ gboolean activate,
AddressbookView *view)
{
BonoboUIComponent *uic;
@@ -770,7 +770,7 @@ load_uri_for_selection (ESourceSelector *selector,
ESource *selected_source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (selector));
ESource *primary = get_primary_source (view);
- if (selected_source != NULL &&
+ if (selected_source != NULL &&
((primary && (!g_str_equal (e_source_peek_uid (primary),e_source_peek_uid (selected_source) )))||force))
activate_source (view, selected_source);
}
@@ -779,17 +779,17 @@ static ESource *
find_first_source (ESourceList *source_list)
{
GSList *groups, *sources, *l, *m;
-
+
groups = e_source_list_peek_groups (source_list);
for (l = groups; l; l = l->next) {
ESourceGroup *group = l->data;
-
+
sources = e_source_group_peek_sources (group);
for (m = sources; m; m = m->next) {
ESource *source = m->data;
return source;
- }
+ }
}
return NULL;
@@ -869,7 +869,7 @@ book_removed (EBook *book, EBookStatus status, gpointer data)
source))
e_source_selector_unselect_source (E_SOURCE_SELECTOR (priv->selector),
source);
-
+
e_source_group_remove_source (e_source_peek_group (source), source);
e_source_list_sync (priv->source_list, NULL);
@@ -928,7 +928,7 @@ save_addressbook_cb(EPopup *ep, EPopupItem *pitem, void *data)
{
AddressbookView *view = data;
EABView *v = get_current_view (view);
- if (v)
+ if (v)
eab_view_save_as (v, TRUE);
}
@@ -998,11 +998,11 @@ popup_event_callback(ESourceSelector *selector, ESource *source, GdkEventButton
}
static gboolean
-selector_tree_drag_drop (GtkWidget *widget,
- GdkDragContext *context,
- int x,
- int y,
- guint time,
+selector_tree_drag_drop (GtkWidget *widget,
+ GdkDragContext *context,
+ int x,
+ int y,
+ guint time,
AddressbookView *view)
{
GtkTreeViewColumn *column;
@@ -1012,10 +1012,10 @@ selector_tree_drag_drop (GtkWidget *widget,
GtkTreeModel *model;
GtkTreeIter iter;
gpointer data;
-
+
if (!gtk_tree_view_get_path_at_pos (GTK_TREE_VIEW (widget), x, y, &path, &column, &cell_x, &cell_y))
return FALSE;
-
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
if (!gtk_tree_model_get_iter (model, &iter, path)) {
@@ -1024,17 +1024,17 @@ selector_tree_drag_drop (GtkWidget *widget,
}
gtk_tree_model_get (model, &iter, 0, &data, -1);
-
+
if (E_IS_SOURCE_GROUP (data)) {
g_object_unref (data);
gtk_tree_path_free (path);
return FALSE;
}
-
+
gtk_tree_path_free (path);
return TRUE;
}
-
+
static gboolean
selector_tree_drag_motion (GtkWidget *widget,
GdkDragContext *context,
@@ -1047,21 +1047,21 @@ selector_tree_drag_motion (GtkWidget *widget,
GtkTreeModel *model;
GtkTreeIter iter;
GdkDragAction action = { 0, };
-
+
if (!gtk_tree_view_get_dest_row_at_pos (GTK_TREE_VIEW (widget),
x, y, &path, &pos))
goto finish;
-
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
-
+
if (!gtk_tree_model_get_iter (model, &iter, path))
goto finish;
-
+
gtk_tree_model_get (model, &iter, 0, &data, -1);
if (E_IS_SOURCE_GROUP (data) || e_source_get_readonly (data))
goto finish;
-
+
gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget), path, GTK_TREE_VIEW_DROP_INTO_OR_BEFORE);
/* Make default action move, not copy */
if (context->actions & GDK_ACTION_MOVE)
@@ -1074,7 +1074,7 @@ selector_tree_drag_motion (GtkWidget *widget,
gtk_tree_path_free (path);
if (data)
g_object_unref (data);
-
+
gdk_drag_status (context, action, GDK_CURRENT_TIME);
return TRUE;
}
@@ -1152,11 +1152,11 @@ merged_contact_cb (EBook *book, EBookStatus status, const char *id, gpointer clo
}
}
-static gboolean
-selector_tree_drag_data_received (GtkWidget *widget,
- GdkDragContext *context,
- gint x,
- gint y,
+static gboolean
+selector_tree_drag_data_received (GtkWidget *widget,
+ GdkDragContext *context,
+ gint x,
+ gint y,
GtkSelectionData *data,
guint info,
guint time,
@@ -1177,17 +1177,17 @@ selector_tree_drag_data_received (GtkWidget *widget,
if (!gtk_tree_view_get_dest_row_at_pos (GTK_TREE_VIEW (widget),
x, y, &path, &pos))
goto finish;
-
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
-
+
if (!gtk_tree_model_get_iter (model, &iter, path))
goto finish;
-
+
gtk_tree_model_get (model, &iter, 0, &target, -1);
if (E_IS_SOURCE_GROUP (target) || e_source_get_readonly (target))
goto finish;
-
+
target_book = e_book_new (target, NULL);
if (!target_book) {
g_message (G_STRLOC ":Couldn't create EBook.");
@@ -1223,11 +1223,11 @@ selector_tree_drag_data_received (GtkWidget *widget,
gtk_tree_path_free (path);
if (target)
g_object_unref (target);
-
+
gtk_drag_finish (context, success, merge_context->remove_from_source, time);
return TRUE;
-}
+}
static void
selector_tree_drag_leave (GtkWidget *widget, GdkDragContext *context, guint time, gpointer data)
@@ -1277,12 +1277,12 @@ addressbook_view_class_init (AddressbookViewClass *klass)
parent_class = g_type_class_peek_parent (klass);
}
-static gboolean
+static gboolean
source_selector_key_press_event_callback (GtkWidget *widget, GdkEventKey *event, AddressbookView *view)
{
if (event->keyval == GDK_Delete) {
delete_addressbook_folder (view);
- return TRUE;
+ return TRUE;
}
return FALSE;
}
@@ -1294,7 +1294,7 @@ addressbook_view_init (AddressbookView *view)
GtkWidget *selector_scrolled_window;
AtkObject *a11y;
- view->priv =
+ view->priv =
priv = g_new0 (AddressbookViewPrivate, 1);
priv->gconf_client = addressbook_component_peek_gconf_client (addressbook_component_peek ());
@@ -1365,7 +1365,7 @@ addressbook_view_init (AddressbookView *view)
G_CALLBACK (primary_source_selection_changed_callback),
G_OBJECT (view), 0);
g_signal_connect_after (priv->selector, "key_press_event",
- G_CALLBACK (source_selector_key_press_event_callback),
+ G_CALLBACK (source_selector_key_press_event_callback),
G_OBJECT (view));
g_signal_connect_object (priv->selector, "popup_event",
G_CALLBACK (popup_event_callback),
@@ -1397,7 +1397,7 @@ addressbook_view_dispose (GObject *object)
if (view->priv) {
if (priv->book)
g_object_unref (priv->book);
-
+
g_free(priv->passwd);
if (priv->source_list)
@@ -1522,7 +1522,7 @@ activate_source (AddressbookView *view,
gtk_widget_show (uid_view);
gtk_widget_show (label);
-
+
g_object_set (uid_view, "type", EAB_VIEW_TABLE, NULL);
gtk_notebook_append_page (GTK_NOTEBOOK (priv->notebook),
@@ -1619,8 +1619,8 @@ addressbook_view_peek_folder_view (AddressbookView *view)
}
void
-addressbook_view_edit_contact (AddressbookView* view,
- const char* source_uid,
+addressbook_view_edit_contact (AddressbookView* view,
+ const char* source_uid,
const char* contact_uid)
{
AddressbookViewPrivate *priv = view->priv;
@@ -1628,7 +1628,7 @@ addressbook_view_edit_contact (AddressbookView* view,
ESource* source = NULL;
EContact* contact = NULL;
EBook* book = NULL;
-
+
if (!source_uid || !contact_uid)
return;
@@ -1637,7 +1637,7 @@ addressbook_view_edit_contact (AddressbookView* view,
return;
/* FIXME: Can I unref this book? */
- book = e_book_new (source, NULL);
+ book = e_book_new (source, NULL);
if (!book)
return;
@@ -1647,7 +1647,7 @@ addressbook_view_edit_contact (AddressbookView* view,
}
e_book_get_contact (book, contact_uid, &contact, NULL);
-
+
if (!contact) {
g_object_unref (book);
return;
diff --git a/addressbook/gui/component/addressbook-view.h b/addressbook/gui/component/addressbook-view.h
index 7e66cc7062..168d46fc81 100644
--- a/addressbook/gui/component/addressbook-view.h
+++ b/addressbook/gui/component/addressbook-view.h
@@ -57,8 +57,8 @@ GtkWidget *addressbook_view_peek_sidebar (AddressbookView *view
GtkWidget *addressbook_view_peek_statusbar (AddressbookView *view);
BonoboControl *addressbook_view_peek_folder_view (AddressbookView *view);
-void addressbook_view_edit_contact (AddressbookView* view,
- const char* source_id,
+void addressbook_view_edit_contact (AddressbookView* view,
+ const char* source_id,
const char* contact_id);
#endif /* _ADDRESSBOOK_VIEW_H_ */
diff --git a/addressbook/gui/component/addressbook.c b/addressbook/gui/component/addressbook.c
index 2134c1a6b1..898ce692d9 100644
--- a/addressbook/gui/component/addressbook.c
+++ b/addressbook/gui/component/addressbook.c
@@ -89,7 +89,7 @@ load_source_auth_cb (EBook *book, EBookStatus status, gpointer closure)
GtkWidget *dialog;
/* XXX "LDAP" has to be removed from the folowing message
- so that it wil valid for other servers which provide
+ so that it wil valid for other servers which provide
anonymous access*/
dialog = gtk_message_dialog_new (NULL,
@@ -164,7 +164,7 @@ addressbook_authenticate (EBook *book, gboolean previous_failure, ESource *sourc
gchar *uri = remove_parameters_from_uri(e_book_get_uri (book));
const gchar *auth_domain = e_source_get_property (source, "auth-domain");
const gchar *component_name;
-
+
component_name = auth_domain ? auth_domain : "Addressbook";
password = e_passwords_get_password (component_name, uri);
@@ -237,14 +237,14 @@ static void
auth_required_cb (EBook *book, gpointer data)
{
LoadSourceData *load_source_data = g_new0(LoadSourceData, 1);
-
+
load_source_data->source = g_object_ref (g_object_ref (e_book_get_source (book)));
load_source_data->cancelled = FALSE;
addressbook_authenticate (book, FALSE, load_source_data->source,
load_source_auth_cb, load_source_data);
-
-
-
+
+
+
}
static void
load_source_cb (EBook *book, EBookStatus status, gpointer closure)
@@ -262,7 +262,7 @@ load_source_cb (EBook *book, EBookStatus status, gpointer closure)
auth = e_source_get_property (load_source_data->source, "auth");
if (auth && strcmp (auth, "none")) {
g_signal_connect (book, "auth_required", G_CALLBACK(auth_required_cb), NULL);
-
+
if (e_book_is_online (book)) {
addressbook_authenticate (book, FALSE, load_source_data->source,
load_source_auth_cb, closure);
diff --git a/addressbook/gui/component/autocompletion-config.c b/addressbook/gui/component/autocompletion-config.c
index a5604d4b2d..567139025b 100644
--- a/addressbook/gui/component/autocompletion-config.c
+++ b/addressbook/gui/component/autocompletion-config.c
@@ -132,7 +132,7 @@ autocompletion_config_control_new (void)
GTK_SHADOW_IN);
ac->control_widget = e_source_selector_new (ac->source_list);
-
+
gtk_container_add (GTK_CONTAINER (scrolledwin), ac->control_widget);
initialize_selection (ac);
@@ -144,7 +144,7 @@ autocompletion_config_control_new (void)
g_signal_connect (ac->control_widget, "selection_changed",
G_CALLBACK (source_selection_changed), ac);
-
+
g_object_weak_ref (G_OBJECT (ac->config_control), config_control_destroy_notify, ac);
CORBA_exception_free (&ev);
diff --git a/addressbook/gui/component/openldap-extract.h b/addressbook/gui/component/openldap-extract.h
index 25c47df653..f11012ec40 100644
--- a/addressbook/gui/component/openldap-extract.h
+++ b/addressbook/gui/component/openldap-extract.h
@@ -217,7 +217,7 @@ get_token( const char ** sp, char ** token_val )
/* kind = TK_UNEXPCHAR; */
/* break; */
}
-
+
return kind;
}
@@ -746,7 +746,7 @@ static char *ldap_utf8_strchr( const char *str, const char *chr )
for( ; *str != '\0'; LDAP_UTF8_INCR(str) ) {
if( ldap_x_utf8_to_ucs4( str ) == ldap_x_utf8_to_ucs4( chr ) ) {
return (char *) str;
- }
+ }
}
return NULL;
@@ -761,7 +761,7 @@ static size_t ldap_utf8_strcspn( const char *str, const char *set )
for( cset = set; *cset != '\0'; LDAP_UTF8_INCR(cset) ) {
if( ldap_x_utf8_to_ucs4( cstr ) == ldap_x_utf8_to_ucs4( cset ) ) {
return cstr - str;
- }
+ }
}
}
@@ -781,7 +781,7 @@ static size_t ldap_utf8_strspn( const char *str, const char *set )
if( ldap_x_utf8_to_ucs4( cstr ) == ldap_x_utf8_to_ucs4( cset ) ) {
break;
- }
+ }
}
}
@@ -951,7 +951,7 @@ ldap_free_urldesc( LDAPURLDesc *ludp )
if ( ludp == NULL ) {
return;
}
-
+
if ( ludp->lud_scheme != NULL ) {
LDAP_FREE( ludp->lud_scheme );
}
@@ -1202,7 +1202,7 @@ ldap_url_parse_ext( LDAP_CONST char *url_in, LDAPURLDesc **ludpp )
* anything real.
*/
if( (p == NULL) && (q != NULL) && ((q = strchr( q, '?')) != NULL)) {
- q++;
+ q++;
/* ? immediately followed by question */
if( *q == '?') {
q++;
diff --git a/addressbook/gui/contact-editor/e-contact-editor-address.c b/addressbook/gui/contact-editor/e-contact-editor-address.c
index 06e79d61d6..5877babb49 100644
--- a/addressbook/gui/contact-editor/e-contact-editor-address.c
+++ b/addressbook/gui/contact-editor/e-contact-editor-address.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-contact-editor-address.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -92,14 +92,14 @@ e_contact_editor_address_class_init (EContactEditorAddressClass *klass)
object_class->get_property = e_contact_editor_address_get_property;
object_class->dispose = e_contact_editor_address_dispose;
- g_object_class_install_property (object_class, PROP_ADDRESS,
+ g_object_class_install_property (object_class, PROP_ADDRESS,
g_param_spec_boxed ("address",
_("Address"),
/*_( */"XXX blurb" /*)*/,
e_contact_address_get_type (),
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_EDITABLE,
+ g_object_class_install_property (object_class, PROP_EDITABLE,
g_param_spec_boolean ("editable",
_("Editable"),
/*_( */"XXX blurb" /*)*/,
@@ -501,7 +501,7 @@ e_contact_editor_address_set_property (GObject *object, guint prop_id,
EContactEditorAddress *e_contact_editor_address;
e_contact_editor_address = E_CONTACT_EDITOR_ADDRESS (object);
-
+
switch (prop_id){
case PROP_ADDRESS:
if (e_contact_editor_address->address)
diff --git a/addressbook/gui/contact-editor/e-contact-editor-fullname.c b/addressbook/gui/contact-editor/e-contact-editor-fullname.c
index daaffd01de..bca5f14499 100644
--- a/addressbook/gui/contact-editor/e-contact-editor-fullname.c
+++ b/addressbook/gui/contact-editor/e-contact-editor-fullname.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* eab-contact-editor-phones.c
* Copyright (C) 2003 Ximian, Inc.
* Author: Chris Toshok <toshok@ximian.com>
@@ -85,13 +85,13 @@ e_contact_editor_fullname_class_init (EContactEditorFullnameClass *klass)
object_class->get_property = e_contact_editor_fullname_get_property;
object_class->dispose = e_contact_editor_fullname_dispose;
- g_object_class_install_property (object_class, PROP_NAME,
+ g_object_class_install_property (object_class, PROP_NAME,
g_param_spec_pointer ("name",
_("Name"),
/*_( */"XXX blurb" /*)*/,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_EDITABLE,
+ g_object_class_install_property (object_class, PROP_EDITABLE,
g_param_spec_boolean ("editable",
_("Editable"),
/*_( */"XXX blurb" /*)*/,
@@ -157,7 +157,7 @@ e_contact_editor_fullname_dispose (GObject *object)
g_object_unref(e_contact_editor_fullname->gui);
e_contact_editor_fullname->gui = NULL;
}
-
+
if (e_contact_editor_fullname->name) {
e_contact_name_free(e_contact_editor_fullname->name);
e_contact_editor_fullname->name = NULL;
@@ -185,7 +185,7 @@ e_contact_editor_fullname_set_property (GObject *object, guint prop_id,
EContactEditorFullname *e_contact_editor_fullname;
e_contact_editor_fullname = E_CONTACT_EDITOR_FULLNAME (object);
-
+
switch (prop_id){
case PROP_NAME:
e_contact_name_free(e_contact_editor_fullname->name);
diff --git a/addressbook/gui/contact-editor/e-contact-editor-fullname.h b/addressbook/gui/contact-editor/e-contact-editor-fullname.h
index 01374f5c82..d0c9690d59 100644
--- a/addressbook/gui/contact-editor/e-contact-editor-fullname.h
+++ b/addressbook/gui/contact-editor/e-contact-editor-fullname.h
@@ -48,7 +48,7 @@ typedef struct _EContactEditorFullnameClass EContactEditorFullnameClass;
struct _EContactEditorFullname
{
GtkDialog parent;
-
+
/* item specific fields */
EContactName *name;
GladeXML *gui;
diff --git a/addressbook/gui/contact-editor/e-contact-editor-im.c b/addressbook/gui/contact-editor/e-contact-editor-im.c
index 93e6da7cae..9e8aa8d071 100644
--- a/addressbook/gui/contact-editor/e-contact-editor-im.c
+++ b/addressbook/gui/contact-editor/e-contact-editor-im.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-contact-editor-im.c
* Copyright (C) 2003 Ximian, Inc.
* Author: Christian Hammond <chipx86@gnupdate.org>
@@ -116,7 +116,7 @@ e_contact_editor_im_class_init (EContactEditorImClass *klass)
object_class->get_property = e_contact_editor_im_get_property;
object_class->dispose = e_contact_editor_im_dispose;
- g_object_class_install_property (object_class, PROP_SERVICE,
+ g_object_class_install_property (object_class, PROP_SERVICE,
g_param_spec_int ("service",
_("Service"),
/*_( */"XXX blurb" /*)*/,
@@ -125,21 +125,21 @@ e_contact_editor_im_class_init (EContactEditorImClass *klass)
FIRST_IM_TYPE,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_LOCATION,
+ g_object_class_install_property (object_class, PROP_LOCATION,
g_param_spec_string ("location",
_("Location"),
/*_( */"XXX blurb" /*)*/,
"HOME",
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_USERNAME,
+ g_object_class_install_property (object_class, PROP_USERNAME,
g_param_spec_string ("username",
_("Username"),
/*_( */"XXX blurb" /*)*/,
NULL,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_EDITABLE,
+ g_object_class_install_property (object_class, PROP_EDITABLE,
g_param_spec_boolean ("editable",
_("Editable"),
/*_( */"XXX blurb" /*)*/,
diff --git a/addressbook/gui/contact-editor/e-contact-editor-im.h b/addressbook/gui/contact-editor/e-contact-editor-im.h
index 56116f7501..9db0d03c80 100644
--- a/addressbook/gui/contact-editor/e-contact-editor-im.h
+++ b/addressbook/gui/contact-editor/e-contact-editor-im.h
@@ -50,7 +50,7 @@ typedef struct _EContactEditorImClass EContactEditorImClass;
struct _EContactEditorIm
{
GtkDialog parent;
-
+
/* item specific fields */
EContactField service;
char *location;
diff --git a/addressbook/gui/contact-editor/e-contact-editor.c b/addressbook/gui/contact-editor/e-contact-editor.c
index 91d9e7af66..b1b30f0c33 100644
--- a/addressbook/gui/contact-editor/e-contact-editor.c
+++ b/addressbook/gui/contact-editor/e-contact-editor.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-contact-editor.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -254,56 +254,56 @@ e_contact_editor_class_init (EContactEditorClass *klass)
editor_class->is_changed = e_contact_editor_is_changed;
editor_class->get_window = e_contact_editor_get_window;
- g_object_class_install_property (object_class, PROP_SOURCE_BOOK,
+ g_object_class_install_property (object_class, PROP_SOURCE_BOOK,
g_param_spec_object ("source_book",
_("Source Book"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_BOOK,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_TARGET_BOOK,
+ g_object_class_install_property (object_class, PROP_TARGET_BOOK,
g_param_spec_object ("target_book",
_("Target Book"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_BOOK,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_CONTACT,
+ g_object_class_install_property (object_class, PROP_CONTACT,
g_param_spec_object ("contact",
_("Contact"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_CONTACT,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_IS_NEW_CONTACT,
+ g_object_class_install_property (object_class, PROP_IS_NEW_CONTACT,
g_param_spec_boolean ("is_new_contact",
_("Is New Contact"),
/*_( */"XXX blurb" /*)*/,
FALSE,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_WRITABLE_FIELDS,
+ g_object_class_install_property (object_class, PROP_WRITABLE_FIELDS,
g_param_spec_object ("writable_fields",
_("Writable Fields"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_LIST,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_REQUIRED_FIELDS,
+ g_object_class_install_property (object_class, PROP_REQUIRED_FIELDS,
g_param_spec_object ("required_fields",
_("Required Fields"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_LIST,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_EDITABLE,
+ g_object_class_install_property (object_class, PROP_EDITABLE,
g_param_spec_boolean ("editable",
_("Editable"),
/*_( */"XXX blurb" /*)*/,
FALSE,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_CHANGED,
+ g_object_class_install_property (object_class, PROP_CHANGED,
g_param_spec_boolean ("changed",
_("Changed"),
/*_( */"XXX blurb" /*)*/,
@@ -359,7 +359,7 @@ style_makes_sense (const EContactName *name, const gchar *company, int style)
case 2:
if(name) {
if (name->additional && *name->additional)
- return TRUE;
+ return TRUE;
else
return FALSE;
}
@@ -384,7 +384,7 @@ name_to_style (const EContactName *name, const gchar *company, int style)
{
char *string;
char *strings[4], **stringptr;
- char *midstring[4], **midstrptr;
+ char *midstring[4], **midstrptr;
char *substring;
switch (style) {
case 0:
@@ -410,7 +410,7 @@ name_to_style (const EContactName *name, const gchar *company, int style)
string = g_strjoinv(" ", strings);
break;
case 2:
- midstrptr=midstring;
+ midstrptr=midstring;
if(name){
if (name->family && *name->family)
*(midstrptr++) = name->family;
@@ -426,7 +426,7 @@ name_to_style (const EContactName *name, const gchar *company, int style)
}
*stringptr = NULL;
string = g_strjoinv(" ", strings);
- break;
+ break;
case 3:
string = g_strdup(company);
break;
@@ -1363,13 +1363,13 @@ sensitize_phone (EContactEditor *editor)
static void
init_im_record_location (EContactEditor *editor, gint record)
{
-
+
#ifdef ENABLE_IM_LOCATION
GtkWidget *location_option_menu;
GtkWidget *location_menu;
gint i;
gchar *widget_name;
-
+
widget_name = g_strdup_printf ("optionmenu-im-location-%d", record);
location_option_menu = glade_xml_get_widget (editor->gui, widget_name);
g_free (widget_name);
@@ -1670,13 +1670,13 @@ static void
sensitize_im (EContactEditor *editor)
{
gint i;
- gboolean enabled;
+ gboolean enabled;
gboolean no_ims_supported;
-
+
enabled = editor->target_editable;
no_ims_supported = TRUE;
- for (i = 0; i < G_N_ELEMENTS (im_service); i++)
+ for (i = 0; i < G_N_ELEMENTS (im_service); i++)
if (is_field_supported (editor, im_service[i].field)) {
no_ims_supported = FALSE;
break;
@@ -1684,7 +1684,7 @@ sensitize_im (EContactEditor *editor)
if (no_ims_supported)
enabled = FALSE;
-
+
for (i = 1; i <= IM_SLOTS; i++) {
sensitize_im_record (editor, i, enabled);
}
@@ -1761,7 +1761,7 @@ fill_in_address_textview (EContactEditor *editor, gint record, EContactAddress *
} else {
gtk_text_buffer_insert (text_buffer, &iter_end, "", -1);
}
- gtk_text_buffer_get_iter_at_line (text_buffer, &iter_start, 0);
+ gtk_text_buffer_get_iter_at_line (text_buffer, &iter_start, 0);
gtk_text_buffer_place_cursor (text_buffer, &iter_start);
}
@@ -2025,7 +2025,7 @@ sensitize_address (EContactEditor *editor)
gboolean enabled = TRUE;
if (!editor->target_editable ||
- !(is_field_supported (editor, addresses [i]) ||
+ !(is_field_supported (editor, addresses [i]) ||
is_field_supported (editor, address_labels[i])))
enabled = FALSE;
@@ -2042,7 +2042,7 @@ typedef struct {
FieldMapping;
/* Table of widgets that interact with simple fields. This table is used to:
- *
+ *
* - Fill in data.
* - Extract data.
* - Set sensitivity based on backend capabilities.
@@ -2266,22 +2266,22 @@ extract_simple_field (EContactEditor *editor, GtkWidget *widget, gint field_id)
&img_buff, &photo.data.inlined.length)) {
GdkPixbuf *pixbuf, *new;
GdkPixbufLoader *loader = gdk_pixbuf_loader_new();
-
+
photo.data.inlined.data = (unsigned char *)img_buff;
img_buff = NULL;
gdk_pixbuf_loader_write (loader, photo.data.inlined.data, photo.data.inlined.length, NULL);
gdk_pixbuf_loader_close (loader, NULL);
-
+
pixbuf = gdk_pixbuf_loader_get_pixbuf (loader);
if (pixbuf) {
int width, height, prompt_response;
g_object_ref (pixbuf);
-
+
height = gdk_pixbuf_get_height (pixbuf);
width = gdk_pixbuf_get_width (pixbuf);
if ((height > 96 || width > 96)) {
-
+
prompt_response = e_error_run (GTK_WINDOW (editor->app), "addressbook:prompt-resize", NULL);
if (prompt_response == GTK_RESPONSE_YES){
@@ -2292,7 +2292,7 @@ extract_simple_field (EContactEditor *editor, GtkWidget *widget, gint field_id)
width = width *96 / height;
height = 96;
}
-
+
new = gdk_pixbuf_scale_simple (pixbuf, width, height, GDK_INTERP_BILINEAR);
if (new) {
GdkPixbufFormat *format = gdk_pixbuf_loader_get_format (loader);
@@ -2317,11 +2317,11 @@ extract_simple_field (EContactEditor *editor, GtkWidget *widget, gint field_id)
}
editor->image_changed = FALSE;
g_object_unref (loader);
-
+
e_contact_set (contact, field_id, &photo);
-
+
g_free (photo.data.inlined.data);
-
+
}
else {
editor->image_changed = FALSE;
@@ -2331,7 +2331,7 @@ extract_simple_field (EContactEditor *editor, GtkWidget *widget, gint field_id)
}
else if (GTK_IS_TOGGLE_BUTTON (widget)) {
gboolean val = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget));
-
+
e_contact_set (contact, field_id, val?(void *)1:NULL);
}
else {
@@ -2593,7 +2593,7 @@ full_name_response (GtkDialog *dialog, int response, EContactEditor *editor)
int style = 0;
gboolean editable = FALSE;
- g_object_get (dialog,
+ g_object_get (dialog,
"editable", &editable,
NULL);
@@ -2637,8 +2637,8 @@ full_name_clicked (GtkWidget *button, EContactEditor *editor)
{
GtkDialog *dialog = GTK_DIALOG (e_contact_editor_fullname_new (editor->name));
gboolean fullname_supported;
-
-
+
+
fullname_supported = is_field_supported (editor, E_CONTACT_FULL_NAME);
g_object_set (dialog,
@@ -2647,7 +2647,7 @@ full_name_clicked (GtkWidget *button, EContactEditor *editor)
g_signal_connect(dialog, "response",
G_CALLBACK (full_name_response), editor);
-
+
/* Close the fullname dialog if the editor is closed */
g_signal_connect_swapped (EAB_EDITOR (editor), "editor_closed",
G_CALLBACK (full_name_editor_delete_event_cb), GTK_WIDGET (dialog));
@@ -2661,7 +2661,7 @@ categories_response (GtkDialog *dialog, int response, EContactEditor *editor)
{
const char *categories;
GtkWidget *entry = glade_xml_get_widget(editor->gui, "entry-categories");
-
+
if (response == GTK_RESPONSE_OK) {
categories = e_categories_dialog_get_categories (E_CATEGORIES_DIALOG (dialog));
if (entry && GTK_IS_ENTRY(entry))
@@ -2704,14 +2704,14 @@ categories_clicked (GtkWidget *button, EContactEditor *editor)
g_free (categories);
return;
}
-
+
g_signal_connect(dialog, "response",
G_CALLBACK (categories_response), editor);
-
+
/* Close the category dialog if the editor is closed*/
g_signal_connect_swapped (EAB_EDITOR (editor), "editor_closed",
G_CALLBACK (categories_editor_delete_event_cb), GTK_WIDGET (dialog));
-
+
gtk_widget_show(GTK_WIDGET(dialog));
g_free (categories);
@@ -2789,7 +2789,7 @@ update_preview_cb (GtkFileChooser *file_chooser, gpointer data)
gtk_file_chooser_set_preview_widget_active (file_chooser, TRUE);
preview = GTK_WIDGET (data);
filename = gtk_file_chooser_get_preview_filename (file_chooser);
- if (filename == NULL)
+ if (filename == NULL)
return;
pixbuf = gdk_pixbuf_new_from_file_at_size (filename, 128, 128, NULL);
@@ -2984,7 +2984,7 @@ save_contact (EContactEditor *ce, gboolean should_close)
if (!ce->target_book)
return;
-
+
if (ce->target_editable && !e_book_is_writable (ce->source_book)) {
if (e_error_run (GTK_WINDOW (ce->app), "addressbook:prompt-move", NULL) == GTK_RESPONSE_NO)
@@ -2999,14 +2999,14 @@ save_contact (EContactEditor *ce, gboolean should_close)
company_name_string = gtk_entry_get_text (GTK_ENTRY (company_name));
if (strcmp (company_name_string , "")) {
- if (!strcmp (name_entry_string, ""))
+ if (!strcmp (name_entry_string, ""))
gtk_entry_set_text (GTK_ENTRY (entry_fullname), company_name_string);
if (!strcmp (file_as_entry_string, ""))
gtk_entry_set_text (GTK_ENTRY (entry_file_as), company_name_string);
}
extract_all (ce);
-
+
if (!e_contact_editor_is_valid (EAB_EDITOR (ce))) {
uid = e_contact_get (ce->contact, E_CONTACT_UID);
g_object_unref (ce->contact);
@@ -3017,7 +3017,7 @@ save_contact (EContactEditor *ce, gboolean should_close)
}
return;
}
-
+
real_save_contact (ce, should_close);
}
@@ -3060,11 +3060,11 @@ static const EContactField non_string_fields [] = {
E_CONTACT_CATEGORY_LIST,
E_CONTACT_BIRTH_DATE,
E_CONTACT_ANNIVERSARY
-
-
+
+
};
-static gboolean
+static gboolean
is_non_string_field (EContactField id)
{
int count = sizeof (non_string_fields) / sizeof (EContactField);
@@ -3075,7 +3075,7 @@ is_non_string_field (EContactField id)
return FALSE;
}
-
+
/* insert checks here (date format, for instance, etc.) */
static gboolean
@@ -3108,7 +3108,7 @@ e_contact_editor_is_valid (EABEditor *editor)
e_iterator_prev (iter)) {
const char *field_name = e_iterator_get (iter);
EContactField field_id = e_contact_field_id (field_name);
-
+
if (is_non_string_field (field_id)) {
if (e_contact_get_const (ce->contact, field_id) == NULL) {
g_string_append_printf (errmsg, _("%s'%s' is empty"),
@@ -3117,7 +3117,7 @@ e_contact_editor_is_valid (EABEditor *editor)
validation_error = TRUE;
break;
}
-
+
} else {
const char *text = e_contact_get_const (ce->contact, field_id);
@@ -3128,12 +3128,12 @@ e_contact_editor_is_valid (EABEditor *editor)
validation_error = TRUE;
break;
}
-
-
+
+
}
}
-
-
+
+
if (validation_error) {
g_string_append (errmsg, ".");
e_error_run (GTK_WINDOW (ce->app), "addressbook:generic-error",
@@ -3181,7 +3181,7 @@ static gint
app_delete_event_cb (GtkWidget *widget, GdkEvent *event, gpointer data)
{
EContactEditor *ce;
-
+
ce = E_CONTACT_EDITOR (data);
/* if we're saving, don't allow the dialog to close */
@@ -3411,7 +3411,7 @@ e_contact_editor_dispose (GObject *object)
g_object_unref(e_contact_editor->contact);
e_contact_editor->contact = NULL;
}
-
+
if (e_contact_editor->source_book) {
g_object_unref(e_contact_editor->source_book);
e_contact_editor->source_book = NULL;
@@ -3534,7 +3534,7 @@ e_contact_editor_set_property (GObject *object, guint prop_id, const GValue *val
EContactEditor *editor;
editor = E_CONTACT_EDITOR (object);
-
+
switch (prop_id){
case PROP_SOURCE_BOOK: {
gboolean writable;
@@ -3551,7 +3551,7 @@ e_contact_editor_set_property (GObject *object, guint prop_id, const GValue *val
editor->source_book = source_book;
g_object_ref (editor->source_book);
-
+
if (!editor->target_book) {
editor->target_book = editor->source_book;
g_object_ref (editor->target_book);
@@ -3672,7 +3672,7 @@ e_contact_editor_set_property (GObject *object, guint prop_id, const GValue *val
editor->required_fields = g_value_get_object (value);
if (editor->required_fields)
g_object_ref (editor->required_fields);
- else
+ else
editor->required_fields = e_list_new (NULL, NULL, NULL);
break;
default:
@@ -3804,7 +3804,7 @@ e_contact_editor_create_web(gchar *name,
if (a11y != NULL) {
atk_object_set_name (a11y, string1);
}
-
+
gtk_widget_show (widget);
return widget;
}
diff --git a/addressbook/gui/contact-editor/e-contact-editor.h b/addressbook/gui/contact-editor/e-contact-editor.h
index c93d57301f..10dd305347 100644
--- a/addressbook/gui/contact-editor/e-contact-editor.h
+++ b/addressbook/gui/contact-editor/e-contact-editor.h
@@ -57,7 +57,7 @@ typedef struct _EContactEditorClass EContactEditorClass;
struct _EContactEditor
{
EABEditor object;
-
+
/* item specific fields */
EBook *source_book;
EBook *target_book;
@@ -65,7 +65,7 @@ struct _EContactEditor
/* UI handler */
BonoboUIComponent *uic;
-
+
GladeXML *gui;
GtkWidget *app;
@@ -92,7 +92,7 @@ struct _EContactEditor
guint image_changed : 1;
EList *writable_fields;
-
+
EList *required_fields;
/* ID for async load_source call */
diff --git a/addressbook/gui/contact-editor/e-contact-quick-add.c b/addressbook/gui/contact-editor/e-contact-quick-add.c
index 1fc68734f0..5a89dea03d 100644
--- a/addressbook/gui/contact-editor/e-contact-quick-add.c
+++ b/addressbook/gui/contact-editor/e-contact-quick-add.c
@@ -12,12 +12,12 @@
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
@@ -133,7 +133,7 @@ merge_cb (EBook *book, EBookStatus status, gpointer closure)
if (qa->cb)
qa->cb (NULL, qa->closure);
}
-
+
quick_add_unref (qa);
}
@@ -157,7 +157,7 @@ contact_added_cb (EContactEditor *ce, EBookStatus status, EContact *contact, gpo
if (qa->cb)
qa->cb (qa->contact, qa->closure);
-
+
/* We don't need to unref qa because we set_data_full below */
g_object_set_data (G_OBJECT (ce), "quick_add", NULL);
}
@@ -257,7 +257,7 @@ clicked_cb (GtkWidget *w, gint button, gpointer closure)
quick_add_merge_contact (qa);
} else if (button == QUICK_ADD_RESPONSE_EDIT_FULL) {
-
+
/* EDIT FULL */
edit_contact (qa);
@@ -304,9 +304,9 @@ build_quick_add_dialog (QuickAdd *qa)
NULL);
gtk_widget_ensure_style (dialog);
- gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox),
+ gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (dialog)->vbox),
0);
- gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (dialog)->action_area),
+ gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (dialog)->action_area),
12);
g_signal_connect (dialog, "response", G_CALLBACK (clicked_cb), qa);
@@ -337,8 +337,8 @@ build_quick_add_dialog (QuickAdd *qa)
g_signal_connect (
qa->option_menu, "changed",
G_CALLBACK (source_changed), qa);
-
- g_object_unref (source_list);
+
+ g_object_unref (source_list);
table = GTK_TABLE (gtk_table_new (3, 2, FALSE));
gtk_table_set_row_spacings (table, 6);
@@ -377,13 +377,13 @@ build_quick_add_dialog (QuickAdd *qa)
1, 2, 2, 3,
GTK_EXPAND | GTK_FILL, 0, xpad, ypad);
- gtk_container_set_border_width (GTK_CONTAINER (table),
+ gtk_container_set_border_width (GTK_CONTAINER (table),
12);
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox),
GTK_WIDGET (table),
FALSE, FALSE, 0);
gtk_widget_show_all (GTK_WIDGET (table));
-
+
return dialog;
}
@@ -452,13 +452,13 @@ e_contact_quick_add_free_form (const gchar *text, EContactQuickAddCallback cb, g
in_quote = !in_quote;
}
-
+
if (last_at == NULL) {
/* No at sign, so we treat it all as the name */
name = g_strdup (text);
} else {
gboolean bad_char = FALSE;
-
+
/* walk backwards to whitespace or a < or a quote... */
while (last_at >= text && !bad_char
&& !(isspace ((gint) *last_at) || *last_at == '<' || *last_at == '"')) {
@@ -482,9 +482,9 @@ e_contact_quick_add_free_form (const gchar *text, EContactQuickAddCallback cb, g
}
/* If all else has failed, make it the name. */
- if (name == NULL && email == NULL)
+ if (name == NULL && email == NULL)
name = g_strdup (text);
-
+
/* Clean up email, remove bracketing <>s */
@@ -502,7 +502,7 @@ e_contact_quick_add_free_form (const gchar *text, EContactQuickAddCallback cb, g
if (changed)
g_strstrip (email);
}
-
+
e_contact_quick_add (name, email, cb, closure);
g_free (name);
diff --git a/addressbook/gui/contact-editor/e-contact-quick-add.h b/addressbook/gui/contact-editor/e-contact-quick-add.h
index ebc32ecdb1..cdb539b1b0 100644
--- a/addressbook/gui/contact-editor/e-contact-quick-add.h
+++ b/addressbook/gui/contact-editor/e-contact-quick-add.h
@@ -12,12 +12,12 @@
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
@@ -31,7 +31,7 @@
typedef void (*EContactQuickAddCallback) (EContact *new_contact, gpointer closure);
-void e_contact_quick_add (const gchar *name, const gchar *email,
+void e_contact_quick_add (const gchar *name, const gchar *email,
EContactQuickAddCallback cb, gpointer closure);
void e_contact_quick_add_free_form (const gchar *text, EContactQuickAddCallback cb, gpointer closure);
diff --git a/addressbook/gui/contact-editor/eab-editor.c b/addressbook/gui/contact-editor/eab-editor.c
index 5c9cd12678..b11c9af657 100644
--- a/addressbook/gui/contact-editor/eab-editor.c
+++ b/addressbook/gui/contact-editor/eab-editor.c
@@ -233,7 +233,7 @@ gboolean
eab_editor_is_valid (EABEditor *editor)
{
g_return_val_if_fail (EAB_IS_EDITOR (editor), FALSE);
-
+
if (EAB_EDITOR_GET_CLASS(editor)->is_valid)
return EAB_EDITOR_GET_CLASS(editor)->is_valid (editor);
else
@@ -244,17 +244,17 @@ GtkWindow*
eab_editor_get_window (EABEditor *editor)
{
g_return_val_if_fail (EAB_IS_EDITOR (editor), NULL);
-
+
if (EAB_EDITOR_GET_CLASS(editor)->get_window)
return EAB_EDITOR_GET_CLASS(editor)->get_window (editor);
else
return NULL;
}
/* This function prompts for saving if editor conents are in changed state and
- save or discards or cancels(just returns with out doing anything) according to user input.
- Editor gets destoryed in case of save and discard case.
+ save or discards or cancels(just returns with out doing anything) according to user input.
+ Editor gets destoryed in case of save and discard case.
*/
-
+
gboolean
eab_editor_prompt_to_save_changes (EABEditor *editor, GtkWindow *window)
{
@@ -319,13 +319,13 @@ eab_editor_confirm_delete (GtkWindow *parent, gboolean plural, gboolean is_list,
if (is_list) {
/* contact list(s) */
if (!plural)
- msg = g_strdup_printf (_("Are you sure you want\nto delete contact list (%s)?"),
+ msg = g_strdup_printf (_("Are you sure you want\nto delete contact list (%s)?"),
name?name:"");
else
msg = g_strdup (_("Are you sure you want\nto delete these contact lists?"));
}
else {
- /* contact(s) */
+ /* contact(s) */
if (!plural)
msg = g_strdup_printf (_("Are you sure you want\nto delete contact (%s)?"),
name?name:"");
diff --git a/addressbook/gui/contact-list-editor/e-contact-list-editor.c b/addressbook/gui/contact-list-editor/e-contact-list-editor.c
index 67b92c904a..85a7b507d5 100644
--- a/addressbook/gui/contact-list-editor/e-contact-list-editor.c
+++ b/addressbook/gui/contact-list-editor/e-contact-list-editor.c
@@ -162,28 +162,28 @@ e_contact_list_editor_class_init (EContactListEditorClass *klass)
object_class->get_property = e_contact_list_editor_get_property;
object_class->dispose = e_contact_list_editor_dispose;
- g_object_class_install_property (object_class, PROP_BOOK,
+ g_object_class_install_property (object_class, PROP_BOOK,
g_param_spec_object ("book",
_("Book"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_BOOK,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_CONTACT,
+ g_object_class_install_property (object_class, PROP_CONTACT,
g_param_spec_object ("contact",
_("Contact"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_CONTACT,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_IS_NEW_LIST,
+ g_object_class_install_property (object_class, PROP_IS_NEW_LIST,
g_param_spec_boolean ("is_new_list",
_("Is New List"),
/*_( */"XXX blurb" /*)*/,
FALSE,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_EDITABLE,
+ g_object_class_install_property (object_class, PROP_EDITABLE,
g_param_spec_boolean ("editable",
_("Editable"),
/*_( */"XXX blurb" /*)*/,
@@ -253,7 +253,7 @@ e_contact_list_editor_init (EContactListEditor *editor)
"changed", G_CALLBACK(list_name_changed_cb), editor);
g_signal_connect (editor->visible_addrs_checkbutton,
"toggled", G_CALLBACK(visible_addrs_toggled_cb), editor);
- g_signal_connect (editor->email_entry,
+ g_signal_connect (editor->email_entry,
"key-press-event", G_CALLBACK(email_key_pressed), editor);
e_table_drag_dest_set (e_table_scrolled_get_table (E_TABLE_SCROLLED (editor->table)),
@@ -270,7 +270,7 @@ e_contact_list_editor_init (EContactListEditor *editor)
"clicked", G_CALLBACK(save_and_close_cb), editor);
g_signal_connect (editor->cancel_button,
"clicked", G_CALLBACK(close_cb), editor);
-
+
g_signal_connect (editor->list_image,
"changed", G_CALLBACK(list_image_changed_cb), editor);
@@ -425,7 +425,7 @@ save_contact (EContactListEditor *cle, gboolean should_close)
if (cle->book) {
EditorCloseStruct *ecs = g_new(EditorCloseStruct, 1);
-
+
ecs->cle = cle;
g_object_ref (cle);
ecs->should_close = should_close;
@@ -539,7 +539,7 @@ e_contact_list_editor_set_property (GObject *object, guint prop_id,
EContactListEditor *editor;
editor = E_CONTACT_LIST_EDITOR (object);
-
+
switch (prop_id){
case PROP_BOOK: {
gboolean changed;
@@ -574,7 +574,7 @@ e_contact_list_editor_set_property (GObject *object, guint prop_id,
gboolean changed = (editor->is_new_list != new_value);
editor->is_new_list = new_value;
-
+
if (changed)
command_state_changed (editor);
break;
@@ -664,7 +664,7 @@ e_contact_list_editor_create_table(gchar *name,
gchar *string1, gchar *string2,
gint int1, gint int2)
{
-
+
ETableModel *model;
GtkWidget *table;
char *etspecfile;
@@ -685,8 +685,8 @@ e_contact_list_editor_create_table(gchar *name,
return table;
}
-static gboolean
-contact_already_exists (EContactListModel *model, const char *email)
+static gboolean
+contact_already_exists (EContactListModel *model, const char *email)
{
int row_count;
int row;
@@ -840,13 +840,13 @@ e_contact_list_editor_create_name_selector (gchar *name,
name_selector_model = e_name_selector_peek_model (name_selector);
e_name_selector_model_add_section (name_selector_model, "Members", "Members", NULL);
-
+
name_selector_entry = e_name_selector_peek_section_entry (name_selector, "Members");
e_name_selector_entry_set_contact_editor_func (name_selector_entry, e_contact_editor_new);
e_name_selector_entry_set_contact_list_editor_func (name_selector_entry, e_contact_list_editor_new);
gtk_widget_show (GTK_WIDGET (name_selector_entry));
-
+
return (GtkWidget *)name_selector_entry;
}
@@ -862,7 +862,7 @@ add_email_cb (GtkWidget *w, EContactListEditor *editor)
/* Skip to the end of the list */
if (adj->upper - adj->lower > adj->page_size)
gtk_adjustment_set_value (adj, adj->upper);
-
+
editor->changed = TRUE;
}
@@ -877,19 +877,19 @@ email_match_selected (GtkWidget *w, EDestination *destination, EContactListEdito
char *email;
EDestinationStore *store;
GtkAdjustment *adj = gtk_scrolled_window_get_vadjustment (GTK_SCROLLED_WINDOW (editor->table));
-
+
email = g_strdup(e_destination_get_address (destination));
store = e_name_selector_entry_peek_destination_store ((ENameSelectorEntry *)w);
e_destination_store_remove_destination (store, destination);
- gtk_entry_set_text (GTK_ENTRY(editor->email_entry), "");
-
+ gtk_entry_set_text (GTK_ENTRY(editor->email_entry), "");
+
if (email && *email) {
e_contact_list_model_add_email (E_CONTACT_LIST_MODEL(editor->model), email);
/* Skip to the end of the list */
if (adj->upper - adj->lower > adj->page_size)
gtk_adjustment_set_value (adj, adj->upper);
-
+
editor->changed = TRUE;
}
@@ -970,7 +970,7 @@ email_key_pressed (GtkWidget *w, GdkEventKey *event, EContactListEditor *editor)
if (event->keyval == GDK_comma || event->keyval == GDK_Return) {
ENameSelectorEntry *entry = (ENameSelectorEntry *)w;
-
+
g_signal_emit_by_name (entry, "activate", 0);
add_email_cb (w, editor);
@@ -1086,14 +1086,14 @@ table_drag_data_received_cb (ETable *table, int row, int col,
for (c = contact_list; c; c = c->next) {
EContact *contact = c->data;
- if (!e_contact_get (contact, E_CONTACT_IS_LIST)) {
+ if (!e_contact_get (contact, E_CONTACT_IS_LIST)) {
if (e_contact_get (contact, E_CONTACT_EMAIL_1)) {
if (! contact_already_exists (E_CONTACT_LIST_MODEL (editor->model)
, e_contact_get (contact, E_CONTACT_EMAIL_1))) {
e_contact_list_model_add_contact (E_CONTACT_LIST_MODEL (editor->model),
contact,
0 /* Hard-wired for default e-mail */);
-
+
changed = TRUE;
}
}
@@ -1252,7 +1252,7 @@ fill_in_info(EContactListEditor *editor)
if (name) e_destination_set_name (list_dest, name);
if (email) e_destination_set_email (list_dest, email);
e_destination_set_html_mail_pref (list_dest, html_pref);
-
+
e_contact_list_model_add_destination (E_CONTACT_LIST_MODEL (editor->model), list_dest);
}
@@ -1265,7 +1265,7 @@ fill_in_info(EContactListEditor *editor)
e_contact_photo_free (photo);
}
}
-
+
if (editor->book) {
e_source_combo_box_set_active (
E_SOURCE_COMBO_BOX (editor->source_menu),
diff --git a/addressbook/gui/contact-list-editor/e-contact-list-model.c b/addressbook/gui/contact-list-editor/e-contact-list-model.c
index d0597e9eea..767e461d87 100644
--- a/addressbook/gui/contact-list-editor/e-contact-list-model.c
+++ b/addressbook/gui/contact-list-editor/e-contact-list-model.c
@@ -208,9 +208,9 @@ e_contact_list_model_add_email (EContactListModel *model,
for (row = 0; row < row_count; row++) {
list_email = (char *) e_table_model_value_at (E_TABLE_MODEL (model), 1, row);
-
+
if (strcmp (list_email, email) == 0) {
- if (e_error_run (NULL, "addressbook:ask-list-add-exists",
+ if (e_error_run (NULL, "addressbook:ask-list-add-exists",
email) != GTK_RESPONSE_YES)
return;
break;
diff --git a/addressbook/gui/merging/eab-contact-compare.c b/addressbook/gui/merging/eab-contact-compare.c
index ff6e86eb6d..ae80059eaa 100644
--- a/addressbook/gui/merging/eab-contact-compare.c
+++ b/addressbook/gui/merging/eab-contact-compare.c
@@ -13,12 +13,12 @@
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
@@ -91,7 +91,7 @@ name_fragment_match_with_synonyms (const gchar *a, const gchar *b, gboolean stri
if (!(a && b && *a && *b))
return FALSE;
- if(!e_utf8_casefold_collate (a, b))
+ if(!e_utf8_casefold_collate (a, b))
return TRUE;
/* Check for nicknames. Yes, the linear search blows. */
@@ -100,7 +100,7 @@ name_fragment_match_with_synonyms (const gchar *a, const gchar *b, gboolean stri
if (!e_utf8_casefold_collate (name_synonyms[i][0], a)
&& !e_utf8_casefold_collate (name_synonyms[i][1], b))
return TRUE;
-
+
if (!e_utf8_casefold_collate (name_synonyms[i][0], b)
&& !e_utf8_casefold_collate (name_synonyms[i][1], a))
return TRUE;
@@ -165,7 +165,7 @@ eab_contact_compare_name_to_string_full (EContact *contact, const gchar *str, gb
++fragment_count;
for (i = 0; familyv && familyv[i]; ++i)
++fragment_count;
-
+
for (i = 0; namev[i] && this_part_match != EAB_CONTACT_MATCH_PART_NONE; ++i) {
if (*namev[i]) {
@@ -194,7 +194,7 @@ eab_contact_compare_name_to_string_full (EContact *contact, const gchar *str, gb
if (addv && this_part_match == EAB_CONTACT_MATCH_PART_NONE) {
for (j = 0; addv[j]; ++j) {
if (name_fragment_match_with_synonyms (addv[j], namev[i], allow_partial_matches)) {
-
+
this_part_match = EAB_CONTACT_MATCH_PART_ADDITIONAL_NAME;
g_free (addv[j]);
@@ -234,7 +234,7 @@ eab_contact_compare_name_to_string_full (EContact *contact, const gchar *str, gb
if (match_count > 0)
match_type = EAB_CONTACT_MATCH_VAGUE;
-
+
if (fragment_count == match_count) {
match_type = EAB_CONTACT_MATCH_EXACT;
@@ -434,8 +434,8 @@ match_email_hostname (const gchar *addr1, const gchar *addr2)
--addr2;
}
if((*addr1 == '@' && *addr2 != '@' ) || (*addr2 == '@' && *addr1 != '@'))
- return FALSE;
-
+ return FALSE;
+
return TRUE;
}
@@ -446,7 +446,7 @@ compare_email_addresses (const gchar *addr1, const gchar *addr2)
addr2 == NULL || *addr2 == 0)
return EAB_CONTACT_MATCH_NOT_APPLICABLE;
- if (match_email_username (addr1, addr2))
+ if (match_email_username (addr1, addr2))
return match_email_hostname (addr1, addr2) ? EAB_CONTACT_MATCH_EXACT : EAB_CONTACT_MATCH_VAGUE;
return EAB_CONTACT_MATCH_NONE;
@@ -487,7 +487,7 @@ eab_contact_compare_email (EContact *contact1, EContact *contact2)
char *addr2 = (char *) i2->data;
match = combine_comparisons (match, compare_email_addresses (addr1, addr2));
-
+
i2 = i2->next;
}
@@ -666,13 +666,13 @@ use_common_book_cb (EBook *book, gpointer closure)
if (contact_name->additional && *contact_name->additional)
query_parts[p++] = g_strdup_printf ("(contains \"full_name\" \"%s\")", contact_name->additional);
-
+
if (contact_name->family && *contact_name->family)
query_parts[p++] = g_strdup_printf ("(contains \"full_name\" \"%s\")", contact_name->family);
e_contact_name_free (contact_name);
}
-
+
contact_email = e_contact_get (contact, E_CONTACT_EMAIL);
if (contact_email) {
GList *iter;
@@ -695,8 +695,8 @@ use_common_book_cb (EBook *book, gpointer closure)
g_list_foreach (contact_email, (GFunc)g_free, NULL);
g_list_free (contact_email);
}
-
-
+
+
/* Build up our full query from the parts. */
query_parts[p] = NULL;
qj = g_strjoinv (" ", query_parts);
@@ -751,7 +751,7 @@ eab_contact_locate_match (EContact *contact, EABContactMatchQueryCallback cb, gp
* @avoid: A list of contacts to not match. These will not show up in the search.
* @cb: The function to call.
* @closure: The closure to add to the call.
- *
+ *
* Look for the best match and return it using the EABContactMatchQueryCallback.
**/
void
diff --git a/addressbook/gui/merging/eab-contact-compare.h b/addressbook/gui/merging/eab-contact-compare.h
index be835539e2..fe3891fab5 100644
--- a/addressbook/gui/merging/eab-contact-compare.h
+++ b/addressbook/gui/merging/eab-contact-compare.h
@@ -13,12 +13,12 @@
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
diff --git a/addressbook/gui/merging/eab-contact-merging.c b/addressbook/gui/merging/eab-contact-merging.c
index a37f877fd8..2f6955bb0f 100644
--- a/addressbook/gui/merging/eab-contact-merging.c
+++ b/addressbook/gui/merging/eab-contact-merging.c
@@ -190,7 +190,7 @@ mergeit (EContactMergingLookup *lookup)
dialog = (GtkDialog *)(gtk_dialog_new_with_buttons (_("Merge Contact"), NULL, GTK_DIALOG_NO_SEPARATOR, NULL));
gtk_container_border_width (GTK_CONTAINER(dialog), 5);
- scrolled_window = gtk_scrolled_window_new (NULL, NULL);
+ scrolled_window = gtk_scrolled_window_new (NULL, NULL);
gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolled_window),
GTK_POLICY_AUTOMATIC,
GTK_POLICY_AUTOMATIC);
@@ -218,7 +218,7 @@ mergeit (EContactMergingLookup *lookup)
if (string && *string) {
/*Four email id's present, should be compared with all email id's in duplicate contact */
/*Merge only if number of email id's in existing contact is less than 4 */
- if ((field == E_CONTACT_EMAIL_1 || field == E_CONTACT_EMAIL_2
+ if ((field == E_CONTACT_EMAIL_1 || field == E_CONTACT_EMAIL_2
|| field == E_CONTACT_EMAIL_3 || field == E_CONTACT_EMAIL_4) && (num_of_email < 4)) {
row++;
str = (char *)e_contact_get_const (lookup->contact, field);
@@ -237,7 +237,7 @@ mergeit (EContactMergingLookup *lookup)
continue;
case 2:
/*New contact has email and it is equal to neither of the 2 emails in the duplicate contact*/
- if((str && *str) &&
+ if((str && *str) &&
(g_ascii_strcasecmp(str,e_contact_get_const (lookup->match, E_CONTACT_EMAIL_1))) &&
(g_ascii_strcasecmp(e_contact_get_const (lookup->match, E_CONTACT_EMAIL_2),str))) {
field = E_CONTACT_EMAIL_3;
@@ -247,9 +247,9 @@ mergeit (EContactMergingLookup *lookup)
continue;
case 3:
/*New contact has email and it is equal to none of the 3 emails in the duplicate contact*/
- if((str && *str) &&
- (g_ascii_strcasecmp(e_contact_get_const (lookup->match, E_CONTACT_EMAIL_1),str)) &&
- (g_ascii_strcasecmp(e_contact_get_const (lookup->match, E_CONTACT_EMAIL_2),str)) &&
+ if((str && *str) &&
+ (g_ascii_strcasecmp(e_contact_get_const (lookup->match, E_CONTACT_EMAIL_1),str)) &&
+ (g_ascii_strcasecmp(e_contact_get_const (lookup->match, E_CONTACT_EMAIL_2),str)) &&
(g_ascii_strcasecmp(e_contact_get_const (lookup->match, E_CONTACT_EMAIL_3),str)))
field = E_CONTACT_EMAIL_4;
else
@@ -260,11 +260,11 @@ mergeit (EContactMergingLookup *lookup)
gtk_box_pack_start (GTK_BOX(hbox), (GtkWidget*)label, FALSE, FALSE, 0);
gtk_table_attach_defaults (table, (GtkWidget *)hbox, 0, 1, row, row + 1);
- dropdown = gtk_combo_box_new_text();
+ dropdown = gtk_combo_box_new_text();
gtk_combo_box_append_text (GTK_COMBO_BOX (dropdown), string);
data = g_new0 (dropdown_data, 1);
-
+
gtk_combo_box_append_text (GTK_COMBO_BOX (dropdown), "");
gtk_combo_box_set_active (GTK_COMBO_BOX (dropdown), 0);
@@ -291,26 +291,26 @@ mergeit (EContactMergingLookup *lookup)
gtk_box_pack_start (GTK_BOX(hbox), (GtkWidget*)label, FALSE, FALSE, 0);
gtk_table_attach_defaults (table, (GtkWidget*)hbox, 1, 2, row, row + 1);
continue;
- }
+ }
/*for all string fields except name and email*/
if(!(string1 && *string1) || (g_ascii_strcasecmp(string, string1))) {
row++;
label = gtk_label_new (e_contact_pretty_name(field));
- hbox = gtk_hbox_new (FALSE, 0);
+ hbox = gtk_hbox_new (FALSE, 0);
gtk_box_pack_start (GTK_BOX(hbox), (GtkWidget*)label, FALSE, FALSE, 0);
- gtk_table_attach_defaults (table, (GtkWidget *)hbox, 0, 1, row, row + 1);
+ gtk_table_attach_defaults (table, (GtkWidget *)hbox, 0, 1, row, row + 1);
data = g_new0 (dropdown_data, 1);
- dropdown = gtk_combo_box_new_text();
+ dropdown = gtk_combo_box_new_text();
gtk_combo_box_append_text (GTK_COMBO_BOX (dropdown), string);
e_contact_set (lookup->match, field, string);
if (string1 && *string1)
gtk_combo_box_append_text (GTK_COMBO_BOX (dropdown), string1);
- else
+ else
gtk_combo_box_append_text (GTK_COMBO_BOX (dropdown), "");
- gtk_combo_box_set_active (GTK_COMBO_BOX (dropdown), 0);
+ gtk_combo_box_set_active (GTK_COMBO_BOX (dropdown), 0);
data->field = field;
data->match = lookup->match;
@@ -322,20 +322,20 @@ mergeit (EContactMergingLookup *lookup)
gtk_box_pack_start (GTK_BOX(hbox), (GtkWidget*)dropdown, FALSE, FALSE, 0);
gtk_table_attach_defaults (table, (GtkWidget *)hbox, 1, 2, row, row + 1);
gtk_widget_show_all ((GtkWidget *)dropdown);
- }
+ }
}
}
gtk_window_set_default_size (GTK_WINDOW (dialog), 420, 300);
gtk_scrolled_window_add_with_viewport (GTK_SCROLLED_WINDOW (scrolled_window), GTK_WIDGET (table));
- gtk_box_pack_start (GTK_BOX (dialog->vbox), GTK_WIDGET (scrolled_window), TRUE, TRUE, 0);
- gtk_widget_show (scrolled_window);
- g_signal_connect (dialog, "map-event", G_CALLBACK (dialog_map), table);
+ gtk_box_pack_start (GTK_BOX (dialog->vbox), GTK_WIDGET (scrolled_window), TRUE, TRUE, 0);
+ gtk_widget_show (scrolled_window);
+ g_signal_connect (dialog, "map-event", G_CALLBACK (dialog_map), table);
gtk_widget_show_all ((GtkWidget *)table);
result = gtk_dialog_run (dialog);
switch (result)
- {
+ {
case GTK_RESPONSE_OK:
lookup->contact = lookup->match;
e_book_async_remove_contact (lookup->book, lookup->match, NULL, lookup);
@@ -344,7 +344,7 @@ mergeit (EContactMergingLookup *lookup)
break;
case GTK_RESPONSE_CANCEL:
value = 0;
- break;
+ break;
}
gtk_widget_destroy (GTK_WIDGET (dialog));
g_list_free (email_attr_list);
@@ -353,17 +353,17 @@ mergeit (EContactMergingLookup *lookup)
static gboolean
check_if_same (EContact *contact, EContact *match)
-{
+{
EContactField field;
GList *email_attr_list;
int num_of_email;
- char *str = NULL, *string = NULL, *string1 = NULL;
+ char *str = NULL, *string = NULL, *string1 = NULL;
for(field = E_CONTACT_FULL_NAME; field != (E_CONTACT_LAST_SIMPLE_STRING -1) ; field++) {
email_attr_list = e_contact_get_attributes (match, E_CONTACT_EMAIL);
num_of_email = g_list_length (email_attr_list);
- if ((field == E_CONTACT_EMAIL_1 || field == E_CONTACT_EMAIL_2
+ if ((field == E_CONTACT_EMAIL_1 || field == E_CONTACT_EMAIL_2
|| field == E_CONTACT_EMAIL_3 || field == E_CONTACT_EMAIL_4) && (num_of_email<4)) {
str = (char *)e_contact_get_const (contact, field);
switch(num_of_email)
@@ -374,17 +374,17 @@ check_if_same (EContact *contact, EContact *match)
if((str && *str) && (g_ascii_strcasecmp(e_contact_get_const (match, E_CONTACT_EMAIL_1),str)))
return FALSE;
case 2:
- if((str && *str) && (g_ascii_strcasecmp(str,e_contact_get_const (match, E_CONTACT_EMAIL_1))) &&
+ if((str && *str) && (g_ascii_strcasecmp(str,e_contact_get_const (match, E_CONTACT_EMAIL_1))) &&
(g_ascii_strcasecmp(e_contact_get_const (match, E_CONTACT_EMAIL_2),str)))
return FALSE;
case 3:
- if((str && *str) && (g_ascii_strcasecmp(e_contact_get_const (match, E_CONTACT_EMAIL_1),str)) &&
+ if((str && *str) && (g_ascii_strcasecmp(e_contact_get_const (match, E_CONTACT_EMAIL_1),str)) &&
(g_ascii_strcasecmp(e_contact_get_const (match, E_CONTACT_EMAIL_2),str)) &&
(g_ascii_strcasecmp(e_contact_get_const (match, E_CONTACT_EMAIL_3),str)))
return FALSE;
}
}
- else {
+ else {
string = (char *)e_contact_get_const (contact, field);
string1 = (char *)e_contact_get_const (match, field);
if ((string && *string) && (string1 && *string1) && (g_ascii_strcasecmp(string1,string)))
diff --git a/addressbook/gui/widgets/e-addressbook-model.c b/addressbook/gui/widgets/e-addressbook-model.c
index dae9c68745..ae553ad4e6 100644
--- a/addressbook/gui/widgets/e-addressbook-model.c
+++ b/addressbook/gui/widgets/e-addressbook-model.c
@@ -342,7 +342,7 @@ eab_model_class_init (GObjectClass *object_class)
NULL, NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
-
+
eab_model_signals [SEARCH_RESULT] =
g_signal_new ("search_result",
G_OBJECT_CLASS_TYPE (object_class),
@@ -351,7 +351,7 @@ eab_model_class_init (GObjectClass *object_class)
NULL, NULL,
g_cclosure_marshal_VOID__INT,
G_TYPE_NONE, 1, G_TYPE_INT);
-
+
eab_model_signals [FOLDER_BAR_MESSAGE] =
g_signal_new ("folder_bar_message",
G_OBJECT_CLASS_TYPE (object_class),
@@ -554,7 +554,7 @@ eab_model_set_property (GObject *object, guint prop_id, const GValue *value, GPa
gboolean need_get_book_view = FALSE;
model = EAB_MODEL (object);
-
+
switch (prop_id){
case PROP_BOOK:
if (model->book) {
@@ -673,7 +673,7 @@ eab_model_new (void)
EABModel *et;
et = g_object_new (EAB_TYPE_MODEL, NULL);
-
+
return et;
}
diff --git a/addressbook/gui/widgets/e-addressbook-reflow-adapter.c b/addressbook/gui/widgets/e-addressbook-reflow-adapter.c
index 29a9ed35af..06caebedee 100644
--- a/addressbook/gui/widgets/e-addressbook-reflow-adapter.c
+++ b/addressbook/gui/widgets/e-addressbook-reflow-adapter.c
@@ -232,7 +232,7 @@ addressbook_incarnate (EReflowModel *erm, int i, GnomeCanvasGroup *parent)
g_signal_connect (item, "drag_begin",
G_CALLBACK(adapter_drag_begin), adapter);
-
+
return item;
}
@@ -264,12 +264,12 @@ remove_contacts (EABModel *model,
{
GArray *indices = (GArray *) data;
int count = indices->len;
-
+
if (count == 1)
e_reflow_model_item_removed (E_REFLOW_MODEL (adapter), g_array_index (indices, gint, 0));
- else
+ else
e_reflow_model_changed (E_REFLOW_MODEL (adapter));
-
+
}
static void
@@ -378,7 +378,7 @@ e_addressbook_reflow_adapter_class_init (GObjectClass *object_class)
object_class->get_property = addressbook_get_property;
object_class->dispose = addressbook_dispose;
- g_object_class_install_property (object_class, PROP_BOOK,
+ g_object_class_install_property (object_class, PROP_BOOK,
g_param_spec_object ("book",
_("Book"),
/*_( */"XXX blurb" /*)*/,
diff --git a/addressbook/gui/widgets/e-addressbook-table-adapter.c b/addressbook/gui/widgets/e-addressbook-table-adapter.c
index 65a82d03c9..b208952245 100644
--- a/addressbook/gui/widgets/e-addressbook-table-adapter.c
+++ b/addressbook/gui/widgets/e-addressbook-table-adapter.c
@@ -152,7 +152,7 @@ addressbook_is_cell_editable (ETableModel *etc, int col, int row)
else if (contact && e_contact_get ((EContact *) contact, E_CONTACT_IS_LIST))
/* we only allow editing of the name and file as for
lists */
- return col == E_CONTACT_FULL_NAME || col == E_CONTACT_FILE_AS;
+ return col == E_CONTACT_FULL_NAME || col == E_CONTACT_FILE_AS;
else
return col < E_CONTACT_LAST_SIMPLE_STRING;
#endif
@@ -265,10 +265,10 @@ remove_contacts (EABModel *model,
{
GArray *indices = (GArray *) data;
int count = indices->len;
-
-
+
+
e_table_model_pre_change (E_TABLE_MODEL (adapter));
- if (count == 1)
+ if (count == 1)
e_table_model_rows_deleted (E_TABLE_MODEL (adapter), g_array_index (indices, gint, 0), 1);
else
e_table_model_changed (E_TABLE_MODEL (adapter));
diff --git a/addressbook/gui/widgets/e-addressbook-view.c b/addressbook/gui/widgets/e-addressbook-view.c
index 483b3b4162..b591389d7c 100644
--- a/addressbook/gui/widgets/e-addressbook-view.c
+++ b/addressbook/gui/widgets/e-addressbook-view.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-addressbook-view.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -212,32 +212,32 @@ eab_view_class_init (EABViewClass *klass)
object_class->get_property = eab_view_get_property;
object_class->dispose = eab_view_dispose;
- g_object_class_install_property (object_class, PROP_BOOK,
+ g_object_class_install_property (object_class, PROP_BOOK,
g_param_spec_object ("book",
_("Book"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_BOOK,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_SOURCE,
+ g_object_class_install_property (object_class, PROP_SOURCE,
g_param_spec_object ("source",
_("Source"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_SOURCE,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_QUERY,
+ g_object_class_install_property (object_class, PROP_QUERY,
g_param_spec_string ("query",
_("Query"),
/*_( */"XXX blurb" /*)*/,
NULL,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_TYPE,
+ g_object_class_install_property (object_class, PROP_TYPE,
g_param_spec_int ("type",
_("Type"),
/*_( */"XXX blurb" /*)*/,
- EAB_VIEW_NONE,
+ EAB_VIEW_NONE,
EAB_VIEW_TABLE,
EAB_VIEW_NONE,
G_PARAM_READWRITE));
@@ -361,7 +361,7 @@ eab_view_dispose (GObject *object)
gtk_widget_destroy (eav->invisible);
eav->invisible = NULL;
}
-
+
/*
if (eav->search_context) {
g_object_unref (eav->search_context);
@@ -450,13 +450,13 @@ eab_view_new (void)
rule_context_add_part, rule_context_next_part);
rule_context_add_rule_set (eav->search_context, "ruleset", filter_rule_get_type (),
rule_context_add_rule, rule_context_next_rule);
-
+
userfile = g_build_filename ( g_get_home_dir (), ".evolution/addressbook/searches.xml", NULL);
xmlfile = g_build_filename (SEARCH_RULE_DIR, "addresstypes.xml", NULL);
-
+
g_object_set_data_full (G_OBJECT (eav->search_context), "user", userfile, g_free);
g_object_set_data_full (G_OBJECT (eav->search_context), "system", xmlfile, g_free);
-
+
rule_context_load (eav->search_context, xmlfile, userfile);
eav->search_rule = filter_rule_new ();
@@ -468,7 +468,7 @@ eab_view_new (void)
filter_rule_add_part (eav->search_rule, filter_part_clone (part));
eav->search = e_filter_bar_new (eav->search_context, xmlfile, userfile, NULL, eav);
-
+
g_free (xmlfile);
g_free (userfile);
@@ -508,9 +508,9 @@ eab_view_new (void)
clipboard_atom,
GDK_SELECTION_TYPE_STRING,
0);
-
+
g_signal_connect (eav->invisible, "selection_get",
- G_CALLBACK (selection_get),
+ G_CALLBACK (selection_get),
eav);
g_signal_connect (eav->invisible, "selection_clear_event",
G_CALLBACK (selection_clear_event),
@@ -604,7 +604,7 @@ set_view_preview (EABView *view)
state ? "1" : "0", NULL);
eab_view_show_contact_preview (view, state);
-
+
g_object_unref (gconf_client);
}
@@ -1005,7 +1005,7 @@ do_popup_menu(EABView *view, GdkEvent *event)
contact_and_book->closure = cards;
e_selection_model_foreach(selection_model, get_card_1, contact_and_book);
}
-
+
/** @HookPoint-EABPopup:Addressbook view Context Menu
* @Id: org.gnome.evolution.addressbook.view.popup
* @Class: org.gnome.evolution.addresbook.popup:1.0
@@ -1055,7 +1055,7 @@ selection_changed (GObject *o, EABView *view)
eab_contact_display_render (EAB_CONTACT_DISPLAY (view->contact_display), NULL,
EAB_CONTACT_DISPLAY_RENDER_NORMAL);
}
-
+
}
static void
@@ -1069,7 +1069,7 @@ table_double_click(ETableScrolled *table, gint row, gint col, GdkEvent *event, E
g_object_get(model,
"book", &book,
NULL);
-
+
g_return_if_fail (E_IS_BOOK (book));
if (e_contact_get (contact, E_CONTACT_IS_LIST))
@@ -1228,10 +1228,10 @@ contacts_removed (EABModel *model, gpointer data, EABView *eav)
gint i;
for (i = 0; i < count; i ++) {
-
-
+
+
if (eav->displayed_contact == g_array_index (indices, gint, i)) {
-
+
/* if the contact that's presently displayed is changed, clear the display */
eab_contact_display_render (EAB_CONTACT_DISPLAY (eav->contact_display), NULL,
EAB_CONTACT_DISPLAY_RENDER_NORMAL);
@@ -1288,7 +1288,7 @@ create_table_view (EABView *view)
ETableModel *adapter;
GtkWidget *table;
char *etspecfile;
-
+
adapter = eab_table_adapter_new(view->model);
/* Here we create the table. We give it the three pieces of
@@ -1315,7 +1315,7 @@ create_table_view (EABView *view)
/* drag & drop signals */
e_table_drag_source_set (E_TABLE(E_TABLE_SCROLLED(table)->table), GDK_BUTTON1_MASK,
drag_types, num_drag_types, GDK_ACTION_MOVE | GDK_ACTION_COPY);
-
+
g_signal_connect (E_TABLE_SCROLLED(table)->table,
"table_drag_data_get",
G_CALLBACK (table_drag_data_get),
@@ -1396,14 +1396,14 @@ search_activated (ESearchBar *esb, EABView *v)
}
g_string_free (s, TRUE);
- } else
+ } else
search_query = g_strdup ("(contains \"x-evolution-any-field\" \"\")");
/* Merge view and sexp */
subid = e_search_bar_get_viewitem_id (esb);
if (subid) {
- master_list = get_master_list ();
+ master_list = get_master_list ();
category_name = g_list_nth_data (master_list, subid-1);
view_sexp = g_strdup_printf ("(is \"category_list\" \"%s\")", category_name);
search_query = g_strconcat ("(and ", view_sexp, search_query, ")", NULL);
@@ -1460,7 +1460,7 @@ compare_subitems (const void *a, const void *b)
g_free (collate_a);
g_free (collate_b);
-
+
return ret;
}
@@ -1502,7 +1502,7 @@ make_suboptions (EABView *view)
GList *master_list;
gint i, N;
GtkWidget *menu;
-
+
master_list = get_master_list ();
N = g_list_length (master_list);
subitems = g_new (EABSearchBarItem, N+2);
@@ -1521,7 +1521,7 @@ make_suboptions (EABView *view)
subitems[N+1].search.id = -1;
subitems[N+1].search.text = NULL;
subitems[N+1].image = NULL;
-
+
qsort (subitems + 1, N, sizeof (subitems[0]), compare_subitems);
menu = generate_viewoption_menu (subitems);
e_search_bar_set_viewoption_menu ((ESearchBar *)view->search, menu);
@@ -1620,7 +1620,7 @@ eab_view_setup_menus (EABView *view,
/**
* eab_view_discard_menus:
* @view: An addressbook view.
- *
+ *
* Makes an addressbook view discard its GAL view menus and its views instance
* objects. This should be called when the corresponding Bonobo component is
* deactivated.
@@ -1688,8 +1688,8 @@ eab_view_print (EABView *view, GtkPrintOperationAction action)
}
}
-/* callback function to handle removal of contacts for
- * which a user doesnt have write permission
+/* callback function to handle removal of contacts for
+ * which a user doesnt have write permission
*/
static void delete_contacts_cb (EBook *book, EBookStatus status, gpointer closure)
{
@@ -1715,10 +1715,10 @@ eab_view_delete_selection(EABView *view, gboolean is_delete)
EContact *contact;
ETable *etable = NULL;
EMinicardView *card_view;
- ESelectionModel *selection_model = NULL;
+ ESelectionModel *selection_model = NULL;
char *name = NULL;
gint row = 0, select;
-
+
list = get_selected_contacts (view);
contact = list->data;
@@ -1738,11 +1738,11 @@ eab_view_delete_selection(EABView *view, gboolean is_delete)
else if (view->view_type == EAB_VIEW_TABLE) {
etable = e_table_scrolled_get_table(E_TABLE_SCROLLED(view->widget));
- row = e_table_get_cursor_row (E_TABLE (etable));
+ row = e_table_get_cursor_row (E_TABLE (etable));
}
/* confirm delete */
- if (is_delete &&
+ if (is_delete &&
!eab_editor_confirm_delete(GTK_WINDOW(gtk_widget_get_toplevel(view->widget)),
plural, is_list, name)) {
g_free (name);
@@ -1765,7 +1765,7 @@ eab_view_delete_selection(EABView *view, gboolean is_delete)
ids,
delete_contacts_cb,
NULL);
-
+
g_list_free (ids);
}
else {
@@ -1778,14 +1778,14 @@ eab_view_delete_selection(EABView *view, gboolean is_delete)
NULL);
}
}
-
+
/* Sets the cursor, at the row after the deleted row */
- if (view->view_type == EAB_VIEW_MINICARD && row!=0) {
+ if (view->view_type == EAB_VIEW_MINICARD && row!=0) {
select = e_sorter_model_to_sorted (selection_model->sorter, row);
/* Sets the cursor, before the deleted row if its the last row */
if (select == e_selection_model_row_count (selection_model) - 1)
- select = select - 1;
+ select = select - 1;
else
select = select + 1;
@@ -1795,12 +1795,12 @@ eab_view_delete_selection(EABView *view, gboolean is_delete)
/* Sets the cursor, at the row after the deleted row */
else if (view->view_type == EAB_VIEW_TABLE && row!=0) {
- select = e_table_model_to_view_row (E_TABLE (etable), row);
-
+ select = e_table_model_to_view_row (E_TABLE (etable), row);
+
/* Sets the cursor, before the deleted row if its the last row */
if (select == e_table_model_row_count (E_TABLE(etable)->model) - 1)
select = select - 1;
- else
+ else
select = select + 1;
row = e_table_view_to_model_row (E_TABLE (etable), select);
@@ -1864,7 +1864,7 @@ selection_received (GtkWidget *invisible,
contact_list = eab_contact_list_from_string (str);
} else
contact_list = eab_contact_list_from_string ((char *)selection_data->data);
-
+
for (l = contact_list; l; l = l->next) {
EContact *contact = l->data;
@@ -1907,15 +1907,15 @@ eab_view_save_as (EABView *view, gboolean all)
{
GList *list = NULL;
EBook *book ;
-
- g_object_get(view->model,
+
+ g_object_get(view->model,
"book", &book,
NULL);
if (all) {
EBookQuery *query = e_book_query_any_field_contains("");
e_book_get_contacts(book, query, &list, NULL);
- e_book_query_unref(query);
+ e_book_query_unref(query);
}
else {
list = get_selected_contacts(view);
@@ -1987,7 +1987,7 @@ eab_view_copy (EABView *view)
{
gtk_html_copy (GTK_HTML (view->contact_display));
}
- else
+ else
{
view->clipboard_contacts = get_selected_contacts (view);
@@ -2035,14 +2035,14 @@ view_transfer_contacts (EABView *view, gboolean delete_from_source, gboolean all
GList *contacts = NULL;
GtkWindow *parent_window;
- g_object_get(view->model,
+ g_object_get(view->model,
"book", &book,
NULL);
if (all) {
EBookQuery *query = e_book_query_any_field_contains("");
e_book_get_contacts(book, query, &contacts, NULL);
- e_book_query_unref(query);
+ e_book_query_unref(query);
}
else {
contacts = get_selected_contacts (view);
@@ -2102,13 +2102,13 @@ eab_view_can_view (EABView *view)
return view ? eab_view_selection_nonempty (view) : FALSE;
}
-gboolean
+gboolean
eab_view_can_send (EABView *view)
{
return view ? eab_view_selection_nonempty (view) : FALSE;
}
-gboolean
+gboolean
eab_view_can_send_to (EABView *view)
{
return view ? eab_view_selection_nonempty (view) : FALSE;
diff --git a/addressbook/gui/widgets/e-addressbook-view.h b/addressbook/gui/widgets/e-addressbook-view.h
index 14f16c82f4..3ba45d6302 100644
--- a/addressbook/gui/widgets/e-addressbook-view.h
+++ b/addressbook/gui/widgets/e-addressbook-view.h
@@ -62,7 +62,7 @@ typedef struct _EABViewClass EABViewClass;
struct _EABView
{
GtkVBox parent;
-
+
/* item specific fields */
EABViewType view_type;
diff --git a/addressbook/gui/widgets/e-minicard-label.c b/addressbook/gui/widgets/e-minicard-label.c
index 1d4bf307c9..ab6e5471de 100644
--- a/addressbook/gui/widgets/e-minicard-label.c
+++ b/addressbook/gui/widgets/e-minicard-label.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-minicard-label.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -203,7 +203,7 @@ e_minicard_label_set_property (GObject *object, guint prop_id, const GValue *va
GnomeCanvasItem *item;
e_minicard_label = E_MINICARD_LABEL (object);
- item = GNOME_CANVAS_ITEM (object);
+ item = GNOME_CANVAS_ITEM (object);
switch (prop_id){
case PROP_WIDTH:
@@ -344,7 +344,7 @@ static gboolean
e_minicard_label_event (GnomeCanvasItem *item, GdkEvent *event)
{
EMinicardLabel *e_minicard_label;
-
+
e_minicard_label = E_MINICARD_LABEL (item);
switch( event->type ) {
@@ -371,7 +371,7 @@ e_minicard_label_event (GnomeCanvasItem *item, GdkEvent *event)
break;
}
case GDK_BUTTON_PRESS:
- case GDK_BUTTON_RELEASE:
+ case GDK_BUTTON_RELEASE:
case GDK_MOTION_NOTIFY:
case GDK_ENTER_NOTIFY:
case GDK_LEAVE_NOTIFY: {
@@ -382,7 +382,7 @@ e_minicard_label_event (GnomeCanvasItem *item, GdkEvent *event)
default:
break;
}
-
+
if (GNOME_CANVAS_ITEM_CLASS( parent_class )->event)
return (* GNOME_CANVAS_ITEM_CLASS( parent_class )->event) (item, event);
else
@@ -413,7 +413,7 @@ set_colors (EMinicardLabel *label)
GtkWidget *canvas = GTK_WIDGET (GNOME_CANVAS_ITEM (label)->canvas);
GtkStyle *style = gtk_widget_get_style (canvas);
if (label->has_focus) {
- gnome_canvas_item_set (label->rect,
+ gnome_canvas_item_set (label->rect,
"outline_color_gdk", &style->mid[GTK_STATE_SELECTED],
"fill_color_gdk", &style->bg[GTK_STATE_NORMAL],
NULL);
@@ -453,21 +453,21 @@ static void
e_minicard_label_reflow(GnomeCanvasItem *item, int flags)
{
EMinicardLabel *e_minicard_label = E_MINICARD_LABEL(item);
-
+
gint old_height;
gdouble text_height;
gdouble left_width;
old_height = e_minicard_label->height;
- g_object_get(e_minicard_label->fieldname,
+ g_object_get(e_minicard_label->fieldname,
"text_height", &text_height,
NULL);
e_minicard_label->height = text_height;
- g_object_get(e_minicard_label->field,
+ g_object_get(e_minicard_label->field,
"text_height", &text_height,
NULL);
diff --git a/addressbook/gui/widgets/e-minicard-label.h b/addressbook/gui/widgets/e-minicard-label.h
index 30e1a274e7..1b64d6874b 100644
--- a/addressbook/gui/widgets/e-minicard-label.h
+++ b/addressbook/gui/widgets/e-minicard-label.h
@@ -53,7 +53,7 @@ typedef struct _EMinicardLabelClass EMinicardLabelClass;
struct _EMinicardLabel
{
GnomeCanvasGroup parent;
-
+
/* item specific fields */
double width;
double height;
diff --git a/addressbook/gui/widgets/e-minicard-view-widget.c b/addressbook/gui/widgets/e-minicard-view-widget.c
index 7f4c84d0fd..5c1693dea2 100644
--- a/addressbook/gui/widgets/e-minicard-view-widget.c
+++ b/addressbook/gui/widgets/e-minicard-view-widget.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-minicard-view-widget.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -102,28 +102,28 @@ e_minicard_view_widget_class_init (EMinicardViewWidgetClass *klass)
object_class->get_property = e_minicard_view_widget_get_property;
object_class->dispose = e_minicard_view_widget_dispose;
- g_object_class_install_property (object_class, PROP_BOOK,
+ g_object_class_install_property (object_class, PROP_BOOK,
g_param_spec_object ("book",
_("Book"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_BOOK,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_QUERY,
+ g_object_class_install_property (object_class, PROP_QUERY,
g_param_spec_string ("query",
_("Query"),
/*_( */"XXX blurb" /*)*/,
NULL,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_EDITABLE,
+ g_object_class_install_property (object_class, PROP_EDITABLE,
g_param_spec_boolean ("editable",
_("Editable"),
/*_( */"XXX blurb" /*)*/,
FALSE,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_COLUMN_WIDTH,
+ g_object_class_install_property (object_class, PROP_COLUMN_WIDTH,
g_param_spec_double ("column_width",
_("Column Width"),
/*_( */"XXX blurb" /*)*/,
@@ -390,7 +390,7 @@ e_minicard_view_widget_size_allocate(GtkWidget *widget, GtkAllocation *allocatio
{
if (GTK_WIDGET_CLASS(parent_class)->size_allocate)
GTK_WIDGET_CLASS(parent_class)->size_allocate (widget, allocation);
-
+
if (GTK_WIDGET_REALIZED(widget)) {
double width;
EMinicardViewWidget *view = E_MINICARD_VIEW_WIDGET(widget);
@@ -443,7 +443,7 @@ e_minicard_view_widget_get_view (EMinicardViewWidget *view)
return NULL;
}
-static gboolean
+static gboolean
e_minicard_view_widget_real_focus_in_event(GtkWidget *widget, GdkEventFocus *event)
{
GnomeCanvas *canvas;
diff --git a/addressbook/gui/widgets/e-minicard-view.c b/addressbook/gui/widgets/e-minicard-view.c
index 2b271629b1..772798432f 100644
--- a/addressbook/gui/widgets/e-minicard-view.c
+++ b/addressbook/gui/widgets/e-minicard-view.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-minicard-view.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -88,7 +88,7 @@ e_minicard_view_drag_data_get(GtkWidget *widget,
switch (info) {
case DND_TARGET_TYPE_VCARD_LIST: {
char *value;
-
+
value = eab_contact_list_to_string (view->drag_list);
gtk_selection_data_set (selection_data,
@@ -101,7 +101,7 @@ e_minicard_view_drag_data_get(GtkWidget *widget,
case DND_TARGET_TYPE_SOURCE_VCARD_LIST: {
EBook *book;
char *value;
-
+
g_object_get (view->adapter, "book", &book, NULL);
value = eab_book_and_contact_list_to_string (book, view->drag_list);
@@ -131,7 +131,7 @@ e_minicard_view_drag_begin (EAddressbookReflowAdapter *adapter, GdkEvent *event,
GdkDragAction actions = GDK_ACTION_MOVE | GDK_ACTION_COPY;
clear_drag_data (view);
-
+
view->drag_list = e_minicard_view_get_card_list (view);
g_print ("dragging %d card(s)\n", g_list_length (view->drag_list));
@@ -213,7 +213,7 @@ e_minicard_view_set_property (GObject *object,
EMinicardView *view;
view = E_MINICARD_VIEW (object);
-
+
switch (prop_id){
case PROP_ADAPTER:
if (view->adapter) {
@@ -246,7 +246,7 @@ e_minicard_view_set_property (GObject *object,
g_signal_connect (model, "writable_status",
G_CALLBACK (writable_status_change), view);
}
-
+
}
break;
case PROP_BOOK:
@@ -350,7 +350,7 @@ static gboolean
e_minicard_view_event (GnomeCanvasItem *item, GdkEvent *event)
{
EMinicardView *view;
-
+
view = E_MINICARD_VIEW (item);
switch( event->type ) {
@@ -359,11 +359,11 @@ e_minicard_view_event (GnomeCanvasItem *item, GdkEvent *event)
gboolean editable;
g_object_get(view->adapter, "editable", &editable, NULL);
-
+
if (editable) {
EBook *book;
g_object_get(view, "book", &book, NULL);
-
+
if (book && E_IS_BOOK (book))
eab_show_contact_editor (book, e_contact_new(), TRUE, editable);
}
@@ -485,39 +485,39 @@ e_minicard_view_class_init (EMinicardViewClass *klass)
GObjectClass *object_class;
GnomeCanvasItemClass *item_class;
EReflowClass *reflow_class;
-
+
object_class = G_OBJECT_CLASS (klass);
item_class = (GnomeCanvasItemClass *) klass;
reflow_class = (EReflowClass *) klass;
-
+
parent_class = g_type_class_peek_parent (klass);
-
+
object_class->set_property = e_minicard_view_set_property;
object_class->get_property = e_minicard_view_get_property;
object_class->dispose = e_minicard_view_dispose;
- g_object_class_install_property (object_class, PROP_ADAPTER,
+ g_object_class_install_property (object_class, PROP_ADAPTER,
g_param_spec_object ("adapter",
_("Adapter"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_ADDRESSBOOK_REFLOW_ADAPTER,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_BOOK,
+ g_object_class_install_property (object_class, PROP_BOOK,
g_param_spec_object ("book",
_("Book"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_BOOK,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_QUERY,
+ g_object_class_install_property (object_class, PROP_QUERY,
g_param_spec_string ("query",
_("Query"),
/*_( */"XXX blurb" /*)*/,
NULL,
G_PARAM_READWRITE));
- g_object_class_install_property (object_class, PROP_EDITABLE,
+ g_object_class_install_property (object_class, PROP_EDITABLE,
g_param_spec_boolean ("editable",
_("Editable"),
/*_( */"XXX blurb" /*)*/,
diff --git a/addressbook/gui/widgets/e-minicard-view.h b/addressbook/gui/widgets/e-minicard-view.h
index 6950204286..ca706fed70 100644
--- a/addressbook/gui/widgets/e-minicard-view.h
+++ b/addressbook/gui/widgets/e-minicard-view.h
@@ -63,7 +63,7 @@ struct _EMinicardView
EReflow parent;
EAddressbookReflowAdapter *adapter;
-
+
/* item specific fields */
GList *drag_list;
diff --git a/addressbook/gui/widgets/e-minicard.c b/addressbook/gui/widgets/e-minicard.c
index 7132389379..c0fd0b5994 100644
--- a/addressbook/gui/widgets/e-minicard.c
+++ b/addressbook/gui/widgets/e-minicard.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-minicard.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -188,14 +188,14 @@ e_minicard_class_init (EMinicardClass *klass)
/*_( */"XXX blurb" /*)*/,
FALSE,
G_PARAM_READWRITE));
-
+
g_object_class_install_property (object_class, PROP_CONTACT,
g_param_spec_object ("contact",
_("Contact"),
/*_( */"XXX blurb" /*)*/,
E_TYPE_CONTACT,
G_PARAM_READWRITE));
-
+
e_minicard_signals [SELECTED] =
g_signal_new ("selected",
G_OBJECT_CLASS_TYPE (object_class),
@@ -264,23 +264,23 @@ set_selected (EMinicard *minicard, gboolean selected)
{
GtkWidget *canvas = GTK_WIDGET(GNOME_CANVAS_ITEM(minicard)->canvas);
if (selected) {
- gnome_canvas_item_set (minicard->rect,
+ gnome_canvas_item_set (minicard->rect,
"outline_color_gdk", &canvas->style->bg[GTK_STATE_ACTIVE],
NULL);
- gnome_canvas_item_set (minicard->header_rect,
+ gnome_canvas_item_set (minicard->header_rect,
"fill_color_gdk", &canvas->style->bg[GTK_STATE_SELECTED],
NULL);
- gnome_canvas_item_set (minicard->header_text,
+ gnome_canvas_item_set (minicard->header_text,
"fill_color_gdk", &canvas->style->text[GTK_STATE_SELECTED],
NULL);
} else {
- gnome_canvas_item_set (minicard->rect,
- "outline_color", NULL,
+ gnome_canvas_item_set (minicard->rect,
+ "outline_color", NULL,
NULL);
- gnome_canvas_item_set (minicard->header_rect,
+ gnome_canvas_item_set (minicard->header_rect,
"fill_color_gdk", &canvas->style->bg[GTK_STATE_NORMAL],
NULL);
- gnome_canvas_item_set (minicard->header_text,
+ gnome_canvas_item_set (minicard->header_text,
"fill_color_gdk", &canvas->style->text[GTK_STATE_NORMAL],
NULL);
}
@@ -306,7 +306,7 @@ e_minicard_set_property (GObject *object, guint prop_id, const GValue *value, G
item = GNOME_CANVAS_ITEM (object);
e_minicard = E_MINICARD (object);
-
+
switch (prop_id){
case PROP_WIDTH:
if (e_minicard->width != g_value_get_double (value)) {
@@ -415,7 +415,7 @@ e_minicard_dispose (GObject *object)
g_return_if_fail (E_IS_MINICARD (object));
e_minicard = E_MINICARD (object);
-
+
if (e_minicard->fields) {
g_list_foreach(e_minicard->fields, (GFunc) e_minicard_field_destroy, NULL);
g_list_free(e_minicard->fields);
@@ -442,12 +442,12 @@ e_minicard_finalize (GObject *object)
g_return_if_fail (E_IS_MINICARD (object));
e_minicard = E_MINICARD (object);
-
+
if (e_minicard->contact) {
g_object_unref (e_minicard->contact);
e_minicard->contact = NULL;
}
-
+
if (e_minicard->list_icon_pixbuf) {
g_object_unref (e_minicard->list_icon_pixbuf);
e_minicard->list_icon_pixbuf = NULL;
@@ -477,7 +477,7 @@ e_minicard_realize (GnomeCanvasItem *item)
if (GNOME_CANVAS_ITEM_CLASS(parent_class)->realize)
(* GNOME_CANVAS_ITEM_CLASS(parent_class)->realize) (item);
-
+
e_minicard->rect =
gnome_canvas_item_new( group,
gnome_canvas_rect_get_type(),
@@ -512,7 +512,7 @@ e_minicard_realize (GnomeCanvasItem *item)
e_canvas_item_move_absolute(e_minicard->header_text, 6, 6);
- e_minicard->list_icon =
+ e_minicard->list_icon =
gnome_canvas_item_new ( group,
gnome_canvas_pixbuf_get_type(),
"pixbuf", e_minicard->list_icon_pixbuf,
@@ -544,7 +544,7 @@ gboolean
e_minicard_activate_editor(EMinicard *minicard)
{
GnomeCanvasItem *item = (GnomeCanvasItem *)minicard;
-
+
if (minicard->editor) {
eab_editor_raise (minicard->editor);
}
@@ -581,7 +581,7 @@ static gboolean
e_minicard_event (GnomeCanvasItem *item, GdkEvent *event)
{
EMinicard *e_minicard;
-
+
e_minicard = E_MINICARD (item);
switch( event->type ) {
@@ -608,7 +608,7 @@ e_minicard_event (GnomeCanvasItem *item, GdkEvent *event)
GDK_POINTER_MOTION_MASK |
GDK_BUTTON_PRESS_MASK |
GDK_BUTTON_RELEASE_MASK);
-
+
e_canvas_item_grab_focus(item, TRUE);
if (gnome_canvas_item_grab (GNOME_CANVAS_ITEM (e_minicard),
@@ -734,7 +734,7 @@ e_minicard_event (GnomeCanvasItem *item, GdkEvent *event)
default:
break;
}
-
+
if (GNOME_CANVAS_ITEM_CLASS( parent_class )->event)
return (* GNOME_CANVAS_ITEM_CLASS( parent_class )->event) (item, event);
else
@@ -749,7 +749,7 @@ e_minicard_resize_children( EMinicard *e_minicard )
if (e_minicard->header_text) {
gnome_canvas_item_set( e_minicard->header_text,
- "width", ((double) e_minicard->width - 12
+ "width", ((double) e_minicard->width - 12
- (is_list ? e_minicard->list_icon_size : 0.0)),
NULL );
}
@@ -773,14 +773,14 @@ add_field (EMinicard *e_minicard, EContactField field, gdouble left_width)
EMinicardField *minicard_field;
char *name;
char *string;
-
+
group = GNOME_CANVAS_GROUP( e_minicard );
-
+
name = g_strdup_printf("%s:", e_contact_pretty_name (field));
string = e_contact_get (e_minicard->contact, field);
new_item = e_minicard_label_new(group);
-
+
if (e_minicard->contact && e_contact_get (e_minicard->contact, E_CONTACT_IS_LIST))
gnome_canvas_item_set( new_item,
"width", e_minicard->width - 4.0,
@@ -847,7 +847,7 @@ add_email_field (EMinicard *e_minicard, GList *email_list, gdouble left_width, i
for (l=email_list, le=emails; l!=NULL && count < limit && le!=NULL; l = l->next, le=le->next) {
const gchar *tmp;
-
+
tmp = get_email_location ((EVCardAttribute *) l->data);
if (tmp)
name = g_strdup_printf ("%s:", tmp);
@@ -856,7 +856,7 @@ add_email_field (EMinicard *e_minicard, GList *email_list, gdouble left_width, i
string = e_text_to_html (le->data, 0);
new_item = e_minicard_label_new(group);
-
+
gnome_canvas_item_set( new_item,
"width", e_minicard->width - 4.0,
"fieldname", name,
@@ -954,7 +954,7 @@ remodel( EMinicard *e_minicard )
for(field = E_CONTACT_FULL_NAME; field != (E_CONTACT_LAST_SIMPLE_STRING -1) && count < 5; field++) {
EMinicardField *minicard_field = NULL;
gboolean is_email=FALSE;
-
+
if (field == E_CONTACT_FAMILY_NAME || field == E_CONTACT_GIVEN_NAME)
continue;
@@ -1028,19 +1028,19 @@ e_minicard_reflow(GnomeCanvasItem *item, int flags)
GList *list;
gdouble text_height;
gint old_height;
-
+
old_height = e_minicard->height;
g_object_get(e_minicard->header_text,
"text_height", &text_height,
NULL);
-
+
e_minicard->height = text_height + 10.0;
-
+
gnome_canvas_item_set(e_minicard->header_rect,
"y2", text_height + 9.0,
NULL);
-
+
for(list = e_minicard->fields; list; list = g_list_next(list)) {
EMinicardField *field = E_MINICARD_FIELD(list->data);
/* Why not use the item that is passed in? */
@@ -1052,7 +1052,7 @@ e_minicard_reflow(GnomeCanvasItem *item, int flags)
e_minicard->height += text_height;
}
e_minicard->height += 2;
-
+
gnome_canvas_item_set(e_minicard->rect,
"x2", (double) e_minicard->width - 1.0,
"y2", (double) e_minicard->height - 1.0,
@@ -1083,7 +1083,7 @@ int
e_minicard_compare (EMinicard *minicard1, EMinicard *minicard2)
{
int cmp = 0;
-
+
g_return_val_if_fail(minicard1 != NULL, 0);
g_return_val_if_fail(E_IS_MINICARD(minicard1), 0);
g_return_val_if_fail(minicard2 != NULL, 0);
@@ -1098,13 +1098,13 @@ e_minicard_compare (EMinicard *minicard1, EMinicard *minicard2)
"file_as", &file_as2,
NULL);
- if (file_as1 && file_as2)
+ if (file_as1 && file_as2)
cmp = g_utf8_collate(file_as1, file_as2);
else if (file_as1)
cmp = -1;
else if (file_as2)
cmp = 1;
- else
+ else
cmp = strcmp(e_minicard_get_card_id(minicard1), e_minicard_get_card_id(minicard2));
g_free (file_as1);
diff --git a/addressbook/gui/widgets/e-minicard.h b/addressbook/gui/widgets/e-minicard.h
index 4a5d1c6e77..a1d084869c 100644
--- a/addressbook/gui/widgets/e-minicard.h
+++ b/addressbook/gui/widgets/e-minicard.h
@@ -60,10 +60,10 @@ enum _EMinicardFocusType {
struct _EMinicard
{
GnomeCanvasGroup parent;
-
+
/* item specific fields */
EContact *contact;
-
+
GnomeCanvasItem *rect;
GnomeCanvasItem *header_rect;
GnomeCanvasItem *header_text;
@@ -107,7 +107,7 @@ struct _EMinicardClass
};
typedef struct _EMinicardField EMinicardField;
-
+
struct _EMinicardField {
EContactField field;
GnomeCanvasItem *label;
diff --git a/addressbook/gui/widgets/eab-contact-display.c b/addressbook/gui/widgets/eab-contact-display.c
index 41e436c07e..639ccf6d04 100644
--- a/addressbook/gui/widgets/eab-contact-display.c
+++ b/addressbook/gui/widgets/eab-contact-display.c
@@ -81,7 +81,7 @@ eab_uri_popup_link_open(EPopup *ep, EPopupItem *item, void *data)
{
EABPopupTargetURI *t = (EABPopupTargetURI *)ep->target;
GError *err = NULL;
-
+
gnome_url_show(t->uri, &err);
if (err) {
g_warning("gnome_url_show: %s", err->message);
@@ -96,11 +96,11 @@ eab_uri_popup_email_address_copy(EPopup *ep, EPopupItem *item, void *data)
struct _EABContactDisplayPrivate *p = display->priv;
EABPopupTargetURI *t = (EABPopupTargetURI *)ep->target;
const char *url = t->uri;
- char *html=NULL;
- int i=0;
+ char *html=NULL;
+ int i=0;
GList *email_list, *l;
int email_num = atoi (url + strlen ("internal-mailto:"));
-
+
email_list = e_contact_get (p->contact, E_CONTACT_EMAIL);
for (l = email_list; l; l=l->next) {
if(i==email_num)
@@ -109,9 +109,9 @@ eab_uri_popup_email_address_copy(EPopup *ep, EPopupItem *item, void *data)
}
g_free(p->selection_uri);
- p->selection_uri = g_strdup(html);
+ p->selection_uri = g_strdup(html);
g_free (html);
-
+
gtk_selection_owner_set(p->invisible, GDK_SELECTION_PRIMARY, gtk_get_current_event_time());
gtk_selection_owner_set(p->invisible, GDK_SELECTION_CLIPBOARD, gtk_get_current_event_time());
}
@@ -136,12 +136,12 @@ eab_uri_popup_address_send(EPopup *ep, EPopupItem *item, void *data)
const char *url = t->uri;
EABContactDisplay *display = data;
struct _EABContactDisplayPrivate *p = display->priv;
-
+
int mail_num = atoi (url + strlen ("internal-mailto:"));
-
+
if (mail_num == -1)
- return;
-
+ return;
+
eab_send_contact (p->contact, mail_num, EAB_DISPOSITION_AS_TO);
}
@@ -160,7 +160,7 @@ eab_selection_get(GtkWidget *widget, GtkSelectionData *data, guint info, guint t
static void
eab_selection_clear_event(GtkWidget *widget, GdkEventSelection *event, EABContactDisplay *display)
{
-#if 0
+#if 0
struct _EABContactDisplayPrivate *p = display->priv;
g_free(p->selection_uri);
@@ -171,7 +171,7 @@ eab_selection_clear_event(GtkWidget *widget, GdkEventSelection *event, EABContac
static EPopupItem eab_uri_popups[] = {
{ E_POPUP_ITEM, "05.open", N_("_Open Link in Browser"), eab_uri_popup_link_open, NULL, NULL, EAB_POPUP_URI_NOT_MAILTO },
{ E_POPUP_ITEM, "10.copy", N_("_Copy Link Location"), eab_uri_popup_link_copy, NULL, "edit-copy", EAB_POPUP_URI_NOT_MAILTO },
- { E_POPUP_ITEM, "15.send", N_("_Send New Message To..."), eab_uri_popup_address_send, NULL, "mail-message-new", EAB_POPUP_URI_MAILTO},
+ { E_POPUP_ITEM, "15.send", N_("_Send New Message To..."), eab_uri_popup_address_send, NULL, "mail-message-new", EAB_POPUP_URI_MAILTO},
{ E_POPUP_ITEM, "20.copy", N_("Copy _Email Address"), eab_uri_popup_email_address_copy, NULL, "edit-copy", EAB_POPUP_URI_MAILTO},
};
@@ -199,7 +199,7 @@ eab_uri_popup_event(EABContactDisplay *display, GdkEvent *event, const char *uri
GtkMenu *menu;
GSList *menus = NULL;
int i;
-
+
emp = eab_popup_new("org.gnome.evolution.addressbook.contactdisplay.popup");
t = eab_popup_target_new_uri(emp, uri);
@@ -212,7 +212,7 @@ eab_uri_popup_event(EABContactDisplay *display, GdkEvent *event, const char *uri
e_popup_add_items((EPopup *)emp, menus, NULL, eab_uri_popup_free, display);
menu = e_popup_create_menu_once((EPopup *)emp,(EPopupTarget*)t, 0);
-
+
if (event == NULL) {
gtk_menu_popup(menu, NULL, NULL, NULL, NULL, 0, gtk_get_current_event_time());
} else {
@@ -267,7 +267,7 @@ on_link_clicked (GtkHTML *html, const char *url, EABContactDisplay *display)
if (mail_num == -1)
return;
-
+
eab_send_contact (display->priv->contact, mail_num, EAB_DISPOSITION_AS_TO);
return;
@@ -275,7 +275,7 @@ on_link_clicked (GtkHTML *html, const char *url, EABContactDisplay *display)
#endif
gnome_url_show (url, &err);
-
+
if (err) {
g_warning ("gnome_url_show: %s", err->message);
g_error_free (err);
@@ -417,7 +417,7 @@ accum_time_attribute (GString *gstr, EContact *contact, const char *html_label,
EContactDate *date;
GDate *gdate = NULL;
char sdate[100];
-
+
date = e_contact_get (contact, field);
if (date) {
gdate = g_date_new_dmy ( date->day,
@@ -508,7 +508,7 @@ render_contact (GtkHTMLStream *html_stream, EContact *contact)
email_list = e_contact_get (contact, E_CONTACT_EMAIL);
email_attr_list = e_contact_get_attributes (contact, E_CONTACT_EMAIL);
-
+
for (l = email_list, al=email_attr_list; l && al; l = l->next, al = al->next) {
#ifdef HANDLE_MAILTO_INTERNALLY
char *html = e_text_to_html (l->data, 0);
@@ -517,7 +517,7 @@ render_contact (GtkHTMLStream *html_stream, EContact *contact)
email_num ++;
g_free (html);
nl = "<br>";
-
+
#else
g_string_append_printf (accum, "%s%s <font color=" HEADER_COLOR ">(%s)</font>", nl, (char*)l->data, get_email_location ((EVCardAttribute *) al->data));
nl = "\n";
@@ -546,7 +546,7 @@ render_contact (GtkHTMLStream *html_stream, EContact *contact)
if (accum->len > 0)
gtk_html_stream_printf (html_stream, "%s", accum->str);
}
-
+
g_string_assign (accum, "");
accum_multival_attribute (accum, contact, _("AIM"), E_CONTACT_IM_AIM, AIM_ICON, 0);
accum_multival_attribute (accum, contact, _("GroupWise"), E_CONTACT_IM_GROUPWISE, GROUPWISE_ICON, 0);
@@ -571,7 +571,7 @@ render_contact (GtkHTMLStream *html_stream, EContact *contact)
accum_attribute (accum, contact, _("Assistant"), E_CONTACT_ASSISTANT, NULL, 0);
accum_attribute (accum, contact, _("Video Chat"), E_CONTACT_VIDEO_URL, VIDEOCONF_ICON, E_TEXT_TO_HTML_CONVERT_URLS);
accum_attribute (accum, contact, _("Calendar"), E_CONTACT_CALENDAR_URI, NULL, E_TEXT_TO_HTML_CONVERT_URLS);
- accum_attribute (accum, contact, _("Free/Busy"), E_CONTACT_FREEBUSY_URL, NULL, E_TEXT_TO_HTML_CONVERT_URLS);
+ accum_attribute (accum, contact, _("Free/Busy"), E_CONTACT_FREEBUSY_URL, NULL, E_TEXT_TO_HTML_CONVERT_URLS);
accum_attribute (accum, contact, _("Phone"), E_CONTACT_PHONE_BUSINESS, NULL, 0);
accum_attribute (accum, contact, _("Fax"), E_CONTACT_PHONE_BUSINESS_FAX, NULL, 0);
accum_address (accum, contact, _("Address"), E_CONTACT_ADDRESS_WORK, E_CONTACT_ADDRESS_LABEL_WORK);
@@ -637,7 +637,7 @@ eab_contact_display_render_normal (EABContactDisplay *display, EContact *contact
gtk_html_stream_printf (html_stream, "<img border=\"1\" src=\"internal-contact-photo:\">");
e_contact_photo_free (photo);
}
-
+
gtk_html_stream_printf (html_stream, "</td><td valign=\"top\">\n");
str = e_contact_get_const (contact, E_CONTACT_FILE_AS);
@@ -735,7 +735,7 @@ eab_contact_display_render_compact (EABContactDisplay *display, EContact *contac
calced_width, calced_height);
e_contact_photo_free (photo);
}
-
+
gtk_html_stream_printf (html_stream, "</td><td valign=\"top\">\n");
str = e_contact_get_const (contact, E_CONTACT_FILE_AS);
@@ -754,7 +754,7 @@ eab_contact_display_render_compact (EABContactDisplay *display, EContact *contac
}
gtk_html_stream_write (html_stream, "<hr>", 4);
-
+
if (e_contact_get (contact, E_CONTACT_IS_LIST)) {
GList *email_list;
GList *l;
@@ -804,7 +804,7 @@ eab_contact_display_render_compact (EABContactDisplay *display, EContact *contac
g_free (html);
}
gtk_html_stream_write (html_stream, "<br>", 4);
-
+
str = e_contact_get_const (contact, E_CONTACT_HOMEPAGE_URL);
if (str) {
html = e_text_to_html (str, E_TEXT_TO_HTML_CONVERT_URLS);
@@ -847,11 +847,11 @@ eab_html_press_event (GtkWidget *widget, GdkEvent *event,EABContactDisplay *disp
{
char *uri;
gboolean res = FALSE;
-
+
if (event->button.button!= 3 )
return FALSE;
-
+
uri = gtk_html_get_url_at (GTK_HTML (widget), event->button.x, event->button.y);
if (uri){
eab_uri_popup_event(display,event,uri);
@@ -873,7 +873,7 @@ eab_contact_display_new (void)
p=display->priv = g_new0 (EABContactDisplayPrivate, 1);
gtk_html_set_default_content_type (GTK_HTML (display), "text/html; charset=utf-8");
-
+
gtk_html_set_editable (GTK_HTML (display), FALSE);
g_signal_connect (display, "url_requested",
@@ -882,7 +882,7 @@ eab_contact_display_new (void)
g_signal_connect (display, "link_clicked",
G_CALLBACK (on_link_clicked),
display);
- g_signal_connect(display, "button_press_event",
+ g_signal_connect(display, "button_press_event",
G_CALLBACK(eab_html_press_event),
display);
p->invisible = gtk_invisible_new();
@@ -890,7 +890,7 @@ eab_contact_display_new (void)
g_signal_connect(p->invisible, "selection_clear_event", G_CALLBACK(eab_selection_clear_event), display);
gtk_selection_add_target(p->invisible, GDK_SELECTION_PRIMARY, GDK_SELECTION_TYPE_STRING, 0);
gtk_selection_add_target(p->invisible, GDK_SELECTION_CLIPBOARD, GDK_SELECTION_TYPE_STRING, 1);
-
+
#if 0
g_signal_connect (display, "object_requested",
G_CALLBACK (on_object_requested),
diff --git a/addressbook/gui/widgets/eab-contact-display.h b/addressbook/gui/widgets/eab-contact-display.h
index cc10b0eeac..e1b84346e7 100644
--- a/addressbook/gui/widgets/eab-contact-display.h
+++ b/addressbook/gui/widgets/eab-contact-display.h
@@ -43,7 +43,7 @@ typedef enum {
struct _EABContactDisplay {
GtkHTML parent;
-
+
EABContactDisplayPrivate *priv;
};
diff --git a/addressbook/gui/widgets/eab-gui-util.c b/addressbook/gui/widgets/eab-gui-util.c
index f7ed275698..731d141a84 100644
--- a/addressbook/gui/widgets/eab-gui-util.c
+++ b/addressbook/gui/widgets/eab-gui-util.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-table-field-chooser.c
* Copyright (C) 2001 Ximian, Inc.
* Author: Chris Toshok <toshok@ximian.com>
@@ -76,7 +76,7 @@ void
eab_error_dialog (const char *msg, EBookStatus status)
{
const char *status_str = status_to_string [status];
-
+
if (status_str)
e_error_run (NULL, "addressbook:generic-error", msg, _(status_str), NULL);
}
@@ -86,7 +86,7 @@ eab_load_error_dialog (GtkWidget *parent, ESource *source, EBookStatus status)
{
char *label_string, *label = NULL, *uri;
GtkWidget *dialog;
-
+
g_return_if_fail (source != NULL);
uri = e_source_get_uri (source);
@@ -97,7 +97,7 @@ eab_load_error_dialog (GtkWidget *parent, ESource *source, EBookStatus status)
"for offline usage. Please load the addressbook once in online mode "
"to download its contents");
}
-
+
else if (!strncmp (uri, "file:", 5)) {
char *path = g_filename_from_uri (uri, NULL, NULL);
label = g_strdup_printf (
@@ -109,7 +109,7 @@ eab_load_error_dialog (GtkWidget *parent, ESource *source, EBookStatus status)
else if (!strncmp (uri, "ldap:", 5)) {
/* special case for ldap: contact folders so we can tell the user about openldap */
#ifdef HAVE_LDAP
- label_string =
+ label_string =
_("We were unable to open this addressbook. This either "
"means you have entered an incorrect URI, or the LDAP server "
"is unreachable.");
@@ -126,12 +126,12 @@ eab_load_error_dialog (GtkWidget *parent, ESource *source, EBookStatus status)
"means you have entered an incorrect URI, or the server "
"is unreachable.");
}
-
+
dialog = e_error_new ((GtkWindow *) parent, "addressbook:load-error", label_string, NULL);
g_signal_connect (dialog, "response", G_CALLBACK (gtk_widget_destroy), NULL);
-
+
gtk_widget_show (dialog);
- g_free (label);
+ g_free (label);
g_free (uri);
}
@@ -168,7 +168,7 @@ eab_search_result_dialog (GtkWidget *parent,
default:
g_return_if_reached ();
}
-
+
e_error_run ((GtkWindow *) parent, "addressbook:search-error", str, NULL);
}
@@ -340,7 +340,7 @@ file_exists(GtkWindow *window, const char *filename)
typedef struct {
GtkWidget *filesel;
char *vcard;
- gboolean has_multiple_contacts;
+ gboolean has_multiple_contacts;
} SaveAsInfo;
static void
@@ -350,11 +350,11 @@ save_it(GtkWidget *widget, SaveAsInfo *info)
char *uri;
gint error = 0;
gint response = 0;
-
+
filename = gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (info->filesel));
- uri = gtk_file_chooser_get_uri (GTK_FILE_CHOOSER (info->filesel));
-
+ uri = gtk_file_chooser_get_uri (GTK_FILE_CHOOSER (info->filesel));
+
if (filename && g_file_test (filename, G_FILE_TEST_EXISTS)) {
response = file_exists(GTK_WINDOW (info->filesel), filename);
switch (response) {
@@ -365,12 +365,12 @@ save_it(GtkWidget *widget, SaveAsInfo *info)
}
}
- error = e_write_file_uri (uri, info->vcard);
+ error = e_write_file_uri (uri, info->vcard);
if (error != 0) {
char *err_str_ext;
if (info->has_multiple_contacts) {
/* more than one, finding the total number of contacts might
- * hit performance while saving large number of contacts
+ * hit performance while saving large number of contacts
*/
err_str_ext = ngettext ("contact", "contacts", 2);
}
@@ -378,16 +378,16 @@ save_it(GtkWidget *widget, SaveAsInfo *info)
err_str_ext = ngettext ("contact", "contacts", 1);
}
- /* translators: Arguments, err_str_ext (item to be saved: "contact"/"contacts"),
- * destination file name, and error code will fill the placeholders
- * {0}, {1} and {2}, respectively in the error message formed
+ /* translators: Arguments, err_str_ext (item to be saved: "contact"/"contacts"),
+ * destination file name, and error code will fill the placeholders
+ * {0}, {1} and {2}, respectively in the error message formed
*/
- e_error_run (GTK_WINDOW (info->filesel), "addressbook:save-error",
+ e_error_run (GTK_WINDOW (info->filesel), "addressbook:save-error",
err_str_ext, filename, g_strerror (errno));
gtk_widget_destroy(GTK_WIDGET(info->filesel));
return;
}
-
+
gtk_widget_destroy(GTK_WIDGET(info->filesel));
}
@@ -430,7 +430,7 @@ make_safe_filename (char *name)
safe = g_strdup (name);
e_filename_make_safe (safe);
-
+
return safe;
}
@@ -523,7 +523,7 @@ eab_contact_save (char *title, EContact *contact, GtkWindow *parent_window)
gtk_file_chooser_set_current_folder (GTK_FILE_CHOOSER (filesel), g_get_home_dir ());
gtk_file_chooser_set_current_name (GTK_FILE_CHOOSER (filesel), file);
gtk_file_chooser_set_local_only (GTK_FILE_CHOOSER (filesel), FALSE);
-
+
info->filesel = filesel;
info->vcard = e_vcard_to_string (E_VCARD (contact), EVC_FORMAT_VCARD_30);
@@ -624,7 +624,7 @@ do_delete (gpointer data, gpointer user_data)
EBook *book = user_data;
EContact *contact = data;
const char *id;
-
+
id = e_contact_get_const (contact, E_CONTACT_UID);
e_book_remove_contact(book, id, NULL);
}
@@ -664,7 +664,7 @@ contact_added_cb (EBook* book, EBookStatus status, const char *id, gpointer user
if (status != E_BOOK_ERROR_OK && status != E_BOOK_ERROR_CANCELLED) {
process->book_status = FALSE;
eab_error_dialog (_("Error adding contact"), status);
- }
+ }
else if (status == E_BOOK_ERROR_CANCELLED) {
process->book_status = FALSE;
}
@@ -786,7 +786,7 @@ eab_send_to_contact_and_email_num_list (GList *c)
return;
CORBA_exception_init (&ev);
-
+
composer_server = bonobo_activation_activate_from_id (COMPOSER_OAFID, 0, NULL, &ev);
/* Figure out how many addresses of each kind we have. */
@@ -819,7 +819,7 @@ eab_send_to_contact_and_email_num_list (GList *c)
cc_list = GNOME_Evolution_Composer_RecipientList__alloc ();
cc_list->_maximum = cc_list->_length = 0;
-
+
bcc_list = GNOME_Evolution_Composer_RecipientList__alloc ();
bcc_list->_maximum = bcc_length;
bcc_list->_length = bcc_length;
@@ -845,7 +845,7 @@ eab_send_to_contact_and_email_num_list (GList *c)
if (is_list) {
for (iterator = emails; iterator; iterator = iterator->next) {
-
+
if (is_hidden) {
recipient = &(bcc_list->_buffer[bcc_i]);
++bcc_i;
@@ -853,7 +853,7 @@ eab_send_to_contact_and_email_num_list (GList *c)
recipient = &(to_list->_buffer[to_i]);
++to_i;
}
-
+
name = NULL;
addr = NULL;
if (iterator && iterator->data) {
@@ -863,7 +863,7 @@ eab_send_to_contact_and_email_num_list (GList *c)
recipient->name = CORBA_string_dup (name ? name : "");
recipient->address = CORBA_string_dup (addr ? addr : "");
-
+
g_free (name);
g_free (addr);
}
@@ -882,7 +882,7 @@ eab_send_to_contact_and_email_num_list (GList *c)
if (nth >= length)
nth = 0;
-
+
if (contact_name) {
name = e_contact_name_to_string (contact_name);
e_contact_name_free (contact_name);
@@ -891,7 +891,7 @@ eab_send_to_contact_and_email_num_list (GList *c)
name = NULL;
addr = g_strdup (g_list_nth_data (emails, nth));
-
+
recipient->name = CORBA_string_dup (name ? name : "");
recipient->address = CORBA_string_dup (addr ? addr : "");
@@ -948,11 +948,11 @@ eab_send_contact_list_as_attachment (GList *contacts)
return;
CORBA_exception_init (&ev);
-
+
composer_server = bonobo_activation_activate_from_id (COMPOSER_OAFID, 0, NULL, &ev);
-
+
content_type = CORBA_string_dup ("text/x-vcard");
filename = CORBA_string_dup ("");
@@ -975,17 +975,17 @@ eab_send_contact_list_as_attachment (GList *contacts)
memcpy (attach_data->_buffer, tempstr, attach_data->_length);
g_free (tempstr);
- GNOME_Evolution_Composer_attachData (composer_server,
+ GNOME_Evolution_Composer_attachData (composer_server,
content_type, filename, description,
show_inline, attach_data,
&ev);
-
+
if (ev._major != CORBA_NO_EXCEPTION) {
g_printerr ("gui/e-meeting-edit.c: I couldn't attach data to the composer via CORBA! Aagh.\n");
CORBA_exception_free (&ev);
return;
}
-
+
CORBA_free (content_type);
CORBA_free (filename);
CORBA_free (description);
@@ -993,7 +993,7 @@ eab_send_contact_list_as_attachment (GList *contacts)
to_list = GNOME_Evolution_Composer_RecipientList__alloc ();
to_list->_maximum = to_list->_length = 0;
-
+
cc_list = GNOME_Evolution_Composer_RecipientList__alloc ();
cc_list->_maximum = cc_list->_length = 0;
@@ -1025,7 +1025,7 @@ eab_send_contact_list_as_attachment (GList *contacts)
subject = CORBA_string_dup (tempstr);
g_free (tempstr);
}
-
+
GNOME_Evolution_Composer_setHeaders (composer_server, "", to_list, cc_list, bcc_list, subject, &ev);
CORBA_free (to_list);
diff --git a/addressbook/gui/widgets/eab-menu.c b/addressbook/gui/widgets/eab-menu.c
index c35cd6ba61..d1c8b4e243 100644
--- a/addressbook/gui/widgets/eab-menu.c
+++ b/addressbook/gui/widgets/eab-menu.c
@@ -115,8 +115,8 @@ EABMenu *eab_menu_new(const char *menuid)
* @cards: Cards selected. This will be freed on completion and the array indices unreferenced.
*
* Create a new selection menu target.
- *
- * Return value:
+ *
+ * Return value:
**/
EABMenuTargetSelect *
eab_menu_target_new_select(EABMenu *eabp, struct _EBook *book, int readonly, GPtrArray *cards)
@@ -139,7 +139,7 @@ eab_menu_target_new_select(EABMenu *eabp, struct _EBook *book, int readonly, GPt
email = e_contact_get(E_CONTACT(contact), E_CONTACT_EMAIL);
if (email) {
has_email = TRUE;
-
+
g_list_foreach(email, (GFunc)g_free, NULL);
g_list_free(email);
}
@@ -243,7 +243,7 @@ GType
eab_menu_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EABMenuHookClass), NULL, NULL, (GClassInitFunc) eabmph_class_init, NULL, NULL,
@@ -253,6 +253,6 @@ eab_menu_hook_get_type(void)
eabmph_parent_class = g_type_class_ref(e_menu_hook_get_type());
type = g_type_register_static(e_menu_hook_get_type(), "EABMenuHook", &info, 0);
}
-
+
return type;
}
diff --git a/addressbook/gui/widgets/eab-menu.h b/addressbook/gui/widgets/eab-menu.h
index 9f521cca85..d095ce9e74 100644
--- a/addressbook/gui/widgets/eab-menu.h
+++ b/addressbook/gui/widgets/eab-menu.h
@@ -44,7 +44,7 @@ enum _eab_menu_target_t {
/**
* enum _eab_menu_target_select_t - EABMenuTargetSelect qualifiers.
- *
+ *
* @EAB_MENU_SELECT_ONE: Only one item is selected.
* @EAB_MENU_SELECT_MANY: More than one item selected.
* @EAB_MENU_SELECT_ANY: One or more items selected.
diff --git a/addressbook/gui/widgets/eab-popup-control.c b/addressbook/gui/widgets/eab-popup-control.c
index 81baba6752..94e46e0524 100644
--- a/addressbook/gui/widgets/eab-popup-control.c
+++ b/addressbook/gui/widgets/eab-popup-control.c
@@ -13,12 +13,12 @@
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
@@ -213,7 +213,7 @@ eab_popup_control_set_free_form (EABPopupControl *pop, const gchar *txt)
return TRUE;
}
-
+
return FALSE;
}
@@ -326,7 +326,7 @@ emit_event (EABPopupControl *pop, const char *event)
event,
arg, NULL);
bonobo_arg_release (arg);
- }
+ }
}
static void
diff --git a/addressbook/gui/widgets/eab-popup-control.h b/addressbook/gui/widgets/eab-popup-control.h
index 7112c90606..1d7ee36f0a 100644
--- a/addressbook/gui/widgets/eab-popup-control.h
+++ b/addressbook/gui/widgets/eab-popup-control.h
@@ -13,12 +13,12 @@
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
@@ -54,7 +54,7 @@ struct _EABPopupControl {
GtkWidget *name_widget;
GtkWidget *email_widget;
GtkWidget *query_msg;
-
+
GtkWidget *main_vbox;
GtkWidget *generic_view;
GtkWidget *contact_display;
diff --git a/addressbook/gui/widgets/eab-popup.c b/addressbook/gui/widgets/eab-popup.c
index d37c1b7b73..ad43bde11e 100644
--- a/addressbook/gui/widgets/eab-popup.c
+++ b/addressbook/gui/widgets/eab-popup.c
@@ -131,8 +131,8 @@ EABPopup *eab_popup_new(const char *menuid)
* @cards: Cards selected. This will be freed on completion.
*
* Create a new selection popup target.
- *
- * Return value:
+ *
+ * Return value:
**/
@@ -180,7 +180,7 @@ eab_popup_target_new_select(EABPopup *eabp, struct _EBook *book, int readonly, G
email = e_contact_get(E_CONTACT(contact), E_CONTACT_EMAIL);
if (email) {
has_email = TRUE;
-
+
g_list_foreach(email, (GFunc)g_free, NULL);
g_list_free(email);
}
@@ -352,7 +352,7 @@ GType
eab_popup_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EABPopupHookClass), NULL, NULL, (GClassInitFunc) eabph_class_init, NULL, NULL,
@@ -362,6 +362,6 @@ eab_popup_hook_get_type(void)
eabph_parent_class = g_type_class_ref(e_popup_hook_get_type());
type = g_type_register_static(e_popup_hook_get_type(), "EABPopupHook", &info, 0);
}
-
+
return type;
}
diff --git a/addressbook/gui/widgets/eab-popup.h b/addressbook/gui/widgets/eab-popup.h
index 3a1fbafd95..2f7b50a30f 100644
--- a/addressbook/gui/widgets/eab-popup.h
+++ b/addressbook/gui/widgets/eab-popup.h
@@ -38,7 +38,7 @@ typedef struct _EABPopupClass EABPopupClass;
/**
* enum _eab_popup_target_t - A list of mail popup target types.
- *
+ *
* @EAB_POPUP_TARGET_SELECT: A selection of cards
* @EAB_POPUP_TARGET_SOURCE: A source selection.
*
@@ -53,7 +53,7 @@ enum _eab_popup_target_t {
/**
* enum _eab_popup_target_select_t - EABPopupTargetSelect qualifiers.
- *
+ *
* @EAB_POPUP_SELECT_ONE: Only one item is selected.
* @EAB_POPUP_SELECT_MANY: Two or more items are selected.
* @EAB_POPUP_SELECT_ANY: One or more items are selected.
@@ -77,10 +77,10 @@ enum _eab_popup_target_uri_t {
};
/**
* enum _eab_popup_target_source_t - EABPopupTargetSource qualifiers.
- *
+ *
* @EAB_POPUP_SOURCE_PRIMARY: Has a primary selection.
* @EAB_POPUP_SOURCE_SYSTEM: Is a 'system' folder.
- *
+ *
**/
enum _eab_popup_target_source_t {
EAB_POPUP_SOURCE_PRIMARY = 1<<0,
@@ -94,7 +94,7 @@ typedef struct _EABPopupTargetSelectNames EABPopupTargetSelectNames;
typedef struct _EABPopupTargetURI EABPopupTargetURI;
/**
* struct _EABPopupTargetSelect - A list of address cards.
- *
+ *
* @target: Superclass.
* @book: Book the cards belong to.
* @cards: All selected cards.
@@ -117,7 +117,7 @@ struct _EABPopupTargetURI {
/**
* struct _EABPopupTargetSource - A source target.
- *
+ *
* @target: Superclass.
* @selector: Selector holding the source selection.
*
@@ -133,7 +133,7 @@ struct _EABPopupTargetSource {
/**
* struct _EABPopupTargetSelectNames - A select names target.
- *
+ *
* @target: Superclass.
* @model: Select names model.
* @row: Row of item selected.
diff --git a/addressbook/gui/widgets/eab-vcard-control.c b/addressbook/gui/widgets/eab-vcard-control.c
index 678a841be9..8922c396c5 100644
--- a/addressbook/gui/widgets/eab-vcard-control.c
+++ b/addressbook/gui/widgets/eab-vcard-control.c
@@ -112,8 +112,8 @@ pstream_load (BonoboPersistStream *ps, const Bonobo_Stream stream,
char *vcard;
EABVCardControl *vcard_control = data;
- if (type && g_ascii_strcasecmp (type, "text/vCard") != 0 &&
- g_ascii_strcasecmp (type, "text/x-vCard") != 0) {
+ if (type && g_ascii_strcasecmp (type, "text/vCard") != 0 &&
+ g_ascii_strcasecmp (type, "text/x-vCard") != 0) {
CORBA_exception_set (ev, CORBA_USER_EXCEPTION,
ex_Bonobo_Persist_WrongDataType, NULL);
return;
@@ -140,8 +140,8 @@ pstream_load (BonoboPersistStream *ps, const Bonobo_Stream stream,
if (list && list->next) {
char *message;
int length = g_list_length (list) - 1;
- message = g_strdup_printf (ngettext("There is one other contact.",
- "There are %d other contacts.", length),
+ message = g_strdup_printf (ngettext("There is one other contact.",
+ "There are %d other contacts.", length),
length);
gtk_label_set_text (GTK_LABEL (vcard_control->label), message);
g_free (message);
@@ -163,8 +163,8 @@ pstream_save (BonoboPersistStream *ps, const Bonobo_Stream stream,
char *vcard;
int length;
- if (type && g_ascii_strcasecmp (type, "text/vCard") != 0 &&
- g_ascii_strcasecmp (type, "text/x-vCard") != 0) {
+ if (type && g_ascii_strcasecmp (type, "text/vCard") != 0 &&
+ g_ascii_strcasecmp (type, "text/x-vCard") != 0) {
CORBA_exception_set (ev, CORBA_USER_EXCEPTION,
ex_Bonobo_Persist_WrongDataType, NULL);
return;
diff --git a/addressbook/gui/widgets/gal-view-minicard.c b/addressbook/gui/widgets/gal-view-minicard.c
index dc32f74fc5..cf0833d1fe 100644
--- a/addressbook/gui/widgets/gal-view-minicard.c
+++ b/addressbook/gui/widgets/gal-view-minicard.c
@@ -22,7 +22,7 @@
static GalViewClass *gal_view_minicard_parent_class;
-static void
+static void
gal_view_minicard_load (GalView *view,
const char *filename)
{
diff --git a/addressbook/gui/widgets/test-reflow.c b/addressbook/gui/widgets/test-reflow.c
index 25b9c525a5..a71a052525 100644
--- a/addressbook/gui/widgets/test-reflow.c
+++ b/addressbook/gui/widgets/test-reflow.c
@@ -102,7 +102,7 @@ static void resize(GnomeCanvas *canvas, gpointer data)
gnome_canvas_item_set( rect,
"x2", (double) width,
"y2", (double) last_alloc.height,
- NULL );
+ NULL );
}
int main( int argc, char *argv[] )
@@ -157,7 +157,7 @@ int main( int argc, char *argv[] )
e_scroll_frame_set_policy (E_SCROLL_FRAME (scrollframe),
GTK_POLICY_AUTOMATIC,
GTK_POLICY_NEVER);
-
+
gtk_container_add (GTK_CONTAINER (scrollframe), canvas);
gnome_app_set_contents( GNOME_APP( app ), scrollframe );
@@ -172,7 +172,7 @@ int main( int argc, char *argv[] )
gtk_widget_show_all( app );
gdk_window_set_back_pixmap( GTK_LAYOUT(canvas)->bin_window, NULL, FALSE);
- gtk_main();
+ gtk_main();
/* Not reached. */
return 0;
diff --git a/addressbook/importers/evolution-csv-importer.c b/addressbook/importers/evolution-csv-importer.c
index ade0e670db..e77d9067a8 100644
--- a/addressbook/importers/evolution-csv-importer.c
+++ b/addressbook/importers/evolution-csv-importer.c
@@ -50,8 +50,8 @@ typedef struct {
EImportTarget *target;
guint idle_id;
-
- int state;
+
+ int state;
FILE *file;
gulong size;
gint count;
@@ -73,14 +73,14 @@ typedef struct {
#define FLAG_OTHER_ADDRESS 0x04
#define FLAG_STREET 0x08
#define FLAG_CITY 0x10
-#define FLAG_STATE 0x20
+#define FLAG_STATE 0x20
#define FLAG_POSTAL_CODE 0x40
#define FLAG_COUNTRY 0x80
-#define FLAG_POBOX 0x70
+#define FLAG_POBOX 0x70
#define FLAG_DATE_BDAY 0x03
-#define FLAG_BIRTH_DAY 0x05
+#define FLAG_BIRTH_DAY 0x05
#define FLAG_BIRTH_YEAR 0x07
-#define FLAG_BIRTH_MONTH 0x50
+#define FLAG_BIRTH_MONTH 0x50
#define FLAG_DATE_ANNIVERSARY 0x30
#define FLAG_INVALID 0xff
int flags;
@@ -158,7 +158,7 @@ static import_fields csv_fields_outlook[] = {
{"Hobby", NOMAP},
{"Home Address PO Box", NOMAP, FLAG_HOME_ADDRESS|FLAG_POBOX},
{"Initials", NOMAP},
- {"Internet FREE/BUSY", E_CONTACT_FREEBUSY_URL},
+ {"Internet FREE/BUSY", E_CONTACT_FREEBUSY_URL},
{"Keywords", NOMAP},
{"Language", NOMAP},
{"Location", NOMAP},
@@ -218,8 +218,8 @@ static import_fields csv_fields_mozilla[] = {
{"Custom 3", NOMAP},
{"Custom 4", NOMAP},
{"Notes", NOMAP},
-
-
+
+
};
static import_fields csv_fields_evolution[] = {
@@ -265,15 +265,15 @@ add_to_notes(EContact *contact, gint i, char *val) {
const gchar *old_text;
const gchar *field_text = NULL;
GString *new_text;
-
+
old_text = e_contact_get_const(contact, E_CONTACT_NOTE);
if(importer == OUTLOOK_IMPORTER)
field_text = csv_fields_outlook[i].csv_attribute;
else if(importer == MOZILLA_IMPORTER)
field_text = csv_fields_mozilla[i].csv_attribute;
else
- field_text = csv_fields_evolution[i].csv_attribute;
-
+ field_text = csv_fields_evolution[i].csv_attribute;
+
new_text = g_string_new(old_text);
if(strlen(new_text->str) != 0)
new_text = g_string_append_c(new_text, '\n');
@@ -302,7 +302,7 @@ date_from_string (const char *str)
length = t - str;
else
length = strlen(str);
-
+
if (g_ascii_isdigit (str[i]) && g_ascii_isdigit (str[i+1])) {
date->month = str[i] * 10 + str[i+1] - '0' * 11;
i = i+3;
@@ -321,13 +321,13 @@ date_from_string (const char *str)
i = i+2;
}
date->year = str[i] * 1000 + str[i+1] * 100 + str[i+2] * 10 + str[i+3] - '0' * 1111;
-
+
return date;
}
-static gboolean
+static gboolean
parseLine (CSVImporter *gci, EContact *contact, char **buf) {
-
+
char *ptr = *buf;
GString *value;
gint i = 0;
@@ -343,7 +343,7 @@ parseLine (CSVImporter *gci, EContact *contact, char **buf) {
work_address = g_new0(EContactAddress, 1);
other_address = g_new0(EContactAddress, 1);
bday = g_new0(EContactDate, 1);
-
+
while(*ptr != '\n') {
value = g_string_new("");
while(*ptr != delimiter) {
@@ -455,7 +455,7 @@ parseLine (CSVImporter *gci, EContact *contact, char **buf) {
case FLAG_DATE_BDAY:
e_contact_set(contact, E_CONTACT_BIRTH_DATE, date_from_string(value->str));
break;
-
+
case FLAG_DATE_ANNIVERSARY:
e_contact_set(contact, E_CONTACT_ANNIVERSARY, date_from_string(value->str));
break;
@@ -472,9 +472,9 @@ parseLine (CSVImporter *gci, EContact *contact, char **buf) {
case FLAG_INVALID:
break;
-
+
default:
- add_to_notes(contact, i, value->str);
+ add_to_notes(contact, i, value->str);
}
}
@@ -495,13 +495,13 @@ parseLine (CSVImporter *gci, EContact *contact, char **buf) {
g_string_free(other_street, TRUE);
if(home_address->locality || home_address->country ||
- home_address->code || home_address->region || home_address->street)
+ home_address->code || home_address->region || home_address->street)
e_contact_set (contact, E_CONTACT_ADDRESS_HOME, home_address);
if(work_address->locality || work_address->country ||
- work_address->code || work_address->region || work_address->street)
+ work_address->code || work_address->region || work_address->street)
e_contact_set (contact, E_CONTACT_ADDRESS_WORK, work_address);
if(other_address->locality || other_address->country ||
- other_address->code || other_address->region || other_address->street)
+ other_address->code || other_address->region || other_address->street)
e_contact_set (contact, E_CONTACT_ADDRESS_OTHER, other_address);
if(importer != OUTLOOK_IMPORTER) {
@@ -520,12 +520,12 @@ getNextCSVEntry(CSVImporter *gci, FILE *f) {
char *buf;
char c;
- /*
- if(!fgets(line, sizeof(line),f))
+ /*
+ if(!fgets(line, sizeof(line),f))
return NULL;
if(gci->count == 0 && importer != MOZILLA_IMPORTER) {
- if(!fgets(line, sizeof(line),f))
+ if(!fgets(line, sizeof(line),f))
return NULL;
gci->count ++;
}
@@ -552,7 +552,7 @@ getNextCSVEntry(CSVImporter *gci, FILE *f) {
else
g_string_append_unichar(line, c);
}
-
+
if(gci->count == 0 && importer != MOZILLA_IMPORTER) {
g_string_free (line, TRUE);
line = g_string_new("");
@@ -575,7 +575,7 @@ getNextCSVEntry(CSVImporter *gci, FILE *f) {
}
else
g_string_append_unichar(line, c);
- }
+ }
gci->count ++;
}
@@ -583,12 +583,12 @@ getNextCSVEntry(CSVImporter *gci, FILE *f) {
str = g_string_append (str, line->str);
g_string_free (line, TRUE);
-
+
if(strlen(str->str) == 0) {
g_string_free(str, TRUE);
return NULL;
}
-
+
contact = e_contact_new();
buf = str->str;
@@ -639,14 +639,14 @@ csv_getwidget(EImport *ei, EImportTarget *target, EImportImporter *im)
{
GtkWidget *vbox, *selector;
ESource *primary;
- ESourceList *source_list;
+ ESourceList *source_list;
/* FIXME Better error handling */
if (!e_book_get_addressbooks (&source_list, NULL))
return NULL;
vbox = gtk_vbox_new (FALSE, FALSE);
-
+
selector = e_source_selector_new (source_list);
e_source_selector_show_selection (E_SOURCE_SELECTOR (selector), FALSE);
gtk_box_pack_start (GTK_BOX (vbox), selector, FALSE, TRUE, 6);
@@ -677,7 +677,7 @@ csv_supported(EImport *ei, EImportTarget *target, EImportImporter *im)
char *ext;
int i;
EImportTargetURI *s;
-
+
if (target->type != E_IMPORT_TARGET_URI)
return FALSE;
@@ -759,26 +759,26 @@ csv_import (EImport *ei, EImportTarget *target, EImportImporter *im)
fseek(file, 0, SEEK_SET);
e_book_open(gci->book, FALSE, NULL);
-
+
gci->idle_id = g_idle_add (csv_import_contacts, gci);
}
static void
-outlook_csv_import(EImport *ei, EImportTarget *target, EImportImporter *im)
+outlook_csv_import(EImport *ei, EImportTarget *target, EImportImporter *im)
{
importer = OUTLOOK_IMPORTER;
csv_import(ei, target, im);
}
static void
-mozilla_csv_import(EImport *ei, EImportTarget *target, EImportImporter *im)
+mozilla_csv_import(EImport *ei, EImportTarget *target, EImportImporter *im)
{
importer = MOZILLA_IMPORTER;
csv_import(ei, target, im);
}
static void
-evolution_csv_import(EImport *ei, EImportTarget *target, EImportImporter *im)
+evolution_csv_import(EImport *ei, EImportTarget *target, EImportImporter *im)
{
importer = EVOLUTION_IMPORTER;
csv_import(ei, target, im);
@@ -791,7 +791,7 @@ csv_cancel(EImport *ei, EImportTarget *target, EImportImporter *im) {
if(gci)
gci->state = 1;
}
-
+
static EImportImporter csv_outlook_importer = {
E_IMPORT_TARGET_URI,
@@ -825,7 +825,7 @@ evolution_csv_outlook_importer_peek(void)
{
csv_outlook_importer.name = _("Outlook CSV or Tab (.csv, .tab)");
csv_outlook_importer.description = _("Outlook CSV and Tab Importer");
-
+
return &csv_outlook_importer;
}
@@ -833,8 +833,8 @@ EImportImporter *
evolution_csv_mozilla_importer_peek(void)
{
csv_mozilla_importer.name = _("Mozilla CSV or Tab (.csv, .tab)");
- csv_mozilla_importer.description = _("Mozilla CSV and Tab Importer");
-
+ csv_mozilla_importer.description = _("Mozilla CSV and Tab Importer");
+
return &csv_mozilla_importer;
}
@@ -842,7 +842,7 @@ EImportImporter *
evolution_csv_evolution_importer_peek(void)
{
csv_evolution_importer.name = _("Evolution CSV or Tab (.csv, .tab)");
- csv_evolution_importer.description = _("Evolution CSV and Tab Importer");
-
+ csv_evolution_importer.description = _("Evolution CSV and Tab Importer");
+
return &csv_evolution_importer;
}
diff --git a/addressbook/importers/evolution-ldif-importer.c b/addressbook/importers/evolution-ldif-importer.c
index 1e055db4da..2361c41310 100644
--- a/addressbook/importers/evolution-ldif-importer.c
+++ b/addressbook/importers/evolution-ldif-importer.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* LDIF importer. LDIF is the file format of an exported Netscape
* addressbook.
*
@@ -155,7 +155,7 @@ getValue( char **src )
static void
populate_contact_address (EContactAddress *address, char *attr, char *value)
{
- if (!g_ascii_strcasecmp (attr, "locality") ||
+ if (!g_ascii_strcasecmp (attr, "locality") ||
!g_ascii_strcasecmp (attr, "l") ||
!g_ascii_strcasecmp (attr, "mozillaHomeLocalityName"))
address->locality = g_strdup (value);
@@ -179,7 +179,7 @@ populate_contact_address (EContactAddress *address, char *attr, char *value)
address->ext = g_strconcat (temp, ",\n", value, NULL);
g_free (temp);
}
- else {
+ else {
address->ext = g_strdup (value);
}
}
@@ -209,8 +209,8 @@ populate_contact_address (EContactAddress *address, char *attr, char *value)
}
static gboolean
-parseLine (LDIFImporter *gci, EContact *contact,
- EContactAddress *work_address, EContactAddress *home_address,
+parseLine (LDIFImporter *gci, EContact *contact,
+ EContactAddress *work_address, EContactAddress *home_address,
char **buf)
{
char *ptr;
@@ -371,7 +371,7 @@ getNextLDIFEntry(LDIFImporter *gci, FILE *f )
work_address->code || work_address->region || work_address->street) {
e_contact_set (contact, E_CONTACT_ADDRESS_WORK, work_address);
}
- if (home_address->locality || home_address->country || home_address->ext ||
+ if (home_address->locality || home_address->country || home_address->ext ||
home_address->code || home_address->region || home_address->street) {
e_contact_set (contact, E_CONTACT_ADDRESS_HOME, home_address);
}
@@ -419,7 +419,7 @@ resolve_list_card (LDIFImporter *gci, EContact *contact)
email_attrs = g_list_append (email_attrs, attr);
}
- }
+ }
e_contact_set_attributes (contact, E_CONTACT_EMAIL, email_attrs);
g_list_foreach (email, (GFunc) g_free, NULL);
@@ -514,14 +514,14 @@ ldif_getwidget(EImport *ei, EImportTarget *target, EImportImporter *im)
{
GtkWidget *vbox, *selector;
ESource *primary;
- ESourceList *source_list;
+ ESourceList *source_list;
/* FIXME Better error handling */
if (!e_book_get_addressbooks (&source_list, NULL))
return NULL;
vbox = gtk_vbox_new (FALSE, FALSE);
-
+
selector = e_source_selector_new (source_list);
e_source_selector_show_selection (E_SOURCE_SELECTOR (selector), FALSE);
gtk_box_pack_start (GTK_BOX (vbox), selector, FALSE, TRUE, 6);
diff --git a/addressbook/importers/evolution-vcard-importer.c b/addressbook/importers/evolution-vcard-importer.c
index 5a7615f924..9afb1b0a47 100644
--- a/addressbook/importers/evolution-vcard-importer.c
+++ b/addressbook/importers/evolution-vcard-importer.c
@@ -54,7 +54,7 @@ typedef struct {
int count;
ESource *primary;
-
+
GList *contactlist;
GList *iterator;
EBook *book;
@@ -258,7 +258,7 @@ vcard_import_contacts(void *data)
static gboolean
has_bom (const gunichar2 *utf16)
{
-
+
if ((utf16 == NULL) || (*utf16 == '\0')) {
return FALSE;
}
@@ -273,7 +273,7 @@ fix_utf16_endianness (gunichar2 *utf16)
if ((utf16 == NULL) || (*utf16 == '\0')) {
- return;
+ return;
}
if (*utf16 != ANTIBOM) {
@@ -285,14 +285,14 @@ fix_utf16_endianness (gunichar2 *utf16)
}
}
-/* Converts an UTF-16 string to an UTF-8 string removing the BOM character
+/* Converts an UTF-16 string to an UTF-8 string removing the BOM character
* WARNING: this may modify the utf16 argument if the function detects the
* string isn't using the local endianness
*/
static gchar *
utf16_to_utf8 (gunichar2 *utf16)
{
-
+
if (utf16 == NULL) {
return NULL;
}
@@ -329,7 +329,7 @@ guess_vcard_encoding (const char *filename)
g_print ("\n");
return VCARD_ENCODING_NONE;
}
-
+
fgets (line, 4096, handle);
if (line == NULL) {
fclose (handle);
@@ -337,7 +337,7 @@ guess_vcard_encoding (const char *filename)
return VCARD_ENCODING_NONE;
}
fclose (handle);
-
+
if (has_bom ((gunichar2*)line)) {
gunichar2 *utf16 = (gunichar2*)line;
/* Check for a BOM to try to detect UTF-16 encoded vcards
@@ -380,7 +380,7 @@ vcard_getwidget(EImport *ei, EImportTarget *target, EImportImporter *im)
{
GtkWidget *vbox, *selector;
ESource *primary;
- ESourceList *source_list;
+ ESourceList *source_list;
/* FIXME Better error handling */
if (!e_book_get_addressbooks (&source_list, NULL))
@@ -391,7 +391,7 @@ vcard_getwidget(EImport *ei, EImportTarget *target, EImportImporter *im)
selector = e_source_selector_new (source_list);
e_source_selector_show_selection (E_SOURCE_SELECTOR (selector), FALSE);
gtk_box_pack_start (GTK_BOX (vbox), selector, FALSE, TRUE, 6);
-
+
primary = g_datalist_get_data(&target->data, "vcard-source");
if (primary == NULL) {
primary = e_source_list_peek_source_any (source_list);
@@ -480,7 +480,7 @@ vcard_import(EImport *ei, EImportTarget *target, EImportImporter *im)
e_import_complete(ei, target);
return;
}
-
+
if (!g_file_get_contents (filename, &contents, NULL, NULL)) {
g_message (G_STRLOC ":Couldn't read file.");
g_free (filename);
@@ -522,7 +522,7 @@ vcard_import(EImport *ei, EImportTarget *target, EImportImporter *im)
else
vcard_import_done(gci);
}
-
+
static void
vcard_cancel(EImport *ei, EImportTarget *target, EImportImporter *im)
{
diff --git a/addressbook/printing/e-contact-print-style-editor.c b/addressbook/printing/e-contact-print-style-editor.c
index 0e4c3246b0..7ae6111e06 100644
--- a/addressbook/printing/e-contact-print-style-editor.c
+++ b/addressbook/printing/e-contact-print-style-editor.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-contact-print-style-editor.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -70,7 +70,7 @@ e_contact_print_style_editor_class_init (EContactPrintStyleEditorClass *klass)
object_class = (GtkObjectClass*) klass;
parent_class = gtk_type_class (gtk_vbox_get_type ());
-
+
object_class->set_arg = e_contact_print_style_editor_set_arg;
object_class->get_arg = e_contact_print_style_editor_get_arg;
object_class->destroy = e_contact_print_style_editor_destroy;
diff --git a/addressbook/printing/e-contact-print-style-editor.h b/addressbook/printing/e-contact-print-style-editor.h
index 1925a4a95a..0041c518da 100644
--- a/addressbook/printing/e-contact-print-style-editor.h
+++ b/addressbook/printing/e-contact-print-style-editor.h
@@ -51,7 +51,7 @@ typedef struct _EContactPrintStyleEditorClass EContactPrintStyleEditorClass;
struct _EContactPrintStyleEditor
{
GtkVBox parent;
-
+
/* item specific fields */
GladeXML *gui;
};
diff --git a/addressbook/printing/e-contact-print-types.h b/addressbook/printing/e-contact-print-types.h
index 44448d6796..fe554fff4a 100644
--- a/addressbook/printing/e-contact-print-types.h
+++ b/addressbook/printing/e-contact-print-types.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-contact-print-types.h
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
diff --git a/addressbook/printing/e-contact-print.c b/addressbook/printing/e-contact-print.c
index b8b1aee6f2..d2ca1a6e64 100644
--- a/addressbook/printing/e-contact-print.c
+++ b/addressbook/printing/e-contact-print.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-contact-print.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -225,10 +225,10 @@ e_contact_print_contact (EContact *contact, EContactPrintContext *ctxt)
cr = gtk_print_context_get_cairo_context (ctxt->context);
cairo_save(cr);
- ctxt->y += get_font_height (ctxt->style->headings_font) * .2;
+ ctxt->y += get_font_height (ctxt->style->headings_font) * .2;
file_as = e_contact_get (contact, E_CONTACT_FILE_AS);
-
+
if (ctxt->style->print_using_grey) {
cairo_save (cr);
cairo_set_source_rgb (cr, .85, .85, .85);
@@ -249,7 +249,7 @@ e_contact_print_contact (EContact *contact, EContactPrintContext *ctxt)
ctxt->y += get_font_height (ctxt->style->headings_font) * .2;
- for (field = E_CONTACT_FILE_AS; field != E_CONTACT_LAST_SIMPLE_STRING; field++)
+ for (field = E_CONTACT_FILE_AS; field != E_CONTACT_LAST_SIMPLE_STRING; field++)
{
const gchar *value;
gchar *text;
@@ -262,7 +262,7 @@ e_contact_print_contact (EContact *contact, EContactPrintContext *ctxt)
e_contact_pretty_name (field), value);
e_contact_output (
- ctxt->context, ctxt->style->body_font,
+ ctxt->context, ctxt->style->body_font,
ctxt->x, ctxt->y, -1, text);
ctxt->y += e_contact_text_height (
@@ -328,7 +328,7 @@ contacts_added (EBookView *book_view, const GList *contact_list,
}
}
-static void
+static void
sequence_complete (EBookView *book_view, const GList *contact_list,
EFlag *book_view_started)
{
@@ -627,9 +627,9 @@ contact_draw (EContact *contact, EContactPrintContext *ctxt)
if (ctxt->style->letter_headings)
e_contact_print_letter_heading (ctxt, ctxt->section);
ctxt->first_section = FALSE;
- }
+ }
- else if (!ctxt->first_contact && (ctxt->y > page_height)) {
+ else if (!ctxt->first_contact && (ctxt->y > page_height)) {
e_contact_start_new_column (ctxt);
if (ctxt->style->letter_headings)
e_contact_print_letter_heading (ctxt, ctxt->section);
@@ -648,7 +648,7 @@ contact_draw_page (GtkPrintOperation *operation,
{
g_list_foreach (ctxt->contact_list, (GFunc) contact_draw, ctxt);
}
-
+
static void
contact_end_print (GtkPrintOperation *operation,
GtkPrintContext *context,
diff --git a/addressbook/printing/e-contact-print.h b/addressbook/printing/e-contact-print.h
index 16fe8b8dcb..fbafb136aa 100644
--- a/addressbook/printing/e-contact-print.h
+++ b/addressbook/printing/e-contact-print.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-contact-print.h
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
diff --git a/addressbook/printing/test-contact-print-style-editor.c b/addressbook/printing/test-contact-print-style-editor.c
index f5d20eea77..b10d1433d0 100644
--- a/addressbook/printing/test-contact-print-style-editor.c
+++ b/addressbook/printing/test-contact-print-style-editor.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* test-contact-print-style-editor.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -42,7 +42,7 @@ static void destroy_callback(GtkWidget *app, gpointer data)
#if 0
static void about_callback( GtkWidget *widget, gpointer data )
{
-
+
const gchar *authors[] =
{
"Christopher James Lahey <clahey@umich.edu>",
@@ -55,7 +55,7 @@ static void about_callback( GtkWidget *widget, gpointer data )
authors,
_( "This should test the contact print style editor widget" ),
NULL);
- gtk_widget_show (about);
+ gtk_widget_show (about);
}
#endif
@@ -76,7 +76,7 @@ int main( int argc, char *argv[] )
app = gnome_app_new("Contact Print Style Editor Test", NULL);
editor = e_contact_print_style_editor_new("");
-
+
gnome_app_set_contents( GNOME_APP( app ), editor );
/* Connect the signals */
@@ -86,7 +86,7 @@ int main( int argc, char *argv[] )
gtk_widget_show_all( app );
- bonobo_main();
+ bonobo_main();
/* Not reached. */
return 0;
diff --git a/addressbook/printing/test-print.c b/addressbook/printing/test-print.c
index d86c33baea..7fc367d24d 100644
--- a/addressbook/printing/test-print.c
+++ b/addressbook/printing/test-print.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* test-print.c
* Copyright (C) 2000 Ximian, Inc.
* Author: Chris Lahey <clahey@ximian.com>
@@ -32,7 +32,7 @@
#if 0
static void about_callback( GtkWidget *widget, gpointer data )
{
-
+
const gchar *authors[] =
{
"Christopher James Lahey <clahey@umich.edu>",
@@ -45,7 +45,7 @@ static void about_callback( GtkWidget *widget, gpointer data )
authors,
_( "This should test the contact print code" ),
NULL);
- gtk_widget_show (about);
+ gtk_widget_show (about);
}
#endif
@@ -62,7 +62,7 @@ int main( int argc, char *argv[] )
NULL);
glade_init ();
-
+
shown_fields = g_list_append(shown_fields, "First field");
shown_fields = g_list_append(shown_fields, "Second field");
shown_fields = g_list_append(shown_fields, "Third field");
@@ -71,7 +71,7 @@ int main( int argc, char *argv[] )
/* does nothing */
e_contact_print (NULL, NULL, NULL, GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG);
- bonobo_main();
+ bonobo_main();
/* Not reached. */
return 0;
diff --git a/addressbook/tools/evolution-addressbook-export-list-cards.c b/addressbook/tools/evolution-addressbook-export-list-cards.c
index f09d481f46..6e8d18e89f 100644
--- a/addressbook/tools/evolution-addressbook-export-list-cards.c
+++ b/addressbook/tools/evolution-addressbook-export-list-cards.c
@@ -728,7 +728,7 @@ action_list_cards (GList *contacts, ActionContext * p_actctx)
#ifdef G_OS_WIN32
/* On Unix the parent exits already in
* fork_to_background(), but without fork() exit only
- * after doing the job. XXX Is this correct?
+ * after doing the job. XXX Is this correct?
*/
if (IsFirstOne == FALSE)
_exit (-1);
diff --git a/addressbook/util/eab-book-util.c b/addressbook/util/eab-book-util.c
index af73fe074b..07f37e1a05 100644
--- a/addressbook/util/eab-book-util.c
+++ b/addressbook/util/eab-book-util.c
@@ -13,12 +13,12 @@
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
@@ -100,8 +100,8 @@ eab_name_and_email_query (EBook *book,
* We only query against the username part of the address, to avoid not matching
* fred@foo.com and fred@mail.foo.com. While their may be namespace collisions
* in the usernames of everyone out there, it shouldn't be that bad. (Famous last words.)
- * But if name is missing we query against complete email id to avoid matching emails like
- * users@foo.org with users@bar.org
+ * But if name is missing we query against complete email id to avoid matching emails like
+ * users@foo.org with users@bar.org
*/
if (escaped_email) {
const gchar *t = escaped_email;
@@ -116,7 +116,7 @@ eab_name_and_email_query (EBook *book,
}
/* Build our name query.*/
-
+
if (escaped_name)
name_query = g_strdup_printf ("(or (beginswith \"file_as\" \"%s\") (beginswith \"full_name\" \"%s\"))", escaped_name, escaped_name);
@@ -185,21 +185,21 @@ eab_strstrcase (const char *haystack, const char *needle)
/* find the needle in the haystack neglecting case */
const char *ptr;
guint len;
-
+
g_return_val_if_fail (haystack != NULL, NULL);
g_return_val_if_fail (needle != NULL, NULL);
-
+
len = strlen (needle);
if (len > strlen (haystack))
return NULL;
-
+
if (len == 0)
return (char *) haystack;
-
+
for (ptr = haystack; *(ptr + len - 1) != '\0'; ptr++)
if (!g_ascii_strncasecmp (ptr, needle, len))
return (char *) ptr;
-
+
return NULL;
}
@@ -227,7 +227,7 @@ eab_contact_list_from_string (const char *str)
while (*p) {
if (*p != '\r') g_string_append_c (gstr, *p);
-
+
p++;
}
@@ -235,7 +235,7 @@ eab_contact_list_from_string (const char *str)
/* Note: The VCard standard says
*
- * vcard = "BEGIN" [ws] ":" [ws] "VCARD" [ws] 1*CRLF
+ * vcard = "BEGIN" [ws] ":" [ws] "VCARD" [ws] 1*CRLF
* items *CRLF "END" [ws] ":" [ws] "VCARD"
*
* which means we can have whitespace (e.g. "BEGIN : VCARD"). So we're not being
@@ -243,7 +243,7 @@ eab_contact_list_from_string (const char *str)
* would be to have a vcard parsing function that returned the end of the vcard
* parsed. Arguably, contact list parsing should all be in libebook's e-vcard.c,
* where we can do proper parsing and validation without code duplication. */
-
+
for (p = eab_strstrcase (p, "BEGIN:VCARD"); p; p = eab_strstrcase (q, "\nBEGIN:VCARD")) {
gchar *card_str;
@@ -361,8 +361,8 @@ static void
have_address_query_cb (EBook *book, EBookSimpleQueryStatus status, const GList *contacts, gpointer closure)
{
HaveAddressInfo *info = (HaveAddressInfo *) closure;
-
- info->cb (book,
+
+ info->cb (book,
info->email,
contacts && (status == E_BOOK_ERROR_OK) ? E_CONTACT (contacts->data) : NULL,
info->closure);
diff --git a/addressbook/util/eab-book-util.h b/addressbook/util/eab-book-util.h
index 5ba3460651..9de1b497be 100644
--- a/addressbook/util/eab-book-util.h
+++ b/addressbook/util/eab-book-util.h
@@ -13,12 +13,12 @@
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
diff --git a/calendar/common/authentication.c b/calendar/common/authentication.c
index f8bce7c86e..f11a0ed1ff 100644
--- a/calendar/common/authentication.c
+++ b/calendar/common/authentication.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Authors :
+/*
+ * Authors :
* Rodrigo Moya <rodrigo@ximian.com>
*
* Copyright 2003, Novell, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -59,7 +59,7 @@ ECal *
auth_new_cal_from_default (ECalSourceType type)
{
ECal *ecal = NULL;
-
+
if (!e_cal_open_default (&ecal, type, auth_func_cb, NULL, NULL))
return NULL;
diff --git a/calendar/common/authentication.h b/calendar/common/authentication.h
index 4cc398f522..2b5804c039 100644
--- a/calendar/common/authentication.h
+++ b/calendar/common/authentication.h
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Authors :
+/*
+ * Authors :
* Rodrigo Moya <rodrigo@ximian.com>
*
* Copyright 2003, Novell, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/conduits/calendar/calendar-conduit.c b/calendar/conduits/calendar/calendar-conduit.c
index b37941aafd..2654477e0f 100644
--- a/calendar/conduits/calendar/calendar-conduit.c
+++ b/calendar/conduits/calendar/calendar-conduit.c
@@ -4,7 +4,7 @@
* Copyright (C) 1998 Free Software Foundation
* Copyright (C) 2000 Ximian, Inc.
*
- * Authors: Eskil Heyn Olsen <deity@eskil.dk>
+ * Authors: Eskil Heyn Olsen <deity@eskil.dk>
* JP Rosevear <jpr@ximian.com>
*
* This program is free software; you can redistribute it and/or
@@ -56,7 +56,7 @@ void conduit_destroy_gpilot_conduit (GnomePilotConduit*);
#define LOG(x) x
#else
#define LOG(x)
-#endif
+#endif
#define WARN g_warning
#define INFO g_message
@@ -101,18 +101,18 @@ struct _ECalConduitCfg {
ESource *source;
gboolean secret;
gboolean multi_day_split;
-
+
gchar *last_uri;
};
static ECalConduitCfg *
-calconduit_load_configuration (guint32 pilot_id)
+calconduit_load_configuration (guint32 pilot_id)
{
ECalConduitCfg *c;
GnomePilotConduitManagement *management;
GnomePilotConduitConfig *config;
gchar prefix[256];
-
+
c = g_new0 (ECalConduitCfg, 1);
g_assert (c != NULL);
@@ -152,14 +152,14 @@ calconduit_load_configuration (guint32 pilot_id)
char *filename = g_filename_from_uri (c->last_uri, NULL, NULL);
const char *path = filename;
const char *home;
-
+
home = g_get_home_dir ();
-
+
if (!strncmp (path, home, strlen (home))) {
path += strlen (home);
if (G_IS_DIR_SEPARATOR (*path))
path++;
-
+
if (!strcmp (path, "evolution/local/Calendar/calendar.ics")) {
gchar *new_filename =
g_build_filename (home,
@@ -173,14 +173,14 @@ calconduit_load_configuration (guint32 pilot_id)
}
g_free (filename);
}
-
- gnome_config_pop_prefix ();
+
+ gnome_config_pop_prefix ();
return c;
}
static void
-calconduit_save_configuration (ECalConduitCfg *c)
+calconduit_save_configuration (ECalConduitCfg *c)
{
gchar prefix[256];
@@ -199,7 +199,7 @@ calconduit_save_configuration (ECalConduitCfg *c)
}
static ECalConduitCfg*
-calconduit_dupe_configuration (ECalConduitCfg *c)
+calconduit_dupe_configuration (ECalConduitCfg *c)
{
ECalConduitCfg *retval;
@@ -216,12 +216,12 @@ calconduit_dupe_configuration (ECalConduitCfg *c)
retval->secret = c->secret;
retval->multi_day_split = c->multi_day_split;
retval->last_uri = g_strdup (c->last_uri);
-
+
return retval;
}
-static void
-calconduit_destroy_configuration (ECalConduitCfg *c)
+static void
+calconduit_destroy_configuration (ECalConduitCfg *c)
{
g_return_if_fail (c != NULL);
@@ -237,12 +237,12 @@ struct _ECalConduitGui {
};
static ECalConduitGui *
-e_cal_gui_new (EPilotSettings *ps)
+e_cal_gui_new (EPilotSettings *ps)
{
ECalConduitGui *gui;
GtkWidget *lbl;
gint rows;
-
+
g_return_val_if_fail (ps != NULL, NULL);
g_return_val_if_fail (E_IS_PILOT_SETTINGS (ps), NULL);
@@ -257,12 +257,12 @@ e_cal_gui_new (EPilotSettings *ps)
gtk_table_attach_defaults (GTK_TABLE (ps), gui->multi_day_split, 1, 2, rows, rows + 1);
gtk_widget_show (lbl);
gtk_widget_show (gui->multi_day_split);
-
+
return gui;
}
static void
-e_cal_gui_fill_widgets (ECalConduitGui *gui, ECalConduitCfg *cfg)
+e_cal_gui_fill_widgets (ECalConduitGui *gui, ECalConduitCfg *cfg)
{
g_return_if_fail (gui != NULL);
g_return_if_fail (cfg != NULL);
@@ -272,7 +272,7 @@ e_cal_gui_fill_widgets (ECalConduitGui *gui, ECalConduitCfg *cfg)
}
static void
-e_cal_gui_fill_config (ECalConduitGui *gui, ECalConduitCfg *cfg)
+e_cal_gui_fill_config (ECalConduitGui *gui, ECalConduitCfg *cfg)
{
g_return_if_fail (gui != NULL);
g_return_if_fail (cfg != NULL);
@@ -281,7 +281,7 @@ e_cal_gui_fill_config (ECalConduitGui *gui, ECalConduitCfg *cfg)
}
static void
-e_cal_gui_destroy (ECalConduitGui *gui)
+e_cal_gui_destroy (ECalConduitGui *gui)
{
g_free (gui);
}
@@ -294,7 +294,7 @@ struct _ECalConduitContext {
ECalConduitCfg *new_cfg;
ECalConduitGui *gui;
GtkWidget *ps;
-
+
struct AppointmentAppInfo ai;
ECal *client;
@@ -305,18 +305,18 @@ struct _ECalConduitContext {
GList *changed;
GHashTable *changed_hash;
GList *locals;
-
+
EPilotMap *map;
};
static ECalConduitContext *
-e_calendar_context_new (guint32 pilot_id)
+e_calendar_context_new (guint32 pilot_id)
{
ECalConduitContext *ctxt;
ctxt = g_new0 (ECalConduitContext, 1);
g_assert (ctxt != NULL);
-
+
ctxt->cfg = calconduit_load_configuration (pilot_id);
ctxt->new_cfg = calconduit_dupe_configuration (ctxt->cfg);
ctxt->ps = NULL;
@@ -329,12 +329,12 @@ e_calendar_context_new (guint32 pilot_id)
ctxt->changed_hash = NULL;
ctxt->locals = NULL;
ctxt->map = NULL;
-
+
return ctxt;
}
static gboolean
-e_calendar_context_foreach_change (gpointer key, gpointer value, gpointer data)
+e_calendar_context_foreach_change (gpointer key, gpointer value, gpointer data)
{
g_free (key);
@@ -345,7 +345,7 @@ static void
e_calendar_context_destroy (ECalConduitContext *ctxt)
{
GList *l;
-
+
g_return_if_fail (ctxt != NULL);
if (ctxt->cfg != NULL)
@@ -358,27 +358,27 @@ e_calendar_context_destroy (ECalConduitContext *ctxt)
if (ctxt->client != NULL)
g_object_unref (ctxt->client);
if (ctxt->default_comp != NULL)
- g_object_unref (ctxt->default_comp);
+ g_object_unref (ctxt->default_comp);
if (ctxt->comps != NULL) {
for (l = ctxt->comps; l; l = l->next)
g_object_unref (l->data);
g_list_free (ctxt->comps);
}
-
+
if (ctxt->changed != NULL)
e_cal_free_change_list (ctxt->changed);
-
+
if (ctxt->changed_hash != NULL) {
g_hash_table_foreach_remove (ctxt->changed_hash, e_calendar_context_foreach_change, NULL);
g_hash_table_destroy (ctxt->changed_hash);
}
-
+
if (ctxt->locals != NULL) {
for (l = ctxt->locals; l != NULL; l = l->next)
calconduit_destroy_record (l->data);
g_list_free (ctxt->locals);
}
-
+
if (ctxt->map != NULL)
e_pilot_map_destroy (ctxt->map);
}
@@ -432,7 +432,7 @@ static char *print_remote (GnomePilotRecord *remote)
sprintf (buff, "[NULL]");
return buff;
}
-
+
unpack_Appointment (&appt, buffer, datebook_v1);
pi_buffer_free(buffer);
#else
@@ -481,12 +481,12 @@ start_calendar_server (ECalConduitContext *ctxt)
As of Evo. 2.5.x, timezone should be set before
calling e_cal_open.
*/
-
+
if (ctxt->timezone) {
if (!e_cal_set_default_timezone (ctxt->client, ctxt->timezone, NULL))
return -1;
}
-
+
if (e_source_get_property (ctxt->cfg->source, "auth")) {
EUri *e_uri;
@@ -510,14 +510,14 @@ start_calendar_server (ECalConduitContext *ctxt)
/* Utility routines */
static icaltimezone *
-get_timezone (ECal *client, const char *tzid)
+get_timezone (ECal *client, const char *tzid)
{
icaltimezone *timezone = NULL;
timezone = icaltimezone_get_builtin_timezone_from_tzid (tzid);
- if (timezone == NULL)
+ if (timezone == NULL)
e_cal_get_timezone (client, tzid, &timezone, NULL);
-
+
return timezone;
}
@@ -536,29 +536,29 @@ get_default_timezone (void)
g_free (location);
location = g_strdup ("UTC");
}
-
+
timezone = icaltimezone_get_builtin_timezone (location);
g_free (location);
g_object_unref (listener);
- return timezone;
+ return timezone;
}
static char *
-map_name (ECalConduitContext *ctxt)
+map_name (ECalConduitContext *ctxt)
{
char *filename;
-
+
filename = g_strdup_printf ("%s/.evolution/calendar/local/system/pilot-map-calendar-%d.xml",
g_get_home_dir (), ctxt->cfg->pilot_id);
-
+
return filename;
}
static icalrecurrencetype_weekday
-get_ical_day (int day)
+get_ical_day (int day)
{
switch (day) {
case 0:
@@ -581,7 +581,7 @@ get_ical_day (int day)
}
static int
-get_pilot_day (icalrecurrencetype_weekday wd)
+get_pilot_day (icalrecurrencetype_weekday wd)
{
switch (wd) {
case ICAL_SUNDAY_WEEKDAY:
@@ -604,24 +604,24 @@ get_pilot_day (icalrecurrencetype_weekday wd)
}
static gboolean
-is_empty_time (struct tm time)
+is_empty_time (struct tm time)
{
- if (time.tm_sec || time.tm_min || time.tm_hour
- || time.tm_mday || time.tm_mon || time.tm_year)
+ if (time.tm_sec || time.tm_min || time.tm_hour
+ || time.tm_mday || time.tm_mon || time.tm_year)
return FALSE;
-
+
return TRUE;
}
static gboolean
-is_all_day (ECal *client, ECalComponentDateTime *dt_start, ECalComponentDateTime *dt_end)
+is_all_day (ECal *client, ECalComponentDateTime *dt_start, ECalComponentDateTime *dt_end)
{
time_t dt_start_time, dt_end_time;
icaltimezone *timezone;
if (dt_start->value->is_date && dt_end->value->is_date)
return TRUE;
-
+
timezone = get_timezone (client, dt_start->tzid);
dt_start_time = icaltime_as_timet_with_zone (*dt_start->value, timezone);
dt_end_time = icaltime_as_timet_with_zone (*dt_end->value, get_timezone (client, dt_end->tzid));
@@ -646,7 +646,7 @@ process_multi_day (ECalConduitContext *ctxt, ECalChange *ccc, GList **multi_comp
*multi_ccc = NULL;
*multi_comp = NULL;
-
+
if (ccc->type == E_CAL_CHANGE_DELETED)
return FALSE;
@@ -665,7 +665,7 @@ process_multi_day (ECalConduitContext *ctxt, ECalChange *ccc, GList **multi_comp
tz_end = get_timezone (ctxt->client, dt_end.tzid);
event_end = icaltime_as_timet_with_zone (*dt_end.value, tz_end);
- day_end = time_day_end_with_zone (event_start, ctxt->timezone);
+ day_end = time_day_end_with_zone (event_start, ctxt->timezone);
if (day_end >= event_end) {
ret = FALSE;
goto cleanup;
@@ -676,7 +676,7 @@ process_multi_day (ECalConduitContext *ctxt, ECalChange *ccc, GList **multi_comp
if (dt_start.value->is_date && dt_end.value->is_date)
is_date = TRUE;
-
+
old_start_value = dt_start.value;
old_end_value = dt_end.value;
while (!last) {
@@ -685,7 +685,7 @@ process_multi_day (ECalConduitContext *ctxt, ECalChange *ccc, GList **multi_comp
char *new_uid = e_cal_component_gen_uid ();
struct icaltimetype start_value, end_value;
ECalChange *c = NULL;
-
+
if (day_end >= event_end) {
day_end = event_end;
last = TRUE;
@@ -696,13 +696,13 @@ process_multi_day (ECalConduitContext *ctxt, ECalChange *ccc, GList **multi_comp
start_value = icaltime_from_timet_with_zone (event_start, is_date, tz_start);
dt_start.value = &start_value;
e_cal_component_set_dtstart (clone, &dt_start);
-
+
end_value = icaltime_from_timet_with_zone (day_end, is_date, tz_end);
dt_end.value = &end_value;
e_cal_component_set_dtend (clone, &dt_end);
e_cal_component_commit_sequence (clone);
-
+
/* FIXME Error handling */
ical_comp = e_cal_component_get_icalcomponent (clone);
if (!ical_comp) {
@@ -717,7 +717,7 @@ process_multi_day (ECalConduitContext *ctxt, ECalChange *ccc, GList **multi_comp
c = g_new0 (ECalChange, 1);
c->comp = clone;
c->type = E_CAL_CHANGE_ADDED;
-
+
*multi_ccc = g_list_prepend (*multi_ccc, c);
*multi_comp = g_list_prepend (*multi_comp, g_object_ref (c->comp));
@@ -728,7 +728,7 @@ process_multi_day (ECalConduitContext *ctxt, ECalChange *ccc, GList **multi_comp
}
dt_start.value = old_start_value;
dt_end.value = old_end_value;
-
+
e_cal_component_get_uid (ccc->comp, &uid);
/* FIXME Error handling */
if (e_cal_component_is_instance (ccc->comp) || e_cal_component_has_recurrences (ccc->comp))
@@ -754,21 +754,21 @@ nth_weekday (int pos, icalrecurrencetype_weekday weekday)
}
static GList *
-next_changed_item (ECalConduitContext *ctxt, GList *changes)
+next_changed_item (ECalConduitContext *ctxt, GList *changes)
{
ECalChange *ccc;
GList *l;
-
+
for (l = changes; l != NULL; l = l->next) {
const char *uid;
ccc = l->data;
-
+
e_cal_component_get_uid (ccc->comp, &uid);
if (g_hash_table_lookup (ctxt->changed_hash, uid))
return l;
}
-
+
return NULL;
}
@@ -781,21 +781,21 @@ compute_status (ECalConduitContext *ctxt, ECalLocalRecord *local, const char *ui
local->local.secret = FALSE;
ccc = g_hash_table_lookup (ctxt->changed_hash, uid);
-
+
if (ccc == NULL) {
local->local.attr = GnomePilotRecordNothing;
return;
}
-
+
switch (ccc->type) {
case E_CAL_CHANGE_ADDED:
local->local.attr = GnomePilotRecordNew;
break;
-
+
case E_CAL_CHANGE_MODIFIED:
local->local.attr = GnomePilotRecordModified;
break;
-
+
case E_CAL_CHANGE_DELETED:
local->local.attr = GnomePilotRecordDeleted;
break;
@@ -806,16 +806,16 @@ static gboolean
rrules_mostly_equal (struct icalrecurrencetype *a, struct icalrecurrencetype *b)
{
struct icalrecurrencetype acopy, bcopy;
-
+
acopy = *a;
bcopy = *b;
-
+
acopy.until = bcopy.until = icaltime_null_time ();
acopy.count = bcopy.count = 0;
-
+
if (!memcmp (&acopy, &bcopy, sizeof (struct icalrecurrencetype)))
return TRUE;
-
+
return FALSE;
}
@@ -823,7 +823,7 @@ static gboolean
find_last_cb (ECalComponent *comp, time_t start, time_t end, gpointer data)
{
time_t *last = data;
-
+
*last = start;
return TRUE;
@@ -858,25 +858,25 @@ local_record_to_pilot_record (ECalLocalRecord *local,
pi_set_error(ctxt->dbi->pilot_socket, PI_ERR_GENERIC_MEMORY);
return p;
}
-
+
pack_Appointment (local->appt, buffer, datebook_v1);
p.record = g_new0(unsigned char, buffer->used);
p.length = buffer->used;
memcpy(p.record, buffer->data, buffer->used);
-
- pi_buffer_free(buffer);
+
+ pi_buffer_free(buffer);
#else
p.record = (unsigned char *)record;
p.length = pack_Appointment (local->appt, p.record, 0xffff);
#endif
- return p;
+ return p;
}
/*
* converts a ECalComponent object to a ECalLocalRecord
*/
static void
-local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduitContext *ctxt)
+local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduitContext *ctxt)
{
const char *uid;
ECalComponentText summary;
@@ -886,13 +886,13 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
ECalComponentClassification classif;
icaltimezone *default_tz = ctxt->timezone;
int i;
-
+
g_return_if_fail (local != NULL);
g_return_if_fail (comp != NULL);
local->comp = comp;
g_object_ref (comp);
-
+
e_cal_component_get_uid (local->comp, &uid);
local->local.ID = e_pilot_map_lookup_pid (ctxt->map, uid, TRUE);
compute_status (ctxt, local, uid);
@@ -900,30 +900,30 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
local->appt = g_new0 (struct Appointment, 1);
/* Handle the fields and category we don't sync by making sure
- * we don't overwrite them
+ * we don't overwrite them
*/
if (local->local.ID != 0) {
int cat = 0;
#ifdef PILOT_LINK_0_12
struct Appointment appt;
pi_buffer_t * record;
-
+
record = pi_buffer_new(DLP_BUF_SIZE);
if(record == NULL){
pi_set_error(ctxt->dbi->pilot_socket, PI_ERR_GENERIC_MEMORY);
return;
}
#else
- struct Appointment appt;
+ struct Appointment appt;
char record[0xffff];
-#endif
- if (dlp_ReadRecordById (ctxt->dbi->pilot_socket,
+#endif
+ if (dlp_ReadRecordById (ctxt->dbi->pilot_socket,
ctxt->dbi->db_handle,
#ifdef PILOT_LINK_0_12
- local->local.ID, record,
+ local->local.ID, record,
NULL, NULL, &cat) > 0) {
#else
- local->local.ID, &record,
+ local->local.ID, &record,
NULL, NULL, NULL, &cat) > 0) {
#endif
local->local.category = cat;
@@ -942,14 +942,14 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
pi_buffer_free (record);
#endif
}
-
+
/*Category support*/
e_pilot_local_category_to_remote(&(local->local.category), comp, &(ctxt->ai.category));
/* STOP: don't replace these with g_strdup, since free_Appointment
uses free to deallocate */
e_cal_component_get_summary (comp, &summary);
- if (summary.value)
+ if (summary.value)
local->appt->description = e_pilot_utf8_to_pchar (summary.value);
e_cal_component_get_description_list (comp, &d_list);
@@ -967,17 +967,17 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
e_cal_component_get_dtstart (comp, &dt_start);
e_cal_component_get_dtend (comp, &dt_end);
if (dt_start.value) {
- icaltimezone_convert_time (dt_start.value,
+ icaltimezone_convert_time (dt_start.value,
get_timezone (ctxt->client, dt_start.tzid),
default_tz);
local->appt->begin = icaltimetype_to_tm (dt_start.value);
}
-
+
if (dt_start.value && dt_end.value) {
if (is_all_day (ctxt->client, &dt_start, &dt_end)) {
local->appt->event = 1;
} else {
- icaltimezone_convert_time (dt_end.value,
+ icaltimezone_convert_time (dt_end.value,
get_timezone (ctxt->client, dt_end.tzid),
default_tz);
local->appt->end = icaltimetype_to_tm (dt_end.value);
@@ -987,7 +987,7 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
local->appt->event = 1;
}
e_cal_component_free_datetime (&dt_start);
- e_cal_component_free_datetime (&dt_end);
+ e_cal_component_free_datetime (&dt_end);
/* Recurrence Rules */
local->appt->repeatType = repeatNone;
@@ -996,10 +996,10 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
if (e_cal_component_has_rrules (comp)) {
GSList *list;
struct icalrecurrencetype *recur;
-
+
e_cal_component_get_rrule_list (comp, &list);
recur = list->data;
-
+
switch (recur->freq) {
case ICAL_DAILY_RECURRENCE:
local->appt->repeatType = repeatDaily;
@@ -1012,18 +1012,18 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
wd = icalrecurrencetype_day_day_of_week (recur->by_day[i]);
local->appt->repeatDays[get_pilot_day (wd)] = 1;
}
-
+
break;
case ICAL_MONTHLY_RECURRENCE:
if (recur->by_month_day[0] != ICAL_RECURRENCE_ARRAY_MAX) {
local->appt->repeatType = repeatMonthlyByDate;
break;
}
-
+
/* Not going to work with -ve by_day/by_set_pos other than -1,
* pilot doesn't support that anyhow */
local->appt->repeatType = repeatMonthlyByDay;
- switch (recur->by_set_pos[0] != ICAL_RECURRENCE_ARRAY_MAX ? recur->by_set_pos[0]
+ switch (recur->by_set_pos[0] != ICAL_RECURRENCE_ARRAY_MAX ? recur->by_set_pos[0]
: icalrecurrencetype_day_position (recur->by_day[0])) {
case 1:
local->appt->repeatDay = dom1stSun;
@@ -1054,11 +1054,11 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
if (local->appt->repeatType != repeatNone) {
local->appt->repeatFrequency = recur->interval;
}
-
+
if (!icaltime_is_null_time (recur->until)) {
local->appt->repeatForever = 0;
- local->appt->repeatEnd = icaltimetype_to_tm_with_zone (&recur->until,
- icaltimezone_get_utc_timezone (),
+ local->appt->repeatEnd = icaltimetype_to_tm_with_zone (&recur->until,
+ icaltimezone_get_utc_timezone (),
default_tz);
} else if (recur->count > 0) {
time_t last = -1;
@@ -1066,37 +1066,37 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
/* The palm does not support count recurrences */
local->appt->repeatForever = 0;
- e_cal_recur_generate_instances (comp, -1, -1, find_last_cb, &last,
- e_cal_resolve_tzid_cb, ctxt->client,
+ e_cal_recur_generate_instances (comp, -1, -1, find_last_cb, &last,
+ e_cal_resolve_tzid_cb, ctxt->client,
default_tz);
itt = icaltime_from_timet_with_zone (last, TRUE, default_tz);
local->appt->repeatEnd = icaltimetype_to_tm (&itt);
} else {
local->appt->repeatForever = 1;
}
-
+
e_cal_component_free_recur_list (list);
}
/* Exceptions */
e_cal_component_get_exdate_list (comp, &edl);
local->appt->exceptions = g_slist_length (edl);
- local->appt->exception = g_new0 (struct tm, local->appt->exceptions);
+ local->appt->exception = g_new0 (struct tm, local->appt->exceptions);
for (l = edl, i = 0; l != NULL; l = l->next, i++) {
ECalComponentDateTime *dt = l->data;
- icaltimezone_convert_time (dt->value,
+ icaltimezone_convert_time (dt->value,
icaltimezone_get_utc_timezone (),
default_tz);
local->appt->exception[i] = icaltimetype_to_tm (dt->value);
}
e_cal_component_free_exdate_list (edl);
}
-
+
/* Alarm */
local->appt->alarm = 0;
if (e_cal_component_has_alarms (comp)) {
- GList *uids, *l;
+ GList *uids, *l;
ECalComponentAlarm *alarm;
ECalComponentAlarmTrigger trigger;
@@ -1104,11 +1104,11 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
for (l = uids; l != NULL; l = l->next) {
alarm = e_cal_component_get_alarm (comp, l->data);
e_cal_component_alarm_get_trigger (alarm, &trigger);
-
+
if ((trigger.type == E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_START
&& trigger.u.rel_duration.is_neg)) {
local->appt->advanceUnits = advMinutes;
- local->appt->advance =
+ local->appt->advance =
trigger.u.rel_duration.minutes
+ trigger.u.rel_duration.hours * 60
+ trigger.u.rel_duration.days * 60 * 24
@@ -1116,7 +1116,7 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
if (local->appt->advance > PILOT_MAX_ADVANCE) {
local->appt->advanceUnits = advHours;
- local->appt->advance =
+ local->appt->advance =
trigger.u.rel_duration.minutes / 60
+ trigger.u.rel_duration.hours
+ trigger.u.rel_duration.days * 24
@@ -1140,7 +1140,7 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
}
cal_obj_uid_list_free (uids);
}
-
+
e_cal_component_get_classification (comp, &classif);
if (classif == E_CAL_COMPONENT_CLASS_PRIVATE)
@@ -1148,10 +1148,10 @@ local_record_from_comp (ECalLocalRecord *local, ECalComponent *comp, ECalConduit
else
local->local.secret = 0;
- local->local.archived = 0;
+ local->local.archived = 0;
}
-static void
+static void
local_record_from_uid (ECalLocalRecord *local,
const char *uid,
ECalConduitContext *ctxt)
@@ -1199,7 +1199,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
struct icalrecurrencetype recur;
ECalComponentText summary = {NULL, NULL};
ECalComponentDateTime dt = {NULL, NULL};
- GSList *edl = NULL;
+ GSList *edl = NULL;
char *txt;
int pos, i;
#ifdef PILOT_LINK_0_12
@@ -1212,7 +1212,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
if(buffer == NULL){
return NULL;
}
-
+
if(pi_buffer_append(buffer, remote->record, remote->length)==NULL){
return NULL;
}
@@ -1237,7 +1237,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
summary.value = txt = e_pilot_utf8_from_pchar (appt.description);
e_cal_component_set_summary (comp, &summary);
free (txt);
-
+
/*Category support*/
e_pilot_remote_category_to_local(remote->category, comp, category);
@@ -1255,7 +1255,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
e_cal_component_set_description_list (comp, &l);
free (txt);
- }
+ }
if (appt.event && !is_empty_time (appt.begin)) {
it = tm_to_icaltimetype (&appt.begin, TRUE);
@@ -1272,7 +1272,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
e_cal_component_set_dtstart (comp, &dt);
}
- if (!is_empty_time (appt.end)) {
+ if (!is_empty_time (appt.end)) {
it = tm_to_icaltimetype (&appt.end, FALSE);
dt.value = &it;
e_cal_component_set_dtend (comp, &dt);
@@ -1301,19 +1301,19 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
if (appt.repeatDays[i])
recur.by_day[pos++] = get_ical_day (i);
}
-
+
break;
case repeatMonthlyByDay:
recur.freq = ICAL_MONTHLY_RECURRENCE;
recur.interval = appt.repeatFrequency;
if (appt.repeatDay < domLastSun)
- recur.by_day[0] = nth_weekday ((appt.repeatDay / 7) + 1,
+ recur.by_day[0] = nth_weekday ((appt.repeatDay / 7) + 1,
get_ical_day (appt.repeatDay % 7));
else
- recur.by_day[0] = nth_weekday (-1, get_ical_day (appt.repeatDay % 7));
+ recur.by_day[0] = nth_weekday (-1, get_ical_day (appt.repeatDay % 7));
break;
-
+
case repeatMonthlyByDate:
recur.freq = ICAL_MONTHLY_RECURRENCE;
recur.interval = appt.repeatFrequency;
@@ -1324,7 +1324,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
recur.freq = ICAL_YEARLY_RECURRENCE;
recur.interval = appt.repeatFrequency;
break;
-
+
default:
g_assert_not_reached ();
}
@@ -1332,12 +1332,12 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
if (recur.freq != ICAL_NO_RECURRENCE) {
GSList *list = NULL, *existing;
struct icalrecurrencetype *erecur;
-
+
/* recurrence start of week */
recur.week_start = get_ical_day (appt.repeatWeekstart);
if (!appt.repeatForever) {
- recur.until = tm_to_icaltimetype (&appt.repeatEnd, TRUE);
+ recur.until = tm_to_icaltimetype (&appt.repeatEnd, TRUE);
}
list = g_slist_append (list, &recur);
@@ -1348,21 +1348,21 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
if (!appt.repeatForever && e_cal_component_has_rrules (in_comp)) {
e_cal_component_get_rrule_list (in_comp, &existing);
erecur = existing->data;
-
- /* If the rules are otherwise the same and the existing uses count,
+
+ /* If the rules are otherwise the same and the existing uses count,
see if they end at the same point */
- if (rrules_mostly_equal (&recur, erecur) &&
+ if (rrules_mostly_equal (&recur, erecur) &&
icaltime_is_null_time (erecur->until) && erecur->count > 0) {
time_t last, elast;
-
- e_cal_recur_generate_instances (comp, -1, -1, find_last_cb, &last,
+
+ e_cal_recur_generate_instances (comp, -1, -1, find_last_cb, &last,
e_cal_resolve_tzid_cb, client,
timezone);
- e_cal_recur_generate_instances (in_comp, -1, -1, find_last_cb, &elast,
- e_cal_resolve_tzid_cb, client,
+ e_cal_recur_generate_instances (in_comp, -1, -1, find_last_cb, &elast,
+ e_cal_resolve_tzid_cb, client,
timezone);
-
+
if (last == elast) {
recur.until = icaltime_null_time ();
recur.count = erecur->count;
@@ -1373,7 +1373,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
g_slist_free (list);
} else {
- e_cal_component_set_rrule_list (comp, NULL);
+ e_cal_component_set_rrule_list (comp, NULL);
}
/* Exceptions */
@@ -1382,11 +1382,11 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
ECalComponentDateTime *dt = g_new0 (ECalComponentDateTime, 1);
dt->value = g_new0 (struct icaltimetype, 1);
- dt->tzid = NULL;
-
+ dt->tzid = NULL;
+
ex = appt.exception[i];
*dt->value = tm_to_icaltimetype (&ex, TRUE);
-
+
edl = g_slist_prepend (edl, dt);
}
e_cal_component_set_exdate_list (comp, edl);
@@ -1397,10 +1397,10 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
ECalComponentAlarm *alarm = NULL;
ECalComponentAlarmTrigger trigger;
gboolean found = FALSE;
-
+
if (e_cal_component_has_alarms (comp)) {
GList *uids, *l;
-
+
uids = e_cal_component_get_alarm_uids (comp);
for (l = uids; l != NULL; l = l->next) {
alarm = e_cal_component_get_alarm (comp, l->data);
@@ -1438,7 +1438,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
e_cal_component_add_alarm (comp, alarm);
e_cal_component_alarm_free (alarm);
}
-
+
e_cal_component_set_transparency (comp, E_CAL_COMPONENT_TRANSP_NONE);
if (remote->secret)
@@ -1447,7 +1447,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
e_cal_component_set_classification (comp, E_CAL_COMPONENT_CLASS_PUBLIC);
e_cal_component_commit_sequence (comp);
-
+
free_Appointment (&appt);
return comp;
@@ -1459,7 +1459,7 @@ check_for_slow_setting (GnomePilotConduit *c, ECalConduitContext *ctxt)
GnomePilotConduitStandard *conduit = GNOME_PILOT_CONDUIT_STANDARD (c);
int map_count;
const char *uri;
-
+
/* If there are objects but no log */
map_count = g_hash_table_size (ctxt->map->pid_map);
if (map_count == 0)
@@ -1472,7 +1472,7 @@ check_for_slow_setting (GnomePilotConduit *c, ECalConduitContext *ctxt)
gnome_pilot_conduit_standard_set_slow (conduit, TRUE);
e_pilot_map_clear (ctxt->map);
}
-
+
if (gnome_pilot_conduit_standard_get_slow (conduit)) {
ctxt->map->write_touched_only = TRUE;
LOG (g_message ( " doing slow sync\n" ));
@@ -1502,7 +1502,7 @@ pre_sync (GnomePilotConduit *conduit,
LOG (g_message ( "---------------------------------------------------------\n" ));
LOG (g_message ( "pre_sync: Calendar Conduit v.%s", CONDUIT_VERSION ));
- ctxt->dbi = dbi;
+ ctxt->dbi = dbi;
ctxt->client = NULL;
/* Get the timezone */
@@ -1510,7 +1510,7 @@ pre_sync (GnomePilotConduit *conduit,
if (ctxt->timezone == NULL)
return -1;
LOG (g_message ( " Using timezone: %s", icaltimezone_get_tzid (ctxt->timezone) ));
-
+
if (start_calendar_server (ctxt) != 0) {
WARN(_("Could not start evolution-data-server"));
gnome_pilot_conduit_error (conduit, _("Could not start evolution-data-server"));
@@ -1543,15 +1543,15 @@ pre_sync (GnomePilotConduit *conduit,
return -1;
ctxt->changed_hash = g_hash_table_new (g_str_hash, g_str_equal);
g_free (change_id);
-
+
/* See if we need to split up any events */
for (l = ctxt->changed; l != NULL; l = l->next) {
ECalChange *ccc = l->data;
GList *multi_comp = NULL, *multi_ccc = NULL;
-
+
if (process_multi_day (ctxt, ccc, &multi_comp, &multi_ccc)) {
ctxt->comps = g_list_concat (ctxt->comps, multi_comp);
-
+
added = g_list_concat (added, multi_ccc);
removed = g_list_prepend (removed, ccc);
}
@@ -1571,11 +1571,11 @@ pre_sync (GnomePilotConduit *conduit,
}
}
g_list_free (removed);
-
+
for (l = ctxt->changed; l != NULL; l = l->next) {
ECalChange *ccc = l->data;
const char *uid;
-
+
e_cal_component_get_uid (ccc->comp, &uid);
if (!e_pilot_map_uid_is_archived (ctxt->map, uid)) {
@@ -1596,7 +1596,7 @@ pre_sync (GnomePilotConduit *conduit,
e_pilot_map_remove_by_uid (ctxt->map, uid);
}
}
-
+
/* Set the count information */
num_records = g_list_length (ctxt->comps);
gnome_pilot_conduit_sync_abs_set_num_local_records(abs_conduit, num_records);
@@ -1639,7 +1639,7 @@ pre_sync (GnomePilotConduit *conduit,
if (ctxt->cfg->sync_type == GnomePilotConduitSyncTypeCopyToPilot
|| ctxt->cfg->sync_type == GnomePilotConduitSyncTypeCopyFromPilot)
ctxt->map->write_touched_only = TRUE;
-
+
return 0;
}
@@ -1652,19 +1652,19 @@ post_sync (GnomePilotConduit *conduit,
gchar *filename, *change_id;
unsigned char *buf;
int dlpRetVal, len;
-
+
LOG (g_message ( "post_sync: Calendar Conduit v.%s", CONDUIT_VERSION ));
-
+
/* Write AppBlock to PDA - updates categories */
buf = (unsigned char*)g_malloc (0xffff);
-
+
len = pack_AppointmentAppInfo (&(ctxt->ai), buf, 0xffff);
-
- dlpRetVal = dlp_WriteAppBlock (dbi->pilot_socket, dbi->db_handle,
+
+ dlpRetVal = dlp_WriteAppBlock (dbi->pilot_socket, dbi->db_handle,
(unsigned char *)buf, len);
-
+
g_free (buf);
-
+
if (dlpRetVal < 0) {
WARN ( ("Could not write pilot's Calendar application block"));
WARN ("dlp_WriteAppBlock(...) = %d", dlpRetVal);
@@ -1676,11 +1676,11 @@ post_sync (GnomePilotConduit *conduit,
g_free (ctxt->cfg->last_uri);
ctxt->cfg->last_uri = g_strdup (e_cal_get_uri (ctxt->client));
calconduit_save_configuration (ctxt->cfg);
-
+
filename = map_name (ctxt);
e_pilot_map_write (filename, ctxt->map);
g_free (filename);
-
+
/* FIX ME ugly hack - our changes musn't count, this does introduce
* a race condition if anyone changes a record elsewhere during sycnc
*/
@@ -1688,7 +1688,7 @@ post_sync (GnomePilotConduit *conduit,
if (e_cal_get_changes (ctxt->client, change_id, &changed, NULL))
e_cal_free_change_list (changed);
g_free (change_id);
-
+
LOG (g_message ( "---------------------------------------------------------\n" ));
return 0;
@@ -1703,7 +1703,7 @@ set_pilot_id (GnomePilotConduitSyncAbs *conduit,
const char *uid;
LOG (g_message ( "set_pilot_id: setting to %d\n", ID ));
-
+
e_cal_component_get_uid (local->comp, &uid);
e_pilot_map_insert (ctxt->map, ID, uid, FALSE);
@@ -1716,12 +1716,12 @@ set_status_cleared (GnomePilotConduitSyncAbs *conduit,
ECalConduitContext *ctxt)
{
const char *uid;
-
+
LOG (g_message ( "set_status_cleared: clearing status\n" ));
-
+
e_cal_component_get_uid (local->comp, &uid);
g_hash_table_remove (ctxt->changed_hash, uid);
-
+
return 0;
}
@@ -1741,7 +1741,7 @@ for_each (GnomePilotConduitSyncAbs *conduit,
comps = ctxt->comps;
count = 0;
-
+
if (comps != NULL) {
LOG (g_message ( "iterating over %d records", g_list_length (comps)));
@@ -1797,17 +1797,17 @@ for_each_modified (GnomePilotConduitSyncAbs *conduit,
if (*local == NULL) {
LOG (g_message ( "for_each_modified beginning\n" ));
-
+
iterator = ctxt->changed;
-
+
count = 0;
-
+
LOG (g_message ( "iterating over %d records", g_hash_table_size (ctxt->changed_hash) ));
-
+
iterator = next_changed_item (ctxt, iterator);
if (iterator != NULL) {
ECalChange *ccc = iterator->data;
-
+
*local = g_new0 (ECalLocalRecord, 1);
local_record_from_comp (*local, ccc->comp, ctxt);
@@ -1825,7 +1825,7 @@ for_each_modified (GnomePilotConduitSyncAbs *conduit,
iterator = g_list_next (iterator);
if (iterator && (iterator = next_changed_item (ctxt, iterator))) {
ECalChange *ccc = iterator->data;
-
+
*local = g_new0 (ECalLocalRecord, 1);
local_record_from_comp (*local, ccc->comp, ctxt);
@@ -1870,7 +1870,7 @@ compare (GnomePilotConduitSyncAbs *conduit,
LOG (g_message ( " equal" ));
else
LOG (g_message ( " not equal" ));
-
+
return retval;
}
@@ -1882,7 +1882,7 @@ add_record (GnomePilotConduitSyncAbs *conduit,
ECalComponent *comp;
char *uid;
int retval = 0;
-
+
g_return_val_if_fail (remote != NULL, -1);
LOG (g_message ( "add_record: adding %s to desktop\n", print_remote (remote) ));
@@ -1892,16 +1892,16 @@ add_record (GnomePilotConduitSyncAbs *conduit,
/* Give it a new UID otherwise it will be the uid of the default comp */
uid = e_cal_component_gen_uid ();
e_cal_component_set_uid (comp, uid);
-
+
if (!e_cal_create_object (ctxt->client, e_cal_component_get_icalcomponent (comp), NULL, NULL))
return -1;
e_pilot_map_insert (ctxt->map, remote->ID, uid, FALSE);
- g_free (uid);
+ g_free (uid);
g_object_unref (comp);
-
+
return retval;
}
@@ -1913,7 +1913,7 @@ replace_record (GnomePilotConduitSyncAbs *conduit,
{
ECalComponent *new_comp;
int retval = 0;
-
+
g_return_val_if_fail (remote != NULL, -1);
LOG (g_message ("replace_record: replace %s with %s\n",
@@ -1923,7 +1923,7 @@ replace_record (GnomePilotConduitSyncAbs *conduit,
g_object_unref (local->comp);
local->comp = new_comp;
- if (!e_cal_modify_object (ctxt->client, e_cal_component_get_icalcomponent (new_comp),
+ if (!e_cal_modify_object (ctxt->client, e_cal_component_get_icalcomponent (new_comp),
CALOBJ_MOD_ALL, NULL))
return -1;
@@ -1950,7 +1950,7 @@ delete_record (GnomePilotConduitSyncAbs *conduit,
e_cal_remove_object_with_mod (ctxt->client, uid, NULL, CALOBJ_MOD_ALL, NULL);
else
e_cal_remove_object (ctxt->client, uid, NULL);
-
+
return 0;
}
@@ -1962,14 +1962,14 @@ archive_record (GnomePilotConduitSyncAbs *conduit,
{
const char *uid;
int retval = 0;
-
+
g_return_val_if_fail (local != NULL, -1);
LOG (g_message ( "archive_record: %s\n", archive ? "yes" : "no" ));
e_cal_component_get_uid (local->comp, &uid);
e_pilot_map_insert (ctxt->map, local->local.ID, uid, archive);
-
+
return retval;
}
@@ -1980,24 +1980,24 @@ match (GnomePilotConduitSyncAbs *conduit,
ECalConduitContext *ctxt)
{
const char *uid;
-
+
LOG (g_message ("match: looking for local copy of %s\n",
- print_remote (remote)));
-
+ print_remote (remote)));
+
g_return_val_if_fail (local != NULL, -1);
g_return_val_if_fail (remote != NULL, -1);
*local = NULL;
uid = e_pilot_map_lookup_uid (ctxt->map, remote->ID, TRUE);
-
+
if (!uid)
return 0;
LOG (g_message ( " matched\n" ));
-
+
*local = g_new0 (ECalLocalRecord, 1);
local_record_from_uid (*local, uid, ctxt);
-
+
return 0;
}
@@ -2034,7 +2034,7 @@ fill_widgets (ECalConduitContext *ctxt)
{
if (ctxt->cfg->source)
e_pilot_settings_set_source (E_PILOT_SETTINGS (ctxt->ps),
- ctxt->cfg->source);
+ ctxt->cfg->source);
e_pilot_settings_set_secret (E_PILOT_SETTINGS (ctxt->ps),
ctxt->cfg->secret);
@@ -2047,7 +2047,7 @@ create_settings_window (GnomePilotConduit *conduit,
ECalConduitContext *ctxt)
{
LOG (g_message ( "create_settings_window" ));
-
+
if (!ctxt->cfg->source_list)
return -1;
@@ -2058,14 +2058,14 @@ create_settings_window (GnomePilotConduit *conduit,
gtk_widget_show (ctxt->ps);
fill_widgets (ctxt);
-
+
return 0;
}
static void
display_settings (GnomePilotConduit *conduit, ECalConduitContext *ctxt)
{
LOG (g_message ( "display_settings" ));
-
+
fill_widgets (ctxt);
}
@@ -2141,7 +2141,7 @@ conduit_get_gpilot_conduit (guint32 pilot_id)
void
conduit_destroy_gpilot_conduit (GnomePilotConduit *conduit)
-{
+{
GtkObject *obj = GTK_OBJECT (conduit);
ECalConduitContext *ctxt;
diff --git a/calendar/conduits/common/libecalendar-common-conduit.c b/calendar/conduits/common/libecalendar-common-conduit.c
index 24f6d0b079..534c9ef8fb 100644
--- a/calendar/conduits/common/libecalendar-common-conduit.c
+++ b/calendar/conduits/common/libecalendar-common-conduit.c
@@ -33,23 +33,23 @@
#define LOG(x)
#ifdef DEBUG_CALCONDUIT
#define LOG(x) x
-#endif
+#endif
#ifdef DEBUG_MEMOCONDUIT
#define LOG(x) x
#endif
#ifdef DEBUG_TODOCONDUIT
#define LOG(x) x
-#endif
+#endif
#ifdef DEBUG_CONDUIT
#define LOG(x) x
-#endif
+#endif
/*
* Adds a category to the category app info structure (name and ID),
* sets category->renamed[i] to true if possible to rename.
- *
+ *
* This will be packed and written to the app info block during post_sync.
- *
+ *
* NOTE: cat_to_add MUST be in PCHAR format. Evolution stores categories
* in UTF-8 format. A conversion must take place before calling
* this function (see e_pilot_utf8_to_pchar() in e-pilot-util.c)
@@ -60,14 +60,14 @@ e_pilot_add_category_if_possible(char *cat_to_add, struct CategoryAppInfo *categ
int i, j;
int retval = 0; /* 0 is the Unfiled category */
LOG(g_message("e_pilot_add_category_if_possible\n"));
-
+
for(i=0; i<PILOT_MAX_CATEGORIES; i++){
/* if strlen is 0, then the category is empty
the PalmOS doesn't let 0-length strings for
categories */
if(strlen(category->name[i]) == 0){
int cat_to_add_len;
-
+
cat_to_add_len = strlen(cat_to_add);
retval = i;
@@ -75,7 +75,7 @@ e_pilot_add_category_if_possible(char *cat_to_add, struct CategoryAppInfo *categ
/* Have to truncate the category name */
cat_to_add_len = 15;
}
-
+
/* only 15 characters for category, 16th is
* '\0' can't do direct mem transfer due to
* declaration type
@@ -87,7 +87,7 @@ e_pilot_add_category_if_possible(char *cat_to_add, struct CategoryAppInfo *categ
for(j=cat_to_add_len; j<16; j++) {
category->name[i][j] = '\0';
}
-
+
//find a desktop id that is not in use between 128 and 255
int desktopUniqueID;
for (desktopUniqueID = 128; desktopUniqueID <= 255; desktopUniqueID++) {
@@ -105,17 +105,17 @@ e_pilot_add_category_if_possible(char *cat_to_add, struct CategoryAppInfo *categ
}
}
category->ID[i] = desktopUniqueID;
-
+
category->renamed[i] = TRUE;
-
+
break;
}
}
-
+
if(retval == 0){
LOG (g_warning ("*** not adding category - category list already full ***"));
}
-
+
return retval;
}
@@ -179,8 +179,8 @@ void e_pilot_remote_category_to_local(int pilotCategory, ECalComponent *comp, st
/* store the data on in evolution */
if (category_string == NULL) {
/* note: this space is needed to make sure evolution clears the category */
- e_cal_component_set_categories (comp, " ");
- }
+ e_cal_component_set_categories (comp, " ");
+ }
else {
/* Since only the first category is synced with the PDA, add the PDA's
@@ -189,7 +189,7 @@ void e_pilot_remote_category_to_local(int pilotCategory, ECalComponent *comp, st
GSList *newcat_in_list;
e_cal_component_get_categories_list (comp, &c_list);
- /* remove old item from list so we don't have duplicate entries */
+ /* remove old item from list so we don't have duplicate entries */
newcat_in_list = g_slist_find_custom(c_list, category_string, (GCompareFunc)strcmp);
if(newcat_in_list != NULL)
{
diff --git a/calendar/conduits/memo/memo-conduit.c b/calendar/conduits/memo/memo-conduit.c
index 74f323987d..f84baf7fed 100644
--- a/calendar/conduits/memo/memo-conduit.c
+++ b/calendar/conduits/memo/memo-conduit.c
@@ -4,7 +4,7 @@
* Copyright (C) 1998 Free Software Foundation
* Copyright (C) 2000 Ximian, Inc.
*
- * Authors: Eskil Heyn Olsen <deity@eskil.dk>
+ * Authors: Eskil Heyn Olsen <deity@eskil.dk>
* JP Rosevear <jpr@ximian.com>
*
* This program is free software; you can redistribute it and/or
@@ -87,11 +87,11 @@ struct _EMemoLocalRecord {
int lastDesktopUniqueID;
static void
-memoconduit_destroy_record (EMemoLocalRecord *local)
+memoconduit_destroy_record (EMemoLocalRecord *local)
{
g_object_unref (local->comp);
free_Memo (local->memo);
- g_free (local->memo);
+ g_free (local->memo);
g_free (local);
}
@@ -109,7 +109,7 @@ struct _EMemoConduitCfg {
};
static EMemoConduitCfg *
-memoconduit_load_configuration (guint32 pilot_id)
+memoconduit_load_configuration (guint32 pilot_id)
{
EMemoConduitCfg *c;
GnomePilotConduitManagement *management;
@@ -119,7 +119,7 @@ memoconduit_load_configuration (guint32 pilot_id)
g_snprintf (prefix, 255, "/gnome-pilot.d/e-memo-conduit/Pilot_%u/",
pilot_id);
-
+
c = g_new0 (EMemoConduitCfg,1);
g_assert (c != NULL);
@@ -133,10 +133,10 @@ memoconduit_load_configuration (guint32 pilot_id)
c->sync_type = GnomePilotConduitSyncTypeNotSet;
gtk_object_unref (GTK_OBJECT (config));
gtk_object_unref (GTK_OBJECT (management));
-
+
/* Custom settings */
gnome_config_push_prefix (prefix);
-
+
if (!e_cal_get_sources (&c->source_list, E_CAL_SOURCE_TYPE_JOURNAL, NULL))
c->source_list = NULL;
if (c->source_list) {
@@ -150,7 +150,7 @@ memoconduit_load_configuration (guint32 pilot_id)
c->source_list = NULL;
}
}
-
+
c->secret = gnome_config_get_bool ("secret=FALSE");
c->priority = gnome_config_get_int ("priority=3");
c->last_uri = gnome_config_get_string ("last_uri");
@@ -161,7 +161,7 @@ memoconduit_load_configuration (guint32 pilot_id)
}
static void
-memoconduit_save_configuration (EMemoConduitCfg *c)
+memoconduit_save_configuration (EMemoConduitCfg *c)
{
gchar prefix[256];
@@ -180,7 +180,7 @@ memoconduit_save_configuration (EMemoConduitCfg *c)
}
static EMemoConduitCfg*
-memoconduit_dupe_configuration (EMemoConduitCfg *c)
+memoconduit_dupe_configuration (EMemoConduitCfg *c)
{
EMemoConduitCfg *retval;
@@ -201,8 +201,8 @@ memoconduit_dupe_configuration (EMemoConduitCfg *c)
return retval;
}
-static void
-memoconduit_destroy_configuration (EMemoConduitCfg *c)
+static void
+memoconduit_destroy_configuration (EMemoConduitCfg *c)
{
g_return_if_fail (c != NULL);
@@ -219,7 +219,7 @@ struct _EMemoConduitContext {
EMemoConduitCfg *cfg;
EMemoConduitCfg *new_cfg;
GtkWidget *ps;
-
+
struct MemoAppInfo ai;
ECal *client;
@@ -230,15 +230,15 @@ struct _EMemoConduitContext {
GList *changed;
GHashTable *changed_hash;
GList *locals;
-
+
EPilotMap *map;
};
static EMemoConduitContext *
-e_memo_context_new (guint32 pilot_id)
+e_memo_context_new (guint32 pilot_id)
{
EMemoConduitContext *ctxt = g_new0 (EMemoConduitContext, 1);
-
+
ctxt->cfg = memoconduit_load_configuration (pilot_id);
ctxt->new_cfg = memoconduit_dupe_configuration (ctxt->cfg);
ctxt->ps = NULL;
@@ -255,10 +255,10 @@ e_memo_context_new (guint32 pilot_id)
}
static gboolean
-e_memo_context_foreach_change (gpointer key, gpointer value, gpointer data)
+e_memo_context_foreach_change (gpointer key, gpointer value, gpointer data)
{
g_free (key);
-
+
return TRUE;
}
@@ -266,14 +266,14 @@ static void
e_memo_context_destroy (EMemoConduitContext *ctxt)
{
GList *l;
-
+
g_return_if_fail (ctxt != NULL);
if (ctxt->cfg != NULL)
memoconduit_destroy_configuration (ctxt->cfg);
if (ctxt->new_cfg != NULL)
memoconduit_destroy_configuration (ctxt->new_cfg);
-
+
if (ctxt->client != NULL)
g_object_unref (ctxt->client);
@@ -295,10 +295,10 @@ e_memo_context_destroy (EMemoConduitContext *ctxt)
memoconduit_destroy_record (l->data);
g_list_free (ctxt->locals);
}
-
+
if (ctxt->changed != NULL)
e_cal_free_change_list (ctxt->changed);
-
+
if (ctxt->map != NULL)
e_pilot_map_destroy (ctxt->map);
@@ -361,7 +361,7 @@ static char *print_remote (GnomePilotRecord *remote)
memo.text : "");
free_Memo (&memo);
-
+
return buff;
}
@@ -372,7 +372,7 @@ start_calendar_server (EMemoConduitContext *ctxt)
if (ctxt->cfg->source) {
ctxt->client = e_cal_new (ctxt->cfg->source, E_CAL_SOURCE_TYPE_JOURNAL);
- if (!e_cal_open (ctxt->client, TRUE, NULL))
+ if (!e_cal_open (ctxt->client, TRUE, NULL))
return -1;
} else if (!e_cal_open_default (&ctxt->client, E_CAL_SOURCE_TYPE_JOURNAL, NULL, NULL, NULL)) {
return -1;
@@ -396,41 +396,41 @@ get_default_timezone (void)
g_free (location);
location = g_strdup ("UTC");
}
-
+
timezone = icaltimezone_get_builtin_timezone (location);
g_free (location);
g_object_unref (listener);
- return timezone;
+ return timezone;
}
static char *
-map_name (EMemoConduitContext *ctxt)
+map_name (EMemoConduitContext *ctxt)
{
char *filename;
-
+
filename = g_strdup_printf ("%s/.evolution/memos/local/system/pilot-map-memo-%d.xml", g_get_home_dir (), ctxt->cfg->pilot_id);
-
+
return filename;
}
static GList *
-next_changed_item (EMemoConduitContext *ctxt, GList *changes)
+next_changed_item (EMemoConduitContext *ctxt, GList *changes)
{
ECalChange *ccc;
GList *l;
-
+
for (l = changes; l != NULL; l = l->next) {
const char *uid;
ccc = l->data;
-
+
e_cal_component_get_uid (ccc->comp, &uid);
if (g_hash_table_lookup (ctxt->changed_hash, uid))
return l;
}
-
+
return NULL;
}
@@ -443,16 +443,16 @@ compute_status (EMemoConduitContext *ctxt, EMemoLocalRecord *local, const char *
local->local.secret = FALSE;
ccc = g_hash_table_lookup (ctxt->changed_hash, uid);
-
+
if (ccc == NULL) {
local->local.attr = GnomePilotRecordNothing;
return;
}
-
+
switch (ccc->type) {
case E_CAL_CHANGE_ADDED:
local->local.attr = GnomePilotRecordNew;
- break;
+ break;
case E_CAL_CHANGE_MODIFIED:
local->local.attr = GnomePilotRecordModified;
break;
@@ -475,7 +475,7 @@ local_record_to_pilot_record (EMemoLocalRecord *local,
g_assert (local->comp != NULL);
g_assert (local->memo != NULL );
-
+
LOG (g_message ( "local_record_to_pilot_record\n" ));
memset (&p, 0, sizeof (GnomePilotRecord));
@@ -504,20 +504,20 @@ local_record_to_pilot_record (EMemoLocalRecord *local,
p.record = (unsigned char *)record;
p.length = pack_Memo (local->memo, p.record, 0xffff);
#endif
- return p;
+ return p;
}
/*
* converts a ECalComponent object to a EMemoLocalRecord
*/
static void
-local_record_from_comp (EMemoLocalRecord *local, ECalComponent *comp, EMemoConduitContext *ctxt)
+local_record_from_comp (EMemoLocalRecord *local, ECalComponent *comp, EMemoConduitContext *ctxt)
{
const char *uid;
GSList *d_list = NULL;
ECalComponentText *description;
ECalComponentClassification classif;
-
+
LOG (g_message ( "local_record_from_comp\n" ));
g_return_if_fail (local != NULL);
@@ -533,7 +533,7 @@ local_record_from_comp (EMemoLocalRecord *local, ECalComponent *comp, EMemoCondu
LOG(fprintf(stderr, "local_record_from_comp: local->local.ID == %lu\n", local->local.ID));
compute_status (ctxt, local, uid);
-
+
LOG(fprintf(stderr, "local_record_from_comp: local->local.attr: %d\n", local->local.attr));
local->memo = g_new0 (struct Memo,1);
@@ -547,7 +547,7 @@ local_record_from_comp (EMemoLocalRecord *local, ECalComponent *comp, EMemoCondu
char record[0xffff];
#endif
int cat = 0;
-
+
#ifdef PILOT_LINK_0_12
record = pi_buffer_new(DLP_BUF_SIZE);
if(record == NULL){
@@ -557,10 +557,10 @@ local_record_from_comp (EMemoLocalRecord *local, ECalComponent *comp, EMemoCondu
#endif
LOG(fprintf(stderr, "local_record_from_comp: calling dlp_ReadRecordById\n"));
- if (dlp_ReadRecordById (ctxt->dbi->pilot_socket,
+ if (dlp_ReadRecordById (ctxt->dbi->pilot_socket,
ctxt->dbi->db_handle,
#ifdef PILOT_LINK_0_12
- local->local.ID, record,
+ local->local.ID, record,
NULL, NULL, &cat) > 0) {
local->local.category = cat;
memset (&memo, 0, sizeof (struct Memo));
@@ -570,14 +570,14 @@ local_record_from_comp (EMemoLocalRecord *local, ECalComponent *comp, EMemoCondu
}
pi_buffer_free (record);
#else
- local->local.ID, &record,
+ local->local.ID, &record,
NULL, NULL, NULL, &cat) > 0) {
local->local.category = cat;
- }
+ }
#endif
LOG(fprintf(stderr, "local_record_from_comp: done calling dlp_ReadRecordById\n"));
}
-
+
/*Category support*/
e_pilot_local_category_to_remote(&(local->local.category), comp, &(ctxt->ai.category));
@@ -596,7 +596,7 @@ local_record_from_comp (EMemoLocalRecord *local, ECalComponent *comp, EMemoCondu
} else {
local->memo->text = NULL;
}
-
+
e_cal_component_get_classification (comp, &classif);
if (classif == E_CAL_COMPONENT_CLASS_PRIVATE)
@@ -607,7 +607,7 @@ local_record_from_comp (EMemoLocalRecord *local, ECalComponent *comp, EMemoCondu
local->local.archived = 0;
}
-static void
+static void
local_record_from_uid (EMemoLocalRecord *local,
const char *uid,
EMemoConduitContext *ctxt)
@@ -617,7 +617,7 @@ local_record_from_uid (EMemoLocalRecord *local,
GError *error = NULL;
g_assert(local!=NULL);
-
+
LOG(g_message("local_record_from_uid\n"));
if (e_cal_get_object (ctxt->client, uid, NULL, &icalcomp, &error)) {
@@ -667,11 +667,11 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
if(buffer == NULL){
return NULL;
}
-
+
if(pi_buffer_append(buffer, remote->record, remote->length)==NULL){
return NULL;
}
-
+
unpack_Memo (&memo, buffer, memo_v1);
pi_buffer_free(buffer);
#else
@@ -680,7 +680,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
#endif
utc_zone = icaltimezone_get_utc_timezone ();
- now = icaltime_from_timet_with_zone (time (NULL), FALSE,
+ now = icaltime_from_timet_with_zone (time (NULL), FALSE,
utc_zone);
if (in_comp == NULL) {
@@ -692,10 +692,10 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
}
e_cal_component_set_last_modified (comp, &now);
-
+
/*Category support*/
e_pilot_remote_category_to_local(remote->category, comp, &(ai->category));
-
+
/* The iCal description field */
if (!memo.text) {
e_cal_component_set_comment_list (comp, NULL);
@@ -713,19 +713,19 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
break;
}
}
-
+
if(foundNL == FALSE){
if(ntext > 50){
txt2 = g_strndup(memo.text, 50);
}
else{
txt2 = g_strdup(memo.text);
-
+
}
}
else{
txt2 = g_strndup(memo.text, idxToUse); /* cuts off '\n' */
-
+
}
sumText.value = txt3 = e_pilot_utf8_from_pchar(txt2);
@@ -741,7 +741,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
free (txt);
g_free(txt2);
free(txt3);
- }
+ }
e_cal_component_set_transparency (comp, E_CAL_COMPONENT_TRANSP_NONE);
@@ -752,7 +752,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
e_cal_component_set_classification (comp, E_CAL_COMPONENT_CLASS_PUBLIC);
e_cal_component_commit_sequence (comp);
-
+
free_Memo(&memo);
return comp;
@@ -764,7 +764,7 @@ check_for_slow_setting (GnomePilotConduit *c, EMemoConduitContext *ctxt)
GnomePilotConduitStandard *conduit = GNOME_PILOT_CONDUIT_STANDARD (c);
int map_count;
const char *uri;
-
+
/* If there are no objects or objects but no log */
map_count = g_hash_table_size (ctxt->map->pid_map);
if (map_count == 0)
@@ -783,7 +783,7 @@ check_for_slow_setting (GnomePilotConduit *c, EMemoConduitContext *ctxt)
LOG (g_message ( " doing slow sync\n" ));
} else {
LOG (g_message ( " doing fast sync\n" ));
- }
+ }
}
/* Pilot syncing callbacks */
@@ -809,9 +809,9 @@ pre_sync (GnomePilotConduit *conduit,
LOG (g_message ( "pre_sync: Memo Conduit v.%s", CONDUIT_VERSION ));
g_message ("Memo Conduit v.%s", CONDUIT_VERSION);
- ctxt->dbi = dbi;
+ ctxt->dbi = dbi;
ctxt->client = NULL;
-
+
if (start_calendar_server (ctxt) != 0) {
WARN(_("Could not start evolution-data-server"));
gnome_pilot_conduit_error (conduit, _("Could not start evolution-data-server"));
@@ -827,18 +827,18 @@ pre_sync (GnomePilotConduit *conduit,
/* Set the default timezone on the backend. */
if (ctxt->timezone && !e_cal_set_default_timezone (ctxt->client, ctxt->timezone, NULL))
return -1;
-
+
/* Get the default component */
if (!e_cal_get_default_object (ctxt->client, &icalcomp, NULL))
return -1;
-
+
ctxt->default_comp = e_cal_component_new ();
if (!e_cal_component_set_icalcomponent (ctxt->default_comp, icalcomp)) {
g_object_unref (ctxt->default_comp);
icalcomponent_free (icalcomp);
return -1;
}
-
+
/* Load the uid <--> pilot id map */
filename = map_name (ctxt);
e_pilot_map_read (filename, &ctxt->map);
@@ -847,24 +847,24 @@ pre_sync (GnomePilotConduit *conduit,
/* Get the local database */
if (!e_cal_get_object_list_as_comp (ctxt->client, "#t", &ctxt->comps, NULL))
return -1;
-
+
/* Count and hash the changes */
change_id = g_strdup_printf ("pilot-sync-evolution-memo-%d", ctxt->cfg->pilot_id);
if (!e_cal_get_changes (ctxt->client, change_id, &ctxt->changed, NULL))
return -1;
-
+
ctxt->changed_hash = g_hash_table_new (g_str_hash, g_str_equal);
g_free (change_id);
-
+
for (l = ctxt->changed; l != NULL; l = l->next) {
ECalChange *ccc = l->data;
const char *uid;
-
+
e_cal_component_get_uid (ccc->comp, &uid);
if (!e_pilot_map_uid_is_archived (ctxt->map, uid)) {
-
+
g_hash_table_insert (ctxt->changed_hash, g_strdup (uid), ccc);
-
+
switch (ccc->type) {
case E_CAL_CHANGE_ADDED:
add_records++;
@@ -887,7 +887,7 @@ pre_sync (GnomePilotConduit *conduit,
gnome_pilot_conduit_sync_abs_set_num_new_local_records (abs_conduit, add_records);
gnome_pilot_conduit_sync_abs_set_num_updated_local_records (abs_conduit, mod_records);
gnome_pilot_conduit_sync_abs_set_num_deleted_local_records(abs_conduit, del_records);
-
+
g_message("num_records: %d\nadd_records: %d\nmod_records: %d\ndel_records: %d\n",
num_records, add_records, mod_records, del_records);
@@ -923,14 +923,14 @@ pre_sync (GnomePilotConduit *conduit,
#endif
g_free (buf);
-
+
lastDesktopUniqueID = 128;
check_for_slow_setting (conduit, ctxt);
if (ctxt->cfg->sync_type == GnomePilotConduitSyncTypeCopyToPilot
|| ctxt->cfg->sync_type == GnomePilotConduitSyncTypeCopyFromPilot)
ctxt->map->write_touched_only = TRUE;
-
+
return 0;
}
@@ -945,14 +945,14 @@ post_sync (GnomePilotConduit *conduit,
int dlpRetVal, len;
buf = (unsigned char*)g_malloc (0xffff);
-
+
len = pack_MemoAppInfo (&(ctxt->ai), buf, 0xffff);
-
- dlpRetVal = dlp_WriteAppBlock (dbi->pilot_socket, dbi->db_handle,
+
+ dlpRetVal = dlp_WriteAppBlock (dbi->pilot_socket, dbi->db_handle,
(unsigned char *)buf, len);
-
+
g_free (buf);
-
+
if (dlpRetVal < 0) {
WARN (_("Could not write pilot's Memo application block"));
WARN ("dlp_WriteAppBlock(...) = %d", dlpRetVal);
@@ -960,14 +960,14 @@ post_sync (GnomePilotConduit *conduit,
_("Could not write pilot's Memo application block"));
return -1;
}
-
+
LOG (g_message ( "post_sync: Memo Conduit v.%s", CONDUIT_VERSION ));
g_free (ctxt->cfg->last_uri);
ctxt->cfg->last_uri = g_strdup (e_cal_get_uri (ctxt->client));
memoconduit_save_configuration (ctxt->cfg);
-
+
filename = map_name (ctxt);
e_pilot_map_write (filename, ctxt->map);
g_free (filename);
@@ -979,7 +979,7 @@ post_sync (GnomePilotConduit *conduit,
if (e_cal_get_changes (ctxt->client, change_id, &changed, NULL))
e_cal_free_change_list (changed);
g_free (change_id);
-
+
LOG (g_message ( "---------------------------------------------------------\n" ));
return 0;
@@ -994,7 +994,7 @@ set_pilot_id (GnomePilotConduitSyncAbs *conduit,
const char *uid;
LOG (g_message ( "set_pilot_id: setting to %d\n", ID ));
-
+
e_cal_component_get_uid (local->comp, &uid);
e_pilot_map_insert (ctxt->map, ID, uid, FALSE);
@@ -1007,12 +1007,12 @@ set_status_cleared (GnomePilotConduitSyncAbs *conduit,
EMemoConduitContext *ctxt)
{
const char *uid;
-
+
LOG (g_message ( "set_status_cleared: clearing status\n" ));
-
+
e_cal_component_get_uid (local->comp, &uid);
g_hash_table_remove (ctxt->changed_hash, uid);
-
+
return 0;
}
@@ -1032,7 +1032,7 @@ for_each (GnomePilotConduitSyncAbs *conduit,
comps = ctxt->comps;
count = 0;
-
+
if (comps != NULL) {
LOG (g_message ( "for_each: iterating over %d records", g_list_length (comps)));
@@ -1089,13 +1089,13 @@ for_each_modified (GnomePilotConduitSyncAbs *conduit,
if (*local == NULL) {
LOG (g_message ( "for_each_modified beginning\n" ));
-
+
iterator = ctxt->changed;
-
+
count = 0;
-
+
LOG (g_message ( "iterating over %d records", g_hash_table_size (ctxt->changed_hash) ));
-
+
iterator = next_changed_item (ctxt, iterator);
if (iterator != NULL) {
ECalChange *ccc = iterator->data;
@@ -1163,7 +1163,7 @@ compare (GnomePilotConduitSyncAbs *conduit,
LOG (g_message ( " equal" ));
else
LOG (g_message ( " not equal" ));
-
+
return retval;
}
@@ -1175,7 +1175,7 @@ add_record (GnomePilotConduitSyncAbs *conduit,
ECalComponent *comp;
char *uid;
int retval = 0;
-
+
g_return_val_if_fail (remote != NULL, -1);
LOG (g_message ( "add_record: adding %s to desktop\n", print_remote (remote) ));
@@ -1204,7 +1204,7 @@ replace_record (GnomePilotConduitSyncAbs *conduit,
{
ECalComponent *new_comp;
int retval = 0;
-
+
g_return_val_if_fail (remote != NULL, -1);
LOG (g_message ("replace_record: replace %s with %s\n",
@@ -1214,7 +1214,7 @@ replace_record (GnomePilotConduitSyncAbs *conduit,
g_object_unref (local->comp);
local->comp = new_comp;
- if (!e_cal_modify_object (ctxt->client, e_cal_component_get_icalcomponent (new_comp),
+ if (!e_cal_modify_object (ctxt->client, e_cal_component_get_icalcomponent (new_comp),
CALOBJ_MOD_ALL, NULL))
return -1;
@@ -1238,7 +1238,7 @@ delete_record (GnomePilotConduitSyncAbs *conduit,
e_pilot_map_remove_by_uid (ctxt->map, uid);
/* FIXME Error handling */
e_cal_remove_object (ctxt->client, uid, NULL);
-
+
return 0;
}
@@ -1250,14 +1250,14 @@ archive_record (GnomePilotConduitSyncAbs *conduit,
{
const char *uid;
int retval = 0;
-
+
g_return_val_if_fail (local != NULL, -1);
LOG (g_message ( "archive_record: %s\n", archive ? "yes" : "no" ));
e_cal_component_get_uid (local->comp, &uid);
e_pilot_map_insert (ctxt->map, local->local.ID, uid, archive);
-
+
return retval;
}
@@ -1268,24 +1268,24 @@ match (GnomePilotConduitSyncAbs *conduit,
EMemoConduitContext *ctxt)
{
const char *uid;
-
+
LOG (g_message ("match: looking for local copy of %s\n",
- print_remote (remote)));
-
+ print_remote (remote)));
+
g_return_val_if_fail (local != NULL, -1);
g_return_val_if_fail (remote != NULL, -1);
*local = NULL;
uid = e_pilot_map_lookup_uid (ctxt->map, remote->ID, TRUE);
-
+
if (!uid)
return 0;
LOG (g_message ( " matched\n" ));
-
+
*local = g_new0 (EMemoLocalRecord, 1);
local_record_from_uid (*local, uid, ctxt);
-
+
return 0;
}
@@ -1321,7 +1321,7 @@ static void
fill_widgets (EMemoConduitContext *ctxt)
{
if (ctxt->cfg->source)
- e_pilot_settings_set_source (E_PILOT_SETTINGS (ctxt->ps),
+ e_pilot_settings_set_source (E_PILOT_SETTINGS (ctxt->ps),
ctxt->cfg->source);
e_pilot_settings_set_secret (E_PILOT_SETTINGS (ctxt->ps),
ctxt->cfg->secret);
@@ -1333,8 +1333,8 @@ create_settings_window (GnomePilotConduit *conduit,
EMemoConduitContext *ctxt)
{
LOG (g_message ( "create_settings_window" ));
-
- if (!ctxt->cfg->source_list)
+
+ if (!ctxt->cfg->source_list)
return -1;
ctxt->ps = e_pilot_settings_new (ctxt->cfg->source_list);
@@ -1343,7 +1343,7 @@ create_settings_window (GnomePilotConduit *conduit,
gtk_widget_show (ctxt->ps);
fill_widgets (ctxt);
-
+
return 0;
}
@@ -1351,7 +1351,7 @@ static void
display_settings (GnomePilotConduit *conduit, EMemoConduitContext *ctxt)
{
LOG (g_message ( "display_settings" ));
-
+
fill_widgets (ctxt);
}
@@ -1365,7 +1365,7 @@ save_settings (GnomePilotConduit *conduit, EMemoConduitContext *ctxt)
ctxt->new_cfg->source = e_pilot_settings_get_source (E_PILOT_SETTINGS (ctxt->ps));
g_object_ref (ctxt->new_cfg->source);
ctxt->new_cfg->secret = e_pilot_settings_get_secret (E_PILOT_SETTINGS (ctxt->ps));
-
+
memoconduit_save_configuration (ctxt->new_cfg);
}
@@ -1389,7 +1389,7 @@ conduit_get_gpilot_conduit (guint32 pilot_id)
retval = gnome_pilot_conduit_sync_abs_new ("MemoDB", 0x6D656D6F);
g_assert (retval != NULL);
-
+
ctxt = e_memo_context_new (pilot_id);
gtk_object_set_data (GTK_OBJECT (retval), "memoconduit_context", ctxt);
@@ -1424,10 +1424,10 @@ conduit_get_gpilot_conduit (guint32 pilot_id)
void
conduit_destroy_gpilot_conduit (GnomePilotConduit *conduit)
-{
+{
GtkObject *obj = GTK_OBJECT (conduit);
EMemoConduitContext *ctxt;
-
+
ctxt = gtk_object_get_data (obj, "memoconduit_context");
e_memo_context_destroy (ctxt);
diff --git a/calendar/conduits/todo/todo-conduit.c b/calendar/conduits/todo/todo-conduit.c
index 0594d53298..e321940386 100644
--- a/calendar/conduits/todo/todo-conduit.c
+++ b/calendar/conduits/todo/todo-conduit.c
@@ -4,7 +4,7 @@
* Copyright (C) 1998 Free Software Foundation
* Copyright (C) 2000 Ximian, Inc.
*
- * Authors: Eskil Heyn Olsen <deity@eskil.dk>
+ * Authors: Eskil Heyn Olsen <deity@eskil.dk>
* JP Rosevear <jpr@ximian.com>
*
* This program is free software; you can redistribute it and/or
@@ -61,7 +61,7 @@ void conduit_destroy_gpilot_conduit (GnomePilotConduit*);
#define LOG(x) x
#else
#define LOG(x)
-#endif
+#endif
#define WARN g_warning
#define INFO g_message
@@ -89,11 +89,11 @@ struct _EToDoLocalRecord {
int lastDesktopUniqueID;
static void
-todoconduit_destroy_record (EToDoLocalRecord *local)
+todoconduit_destroy_record (EToDoLocalRecord *local)
{
g_object_unref (local->comp);
free_ToDo (local->todo);
- g_free (local->todo);
+ g_free (local->todo);
g_free (local);
}
@@ -111,7 +111,7 @@ struct _EToDoConduitCfg {
};
static EToDoConduitCfg *
-todoconduit_load_configuration (guint32 pilot_id)
+todoconduit_load_configuration (guint32 pilot_id)
{
EToDoConduitCfg *c;
GnomePilotConduitManagement *management;
@@ -121,7 +121,7 @@ todoconduit_load_configuration (guint32 pilot_id)
g_snprintf (prefix, 255, "/gnome-pilot.d/e-todo-conduit/Pilot_%u/",
pilot_id);
-
+
c = g_new0 (EToDoConduitCfg,1);
g_assert (c != NULL);
@@ -135,10 +135,10 @@ todoconduit_load_configuration (guint32 pilot_id)
c->sync_type = GnomePilotConduitSyncTypeNotSet;
gtk_object_unref (GTK_OBJECT (config));
gtk_object_unref (GTK_OBJECT (management));
-
+
/* Custom settings */
gnome_config_push_prefix (prefix);
-
+
if (!e_cal_get_sources (&c->source_list, E_CAL_SOURCE_TYPE_TODO, NULL))
c->source_list = NULL;
if (c->source_list) {
@@ -152,7 +152,7 @@ todoconduit_load_configuration (guint32 pilot_id)
c->source_list = NULL;
}
}
-
+
c->secret = gnome_config_get_bool ("secret=FALSE");
c->priority = gnome_config_get_int ("priority=3");
c->last_uri = gnome_config_get_string ("last_uri");
@@ -163,7 +163,7 @@ todoconduit_load_configuration (guint32 pilot_id)
}
static void
-todoconduit_save_configuration (EToDoConduitCfg *c)
+todoconduit_save_configuration (EToDoConduitCfg *c)
{
gchar prefix[256];
@@ -182,7 +182,7 @@ todoconduit_save_configuration (EToDoConduitCfg *c)
}
static EToDoConduitCfg*
-todoconduit_dupe_configuration (EToDoConduitCfg *c)
+todoconduit_dupe_configuration (EToDoConduitCfg *c)
{
EToDoConduitCfg *retval;
@@ -203,8 +203,8 @@ todoconduit_dupe_configuration (EToDoConduitCfg *c)
return retval;
}
-static void
-todoconduit_destroy_configuration (EToDoConduitCfg *c)
+static void
+todoconduit_destroy_configuration (EToDoConduitCfg *c)
{
g_return_if_fail (c != NULL);
@@ -220,13 +220,13 @@ struct _EToDoConduitGui {
};
static EToDoConduitGui *
-e_todo_gui_new (EPilotSettings *ps)
+e_todo_gui_new (EPilotSettings *ps)
{
EToDoConduitGui *gui;
GtkWidget *lbl;
GtkObject *adj;
gint rows;
-
+
g_return_val_if_fail (ps != NULL, NULL);
g_return_val_if_fail (E_IS_PILOT_SETTINGS (ps), NULL);
@@ -244,12 +244,12 @@ e_todo_gui_new (EPilotSettings *ps)
gtk_table_attach_defaults (GTK_TABLE (ps), gui->priority, 1, 2, rows, rows + 1);
gtk_widget_show (lbl);
gtk_widget_show (gui->priority);
-
+
return gui;
}
static void
-e_todo_gui_fill_widgets (EToDoConduitGui *gui, EToDoConduitCfg *cfg)
+e_todo_gui_fill_widgets (EToDoConduitGui *gui, EToDoConduitCfg *cfg)
{
g_return_if_fail (gui != NULL);
g_return_if_fail (cfg != NULL);
@@ -258,7 +258,7 @@ e_todo_gui_fill_widgets (EToDoConduitGui *gui, EToDoConduitCfg *cfg)
}
static void
-e_todo_gui_fill_config (EToDoConduitGui *gui, EToDoConduitCfg *cfg)
+e_todo_gui_fill_config (EToDoConduitGui *gui, EToDoConduitCfg *cfg)
{
g_return_if_fail (gui != NULL);
g_return_if_fail (cfg != NULL);
@@ -267,7 +267,7 @@ e_todo_gui_fill_config (EToDoConduitGui *gui, EToDoConduitCfg *cfg)
}
static void
-e_todo_gui_destroy (EToDoConduitGui *gui)
+e_todo_gui_destroy (EToDoConduitGui *gui)
{
g_free (gui);
}
@@ -280,7 +280,7 @@ struct _EToDoConduitContext {
EToDoConduitCfg *new_cfg;
EToDoConduitGui *gui;
GtkWidget *ps;
-
+
struct ToDoAppInfo ai;
ECal *client;
@@ -291,15 +291,15 @@ struct _EToDoConduitContext {
GList *changed;
GHashTable *changed_hash;
GList *locals;
-
+
EPilotMap *map;
};
static EToDoConduitContext *
-e_todo_context_new (guint32 pilot_id)
+e_todo_context_new (guint32 pilot_id)
{
EToDoConduitContext *ctxt = g_new0 (EToDoConduitContext, 1);
-
+
ctxt->cfg = todoconduit_load_configuration (pilot_id);
ctxt->new_cfg = todoconduit_dupe_configuration (ctxt->cfg);
ctxt->gui = NULL;
@@ -317,10 +317,10 @@ e_todo_context_new (guint32 pilot_id)
}
static gboolean
-e_todo_context_foreach_change (gpointer key, gpointer value, gpointer data)
+e_todo_context_foreach_change (gpointer key, gpointer value, gpointer data)
{
g_free (key);
-
+
return TRUE;
}
@@ -328,7 +328,7 @@ static void
e_todo_context_destroy (EToDoConduitContext *ctxt)
{
GList *l;
-
+
g_return_if_fail (ctxt != NULL);
if (ctxt->cfg != NULL)
@@ -337,7 +337,7 @@ e_todo_context_destroy (EToDoConduitContext *ctxt)
todoconduit_destroy_configuration (ctxt->new_cfg);
if (ctxt->gui != NULL)
e_todo_gui_destroy (ctxt->gui);
-
+
if (ctxt->client != NULL)
g_object_unref (ctxt->client);
@@ -359,10 +359,10 @@ e_todo_context_destroy (EToDoConduitContext *ctxt)
todoconduit_destroy_record (l->data);
g_list_free (ctxt->locals);
}
-
+
if (ctxt->changed != NULL)
e_cal_free_change_list (ctxt->changed);
-
+
if (ctxt->map != NULL)
e_pilot_map_destroy (ctxt->map);
@@ -437,7 +437,7 @@ static char *print_remote (GnomePilotRecord *remote)
remote->category);
free_ToDo (&todo);
-
+
return buff;
}
@@ -475,7 +475,7 @@ start_calendar_server (EToDoConduitContext *ctxt)
if (ctxt->timezone && !e_cal_set_default_timezone (ctxt->client, ctxt->timezone, NULL))
return -1;
- LOG (g_message ( " timezone set to : %s", icaltimezone_get_tzid (ctxt->timezone) ));
+ LOG (g_message ( " timezone set to : %s", icaltimezone_get_tzid (ctxt->timezone) ));
if (e_source_get_property (ctxt->cfg->source, "auth")) {
EUri *e_uri;
@@ -488,7 +488,7 @@ start_calendar_server (EToDoConduitContext *ctxt)
if (ctxt->client)
e_cal_set_auth_func (ctxt->client, (ECalAuthFunc) auth_func_cb, NULL);
}
- if (!e_cal_open (ctxt->client, TRUE, NULL))
+ if (!e_cal_open (ctxt->client, TRUE, NULL))
retval = -1;
} else if (!e_cal_open_default (&ctxt->client, E_CAL_SOURCE_TYPE_TODO, NULL, NULL, NULL)) {
retval = -1;
@@ -501,14 +501,14 @@ start_calendar_server (EToDoConduitContext *ctxt)
/* Utility routines */
static icaltimezone *
-get_timezone (ECal *client, const char *tzid)
+get_timezone (ECal *client, const char *tzid)
{
icaltimezone *timezone = NULL;
timezone = icaltimezone_get_builtin_timezone_from_tzid (tzid);
if (timezone == NULL)
e_cal_get_timezone (client, tzid, &timezone, NULL);
-
+
return timezone;
}
@@ -527,51 +527,51 @@ get_default_timezone (void)
g_free (location);
location = g_strdup ("UTC");
}
-
+
timezone = icaltimezone_get_builtin_timezone (location);
g_free (location);
g_object_unref (listener);
- return timezone;
+ return timezone;
}
static char *
-map_name (EToDoConduitContext *ctxt)
+map_name (EToDoConduitContext *ctxt)
{
char *filename;
-
+
filename = g_strdup_printf ("%s/.evolution/tasks/local/system/pilot-map-todo-%d.xml", g_get_home_dir (), ctxt->cfg->pilot_id);
-
+
return filename;
}
static gboolean
-is_empty_time (struct tm time)
+is_empty_time (struct tm time)
{
- if (time.tm_sec || time.tm_min || time.tm_hour
- || time.tm_mday || time.tm_mon || time.tm_year)
+ if (time.tm_sec || time.tm_min || time.tm_hour
+ || time.tm_mday || time.tm_mon || time.tm_year)
return FALSE;
-
+
return TRUE;
}
static GList *
-next_changed_item (EToDoConduitContext *ctxt, GList *changes)
+next_changed_item (EToDoConduitContext *ctxt, GList *changes)
{
ECalChange *ccc;
GList *l;
-
+
for (l = changes; l != NULL; l = l->next) {
const char *uid;
ccc = l->data;
-
+
e_cal_component_get_uid (ccc->comp, &uid);
if (g_hash_table_lookup (ctxt->changed_hash, uid))
return l;
}
-
+
return NULL;
}
@@ -584,16 +584,16 @@ compute_status (EToDoConduitContext *ctxt, EToDoLocalRecord *local, const char *
local->local.secret = FALSE;
ccc = g_hash_table_lookup (ctxt->changed_hash, uid);
-
+
if (ccc == NULL) {
local->local.attr = GnomePilotRecordNothing;
return;
}
-
+
switch (ccc->type) {
case E_CAL_CHANGE_ADDED:
local->local.attr = GnomePilotRecordNew;
- break;
+ break;
case E_CAL_CHANGE_MODIFIED:
local->local.attr = GnomePilotRecordModified;
break;
@@ -616,7 +616,7 @@ local_record_to_pilot_record (EToDoLocalRecord *local,
g_assert (local->comp != NULL);
g_assert (local->todo != NULL );
-
+
LOG (g_message ( "local_record_to_pilot_record\n" ));
memset (&p, 0, sizeof (GnomePilotRecord));
@@ -640,19 +640,19 @@ local_record_to_pilot_record (EToDoLocalRecord *local,
p.length = buffer->used;
memcpy(p.record, buffer->data, buffer->used);
- pi_buffer_free(buffer);
+ pi_buffer_free(buffer);
#else
p.record = (unsigned char *)record;
p.length = pack_ToDo (local->todo, p.record, 0xffff);
#endif
- return p;
+ return p;
}
/*
* converts a ECalComponent object to a EToDoLocalRecord
*/
static void
-local_record_from_comp (EToDoLocalRecord *local, ECalComponent *comp, EToDoConduitContext *ctxt)
+local_record_from_comp (EToDoLocalRecord *local, ECalComponent *comp, EToDoConduitContext *ctxt)
{
const char *uid;
int *priority;
@@ -663,7 +663,7 @@ local_record_from_comp (EToDoLocalRecord *local, ECalComponent *comp, EToDoCondu
ECalComponentDateTime due;
ECalComponentClassification classif;
icaltimezone *default_tz = get_default_timezone ();
-
+
LOG (g_message ( "local_record_from_comp\n" ));
g_return_if_fail (local != NULL);
@@ -692,14 +692,14 @@ local_record_from_comp (EToDoLocalRecord *local, ECalComponent *comp, EToDoCondu
#else
char record[0xffff];
#endif
-
- if (dlp_ReadRecordById (ctxt->dbi->pilot_socket,
+
+ if (dlp_ReadRecordById (ctxt->dbi->pilot_socket,
ctxt->dbi->db_handle,
#ifdef PILOT_LINK_0_12
- local->local.ID, record,
+ local->local.ID, record,
NULL, NULL, &cat) > 0) {
#else
- local->local.ID, &record,
+ local->local.ID, &record,
NULL, NULL, NULL, &cat) > 0) {
#endif
local->local.category = cat;
@@ -708,14 +708,14 @@ local_record_from_comp (EToDoLocalRecord *local, ECalComponent *comp, EToDoCondu
pi_buffer_free(record);
#endif
}
-
+
/*Category support*/
e_pilot_local_category_to_remote(&(local->local.category), comp, &(ctxt->ai.category));
/* STOP: don't replace these with g_strdup, since free_ToDo
uses free to deallocate */
e_cal_component_get_summary (comp, &summary);
- if (summary.value)
+ if (summary.value)
local->todo->description = e_pilot_utf8_to_pchar (summary.value);
e_cal_component_get_description_list (comp, &d_list);
@@ -729,7 +729,7 @@ local_record_from_comp (EToDoLocalRecord *local, ECalComponent *comp, EToDoCondu
local->todo->note = NULL;
}
- e_cal_component_get_due (comp, &due);
+ e_cal_component_get_due (comp, &due);
if (due.value) {
icaltimezone_convert_time (due.value,
get_timezone (ctxt->client, due.tzid),
@@ -739,14 +739,14 @@ local_record_from_comp (EToDoLocalRecord *local, ECalComponent *comp, EToDoCondu
} else {
local->todo->indefinite = 1;
}
- e_cal_component_free_datetime (&due);
+ e_cal_component_free_datetime (&due);
- e_cal_component_get_status (comp, &status);
+ e_cal_component_get_status (comp, &status);
if (status == ICAL_STATUS_COMPLETED)
local->todo->complete = 1;
else
local->todo->complete = 0;
-
+
e_cal_component_get_priority (comp, &priority);
if (priority && *priority != 0) {
if (*priority <= 3)
@@ -759,12 +759,12 @@ local_record_from_comp (EToDoLocalRecord *local, ECalComponent *comp, EToDoCondu
local->todo->priority = 4;
else
local->todo->priority = 5;
-
+
e_cal_component_free_priority (priority);
} else {
local->todo->priority = ctxt->cfg->priority;
- }
-
+ }
+
e_cal_component_get_classification (comp, &classif);
if (classif == E_CAL_COMPONENT_CLASS_PRIVATE)
@@ -775,7 +775,7 @@ local_record_from_comp (EToDoLocalRecord *local, ECalComponent *comp, EToDoCondu
local->local.archived = 0;
}
-static void
+static void
local_record_from_uid (EToDoLocalRecord *local,
const char *uid,
EToDoConduitContext *ctxt)
@@ -785,7 +785,7 @@ local_record_from_uid (EToDoLocalRecord *local,
GError *error = NULL;
g_assert(local!=NULL);
-
+
LOG(g_message("local_record_from_uid\n"));
if (e_cal_get_object (ctxt->client, uid, NULL, &icalcomp, &error)) {
@@ -830,7 +830,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
#ifdef PILOT_LINK_0_12
pi_buffer_t * buffer;
#endif
-
+
g_return_val_if_fail (remote != NULL, NULL);
#ifdef PILOT_LINK_0_12
@@ -851,7 +851,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
#endif
utc_zone = icaltimezone_get_utc_timezone ();
- now = icaltime_from_timet_with_zone (time (NULL), FALSE,
+ now = icaltime_from_timet_with_zone (time (NULL), FALSE,
utc_zone);
if (in_comp == NULL) {
@@ -867,10 +867,10 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
summary.value = txt = e_pilot_utf8_from_pchar (todo.description);
e_cal_component_set_summary (comp, &summary);
free (txt);
-
+
/*Category support*/
e_pilot_remote_category_to_local(remote->category, comp, &(ai->category));
-
+
/* The iCal description field */
if (!todo.note) {
e_cal_component_set_comment_list (comp, NULL);
@@ -885,7 +885,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
e_cal_component_set_description_list (comp, &l);
free (txt);
- }
+ }
if (todo.complete) {
int percent = 100;
@@ -896,9 +896,9 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
} else {
int *percent = NULL;
icalproperty_status status;
-
+
e_cal_component_set_completed (comp, NULL);
-
+
e_cal_component_get_percent (comp, &percent);
if (percent == NULL || *percent == 100) {
int p = 0;
@@ -934,7 +934,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
default:
priority = 9;
}
-
+
e_cal_component_set_priority (comp, &priority);
e_cal_component_set_transparency (comp, E_CAL_COMPONENT_TRANSP_NONE);
@@ -944,7 +944,7 @@ comp_from_remote_record (GnomePilotConduitSyncAbs *conduit,
e_cal_component_set_classification (comp, E_CAL_COMPONENT_CLASS_PUBLIC);
e_cal_component_commit_sequence (comp);
-
+
free_ToDo(&todo);
return comp;
@@ -956,7 +956,7 @@ check_for_slow_setting (GnomePilotConduit *c, EToDoConduitContext *ctxt)
GnomePilotConduitStandard *conduit = GNOME_PILOT_CONDUIT_STANDARD (c);
int map_count;
const char *uri;
-
+
/* If there are no objects or objects but no log */
map_count = g_hash_table_size (ctxt->map->pid_map);
if (map_count == 0)
@@ -975,7 +975,7 @@ check_for_slow_setting (GnomePilotConduit *c, EToDoConduitContext *ctxt)
LOG (g_message ( " doing slow sync\n" ));
} else {
LOG (g_message ( " doing fast sync\n" ));
- }
+ }
}
/* Pilot syncing callbacks */
@@ -1001,7 +1001,7 @@ pre_sync (GnomePilotConduit *conduit,
LOG (g_message ( "pre_sync: ToDo Conduit v.%s", CONDUIT_VERSION ));
g_message ("ToDo Conduit v.%s", CONDUIT_VERSION);
- ctxt->dbi = dbi;
+ ctxt->dbi = dbi;
ctxt->client = NULL;
/* Get the timezone */
@@ -1015,19 +1015,19 @@ pre_sync (GnomePilotConduit *conduit,
gnome_pilot_conduit_error (conduit, _("Could not start evolution-data-server"));
return -1;
}
-
+
/* Get the default component */
if (!e_cal_get_default_object (ctxt->client, &icalcomp, NULL))
return -1;
LOG (g_message ( " Got default component: %p", icalcomp));
-
+
ctxt->default_comp = e_cal_component_new ();
if (!e_cal_component_set_icalcomponent (ctxt->default_comp, icalcomp)) {
g_object_unref (ctxt->default_comp);
icalcomponent_free (icalcomp);
return -1;
}
-
+
/* Load the uid <--> pilot id map */
filename = map_name (ctxt);
e_pilot_map_read (filename, &ctxt->map);
@@ -1036,24 +1036,24 @@ pre_sync (GnomePilotConduit *conduit,
/* Get the local database */
if (!e_cal_get_object_list_as_comp (ctxt->client, "#t", &ctxt->comps, NULL))
return -1;
-
+
/* Count and hash the changes */
change_id = g_strdup_printf ("pilot-sync-evolution-todo-%d", ctxt->cfg->pilot_id);
if (!e_cal_get_changes (ctxt->client, change_id, &ctxt->changed, NULL))
return -1;
-
+
ctxt->changed_hash = g_hash_table_new (g_str_hash, g_str_equal);
g_free (change_id);
-
+
for (l = ctxt->changed; l != NULL; l = l->next) {
ECalChange *ccc = l->data;
const char *uid;
-
+
e_cal_component_get_uid (ccc->comp, &uid);
if (!e_pilot_map_uid_is_archived (ctxt->map, uid)) {
-
+
g_hash_table_insert (ctxt->changed_hash, g_strdup (uid), ccc);
-
+
switch (ccc->type) {
case E_CAL_CHANGE_ADDED:
add_records++;
@@ -1076,7 +1076,7 @@ pre_sync (GnomePilotConduit *conduit,
gnome_pilot_conduit_sync_abs_set_num_new_local_records (abs_conduit, add_records);
gnome_pilot_conduit_sync_abs_set_num_updated_local_records (abs_conduit, mod_records);
gnome_pilot_conduit_sync_abs_set_num_deleted_local_records(abs_conduit, del_records);
-
+
g_message("num_records: %d\nadd_records: %d\nmod_records: %d\ndel_records: %d\n",
num_records, add_records, mod_records, del_records);
@@ -1093,7 +1093,7 @@ pre_sync (GnomePilotConduit *conduit,
buf = (unsigned char*)g_malloc (0xffff);
len = dlp_ReadAppBlock (dbi->pilot_socket, dbi->db_handle, 0,
(unsigned char *)buf, 0xffff);
-#endif
+#endif
if (len < 0) {
WARN (_("Could not read pilot's ToDo application block"));
WARN ("dlp_ReadAppBlock(...) = %d", len);
@@ -1109,14 +1109,14 @@ pre_sync (GnomePilotConduit *conduit,
#endif
unpack_ToDoAppInfo (&(ctxt->ai), buf, len);
g_free (buf);
-
+
lastDesktopUniqueID = 128;
check_for_slow_setting (conduit, ctxt);
if (ctxt->cfg->sync_type == GnomePilotConduitSyncTypeCopyToPilot
|| ctxt->cfg->sync_type == GnomePilotConduitSyncTypeCopyFromPilot)
ctxt->map->write_touched_only = TRUE;
-
+
return 0;
}
@@ -1131,14 +1131,14 @@ post_sync (GnomePilotConduit *conduit,
int dlpRetVal, len;
buf = (unsigned char*)g_malloc (0xffff);
-
+
len = pack_ToDoAppInfo (&(ctxt->ai), buf, 0xffff);
-
- dlpRetVal = dlp_WriteAppBlock (dbi->pilot_socket, dbi->db_handle,
+
+ dlpRetVal = dlp_WriteAppBlock (dbi->pilot_socket, dbi->db_handle,
(unsigned char *)buf, len);
-
+
g_free (buf);
-
+
if (dlpRetVal < 0) {
WARN (_("Could not write pilot's ToDo application block"));
WARN ("dlp_WriteAppBlock(...) = %d", dlpRetVal);
@@ -1146,14 +1146,14 @@ post_sync (GnomePilotConduit *conduit,
_("Could not write pilot's ToDo application block"));
return -1;
}
-
+
LOG (g_message ( "post_sync: ToDo Conduit v.%s", CONDUIT_VERSION ));
g_free (ctxt->cfg->last_uri);
ctxt->cfg->last_uri = g_strdup (e_cal_get_uri (ctxt->client));
todoconduit_save_configuration (ctxt->cfg);
-
+
filename = map_name (ctxt);
e_pilot_map_write (filename, ctxt->map);
g_free (filename);
@@ -1165,7 +1165,7 @@ post_sync (GnomePilotConduit *conduit,
if (e_cal_get_changes (ctxt->client, change_id, &changed, NULL))
e_cal_free_change_list (changed);
g_free (change_id);
-
+
LOG (g_message ( "---------------------------------------------------------\n" ));
return 0;
@@ -1180,7 +1180,7 @@ set_pilot_id (GnomePilotConduitSyncAbs *conduit,
const char *uid;
LOG (g_message ( "set_pilot_id: setting to %d\n", ID ));
-
+
e_cal_component_get_uid (local->comp, &uid);
e_pilot_map_insert (ctxt->map, ID, uid, FALSE);
@@ -1193,12 +1193,12 @@ set_status_cleared (GnomePilotConduitSyncAbs *conduit,
EToDoConduitContext *ctxt)
{
const char *uid;
-
+
LOG (g_message ( "set_status_cleared: clearing status\n" ));
-
+
e_cal_component_get_uid (local->comp, &uid);
g_hash_table_remove (ctxt->changed_hash, uid);
-
+
return 0;
}
@@ -1218,7 +1218,7 @@ for_each (GnomePilotConduitSyncAbs *conduit,
comps = ctxt->comps;
count = 0;
-
+
if (comps != NULL) {
LOG (g_message ( "iterating over %d records", g_list_length (comps)));
@@ -1229,7 +1229,7 @@ for_each (GnomePilotConduitSyncAbs *conduit,
* gets messed up. The calling function keeps track of
* the *local variable */
unused = g_list_prepend (ctxt->locals, *local);
-
+
iterator = comps;
} else {
LOG (g_message ( "no events" ));
@@ -1243,7 +1243,7 @@ for_each (GnomePilotConduitSyncAbs *conduit,
*local = g_new0 (EToDoLocalRecord, 1);
local_record_from_comp (*local, iterator->data, ctxt);
-
+
/* NOTE: ignore the return value, otherwise ctxt->locals
* gets messed up. The calling function keeps track of
* the *local variable */
@@ -1274,20 +1274,20 @@ for_each_modified (GnomePilotConduitSyncAbs *conduit,
if (*local == NULL) {
LOG (g_message ( "for_each_modified beginning\n" ));
-
+
iterator = ctxt->changed;
-
+
count = 0;
-
+
LOG (g_message ( "iterating over %d records", g_hash_table_size (ctxt->changed_hash) ));
-
+
iterator = next_changed_item (ctxt, iterator);
if (iterator != NULL) {
ECalChange *ccc = iterator->data;
-
+
*local = g_new0 (EToDoLocalRecord, 1);
local_record_from_comp (*local, ccc->comp, ctxt);
-
+
/* NOTE: ignore the return value, otherwise ctxt->locals
* gets messed up. The calling function keeps track of
* the *local variable */
@@ -1302,10 +1302,10 @@ for_each_modified (GnomePilotConduitSyncAbs *conduit,
iterator = g_list_next (iterator);
if (iterator && (iterator = next_changed_item (ctxt, iterator))) {
ECalChange *ccc = iterator->data;
-
+
*local = g_new0 (EToDoLocalRecord, 1);
- local_record_from_comp (*local, ccc->comp, ctxt);
-
+ local_record_from_comp (*local, ccc->comp, ctxt);
+
/* NOTE: ignore the return value, otherwise ctxt->locals
* gets messed up. The calling function keeps track of
* the *local variable */
@@ -1347,7 +1347,7 @@ compare (GnomePilotConduitSyncAbs *conduit,
LOG (g_message ( " equal" ));
else
LOG (g_message ( " not equal" ));
-
+
return retval;
}
@@ -1359,7 +1359,7 @@ add_record (GnomePilotConduitSyncAbs *conduit,
ECalComponent *comp;
char *uid;
int retval = 0;
-
+
g_return_val_if_fail (remote != NULL, -1);
LOG (g_message ( "add_record: adding %s to desktop\n", print_remote (remote) ));
@@ -1389,7 +1389,7 @@ replace_record (GnomePilotConduitSyncAbs *conduit,
{
ECalComponent *new_comp;
int retval = 0;
-
+
g_return_val_if_fail (remote != NULL, -1);
LOG (g_message ("replace_record: replace %s with %s\n",
@@ -1399,7 +1399,7 @@ replace_record (GnomePilotConduitSyncAbs *conduit,
g_object_unref (local->comp);
local->comp = new_comp;
- if (!e_cal_modify_object (ctxt->client, e_cal_component_get_icalcomponent (new_comp),
+ if (!e_cal_modify_object (ctxt->client, e_cal_component_get_icalcomponent (new_comp),
CALOBJ_MOD_ALL, NULL))
return -1;
@@ -1423,7 +1423,7 @@ delete_record (GnomePilotConduitSyncAbs *conduit,
e_pilot_map_remove_by_uid (ctxt->map, uid);
/* FIXME Error handling */
e_cal_remove_object (ctxt->client, uid, NULL);
-
+
return 0;
}
@@ -1435,14 +1435,14 @@ archive_record (GnomePilotConduitSyncAbs *conduit,
{
const char *uid;
int retval = 0;
-
+
g_return_val_if_fail (local != NULL, -1);
LOG (g_message ( "archive_record: %s\n", archive ? "yes" : "no" ));
e_cal_component_get_uid (local->comp, &uid);
e_pilot_map_insert (ctxt->map, local->local.ID, uid, archive);
-
+
return retval;
}
@@ -1453,24 +1453,24 @@ match (GnomePilotConduitSyncAbs *conduit,
EToDoConduitContext *ctxt)
{
const char *uid;
-
+
LOG (g_message ("match: looking for local copy of %s\n",
- print_remote (remote)));
-
+ print_remote (remote)));
+
g_return_val_if_fail (local != NULL, -1);
g_return_val_if_fail (remote != NULL, -1);
*local = NULL;
uid = e_pilot_map_lookup_uid (ctxt->map, remote->ID, TRUE);
-
+
if (!uid)
return 0;
LOG (g_message ( " matched\n" ));
-
+
*local = g_new0 (EToDoLocalRecord, 1);
local_record_from_uid (*local, uid, ctxt);
-
+
return 0;
}
@@ -1506,7 +1506,7 @@ static void
fill_widgets (EToDoConduitContext *ctxt)
{
if (ctxt->cfg->source)
- e_pilot_settings_set_source (E_PILOT_SETTINGS (ctxt->ps),
+ e_pilot_settings_set_source (E_PILOT_SETTINGS (ctxt->ps),
ctxt->cfg->source);
e_pilot_settings_set_secret (E_PILOT_SETTINGS (ctxt->ps),
ctxt->cfg->secret);
@@ -1520,8 +1520,8 @@ create_settings_window (GnomePilotConduit *conduit,
EToDoConduitContext *ctxt)
{
LOG (g_message ( "create_settings_window" ));
-
- if (!ctxt->cfg->source_list)
+
+ if (!ctxt->cfg->source_list)
return -1;
ctxt->ps = e_pilot_settings_new (ctxt->cfg->source_list);
@@ -1531,7 +1531,7 @@ create_settings_window (GnomePilotConduit *conduit,
gtk_widget_show (ctxt->ps);
fill_widgets (ctxt);
-
+
return 0;
}
@@ -1539,7 +1539,7 @@ static void
display_settings (GnomePilotConduit *conduit, EToDoConduitContext *ctxt)
{
LOG (g_message ( "display_settings" ));
-
+
fill_widgets (ctxt);
}
@@ -1554,7 +1554,7 @@ save_settings (GnomePilotConduit *conduit, EToDoConduitContext *ctxt)
g_object_ref (ctxt->new_cfg->source);
ctxt->new_cfg->secret = e_pilot_settings_get_secret (E_PILOT_SETTINGS (ctxt->ps));
e_todo_gui_fill_config (ctxt->gui, ctxt->new_cfg);
-
+
todoconduit_save_configuration (ctxt->new_cfg);
}
@@ -1578,7 +1578,7 @@ conduit_get_gpilot_conduit (guint32 pilot_id)
retval = gnome_pilot_conduit_sync_abs_new ("ToDoDB", 0x746F646F);
g_assert (retval != NULL);
-
+
ctxt = e_todo_context_new (pilot_id);
gtk_object_set_data (GTK_OBJECT (retval), "todoconduit_context", ctxt);
@@ -1613,10 +1613,10 @@ conduit_get_gpilot_conduit (guint32 pilot_id)
void
conduit_destroy_gpilot_conduit (GnomePilotConduit *conduit)
-{
+{
GtkObject *obj = GTK_OBJECT (conduit);
EToDoConduitContext *ctxt;
-
+
ctxt = gtk_object_get_data (obj, "todoconduit_context");
e_todo_context_destroy (ctxt);
diff --git a/calendar/gui/alarm-notify/alarm-notify-dialog.c b/calendar/gui/alarm-notify/alarm-notify-dialog.c
index eab6b95606..7022c389be 100644
--- a/calendar/gui/alarm-notify/alarm-notify-dialog.c
+++ b/calendar/gui/alarm-notify/alarm-notify-dialog.c
@@ -34,7 +34,7 @@
#include <gtk/gtkwindow.h>
#include <gtk/gtk.h>
#include <glib/gi18n.h>
-#if 0
+#if 0
# include <libgnomeui/gnome-winhints.h>
#endif
#include <glade/glade.h>
@@ -46,7 +46,7 @@
#include <e-util/e-icon-factory.h>
-
+
enum {
ALARM_DISPLAY_COLUMN,
ALARM_SUMMARY_COLUMN,
@@ -55,7 +55,7 @@ enum {
ALARM_START_COLUMN,
ALARM_END_COLUMN,
-
+
ALARM_FUNCINFO_COLUMN,
N_ALARM_COLUMNS
@@ -74,16 +74,16 @@ typedef struct {
GtkWidget *dialog;
GtkWidget *snooze_time_min;
GtkWidget *snooze_time_hrs;
- GtkWidget *snooze_btn;
+ GtkWidget *snooze_btn;
GtkWidget *minutes_label;
GtkWidget *hrs_label;
GtkWidget *description;
GtkWidget *location;
GtkWidget *treeview;
GtkWidget *scrolledwindow;
-
+
AlarmFuncInfo *cur_funcinfo;
-
+
} AlarmNotify;
@@ -91,9 +91,9 @@ static void
tree_selection_changed_cb (GtkTreeSelection *selection, gpointer data);
static void
-fill_in_labels (AlarmNotify *an, const gchar *summary, const gchar *description,
+fill_in_labels (AlarmNotify *an, const gchar *summary, const gchar *description,
const gchar *location, time_t occur_start, time_t occur_end);
-static void
+static void
edit_pressed_cb (GtkButton *button, gpointer user_data);
static void
@@ -137,7 +137,7 @@ dialog_response_cb (GtkDialog *dialog, guint response_id, gpointer user_data)
GtkTreeModel *model = NULL;
AlarmFuncInfo *funcinfo = NULL;
GtkTreeSelection *selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (an->treeview));
-
+
if (gtk_tree_selection_get_selected (selection, &model, &iter)) {
gtk_tree_model_get (model, &iter, ALARM_FUNCINFO_COLUMN, &funcinfo, -1);
}
@@ -158,7 +158,7 @@ dialog_response_cb (GtkDialog *dialog, guint response_id, gpointer user_data)
return;
}
-static void
+static void
edit_pressed_cb (GtkButton *button, gpointer user_data)
{
AlarmNotify *an = user_data;
@@ -168,14 +168,14 @@ edit_pressed_cb (GtkButton *button, gpointer user_data)
GtkTreeSelection *selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (an->treeview));
if (gtk_tree_selection_get_selected (selection, &model, &iter))
- gtk_tree_model_get (model, &iter, ALARM_FUNCINFO_COLUMN, &funcinfo, -1);
+ gtk_tree_model_get (model, &iter, ALARM_FUNCINFO_COLUMN, &funcinfo, -1);
g_return_if_fail (funcinfo);
-
+
(* funcinfo->func) (ALARM_NOTIFY_EDIT, -1, funcinfo->func_data);
}
-static void
+static void
snooze_pressed_cb (GtkButton *button, gpointer user_data)
{
int snooze_timeout;
@@ -188,7 +188,7 @@ snooze_pressed_cb (GtkButton *button, gpointer user_data)
gtk_widget_grab_focus ((GtkWidget *) button);
if (gtk_tree_selection_get_selected (selection, &model, &iter))
- gtk_tree_model_get (model, &iter, ALARM_FUNCINFO_COLUMN, &funcinfo, -1);
+ gtk_tree_model_get (model, &iter, ALARM_FUNCINFO_COLUMN, &funcinfo, -1);
g_return_if_fail (funcinfo);
@@ -226,25 +226,25 @@ notified_alarms_dialog_new (void)
GtkTreeViewColumn *column = NULL;
GtkTreeSelection *selection = NULL;
GtkTreeModel *model = GTK_TREE_MODEL (gtk_list_store_new (
- N_ALARM_COLUMNS,
-
+ N_ALARM_COLUMNS,
+
G_TYPE_STRING, /* Display */
G_TYPE_STRING, /* Summary */
G_TYPE_STRING, /* Description */
G_TYPE_STRING, /* Location */
-
+
G_TYPE_POINTER, /* Start */
G_TYPE_POINTER, /* End */
-
+
G_TYPE_POINTER /* FuncInfo*/));
-
+
an->xml = glade_xml_new (EVOLUTION_GLADEDIR "/alarm-notify.glade", NULL, NULL);
if (!an->xml) {
g_message ("alarm_notify_dialog(): Could not load the Glade XML file!");
g_free (an);
return NULL;
}
-
+
an->dialog = glade_xml_get_widget (an->xml, "alarm-notify");
an->snooze_time_min = glade_xml_get_widget (an->xml, "snooze-time-min");
an->minutes_label = glade_xml_get_widget (an->xml, "minutes-label");
@@ -258,7 +258,7 @@ notified_alarms_dialog_new (void)
an->snooze_btn = snooze_btn;
edit_btn = glade_xml_get_widget (an->xml, "edit-button");
- if (!(an->dialog && an->scrolledwindow && an->treeview && an->snooze_time_min && an->snooze_time_hrs
+ if (!(an->dialog && an->scrolledwindow && an->treeview && an->snooze_time_min && an->snooze_time_hrs
&& an->description && an->location && edit_btn && snooze_btn)) {
g_message ("alarm_notify_dialog(): Could not find all widgets in Glade file!");
g_object_unref (an->xml);
@@ -275,14 +275,14 @@ notified_alarms_dialog_new (void)
gtk_tree_view_column_set_attributes (column, renderer,
"markup", ALARM_DISPLAY_COLUMN, NULL);
-
+
gtk_tree_view_append_column (GTK_TREE_VIEW (an->treeview), column);
-
+
selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (an->treeview));
gtk_tree_selection_set_mode (selection, GTK_SELECTION_SINGLE);
g_signal_connect (G_OBJECT (selection), "changed",
G_CALLBACK (tree_selection_changed_cb), an);
-
+
gtk_widget_realize (an->dialog);
gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (an->dialog)->vbox), 0);
gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (an->dialog)->action_area), 12);
@@ -295,7 +295,7 @@ notified_alarms_dialog_new (void)
g_signal_connect (snooze_btn, "clicked", G_CALLBACK (snooze_pressed_cb), an);
g_signal_connect (G_OBJECT (an->dialog), "response", G_CALLBACK (dialog_response_cb), an);
g_signal_connect (G_OBJECT (an->dialog), "destroy", G_CALLBACK (dialog_destroyed_cb), an);
-
+
if (!GTK_WIDGET_REALIZED (an->dialog))
gtk_widget_realize (an->dialog);
icon_list = e_icon_factory_get_icon_list ("stock_alarm");
@@ -304,25 +304,25 @@ notified_alarms_dialog_new (void)
g_list_foreach (icon_list, (GFunc) g_object_unref, NULL);
g_list_free (icon_list);
}
-
+
/* Set callback for updating the snooze "minutes" label */
g_signal_connect (G_OBJECT (an->snooze_time_min), "value_changed",
G_CALLBACK (an_update_minutes_label), an);
-
+
/* Set callback for updating the snooze "hours" label */
g_signal_connect (G_OBJECT (an->snooze_time_hrs), "value_changed",
G_CALLBACK (an_update_hrs_label), an);
-
-
+
+
na = g_new0 (AlarmNotificationsDialog, 1);
na->treeview = an->treeview;
na->dialog = an->dialog;
-
+
return na;
}
-
-
+
+
/**
* add_alarm_to_notified_alarms_dialog:
* @na: Pointer to the dialog-info
@@ -341,9 +341,9 @@ notified_alarms_dialog_new (void)
*
* Return value: the iter in the treeview of the dialog
**/
-
-GtkTreeIter
-add_alarm_to_notified_alarms_dialog (AlarmNotificationsDialog *na, time_t trigger,
+
+GtkTreeIter
+add_alarm_to_notified_alarms_dialog (AlarmNotificationsDialog *na, time_t trigger,
time_t occur_start, time_t occur_end,
ECalComponentVType vtype, const char *summary,
const char *description, const char *location,
@@ -368,29 +368,29 @@ add_alarm_to_notified_alarms_dialog (AlarmNotificationsDialog *na, time_t trigge
funcinfo = g_new0 (AlarmFuncInfo, 1);
funcinfo->func = func;
funcinfo->func_data = func_data;
-
+
gtk_list_store_append (GTK_LIST_STORE(model), &iter);
current_zone = config_data_get_timezone ();
start = timet_to_str_with_zone (occur_start, current_zone);
end = timet_to_str_with_zone (occur_end, current_zone);
str_time = calculate_time (occur_start, occur_end);
- to_display = g_strdup_printf ("<big><b>%s</b></big>\n%s %s",
+ to_display = g_strdup_printf ("<big><b>%s</b></big>\n%s %s",
summary, start, str_time);
g_free (start);
g_free (end);
- gtk_list_store_set (GTK_LIST_STORE(model), &iter,
+ gtk_list_store_set (GTK_LIST_STORE(model), &iter,
ALARM_DISPLAY_COLUMN, to_display, -1);
g_free (to_display);
g_free (str_time);
-
+
gtk_list_store_set (GTK_LIST_STORE(model), &iter, ALARM_SUMMARY_COLUMN, summary, -1);
gtk_list_store_set (GTK_LIST_STORE(model), &iter, ALARM_DESCRIPTION_COLUMN, description, -1);
gtk_list_store_set (GTK_LIST_STORE(model), &iter, ALARM_LOCATION_COLUMN, location, -1);
gtk_list_store_set (GTK_LIST_STORE(model), &iter, ALARM_START_COLUMN, occur_start, -1);
gtk_list_store_set (GTK_LIST_STORE(model), &iter, ALARM_END_COLUMN, occur_end, -1);
gtk_list_store_set (GTK_LIST_STORE(model), &iter, ALARM_FUNCINFO_COLUMN, funcinfo, -1);
-
+
return iter;
}
@@ -400,7 +400,7 @@ tree_selection_changed_cb (GtkTreeSelection *selection, gpointer user_data)
GtkTreeModel *model;
GtkTreeIter iter;
AlarmNotify *an = user_data;
-
+
if (gtk_tree_selection_get_selected (selection, &model, &iter))
{
gchar *summary, *description, *location;
@@ -413,17 +413,17 @@ tree_selection_changed_cb (GtkTreeSelection *selection, gpointer user_data)
gtk_tree_model_get (model, &iter, ALARM_START_COLUMN, &occur_start, -1);
gtk_tree_model_get (model, &iter, ALARM_END_COLUMN, &occur_end, -1);\
gtk_tree_model_get (model, &iter, ALARM_FUNCINFO_COLUMN, &an->cur_funcinfo, -1);
-
+
fill_in_labels (an, summary, description, location, occur_start, occur_end);
} else {
- gtk_widget_set_sensitive (an->snooze_btn, FALSE);
+ gtk_widget_set_sensitive (an->snooze_btn, FALSE);
}
}
-static void
-fill_in_labels (AlarmNotify *an, const gchar *summary, const gchar *description,
+static void
+fill_in_labels (AlarmNotify *an, const gchar *summary, const gchar *description,
const gchar *location, time_t occur_start, time_t occur_end)
{
GtkTextTagTable *table = gtk_text_tag_table_new ();
diff --git a/calendar/gui/alarm-notify/alarm-notify-dialog.h b/calendar/gui/alarm-notify/alarm-notify-dialog.h
index fbfc64adc6..43bfb2c523 100644
--- a/calendar/gui/alarm-notify/alarm-notify-dialog.h
+++ b/calendar/gui/alarm-notify/alarm-notify-dialog.h
@@ -49,8 +49,8 @@ typedef void (* AlarmNotifyFunc) (AlarmNotifyResult result, int snooze_mins, gpo
AlarmNotificationsDialog *
notified_alarms_dialog_new (void);
-GtkTreeIter
-add_alarm_to_notified_alarms_dialog (AlarmNotificationsDialog *na, time_t trigger,
+GtkTreeIter
+add_alarm_to_notified_alarms_dialog (AlarmNotificationsDialog *na, time_t trigger,
time_t occur_start, time_t occur_end,
ECalComponentVType vtype, const char *summary,
const char *description, const char *location,
diff --git a/calendar/gui/alarm-notify/alarm-notify.c b/calendar/gui/alarm-notify/alarm-notify.c
index 9044f2d5d6..4d287c8cd2 100644
--- a/calendar/gui/alarm-notify/alarm-notify.c
+++ b/calendar/gui/alarm-notify/alarm-notify.c
@@ -40,7 +40,7 @@ struct _AlarmNotifyPrivate {
/* FIXME do we need per source type uri hashes? or perhaps we
just need to hash based on source */
GHashTable *uri_client_hash [E_CAL_SOURCE_TYPE_LAST];
- ESourceList *source_lists [E_CAL_SOURCE_TYPE_LAST];
+ ESourceList *source_lists [E_CAL_SOURCE_TYPE_LAST];
ESourceList *selected_calendars;
GMutex *mutex;
};
@@ -88,23 +88,23 @@ process_removal_in_hash (gpointer key, gpointer value, gpointer data)
ProcessRemovalsData *prd = data;
GSList *groups, *sources, *p, *q;
gboolean found = FALSE;
-
+
/* search the list of selected calendars */
groups = e_source_list_peek_groups (prd->source_list);
for (p = groups; p != NULL; p = p->next) {
ESourceGroup *group = E_SOURCE_GROUP (p->data);
-
+
sources = e_source_group_peek_sources (group);
for (q = sources; q != NULL; q = q->next) {
ESource *source = E_SOURCE (q->data);
char *source_uri;
const char *completion = e_source_get_property (source, "alarm");
-
+
source_uri = e_source_get_uri (source);
if (strcmp (source_uri, uri) == 0)
if (!completion || !g_ascii_strcasecmp (completion, "true"))
found = TRUE;
-
+
g_free (source_uri);
if (found)
@@ -128,7 +128,7 @@ list_changed_cb (ESourceList *source_list, gpointer data)
int i;
g_signal_handlers_block_by_func(source_list, list_changed_cb, data);
-
+
priv = an->priv;
/* Figure out the source type */
@@ -140,25 +140,25 @@ list_changed_cb (ESourceList *source_list, gpointer data)
}
if (source_type == E_CAL_SOURCE_TYPE_LAST)
return;
-
+
/* process the additions */
groups = e_source_list_peek_groups (source_list);
for (p = groups; p != NULL; p = p->next) {
ESourceGroup *group = E_SOURCE_GROUP (p->data);
-
+
sources = e_source_group_peek_sources (group);
for (q = sources; q != NULL; q = q->next) {
ESource *source = E_SOURCE (q->data);
char *uri;
const char *completion = e_source_get_property (source, "alarm");
-
- if (completion && (!g_ascii_strcasecmp (completion, "false") ||
+
+ if (completion && (!g_ascii_strcasecmp (completion, "false") ||
!g_ascii_strcasecmp (completion, "never")))
continue;
-
+
uri = e_source_get_uri (source);
if (!g_hash_table_lookup (priv->uri_client_hash[source_type], uri)) {
- d (printf("%s:%d (list_changed_cb) - Adding Calendar %s\n", __FILE__, __LINE__, uri));
+ d (printf("%s:%d (list_changed_cb) - Adding Calendar %s\n", __FILE__, __LINE__, uri));
alarm_notify_add_calendar (an, source_type, source, FALSE);
}
g_free (uri);
@@ -177,7 +177,7 @@ list_changed_cb (ESourceList *source_list, gpointer data)
}
g_list_free (prd.removals);
g_signal_handlers_unblock_by_func(source_list, list_changed_cb, data);
-
+
}
ESourceList *
@@ -194,7 +194,7 @@ load_calendars (AlarmNotify *an, ECalSourceType source_type)
GSList *groups, *sources, *p, *q;
priv = an->priv;
-
+
if (!e_cal_get_sources (&source_list, source_type, NULL)) {
d (printf("%s:%d (load_calendars) - Cannont get sources\n ", __FILE__, __LINE__));
priv->source_lists[source_type] = NULL;
@@ -205,22 +205,22 @@ load_calendars (AlarmNotify *an, ECalSourceType source_type)
groups = e_source_list_peek_groups (source_list);
for (p = groups; p != NULL; p = p->next) {
ESourceGroup *group = E_SOURCE_GROUP (p->data);
-
+
sources = e_source_group_peek_sources (group);
for (q = sources; q != NULL; q = q->next) {
ESource *source = E_SOURCE (q->data);
char *uri;
const char *completion = e_source_get_property (source, "alarm");
-
+
if (completion && (!g_ascii_strcasecmp (completion, "false") ||
- !g_ascii_strcasecmp (completion, "never")))
+ !g_ascii_strcasecmp (completion, "never")))
continue;
-
+
uri = e_source_get_uri (source);
- d (printf("%s:%d (load_calendars) - Loading Calendar %s \n", __FILE__, __LINE__, uri));
+ d (printf("%s:%d (load_calendars) - Loading Calendar %s \n", __FILE__, __LINE__, uri));
alarm_notify_add_calendar (an, source_type, source, FALSE);
g_free (uri);
-
+
}
}
@@ -241,7 +241,7 @@ alarm_notify_init (AlarmNotify *an, AlarmNotifyClass *klass)
priv->selected_calendars = config_data_get_calendars ("/apps/evolution/calendar/sources");
d (printf("%s:%d (alarm_notify_init) - Initing Alarm Notify\n", __FILE__, __LINE__));
-
+
for (i = 0; i < E_CAL_SOURCE_TYPE_LAST; i++)
priv->uri_client_hash[i] = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_object_unref);
@@ -267,12 +267,12 @@ alarm_notify_finalize (GObject *object)
AlarmNotify *an;
AlarmNotifyPrivate *priv;
int i;
-
+
g_return_if_fail (object != NULL);
g_return_if_fail (IS_ALARM_NOTIFY (object));
-
+
d (printf("%s:%d (alarm_notify_finalize) - Finalize \n ", __FILE__, __LINE__));
-
+
an = ALARM_NOTIFY (object);
priv = an->priv;
@@ -345,8 +345,8 @@ static void
alarm_msg_received(EThread *e, EMsg *msg, void *data)
{
AlarmMsg *m = (AlarmMsg *)msg;
-
- d(printf("%s:%d (alarm_msg_received) - %p: Received at thread %" G_GINT64_MODIFIER "x\n", __FILE__, __LINE__, m, e_util_pthread_id(pthread_self())));
+
+ d(printf("%s:%d (alarm_msg_received) - %p: Received at thread %" G_GINT64_MODIFIER "x\n", __FILE__, __LINE__, m, e_util_pthread_id(pthread_self())));
if (m->receive_msg) {
m->receive_msg (e, m, data);
}
@@ -354,9 +354,9 @@ alarm_msg_received(EThread *e, EMsg *msg, void *data)
/**
* alarm_notify_new:
- *
+ *
* Creates a new #AlarmNotify object.
- *
+ *
* Return value: A newly-created #AlarmNotify, or NULL if its corresponding
* CORBA object could not be created.
**/
@@ -364,10 +364,10 @@ AlarmNotify *
alarm_notify_new (void)
{
AlarmNotify *an;
-
+
d (printf("%s:%d (alarm_notify_new) - Alarm Notify New \n ", __FILE__, __LINE__));
- /* Create a thread for alarm queue operation*/
+ /* Create a thread for alarm queue operation*/
alarm_channel_setup(&alarm_reply_port, &alarm_reply_channel, alarm_msgport_replied);
alarm_operation_thread = e_thread_new(E_THREAD_QUEUE);
@@ -378,7 +378,7 @@ alarm_notify_new (void)
an = g_object_new (TYPE_ALARM_NOTIFY,
"poa", bonobo_poa_get_threaded (ORBIT_THREAD_HINT_PER_REQUEST, NULL),
NULL);
-
+
return an;
}
@@ -389,9 +389,9 @@ cal_opened_cb (ECal *client, ECalendarStatus status, gpointer user_data)
AlarmNotify *an = ALARM_NOTIFY (user_data);
priv = an->priv;
-
+
d (printf("%s:%d (cal_opened_cb) %s - Calendar Status %d\n", __FILE__, __LINE__, e_cal_get_uri (client), status));
-
+
if (status == E_CALENDAR_STATUS_OK)
alarm_queue_add_client (client);
else {
@@ -408,7 +408,7 @@ cal_opened_cb (ECal *client, ECalendarStatus status, gpointer user_data)
* @uri: URI of the calendar to load.
* @load_afterwards: Whether this calendar should be loaded in the future
* when the alarm daemon starts up.
- *
+ *
* Tells the alarm notification service to load a calendar and start monitoring
* its alarms. It can optionally be made to save the URI of this calendar so
* that it can be loaded in the future when the alarm daemon starts up.
@@ -430,7 +430,7 @@ alarm_notify_add_calendar (AlarmNotify *an, ECalSourceType source_type, ESource
e_uri = e_uri_new (str_uri);
pass_key = e_uri_to_string (e_uri, FALSE);
e_uri_free (e_uri);
-
+
g_mutex_lock (an->priv->mutex);
/* See if we already know about this uri */
if (g_hash_table_lookup (priv->uri_client_hash[source_type], str_uri)) {
@@ -455,11 +455,11 @@ alarm_notify_add_calendar (AlarmNotify *an, ECalSourceType source_type, ESource
return;
}
}
-
+
client = auth_new_cal_from_source (source, source_type);
if (client) {
- d (printf("%s:%d (alarm_notify_add_calendar) %s - Calendar Open Async... %p\n", __FILE__, __LINE__, str_uri, client));
+ d (printf("%s:%d (alarm_notify_add_calendar) %s - Calendar Open Async... %p\n", __FILE__, __LINE__, str_uri, client));
g_hash_table_insert (priv->uri_client_hash[source_type], g_strdup (str_uri), client);
g_signal_connect (G_OBJECT (client), "cal_opened", G_CALLBACK (cal_opened_cb), an);
e_cal_open_async (client, FALSE);
@@ -474,7 +474,7 @@ alarm_notify_remove_calendar (AlarmNotify *an, ECalSourceType source_type, const
{
AlarmNotifyPrivate *priv;
ECal *client;
-
+
priv = an->priv;
client = g_hash_table_lookup (priv->uri_client_hash[source_type], str_uri);
diff --git a/calendar/gui/alarm-notify/alarm-notify.h b/calendar/gui/alarm-notify/alarm-notify.h
index 342dd1dba1..8d11367bca 100644
--- a/calendar/gui/alarm-notify/alarm-notify.h
+++ b/calendar/gui/alarm-notify/alarm-notify.h
@@ -47,7 +47,7 @@ struct _AlarmMsg {
void (*receive_msg)(EThread *e, struct _AlarmMsg *msg, void *data); /* message received */
void *data;
-
+
/* Private Usage */
struct _AlarmMsgPrivate *priv;
};
diff --git a/calendar/gui/alarm-notify/alarm-queue.c b/calendar/gui/alarm-notify/alarm-queue.c
index 5a086266b8..e166791ade 100644
--- a/calendar/gui/alarm-notify/alarm-queue.c
+++ b/calendar/gui/alarm-notify/alarm-queue.c
@@ -173,7 +173,7 @@ static void query_objects_removed_cb (ECal *client, GList *objects, gpointer dat
static void remove_client_alarms (ClientAlarms *ca);
static void update_cqa (CompQueuedAlarms *cqa, ECalComponent *comp);
-static void update_qa (ECalComponentAlarms *alarms, QueuedAlarm *qa);
+static void update_qa (ECalComponentAlarms *alarms, QueuedAlarm *qa);
static void tray_list_remove_cqa (CompQueuedAlarms *cqa);
static void on_dialog_objs_removed_cb (ECal *client, GList *objects, gpointer data);
@@ -199,7 +199,7 @@ queue_midnight_refresh (void)
midnight = time_day_end_with_zone (time (NULL), zone);
d(printf("%s:%d (queue_midnight_refresh) - Refresh at %s \n",__FILE__, __LINE__, ctime(&midnight)));
-
+
midnight_refresh_id = alarm_add (midnight, midnight_refresh_cb, NULL, NULL);
if (!midnight_refresh_id) {
d(printf("%s:%d (queue_midnight_refresh) - Could not setup the midnight refresh alarm\n",__FILE__, __LINE__));
@@ -212,9 +212,9 @@ static void
add_client_alarms_cb (gpointer key, gpointer value, gpointer data)
{
ClientAlarms *ca = (ClientAlarms *)data;
-
+
d(printf("%s:%d (add_client_alarms_cb) - Adding %p\n",__FILE__, __LINE__, ca));
-
+
ca = value;
load_alarms_for_today (ca);
}
@@ -230,13 +230,13 @@ midnight_refresh_async (EThread *e, AlarmMsg *msg, void *data)
struct _midnight_refresh_msg *list = msg->data;
d(printf("%s:%d (midnight_refresh_async) \n",__FILE__, __LINE__));
-
+
/* Re-load the alarms for all clients */
g_hash_table_foreach (client_alarms_hash, add_client_alarms_cb, NULL);
/* Re-schedule the midnight update */
if (list->remove && midnight_refresh_id != NULL) {
- d(printf("%s:%d (midnight_refresh_async) - Reschedule the midnight update \n",__FILE__, __LINE__));
+ d(printf("%s:%d (midnight_refresh_async) - Reschedule the midnight update \n",__FILE__, __LINE__));
alarm_remove (midnight_refresh_id);
midnight_refresh_id = NULL;
}
@@ -249,7 +249,7 @@ midnight_refresh_cb (gpointer alarm_id, time_t trigger, gpointer data)
{
AlarmMsg *msg;
struct _midnight_refresh_msg *list;
-
+
/* These two structures will be freed by the msg destroy function*/
msg = malloc (sizeof (AlarmMsg));
msg->receive_msg = midnight_refresh_async;
@@ -420,7 +420,7 @@ alarm_trigger_cb (gpointer alarm_id, time_t trigger, gpointer data)
#ifdef HAVE_LIBNOTIFY
popup_notification (trigger, cqa, alarm_id, TRUE);
#endif
- display_notification (trigger, cqa, alarm_id, TRUE);
+ display_notification (trigger, cqa, alarm_id, TRUE);
break;
case E_CAL_COMPONENT_ALARM_EMAIL:
@@ -462,13 +462,13 @@ add_component_alarms (ClientAlarms *ca, ECalComponentAlarms *alarms)
cqa->queued_alarms = NULL;
d(printf("%s:%d (add_component_alarms) - Creating CQA %p\n",__FILE__, __LINE__, cqa));
-
+
for (l = alarms->alarms; l; l = l->next) {
ECalComponentAlarmInstance *instance;
gpointer alarm_id;
QueuedAlarm *qa;
time_t tnow = time(NULL);
-
+
instance = l->data;
if (!has_known_notification (cqa->alarms->comp, instance->auid)) {
@@ -517,11 +517,11 @@ load_alarms (ClientAlarms *ca, time_t start, time_t end)
char *str_query, *iso_start, *iso_end;
d(printf("%s:%d (load_alarms) \n",__FILE__, __LINE__));
-
+
iso_start = isodate_from_time_t (start);
if (!iso_start)
return;
-
+
iso_end = isodate_from_time_t (end);
if (!iso_end) {
g_free (iso_start);
@@ -535,7 +535,7 @@ load_alarms (ClientAlarms *ca, time_t start, time_t end)
/* create the live query */
if (ca->query) {
- d(printf("%s:%d (load_alarms) - Disconnecting old queries \n",__FILE__, __LINE__));
+ d(printf("%s:%d (load_alarms) - Disconnecting old queries \n",__FILE__, __LINE__));
g_signal_handlers_disconnect_matched (ca->query, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, ca);
g_object_unref (ca->query);
ca->query = NULL;
@@ -546,7 +546,7 @@ load_alarms (ClientAlarms *ca, time_t start, time_t end)
g_warning (G_STRLOC ": Could not get query for client");
} else {
d(printf("%s:%d (load_alarms) - Setting Call backs \n",__FILE__, __LINE__));
-
+
g_signal_connect (G_OBJECT (ca->query), "objects_added",
G_CALLBACK (query_objects_changed_cb), ca);
g_signal_connect (G_OBJECT (ca->query), "objects_modified",
@@ -579,7 +579,7 @@ load_alarms_for_today (ClientAlarms *ca)
from = MAX (config_data_get_last_notification_time () + 1, day_start);
day_end = time_day_end_with_zone (now, zone);
- d(printf("%s:%d (load_alarms_for_today) - From %s to %s\n",__FILE__, __LINE__, ctime (&from), ctime(&day_end)));
+ d(printf("%s:%d (load_alarms_for_today) - From %s to %s\n",__FILE__, __LINE__, ctime (&from), ctime(&day_end)));
load_alarms (ca, from, day_end);
}
@@ -640,16 +640,16 @@ remove_comp (ClientAlarms *ca, ECalComponentId *id)
g_free (id->rid);
id->rid = NULL;
}
-
+
cqa = lookup_comp_queued_alarms (ca, id);
- if (!cqa)
+ if (!cqa)
return;
/* If a component is present, then it means we must have alarms queued
* for it.
*/
g_return_if_fail (cqa->queued_alarms != NULL);
-
+
d(printf("%s:%d (remove_comp) - Removing CQA %p\n",__FILE__, __LINE__, cqa));
remove_alarms (cqa, TRUE);
}
@@ -663,18 +663,18 @@ struct _query_msg {
gpointer data;
};
-static GList *
+static GList *
duplicate_ical (GList *in_list)
{
GList *l, *out_list = NULL;
for (l = in_list; l; l = l->next) {
out_list = g_list_prepend (out_list, icalcomponent_new_clone (l->data));
}
-
+
return g_list_reverse (out_list);
}
-static GList *
+static GList *
duplicate_ecal (GList *in_list)
{
GList *l, *out_list = NULL;
@@ -686,7 +686,7 @@ duplicate_ecal (GList *in_list)
id->rid = g_strdup (old->rid);
out_list = g_list_prepend (out_list, id);
}
-
+
return g_list_reverse (out_list);
}
@@ -703,11 +703,11 @@ query_objects_changed_async (EThread *e, AlarmMsg *msg, void *data)
struct _query_msg *list = msg->data;
ECal *client;
GList *objects;
-
+
client = list->client;
ca = list->data;
objects = list->objects;
-
+
from = config_data_get_last_notification_time ();
if (from == -1)
from = time (NULL);
@@ -717,9 +717,9 @@ query_objects_changed_async (EThread *e, AlarmMsg *msg, void *data)
zone = config_data_get_timezone ();
day_end = time_day_end_with_zone (time (NULL), zone);
-
+
d(printf("%s:%d (query_objects_changed_async) - Querying for object between %s to %s\n",__FILE__, __LINE__, ctime(&from), ctime(&day_end)));
-
+
for (l = objects; l != NULL; l = l->next) {
ECalComponentId *id;
GSList *sl;
@@ -753,7 +753,7 @@ query_objects_changed_async (EThread *e, AlarmMsg *msg, void *data)
d(printf("%s:%d (query_objects_changed_async) - Alarm Already Exist for %s\n",__FILE__, __LINE__, id->uid));
/* if the alarms or the alarms list is empty remove it after updating the cqa structure */
if (alarms == NULL || alarms->alarms == NULL) {
-
+
/* update the cqa and its queued alarms for changes in summary and alarm_uid */
update_cqa (cqa, comp);
@@ -766,7 +766,7 @@ query_objects_changed_async (EThread *e, AlarmMsg *msg, void *data)
remove_alarms (cqa, FALSE);
cqa->alarms = alarms;
cqa->queued_alarms = NULL;
-
+
/* add the new alarms */
for (sl = cqa->alarms->alarms; sl; sl = sl->next) {
ECalComponentAlarmInstance *instance;
@@ -782,7 +782,7 @@ query_objects_changed_async (EThread *e, AlarmMsg *msg, void *data)
alarm_id = alarm_add (instance->trigger, alarm_trigger_cb, cqa, NULL);
if (!alarm_id) {
- d(printf("%s:%d (query_objects_changed_async) -Unable to schedule trigger for %s \n",__FILE__, __LINE__, ctime(&(instance->trigger))));
+ d(printf("%s:%d (query_objects_changed_async) -Unable to schedule trigger for %s \n",__FILE__, __LINE__, ctime(&(instance->trigger))));
continue;
}
@@ -790,11 +790,11 @@ query_objects_changed_async (EThread *e, AlarmMsg *msg, void *data)
qa->alarm_id = alarm_id;
qa->instance = instance;
qa->snooze = FALSE;
- qa->orig_trigger = instance->trigger;
+ qa->orig_trigger = instance->trigger;
cqa->queued_alarms = g_slist_prepend (cqa->queued_alarms, qa);
d(printf("%s:%d (query_objects_changed_async) - Adding %p to queue \n",__FILE__, __LINE__, qa));
}
-
+
cqa->queued_alarms = g_slist_reverse (cqa->queued_alarms);
g_object_unref (comp);
comp = NULL;
@@ -817,7 +817,7 @@ query_objects_changed_cb (ECal *client, GList *objects, gpointer data)
list->data = data;
msg->data = list;
- d(printf("%s:%d (query_objects_changed_cb) - Posting a task\n",__FILE__, __LINE__));
+ d(printf("%s:%d (query_objects_changed_cb) - Posting a task\n",__FILE__, __LINE__));
e_thread_put(alarm_operation_thread, (EMsg *)msg);
}
@@ -833,18 +833,18 @@ query_objects_removed_async (EThread *e, AlarmMsg *msg, void *data)
struct _query_msg *list = msg->data;
ECal *client;
GList *objects;
-
+
client = list->client;
ca = list->data;
objects = list->objects;
-
+
d(printf("%s:%d (query_objects_removed_async) - Removing %d objects\n",__FILE__, __LINE__, g_list_length(objects)));
-
- for (l = objects; l != NULL; l = l->next) {
+
+ for (l = objects; l != NULL; l = l->next) {
/* If the alarm is already triggered remove it. */
tray_list_remove_cqa (lookup_comp_queued_alarms (ca, l->data));
remove_comp (ca, l->data);
- g_hash_table_remove (ca->uid_alarms_hash, l->data);
+ g_hash_table_remove (ca->uid_alarms_hash, l->data);
e_cal_component_free_id (l->data);
}
@@ -864,10 +864,10 @@ query_objects_removed_cb (ECal *client, GList *objects, gpointer data)
list = malloc (sizeof (struct _query_msg));
list->client = client;
list->objects = duplicate_ecal (objects);
- list->data = data;
+ list->data = data;
msg->data = list;
- d(printf("%s:%d (query_objects_removed_cb) - Posting a task\n",__FILE__, __LINE__));
+ d(printf("%s:%d (query_objects_removed_cb) - Posting a task\n",__FILE__, __LINE__));
e_thread_put(alarm_operation_thread, (EMsg *)msg);
}
@@ -916,7 +916,7 @@ edit_component (ECal *client, ECalComponent *comp)
GNOME_Evolution_Calendar_CompEditorFactory_CompEditorMode corba_type;
d(printf("%s:%d (edit_component) - Client %p\n",__FILE__, __LINE__, client));
-
+
e_cal_component_get_uid (comp, &uid);
uri = e_cal_get_uri (client);
@@ -939,9 +939,9 @@ edit_component (ECal *client, ECalComponent *comp)
corba_type = GNOME_Evolution_Calendar_CompEditorFactory_EDITOR_MODE_TODO;
break;
default:
- corba_type = GNOME_Evolution_Calendar_CompEditorFactory_EDITOR_MODE_EVENT;
+ corba_type = GNOME_Evolution_Calendar_CompEditorFactory_EDITOR_MODE_EVENT;
}
-
+
GNOME_Evolution_Calendar_CompEditorFactory_editExisting (factory, uri, (char *) uid, corba_type, &ev);
if (BONOBO_EX (&ev))
@@ -1001,7 +1001,7 @@ free_tray_icon_data (TrayIconData *tray_data)
g_object_unref (tray_data->comp);
tray_data->comp = NULL;
-
+
tray_data->cqa = NULL;
tray_data->alarm_id = NULL;
tray_data->tray_icon = NULL;
@@ -1021,11 +1021,11 @@ on_dialog_objs_removed_async (EThread *e, AlarmMsg *msg, void *data)
GList *objects;
d(printf("%s:%d (on_dialog_objs_removed_async)\n",__FILE__, __LINE__));
-
+
client = list->client;
tray_data = list->data;
objects = list->objects;
-
+
e_cal_component_get_uid (tray_data->comp, &our_uid);
g_return_if_fail (our_uid && *our_uid);
@@ -1061,7 +1061,7 @@ on_dialog_objs_removed_cb (ECal *client, GList *objects, gpointer data)
msg->data = list;
d(printf("%s:%d (on_dialog_objs_removed_cb) - Posting a task \n",__FILE__, __LINE__));
- e_thread_put(alarm_operation_thread, (EMsg *)msg);
+ e_thread_put(alarm_operation_thread, (EMsg *)msg);
}
struct _tray_cqa_msg {
@@ -1076,12 +1076,12 @@ tray_list_remove_cqa_async(EThread *e, AlarmMsg *msg, void *data)
GList *list = tray_icons_list;
d(printf("%s:%d (tray_list_remove_cqa_async) - Removing CQA %p from tray list\n",__FILE__, __LINE__, cqa));
-
+
while (list) {
TrayIconData *tray_data = list->data;
GList *tmp = list;
GtkTreeModel *model;
-
+
list = list->next;
if (tray_data->cqa == cqa) {
d(printf("%s:%d (tray_list_remove_cqa_async) - Found.\n", __FILE__, __LINE__));
@@ -1093,9 +1093,9 @@ tray_list_remove_cqa_async(EThread *e, AlarmMsg *msg, void *data)
free_tray_icon_data (tray_data);
}
}
-
+
d(printf("%s:%d (tray_list_remove_cqa_async) - %d alarms left.\n", __FILE__, __LINE__, g_list_length (tray_icons_list)));
-
+
if (alarm_notifications_dialog) {
if (!g_list_length (tray_icons_list)) {
gtk_widget_destroy (alarm_notifications_dialog->dialog);
@@ -1140,11 +1140,11 @@ tray_list_remove_async(EThread *e, AlarmMsg *msg, void *data)
while (list != NULL) {
TrayIconData *tray_data = list->data;
-
+
if (!tray_data->snooze_set){
GList *temp = list->next;
gboolean status;
-
+
tray_icons_list = g_list_remove_link (tray_icons_list, list);
status = remove_queued_alarm (tray_data->cqa, tray_data->alarm_id, FALSE, TRUE);
if (status) {
@@ -1157,11 +1157,11 @@ tray_list_remove_async(EThread *e, AlarmMsg *msg, void *data)
g_list_free_1 (list);
if (tray_icons_list != list) /* List head is modified */
list = tray_icons_list;
- else
+ else
list = temp;
} else
list = list->next;
- }
+ }
}
static void
@@ -1190,7 +1190,7 @@ tray_list_remove_data_async(EThread *e, AlarmMsg *msg, void *data)
TrayIconData *tray_data = tmsg->data;
d(printf("%s:%d (tray_list_remove_data_async) - Removing %p from tray list\n",__FILE__, __LINE__, tray_data));
-
+
tray_icons_list = g_list_remove_all (tray_icons_list, tray_data);
free_tray_icon_data (tray_data);
tray_data = NULL;
@@ -1219,23 +1219,23 @@ notify_dialog_cb (AlarmNotifyResult result, int snooze_mins, gpointer data)
TrayIconData *tray_data = data;
d(printf("%s:%d (notify_dialog_cb) - Received from dialog\n",__FILE__, __LINE__));
-
+
g_signal_handlers_disconnect_matched (tray_data->query, G_SIGNAL_MATCH_FUNC,
0, 0, NULL, on_dialog_objs_removed_cb, NULL);
switch (result) {
case ALARM_NOTIFY_SNOOZE:
- d(printf("%s:%d (notify_dialog_cb) - Creating a snooze\n",__FILE__, __LINE__));
+ d(printf("%s:%d (notify_dialog_cb) - Creating a snooze\n",__FILE__, __LINE__));
create_snooze (tray_data->cqa, tray_data->alarm_id, snooze_mins);
tray_data->snooze_set = TRUE;
tray_list_remove_data (tray_data);
if (alarm_notifications_dialog) {
- GtkTreeSelection *selection =
+ GtkTreeSelection *selection =
gtk_tree_view_get_selection (
GTK_TREE_VIEW (alarm_notifications_dialog->treeview));
GtkTreeIter iter;
GtkTreeModel *model = NULL;
-
+
/* We can` also use tray_data->iter */
if (gtk_tree_selection_get_selected (selection, &model, &iter)) {
gtk_list_store_remove (GTK_LIST_STORE (model), &iter);
@@ -1249,9 +1249,9 @@ notify_dialog_cb (AlarmNotifyResult result, int snooze_mins, gpointer data)
gtk_tree_selection_select_iter (selection, &iter);
}
}
-
+
}
-
+
break;
case ALARM_NOTIFY_EDIT:
@@ -1263,20 +1263,20 @@ notify_dialog_cb (AlarmNotifyResult result, int snooze_mins, gpointer data)
d(printf("%s:%d (notify_dialog_cb) - Dialog close\n",__FILE__, __LINE__));
if (alarm_notifications_dialog) {
GtkTreeIter iter;
- GtkTreeModel *model =
+ GtkTreeModel *model =
gtk_tree_view_get_model (
GTK_TREE_VIEW (alarm_notifications_dialog->treeview));
gboolean valid = gtk_tree_model_get_iter_first (model, &iter);
-
- /* Maybe we should warn about this first? */
+
+ /* Maybe we should warn about this first? */
while (valid) {
valid = gtk_list_store_remove (GTK_LIST_STORE (model), &iter);
}
-
+
gtk_widget_destroy (alarm_notifications_dialog->dialog);
g_free (alarm_notifications_dialog);
alarm_notifications_dialog = NULL;
-
+
/* Task to remove the tray icons */
tray_list_remove_icons ();
}
@@ -1309,14 +1309,14 @@ open_alarm_dialog (TrayIconData *tray_data)
if (!alarm_notifications_dialog)
alarm_notifications_dialog = notified_alarms_dialog_new ();
-
+
if (alarm_notifications_dialog) {
GtkTreeSelection *selection = NULL;
-
+
selection = gtk_tree_view_get_selection (
GTK_TREE_VIEW (alarm_notifications_dialog->treeview));
-
+
tray_data->iter = add_alarm_to_notified_alarms_dialog (
alarm_notifications_dialog,
tray_data->trigger,
@@ -1327,11 +1327,11 @@ open_alarm_dialog (TrayIconData *tray_data)
tray_data->description,
tray_data->location,
notify_dialog_cb, tray_data);
-
+
gtk_tree_selection_select_iter (selection, &tray_data->iter);
}
-
+
}
return TRUE;
@@ -1341,25 +1341,25 @@ static gint
tray_icon_clicked_cb (GtkWidget *widget, GdkEventButton *event, gpointer user_data)
{
if (event->type == GDK_BUTTON_PRESS) {
- d(printf("%s:%d (tray_icon_clicked_cb) - left click and %d alarms\n",__FILE__, __LINE__, g_list_length (tray_icons_list)));
+ d(printf("%s:%d (tray_icon_clicked_cb) - left click and %d alarms\n",__FILE__, __LINE__, g_list_length (tray_icons_list)));
if (event->button == 1 && g_list_length (tray_icons_list) > 0) {
GList *tmp;
for (tmp = tray_icons_list; tmp; tmp = tmp->next) {
open_alarm_dialog (tmp->data);
}
-
+
return TRUE;
} else if (event->button == 3) {
- d(printf("%s:%d (tray_icon_clicked_cb) - right click\n",__FILE__, __LINE__));
+ d(printf("%s:%d (tray_icon_clicked_cb) - right click\n",__FILE__, __LINE__));
if (tray_blink_id > -1)
g_source_remove (tray_blink_id);
tray_blink_id = -1;
-
-
+
+
gtk_status_icon_set_visible (tray_icon, FALSE);
g_object_unref (tray_icon);
- tray_icon = NULL;
+ tray_icon = NULL;
return TRUE;
}
}
@@ -1400,7 +1400,7 @@ tray_icon_blink_cb (gpointer data)
GdkPixbuf *pixbuf;
tray_blink_state = tray_blink_state == TRUE ? FALSE: TRUE;
-
+
pixbuf = e_icon_factory_get_icon (tray_blink_state == TRUE?
"stock_appointment-reminder-excl" :
"stock_appointment-reminder",
@@ -1420,7 +1420,7 @@ static void
tray_list_add_async (EThread *e, AlarmMsg *msg, void *data)
{
struct _tray_msg *list = msg->data;
- d(printf("%s:%d (tray_list_add_async) - Add %p\n",__FILE__, __LINE__, list->data));
+ d(printf("%s:%d (tray_list_add_async) - Add %p\n",__FILE__, __LINE__, list->data));
tray_icons_list = g_list_prepend (tray_icons_list, list->data);
}
@@ -1437,8 +1437,8 @@ tray_list_add_new (TrayIconData *data)
list = malloc (sizeof (struct _tray_msg));
list->data = data;
msg->data = list;
-
- d(printf("%s:%d (tray_list_add_new) - Posting a task\n",__FILE__, __LINE__));
+
+ d(printf("%s:%d (tray_list_add_new) - Posting a task\n",__FILE__, __LINE__));
e_thread_put(alarm_operation_thread, (EMsg *)msg);
}
@@ -1458,15 +1458,15 @@ display_notification (time_t trigger, CompQueuedAlarms *cqa,
ECalComponentOrganizer organiser;
d(printf("%s:%d (display_notification)\n",__FILE__, __LINE__));
-
+
comp = cqa->alarms->comp;
qa = lookup_queued_alarm (cqa, alarm_id);
if (!qa)
return;
-
+
/* get a sensible description for the event */
e_cal_component_get_summary (comp, &text);
- e_cal_component_get_organizer (comp, &organiser);
+ e_cal_component_get_organizer (comp, &organiser);
if (text.value)
summary = text.value;
@@ -1502,7 +1502,7 @@ display_notification (time_t trigger, CompQueuedAlarms *cqa,
G_CALLBACK (popup_menu), NULL);
}
-
+
current_zone = config_data_get_timezone ();
alarm_str = timet_to_str_with_zone (trigger, current_zone);
start_str = timet_to_str_with_zone (qa->instance->occur_start, current_zone);
@@ -1578,17 +1578,17 @@ popup_notification (time_t trigger, CompQueuedAlarms *cqa,
char *body;
d(printf("%s:%d (popup_notification)\n",__FILE__, __LINE__));
-
+
comp = cqa->alarms->comp;
qa = lookup_queued_alarm (cqa, alarm_id);
if (!qa)
return;
if (!notify_is_initted ())
notify_init("Evolution Alarm Notify");
-
+
/* get a sensible description for the event */
e_cal_component_get_summary (comp, &text);
- e_cal_component_get_organizer (comp, &organiser);
+ e_cal_component_get_organizer (comp, &organiser);
if (text.value)
@@ -1620,12 +1620,12 @@ popup_notification (time_t trigger, CompQueuedAlarms *cqa,
if (location)
body = g_strdup_printf ("%s %s\n%s %s", _("Location:"), location, start_str, time_str);
else
- body = g_strdup_printf ("%s %s", start_str, time_str);
+ body = g_strdup_printf ("%s %s", start_str, time_str);
}
n = notify_notification_new (summary, body, "stock_appointment-reminder", NULL);
if (!notify_notification_show(n, NULL))
- g_warning ("Could not send notification to daemon\n");
+ g_warning ("Could not send notification to daemon\n");
/* create the private structure */
g_free (start_str);
@@ -1650,7 +1650,7 @@ audio_notification (time_t trigger, CompQueuedAlarms *cqa,
int flag = 0;
d(printf("%s:%d (audio_notification)\n",__FILE__, __LINE__));
-
+
comp = cqa->alarms->comp;
qa = lookup_queued_alarm (cqa, alarm_id);
if (!qa)
@@ -1691,7 +1691,7 @@ mail_notification (time_t trigger, CompQueuedAlarms *cqa, gpointer alarm_id)
/* FIXME */
d(printf("%s:%d (mail_notification)\n",__FILE__, __LINE__));
-
+
if (!e_cal_get_static_capability (cqa->parent_client->client,
CAL_STATIC_CAPABILITY_NO_EMAIL_ALARMS))
return;
@@ -1713,17 +1713,17 @@ mail_notification (time_t trigger, CompQueuedAlarms *cqa, gpointer alarm_id)
/* Performs notification of a procedure alarm */
static gboolean
-procedure_notification_dialog (const char *cmd, const char *url)
+procedure_notification_dialog (const char *cmd, const char *url)
{
GtkWidget *dialog, *label, *checkbox;
char *str;
int btn;
d(printf("%s:%d (procedure_notification_dialog)\n",__FILE__, __LINE__));
-
+
if (config_data_is_blessed_program (url))
return TRUE;
-
+
dialog = gtk_dialog_new_with_buttons (_("Warning"),
NULL, 0,
GTK_STOCK_NO, GTK_RESPONSE_CANCEL,
@@ -1746,7 +1746,7 @@ procedure_notification_dialog (const char *cmd, const char *url)
checkbox = gtk_check_button_new_with_label
(_("Do not ask me about this program again."));
gtk_widget_show (checkbox);
- gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox),
+ gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox),
checkbox, TRUE, TRUE, 4);
/* Run the dialog */
@@ -1771,7 +1771,7 @@ procedure_notification (time_t trigger, CompQueuedAlarms *cqa, gpointer alarm_id
int result;
d(printf("%s:%d (procedure_notification)\n",__FILE__, __LINE__));
-
+
comp = cqa->alarms->comp;
qa = lookup_queued_alarm (cqa, alarm_id);
if (!qa)
@@ -1805,7 +1805,7 @@ procedure_notification (time_t trigger, CompQueuedAlarms *cqa, gpointer alarm_id
result = 0;
if (procedure_notification_dialog (cmd, url))
result = gnome_execute_shell (NULL, cmd);
-
+
if (cmd != (char *) url)
g_free (cmd);
@@ -1831,14 +1831,14 @@ check_midnight_refresh (gpointer user_data)
icaltimezone *zone;
d(printf("%s:%d (check_midnight_refresh)\n",__FILE__, __LINE__));
-
+
zone = config_data_get_timezone ();
new_midnight = time_day_end_with_zone (time (NULL), zone);
if (new_midnight > midnight) {
AlarmMsg *msg;
struct _midnight_refresh_msg *list;
-
+
/* These two structures will be freed by the msg destroy function*/
msg = malloc (sizeof (AlarmMsg));
msg->receive_msg = midnight_refresh_async;
@@ -1850,7 +1850,7 @@ check_midnight_refresh (gpointer user_data)
msg->data = list;
d(printf("%s:%d (check_midnight_refresh) - Posting a task to refresh\n",__FILE__, __LINE__));
- e_thread_put(alarm_operation_thread, (EMsg *)msg);
+ e_thread_put(alarm_operation_thread, (EMsg *)msg);
}
return TRUE;
@@ -1869,7 +1869,7 @@ alarm_queue_init (gpointer data)
g_return_if_fail (alarm_queue_inited == FALSE);
d(printf("%s:%d (alarm_queue_init)\n",__FILE__, __LINE__));
-
+
client_alarms_hash = g_hash_table_new (g_direct_hash, g_direct_equal);
queue_midnight_refresh ();
@@ -1896,12 +1896,12 @@ free_client_alarms_cb (gpointer key, gpointer value, gpointer user_data)
ClientAlarms *ca = value;
d(printf("%s:%d (free_client_alarms_cb) - %p\n",__FILE__, __LINE__, ca));
-
+
if (ca) {
remove_client_alarms (ca);
if (ca->client) {
d(printf("%s:%d (free_client_alarms_cb) - Disconnecting Client \n",__FILE__, __LINE__));
-
+
g_signal_handlers_disconnect_matched (ca->client, G_SIGNAL_MATCH_DATA,
0, 0, NULL, NULL, ca);
g_object_unref (ca->client);
@@ -1909,7 +1909,7 @@ free_client_alarms_cb (gpointer key, gpointer value, gpointer user_data)
if (ca->query) {
d(printf("%s:%d (free_client_alarms_cb) - Disconnecting Query \n",__FILE__, __LINE__));
-
+
g_signal_handlers_disconnect_matched (ca->query, G_SIGNAL_MATCH_DATA,
0, 0, NULL, NULL, ca);
g_object_unref (ca->query);
@@ -1940,7 +1940,7 @@ alarm_queue_done (void)
g_return_if_fail (g_hash_table_size (client_alarms_hash) == 0);
d(printf("%s:%d (alarm_queue_done)\n",__FILE__, __LINE__));
-
+
g_hash_table_foreach_remove (client_alarms_hash, (GHRFunc) free_client_alarms_cb, NULL);
g_hash_table_destroy (client_alarms_hash);
client_alarms_hash = NULL;
@@ -1953,7 +1953,7 @@ alarm_queue_done (void)
alarm_queue_inited = FALSE;
}
-static gboolean
+static gboolean
compare_ids (gpointer a, gpointer b)
{
ECalComponentId *id, *id1;
@@ -1967,12 +1967,12 @@ compare_ids (gpointer a, gpointer b)
return g_str_equal (id->rid, id1->rid);
else if (!(id->rid && id1->rid))
return TRUE;
- }
+ }
}
return FALSE;
}
-static guint
+static guint
hash_ids (gpointer a)
{
ECalComponentId *id =a;
@@ -2002,7 +2002,7 @@ static void alarm_queue_add_async (EThread *e, AlarmMsg *msg, void *data)
}
d(printf("%s:%d (alarm_queue_add_async) - %p\n",__FILE__, __LINE__, client));
-
+
ca = g_new (ClientAlarms, 1);
ca->client = client;
@@ -2018,7 +2018,7 @@ static void alarm_queue_add_async (EThread *e, AlarmMsg *msg, void *data)
g_signal_connect (client, "cal_opened",
G_CALLBACK (cal_opened_cb),
ca);
- }
+ }
}
/**
@@ -2072,12 +2072,12 @@ static gboolean
remove_comp_by_id (gpointer key, gpointer value, gpointer userdata) {
ClientAlarms *ca = (ClientAlarms *)userdata;
-
+
d(printf("%s:%d (remove_comp_by_id)\n",__FILE__, __LINE__));
-
+
/* if (!g_hash_table_size (ca->uid_alarms_hash)) */
/* return; */
-
+
remove_cqa (ca, (ECalComponentId *)key, (CompQueuedAlarms *) value);
return TRUE;
@@ -2088,10 +2088,10 @@ remove_comp_by_id (gpointer key, gpointer value, gpointer userdata) {
static void
remove_client_alarms (ClientAlarms *ca)
{
- d(printf("%s:%d (remove_client_alarms) - size %d \n",__FILE__, __LINE__, g_hash_table_size (ca->uid_alarms_hash)));
+ d(printf("%s:%d (remove_client_alarms) - size %d \n",__FILE__, __LINE__, g_hash_table_size (ca->uid_alarms_hash)));
g_hash_table_foreach_remove (ca->uid_alarms_hash, (GHRFunc)remove_comp_by_id, ca);
-
+
/* The hash table should be empty now */
g_return_if_fail (g_hash_table_size (ca->uid_alarms_hash) == 0);
}
@@ -2122,7 +2122,7 @@ alarm_queue_remove_async (EThread *e, AlarmMsg *msg, void *data)
/* Clean up */
if (ca->client) {
d(printf("%s:%d (alarm_queue_remove_async) - Disconnecting Client \n",__FILE__, __LINE__));
-
+
g_signal_handlers_disconnect_matched (ca->client, G_SIGNAL_MATCH_DATA,
0, 0, NULL, NULL, ca);
g_object_unref (ca->client);
@@ -2131,7 +2131,7 @@ alarm_queue_remove_async (EThread *e, AlarmMsg *msg, void *data)
if (ca->query) {
d(printf("%s:%d (alarm_queue_remove_async) - Disconnecting Query \n",__FILE__, __LINE__));
-
+
g_signal_handlers_disconnect_matched (ca->query, G_SIGNAL_MATCH_DATA,
0, 0, NULL, NULL, ca);
g_object_unref (ca->query);
@@ -2176,9 +2176,9 @@ alarm_queue_remove_client (ECal *client, gboolean immediately)
e_thread_put(alarm_operation_thread, (EMsg *)msg);
}
-/* Update non-time related variables for various structures on modification of an existing component
+/* Update non-time related variables for various structures on modification of an existing component
to be called only from query_objects_changed_cb */
-static void
+static void
update_cqa (CompQueuedAlarms *cqa, ECalComponent *newcomp)
{
ECalComponent *oldcomp;
@@ -2195,7 +2195,7 @@ update_cqa (CompQueuedAlarms *cqa, ECalComponent *newcomp)
to = time_day_end_with_zone (time (NULL), zone);
d(printf("%s:%d (update_cqa) - Generating alarms between %s and %s\n",__FILE__, __LINE__, ctime(&from), ctime(&to)));
- alarms = e_cal_util_generate_alarms_for_comp (newcomp, from, to, omit,
+ alarms = e_cal_util_generate_alarms_for_comp (newcomp, from, to, omit,
e_cal_resolve_tzid_cb, cqa->parent_client->client, zone);
/* Update auids in Queued Alarms*/
@@ -2208,14 +2208,14 @@ update_cqa (CompQueuedAlarms *cqa, ECalComponent *newcomp)
else {
if (e_cal_component_get_alarm (oldcomp, check_auid)) { /* Need to update QueuedAlarms */
if (alarms == NULL) {
- d(printf("%s:%d (update_cqa) - No alarms found in the modified component\n",__FILE__, __LINE__));
+ d(printf("%s:%d (update_cqa) - No alarms found in the modified component\n",__FILE__, __LINE__));
break;
}
update_qa (alarms, qa);
}
else
g_warning ("Failed in auid lookup for old component also\n");
- }
+ }
}
/* Update the actual component stored in CompQueuedAlarms structure */
@@ -2240,4 +2240,4 @@ update_qa (ECalComponentAlarms *alarms, QueuedAlarm *qa)
break;
}
}
-}
+}
diff --git a/calendar/gui/alarm-notify/alarm.c b/calendar/gui/alarm-notify/alarm.c
index 38e0638ec8..5239812c99 100644
--- a/calendar/gui/alarm-notify/alarm.c
+++ b/calendar/gui/alarm-notify/alarm.c
@@ -145,13 +145,13 @@ setup_timeout (void)
* current time we timeout immediately */
diff = MAX (0, ar->trigger - time (NULL));
now = time (NULL);
-
+
/* Add the time out */
g_message ("Setting timeout for %d %lu %lu", diff, ar->trigger, now);
g_message (" %s", ctime (&ar->trigger));
g_message (" %s", ctime (&now));
timeout_id = g_timeout_add (diff * 1000, alarm_ready_cb, NULL);
-
+
}
/* Used from g_list_insert_sorted(); compares the trigger times of two AlarmRecord structures. */
@@ -175,7 +175,7 @@ queue_alarm (AlarmRecord *ar)
/* Track the current head of the list in case there are changes */
old_head = alarms;
- /* Insert the new alarm in order if the alarm's trigger time is
+ /* Insert the new alarm in order if the alarm's trigger time is
after the current time */
alarms = g_list_insert_sorted (alarms, ar, compare_alarm_by_time);
@@ -226,7 +226,7 @@ alarm_add (time_t trigger, AlarmFunction alarm_fn, gpointer data,
/**
* alarm_remove:
* @alarm: A queued alarm identifier.
- *
+ *
* Removes an alarm from the alarm queue.
**/
void
@@ -274,7 +274,7 @@ alarm_remove (gpointer alarm)
/**
* alarm_done:
- *
+ *
* Terminates the alarm timer mechanism. This should be called at the end of
* the program.
**/
diff --git a/calendar/gui/alarm-notify/config-data.c b/calendar/gui/alarm-notify/config-data.c
index c35d2b4a6c..e7120d4b38 100644
--- a/calendar/gui/alarm-notify/config-data.c
+++ b/calendar/gui/alarm-notify/config-data.c
@@ -101,10 +101,10 @@ config_data_get_calendars (const char *key)
ESourceList *cal_sources;
gboolean state;
GSList *gconf_list;
-
+
if (!inited)
conf_client = gconf_client_get_default ();
-
+
gconf_list = gconf_client_get_list (conf_client,
key,
GCONF_VALUE_STRING,
@@ -117,12 +117,12 @@ config_data_get_calendars (const char *key)
return cal_sources;
}
- state = gconf_client_get_bool (conf_client,
+ state = gconf_client_get_bool (conf_client,
"/apps/evolution/calendar/notify/notify_with_tray",
NULL);
if (!state) /* Should be old client*/ {
GSList *source;
- gconf_client_set_bool (conf_client,
+ gconf_client_set_bool (conf_client,
"/apps/evolution/calendar/notify/notify_with_tray",
TRUE,
NULL);
@@ -149,11 +149,11 @@ config_data_get_calendars (const char *key)
}
return cal_sources;
-
+
}
void
-config_data_replace_string_list (const char *key,
+config_data_replace_string_list (const char *key,
const char *old,
const char *new)
{
@@ -166,9 +166,9 @@ config_data_replace_string_list (const char *key,
key,
GCONF_VALUE_STRING,
NULL);
-
+
for (tmp = source; tmp; tmp = tmp->next) {
-
+
if (strcmp (tmp->data, old) == 0) {
gboolean state;
@@ -205,7 +205,7 @@ config_data_get_timezone (void)
ensure_inited ();
- location = gconf_client_get_string (conf_client,
+ location = gconf_client_get_string (conf_client,
"/apps/evolution/calendar/display/timezone",
NULL);
if (location && location[0]) {
@@ -246,7 +246,7 @@ config_data_get_notify_with_tray (void)
/**
* config_data_set_last_notification_time:
* @t: A time value.
- *
+ *
* Saves the last notification time so that it can be fetched the next time the
* alarm daemon is run. This way the daemon can show alarms that should have
* triggered while it was not running.
@@ -271,9 +271,9 @@ config_data_set_last_notification_time (time_t t)
/**
* config_data_get_last_notification_time:
- *
+ *
* Queries the last saved value for alarm notification times.
- *
+ *
* Return value: The last saved value, or -1 if no value had been saved before.
**/
time_t
@@ -295,7 +295,7 @@ config_data_get_last_notification_time (void)
/**
* config_data_save_blessed_program:
* @program: a program name
- *
+ *
* Saves a program name as "blessed"
**/
void
@@ -317,9 +317,9 @@ config_data_save_blessed_program (const char *program)
/**
* config_data_is_blessed_program:
* @program: a program name
- *
+ *
* Checks to see if a program is blessed
- *
+ *
* Return value: TRUE if program is blessed, FALSE otherwise
**/
gboolean
diff --git a/calendar/gui/alarm-notify/notify-main.c b/calendar/gui/alarm-notify/notify-main.c
index 3a87002c65..83c2421d38 100644
--- a/calendar/gui/alarm-notify/notify-main.c
+++ b/calendar/gui/alarm-notify/notify-main.c
@@ -78,7 +78,7 @@ save_session_cb (GnomeClient *client, GnomeSaveStyle save_style, gint shutdown,
args[1] = NULL;
gnome_client_set_restart_command (client, 1, args);
g_free (args[0]);
-
+
return TRUE;
}
@@ -157,7 +157,7 @@ main (int argc, char **argv)
init_session ();
/* FIXME Ideally we should not use camel libraries in calendar, though it is the case
- currently for attachments. Remove this once that is fixed.
+ currently for attachments. Remove this once that is fixed.
Initialise global camel_object_type */
camel_object_get_type();
diff --git a/calendar/gui/cal-search-bar.c b/calendar/gui/cal-search-bar.c
index 7c498b79ef..d82d0e7ce6 100644
--- a/calendar/gui/cal-search-bar.c
+++ b/calendar/gui/cal-search-bar.c
@@ -65,7 +65,7 @@ enum {
SEARCH_COMMENT_CONTAINS,
SEARCH_LOCATION_CONTAINS,
SEARCH_ATTENDEE_CONTAINS
-
+
};
/* Comments are disabled because they are kind of useless right now, see bug 33247 */
@@ -164,7 +164,7 @@ cal_search_bar_class_init (CalSearchBarClass *klass)
klass->sexp_changed = NULL;
klass->category_changed = NULL;
- search_bar_class->search_activated = cal_search_bar_search_activated;
+ search_bar_class->search_activated = cal_search_bar_search_activated;
object_class->destroy = cal_search_bar_destroy;
}
@@ -217,13 +217,13 @@ cal_search_bar_destroy (GtkObject *object)
free_categories (priv->categories);
priv->categories = NULL;
}
-
+
if (priv->search_rule) {
g_object_unref (priv->search_rule);
priv->search_rule = NULL;
}
-
- /* FIXME
+
+ /* FIXME
if (priv->search_context) {
g_object_unref (priv->search_context);
priv->search_context = NULL;
@@ -232,7 +232,7 @@ cal_search_bar_destroy (GtkObject *object)
g_free (priv);
cal_search->priv = NULL;
}
-
+
if (GTK_OBJECT_CLASS (cal_search_bar_parent_class)->destroy)
(* GTK_OBJECT_CLASS (cal_search_bar_parent_class)->destroy) (object);
}
@@ -266,11 +266,11 @@ get_current_category (CalSearchBar *cal_search)
if (priv->view_flag == CAL_SEARCH_TASKS_DEFAULT)
i = viewid - CATEGORIES_TASKS_OFFSET;
- else if (priv->view_flag == CAL_SEARCH_MEMOS_DEFAULT)
+ else if (priv->view_flag == CAL_SEARCH_MEMOS_DEFAULT)
i = viewid - CATEGORIES_MEMOS_OFFSET;
else if (priv->view_flag == CAL_SEARCH_CALENDAR_DEFAULT)
i = viewid - CATEGORIES_CALENDAR_OFFSET;
-
+
if (i >= 0 && i < priv->categories->len)
return priv->categories->pdata[i];
else
@@ -296,7 +296,7 @@ get_show_option_sexp (CalSearchBar *cal_search)
if (viewid == CATEGORIES_UNMATCHED)
return g_strdup ("(has-categories? #f)"); /* Unfiled items */
- else if (viewid == CATEGORIES_ALL)
+ else if (viewid == CATEGORIES_ALL)
return NULL; /* All items */
switch (priv->view_flag) {
@@ -345,9 +345,9 @@ get_show_option_sexp (CalSearchBar *cal_search)
g_free (due);
return ret;
- } else if (viewid == COMPLETED_TASK)
+ } else if (viewid == COMPLETED_TASK)
return g_strdup ("(is-completed?)");
- else if (viewid == TASK_WITH_ATTACHMENT)
+ else if (viewid == TASK_WITH_ATTACHMENT)
return g_strdup ("(has-attachments?)");
break;
case CAL_SEARCH_CALENDAR_DEFAULT:
@@ -369,7 +369,7 @@ get_show_option_sexp (CalSearchBar *cal_search)
g_free (end);
return ret;
- } else if (viewid == N_DAY_APPOINTMENT) {
+ } else if (viewid == N_DAY_APPOINTMENT) {
start_range = time (NULL);
end_range = time_add_day (start_range, 7);
start = isodate_from_time_t (start_range);
@@ -415,17 +415,17 @@ notify_e_cal_view_contains (CalSearchBar *cal_search, const char *field, const c
if (text && *text) {
sexp = g_strdup_printf ("(contains? \"%s\" \"%s\")", field, text);
g_free (text);
- } else
+ } else
sexp = g_strdup ("(contains? \"summary\" \"\")"); /* Show all */
/* Apply the selected view on search */
- if (view && *view){
+ if (view && *view){
sexp = g_strconcat ("(and ",sexp, view, ")", NULL);
}
-
+
notify_sexp_changed (cal_search, sexp);
-
+
g_free (sexp);
}
@@ -463,7 +463,7 @@ regen_query (CalSearchBar *cal_search)
cal_search->priv->start = -1;
cal_search->priv->end = -1;
-
+
/* Get the selected view */
show_option_sexp = get_show_option_sexp (cal_search);
@@ -495,11 +495,11 @@ regen_query (CalSearchBar *cal_search)
out = g_string_new ("");
filter_rule_build_code (efb->current_query, out);
- if (show_option_sexp && *show_option_sexp)
+ if (show_option_sexp && *show_option_sexp)
sexp = g_strconcat ("(and ", out->str, show_option_sexp, ")", NULL);
-
+
notify_sexp_changed (cal_search, sexp ? sexp : out->str);
-
+
g_string_free (out, TRUE);
g_free(sexp);
break;
@@ -590,7 +590,7 @@ setup_category_options (CalSearchBar *cal_search, CALSearchBarItem *subitems, gi
}
index = i + offset;
}
-
+
subitems[index].search.id = -1; /* terminator */
subitems[index].search.text = NULL;
subitems[index].image = NULL;
@@ -604,7 +604,7 @@ make_suboptions (CalSearchBar *cal_search)
CalSearchBarPrivate *priv;
CALSearchBarItem *subitems = NULL;
GtkWidget *menu;
-
+
priv = cal_search->priv;
g_return_if_fail (priv->categories != NULL);
@@ -624,7 +624,7 @@ make_suboptions (CalSearchBar *cal_search)
subitems[1].search.id = CATEGORIES_UNMATCHED;
subitems[1].image = NULL;
- subitems[2].search.text = NULL;
+ subitems[2].search.text = NULL;
subitems[2].search.id = 0;
subitems[2].image = NULL;
@@ -650,7 +650,7 @@ make_suboptions (CalSearchBar *cal_search)
/* All the other items */
setup_category_options (cal_search, subitems, 8, CATEGORIES_TASKS_OFFSET);
-
+
menu = generate_viewoption_menu (subitems);
e_search_bar_set_viewoption_menu ((ESearchBar *)cal_search, menu);
@@ -686,15 +686,15 @@ make_suboptions (CalSearchBar *cal_search)
subitems[1].search.id = CATEGORIES_UNMATCHED;
subitems[1].image = NULL;
- subitems[2].search.text = NULL;
+ subitems[2].search.text = NULL;
subitems[2].search.id = 0;
subitems[2].image = NULL;
- subitems[3].search.text = _("Active Appointments");
+ subitems[3].search.text = _("Active Appointments");
subitems[3].search.id = ACTIVE_APPONTMENT;
subitems[3].image = NULL;
- subitems[4].search.text = _("Next 7 Days' Appointments");
+ subitems[4].search.text = _("Next 7 Days' Appointments");
subitems[4].search.id = N_DAY_APPOINTMENT;
subitems[4].image = NULL;
@@ -705,7 +705,7 @@ make_suboptions (CalSearchBar *cal_search)
e_search_bar_set_viewoption_menu ((ESearchBar *)cal_search, menu);
}
- if(subitems != NULL)
+ if(subitems != NULL)
g_free (subitems);
}
@@ -720,9 +720,9 @@ search_menu_activated (ESearchBar *esb, int id)
* cal_search_bar_construct:
* @cal_search: A calendar search bar.
* @flags: bitfield of items to appear in the search menu
- *
+ *
* Constructs a calendar search bar by binding its menu and option items.
- *
+ *
* Return value: The same value as @cal_search.
**/
CalSearchBar *
@@ -733,12 +733,12 @@ cal_search_bar_construct (CalSearchBar *cal_search, guint32 flags)
int i, j;
char *xmlfile = NULL;
char *userfile = NULL;
- FilterPart *part;
+ FilterPart *part;
RuleContext *search_context;
FilterRule *search_rule;
-
+
g_return_val_if_fail (IS_CAL_SEARCH_BAR (cal_search), NULL);
-
+
items = g_alloca ((G_N_ELEMENTS (search_option_items) + 1) * sizeof (ESearchBarItem));
for (i = 0, j = 0; i < G_N_ELEMENTS (search_option_items); i++, bit <<= 1) {
if ((flags & bit) != 0) {
@@ -748,7 +748,7 @@ cal_search_bar_construct (CalSearchBar *cal_search, guint32 flags)
j++;
}
}
-
+
items[j].text = NULL;
items[j].id = -1;
search_context = rule_context_new ();
@@ -773,16 +773,16 @@ cal_search_bar_construct (CalSearchBar *cal_search, guint32 flags)
g_object_set_data_full (G_OBJECT (search_context), "user", userfile, g_free);
g_object_set_data_full (G_OBJECT (search_context), "system", xmlfile, g_free);
- rule_context_load (search_context, xmlfile, userfile);
+ rule_context_load (search_context, xmlfile, userfile);
search_rule = filter_rule_new ();
part = rule_context_next_part (search_context, NULL);
-
+
if (part == NULL)
g_warning ("Could not load calendar search; no parts.");
- else
+ else
filter_rule_add_part (search_rule, filter_part_clone (part));
- e_filter_bar_new_construct (search_context, xmlfile, userfile, NULL, cal_search,
+ e_filter_bar_new_construct (search_context, xmlfile, userfile, NULL, cal_search,
(EFilterBar*) cal_search );
e_search_bar_set_menu ((ESearchBar *) cal_search, calendar_search_items);
@@ -795,16 +795,16 @@ cal_search_bar_construct (CalSearchBar *cal_search, guint32 flags)
g_free (xmlfile);
g_free (userfile);
-
+
return cal_search;
}
/**
* cal_search_bar_new:
* flags: bitfield of items to appear in the search menu
- *
+ *
* creates a new calendar search bar.
- *
+ *
* return value: a newly-created calendar search bar. you should connect to the
* "sexp_changed" signal to monitor changes in the generated sexps.
**/
@@ -854,7 +854,7 @@ sort_categories (GPtrArray *categories)
* cal_search_bar_set_categories:
* @cal_search: A calendar search bar.
* @categories: Array of pointers to strings for the category names.
- *
+ *
* Sets the list of categories that are to be shown in the drop-down list
* of a calendar search bar. The search bar will automatically add an item
* for "unfiled" components, that is, those that have no categories assigned
@@ -880,10 +880,10 @@ cal_search_bar_set_categories (CalSearchBar *cal_search, GPtrArray *categories)
/**
* cal_search_bar_get_category:
* @cal_search: A calendar search bar.
- *
+ *
* Queries the currently selected category name in a calendar search bar.
* If "All" or "Unfiled" are selected, this function will return NULL.
- *
+ *
* Return value: Name of the selected category, or NULL if there is no
* selected category.
**/
@@ -897,13 +897,13 @@ cal_search_bar_get_category (CalSearchBar *cal_search)
return category;
}
-void
+void
cal_search_bar_get_time_range (CalSearchBar *cal_search, time_t *start, time_t *end)
{
CalSearchBarPrivate *priv;
g_return_if_fail (IS_CAL_SEARCH_BAR (cal_search));
-
+
priv = cal_search->priv;
*start = priv->start;
diff --git a/calendar/gui/calendar-commands.c b/calendar/gui/calendar-commands.c
index 7c6576bf2a..b4d46d358e 100644
--- a/calendar/gui/calendar-commands.c
+++ b/calendar/gui/calendar-commands.c
@@ -409,7 +409,7 @@ calendar_control_sensitize_calendar_commands (BonoboControl *control, GnomeCalen
if (bonobo_ui_component_get_container (uic) == CORBA_OBJECT_NIL)
return;
-
+
view = gnome_calendar_get_current_view_widget (gcal);
menu = gnome_calendar_get_calendar_menu (gcal);
diff --git a/calendar/gui/calendar-component.c b/calendar/gui/calendar-component.c
index 6168988aad..607e199f81 100644
--- a/calendar/gui/calendar-component.c
+++ b/calendar/gui/calendar-component.c
@@ -82,16 +82,16 @@ static gint num_drag_types = sizeof(drag_types) / sizeof(drag_types[0]);
#define PARENT_TYPE bonobo_object_get_type ()
static BonoboObjectClass *parent_class = NULL;
-typedef struct
+typedef struct
{
ESourceList *source_list;
ESourceList *task_source_list;
ESourceList *memo_source_list;
-
+
GSList *source_selection;
GSList *task_source_selection;
GSList *memo_source_selection;
-
+
GnomeCalendar *calendar;
EInfoLabel *info_label;
@@ -106,7 +106,7 @@ typedef struct
EUserCreatableItemsHandler *creatable_items_handler;
EActivityHandler *activity_handler;
-
+
float vpane_pos;
} CalendarComponentView;
@@ -135,7 +135,7 @@ static void
calcomp_vpane_realized (GtkWidget *vpane, CalendarComponentView *view)
{
gtk_paned_set_position (GTK_PANED (vpane), (int)(view->vpane_pos*vpane->allocation.height));
-
+
}
static gboolean
@@ -190,7 +190,7 @@ ensure_sources (CalendarComponent *component)
group = E_SOURCE_GROUP (g->data);
- /* compare only file:// part. If user home dir name changes we do not want to create
+ /* compare only file:// part. If user home dir name changes we do not want to create
one more group */
if (!on_this_computer && !strncmp (base_uri_proto, e_source_group_peek_base_uri (group), 7))
@@ -225,11 +225,11 @@ ensure_sources (CalendarComponent *component)
homedir name changes */
if (strcmp (base_uri_proto, e_source_group_peek_base_uri (on_this_computer))) {
e_source_group_set_base_uri (on_this_computer, base_uri_proto);
-
+
/* *sigh* . We shouldn't need this sync call here as set_base_uri
call results in synching to gconf, but that happens in idle loop
and too late to prevent user seeing "Can not Open ... because of invalid uri" error.*/
- e_source_list_sync (source_list,NULL);
+ e_source_list_sync (source_list,NULL);
}
}
else {
@@ -247,7 +247,7 @@ ensure_sources (CalendarComponent *component)
/* Create the default Person addressbook */
personal_source = e_source_new (_("Personal"), PERSONAL_RELATIVE_URI);
e_source_group_add_source (on_this_computer, personal_source, -1);
-
+
calendars_selected = calendar_config_get_calendars_selected ();
if (!primary_calendar && !calendars_selected) {
GSList selected;
@@ -277,7 +277,7 @@ ensure_sources (CalendarComponent *component)
}
if (contacts) {
GSList *sources = e_source_group_peek_sources (contacts);
- if (sources)
+ if (sources)
birthdays_source = E_SOURCE (sources->data); /* There is only one source under Contacts Group*/
}
else {
@@ -299,7 +299,7 @@ ensure_sources (CalendarComponent *component)
if (!e_source_get_property (birthdays_source, "delete"))
e_source_set_property(birthdays_source, "delete", "no");
-
+
if (e_source_peek_color_spec (birthdays_source) == NULL)
e_source_set_color_spec (birthdays_source, "#DDBECE");
@@ -316,7 +316,7 @@ ensure_sources (CalendarComponent *component)
g_object_unref (personal_source);
if (birthdays_source)
g_object_unref (birthdays_source);
-
+
g_free (base_uri_proto);
g_free (base_uri);
}
@@ -328,10 +328,10 @@ static gboolean
is_in_selection (GSList *selection, ESource *source)
{
GSList *l;
-
+
for (l = selection; l; l = l->next) {
ESource *selected_source = l->data;
-
+
if (!strcmp (e_source_peek_uid (selected_source), e_source_peek_uid (source)))
return TRUE;
}
@@ -343,10 +343,10 @@ static gboolean
is_in_uids (GSList *uids, ESource *source)
{
GSList *l;
-
+
for (l = uids; l; l = l->next) {
const char *uid = l->data;
-
+
if (!strcmp (uid, e_source_peek_uid (source)))
return TRUE;
}
@@ -358,7 +358,7 @@ static void
update_uris_for_selection (CalendarComponentView *component_view)
{
GSList *selection, *l, *uids_selected = NULL;
-
+
selection = e_source_selector_get_selection (E_SOURCE_SELECTOR (component_view->source_selector));
for (l = component_view->source_selection; l; l = l->next) {
@@ -370,11 +370,11 @@ update_uris_for_selection (CalendarComponentView *component_view)
for (l = selection; l; l = l->next) {
ESource *selected_source = l->data;
-
+
if (gnome_calendar_add_source (component_view->calendar, E_CAL_SOURCE_TYPE_EVENT, selected_source))
uids_selected = g_slist_append (uids_selected, (char *) e_source_peek_uid (selected_source));
}
-
+
e_source_selector_free_selection (component_view->source_selection);
component_view->source_selection = selection;
@@ -416,10 +416,10 @@ update_selection (CalendarComponentView *component_view)
for (l = selection; l; l = l->next) {
ESource *source = l->data;
- if (!is_in_uids (uids_selected, source))
+ if (!is_in_uids (uids_selected, source))
e_source_selector_unselect_source (E_SOURCE_SELECTOR (component_view->source_selector), source);
}
-
+
e_source_selector_free_selection (selection);
/* Make sure the whole selection is there */
@@ -428,9 +428,9 @@ update_selection (CalendarComponentView *component_view)
ESource *source;
source = e_source_list_peek_source_by_uid (component_view->source_list, uid);
- if (source)
+ if (source)
e_source_selector_select_source (E_SOURCE_SELECTOR (component_view->source_selector), source);
-
+
g_free (uid);
}
g_slist_free (uids_selected);
@@ -463,7 +463,7 @@ update_task_memo_selection (CalendarComponentView *component_view, ECalSourceTyp
gnome_calendar_remove_source_by_uid (component_view->calendar, type, uid);
else if (!is_in_uids (uids_selected, source))
gnome_calendar_remove_source (component_view->calendar, type, source);
-
+
g_free (uid);
}
g_slist_free (source_selection);
@@ -495,7 +495,7 @@ update_primary_selection (CalendarComponentView *component_view)
source = e_source_list_peek_source_by_uid (component_view->source_list, uid);
g_free (uid);
}
-
+
if (source) {
e_source_selector_set_primary_selection (E_SOURCE_SELECTOR (component_view->source_selector), source);
} else {
@@ -526,7 +526,7 @@ update_primary_task_memo_selection (CalendarComponentView *component_view, ECalS
g_free (uid);
}
-
+
if (source)
gnome_calendar_set_default_source (component_view->calendar, type, source);
}
@@ -537,7 +537,7 @@ copy_calendar_cb (EPopup *ep, EPopupItem *pitem, void *data)
{
CalendarComponentView *component_view = data;
ESource *selected_source;
-
+
selected_source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (component_view->source_selector));
if (!selected_source)
return;
@@ -575,7 +575,7 @@ delete_calendar_cb (EPopup *ep, EPopupItem *pitem, void *data)
e_source_selector_unselect_source (E_SOURCE_SELECTOR (component_view->source_selector),
selected_source);
}
-
+
e_source_group_remove_source (e_source_peek_group (selected_source), selected_source);
e_source_list_sync (component_view->source_list, NULL);
}
@@ -622,7 +622,7 @@ popup_event_cb(ESourceSelector *selector, ESource *insource, GdkEventButton *eve
GSList *menus = NULL;
int i;
GtkMenu *menu;
-
+
/** @HookPoint-ECalPopup: Calendar Source Selector Context Menu
* @Id: org.gnome.evolution.calendar.source.popup
* @Class: org.gnome.evolution.calendar.popup:1.0
@@ -633,10 +633,10 @@ popup_event_cb(ESourceSelector *selector, ESource *insource, GdkEventButton *eve
ep = e_cal_popup_new("org.gnome.evolution.calendar.source.popup");
t = e_cal_popup_target_new_source(ep, selector);
t->target.widget = (GtkWidget *)component_view->calendar;
-
+
for (i=0;i<sizeof(ecc_source_popups)/sizeof(ecc_source_popups[0]);i++)
menus = g_slist_prepend(menus, &ecc_source_popups[i]);
-
+
e_popup_add_items((EPopup *)ep, menus, NULL, ecc_source_popup_free, component_view);
menu = e_popup_create_menu_once((EPopup *)ep, (EPopupTarget *)t, 0);
@@ -802,7 +802,7 @@ config_primary_selection_changed_cb (GConfClient *client, guint id, GConfEntry *
{
CalendarComponent *calendar_component = data;
CalendarComponentPrivate *priv = calendar_component->priv;
-
+
if (priv->create_ecal) {
g_object_unref (priv->create_ecal);
priv->create_ecal = NULL;
@@ -848,13 +848,13 @@ impl_handleURI (PortableServer_Servant servant, const char *uri, CORBA_Environme
char *rid = NULL;
priv = calendar_component->priv;
-
+
l = g_list_last (priv->views);
if (!l)
return;
view = l->data;
-
+
if (!strncmp (uri, "calendar:", 9)) {
EUri *euri = e_uri_new (uri);
const char *p;
@@ -866,17 +866,17 @@ impl_handleURI (PortableServer_Servant servant, const char *uri, CORBA_Environme
if (p) {
while (*p) {
len = strcspn (p, "=&");
-
+
/* If it's malformed, give up. */
if (p[len] != '=')
break;
-
+
header = (char *) p;
header[len] = '\0';
p += len + 1;
-
+
clen = strcspn (p, "&");
-
+
content = g_strndup (p, clen);
if (!g_ascii_strcasecmp (header, "startdate")) {
@@ -902,14 +902,14 @@ impl_handleURI (PortableServer_Servant servant, const char *uri, CORBA_Environme
}
if (start != -1) {
-
+
if (end == -1)
end = start;
gnome_calendar_set_selected_time_range (view->calendar, start, end);
}
if (src_uid && uid)
gnome_calendar_edit_appointment (view->calendar, src_uid, uid, rid);
-
+
g_free (src_uid);
g_free (uid);
g_free (rid);
@@ -942,11 +942,11 @@ impl_upgradeFromVersion (PortableServer_Servant servant,
}
static gboolean
-selector_tree_drag_drop (GtkWidget *widget,
- GdkDragContext *context,
- int x,
- int y,
- guint time,
+selector_tree_drag_drop (GtkWidget *widget,
+ GdkDragContext *context,
+ int x,
+ int y,
+ guint time,
CalendarComponent *component)
{
GtkTreeViewColumn *column;
@@ -956,12 +956,12 @@ selector_tree_drag_drop (GtkWidget *widget,
GtkTreeModel *model;
GtkTreeIter iter;
gpointer data;
-
- if (!gtk_tree_view_get_path_at_pos (GTK_TREE_VIEW (widget), x, y, &path,
+
+ if (!gtk_tree_view_get_path_at_pos (GTK_TREE_VIEW (widget), x, y, &path,
&column, &cell_x, &cell_y))
return FALSE;
-
-
+
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
if (!gtk_tree_model_get_iter (model, &iter, path)) {
@@ -970,17 +970,17 @@ selector_tree_drag_drop (GtkWidget *widget,
}
gtk_tree_model_get (model, &iter, 0, &data, -1);
-
+
if (E_IS_SOURCE_GROUP (data)) {
g_object_unref (data);
gtk_tree_path_free (path);
return FALSE;
}
-
+
gtk_tree_path_free (path);
return TRUE;
}
-
+
static gboolean
selector_tree_drag_motion (GtkWidget *widget,
GdkDragContext *context,
@@ -995,21 +995,21 @@ selector_tree_drag_motion (GtkWidget *widget,
GtkTreeModel *model;
GtkTreeIter iter;
GdkDragAction action = GDK_ACTION_DEFAULT;
-
+
if (!gtk_tree_view_get_dest_row_at_pos (GTK_TREE_VIEW (widget),
x, y, &path, &pos))
goto finish;
-
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
-
+
if (!gtk_tree_model_get_iter (model, &iter, path))
goto finish;
-
+
gtk_tree_model_get (model, &iter, 0, &data, -1);
if (E_IS_SOURCE_GROUP (data) || e_source_get_readonly (data))
goto finish;
-
+
gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget), path, GTK_TREE_VIEW_DROP_INTO_OR_BEFORE);
action = context->suggested_action;
@@ -1030,11 +1030,11 @@ update_single_object (ECal *client, icalcomponent *icalcomp)
icalcomponent *tmp_icalcomp;
uid = (char *) icalcomponent_get_uid (icalcomp);
-
+
if (e_cal_get_object (client, uid, NULL, &tmp_icalcomp, NULL))
return e_cal_modify_object (client, icalcomp, CALOBJ_MOD_ALL, NULL);
- return e_cal_create_object (client, icalcomp, &uid, NULL);
+ return e_cal_create_object (client, icalcomp, &uid, NULL);
}
static gboolean
@@ -1052,7 +1052,7 @@ update_objects (ECal *client, icalcomponent *icalcomp)
subcomp = icalcomponent_get_first_component (icalcomp, ICAL_ANY_COMPONENT);
while (subcomp) {
gboolean success;
-
+
kind = icalcomponent_isa (subcomp);
if (kind == ICAL_VTIMEZONE_COMPONENT) {
icaltimezone *zone;
@@ -1078,10 +1078,10 @@ update_objects (ECal *client, icalcomponent *icalcomp)
}
static void
-selector_tree_drag_data_received (GtkWidget *widget,
- GdkDragContext *context,
- gint x,
- gint y,
+selector_tree_drag_data_received (GtkWidget *widget,
+ GdkDragContext *context,
+ gint x,
+ gint y,
GtkSelectionData *data,
guint info,
guint time,
@@ -1099,20 +1099,20 @@ selector_tree_drag_data_received (GtkWidget *widget,
if (!gtk_tree_view_get_dest_row_at_pos (GTK_TREE_VIEW (widget),
x, y, &path, &pos))
goto finish;
-
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
-
+
if (!gtk_tree_model_get_iter (model, &iter, path))
goto finish;
-
-
+
+
gtk_tree_model_get (model, &iter, 0, &source, -1);
if (E_IS_SOURCE_GROUP (source) || e_source_get_readonly (source))
goto finish;
icalcomp = icalparser_parse_string ((char *)data->data);
-
+
if (icalcomp) {
char * uid;
@@ -1122,18 +1122,18 @@ selector_tree_drag_data_received (GtkWidget *widget,
icalcomponent_set_uid (icalcomp, uid);
}
- client = auth_new_cal_from_source (source,
+ client = auth_new_cal_from_source (source,
E_CAL_SOURCE_TYPE_EVENT);
-
+
if (client) {
if (e_cal_open (client, TRUE, NULL)) {
success = TRUE;
update_objects (client, icalcomp);
}
-
+
g_object_unref (client);
}
-
+
icalcomponent_free (icalcomp);
}
@@ -1144,12 +1144,12 @@ selector_tree_drag_data_received (GtkWidget *widget,
gtk_tree_path_free (path);
gtk_drag_finish (context, success, context->action == GDK_ACTION_MOVE, time);
-}
+}
static void
selector_tree_drag_leave (GtkWidget *widget, GdkDragContext *context, guint time, gpointer data)
{
- gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget),
+ gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget),
NULL, GTK_TREE_VIEW_DROP_BEFORE);
}
@@ -1161,57 +1161,57 @@ control_activate_cb (BonoboControl *control, gboolean activate, gpointer data)
if (activate) {
BonoboUIComponent *uic;
uic = bonobo_control_get_ui_component (component_view->view_control);
-
+
e_user_creatable_items_handler_activate (component_view->creatable_items_handler, uic);
- }
+ }
}
static void
config_create_ecal_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer data)
-{
+{
CalendarComponent *calendar_component = data;
CalendarComponentPrivate *priv;
-
+
priv = calendar_component->priv;
g_object_unref (priv->create_ecal);
priv->create_ecal = NULL;
-
+
priv->notifications = g_list_remove (priv->notifications, GUINT_TO_POINTER (id));
}
static ECal *
-setup_create_ecal (CalendarComponent *calendar_component, CalendarComponentView *component_view)
+setup_create_ecal (CalendarComponent *calendar_component, CalendarComponentView *component_view)
{
CalendarComponentPrivate *priv;
ESource *source = NULL;
char *uid;
guint not;
-
+
priv = calendar_component->priv;
/* Try to use the client from the calendar first to avoid re-opening things */
if (component_view) {
ECal *default_ecal;
-
+
default_ecal = gnome_calendar_get_default_client (component_view->calendar);
if (default_ecal)
return default_ecal;
}
-
+
/* If there is an existing fall back, use that */
if (priv->create_ecal)
- return priv->create_ecal;
+ return priv->create_ecal;
- /* Get the current primary calendar, or try to set one if it doesn't already exist */
+ /* Get the current primary calendar, or try to set one if it doesn't already exist */
uid = calendar_config_get_primary_calendar ();
if (uid) {
source = e_source_list_peek_source_by_uid (priv->source_list, uid);
g_free (uid);
priv->create_ecal = auth_new_cal_from_source (source, E_CAL_SOURCE_TYPE_EVENT);
- }
+ }
if (!priv->create_ecal) {
/* Try to create a default if there isn't one */
@@ -1219,19 +1219,19 @@ setup_create_ecal (CalendarComponent *calendar_component, CalendarComponentView
if (source)
priv->create_ecal = auth_new_cal_from_source (source, E_CAL_SOURCE_TYPE_EVENT);
}
-
+
if (priv->create_ecal) {
icaltimezone *zone;
-
+
zone = calendar_config_get_icaltimezone ();
e_cal_set_default_timezone (priv->create_ecal, zone, NULL);
if (!e_cal_open (priv->create_ecal, FALSE, NULL)) {
GtkWidget *dialog;
-
+
dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_MODAL,
GTK_MESSAGE_WARNING, GTK_BUTTONS_OK,
- _("Unable to open the calendar '%s' for creating events and meetings"),
+ _("Unable to open the calendar '%s' for creating events and meetings"),
e_source_peek_name (source));
gtk_dialog_run (GTK_DIALOG (dialog));
@@ -1244,7 +1244,7 @@ setup_create_ecal (CalendarComponent *calendar_component, CalendarComponentView
} else {
GtkWidget *dialog;
-
+
dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_MODAL,
GTK_MESSAGE_WARNING, GTK_BUTTONS_OK,
_("There is no calendar available for creating events and meetings"));
@@ -1252,10 +1252,10 @@ setup_create_ecal (CalendarComponent *calendar_component, CalendarComponentView
gtk_widget_destroy (dialog);
return NULL;
- }
+ }
/* Handle the fact it may change on us */
- not = calendar_config_add_notification_primary_calendar (config_create_ecal_changed_cb,
+ not = calendar_config_add_notification_primary_calendar (config_create_ecal_changed_cb,
calendar_component);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
@@ -1297,7 +1297,7 @@ create_new_event (CalendarComponent *calendar_component, CalendarComponentView *
e_comp_editor_registry_add (comp_editor_registry, COMP_EDITOR (editor), TRUE);
}
- return TRUE;
+ return TRUE;
}
static void
@@ -1307,18 +1307,18 @@ create_local_item_cb (EUserCreatableItemsHandler *handler, const char *item_type
CalendarComponentPrivate *priv;
CalendarComponentView *component_view = NULL;
GList *l;
-
+
priv = calendar_component->priv;
-
+
for (l = priv->views; l; l = l->next) {
component_view = l->data;
if (component_view->creatable_items_handler == handler)
break;
-
+
component_view = NULL;
}
-
+
if (strcmp (item_type_name, CREATE_EVENT_ID) == 0)
create_new_event (calendar_component, component_view, FALSE, FALSE);
else if (strcmp (item_type_name, CREATE_ALLDAY_EVENT_ID) == 0)
@@ -1338,12 +1338,12 @@ create_component_view (CalendarComponent *calendar_component)
GtkWidget *statusbar_widget;
guint not;
AtkObject *a11y;
-
+
priv = calendar_component->priv;
/* Create the calendar component view */
component_view = g_new0 (CalendarComponentView, 1);
-
+
vpane = gtk_vpaned_new ();
g_signal_connect_after (vpane, "realize",
G_CALLBACK(calcomp_vpane_realized), component_view);
@@ -1355,20 +1355,20 @@ create_component_view (CalendarComponent *calendar_component)
component_view->task_source_list = g_object_ref (priv->task_source_list);
component_view->memo_source_list = g_object_ref (priv->memo_source_list);
component_view->vpane_pos = calendar_config_get_tag_vpane_pos ();
-
+
/* Create sidebar selector */
component_view->source_selector = e_source_selector_new (calendar_component->priv->source_list);
e_source_selector_set_select_new ((ESourceSelector *)component_view->source_selector, TRUE);
a11y = gtk_widget_get_accessible (GTK_WIDGET (component_view->source_selector));
atk_object_set_name (a11y, _("Calendar Source Selector"));
- g_signal_connect (component_view->source_selector, "drag-motion", G_CALLBACK (selector_tree_drag_motion),
+ g_signal_connect (component_view->source_selector, "drag-motion", G_CALLBACK (selector_tree_drag_motion),
calendar_component);
- g_signal_connect (component_view->source_selector, "drag-leave", G_CALLBACK (selector_tree_drag_leave),
+ g_signal_connect (component_view->source_selector, "drag-leave", G_CALLBACK (selector_tree_drag_leave),
calendar_component);
- g_signal_connect (component_view->source_selector, "drag-drop", G_CALLBACK (selector_tree_drag_drop),
+ g_signal_connect (component_view->source_selector, "drag-drop", G_CALLBACK (selector_tree_drag_drop),
calendar_component);
- g_signal_connect (component_view->source_selector, "drag-data-received",
+ g_signal_connect (component_view->source_selector, "drag-data-received",
G_CALLBACK (selector_tree_drag_data_received), calendar_component);
gtk_drag_dest_set(component_view->source_selector, GTK_DEST_DEFAULT_ALL, drag_types,
@@ -1392,9 +1392,9 @@ create_component_view (CalendarComponent *calendar_component)
gtk_box_pack_start(GTK_BOX (vbox), GTK_WIDGET (component_view->info_label), FALSE, TRUE, 0);
gtk_box_pack_start(GTK_BOX (vbox), selector_scrolled_window, TRUE, TRUE, 0);
gtk_widget_show (vbox);
-
- gtk_paned_pack1 (GTK_PANED (vpane), vbox, FALSE, FALSE);
-
+
+ gtk_paned_pack1 (GTK_PANED (vpane), vbox, FALSE, FALSE);
+
component_view->sidebar_control = bonobo_control_new (vpane);
/* Create main view */
@@ -1404,15 +1404,15 @@ create_component_view (CalendarComponent *calendar_component)
return NULL;
}
-
+
component_view->calendar = (GnomeCalendar *) bonobo_control_get_widget (component_view->view_control);
- gtk_paned_pack2 (GTK_PANED (vpane), gnome_calendar_get_tag (component_view->calendar), FALSE, FALSE);
+ gtk_paned_pack2 (GTK_PANED (vpane), gnome_calendar_get_tag (component_view->calendar), FALSE, FALSE);
/* This signal is thrown if backends die - we update the selector */
- g_signal_connect (component_view->calendar, "source_added",
+ g_signal_connect (component_view->calendar, "source_added",
G_CALLBACK (source_added_cb), component_view);
- g_signal_connect (component_view->calendar, "source_removed",
+ g_signal_connect (component_view->calendar, "source_removed",
G_CALLBACK (source_removed_cb), component_view);
/* Create status bar */
@@ -1422,9 +1422,9 @@ create_component_view (CalendarComponent *calendar_component)
gtk_widget_show (statusbar_widget);
component_view->statusbar_control = bonobo_control_new (statusbar_widget);
-
+
gnome_calendar_set_activity_handler (component_view->calendar, component_view->activity_handler);
-
+
/* connect after setting the initial selections, or we'll get unwanted calls
to calendar_control_sensitize_calendar_commands */
g_signal_connect (component_view->source_selector, "selection_changed",
@@ -1444,7 +1444,7 @@ create_component_view (CalendarComponent *calendar_component)
G_CALLBACK (calendar_dates_changed_cb), component_view);
/* Load the selection from the last run */
- update_selection (component_view);
+ update_selection (component_view);
update_primary_selection (component_view);
update_task_memo_selection (component_view, E_CAL_SOURCE_TYPE_TODO);
update_primary_task_memo_selection (component_view, E_CAL_SOURCE_TYPE_TODO);
@@ -1453,19 +1453,19 @@ create_component_view (CalendarComponent *calendar_component)
/* If the tasks/memos selection changes elsewhere, update it for the mini
mini tasks view sidebar */
- not = calendar_config_add_notification_tasks_selected (config_tasks_selection_changed_cb,
+ not = calendar_config_add_notification_tasks_selected (config_tasks_selection_changed_cb,
component_view);
component_view->notifications = g_list_prepend (component_view->notifications, GUINT_TO_POINTER (not));
- not = calendar_config_add_notification_memos_selected (config_memos_selection_changed_cb,
+ not = calendar_config_add_notification_memos_selected (config_memos_selection_changed_cb,
component_view);
component_view->notifications = g_list_prepend (component_view->notifications, GUINT_TO_POINTER (not));
- not = calendar_config_add_notification_primary_tasks (config_primary_tasks_selection_changed_cb,
+ not = calendar_config_add_notification_primary_tasks (config_primary_tasks_selection_changed_cb,
component_view);
component_view->notifications = g_list_prepend (component_view->notifications, GUINT_TO_POINTER (not));
-
- not = calendar_config_add_notification_primary_memos (config_primary_memos_selection_changed_cb,
+
+ not = calendar_config_add_notification_primary_memos (config_primary_memos_selection_changed_cb,
component_view);
component_view->notifications = g_list_prepend (component_view->notifications, GUINT_TO_POINTER (not));
@@ -1474,21 +1474,21 @@ create_component_view (CalendarComponent *calendar_component)
static void
destroy_component_view (CalendarComponentView *component_view)
-{
+{
GList *l;
-
+
if (component_view->source_list)
g_object_unref (component_view->source_list);
if (component_view->task_source_list)
g_object_unref (component_view->task_source_list);
-
+
if (component_view->memo_source_list)
g_object_unref (component_view->memo_source_list);
if (component_view->source_selection)
e_source_selector_free_selection (component_view->source_selection);
-
+
for (l = component_view->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
g_list_free (component_view->notifications);
@@ -1518,12 +1518,12 @@ view_destroyed_cb (gpointer data, GObject *where_the_object_was)
CalendarComponent *calendar_component = data;
CalendarComponentPrivate *priv;
GList *l;
-
+
priv = calendar_component->priv;
for (l = priv->views; l; l = l->next) {
CalendarComponentView *component_view = l->data;
-
+
if (G_OBJECT (component_view->view_control) == where_the_object_was) {
priv->views = g_list_remove (priv->views, component_view);
destroy_component_view (component_view);
@@ -1542,7 +1542,7 @@ impl_createView (PortableServer_Servant servant,
CalendarComponentPrivate *priv;
CalendarComponentView *component_view;
EComponentView *ecv;
-
+
priv = calendar_component->priv;
/* Create the calendar component view */
@@ -1556,7 +1556,7 @@ impl_createView (PortableServer_Servant servant,
g_object_weak_ref (G_OBJECT (component_view->view_control), view_destroyed_cb, calendar_component);
priv->views = g_list_append (priv->views, component_view);
-
+
/* TODO: Make CalendarComponentView just subclass EComponentView */
ecv = e_component_view_new_controls (parent, "calendar", component_view->sidebar_control,
component_view->view_control, component_view->statusbar_control);
@@ -1619,7 +1619,7 @@ impl_requestCreateItem (PortableServer_Servant servant,
{
CalendarComponent *calendar_component = CALENDAR_COMPONENT (bonobo_object_from_servant (servant));
gboolean result = FALSE;
-
+
if (strcmp (item_type_name, CREATE_EVENT_ID) == 0)
result = create_new_event (calendar_component, NULL, FALSE, FALSE);
else if (strcmp (item_type_name, CREATE_ALLDAY_EVENT_ID) == 0)
@@ -1644,7 +1644,7 @@ impl_dispose (GObject *object)
CalendarComponent *calendar_component = CALENDAR_COMPONENT (object);
CalendarComponentPrivate *priv = calendar_component->priv;
GList *l;
-
+
if (priv->source_list != NULL) {
g_object_unref (priv->source_list);
priv->source_list = NULL;
@@ -1662,12 +1662,12 @@ impl_dispose (GObject *object)
for (l = priv->views; l; l = l->next) {
CalendarComponentView *component_view = l->data;
-
+
g_object_weak_unref (G_OBJECT (component_view->view_control), view_destroyed_cb, calendar_component);
}
g_list_free (priv->views);
priv->views = NULL;
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
g_list_free (priv->notifications);
@@ -1681,14 +1681,14 @@ impl_finalize (GObject *object)
{
CalendarComponentPrivate *priv = CALENDAR_COMPONENT (object)->priv;
GList *l;
-
+
for (l = priv->views; l; l = l->next) {
CalendarComponentView *component_view = l->data;
-
+
destroy_component_view (component_view);
}
g_list_free (priv->views);
-
+
g_free (priv->base_directory);
g_free (priv->config_directory);
g_free (priv);
@@ -1719,7 +1719,7 @@ calendar_component_init (CalendarComponent *component)
{
CalendarComponentPrivate *priv;
guint not;
-
+
priv = g_new0 (CalendarComponentPrivate, 1);
priv->base_directory = g_build_filename (g_get_home_dir (), ".evolution", NULL);
@@ -1731,7 +1731,7 @@ calendar_component_init (CalendarComponent *component)
* calendar_component_peek_gconf_client(). */
priv->gconf_client = gconf_client_get_default ();
- not = calendar_config_add_notification_primary_calendar (config_primary_selection_changed_cb,
+ not = calendar_config_add_notification_primary_calendar (config_primary_selection_changed_cb,
component);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
diff --git a/calendar/gui/calendar-config.c b/calendar/gui/calendar-config.c
index 46714ec324..e8cc126f5d 100644
--- a/calendar/gui/calendar-config.c
+++ b/calendar/gui/calendar-config.c
@@ -77,7 +77,7 @@ void
calendar_config_remove_notification (guint id)
{
calendar_config_init ();
-
+
gconf_client_notify_remove (config, id);
}
@@ -141,9 +141,9 @@ calendar_config_add_notification_calendars_selected (GConfClientNotifyFunc func,
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_SELECTED_CALENDARS, func, data, NULL, NULL);
-
+
return id;
}
@@ -171,9 +171,9 @@ calendar_config_add_notification_primary_calendar (GConfClientNotifyFunc func, g
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_PRIMARY_CALENDAR, func, data, NULL, NULL);
-
+
return id;
}
@@ -192,7 +192,7 @@ calendar_config_get_timezone (void)
static void
set_standard_offsets (icalcomponent *zone_comp, int offset)
{
- icalcomponent *dl_comp, *s_comp;
+ icalcomponent *dl_comp, *s_comp;
icalproperty *offset_from, *offset_to;
/* Set the offset of the standard component to all the daylight components also */
@@ -217,19 +217,19 @@ calendar_config_get_icaltimezone (void)
icaltimezone *zone = NULL;
calendar_config_init ();
-
+
location = calendar_config_get_timezone ();
if (location) {
icalcomponent *icalcomp, *dl_comp;
-
+
zone = icaltimezone_get_builtin_timezone (location);
icalcomp = icaltimezone_get_component (zone);
-
+
if (!(dl_comp = icalcomponent_get_first_component (icalcomp, ICAL_XDAYLIGHT_COMPONENT))) {
g_free (location);
return zone;
- }
+ }
if (!calendar_config_get_daylight_saving () && zone) {
icalcomponent *zone_comp, *s_comp;
@@ -237,7 +237,7 @@ calendar_config_get_icaltimezone (void)
icaltimezone *st_zone = NULL;
int offset;
char *n_tzid, *tzid;
-
+
tzid = icaltimezone_get_tzid (zone);
n_tzid = g_strconcat (tzid, "-(Standard)", NULL);
@@ -255,10 +255,10 @@ calendar_config_get_icaltimezone (void)
if (!s_comp) {
g_free (n_tzid);
icalcomponent_free (zone_comp);
- g_free (location);
+ g_free (location);
return zone;
}
-
+
offset_to = icalcomponent_get_first_property (s_comp, ICAL_TZOFFSETTO_PROPERTY);
offset = icalproperty_get_tzoffsetto (offset_to);
@@ -274,10 +274,10 @@ calendar_config_get_icaltimezone (void)
st_zone = icaltimezone_new ();
icaltimezone_set_component (st_zone, zone_comp);
-
+
zone = st_zone;
g_hash_table_insert (custom_zones, n_tzid, zone);
- }
+ }
g_free (location);
}
@@ -304,9 +304,9 @@ calendar_config_add_notification_timezone (GConfClientNotifyFunc func, gpointer
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_TIMEZONE, func, data, NULL, NULL);
-
+
return id;
}
@@ -314,16 +314,16 @@ gboolean
calendar_config_get_daylight_saving (void)
{
calendar_config_init ();
-
+
return gconf_client_get_bool (config, CALENDAR_CONFIG_DAYLIGHT_SAVING, NULL);
-
+
}
void
calendar_config_set_daylight_saving (gboolean daylight_saving)
{
calendar_config_init ();
-
+
gconf_client_set_bool (config, CALENDAR_CONFIG_DAYLIGHT_SAVING, daylight_saving, NULL);
}
@@ -333,9 +333,9 @@ calendar_config_add_notification_daylight_saving (GConfClientNotifyFunc func, gp
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_DAYLIGHT_SAVING, func, data, NULL, NULL);
-
+
return id;
}
@@ -370,9 +370,9 @@ calendar_config_add_notification_24_hour_format (GConfClientNotifyFunc func, gpo
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_24HOUR, func, data, NULL, NULL);
-
+
return id;
}
@@ -445,7 +445,7 @@ calendar_config_set_show_status (gboolean state)
}
/* Show timezone */
-gboolean
+gboolean
calendar_config_get_show_timezone (void)
{
calendar_config_init ();
@@ -453,22 +453,22 @@ calendar_config_get_show_timezone (void)
return gconf_client_get_bool (config, CALENDAR_CONFIG_SHOW_TIMEZONE, NULL);
}
-void
+void
calendar_config_set_show_timezone (gboolean status)
{
calendar_config_init ();
- gconf_client_set_bool (config, CALENDAR_CONFIG_SHOW_TIMEZONE, status, NULL);
+ gconf_client_set_bool (config, CALENDAR_CONFIG_SHOW_TIMEZONE, status, NULL);
}
-gboolean
+gboolean
calendar_config_get_show_categories (void)
{
calendar_config_init ();
return gconf_client_get_bool (config, CALENDAR_CONFIG_SHOW_CATEGORIES, NULL);
}
-void
+void
calendar_config_set_show_categories (gboolean status)
{
calendar_config_init ();
@@ -495,16 +495,16 @@ calendar_config_set_week_start_day (gint week_start_day)
gconf_client_set_int (config, CALENDAR_CONFIG_WEEK_START, week_start_day, NULL);
}
-guint
+guint
calendar_config_add_notification_week_start_day (GConfClientNotifyFunc func, gpointer data)
{
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_WEEK_START, func, data, NULL, NULL);
-
- return id;
+
+ return id;
}
/* The start and end times of the work-day. */
@@ -525,16 +525,16 @@ calendar_config_set_day_start_hour (gint day_start_hour)
gconf_client_set_int (config, CALENDAR_CONFIG_DAY_START_HOUR, day_start_hour, NULL);
}
-guint
+guint
calendar_config_add_notification_day_start_hour (GConfClientNotifyFunc func, gpointer data)
{
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_DAY_START_HOUR, func, data, NULL, NULL);
-
- return id;
+
+ return id;
}
gint
@@ -554,16 +554,16 @@ calendar_config_set_day_start_minute (gint day_start_min)
gconf_client_set_int (config, CALENDAR_CONFIG_DAY_START_MINUTE, day_start_min, NULL);
}
-guint
+guint
calendar_config_add_notification_day_start_minute (GConfClientNotifyFunc func, gpointer data)
{
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_DAY_START_MINUTE, func, data, NULL, NULL);
-
- return id;
+
+ return id;
}
gint
@@ -583,16 +583,16 @@ calendar_config_set_day_end_hour (gint day_end_hour)
gconf_client_set_int (config, CALENDAR_CONFIG_DAY_END_HOUR, day_end_hour, NULL);
}
-guint
+guint
calendar_config_add_notification_day_end_hour (GConfClientNotifyFunc func, gpointer data)
{
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_DAY_END_HOUR, func, data, NULL, NULL);
-
- return id;
+
+ return id;
}
gint
@@ -612,16 +612,16 @@ calendar_config_set_day_end_minute (gint day_end_min)
gconf_client_set_int (config, CALENDAR_CONFIG_DAY_END_MINUTE, day_end_min, NULL);
}
-guint
+guint
calendar_config_add_notification_day_end_minute (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_DAY_END_MINUTE, func, data, NULL, NULL);
-
- return id;
+
+ return id;
}
/* The time divisions in the Day/Work-Week view in minutes (5/10/15/30/60). */
@@ -648,9 +648,9 @@ calendar_config_add_notification_time_divisions (GConfClientNotifyFunc func, gpo
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_TIME_DIVISIONS, func, data, NULL, NULL);
-
+
return id;
}
@@ -704,15 +704,15 @@ calendar_config_set_dnav_show_week_no (gboolean show_week_no)
gconf_client_set_bool (config, CALENDAR_CONFIG_DN_SHOW_WEEK_NUMBERS, show_week_no, NULL);
}
-guint
+guint
calendar_config_add_notification_dnav_show_week_no (GConfClientNotifyFunc func, gpointer data)
{
guint id;
calendar_config_init ();
-
+
id = gconf_client_notify_add (config, CALENDAR_CONFIG_DN_SHOW_WEEK_NUMBERS, func, data, NULL, NULL);
-
+
return id;
}
@@ -854,11 +854,11 @@ guint
calendar_config_add_notification_tasks_selected (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_TASKS_SELECTED_TASKS, func, data, NULL, NULL);
-
+
return id;
}
@@ -884,11 +884,11 @@ guint
calendar_config_add_notification_primary_tasks (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_PRIMARY_TASKS, func, data, NULL, NULL);
-
+
return id;
}
@@ -932,11 +932,11 @@ guint
calendar_config_add_notification_memos_selected (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_MEMOS_SELECTED_MEMOS, func, data, NULL, NULL);
-
+
return id;
}
@@ -962,11 +962,11 @@ guint
calendar_config_add_notification_primary_memos (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_PRIMARY_MEMOS, func, data, NULL, NULL);
-
+
return id;
}
/***************************************/
@@ -993,11 +993,11 @@ guint
calendar_config_add_notification_compress_weekend (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_COMPRESS_WEEKEND, func, data, NULL, NULL);
-
+
return id;
}
@@ -1023,11 +1023,11 @@ guint
calendar_config_add_notification_show_event_end (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_SHOW_EVENT_END, func, data, NULL, NULL);
-
+
return id;
}
@@ -1049,16 +1049,16 @@ calendar_config_set_working_days (CalWeekdays days)
gconf_client_set_int (config, CALENDAR_CONFIG_WORKING_DAYS, days, NULL);
}
-guint
+guint
calendar_config_add_notification_working_days (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_WORKING_DAYS , func, data, NULL, NULL);
-
- return id;
+
+ return id;
}
/* Settings to hide completed tasks. */
@@ -1079,16 +1079,16 @@ calendar_config_set_hide_completed_tasks (gboolean hide)
gconf_client_set_bool (config, CALENDAR_CONFIG_TASKS_HIDE_COMPLETED, hide, NULL);
}
-guint
+guint
calendar_config_add_notification_hide_completed_tasks (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_TASKS_HIDE_COMPLETED , func, data, NULL, NULL);
-
- return id;
+
+ return id;
}
CalUnits
@@ -1137,16 +1137,16 @@ calendar_config_set_hide_completed_tasks_units (CalUnits cu)
g_free (units);
}
-guint
+guint
calendar_config_add_notification_hide_completed_tasks_units (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_TASKS_HIDE_COMPLETED_UNITS , func, data, NULL, NULL);
-
- return id;
+
+ return id;
}
gint
@@ -1166,16 +1166,16 @@ calendar_config_set_hide_completed_tasks_value (gint value)
gconf_client_set_int (config, CALENDAR_CONFIG_TASKS_HIDE_COMPLETED_VALUE, value, NULL);
}
-guint
+guint
calendar_config_add_notification_hide_completed_tasks_value (GConfClientNotifyFunc func, gpointer data)
{
guint id;
-
+
calendar_config_init ();
id = gconf_client_notify_add (config, CALENDAR_CONFIG_TASKS_HIDE_COMPLETED_VALUE , func, data, NULL, NULL);
-
- return id;
+
+ return id;
}
/**
@@ -1514,7 +1514,7 @@ calendar_config_set_default_reminder_units (CalUnits units)
/**
* calendar_config_get_hide_completed_tasks_sexp:
*
- * @get_completed: Whether to form subexpression that
+ * @get_completed: Whether to form subexpression that
* gets completed or not completed tasks.
* Returns the subexpression to use to filter out completed tasks according
* to the config settings. The returned sexp should be freed.
@@ -1594,18 +1594,18 @@ calendar_config_set_free_busy_template (const gchar *template)
gconf_client_set_string (config, CALENDAR_CONFIG_TEMPLATE, template, NULL);
}
-guint
-calendar_config_add_notification_free_busy_template (GConfClientNotifyFunc func,
+guint
+calendar_config_add_notification_free_busy_template (GConfClientNotifyFunc func,
gpointer data)
{
guint id;
-
+
calendar_config_init ();
- id = gconf_client_notify_add (config, CALENDAR_CONFIG_TEMPLATE, func, data,
+ id = gconf_client_notify_add (config, CALENDAR_CONFIG_TEMPLATE, func, data,
NULL, NULL);
-
- return id;
+
+ return id;
}
void
diff --git a/calendar/gui/calendar-config.h b/calendar/gui/calendar-config.h
index ec7d3dee16..5e0dbc9059 100644
--- a/calendar/gui/calendar-config.h
+++ b/calendar/gui/calendar-config.h
@@ -246,7 +246,7 @@ void calendar_config_set_free_busy (GSList * url_list);
gchar *calendar_config_get_free_busy_template (void);
void calendar_config_set_free_busy_template (const gchar *template);
-guint calendar_config_add_notification_free_busy_template (GConfClientNotifyFunc func,
+guint calendar_config_add_notification_free_busy_template (GConfClientNotifyFunc func,
gpointer data);
/* Shows the timezone dialog if the user hasn't set a default timezone. */
diff --git a/calendar/gui/calendar-view-factory.c b/calendar/gui/calendar-view-factory.c
index 563803ae5d..262fe3dd00 100644
--- a/calendar/gui/calendar-view-factory.c
+++ b/calendar/gui/calendar-view-factory.c
@@ -171,10 +171,10 @@ calendar_view_factory_new_view (GalViewFactory *factory, const char *name)
* calendar_view_factory_construct:
* @cal_view_factory: A calendar view factory.
* @view_type: Type of calendar views that the factory will create.
- *
+ *
* Constructs a calendar view factory by setting the type of views it will
* create.
- *
+ *
* Return value: The same value as @cal_view_factory.
**/
CalendarViewFactory *
@@ -196,9 +196,9 @@ calendar_view_factory_construct (CalendarViewFactory *cal_view_factory,
/**
* calendar_view_factory_new:
* @view_type: Type of calendar views that the factory will create.
- *
+ *
* Creates a new factory for calendar views.
- *
+ *
* Return value: A newly-created calendar view factory.
**/
CalendarViewFactory *
diff --git a/calendar/gui/calendar-view.c b/calendar/gui/calendar-view.c
index e75a81052b..ea59c70fd1 100644
--- a/calendar/gui/calendar-view.c
+++ b/calendar/gui/calendar-view.c
@@ -207,9 +207,9 @@ calendar_view_clone (GalView *view)
* @cal_view: A calendar view.
* @view_type: The type of calendar view that this object will represent.
* @title: Title for the view.
- *
+ *
* Constructs a calendar view by setting its view type and title.
- *
+ *
* Return value: The same value as @cal_view.
**/
CalendarView *
@@ -235,9 +235,9 @@ calendar_view_construct (CalendarView *cal_view,
* calendar_view_new:
* @view_type: The type of calendar view that this object will represent.
* @title: Title for the view.
- *
+ *
* Creates a new calendar view object.
- *
+ *
* Return value: A newly-created calendar view.
**/
CalendarView *
@@ -252,9 +252,9 @@ calendar_view_new (GnomeCalendarViewType view_type, const char *title)
/**
* calendar_view_get_view_type:
* @cal_view: A calendar view.
- *
+ *
* Queries the calendar view type of a calendar view.
- *
+ *
* Return value: Type of calendar view.
**/
GnomeCalendarViewType
diff --git a/calendar/gui/comp-editor-factory.c b/calendar/gui/comp-editor-factory.c
index dd508987d4..a7f6a3b493 100644
--- a/calendar/gui/comp-editor-factory.c
+++ b/calendar/gui/comp-editor-factory.c
@@ -71,7 +71,7 @@ typedef struct {
/* Client of the calendar */
ECal *client;
-
+
/* Count editors using this client */
int editor_count;
@@ -245,16 +245,16 @@ edit_existing (OpenClient *oc, const char *uid)
return;
}
-
+
comp = e_cal_component_new ();
if (!e_cal_component_set_icalcomponent (comp, icalcomp)) {
g_object_unref (comp);
icalcomponent_free (icalcomp);
return;
}
-
+
/* Create the appropriate type of editor */
-
+
vtype = e_cal_component_get_vtype (comp);
if (itip_organizer_is_user (comp, oc->client))
flags |= COMP_EDITOR_USER_ORG;
@@ -264,7 +264,7 @@ edit_existing (OpenClient *oc, const char *uid)
case E_CAL_COMPONENT_EVENT:
if (e_cal_component_has_attendees (comp))
flags |= COMP_EDITOR_MEETING;
-
+
editor = COMP_EDITOR (event_editor_new (oc->client, flags));
break;
@@ -292,7 +292,7 @@ static ECalComponent *
get_default_task (ECal *client)
{
ECalComponent *comp;
-
+
comp = cal_comp_task_new_with_defaults (client);
return comp;
@@ -304,7 +304,7 @@ edit_new (OpenClient *oc, const GNOME_Evolution_Calendar_CompEditorFactory_CompE
{
ECalComponent *comp;
CompEditor *editor;
-
+
switch (type) {
case GNOME_Evolution_Calendar_CompEditorFactory_EDITOR_MODE_EVENT:
editor = COMP_EDITOR (event_editor_new (oc->client, FALSE));
@@ -540,7 +540,7 @@ impl_editExisting (PortableServer_Servant servant,
OpenClient *oc;
CompEditor *editor;
ECalSourceType source_type;
-
+
factory = COMP_EDITOR_FACTORY (bonobo_object_from_servant (servant));
switch (corba_type) {
@@ -550,7 +550,7 @@ impl_editExisting (PortableServer_Servant servant,
default:
source_type = E_CAL_SOURCE_TYPE_EVENT;
}
-
+
oc = lookup_open_client (factory, source_type, str_uri, ev);
if (!oc)
return;
@@ -594,7 +594,7 @@ impl_editNew (PortableServer_Servant servant,
CompEditorFactory *factory;
OpenClient *oc;
ECalSourceType source_type;
-
+
factory = COMP_EDITOR_FACTORY (bonobo_object_from_servant (servant));
switch (corba_type) {
@@ -619,9 +619,9 @@ impl_editNew (PortableServer_Servant servant,
/**
* comp_editor_factory_new:
- *
+ *
* Creates a new calendar component editor factory.
- *
+ *
* Return value: A newly-created component editor factory.
**/
CompEditorFactory *
diff --git a/calendar/gui/comp-util.c b/calendar/gui/comp-util.c
index 0be96dbefa..07d06a8f19 100644
--- a/calendar/gui/comp-util.c
+++ b/calendar/gui/comp-util.c
@@ -37,7 +37,7 @@
* cal_comp_util_add_exdate:
* @comp: A calendar component object.
* @itt: Time for the exception.
- *
+ *
* Adds an exception date to the current list of EXDATE properties in a calendar
* component object.
**/
@@ -85,7 +85,7 @@ e_cal_component_compare_tzid (const char *tzid1, const char *tzid2)
* cal_comp_util_compare_event_timezones:
* @comp: A calendar component object.
* @client: A #ECal.
- *
+ *
* Checks if the component uses the given timezone for both the start and
* the end time, or if the UTC offsets of the start and end times are the same
* as in the given zone.
@@ -191,14 +191,14 @@ cal_comp_util_compare_event_timezones (ECalComponent *comp,
* @comp: A calendar component.
* @client: Calendar client where the component purportedly lives.
* @widget: Widget to be used as the basis for UTF8 conversion.
- *
+ *
* Assumming a calendar component with an empty SUMMARY property (as per
* string_is_empty()), asks whether the user wants to delete it based on
* whether the appointment is on the calendar server or not. If the
* component is on the server, this function will present a confirmation
* dialog and delete the component if the user tells it to. If the component
* is not on the server it will just return TRUE.
- *
+ *
* Return value: A result code indicating whether the component
* was not on the server and is to be deleted locally, whether it
* was on the server and the user deleted it, or whether the
@@ -223,7 +223,7 @@ cal_comp_is_on_server (ECalComponent *comp, ECal *client)
* the user.
*/
e_cal_component_get_uid (comp, &uid);
-
+
/*TODO We should not be checking for this here. But since e_cal_util_construct_instance does not
create the instances of all day events, so we dafault to old behaviour */
if (e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_RECURRENCES_NO_MASTER)) {
@@ -246,10 +246,10 @@ cal_comp_is_on_server (ECalComponent *comp, ECal *client)
/**
* cal_comp_event_new_with_defaults:
- *
+ *
* Creates a new VEVENT component and adds any default alarms to it as set in
* the program's configuration values.
- *
+ *
* Return value: A newly-created calendar component.
**/
ECalComponent *
@@ -272,7 +272,7 @@ cal_comp_event_new_with_defaults (ECal *client)
e_cal_component_set_new_vtype (comp, E_CAL_COMPONENT_EVENT);
}
-
+
if (!calendar_config_get_use_default_reminder ())
return comp;
@@ -303,11 +303,11 @@ cal_comp_event_new_with_defaults (ECal *client)
trigger.u.rel_duration.minutes = interval;
break;
- case CAL_HOURS:
+ case CAL_HOURS:
trigger.u.rel_duration.hours = interval;
break;
- case CAL_DAYS:
+ case CAL_DAYS:
trigger.u.rel_duration.days = interval;
break;
@@ -324,7 +324,7 @@ cal_comp_event_new_with_defaults (ECal *client)
}
ECalComponent *
-cal_comp_event_new_with_current_time (ECal *client, gboolean all_day)
+cal_comp_event_new_with_current_time (ECal *client, gboolean all_day)
{
ECalComponent *comp;
struct icaltimetype itt;
@@ -334,23 +334,23 @@ cal_comp_event_new_with_current_time (ECal *client, gboolean all_day)
comp = cal_comp_event_new_with_defaults (client);
g_return_val_if_fail (comp, NULL);
-
+
zone = calendar_config_get_icaltimezone ();
if (all_day) {
itt = icaltime_from_timet_with_zone (time (NULL), 1, zone);
dt.value = &itt;
dt.tzid = icaltimezone_get_tzid (zone);
-
+
e_cal_component_set_dtstart (comp, &dt);
- e_cal_component_set_dtend (comp, &dt);
+ e_cal_component_set_dtend (comp, &dt);
} else {
itt = icaltime_current_time_with_zone (zone);
icaltime_adjust (&itt, 0, 1, -itt.minute, -itt.second);
-
+
dt.value = &itt;
dt.tzid = icaltimezone_get_tzid (zone);
-
+
e_cal_component_set_dtstart (comp, &dt);
icaltime_adjust (&itt, 0, 1, 0, 0);
e_cal_component_set_dtend (comp, &dt);
@@ -367,7 +367,7 @@ cal_comp_task_new_with_defaults (ECal *client)
if (!e_cal_get_default_object (client, &icalcomp, NULL))
icalcomp = icalcomponent_new (ICAL_VTODO_COMPONENT);
-
+
comp = e_cal_component_new ();
if (!e_cal_component_set_icalcomponent (comp, icalcomp)) {
icalcomponent_free (icalcomp);
@@ -386,7 +386,7 @@ cal_comp_memo_new_with_defaults (ECal *client)
if (!e_cal_get_default_object (client, &icalcomp, NULL))
icalcomp = icalcomponent_new (ICAL_VJOURNAL_COMPONENT);
-
+
comp = e_cal_component_new ();
if (!e_cal_component_set_icalcomponent (comp, icalcomp)) {
icalcomponent_free (icalcomp);
@@ -400,7 +400,7 @@ cal_comp_memo_new_with_defaults (ECal *client)
/**
* cal_comp_util_get_n_icons:
* @comp: A calendar component object.
- *
+ *
* Get the number of icons owned by the component.
*
* Returns: the number of icons owned by the component.
diff --git a/calendar/gui/dialogs/alarm-dialog.c b/calendar/gui/dialogs/alarm-dialog.c
index 342f8be472..7267c29380 100644
--- a/calendar/gui/dialogs/alarm-dialog.c
+++ b/calendar/gui/dialogs/alarm-dialog.c
@@ -71,7 +71,7 @@ typedef struct {
/* The client */
ECal *ecal;
-
+
/* Toplevel */
GtkWidget *toplevel;
@@ -89,7 +89,7 @@ typedef struct {
GtkWidget *repeat_unit;
GtkWidget *option_notebook;
-
+
/* Display alarm widgets */
GtkWidget *dalarm_group;
GtkWidget *dalarm_message;
@@ -212,7 +212,7 @@ alarm_to_dialog (Dialog *dialog)
gboolean repeat;
ECalComponentAlarmAction action;
char *email;
- int i;
+ int i;
/* Clean the page */
clear_widgets (dialog);
@@ -232,7 +232,7 @@ alarm_to_dialog (Dialog *dialog)
&& e_cal_get_alarm_email_address (dialog->ecal, &email, NULL)) {
ECalComponentAttendee *a;
GSList attendee_list;
-
+
a = g_new0 (ECalComponentAttendee, 1);
a->value = email;
attendee_list.data = a;
@@ -429,7 +429,7 @@ malarm_widgets_to_alarm (Dialog *dialog, ECalComponentAlarm *alarm)
icalcomponent *icalcomp;
icalproperty *icalprop;
GList *l;
-
+
/* Attendees */
name_selector_model = e_name_selector_peek_model (dialog->name_selector);
e_name_selector_model_peek_section (name_selector_model, section_name, NULL, &destination_store);
@@ -440,7 +440,7 @@ malarm_widgets_to_alarm (Dialog *dialog, ECalComponentAlarm *alarm)
ECalComponentAttendee *a;
dest = l->data;
-
+
a = g_new0 (ECalComponentAttendee, 1);
a->value = e_destination_get_email (dest);
a->cn = e_destination_get_name (dest);
@@ -455,7 +455,7 @@ malarm_widgets_to_alarm (Dialog *dialog, ECalComponentAlarm *alarm)
if (!gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (dialog->malarm_message)))
return;
-
+
/* Description */
text_buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (dialog->malarm_description));
gtk_text_buffer_get_start_iter (text_buffer, &text_iter_start);
@@ -574,11 +574,11 @@ palarm_widgets_to_alarm (Dialog *dialog, ECalComponentAlarm *alarm)
description.value = str;
description.altrep = NULL;
-
+
e_cal_component_alarm_set_description (alarm, &description);
g_free (str);
-
+
/* remove the X-EVOLUTION-NEEDS-DESCRIPTION property, so that
* we don't re-set the alarm's description */
icalcomp = e_cal_component_alarm_get_icalcomponent (alarm);
@@ -621,7 +621,7 @@ populate_widgets_from_alarm (Dialog *dialog)
e_dialog_option_menu_set (dialog->time, E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_START, time_map);
break;
- case E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_END:
+ case E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_END:
e_dialog_option_menu_set (dialog->time, E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_END, time_map);
break;
default:
@@ -790,7 +790,7 @@ get_widgets (Dialog *dialog)
dialog->malarm_addressbook = GW ("malarm-addressbook");
dialog->malarm_message = GW ("malarm-message");
dialog->malarm_description = GW ("malarm-description");
-
+
dialog->palarm_group = GW ("palarm-group");
dialog->palarm_program = GW ("palarm-program");
dialog->palarm_args = GW ("palarm-args");
@@ -821,7 +821,7 @@ get_widgets (Dialog *dialog)
&& dialog->malarm_description
&& dialog->palarm_group
&& dialog->palarm_program
- && dialog->palarm_args);
+ && dialog->palarm_args);
}
#if 0
@@ -910,7 +910,7 @@ check_custom_sound (Dialog *dialog)
{
char *str, *dir;
gboolean sens;
-
+
str = gtk_file_chooser_get_filename (
GTK_FILE_CHOOSER (dialog->aalarm_file_chooser));
@@ -943,7 +943,7 @@ static void
aalarm_attach_changed_cb (GtkWidget *widget, gpointer data)
{
Dialog *dialog = data;
-
+
check_custom_sound (dialog);
}
@@ -954,7 +954,7 @@ check_custom_message (Dialog *dialog)
GtkTextBuffer *text_buffer;
GtkTextIter text_iter_start, text_iter_end;
gboolean sens;
-
+
text_buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (dialog->dalarm_description));
gtk_text_buffer_get_start_iter (text_buffer, &text_iter_start);
gtk_text_buffer_get_end_iter (text_buffer, &text_iter_end);
@@ -982,7 +982,7 @@ static void
dalarm_description_changed_cb (GtkWidget *widget, gpointer data)
{
Dialog *dialog = data;
-
+
check_custom_message (dialog);
}
@@ -991,7 +991,7 @@ check_custom_program (Dialog *dialog)
{
char *str;
gboolean sens;
-
+
str = e_dialog_editable_get (dialog->palarm_program);
sens = str && *str;
@@ -1002,7 +1002,7 @@ static void
palarm_program_changed_cb (GtkWidget *widget, gpointer data)
{
Dialog *dialog = data;
-
+
check_custom_program (dialog);
}
@@ -1037,7 +1037,7 @@ malarm_addresses_changed_cb (GtkWidget *editable,
gpointer data)
{
Dialog *dialog = data;
-
+
check_custom_email (dialog);
}
@@ -1057,7 +1057,7 @@ static void
malarm_description_changed_cb (GtkWidget *widget, gpointer data)
{
Dialog *dialog = data;
-
+
check_custom_email (dialog);
}
@@ -1068,7 +1068,7 @@ action_selection_done_cb (GtkMenuShell *menu_shell, gpointer data)
char *dir;
ECalComponentAlarmAction action;
int page = 0, i;
-
+
action = e_dialog_option_menu_get (dialog->action, action_map);
for (i = 0; action_map[i] != -1 ; i++) {
if (action == action_map[i]) {
@@ -1076,11 +1076,11 @@ action_selection_done_cb (GtkMenuShell *menu_shell, gpointer data)
break;
}
}
-
+
gtk_notebook_set_current_page (
GTK_NOTEBOOK (dialog->option_notebook), page);
- switch (action) {
+ switch (action) {
case E_CAL_COMPONENT_ALARM_AUDIO:
dir = calendar_config_get_dir_path ();
if ( dir && *dir )
@@ -1114,7 +1114,7 @@ init_widgets (Dialog *dialog)
{
GtkWidget *menu;
GtkTextBuffer *text_buffer;
-
+
menu = gtk_option_menu_get_menu (GTK_OPTION_MENU (dialog->action));
g_signal_connect (menu, "selection_done",
G_CALLBACK (action_selection_done_cb),
@@ -1158,12 +1158,12 @@ alarm_dialog_run (GtkWidget *parent, ECal *ecal, ECalComponentAlarm *alarm)
int response_id;
GList *icon_list;
char *gladefile;
-
+
g_return_val_if_fail (alarm != NULL, FALSE);
dialog.alarm = alarm;
dialog.ecal = ecal;
-
+
gladefile = g_build_filename (EVOLUTION_GLADEDIR,
"alarm-dialog.glade",
NULL);
@@ -1201,7 +1201,7 @@ alarm_dialog_run (GtkWidget *parent, ECal *ecal, ECalComponentAlarm *alarm)
gtk_window_set_transient_for (GTK_WINDOW (dialog.toplevel),
GTK_WINDOW (parent));
-
+
response_id = gtk_dialog_run (GTK_DIALOG (dialog.toplevel));
if (response_id == GTK_RESPONSE_OK)
diff --git a/calendar/gui/dialogs/alarm-list-dialog.c b/calendar/gui/dialogs/alarm-list-dialog.c
index de59361519..4b2be10d48 100644
--- a/calendar/gui/dialogs/alarm-list-dialog.c
+++ b/calendar/gui/dialogs/alarm-list-dialog.c
@@ -59,7 +59,7 @@ typedef struct {
/* The list store */
EAlarmList *list_store;
-
+
/* Toplevel */
GtkWidget *toplevel;
@@ -68,7 +68,7 @@ typedef struct {
GtkWidget *edit;
GtkWidget *delete;
GtkWidget *box;
-
+
} Dialog;
/* Gets the widgets from the XML file and returns TRUE if they are all available. */
@@ -83,7 +83,7 @@ get_widgets (Dialog *dialog)
dialog->box = GW ("vbox53");
dialog->list = GW ("list");
- dialog->add = GW ("add");
+ dialog->add = GW ("add");
dialog->edit = GW ("edit");
dialog->delete = GW ("delete");
@@ -130,7 +130,7 @@ add_clicked_cb (GtkButton *button, gpointer data)
GtkTreeIter iter;
icalcomponent *icalcomp;
icalproperty *icalprop;
-
+
view = GTK_TREE_VIEW (dialog->list);
alarm = e_cal_component_alarm_new ();
@@ -139,7 +139,7 @@ add_clicked_cb (GtkButton *button, gpointer data)
icalprop = icalproperty_new_x ("1");
icalproperty_set_x_name (icalprop, "X-EVOLUTION-NEEDS-DESCRIPTION");
icalcomponent_add_property (icalcomp, icalprop);
-
+
if (alarm_dialog_run (dialog->toplevel, dialog->ecal, alarm)) {
e_alarm_list_append (dialog->list_store, &iter, alarm);
gtk_tree_selection_select_iter (gtk_tree_view_get_selection (view), &iter);
@@ -271,9 +271,9 @@ alarm_list_dialog_run (GtkWidget *parent, ECal *ecal, EAlarmList *list_store)
int response_id;
GList *icon_list;
char *gladefile;
-
+
dialog.ecal = ecal;
- dialog.list_store = list_store;
+ dialog.list_store = list_store;
gladefile = g_build_filename (EVOLUTION_GLADEDIR,
"alarm-list-dialog.glade",
@@ -294,7 +294,7 @@ alarm_list_dialog_run (GtkWidget *parent, ECal *ecal, EAlarmList *list_store)
init_widgets (&dialog);
sensitize_buttons (&dialog);
-
+
gtk_widget_ensure_style (dialog.toplevel);
gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (dialog.toplevel)->vbox), 0);
gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (dialog.toplevel)->action_area), 12);
@@ -323,10 +323,10 @@ alarm_list_dialog_peek (ECal *ecal, EAlarmList *list_store)
{
Dialog *dialog;
char *gladefile;
-
+
dialog = (Dialog *)g_new (Dialog, 1);
dialog->ecal = ecal;
- dialog->list_store = list_store;
+ dialog->list_store = list_store;
gladefile = g_build_filename (EVOLUTION_GLADEDIR,
"alarm-list-dialog.glade",
@@ -347,7 +347,7 @@ alarm_list_dialog_peek (ECal *ecal, EAlarmList *list_store)
init_widgets (dialog);
sensitize_buttons (dialog);
-
+
g_object_unref (dialog->xml);
/* Free the other stuff when the parent really gets destroyed. */
diff --git a/calendar/gui/dialogs/cal-attachment-select-file.c b/calendar/gui/dialogs/cal-attachment-select-file.c
index aa57f95dc7..c8f5e89057 100644
--- a/calendar/gui/dialogs/cal-attachment-select-file.c
+++ b/calendar/gui/dialogs/cal-attachment-select-file.c
@@ -58,9 +58,9 @@ run_selector(CompEditor *editor, const char *title, guint32 flags, gboolean *sho
GtkWidget *showinline = NULL;
char *path;
GList *icon_list;
-
+
path = g_object_get_data ((GObject *) editor, "attach_path");
-
+
if (flags & SELECTOR_MODE_SAVE)
selection = gtk_file_chooser_dialog_new (title,
NULL,
@@ -75,49 +75,49 @@ run_selector(CompEditor *editor, const char *title, guint32 flags, gboolean *sho
GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
GTK_STOCK_OPEN, GTK_RESPONSE_OK,
NULL);
-
+
gtk_dialog_set_default_response (GTK_DIALOG (selection), GTK_RESPONSE_OK);
gtk_file_chooser_set_local_only (GTK_FILE_CHOOSER (selection), FALSE);
-
+
if ((flags & SELECTOR_MODE_SAVE) == 0)
gtk_file_chooser_set_select_multiple ((GtkFileChooser *) selection, (flags & SELECTOR_MODE_MULTI));
-
+
/* restore last path used */
if (!path)
gtk_file_chooser_set_current_folder (GTK_FILE_CHOOSER (selection), g_get_home_dir ());
else
gtk_file_chooser_set_current_folder (GTK_FILE_CHOOSER (selection), path);
-
+
if (showinline_p) {
showinline = gtk_check_button_new_with_mnemonic (_("_Suggest automatic display of attachment"));
gtk_widget_show (showinline);
gtk_file_chooser_set_extra_widget (GTK_FILE_CHOOSER (selection), showinline);
}
-
+
gtk_window_set_transient_for ((GtkWindow *) selection, (GtkWindow *) editor);
gtk_window_set_wmclass ((GtkWindow *) selection, "fileselection", "Evolution:editor");
gtk_window_set_modal ((GtkWindow *) selection, TRUE);
-
+
icon_list = e_icon_factory_get_icon_list ("mail-message-new");
if (icon_list) {
gtk_window_set_icon_list (GTK_WINDOW (selection), icon_list);
g_list_foreach (icon_list, (GFunc) g_object_unref, NULL);
g_list_free (icon_list);
}
-
+
if (gtk_dialog_run ((GtkDialog *) selection) == GTK_RESPONSE_OK) {
if (showinline_p)
*showinline_p = gtk_toggle_button_get_active ((GtkToggleButton *) showinline);
-
+
path = g_path_get_dirname (gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (selection)));
-
+
g_object_set_data_full ((GObject *) editor, "attach_path", g_strdup_printf ("%s/", path), g_free);
g_free (path);
} else {
gtk_widget_destroy (selection);
selection = NULL;
}
-
+
return selection;
}
@@ -139,7 +139,7 @@ comp_editor_select_file (CompEditor *editor, const char *title, gboolean save_mo
guint32 flags = save_mode ? SELECTOR_MODE_SAVE : SELECTOR_MODE_MULTI;
GtkWidget *selection;
char *name = NULL;
-
+
selection = run_selector (editor, title, flags, NULL);
if (selection) {
name = g_strdup (gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (selection)));
@@ -154,15 +154,15 @@ comp_editor_select_file_attachments (CompEditor *editor, gboolean *showinline_p)
{
GtkWidget *selection;
GPtrArray *list = NULL;
-
+
selection = run_selector (editor, _("Attach file(s)"), SELECTOR_MODE_MULTI, showinline_p);
-
+
if (selection) {
GSList *l, *n;
-
+
if ((l = gtk_file_chooser_get_uris (GTK_FILE_CHOOSER (selection)))) {
list = g_ptr_array_new ();
-
+
while (l) {
n = l->next;
g_ptr_array_add (list, l->data);
@@ -170,10 +170,10 @@ comp_editor_select_file_attachments (CompEditor *editor, gboolean *showinline_p)
l = n;
}
}
-
+
gtk_widget_destroy (selection);
}
-
+
return list;
}
diff --git a/calendar/gui/dialogs/cal-prefs-dialog.c b/calendar/gui/dialogs/cal-prefs-dialog.c
index afea9a8df2..a916359b2b 100644
--- a/calendar/gui/dialogs/cal-prefs-dialog.c
+++ b/calendar/gui/dialogs/cal-prefs-dialog.c
@@ -124,11 +124,11 @@ timezone_changed (GtkWidget *widget, CalendarPrefsDialog *prefs)
zone = e_timezone_entry_get_timezone (E_TIMEZONE_ENTRY (prefs->timezone));
icalcomp = icaltimezone_get_component (zone);
- if (!(dl_comp = icalcomponent_get_first_component (icalcomp, ICAL_XDAYLIGHT_COMPONENT)))
+ if (!(dl_comp = icalcomponent_get_first_component (icalcomp, ICAL_XDAYLIGHT_COMPONENT)))
gtk_widget_set_sensitive ((GtkWidget *) prefs->daylight_saving, FALSE);
- else
+ else
gtk_widget_set_sensitive ((GtkWidget *) prefs->daylight_saving, TRUE);
-
+
calendar_config_set_timezone (icaltimezone_get_location (zone));
}
@@ -334,7 +334,7 @@ alarms_selection_changed (ESourceSelector *selector, CalendarPrefsDialog *prefs)
alarm = e_source_get_property (source, "alarm");
if (alarm && !g_ascii_strcasecmp (alarm, "never"))
continue;
-
+
g_message ("Unsetting for %s", e_source_peek_name (source));
e_source_set_property (source, "alarm", "false");
}
@@ -356,7 +356,7 @@ alarms_selection_changed (ESourceSelector *selector, CalendarPrefsDialog *prefs)
e_source_selector_free_selection (selection);
/* FIXME show an error if this fails? */
- e_source_list_sync (source_list, NULL);
+ e_source_list_sync (source_list, NULL);
}
static void
@@ -406,7 +406,7 @@ setup_changes (CalendarPrefsDialog *prefs)
g_signal_connect (G_OBJECT (prefs->default_reminder_units), "changed", G_CALLBACK (default_reminder_units_changed), prefs);
g_signal_connect (G_OBJECT (prefs->alarm_list_widget), "selection_changed", G_CALLBACK (alarms_selection_changed), prefs);
-
+
g_signal_connect (G_OBJECT (prefs->template_url), "changed", G_CALLBACK (template_url_changed), prefs);
}
@@ -506,14 +506,14 @@ show_config (CalendarPrefsDialog *prefs)
g_free (location);
icalcomp = icaltimezone_get_component (zone);
- if (!(dl_comp = icalcomponent_get_first_component (icalcomp, ICAL_XDAYLIGHT_COMPONENT)))
+ if (!(dl_comp = icalcomponent_get_first_component (icalcomp, ICAL_XDAYLIGHT_COMPONENT)))
gtk_widget_set_sensitive ((GtkWidget *) prefs->daylight_saving, FALSE);
- else
+ else
gtk_widget_set_sensitive ((GtkWidget *) prefs->daylight_saving, TRUE);
-
+
set = calendar_config_get_daylight_saving ();
gtk_toggle_button_set_active ((GtkToggleButton *) prefs->daylight_saving, set);
-
+
/* Working Days. */
working_days = calendar_config_get_working_days ();
mask = 1 << 0;
@@ -665,7 +665,7 @@ calendar_prefs_dialog_construct (CalendarPrefsDialog *prefs)
/* Alarms tab */
prefs->scrolled_window = glade_xml_get_widget (gui, "calendar-source-scrolled-window");
-
+
/* Free/Busy tab */
prefs->template_url = glade_xml_get_widget (gui, "template_url");
target = e_cal_config_target_new_prefs (ec, prefs->gconf);
diff --git a/calendar/gui/dialogs/cal-prefs-dialog.h b/calendar/gui/dialogs/cal-prefs-dialog.h
index d6f84aae4d..d0df6e4a12 100644
--- a/calendar/gui/dialogs/cal-prefs-dialog.h
+++ b/calendar/gui/dialogs/cal-prefs-dialog.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* David Trowbridge <trowbrds cs colorado edu>
* Damon Chaplin <damon@ximian.com>
*
* Copyright (C) 2005 Novell, Inc. (www.novell.com)
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/dialogs/calendar-setup.c b/calendar/gui/dialogs/calendar-setup.c
index a7b2e15b80..3f6bcf4e45 100644
--- a/calendar/gui/dialogs/calendar-setup.c
+++ b/calendar/gui/dialogs/calendar-setup.c
@@ -243,15 +243,15 @@ eccp_get_source_name (EConfig *ec, EConfigItem *item, struct _GtkWidget *parent,
return entry;
}
-static void
+static void
offline_status_changed_cb (GtkWidget *widget, CalendarSourceDialog *sdialog)
{
-
+
if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)))
e_source_set_property (sdialog->source, "offline_sync", "1");
- else
- e_source_set_property (sdialog->source, "offline_sync", "0");
-
+ else
+ e_source_set_property (sdialog->source, "offline_sync", "0");
+
}
static GtkWidget *
@@ -268,9 +268,9 @@ eccp_general_offline (EConfig *ec, EConfigItem *item, struct _GtkWidget *parent,
else {
row = ((GtkTable*)parent)->nrows;
- if (sdialog->source_type == E_CAL_SOURCE_TYPE_EVENT)
+ if (sdialog->source_type == E_CAL_SOURCE_TYPE_EVENT)
offline_setting = gtk_check_button_new_with_mnemonic (_("Cop_y calendar contents locally for offline operation"));
- else if (sdialog->source_type == E_CAL_SOURCE_TYPE_TODO)
+ else if (sdialog->source_type == E_CAL_SOURCE_TYPE_TODO)
offline_setting = gtk_check_button_new_with_mnemonic (_("Cop_y task list contents locally for offline operation"));
else if(sdialog->source_type == E_CAL_SOURCE_TYPE_JOURNAL)
offline_setting = gtk_check_button_new_with_mnemonic (_("Cop_y memo list contents locally for offline operation"));
@@ -280,7 +280,7 @@ eccp_general_offline (EConfig *ec, EConfigItem *item, struct _GtkWidget *parent,
gtk_table_attach (GTK_TABLE (parent), offline_setting, 1, 2, row, row+1, GTK_EXPAND | GTK_FILL, 0, 0, 0);
}
-
+
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (offline_setting), (offline_sync && g_str_equal (offline_sync, "1")) ? TRUE : FALSE);
if (is_local)
gtk_widget_hide (offline_setting);
@@ -397,7 +397,7 @@ static ECalConfigItem ecmp_items[] = {
{ 0 },
};
-/**
+/**
* cs_load_sources:
* @sdialog: dialog where to load sources list
* @conf_key: configuration key where to get sources' list
@@ -463,7 +463,7 @@ calendar_setup_edit_calendar (struct _GtkWindow *parent, ESource *source, ESourc
e_source_set_absolute_uri (sdialog->source, NULL);
e_source_set_group (sdialog->source, sdialog->source_group);
- sdialog->source_type = E_CAL_SOURCE_TYPE_EVENT;
+ sdialog->source_type = E_CAL_SOURCE_TYPE_EVENT;
sdialog->config = ec = e_cal_config_new (E_CONFIG_BOOK, "org.gnome.evolution.calendar.calendarProperties");
for (i = 0; eccp_items[i].path; i++)
items = g_slist_prepend (items, &eccp_items[i]);
@@ -478,7 +478,7 @@ calendar_setup_edit_calendar (struct _GtkWindow *parent, ESource *source, ESourc
sdialog->window = e_config_create_window ((EConfig *)ec, NULL, _("Calendar Properties"));
else
sdialog->window = e_config_create_window ((EConfig *)ec, NULL, _("New Calendar"));
-
+
/* forces initial validation */
if (!sdialog->original_source)
e_config_target_changed ((EConfig *)ec, E_CONFIG_TARGET_CHANGED_STATE);
diff --git a/calendar/gui/dialogs/cancel-comp.c b/calendar/gui/dialogs/cancel-comp.c
index ffecf671c8..93dfc1d4b1 100644
--- a/calendar/gui/dialogs/cancel-comp.c
+++ b/calendar/gui/dialogs/cancel-comp.c
@@ -33,7 +33,7 @@
/* is_past_event:
- *
+ *
* returns TRUE if @comp is in the past, FALSE otherwise.
* Comparision is based only on date part, time part is ignored.
*/
@@ -56,10 +56,10 @@ is_past_event (ECalComponent *comp)
/**
* cancel_component_dialog:
- *
+ *
* Pops up a dialog box asking the user whether he wants to send a
* cancel and delete an iTip/iMip message
- *
+ *
* Return value: TRUE if the user clicked Yes, FALSE otherwise.
**/
gboolean
@@ -67,12 +67,12 @@ cancel_component_dialog (GtkWindow *parent, ECal *client, ECalComponent *comp, g
{
ECalComponentVType vtype;
const char *id;
-
+
if (deleting && e_cal_get_save_schedules (client))
return TRUE;
-
+
vtype = e_cal_component_get_vtype (comp);
-
+
switch (vtype) {
case E_CAL_COMPONENT_EVENT:
if (is_past_event (comp)) {
@@ -103,7 +103,7 @@ cancel_component_dialog (GtkWindow *parent, ECal *client, ECalComponent *comp, g
g_message (G_STRLOC ": Cannot handle object of type %d", vtype);
return FALSE;
}
-
+
if (e_error_run (parent, id, NULL) == GTK_RESPONSE_YES)
return TRUE;
else
diff --git a/calendar/gui/dialogs/changed-comp.c b/calendar/gui/dialogs/changed-comp.c
index 6afae1a6b3..bfc89604e3 100644
--- a/calendar/gui/dialogs/changed-comp.c
+++ b/calendar/gui/dialogs/changed-comp.c
@@ -37,10 +37,10 @@
* @comp: A calendar component
* @deleted: Whether the object is being deleted or updated
* @changed: Whether or not the user has made changes
- *
+ *
* Pops up a dialog box asking the user whether changes made (if any)
* should be thrown away because the item has been updated elsewhere
- *
+ *
* Return value: TRUE if the user clicked Yes, FALSE otherwise.
**/
gboolean
@@ -51,7 +51,7 @@ changed_component_dialog (GtkWindow *parent, ECalComponent *comp, gboolean delet
char *str;
gint response;
GList *icon_list;
-
+
vtype = e_cal_component_get_vtype (comp);
if (deleted) {
@@ -76,7 +76,7 @@ changed_component_dialog (GtkWindow *parent, ECalComponent *comp, gboolean delet
if (changed)
str = g_strdup_printf (_("%s You have made changes. Forget those changes and close the editor?"), str);
else
- str = g_strdup_printf (_("%s You have made no changes, close the editor?"), str);
+ str = g_strdup_printf (_("%s You have made no changes, close the editor?"), str);
} else {
switch (vtype) {
@@ -100,20 +100,20 @@ changed_component_dialog (GtkWindow *parent, ECalComponent *comp, gboolean delet
if (changed)
str = g_strdup_printf (_("%s You have made changes. Forget those changes and update the editor?"), str);
else
- str = g_strdup_printf (_("%s You have made no changes, update the editor?"), str);
+ str = g_strdup_printf (_("%s You have made no changes, update the editor?"), str);
}
-
+
dialog = gtk_message_dialog_new (parent, GTK_DIALOG_MODAL,
GTK_MESSAGE_QUESTION,
GTK_BUTTONS_YES_NO, str);
-
+
icon_list = e_icon_factory_get_icon_list ("stock_calendar");
if (icon_list) {
gtk_window_set_icon_list (GTK_WINDOW (dialog), icon_list);
g_list_foreach (icon_list, (GFunc) g_object_unref, NULL);
g_list_free (icon_list);
}
-
+
response = gtk_dialog_run (GTK_DIALOG (dialog));
gtk_widget_destroy (dialog);
diff --git a/calendar/gui/dialogs/comp-editor-page.c b/calendar/gui/dialogs/comp-editor-page.c
index 897764dfa8..174f7eb50d 100644
--- a/calendar/gui/dialogs/comp-editor-page.c
+++ b/calendar/gui/dialogs/comp-editor-page.c
@@ -58,10 +58,10 @@ static guint comp_editor_page_signals[LAST_SIGNAL];
/**
* comp_editor_page_get_type:
- *
+ *
* Registers the #CompEditorPage class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the #CompEditorPage class.
**/
GtkType
@@ -143,23 +143,23 @@ comp_editor_page_class_init (CompEditorPageClass *class)
NULL, NULL,
g_cclosure_marshal_VOID__OBJECT,
G_TYPE_NONE, 1, G_TYPE_OBJECT);
- comp_editor_page_signals[FOCUS_IN] =
+ comp_editor_page_signals[FOCUS_IN] =
g_signal_new ("focus_in",
G_TYPE_FROM_CLASS (class),
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (CompEditorPageClass, focus_in),
NULL, NULL,
g_cclosure_marshal_VOID__POINTER,
- G_TYPE_NONE, 1, G_TYPE_POINTER);
- comp_editor_page_signals[FOCUS_OUT] =
+ G_TYPE_NONE, 1, G_TYPE_POINTER);
+ comp_editor_page_signals[FOCUS_OUT] =
g_signal_new ("focus_out",
G_TYPE_FROM_CLASS (class),
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (CompEditorPageClass, focus_out),
NULL, NULL,
g_cclosure_marshal_VOID__POINTER,
- G_TYPE_NONE, 1, G_TYPE_POINTER);
-
+ G_TYPE_NONE, 1, G_TYPE_POINTER);
+
class->changed = NULL;
class->summary_changed = NULL;
class->dates_changed = NULL;
@@ -213,9 +213,9 @@ comp_editor_page_destroy (GtkObject *object)
/**
* comp_editor_page_get_widget:
* @page: An editor page.
- *
+ *
* Queries the main widget of an editor page.
- *
+ *
* Return value: The widget that is the page's upper container. It should
* normally be inserted in a notebook widget.
**/
@@ -232,7 +232,7 @@ comp_editor_page_get_widget (CompEditorPage *page)
/**
* comp_editor_page_focus_main_widget:
* @page: An editor page.
- *
+ *
* Makes an editor page focus its main widget. This is used by the component
* editor when it first pops up so that it can focus the main widget in the
* first page.
@@ -251,7 +251,7 @@ comp_editor_page_focus_main_widget (CompEditorPage *page)
* comp_editor_page_fill_widgets:
* @page: An editor page.
* @comp: A calendar component.
- *
+ *
* Fills the widgets of an editor page with the data from a calendar component.
**/
gboolean
@@ -268,7 +268,7 @@ comp_editor_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
* comp_editor_page_fill_component:
* @page: An editor page.
* @comp: A calendar component.
- *
+ *
* Takes the data from the widgets of an editor page and sets it on a calendar
* component, replacing the contents of the properties that the editor page
* knows how to manipulate.
@@ -338,7 +338,7 @@ comp_editor_page_set_e_cal (CompEditorPage *page, ECal *client)
* comp_editor_page_set_summary:
* @page: An editor page
* @summary: The text of the new summary value
- *
+ *
* Sets the summary value for this group of widgets
**/
void
@@ -373,7 +373,7 @@ comp_editor_page_unset_focused_widget (CompEditorPage *page, GtkWidget *widget)
* @page: An editor page
* @widget: The widget that has the current focus
**/
-void
+void
comp_editor_page_set_focused_widget (CompEditorPage *page, GtkWidget *widget)
{
g_return_if_fail (page!= NULL);
@@ -388,7 +388,7 @@ comp_editor_page_set_focused_widget (CompEditorPage *page, GtkWidget *widget)
* comp_editor_page_set_dates:
* @page: An editor page
* @dates: A collection of various dates in time_t format
- *
+ *
* Sets the date values for this group of widgets
**/
void
@@ -404,7 +404,7 @@ comp_editor_page_set_dates (CompEditorPage *page, CompEditorPageDates *dates)
/**
* comp_editor_page_notify_changed:
* @page: An editor page.
- *
+ *
* Makes an editor page emit the "changed" signal. This is meant to be
* used only by page implementations.
**/
@@ -419,9 +419,9 @@ comp_editor_page_notify_changed (CompEditorPage *page)
/**
* comp_editor_page_notify_needs_send:
- * @page:
- *
- *
+ * @page:
+ *
+ *
**/
void
comp_editor_page_notify_needs_send (CompEditorPage *page)
@@ -429,13 +429,13 @@ comp_editor_page_notify_needs_send (CompEditorPage *page)
g_return_if_fail (page != NULL);
g_return_if_fail (IS_COMP_EDITOR_PAGE (page));
- gtk_signal_emit (GTK_OBJECT (page), comp_editor_page_signals[NEEDS_SEND]);
+ gtk_signal_emit (GTK_OBJECT (page), comp_editor_page_signals[NEEDS_SEND]);
}
/**
* comp_editor_page_notify_summary_changed:
* @page: An editor page.
- *
+ *
* Makes an editor page emit the "summary_changed" signal. This is meant to be
* used only by page implementations.
**/
@@ -446,7 +446,7 @@ comp_editor_page_notify_summary_changed (CompEditorPage *page,
g_return_if_fail (page != NULL);
g_return_if_fail (IS_COMP_EDITOR_PAGE (page));
-
+
gtk_signal_emit (GTK_OBJECT (page),
comp_editor_page_signals[SUMMARY_CHANGED],
summary);
@@ -455,7 +455,7 @@ comp_editor_page_notify_summary_changed (CompEditorPage *page,
/**
* comp_editor_page_notify_dates_changed:
* @page: An editor page.
- *
+ *
* Makes an editor page emit the "dates_changed" signal. This is meant to be
* used only by page implementations.
**/
@@ -474,7 +474,7 @@ comp_editor_page_notify_dates_changed (CompEditorPage *page,
/**
* comp_editor_page_notify_client_changed:
* @page: An editor page.
- *
+ *
* Makes an editor page emit the "client_changed" signal. This is meant to be
* used only by page implementations.
**/
diff --git a/calendar/gui/dialogs/comp-editor-util.c b/calendar/gui/dialogs/comp-editor-util.c
index 8aa7bbd734..dabf01745e 100644
--- a/calendar/gui/dialogs/comp-editor-util.c
+++ b/calendar/gui/dialogs/comp-editor-util.c
@@ -43,7 +43,7 @@
* comp_editor_dates:
* @dates: A structure to be filled out with dates of a component
* @comp: The component to extract the dates from
- *
+ *
* Extracts the dates from the calendar component into the
* CompEditorPageDates structure. Call comp_editor_free_dates() to free the
* results.
@@ -57,7 +57,7 @@ comp_editor_dates (CompEditorPageDates *dates, ECalComponent *comp)
dates->end = NULL;
dates->due = NULL;
dates->complete = NULL;
-
+
/* Note that the ECalComponentDateTime's returned contain allocated
icaltimetype and tzid values, so we just take over ownership of
those. */
@@ -119,7 +119,7 @@ write_label_piece (struct icaltimetype *tt, char *buffer, int size,
struct tm tmp_tm = { 0 };
struct icaltimetype tt_copy = *tt;
int len;
-
+
/* FIXME: May want to convert the time to an appropriate zone. */
if (stext != NULL)
@@ -145,7 +145,7 @@ write_label_piece (struct icaltimetype *tt, char *buffer, int size,
len = strlen (buffer);
e_time_format_date_and_time (&tmp_tm,
- calendar_config_get_24_hour_format (),
+ calendar_config_get_24_hour_format (),
!tt_copy.is_date, FALSE,
&buffer[len], size - len);
if (etext != NULL)
@@ -156,7 +156,7 @@ write_label_piece (struct icaltimetype *tt, char *buffer, int size,
* comp_editor_date_label:
* @dates: The dates to use in constructing a label
* @label: The label whose text is to be set
- *
+ *
* Set the text of a label based on the dates available and the user's
* formatting preferences
**/
@@ -192,7 +192,7 @@ comp_editor_date_label (CompEditorPageDates *dates, GtkWidget *label)
else
write_label_piece (dates->complete, buffer, 1024, _("Completed "), NULL, NULL);
}
-
+
if (due_set && dates->complete == NULL) {
if (start_set)
write_label_piece (dates->due->value, buffer, 1024, _(" (Due "), ")", NULL);
@@ -207,7 +207,7 @@ static void
date_edit_destroy_cb (EDateEdit *date_edit, gpointer data)
{
EDateEditConfig *config = data;
-
+
g_object_unref (config);
}
@@ -218,9 +218,9 @@ date_edit_destroy_cb (EDateEdit *date_edit, gpointer data)
* @make_time_insensitive: Whether the time field is made insensitive rather
* than hiding it. This is useful if you want to preserve the layout of the
* widgets.
- *
+ *
* Creates a new #EDateEdit widget, configured using the calendar's preferences.
- *
+ *
* Return value: A newly-created #EDateEdit widget.
**/
GtkWidget *
@@ -229,7 +229,7 @@ comp_editor_new_date_edit (gboolean show_date, gboolean show_time,
{
EDateEdit *dedit;
EDateEditConfig *config;
-
+
dedit = E_DATE_EDIT (e_date_edit_new ());
e_date_edit_set_show_date (dedit, show_date);
@@ -239,10 +239,10 @@ comp_editor_new_date_edit (gboolean show_date, gboolean show_time,
#else
e_date_edit_set_make_time_insensitive (dedit, FALSE);
#endif
-
+
config = e_date_edit_config_new (dedit);
g_signal_connect (G_OBJECT (dedit), "destroy", G_CALLBACK (date_edit_destroy_cb), config);
-
+
return GTK_WIDGET (dedit);
}
@@ -280,10 +280,10 @@ comp_editor_get_current_time (GtkObject *object, gpointer data)
/**
* comp_editor_strip_categories:
* @categories: A string of category names entered by the user.
- *
+ *
* Takes a string of the form "categ, categ, categ, ..." and removes the
* whitespace between categories to result in "categ,categ,categ,..."
- *
+ *
* Return value: The category names stripped of surrounding whitespace
* and separated with commas.
**/
@@ -329,7 +329,7 @@ comp_editor_strip_categories (const char *categories)
start = p;
end = p;
} else
- end = g_utf8_next_char(p) - 1;
+ end = g_utf8_next_char(p) - 1;
}
}
diff --git a/calendar/gui/dialogs/comp-editor.c b/calendar/gui/dialogs/comp-editor.c
index e2ca1b5730..2b2b797775 100644
--- a/calendar/gui/dialogs/comp-editor.c
+++ b/calendar/gui/dialogs/comp-editor.c
@@ -81,7 +81,7 @@
struct _CompEditorPrivate {
/* Client to use */
ECal *client;
-
+
/* Source client (where comp lives currently) */
ECal *source_client;
@@ -98,7 +98,7 @@ struct _CompEditorPrivate {
GtkNotebook *notebook;
/* Focussed Widget*/
- GtkWidget *focused_entry;
+ GtkWidget *focused_entry;
/* Attachment handling */
GtkWidget *attachment_bar;
@@ -109,20 +109,20 @@ struct _CompEditorPrivate {
GtkWidget *attachment_expander_num;
guint32 attachment_bar_visible : 1;
-
- /* TODO use this flags for setting all the boolean variables
+
+ /* TODO use this flags for setting all the boolean variables
below */
CompEditorFlags flags;
-
+
gboolean changed;
gboolean needs_send;
CalObjModType mod;
-
+
gboolean existing_org;
gboolean user_org;
gboolean is_group_item;
-
+
gboolean warned;
char *help_section;
@@ -212,12 +212,12 @@ attach_message(CompEditor *editor, CamelMimeMessage *msg)
g_free(desc);
} else
camel_mime_part_set_description(mime_part, _("Attached message"));
-
+
i = e_attachment_bar_get_num_attachments (E_ATTACHMENT_BAR (editor->priv->attachment_bar));
i++;
filename = g_strdup_printf ("email%d",i);
camel_mime_part_set_filename (mime_part, filename);
-
+
camel_medium_set_content_object((CamelMedium *)mime_part, (CamelDataWrapper *)msg);
camel_mime_part_set_content_type(mime_part, "message/rfc822");
e_attachment_bar_attach_mime_part(E_ATTACHMENT_BAR(editor->priv->attachment_bar), mime_part);
@@ -259,7 +259,7 @@ drop_action(CompEditor *editor, GdkDragContext *context, guint32 action, GtkSele
stream = camel_stream_mem_new ();
camel_stream_write (stream, (char *)selection->data, selection->length);
camel_stream_reset (stream);
-
+
msg = camel_mime_message_new ();
if (camel_data_wrapper_construct_from_stream((CamelDataWrapper *)msg, stream) != -1) {
attach_message(editor, msg);
@@ -276,7 +276,7 @@ drop_action(CompEditor *editor, GdkDragContext *context, guint32 action, GtkSele
tmp = g_strndup ((char *)selection->data, selection->length);
urls = g_strsplit (tmp, "\n", 0);
g_free (tmp);
-
+
for (i = 0; urls[i] != NULL; i++) {
str = g_strstrip (urls[i]);
if (urls[i][0] == '#') {
@@ -309,7 +309,7 @@ drop_action(CompEditor *editor, GdkDragContext *context, guint32 action, GtkSele
g_free (str);
}
}
-
+
g_free (urls);
success = TRUE;
break;
@@ -317,15 +317,15 @@ drop_action(CompEditor *editor, GdkDragContext *context, guint32 action, GtkSele
case DND_TYPE_TEXT_CALENDAR:
content_type = gdk_atom_name (selection->type);
d(printf ("dropping a %s\n", content_type));
-
+
mime_part = camel_mime_part_new ();
camel_mime_part_set_content (mime_part, (char *)selection->data, selection->length, content_type);
camel_mime_part_set_disposition (mime_part, "inline");
-
+
e_attachment_bar_attach_mime_part
(E_ATTACHMENT_BAR (editor->priv->attachment_bar),
mime_part);
-
+
camel_object_unref (mime_part);
g_free (content_type);
@@ -393,7 +393,7 @@ drop_action(CompEditor *editor, GdkDragContext *context, guint32 action, GtkSele
desc = g_strdup_printf(ngettext("Attached message", "%d attached messages", uids->len), uids->len);
camel_mime_part_set_description(mime_part, desc);
g_free(desc);
-
+
num = e_attachment_bar_get_num_attachments (E_ATTACHMENT_BAR (editor->priv->attachment_bar));
num++;
filename = g_strdup_printf ("email%d", num);
@@ -591,23 +591,23 @@ listen_for_changes (CompEditor *editor)
G_SIGNAL_MATCH_DATA,
0, 0, NULL, NULL,
editor);
-
+
g_object_unref (priv->view);
priv->view = NULL;
}
-
+
/* Listen for changes */
if (priv->comp)
e_cal_component_get_uid (priv->comp, &uid);
if (uid) {
char *query;
-
+
query = g_strdup_printf ("(uid? \"%s\")", uid);
e_cal_get_query (priv->source_client, query, &priv->view, NULL);
g_free (query);
}
-
+
if (priv->view) {
g_signal_connect (priv->view, "objects_modified",
G_CALLBACK (obj_modified_cb), editor);
@@ -654,9 +654,9 @@ get_attachment_list (CompEditor *editor)
char *attach_file_url;
char *safe_fname, *utf8_safe_fname;
char *filename;
-
+
wrapper = camel_medium_get_content_object (CAMEL_MEDIUM (p->data));
-
+
/* Extract the content from the stream and write it down
* as a mime part file into the directory denoting the
* calendar source */
@@ -682,7 +682,7 @@ get_attachment_list (CompEditor *editor)
g_free (filename);
continue;
}
-
+
if (camel_data_wrapper_decode_to_stream (wrapper, (CamelStream *) stream) == -1) {
g_free (attach_file_url);
camel_stream_close (stream);
@@ -747,7 +747,7 @@ save_comp (CompEditor *editor)
/* retrieve all timezones */
comp_editor_page_fill_timezones (l->data, timezones);
}
-
+
/* If we are not the organizer, we don't update the sequence number */
if (!e_cal_component_has_organizer (clone) || itip_organizer_is_user (clone, priv->client) || itip_sentby_is_user (clone))
e_cal_component_commit_sequence (clone);
@@ -762,11 +762,11 @@ save_comp (CompEditor *editor)
/* send timezones */
g_hash_table_foreach (timezones, (GHFunc) send_timezone, editor);
g_hash_table_destroy (timezones);
-
+
/* Attachments*/
-
+
e_cal_component_set_attachment_list (priv->comp,
- get_attachment_list (editor));
+ get_attachment_list (editor));
icalcomp = e_cal_component_get_icalcomponent (priv->comp);
/* send the component to the server */
if (!cal_comp_is_on_server (priv->comp, priv->client)) {
@@ -812,7 +812,7 @@ save_comp (CompEditor *editor)
if (delay_set)
return TRUE;
}
-
+
if (!result) {
GtkWidget *dialog;
@@ -835,7 +835,7 @@ save_comp (CompEditor *editor)
e_cal_get_source (priv->source_client)) &&
cal_comp_is_on_server (priv->comp, priv->source_client)) {
/* Comp found a new home. Remove it from old one. */
-
+
if (e_cal_component_is_instance (priv->comp) || e_cal_component_has_recurrences (priv->comp))
e_cal_remove_object_with_mod (priv->source_client, orig_uid, NULL,
CALOBJ_MOD_ALL, NULL);
@@ -846,7 +846,7 @@ save_comp (CompEditor *editor)
* again this session. */
g_object_unref (priv->source_client);
priv->source_client = g_object_ref (priv->client);
-
+
listen_for_changes (editor);
}
@@ -864,19 +864,19 @@ save_comp_with_send (CompEditor *editor)
gboolean delegate;
priv = editor->priv;
-
+
send = priv->changed && priv->needs_send;
delegate = priv->flags & COMP_EDITOR_DELEGATE;
-
+
if (delegate) {
icalcomponent *icalcomp = e_cal_component_get_icalcomponent (priv->comp);
icalproperty *icalprop;
-
+
icalprop = icalproperty_new_x ("1");
icalproperty_set_x_name (icalprop, "X-EVOLUTION-DELEGATED");
icalcomponent_add_property (icalcomp, icalprop);
}
-
+
if (!save_comp (editor))
return FALSE;
@@ -889,7 +889,7 @@ save_comp_with_send (CompEditor *editor)
} else {
if (!comp_editor_send_comp (editor, E_CAL_COMPONENT_METHOD_REQUEST))
return FALSE;
-
+
if (delegate)
return comp_editor_send_comp (editor, E_CAL_COMPONENT_METHOD_REPLY);
}
@@ -933,7 +933,7 @@ prompt_and_save_changes (CompEditor *editor, gboolean send)
if (e_cal_component_is_instance (priv->comp))
if (!recur_component_dialog (priv->client, priv->comp, &priv->mod, GTK_WINDOW (editor), FALSE))
return FALSE;
-
+
if (send && save_comp_with_send (editor))
return TRUE;
else if (!send && save_comp (editor))
@@ -954,7 +954,7 @@ delete_event_cb (GtkWidget *widget, GdkEvent *event, gpointer data)
CompEditor *editor = COMP_EDITOR (data);
commit_all_fields (editor);
-
+
if (prompt_and_save_changes (editor, TRUE))
close_dialog (editor);
@@ -966,7 +966,7 @@ attachment_bar_changed_cb (EAttachmentBar *bar,
void *data)
{
CompEditor *editor = COMP_EDITOR (data);
-
+
guint attachment_num = e_attachment_bar_get_num_attachments (
E_ATTACHMENT_BAR (editor->priv->attachment_bar));
if (attachment_num) {
@@ -979,37 +979,37 @@ attachment_bar_changed_cb (EAttachmentBar *bar,
gtk_widget_show (editor->priv->attachment_expander_icon);
e_expander_set_expanded(E_EXPANDER(editor->priv->attachment_expander),TRUE);
-
+
} else {
gtk_label_set_text (GTK_LABEL (editor->priv->attachment_expander_num), "");
gtk_widget_hide (editor->priv->attachment_expander_icon);
e_expander_set_expanded(E_EXPANDER(editor->priv->attachment_expander),FALSE);
}
-
-
+
+
/* Mark the editor as changed so it prompts about unsaved
changes on close */
comp_editor_set_changed (editor, TRUE);
}
-static void
-attachment_expander_activate_cb (EExpander *expander,
- void *data)
-{
- CompEditor *editor = COMP_EDITOR (data);
- gboolean show = e_expander_get_expanded (expander);
-
- /* Update the expander label */
- if (show)
- gtk_label_set_text_with_mnemonic (GTK_LABEL (editor->priv->attachment_expander_label),
- _("Hide Attachment _Bar"));
- else
- gtk_label_set_text_with_mnemonic (GTK_LABEL (editor->priv->attachment_expander_label),
- _("Show Attachment _Bar"));
+static void
+attachment_expander_activate_cb (EExpander *expander,
+ void *data)
+{
+ CompEditor *editor = COMP_EDITOR (data);
+ gboolean show = e_expander_get_expanded (expander);
+
+ /* Update the expander label */
+ if (show)
+ gtk_label_set_text_with_mnemonic (GTK_LABEL (editor->priv->attachment_expander_label),
+ _("Hide Attachment _Bar"));
+ else
+ gtk_label_set_text_with_mnemonic (GTK_LABEL (editor->priv->attachment_expander_label),
+ _("Show Attachment _Bar"));
}
-static gboolean
+static gboolean
open_attachment (EAttachmentBar *bar, CompEditor *editor)
{
GnomeIconList *icon_list;
@@ -1017,7 +1017,7 @@ open_attachment (EAttachmentBar *bar, CompEditor *editor)
int num;
char *attach_file_url;
GError *error = NULL;
-
+
if (E_IS_ATTACHMENT_BAR (bar)) {
icon_list = GNOME_ICON_LIST (bar);
p = gnome_icon_list_get_selection (icon_list);
@@ -1028,7 +1028,7 @@ open_attachment (EAttachmentBar *bar, CompEditor *editor)
char *filename = NULL;
const char *local_store = e_cal_get_local_attachment_store (editor->priv->client);
- e_cal_component_get_uid (editor->priv->comp, &comp_uid);
+ e_cal_component_get_uid (editor->priv->comp, &comp_uid);
num = GPOINTER_TO_INT (p->data);
list = e_attachment_bar_get_attachment (bar, num);
attachment = list->data;
@@ -1039,7 +1039,7 @@ open_attachment (EAttachmentBar *bar, CompEditor *editor)
camel_mime_part_get_filename(attachment->body));
attach_file_url = g_build_path ("/", local_store, filename, NULL);
-
+
/* launch the url now */
/* TODO should send GError and handle error conditions
* here */
@@ -1050,14 +1050,14 @@ open_attachment (EAttachmentBar *bar, CompEditor *editor)
g_free (filename);
g_free (attach_file_url); }
return TRUE;
- } else
+ } else
return FALSE;
}
-static gboolean
+static gboolean
attachment_bar_icon_clicked_cb (EAttachmentBar *bar, GdkEvent *event, CompEditor *editor)
{
- if (E_IS_ATTACHMENT_BAR (bar) && event->type == GDK_2BUTTON_PRESS)
+ if (E_IS_ATTACHMENT_BAR (bar) && event->type == GDK_2BUTTON_PRESS)
if (open_attachment (bar, editor))
return TRUE;
return FALSE;
@@ -1070,7 +1070,7 @@ cab_open(EPopup *ep, EPopupItem *item, void *data)
{
EAttachmentBar *bar = data;
CompEditor *editor = COMP_EDITOR (gtk_widget_get_toplevel (GTK_WIDGET (bar)));
-
+
if (!open_attachment (bar, editor))
g_message ("\n Open failed");
}
@@ -1097,20 +1097,20 @@ cab_add(EPopup *ep, EPopupItem *item, void *data)
if (!g_ascii_strcasecmp (url->protocol, "file"))
e_attachment_bar_attach (bar, url->path, is_inline ? "inline" : "attachment");
- else
+ else
e_attachment_bar_attach_remote_file (bar, file_list->pdata[i], is_inline ? "inline" : "attachment");
g_free (file_list->pdata[i]);
camel_url_free (url);
}
-
- g_ptr_array_free (file_list, TRUE);
+
+ g_ptr_array_free (file_list, TRUE);
}
static void
cab_properties(EPopup *ep, EPopupItem *item, void *data)
{
EAttachmentBar *bar = data;
-
+
e_attachment_bar_edit_selected(bar);
}
@@ -1138,17 +1138,17 @@ cab_popup_position(GtkMenu *menu, int *x, int *y, gboolean *push_in, gpointer us
GnomeIconList *icon_list = user_data;
GList *selection;
GnomeCanvasPixbuf *image;
-
+
gdk_window_get_origin (((GtkWidget*) bar)->window, x, y);
-
+
selection = gnome_icon_list_get_selection (icon_list);
if (selection == NULL)
return;
-
+
image = gnome_icon_list_get_icon_pixbuf_item (icon_list, GPOINTER_TO_INT(selection->data));
if (image == NULL)
return;
-
+
/* Put menu to the center of icon. */
*x += (int)(image->item.x1 + image->item.x2) / 2;
*y += (int)(image->item.y1 + image->item.y2) / 2;
@@ -1197,7 +1197,7 @@ cab_popup(EAttachmentBar *bar, GdkEventButton *event, int id)
/* GtkWidget methods. */
-static gboolean
+static gboolean
popup_menu_event (GtkWidget *widget)
{
cab_popup((EAttachmentBar *)widget, NULL, -1);
@@ -1211,10 +1211,10 @@ button_press_event (GtkWidget *widget, GdkEventButton *event)
EAttachmentBar *bar = (EAttachmentBar *)widget;
GnomeIconList *icon_list = GNOME_ICON_LIST(widget);
int icon_number = -1;
-
+
if (event->button != 3)
return FALSE;
-
+
if (!gnome_icon_list_get_selection (icon_list)) {
icon_number = gnome_icon_list_get_icon_at (icon_list, event->x, event->y);
if (icon_number >= 0) {
@@ -1224,7 +1224,7 @@ button_press_event (GtkWidget *widget, GdkEventButton *event)
}
cab_popup(bar, event, icon_number);
-
+
return TRUE;
}
@@ -1236,7 +1236,7 @@ key_press_event(GtkWidget *widget, GdkEventKey *event)
e_attachment_bar_remove_selected (bar);
return TRUE;
}
-
+
return FALSE;
}
@@ -1245,13 +1245,13 @@ editor_key_press_event(GtkWidget *widget, GdkEventKey *event, CompEditor *editor
{
if (event->keyval == GDK_Escape) {
commit_all_fields (editor);
-
+
if (prompt_and_save_changes (editor, TRUE))
close_dialog (editor);
return TRUE;
}
-
+
return FALSE;
}
/* Menu callbacks */
@@ -1270,23 +1270,23 @@ menu_file_save_cb (BonoboUIComponent *uic,
if (e_attachment_bar_get_download_count (E_ATTACHMENT_BAR (editor->priv->attachment_bar)) ){
gboolean response = 1;
/*FIXME: Cannot use mail functions from calendar!!!! */
-#if 0
+#if 0
ECalComponentVType vtype = e_cal_component_get_vtype(editor->priv->comp);
if (vtype == E_CAL_COMPONENT_EVENT)
- response = em_utils_prompt_user((GtkWindow *)widget,
- NULL,
- "calendar:ask-send-event-pending-download",
+ response = em_utils_prompt_user((GtkWindow *)widget,
+ NULL,
+ "calendar:ask-send-event-pending-download",
NULL);
else
- response = em_utils_prompt_user((GtkWindow *)widget,
- NULL,
- "calendar:ask-send-task-pending-download",
+ response = em_utils_prompt_user((GtkWindow *)widget,
+ NULL,
+ "calendar:ask-send-task-pending-download",
NULL);
#endif
- if (!response)
+ if (!response)
return;
- }
+ }
if (!e_cal_is_read_only (priv->client, &read_only, NULL) || read_only) {
e_error_run ((GtkWindow *) gtk_widget_get_toplevel (GTK_WIDGET (editor)), "calendar:prompt-read-only-cal", NULL);
@@ -1305,10 +1305,10 @@ menu_file_save_cb (BonoboUIComponent *uic,
if (!correct)
return;
- if (!text.value)
+ if (!text.value)
if (!send_component_prompt_subject ((GtkWindow *) editor, priv->client, priv->comp))
return;
- if (save_comp_with_send (editor))
+ if (save_comp_with_send (editor))
close_dialog (editor);
}
@@ -1323,16 +1323,16 @@ menu_file_print_cb (BonoboUIComponent *uic,
ECalComponent *comp;
GList *l;
icalcomponent *icalcomp = e_cal_component_get_icalcomponent (priv->comp);
-
+
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (icalcomp));
for (l = priv->pages; l != NULL; l = l->next)
comp_editor_page_fill_component (l->data, comp);
-
+
print_comp (comp, priv->client, GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG);
- g_object_unref (comp);
+ g_object_unref (comp);
}
static void
@@ -1345,14 +1345,14 @@ menu_file_print_preview_cb (BonoboUIComponent *uic,
ECalComponent *comp;
GList *l;
icalcomponent *icalcomp = e_cal_component_get_icalcomponent (priv->comp);
-
+
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (icalcomp));
for (l = priv->pages; l != NULL; l = l->next)
- comp_editor_page_fill_component (l->data, comp);
+ comp_editor_page_fill_component (l->data, comp);
print_comp (comp, priv->client, TRUE);
- g_object_unref (comp);
+ g_object_unref (comp);
}
static void
@@ -1361,7 +1361,7 @@ menu_file_close_cb (BonoboUIComponent *uic,
const char *path)
{
CompEditor *editor = (CompEditor *) data;
-
+
commit_all_fields (editor);
if (prompt_and_save_changes (editor, TRUE))
@@ -1409,8 +1409,8 @@ menu_edit_selectall_cb (BonoboUIComponent *uic,
if (GTK_IS_ENTRY (priv->focused_entry)) {
gtk_editable_set_position (GTK_EDITABLE (priv->focused_entry), -1);
gtk_editable_select_region (GTK_EDITABLE (priv->focused_entry), 0, -1);
- }
- if (GTK_IS_TEXT_VIEW (priv->focused_entry))
+ }
+ if (GTK_IS_TEXT_VIEW (priv->focused_entry))
g_signal_emit_by_name (priv->focused_entry, "select-all", TRUE);
}
@@ -1421,7 +1421,7 @@ menu_edit_cut_cb (BonoboUIComponent *uic,
{
CompEditor *editor = data;
CompEditorPrivate *priv = editor->priv;
-
+
if (GTK_IS_ENTRY (priv->focused_entry))
gtk_editable_cut_clipboard (GTK_EDITABLE (priv->focused_entry));
if (GTK_IS_TEXT_VIEW (priv->focused_entry))
@@ -1454,13 +1454,13 @@ menu_insert_attachment_cb (BonoboUIComponent *uic,
if (!g_ascii_strcasecmp (url->protocol, "file"))
e_attachment_bar_attach (bar, url->path, is_inline ? "inline" : "attachment");
- else
+ else
e_attachment_bar_attach_remote_file (bar, file_list->pdata[i], is_inline ? "inline" : "attachment");
g_free (file_list->pdata[i]);
camel_url_free (url);
}
-
- g_ptr_array_free (file_list, TRUE);
+
+ g_ptr_array_free (file_list, TRUE);
}
static void
@@ -1469,7 +1469,7 @@ menu_help_cb (BonoboUIComponent *uic,
const char *path)
{
CompEditor *editor = (CompEditor *) data;
-
+
comp_editor_show_help (editor);
}
@@ -1477,17 +1477,17 @@ static BonoboUIVerb verbs [] = {
BONOBO_UI_VERB ("FileSave", menu_file_save_cb),
BONOBO_UI_VERB ("CalendarPrint", menu_file_print_cb),
- BONOBO_UI_VERB ("CalendarPrintPreview", menu_file_print_preview_cb),
+ BONOBO_UI_VERB ("CalendarPrintPreview", menu_file_print_preview_cb),
BONOBO_UI_VERB ("FileClose", menu_file_close_cb),
BONOBO_UI_VERB ("EditCopy", menu_edit_copy_cb),
BONOBO_UI_VERB ("EditPaste", menu_edit_paste_cb),
BONOBO_UI_VERB ("EditCut", menu_edit_cut_cb),
- BONOBO_UI_VERB ("EditSelectAll", menu_edit_selectall_cb),
+ BONOBO_UI_VERB ("EditSelectAll", menu_edit_selectall_cb),
BONOBO_UI_VERB ("InsertAttachments", menu_insert_attachment_cb),
-
+
BONOBO_UI_VERB ("Help", menu_help_cb),
-
+
BONOBO_UI_VERB_END
};
@@ -1530,7 +1530,7 @@ setup_widgets (CompEditor *editor)
gtk_notebook_set_show_tabs (priv->notebook, FALSE);
g_signal_connect (editor, "delete_event", G_CALLBACK (delete_event_cb), editor);
- g_signal_connect (editor, "key_press_event", G_CALLBACK (editor_key_press_event), editor);
+ g_signal_connect (editor, "key_press_event", G_CALLBACK (editor_key_press_event), editor);
/*Attachments */
priv->attachment_scrolled_window = gtk_scrolled_window_new (NULL, NULL);
@@ -1538,7 +1538,7 @@ setup_widgets (CompEditor *editor)
GTK_SHADOW_IN);
gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (priv->attachment_scrolled_window),
GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
-
+
priv->attachment_bar = e_attachment_bar_new (NULL);
g_signal_connect (priv->attachment_bar, "button_press_event", G_CALLBACK (button_press_event), NULL);
@@ -1552,7 +1552,7 @@ setup_widgets (CompEditor *editor)
g_signal_connect (priv->attachment_bar, "changed",
G_CALLBACK (attachment_bar_changed_cb), editor);
g_signal_connect (GNOME_ICON_LIST (priv->attachment_bar), "event",
- G_CALLBACK (attachment_bar_icon_clicked_cb), editor);
+ G_CALLBACK (attachment_bar_icon_clicked_cb), editor);
priv->attachment_expander_label =
gtk_label_new_with_mnemonic (_("Show Attachment _Bar"));
priv->attachment_expander_num = gtk_label_new ("");
@@ -1560,12 +1560,12 @@ setup_widgets (CompEditor *editor)
gtk_misc_set_alignment (GTK_MISC (priv->attachment_expander_label), 0.0, 0.5);
gtk_misc_set_alignment (GTK_MISC (priv->attachment_expander_num), 1.0, 0.5);
expander_hbox = gtk_hbox_new (FALSE, 0);
-
+
attachment_pixbuf = e_icon_factory_get_icon ("mail-attachment", E_ICON_SIZE_MENU);
priv->attachment_expander_icon = gtk_image_new_from_pixbuf (attachment_pixbuf);
gtk_misc_set_alignment (GTK_MISC (priv->attachment_expander_icon), 1, 0.5);
gtk_widget_set_size_request (priv->attachment_expander_icon, 100, -1);
- g_object_unref (attachment_pixbuf);
+ g_object_unref (attachment_pixbuf);
gtk_box_pack_start (GTK_BOX (expander_hbox), priv->attachment_expander_label,
TRUE, TRUE, 0);
@@ -1584,8 +1584,8 @@ setup_widgets (CompEditor *editor)
gtk_box_pack_start (GTK_BOX (vbox), priv->attachment_expander, FALSE, FALSE, GNOME_PAD_SMALL);
gtk_widget_show (priv->attachment_expander);
- e_expander_set_expanded (E_EXPANDER (priv->attachment_expander), FALSE);
- g_signal_connect_after (priv->attachment_expander, "activate",
+ e_expander_set_expanded (E_EXPANDER (priv->attachment_expander), FALSE);
+ g_signal_connect_after (priv->attachment_expander, "activate",
G_CALLBACK (attachment_expander_activate_cb), editor);
}
@@ -1617,7 +1617,7 @@ comp_editor_init (CompEditor *editor)
editor->uic = bonobo_ui_component_new_default ();
/* FIXME: handle bonobo exceptions */
bonobo_ui_component_set_container (editor->uic, bonobo_object_corba_objref (BONOBO_OBJECT (container)), NULL);
-
+
bonobo_ui_component_add_verb_list_with_data (editor->uic, verbs, editor);
bonobo_ui_component_freeze (editor->uic, NULL);
@@ -1678,7 +1678,7 @@ comp_editor_finalize (GObject *object)
g_object_unref (priv->client);
priv->client = NULL;
}
-
+
if (priv->source_client) {
g_object_unref (priv->source_client);
priv->source_client = NULL;
@@ -1759,8 +1759,8 @@ close_dialog (CompEditor *editor)
notification back when we are in an inconsistent state */
if (priv->view)
g_signal_handlers_disconnect_matched (G_OBJECT (priv->view),
- G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, editor);
-
+ G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, editor);
+
gtk_widget_destroy (GTK_WIDGET (editor));
}
@@ -1883,10 +1883,10 @@ comp_editor_get_changed (CompEditor *editor)
return priv->changed;
}
-void
+void
comp_editor_set_flags (CompEditor *editor, CompEditorFlags flags)
{
-
+
CompEditorPrivate *priv;
g_return_if_fail (editor != NULL);
@@ -1898,10 +1898,10 @@ comp_editor_set_flags (CompEditor *editor, CompEditorFlags flags)
}
-CompEditorFlags
+CompEditorFlags
comp_editor_get_flags (CompEditor *editor)
{
-
+
CompEditorPrivate *priv;
g_return_val_if_fail (editor != NULL, FALSE);
@@ -1982,11 +1982,11 @@ static void page_unmapped_cb (GtkWidget *page_widget,
* comp_editor_append_page:
* @editor: A component editor
* @page: A component editor page
- * @label: Label of the page. Should be NULL if add is FALSE.
+ * @label: Label of the page. Should be NULL if add is FALSE.
* @add: Add's the page into the notebook if TRUE
*
* Appends a page to the notebook if add is TRUE else
- * just adds it to the list of pages.
+ * just adds it to the list of pages.
**/
void
comp_editor_append_page (CompEditor *editor,
@@ -2029,7 +2029,7 @@ comp_editor_append_page (CompEditor *editor,
is_first_page = (priv->pages == NULL);
priv->pages = g_list_append (priv->pages, page);
-
+
if (add)
gtk_notebook_append_page (priv->notebook, page_widget, label_widget);
@@ -2085,7 +2085,7 @@ comp_editor_remove_page (CompEditor *editor, CompEditorPage *page)
page_num = gtk_notebook_page_num (priv->notebook, page_widget);
if (page_num == -1)
return;
-
+
/* Disconnect all the signals added in append_page(). */
g_signal_handlers_disconnect_matched (page, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, editor);
g_signal_handlers_disconnect_matched (page_widget, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, page);
@@ -2240,7 +2240,7 @@ make_title_from_string (ECalComponent *comp, const char *str, gboolean is_group_
break;
case E_CAL_COMPONENT_TODO:
if (is_group_item)
- type_string = _("Assigned Task - %s");
+ type_string = _("Assigned Task - %s");
else
type_string = _("Task - %s");
break;
@@ -2345,7 +2345,7 @@ attachment_guess_mime_type (const char *file_name)
return type;
}
-static void
+static void
set_attachment_list (CompEditor *editor, GSList *attach_list)
{
GSList *p = NULL;
@@ -2355,10 +2355,10 @@ set_attachment_list (CompEditor *editor, GSList *attach_list)
if (e_attachment_bar_get_num_attachments (E_ATTACHMENT_BAR (editor->priv->attachment_bar))) {
/* To prevent repopulating the
- * bar due to redraw functions in fill_widget.
+ * bar due to redraw functions in fill_widget.
* Assumes it can be set only once.
- */
- return;
+ */
+ return;
}
for (p = attach_list; p != NULL; p = p->next) {
@@ -2367,32 +2367,32 @@ set_attachment_list (CompEditor *editor, GSList *attach_list)
CamelDataWrapper *wrapper;
CamelStream *stream;
struct stat statbuf;
- char *mime_type, *file_name;
+ char *mime_type, *file_name;
char *ptr;
attach_filename = (char *) p->data;
- /* should we assert if g_str_has_prefix (attach_filename, "file://"))
+ /* should we assert if g_str_has_prefix (attach_filename, "file://"))
* here
*/
/* get url sans protocol and add it to the bar.
- * how to set the filename properly */
+ * how to set the filename properly */
file_name = g_filename_from_uri (attach_filename, NULL, NULL);
if (!file_name)
continue;
-
+
if (g_stat (file_name, &statbuf) < 0) {
g_warning ("Cannot attach file %s: %s", file_name, g_strerror (errno));
g_free (file_name);
continue;
}
-
+
/* return if it's not a regular file */
if (!S_ISREG (statbuf.st_mode)) {
g_warning ("Cannot attach file %s: not a regular file", file_name);
g_free (file_name);
return;
}
-
+
stream = camel_stream_fs_new_with_name (file_name, O_RDONLY, 0);
if (!stream) {
g_warning ("Cannot attach file %s: %s", file_name, g_strerror (errno));
@@ -2407,7 +2407,7 @@ set_attachment_list (CompEditor *editor, GSList *attach_list)
} else {
wrapper = camel_data_wrapper_new ();
}
-
+
camel_data_wrapper_construct_from_stream (wrapper, stream);
camel_data_wrapper_set_mime_type (wrapper, mime_type);
g_free (mime_type);
@@ -2418,18 +2418,18 @@ set_attachment_list (CompEditor *editor, GSList *attach_list)
}
camel_object_unref (stream);
-
+
part = camel_mime_part_new ();
camel_medium_set_content_object (CAMEL_MEDIUM (part), wrapper);
camel_object_unref (wrapper);
-
+
camel_mime_part_set_disposition (part, "attachment");
ptr = strstr (file_name, comp_uid);
if (ptr) {
ptr += strlen(comp_uid);
if (*ptr++ == '-')
- camel_mime_part_set_filename (part, ptr);
+ camel_mime_part_set_filename (part, ptr);
}
g_free (file_name);
@@ -2437,7 +2437,7 @@ set_attachment_list (CompEditor *editor, GSList *attach_list)
e_expander_set_expanded (E_EXPANDER (editor->priv->attachment_expander), TRUE);
camel_object_unref (part);
- }
+ }
}
static void
@@ -2455,7 +2455,7 @@ fill_widgets (CompEditor *editor)
set_attachment_list (editor, attachment_list);
g_slist_foreach (attachment_list, (GFunc)g_free, NULL);
g_slist_free (attachment_list);
- }
+ }
for (l = priv->pages; l != NULL; l = l->next)
comp_editor_page_fill_widgets (l->data, priv->comp);
@@ -2499,7 +2499,7 @@ real_edit_comp (CompEditor *editor, ECalComponent *comp)
{
CompEditorPrivate *priv;
const char *uid;
-
+
g_return_if_fail (editor != NULL);
g_return_if_fail (IS_COMP_EDITOR (editor));
@@ -2512,11 +2512,11 @@ real_edit_comp (CompEditor *editor, ECalComponent *comp)
if (comp)
priv->comp = e_cal_component_clone (comp);
-
+
priv->existing_org = e_cal_component_has_organizer (comp);
priv->user_org = (itip_organizer_is_user (comp, priv->client) || itip_sentby_is_user (comp));
priv->warned = FALSE;
-
+
set_title_from_comp (editor);
set_icon_from_comp (editor);
e_cal_component_get_uid (comp, &uid);
@@ -2532,10 +2532,10 @@ real_edit_comp (CompEditor *editor, ECalComponent *comp)
static void
set_attendees_for_delegation (ECalComponent *comp, const char *address, ECalComponentItipMethod method)
{
- icalproperty *prop;
+ icalproperty *prop;
icalparameter *param;
icalcomponent *icalcomp;
-
+
icalcomp = e_cal_component_get_icalcomponent (comp);
for (prop = icalcomponent_get_first_property (icalcomp, ICAL_ATTENDEE_PROPERTY);
@@ -2550,7 +2550,7 @@ set_attendees_for_delegation (ECalComponent *comp, const char *address, ECalComp
((delfrom && *delfrom) &&
g_str_equal (itip_strip_mailto (delfrom), address)))) {
icalcomponent_remove_property (icalcomp, prop);
- }
+ }
}
@@ -2565,8 +2565,8 @@ get_users_from_memo_comp (ECalComponent *comp, GList **users)
char **emails, **iter;
icalcomp = e_cal_component_get_icalcomponent (comp);
-
- for (icalprop = icalcomponent_get_first_property (icalcomp, ICAL_X_PROPERTY); icalprop;
+
+ for (icalprop = icalcomponent_get_first_property (icalcomp, ICAL_X_PROPERTY); icalprop;
icalprop = icalcomponent_get_next_property (icalcomp, ICAL_X_PROPERTY)) {
if (g_str_equal (icalproperty_get_x_name (icalprop), "X-EVOLUTION-RECIPIENTS")) {
break;
@@ -2593,7 +2593,7 @@ real_send_comp (CompEditor *editor, ECalComponentItipMethod method)
ECalComponent *send_comp;
char *address = NULL;
GList *users = NULL;
-
+
g_return_val_if_fail (editor != NULL, FALSE);
g_return_val_if_fail (IS_COMP_EDITOR (editor), FALSE);
@@ -2601,9 +2601,9 @@ real_send_comp (CompEditor *editor, ECalComponentItipMethod method)
send_comp = e_cal_component_clone (priv->comp);
- if (e_cal_component_get_vtype (send_comp) == E_CAL_COMPONENT_JOURNAL)
+ if (e_cal_component_get_vtype (send_comp) == E_CAL_COMPONENT_JOURNAL)
get_users_from_memo_comp (send_comp, &users);
-
+
/* The user updates the delegated status to the Organizer, so remove all other attendees */
if ((priv->flags & COMP_EDITOR_DELEGATE)) {
address = itip_get_comp_attendee (send_comp, priv->client);
@@ -2611,7 +2611,7 @@ real_send_comp (CompEditor *editor, ECalComponentItipMethod method)
if (address)
set_attendees_for_delegation (send_comp, address, method);
}
-
+
if (!e_cal_component_has_attachments (priv->comp)) {
if (itip_send_comp (method, send_comp, priv->client,
NULL, NULL, users)) {
@@ -2624,7 +2624,7 @@ real_send_comp (CompEditor *editor, ECalComponentItipMethod method)
int num_attachments, i;
GSList *attach_list = NULL;
GSList *mime_attach_list;
-
+
num_attachments = e_cal_component_get_num_attachments (send_comp);
for (i = 0; i < num_attachments ; i++) {
@@ -2645,7 +2645,7 @@ real_send_comp (CompEditor *editor, ECalComponentItipMethod method)
g_object_unref (send_comp);
g_free (address);
comp_editor_set_changed (editor, TRUE);
-
+
return FALSE;
}
@@ -2689,7 +2689,7 @@ comp_editor_get_comp (CompEditor *editor)
/**
* comp_editor_get_current_comp
- *
+ *
* @param editor
* @param correct Set this no non-NULL if you are interested to know if
* all pages reported success when filling component.
@@ -2771,12 +2771,12 @@ gboolean
comp_editor_close (CompEditor *editor)
{
gboolean close;
-
+
g_return_val_if_fail (editor != NULL, FALSE);
g_return_val_if_fail (IS_COMP_EDITOR (editor), FALSE);
commit_all_fields (editor);
-
+
close = prompt_and_save_changes (editor, TRUE);
if (close)
close_dialog (editor);
@@ -2790,7 +2790,7 @@ comp_editor_close (CompEditor *editor)
* be freed by the caller.
*/
GSList *
-comp_editor_get_mime_attach_list (CompEditor *editor)
+comp_editor_get_mime_attach_list (CompEditor *editor)
{
struct CalMimeAttach *cal_mime_attach;
GSList *attach_list = NULL, *l, *parts;
@@ -2798,7 +2798,7 @@ comp_editor_get_mime_attach_list (CompEditor *editor)
/* TODO assert sanity of bar */
parts = e_attachment_bar_get_parts (E_ATTACHMENT_BAR (editor->priv->attachment_bar));
for (l = parts; l ; l = l->next) {
-
+
CamelDataWrapper *wrapper;
CamelStreamMem *mstream;
unsigned char *buffer = NULL;
@@ -2807,10 +2807,10 @@ comp_editor_get_mime_attach_list (CompEditor *editor)
cal_mime_attach = g_malloc0 (sizeof (struct CalMimeAttach));
wrapper = camel_medium_get_content_object (CAMEL_MEDIUM (l->data));
mstream = (CamelStreamMem *) camel_stream_mem_new ();
-
+
camel_data_wrapper_decode_to_stream (wrapper, (CamelStream *) mstream);
buffer = g_memdup (mstream->buffer->data, mstream->buffer->len);
-
+
cal_mime_attach->encoded_data = (char *)buffer;
cal_mime_attach->length = mstream->buffer->len;
cal_mime_attach->filename = g_strdup (camel_mime_part_get_filename
@@ -2820,15 +2820,15 @@ comp_editor_get_mime_attach_list (CompEditor *editor)
desc = _("attachment");
cal_mime_attach->description = g_strdup (desc);
cal_mime_attach->content_type = g_strdup (camel_data_wrapper_get_mime_type (wrapper));
-
+
disp = camel_mime_part_get_disposition ((CamelMimePart *)l->data);
- if (disp && !g_ascii_strcasecmp(disp, "inline"))
+ if (disp && !g_ascii_strcasecmp(disp, "inline"))
cal_mime_attach->disposition = TRUE;
-
+
attach_list = g_slist_append (attach_list, cal_mime_attach);
camel_object_unref (mstream);
-
+
}
g_slist_free (parts);
@@ -2864,7 +2864,7 @@ comp_editor_focus (CompEditor *editor)
/**
* comp_editor_notify_client_changed:
* @editor: A component editor.
- *
+ *
* Makes an editor emit the "client_changed" signal.
**/
void
@@ -2880,7 +2880,7 @@ comp_editor_notify_client_changed (CompEditor *editor, ECal *client)
priv = editor->priv;
priv->changed = TRUE;
-
+
g_object_unref (priv->client);
priv->client = client;
@@ -2909,7 +2909,7 @@ page_changed_cb (GtkObject *obj, gpointer data)
_("Changes made to this item may be discarded if an update arrives"));
priv->warned = TRUE;
}
-
+
}
static void
@@ -2921,7 +2921,7 @@ needs_send_cb (GtkObject *obj, gpointer data)
}
/* Focus out widget callback */
-static void
+static void
page_focus_out_widget_cb (GtkObject *obj, GtkWidget *widget, gpointer data)
{
CompEditor *editor = COMP_EDITOR (data);
@@ -2936,7 +2936,7 @@ page_focus_out_widget_cb (GtkObject *obj, GtkWidget *widget, gpointer data)
static void
page_focus_in_widget_cb (GtkObject *obj, GtkWidget *widget, gpointer data)
{
-
+
CompEditor *editor = COMP_EDITOR (data);
CompEditorPrivate *priv;
@@ -3016,7 +3016,7 @@ obj_modified_cb (ECal *client, GList *objects, gpointer data)
_("Unable to use current version!"));
gtk_dialog_run (GTK_DIALOG (dialog));
gtk_widget_destroy (dialog);
-
+
icalcomponent_free (icalcomp);
}
diff --git a/calendar/gui/dialogs/comp-editor.h b/calendar/gui/dialogs/comp-editor.h
index e761061939..7243808386 100644
--- a/calendar/gui/dialogs/comp-editor.h
+++ b/calendar/gui/dialogs/comp-editor.h
@@ -107,7 +107,7 @@ gboolean comp_editor_save_comp (CompEditor *editor,
void comp_editor_delete_comp (CompEditor *editor);
gboolean comp_editor_send_comp (CompEditor *editor,
ECalComponentItipMethod method);
-GSList *comp_editor_get_mime_attach_list (CompEditor *editor);
+GSList *comp_editor_get_mime_attach_list (CompEditor *editor);
gboolean comp_editor_close (CompEditor *editor);
void comp_editor_focus (CompEditor *editor);
diff --git a/calendar/gui/dialogs/delete-comp.c b/calendar/gui/dialogs/delete-comp.c
index 2644f18c13..8446608222 100644
--- a/calendar/gui/dialogs/delete-comp.c
+++ b/calendar/gui/dialogs/delete-comp.c
@@ -47,11 +47,11 @@
* the component instead.
* @widget: A widget to use as a basis for conversion from UTF8 into font
* encoding.
- *
+ *
* Pops up a dialog box asking the user whether he wants to delete a number of
* calendar components. The dialog will not appear, however, if the
* configuration option for confirmation is turned off.
- *
+ *
* Return value: TRUE if the user clicked Yes, FALSE otherwise. If the
* configuration option for confirmation is turned off, this function will
* unconditionally return TRUE.
@@ -65,7 +65,7 @@ delete_component_dialog (ECalComponent *comp,
const char *id;
char *arg0 = NULL;
int response;
-
+
if (comp) {
g_return_val_if_fail (E_IS_CAL_COMPONENT (comp), FALSE);
g_return_val_if_fail (n_comps == 1, FALSE);
@@ -82,14 +82,14 @@ delete_component_dialog (ECalComponent *comp,
if (comp) {
ECalComponentText summary;
-
+
vtype = e_cal_component_get_vtype (comp);
-
+
if (!consider_as_untitled) {
e_cal_component_get_summary (comp, &summary);
arg0 = g_strdup (summary.value);
}
-
+
switch (vtype) {
case E_CAL_COMPONENT_EVENT:
if (arg0)
@@ -146,14 +146,14 @@ delete_component_dialog (ECalComponent *comp,
vtype);
return FALSE;
}
-
+
if (n_comps > 1)
arg0 = g_strdup_printf ("%d", n_comps);
}
-
+
response = e_error_run ((GtkWindow *) gtk_widget_get_toplevel (widget), id, arg0, NULL);
g_free (arg0);
-
+
return response == GTK_RESPONSE_YES;
}
@@ -167,7 +167,7 @@ cb_toggled_cb (GtkWidget *toggle, gpointer data)
gtk_widget_set_sensitive (entry, active);
}
-gboolean
+gboolean
prompt_retract_dialog (ECalComponent *comp, char **retract_text, GtkWidget *parent)
{
char *message = NULL;
@@ -175,7 +175,7 @@ prompt_retract_dialog (ECalComponent *comp, char **retract_text, GtkWidget *pare
GtkMessageDialog *dialog = NULL;
GtkWidget *cb, *label, *entry, *vbox, *sw, *frame;
gboolean ret_val = FALSE;
-
+
type = e_cal_component_get_vtype (comp);
switch (type) {
@@ -193,13 +193,13 @@ prompt_retract_dialog (ECalComponent *comp, char **retract_text, GtkWidget *pare
return FALSE;
}
- dialog = (GtkMessageDialog *) gtk_message_dialog_new_with_markup
- ((GtkWindow *) gtk_widget_get_toplevel (parent), GTK_DIALOG_MODAL,
+ dialog = (GtkMessageDialog *) gtk_message_dialog_new_with_markup
+ ((GtkWindow *) gtk_widget_get_toplevel (parent), GTK_DIALOG_MODAL,
GTK_MESSAGE_QUESTION, GTK_BUTTONS_OK_CANCEL, "<b>%s</b>", message);
g_free (message);
gtk_window_set_resizable (GTK_WINDOW (dialog), TRUE);
-
+
gtk_box_set_spacing ((GtkBox *) (GTK_DIALOG (dialog)->vbox), 12);
vbox = GTK_WIDGET (GTK_DIALOG (dialog)->vbox);
@@ -207,7 +207,7 @@ prompt_retract_dialog (ECalComponent *comp, char **retract_text, GtkWidget *pare
gtk_container_add (GTK_CONTAINER (vbox), cb);
label = gtk_label_new_with_mnemonic ("_Retract comment");
-
+
frame = gtk_frame_new (NULL);
gtk_frame_set_label_widget ((GtkFrame *) frame, label);
gtk_frame_set_label_align ((GtkFrame *) frame, 0, 0);
@@ -216,7 +216,7 @@ prompt_retract_dialog (ECalComponent *comp, char **retract_text, GtkWidget *pare
sw = gtk_scrolled_window_new (NULL, NULL);
gtk_scrolled_window_set_policy ((GtkScrolledWindow *)sw, GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
-
+
entry = gtk_text_view_new ();
gtk_scrolled_window_add_with_viewport ((GtkScrolledWindow *)sw, entry);
gtk_label_set_mnemonic_widget ((GtkLabel *)label, entry);
@@ -237,7 +237,7 @@ prompt_retract_dialog (ECalComponent *comp, char **retract_text, GtkWidget *pare
gtk_text_buffer_get_start_iter (text_buffer, &text_iter_start);
gtk_text_buffer_get_end_iter (text_buffer, &text_iter_end);
- *retract_text = gtk_text_buffer_get_text (text_buffer, &text_iter_start,
+ *retract_text = gtk_text_buffer_get_text (text_buffer, &text_iter_start,
&text_iter_end, FALSE);
}
}
diff --git a/calendar/gui/dialogs/delete-error.c b/calendar/gui/dialogs/delete-error.c
index a3bcfb76ee..d8f4df3cfc 100644
--- a/calendar/gui/dialogs/delete-error.c
+++ b/calendar/gui/dialogs/delete-error.c
@@ -33,9 +33,9 @@
/**
* delete_error_dialog:
- *
+ *
* Shows any applicable error messages as the result of deleting and object
- *
+ *
**/
void
delete_error_dialog (GError *error, ECalComponentVType vtype)
@@ -43,10 +43,10 @@ delete_error_dialog (GError *error, ECalComponentVType vtype)
GList *icon_list = NULL;
GtkWidget *dialog;
const char *str;
-
+
if (!error)
return;
-
+
switch (error->code) {
case E_CALENDAR_STATUS_CORBA_EXCEPTION:
switch (vtype) {
@@ -98,11 +98,11 @@ delete_error_dialog (GError *error, ECalComponentVType vtype)
break;
case E_CALENDAR_STATUS_OK:
case E_CALENDAR_STATUS_OBJECT_NOT_FOUND:
- default:
+ default:
/* If not found, we don't care - its gone anyhow */
return;
}
-
+
dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_MODAL,
GTK_MESSAGE_ERROR,
GTK_BUTTONS_OK, str);
@@ -110,13 +110,13 @@ delete_error_dialog (GError *error, ECalComponentVType vtype)
icon_list = e_icon_factory_get_icon_list ("stock_calendar");
else if (vtype == E_CAL_COMPONENT_TODO)
icon_list = e_icon_factory_get_icon_list ("stock_todo");
-
+
if (icon_list) {
gtk_window_set_icon_list (GTK_WINDOW (dialog), icon_list);
g_list_foreach (icon_list, (GFunc) g_object_unref, NULL);
g_list_free (icon_list);
}
-
+
gtk_dialog_run (GTK_DIALOG (dialog));
gtk_widget_destroy (dialog);
}
diff --git a/calendar/gui/dialogs/e-delegate-dialog.c b/calendar/gui/dialogs/e-delegate-dialog.c
index 0340194b22..8f2fbb4ed7 100644
--- a/calendar/gui/dialogs/e-delegate-dialog.c
+++ b/calendar/gui/dialogs/e-delegate-dialog.c
@@ -49,7 +49,7 @@ struct _EDelegateDialogPrivate {
GtkWidget *addressbook;
ENameSelector *name_selector;
- GtkWidget *entry;
+ GtkWidget *entry;
};
static const char *section_name = "Delegate To";
@@ -167,7 +167,7 @@ e_delegate_dialog_construct (EDelegateDialog *edd, const char *name, const char
e_name_selector_model_peek_section (name_selector_model, section_name, NULL, &destination_store);
e_destination_store_append_destination (destination_store, dest);
g_object_unref (dest);
-
+
g_signal_connect((priv->addressbook), "clicked",
G_CALLBACK (addressbook_clicked_cb), edd);
@@ -193,7 +193,7 @@ get_widgets (EDelegateDialog *edd)
priv->app = GW ("delegate-dialog");
priv->hbox = GW ("delegate-hbox");
- priv->addressbook = GW ("addressbook");
+ priv->addressbook = GW ("addressbook");
return (priv->app
&& priv->hbox
@@ -206,7 +206,7 @@ addressbook_clicked_cb (GtkWidget *widget, gpointer data)
EDelegateDialog *edd = data;
EDelegateDialogPrivate *priv;
ENameSelectorDialog *name_selector_dialog;
-
+
priv = edd->priv;
name_selector_dialog = e_name_selector_peek_dialog (priv->name_selector);
@@ -251,7 +251,7 @@ e_delegate_dialog_get_delegate (EDelegateDialog *edd)
EDestinationStore *destination_store;
GList *destinations;
EDestination *destination;
-
+
g_return_val_if_fail (edd != NULL, NULL);
g_return_val_if_fail (E_IS_DELEGATE_DIALOG (edd), NULL);
@@ -269,7 +269,7 @@ e_delegate_dialog_get_delegate (EDelegateDialog *edd)
g_free (priv->address);
priv->address = g_strdup (e_destination_get_email (destination));
}
-
+
g_list_free (destinations);
return g_strdup (priv->address);
}
@@ -283,7 +283,7 @@ e_delegate_dialog_get_delegate_name (EDelegateDialog *edd)
EDestinationStore *destination_store;
GList *destinations;
EDestination *destination;
-
+
g_return_val_if_fail (edd != NULL, NULL);
g_return_val_if_fail (E_IS_DELEGATE_DIALOG (edd), NULL);
@@ -301,7 +301,7 @@ e_delegate_dialog_get_delegate_name (EDelegateDialog *edd)
g_free (priv->name);
priv->name = g_strdup (e_destination_get_name (destination));
}
-
+
g_list_free (destinations);
return g_strdup (priv->name);
}
diff --git a/calendar/gui/dialogs/e-send-options-utils.c b/calendar/gui/dialogs/e-send-options-utils.c
index 01fe01529e..2d776c1df6 100644
--- a/calendar/gui/dialogs/e-send-options-utils.c
+++ b/calendar/gui/dialogs/e-send-options-utils.c
@@ -23,8 +23,8 @@
#include <glib.h>
#include <string.h>
-void
-e_sendoptions_utils_set_default_data (ESendOptionsDialog *sod, ESource *source, char * type)
+void
+e_sendoptions_utils_set_default_data (ESendOptionsDialog *sod, ESource *source, char * type)
{
ESendOptionsGeneral *gopts = NULL;
ESendOptionsStatusTracking *sopts;
@@ -32,20 +32,20 @@ e_sendoptions_utils_set_default_data (ESendOptionsDialog *sod, ESource *source,
ESourceList *source_list;
const char *uid;
const char *value;
-
+
gopts = sod->data->gopts;
sopts = sod->data->sopts;
-
+
if (!strcmp (type, "calendar"))
source_list = e_source_list_new_for_gconf (gconf, "/apps/evolution/calendar/sources");
- else
+ else
source_list = e_source_list_new_for_gconf (gconf, "/apps/evolution/tasks/sources");
-
+
uid = e_source_peek_uid (source);
source = e_source_list_peek_source_by_uid (source_list, uid);
/* priority */
- value = e_source_get_property (source, "priority");
+ value = e_source_get_property (source, "priority");
if (value) {
if (!strcmp (value, "high"))
gopts->priority = E_PRIORITY_HIGH;
@@ -57,20 +57,20 @@ e_sendoptions_utils_set_default_data (ESendOptionsDialog *sod, ESource *source,
gopts->priority = E_PRIORITY_UNDEFINED;
}
/* Reply requested */
- value = e_source_get_property (source, "reply-requested");
+ value = e_source_get_property (source, "reply-requested");
if (value) {
if (!strcmp (value, "none"))
gopts->reply_enabled = FALSE;
else if (!strcmp (value, "convinient")) {
gopts->reply_enabled = TRUE;
- gopts->reply_convenient = TRUE;
+ gopts->reply_convenient = TRUE;
} else {
gint i = atoi (value);
gopts->reply_within = i;
}
}
/* Delay delivery */
- value = e_source_get_property (source, "delay-delivery");
+ value = e_source_get_property (source, "delay-delivery");
if (value) {
if (!strcmp (value, "none"))
gopts->delay_enabled = FALSE;
@@ -78,9 +78,9 @@ e_sendoptions_utils_set_default_data (ESendOptionsDialog *sod, ESource *source,
gopts->delay_enabled = TRUE;
gopts->delay_until = icaltime_as_timet (icaltime_from_string (value));
}
- }
+ }
/* Expiration Date */
- value = e_source_get_property (source, "expiration");
+ value = e_source_get_property (source, "expiration");
if (value) {
if (!strcmp (value, "none"))
gopts->expiration_enabled = FALSE;
@@ -94,7 +94,7 @@ e_sendoptions_utils_set_default_data (ESendOptionsDialog *sod, ESource *source,
}
}
/* status tracking */
- value = e_source_get_property (source, "status-tracking");
+ value = e_source_get_property (source, "status-tracking");
if (value) {
if (!strcmp (value, "none"))
sopts->tracking_enabled = FALSE;
@@ -110,44 +110,44 @@ e_sendoptions_utils_set_default_data (ESendOptionsDialog *sod, ESource *source,
}
/* Return Notifications */
-
- value = e_source_get_property (source, "return-open");
+
+ value = e_source_get_property (source, "return-open");
if (value) {
if (!strcmp (value, "none"))
sopts->opened = E_RETURN_NOTIFY_NONE;
- else
+ else
sopts->opened = E_RETURN_NOTIFY_MAIL;
}
-
- value = e_source_get_property (source, "return-accept");
+
+ value = e_source_get_property (source, "return-accept");
if (value) {
if (!strcmp (value, "none"))
sopts->accepted = E_RETURN_NOTIFY_NONE;
- else
+ else
sopts->accepted = E_RETURN_NOTIFY_MAIL;
}
- value = e_source_get_property (source, "return-decline");
+ value = e_source_get_property (source, "return-decline");
if (value) {
if (!strcmp (value, "none"))
sopts->declined = E_RETURN_NOTIFY_NONE;
- else
+ else
sopts->declined = E_RETURN_NOTIFY_MAIL;
}
-
- value = e_source_get_property (source, "return-complete");
+
+ value = e_source_get_property (source, "return-complete");
if (value) {
if (!strcmp (value, "none"))
sopts->completed = E_RETURN_NOTIFY_NONE;
- else
+ else
sopts->completed = E_RETURN_NOTIFY_MAIL;
}
g_object_unref (gconf);
}
-void
-e_sendoptions_utils_fill_component (ESendOptionsDialog *sod, ECalComponent *comp)
+void
+e_sendoptions_utils_fill_component (ESendOptionsDialog *sod, ECalComponent *comp)
{
int i = 1;
icalproperty *prop;
@@ -164,19 +164,19 @@ e_sendoptions_utils_fill_component (ESendOptionsDialog *sod, ECalComponent *comp
if (e_sendoptions_get_need_general_options (sod)) {
prop = icalproperty_new_x ((const char *) g_strdup_printf ("%d", gopts->priority));
icalproperty_set_x_name (prop, "X-EVOLUTION-OPTIONS-PRIORITY");
- icalcomponent_add_property (icalcomp, prop);
+ icalcomponent_add_property (icalcomp, prop);
if (gopts->reply_enabled) {
- if (gopts->reply_convenient)
- prop = icalproperty_new_x ("convenient");
- else
+ if (gopts->reply_convenient)
+ prop = icalproperty_new_x ("convenient");
+ else
prop = icalproperty_new_x ((const char *) g_strdup_printf ( "%d", gopts->reply_within));
icalproperty_set_x_name (prop, "X-EVOLUTION-OPTIONS-REPLY");
icalcomponent_add_property (icalcomp, prop);
}
if (gopts->expiration_enabled && gopts->expire_after) {
- prop = icalproperty_new_x ((const char *) g_strdup_printf ( "%d", gopts->expire_after));
+ prop = icalproperty_new_x ((const char *) g_strdup_printf ( "%d", gopts->expire_after));
icalproperty_set_x_name (prop, "X-EVOLUTION-OPTIONS-EXPIRE");
icalcomponent_add_property (icalcomp, prop);
}
@@ -184,35 +184,35 @@ e_sendoptions_utils_fill_component (ESendOptionsDialog *sod, ECalComponent *comp
if (gopts->delay_enabled) {
struct icaltimetype temp;
icaltimezone *zone = calendar_config_get_icaltimezone ();
- temp = icaltime_from_timet_with_zone (gopts->delay_until, FALSE, zone);
+ temp = icaltime_from_timet_with_zone (gopts->delay_until, FALSE, zone);
prop = icalproperty_new_x (icaltime_as_ical_string (temp));
icalproperty_set_x_name (prop, "X-EVOLUTION-OPTIONS-DELAY");
icalcomponent_add_property (icalcomp, prop);
}
}
-
- if (sopts->tracking_enabled)
- prop = icalproperty_new_x ((const char *) g_strdup_printf ( "%d", sopts->track_when));
+
+ if (sopts->tracking_enabled)
+ prop = icalproperty_new_x ((const char *) g_strdup_printf ( "%d", sopts->track_when));
else
prop = icalproperty_new_x ("0");
icalproperty_set_x_name (prop, "X-EVOLUTION-OPTIONS-TRACKINFO");
icalcomponent_add_property (icalcomp, prop);
-
-
- prop = icalproperty_new_x ((const char *) g_strdup_printf ("%d", sopts->opened));
+
+
+ prop = icalproperty_new_x ((const char *) g_strdup_printf ("%d", sopts->opened));
icalproperty_set_x_name (prop, "X-EVOLUTION-OPTIONS-OPENED");
icalcomponent_add_property (icalcomp, prop);
-
- prop = icalproperty_new_x ((const char *) g_strdup_printf ("%d", sopts->accepted));
+
+ prop = icalproperty_new_x ((const char *) g_strdup_printf ("%d", sopts->accepted));
icalproperty_set_x_name (prop, "X-EVOLUTION-OPTIONS-ACCEPTED");
icalcomponent_add_property (icalcomp, prop);
- prop = icalproperty_new_x ((const char *) g_strdup_printf ("%d", sopts->declined));
+ prop = icalproperty_new_x ((const char *) g_strdup_printf ("%d", sopts->declined));
icalproperty_set_x_name (prop, "X-EVOLUTION-OPTIONS-DECLINED");
icalcomponent_add_property (icalcomp, prop);
- prop = icalproperty_new_x ((const char *) g_strdup_printf ("%d", sopts->completed));
+ prop = icalproperty_new_x ((const char *) g_strdup_printf ("%d", sopts->completed));
icalproperty_set_x_name (prop, "X-EVOLUTION-OPTIONS-COMPLETED");
icalcomponent_add_property (icalcomp, prop);
}
diff --git a/calendar/gui/dialogs/e-send-options-utils.h b/calendar/gui/dialogs/e-send-options-utils.h
index a1a2b99842..560a37ea9d 100644
--- a/calendar/gui/dialogs/e-send-options-utils.h
+++ b/calendar/gui/dialogs/e-send-options-utils.h
@@ -26,6 +26,6 @@
#include <libecal/e-cal-component.h>
#include <libedataserver/e-source-list.h>
-void e_sendoptions_utils_set_default_data (ESendOptionsDialog *sod, ESource *source, char* type);
+void e_sendoptions_utils_set_default_data (ESendOptionsDialog *sod, ESource *source, char* type);
void e_sendoptions_utils_fill_component (ESendOptionsDialog *sod, ECalComponent *comp);
#endif
diff --git a/calendar/gui/dialogs/event-editor.c b/calendar/gui/dialogs/event-editor.c
index eb86ea07b4..e5081f8a34 100644
--- a/calendar/gui/dialogs/event-editor.c
+++ b/calendar/gui/dialogs/event-editor.c
@@ -51,7 +51,7 @@ struct _EventEditorPrivate {
EMeetingStore *model;
gboolean is_meeting;
gboolean meeting_shown;
- gboolean updating;
+ gboolean updating;
};
@@ -74,14 +74,14 @@ event_editor_class_init (EventEditorClass *klass)
{
GObjectClass *gobject_class;
CompEditorClass *editor_class;
-
+
gobject_class = (GObjectClass *) klass;
editor_class = (CompEditorClass *) klass;
editor_class->set_e_cal = event_editor_set_e_cal;
editor_class->edit_comp = event_editor_edit_comp;
editor_class->send_comp = event_editor_send_comp;
-
+
gobject_class->finalize = event_editor_finalize;
}
@@ -114,11 +114,11 @@ menu_view_role_cb (BonoboUIComponent *component,
gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- event_page_set_view_role (ee->priv->event_page, atoi(state));
- calendar_config_set_show_role (atoi(state));
+ event_page_set_view_role (ee->priv->event_page, atoi(state));
+ calendar_config_set_show_role (atoi(state));
}
static void
@@ -129,12 +129,12 @@ menu_view_status_cb (BonoboUIComponent *component,
gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
event_page_set_view_status (ee->priv->event_page, atoi(state));
- calendar_config_set_show_status (atoi(state));
+ calendar_config_set_show_status (atoi(state));
}
static void
@@ -145,11 +145,11 @@ menu_view_type_cb (BonoboUIComponent *component,
gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- event_page_set_view_type (ee->priv->event_page, atoi(state));
- calendar_config_set_show_type (atoi(state));
+ event_page_set_view_type (ee->priv->event_page, atoi(state));
+ calendar_config_set_show_type (atoi(state));
}
static void
@@ -160,11 +160,11 @@ menu_view_rsvp_cb (BonoboUIComponent *component,
gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- event_page_set_view_rsvp (ee->priv->event_page, atoi(state));
- calendar_config_set_show_rsvp (atoi(state));
+ event_page_set_view_rsvp (ee->priv->event_page, atoi(state));
+ calendar_config_set_show_rsvp (atoi(state));
}
static void
@@ -187,11 +187,11 @@ menu_show_time_busy_cb (BonoboUIComponent *component,
gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- event_page_set_show_time_busy (ee->priv->event_page, atoi(state));
+ event_page_set_show_time_busy (ee->priv->event_page, atoi(state));
}
static void
@@ -202,10 +202,10 @@ menu_all_day_event_cb (BonoboUIComponent *component,
gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- event_page_set_all_day_event (ee->priv->event_page, atoi(state));
+ event_page_set_all_day_event (ee->priv->event_page, atoi(state));
}
static void
@@ -216,10 +216,10 @@ menu_show_time_zone_cb (BonoboUIComponent *component,
gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- event_page_set_show_timezone (ee->priv->event_page, atoi(state));
+ event_page_set_show_timezone (ee->priv->event_page, atoi(state));
calendar_config_set_show_timezone (atoi(state));
}
@@ -231,11 +231,11 @@ menu_show_categories_cb (BonoboUIComponent *component,
gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- event_page_set_show_categories (ee->priv->event_page, atoi(state));
+ event_page_set_show_categories (ee->priv->event_page, atoi(state));
calendar_config_set_show_categories (atoi(state));
}
@@ -251,7 +251,7 @@ menu_class_public_cb (BonoboUIComponent *ui_component,
return;
comp_editor_page_notify_changed (COMP_EDITOR_PAGE (ee->priv->event_page));
-
+
event_page_set_classification (ee->priv->event_page, E_CAL_COMPONENT_CLASS_PUBLIC);
}
@@ -265,7 +265,7 @@ menu_class_private_cb (BonoboUIComponent *ui_component,
EventEditor *ee = (EventEditor *) user_data;
if (state[0] == '0')
return;
-
+
comp_editor_page_notify_changed (COMP_EDITOR_PAGE (ee->priv->event_page));
event_page_set_classification (ee->priv->event_page, E_CAL_COMPONENT_CLASS_PRIVATE);
@@ -295,7 +295,7 @@ menu_action_recurrence_cb (BonoboUIComponent *ui_component,
gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
+
gtk_widget_show (ee->priv->recur_window);
}
@@ -304,13 +304,13 @@ menu_action_freebusy_cb (BonoboUIComponent *ui_component,
const char *path,
Bonobo_UIComponent_EventType type,
const char *state,
- gpointer user_data)
+ gpointer user_data)
{
EventEditor *ee = (EventEditor *) user_data;
-
- if (!ee->priv->sched_window)
+
+ if (!ee->priv->sched_window)
create_schedule_page (ee);
- else
+ else
gtk_widget_show (ee->priv->sched_window);
}
@@ -329,7 +329,7 @@ menu_all_day_event_cmd (BonoboUIComponent *uic,
void *data,
const char *path)
{
- /* TODO
+ /* TODO
EventEditor *ee = (EventEditor *) data;
event_page_set_all_day_event (ee->priv->event_page, atoi(state));*/
@@ -340,10 +340,10 @@ menu_show_time_zone_cmd (BonoboUIComponent *uic,
void *data,
const char *path)
{
- /* TODO
+ /* TODO
EventEditor *ee = (EventEditor *) data;
-
- event_page_set_show_timezone (ee->priv->event_page, atoi(state));
+
+ event_page_set_show_timezone (ee->priv->event_page, atoi(state));
calendar_config_set_show_timezone (atoi(state)); */
}
@@ -353,7 +353,7 @@ menu_action_recurrence_cmd (BonoboUIComponent *uic,
const char *path)
{
EventEditor *ee = (EventEditor *) data;
-
+
gtk_widget_show (ee->priv->recur_window);
}
@@ -395,9 +395,9 @@ menu_action_freebusy_cmd (BonoboUIComponent *uic,
{
EventEditor *ee = (EventEditor *) data;
- if (!ee->priv->sched_window)
+ if (!ee->priv->sched_window)
create_schedule_page (ee);
- else
+ else
gtk_widget_show (ee->priv->sched_window);
}
@@ -407,18 +407,18 @@ menu_insert_send_options_cmd (BonoboUIComponent *uic,
const char *path)
{
EventEditor *ee = (EventEditor *) data;
-
+
event_page_sendoptions_clicked_cb (ee->priv->event_page);
}
static BonoboUIVerb verbs [] = {
BONOBO_UI_VERB ("ActionAlarm", menu_action_alarm_cmd),
BONOBO_UI_VERB ("ActionAllDayEvent", menu_all_day_event_cmd),
- BONOBO_UI_VERB ("ViewTimeZone", menu_show_time_zone_cmd),
+ BONOBO_UI_VERB ("ViewTimeZone", menu_show_time_zone_cmd),
BONOBO_UI_VERB ("ActionRecurrence", menu_action_recurrence_cmd),
BONOBO_UI_VERB ("ActionFreeBusy", menu_action_freebusy_cmd),
BONOBO_UI_VERB ("InsertSendOptions", menu_insert_send_options_cmd),
-
+
BONOBO_UI_VERB_END
};
@@ -433,14 +433,14 @@ static EPixmap pixmaps[] = {
E_PIXMAP ("/Toolbar/ActionAlarm", "stock_alarm", E_ICON_SIZE_LARGE_TOOLBAR),
E_PIXMAP ("/Toolbar/ActionAllDayEvent", "stock_new-24h-appointment", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/ViewTimeZone", "stock_timezone", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/ActionRecurrence", "stock_task-recurring", E_ICON_SIZE_LARGE_TOOLBAR),
+ E_PIXMAP ("/Toolbar/ViewTimeZone", "stock_timezone", E_ICON_SIZE_LARGE_TOOLBAR),
+ E_PIXMAP ("/Toolbar/ActionRecurrence", "stock_task-recurring", E_ICON_SIZE_LARGE_TOOLBAR),
/* These two will have an absolute path to the png file filled
* in at run-time, see event_editor_init().
*/
E_PIXMAP ("/Toolbar/ActionFreeBusy", NULL, E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/commands/ActionFreeBusy", NULL, E_ICON_SIZE_MENU),
+ E_PIXMAP ("/commands/ActionFreeBusy", NULL, E_ICON_SIZE_MENU),
E_PIXMAP_END
};
@@ -458,7 +458,7 @@ event_editor_init (EventEditor *ee)
priv->model = E_MEETING_STORE (e_meeting_store_new ());
priv->meeting_shown = TRUE;
- priv->updating = FALSE;
+ priv->updating = FALSE;
priv->is_meeting = FALSE;
bonobo_ui_component_freeze (editor->uic, NULL);
@@ -486,7 +486,7 @@ event_editor_init (EventEditor *ee)
bonobo_ui_component_add_listener (
editor->uic, "ViewStatus",
menu_view_status_cb, editor);
-
+
/* Show hide the type fields */
status = calendar_config_get_show_type ();
bonobo_ui_component_set_prop (
@@ -517,15 +517,15 @@ event_editor_init (EventEditor *ee)
bonobo_ui_component_add_listener (
editor->uic, "ActionAlarm",
menu_action_alarm_cb, editor);
-
+
bonobo_ui_component_add_listener (
- editor->uic, "ActionAllDayEvent",
+ editor->uic, "ActionAllDayEvent",
menu_all_day_event_cb, editor);
-
+
bonobo_ui_component_add_listener (
- editor->uic, "ActionShowTimeBusy",
+ editor->uic, "ActionShowTimeBusy",
menu_show_time_busy_cb, editor);
-
+
status = calendar_config_get_show_timezone ();
bonobo_ui_component_set_prop (
editor->uic, "/commands/ViewTimeZone",
@@ -556,10 +556,10 @@ event_editor_init (EventEditor *ee)
menu_class_confidential_cb, editor);
bonobo_ui_component_add_listener (
- editor->uic, "ActionRecurrence",
+ editor->uic, "ActionRecurrence",
menu_action_recurrence_cb, editor);
bonobo_ui_component_add_listener (
- editor->uic, "ActionFreeBusy",
+ editor->uic, "ActionFreeBusy",
menu_action_freebusy_cb, editor);
/* NOTE: Make sure the 6 and 7 below correspond to the correct
@@ -571,14 +571,14 @@ event_editor_init (EventEditor *ee)
}
e_pixmaps_update (editor->uic, pixmaps);
- bonobo_ui_component_thaw (editor->uic, NULL);
+ bonobo_ui_component_thaw (editor->uic, NULL);
comp_editor_set_help_section (COMP_EDITOR (ee), "usage-calendar-apts");
}
/* Handler for the delete event. It hides the window without destroying it.
Connected to the recur dialog and Free busy dialog */
-static gboolean
+static gboolean
window_delete_event (GtkWidget *widget, GdkEvent *event, gpointer user_data)
{
gtk_widget_hide (widget);
@@ -597,7 +597,7 @@ event_editor_construct (EventEditor *ee, ECal *client)
priv->event_page = event_page_new (priv->model, client, COMP_EDITOR(ee)->uic);
g_object_ref_sink (priv->event_page);
- comp_editor_append_page (COMP_EDITOR (ee),
+ comp_editor_append_page (COMP_EDITOR (ee),
COMP_EDITOR_PAGE (priv->event_page),
_("Appoint_ment"), TRUE);
g_signal_connect (G_OBJECT (priv->event_page), "client_changed",
@@ -611,7 +611,7 @@ event_editor_construct (EventEditor *ee, ECal *client)
g_signal_connect ((GtkWidget *) priv->recur_window, "delete-event", G_CALLBACK(window_delete_event), NULL);
priv->recur_page = recurrence_page_new ();
g_object_ref_sink (priv->recur_page);
- gtk_container_add ((GtkContainer *) (GTK_DIALOG (priv->recur_window)->vbox),
+ gtk_container_add ((GtkContainer *) (GTK_DIALOG (priv->recur_window)->vbox),
comp_editor_page_get_widget (COMP_EDITOR_PAGE (priv->recur_page)));
gtk_widget_show_all (gtk_bin_get_child (GTK_BIN (priv->recur_window)));
comp_editor_append_page (COMP_EDITOR (ee), COMP_EDITOR_PAGE (priv->recur_page), NULL, FALSE);
@@ -621,9 +621,9 @@ event_editor_construct (EventEditor *ee, ECal *client)
event_page_show_options (priv->event_page);
comp_editor_set_group_item (COMP_EDITOR (ee), TRUE);
- if (!((flags & COMP_EDITOR_USER_ORG) || (flags & COMP_EDITOR_DELEGATE)|| (flags & COMP_EDITOR_NEW_ITEM)))
+ if (!((flags & COMP_EDITOR_USER_ORG) || (flags & COMP_EDITOR_DELEGATE)|| (flags & COMP_EDITOR_NEW_ITEM)))
bonobo_ui_component_set_prop (editor->uic, "/commands/ActionFreeBusy", "hidden", "1", NULL);
-
+
event_page_set_meeting (priv->event_page, TRUE);
priv->meeting_shown=TRUE;
} else {
@@ -649,14 +649,14 @@ event_editor_set_e_cal (CompEditor *editor, ECal *client)
{
EventEditor *ee;
EventEditorPrivate *priv;
-
+
ee = EVENT_EDITOR (editor);
priv = ee->priv;
e_meeting_store_set_e_cal (priv->model, client);
-
+
if (COMP_EDITOR_CLASS (event_editor_parent_class)->set_e_cal)
- COMP_EDITOR_CLASS (event_editor_parent_class)->set_e_cal (editor, client);
+ COMP_EDITOR_CLASS (event_editor_parent_class)->set_e_cal (editor, client);
}
static void
@@ -669,10 +669,10 @@ event_editor_edit_comp (CompEditor *editor, ECalComponent *comp)
ECalComponentDateTime dtstart, dtend;
ECal *client;
GSList *attendees = NULL;
-
+
ee = EVENT_EDITOR (editor);
priv = ee->priv;
-
+
priv->updating = TRUE;
delegate = (comp_editor_get_flags (COMP_EDITOR (editor)) & COMP_EDITOR_DELEGATE);
@@ -694,26 +694,26 @@ event_editor_edit_comp (CompEditor *editor, ECalComponent *comp)
/* Get meeting related stuff */
e_cal_component_get_organizer (comp, &organizer);
e_cal_component_get_attendee_list (comp, &attendees);
-
+
/* Set up the attendees */
if (attendees != NULL) {
GSList *l;
int row;
char *user_email;
- user_email = itip_get_comp_attendee (comp, client);
-
+ user_email = itip_get_comp_attendee (comp, client);
+
if (!priv->meeting_shown) {
bonobo_ui_component_set_prop (editor->uic, "/commands/ActionFreeBusy", "hidden", "0", NULL);
}
-
+
if (!(delegate && e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_DELEGATE_TO_MANY))) {
for (l = attendees; l != NULL; l = l->next) {
ECalComponentAttendee *ca = l->data;
EMeetingAttendee *ia;
-
+
if (delegate && !g_str_equal (itip_strip_mailto (ca->value), user_email))
continue;
-
+
ia = E_MEETING_ATTENDEE (e_meeting_attendee_new_from_e_cal_component_attendee (ca));
/* If we aren't the organizer or the attendee is just delegated, don't allow editing */
@@ -751,10 +751,10 @@ event_editor_edit_comp (CompEditor *editor, ECalComponent *comp)
e_meeting_attendee_set_edit_level (ia, E_MEETING_ATTENDEE_EDIT_NONE);
}
}
-
- event_page_set_meeting (priv->event_page, TRUE);
+
+ event_page_set_meeting (priv->event_page, TRUE);
priv->meeting_shown = TRUE;
- }
+ }
e_cal_component_free_attendee_list (attendees);
comp_editor_set_needs_send (COMP_EDITOR (ee), priv->meeting_shown && (itip_organizer_is_user (comp, client) || itip_sentby_is_user (comp)));
@@ -775,12 +775,12 @@ event_editor_send_comp (CompEditor *editor, ECalComponentItipMethod method)
if (method == E_CAL_COMPONENT_METHOD_PUBLISH ||
method == E_CAL_COMPONENT_METHOD_CANCEL)
goto parent;
-
+
comp = event_page_get_cancel_comp (priv->event_page);
if (comp != NULL) {
ECal *client;
gboolean result;
-
+
client = e_meeting_store_get_e_cal (priv->model);
result = itip_send_comp (E_CAL_COMPONENT_METHOD_CANCEL, comp,
client, NULL, NULL, NULL);
@@ -788,7 +788,7 @@ event_editor_send_comp (CompEditor *editor, ECalComponentItipMethod method)
if (!result)
return FALSE;
- else
+ else
return TRUE;
}
@@ -816,7 +816,7 @@ event_editor_finalize (GObject *object)
g_object_unref (priv->event_page);
priv->event_page = NULL;
}
-
+
if (priv->recur_page) {
g_object_unref (priv->recur_page);
priv->recur_page = NULL;
@@ -864,13 +864,13 @@ show_meeting (EventEditor *ee)
EventEditorPrivate *priv;
CompEditor *editor = COMP_EDITOR (ee);
CompEditorFlags flags = comp_editor_get_flags (editor);
-
+
priv = ee->priv;
event_page_set_meeting (priv->event_page, TRUE);
if (!priv->meeting_shown) {
bonobo_ui_component_set_prop (editor->uic, "/commands/ActionFreeBusy", "hidden", "0", NULL);
-
+
priv->meeting_shown = TRUE;
comp_editor_set_changed (COMP_EDITOR (ee), FALSE);
diff --git a/calendar/gui/dialogs/event-page.c b/calendar/gui/dialogs/event-page.c
index b9b354f017..a60b87c4c9 100644
--- a/calendar/gui/dialogs/event-page.c
+++ b/calendar/gui/dialogs/event-page.c
@@ -82,7 +82,7 @@ struct _EventPagePrivate {
EAccountList *accounts;
GList *address_strings;
- EMeetingAttendee *ia;
+ EMeetingAttendee *ia;
char *default_address;
char *user_add;
ECalComponent *comp;
@@ -94,7 +94,7 @@ struct _EventPagePrivate {
/* Lists of attendees */
GPtrArray *deleted_attendees;
-
+
GtkWidget *start_time;
GtkWidget *end_time;
GtkWidget *end_time_selector;
@@ -112,7 +112,7 @@ struct _EventPagePrivate {
GtkWidget *description;
ECalComponentClassification classification;
-
+
gboolean show_time_as_busy;
GtkWidget *alarm_dialog;
@@ -124,7 +124,7 @@ struct _EventPagePrivate {
GtkWidget *categories;
GtkWidget *source_selector;
-
+
/* Meeting related items */
GtkWidget *list_box;
GtkWidget *organizer_table;
@@ -147,14 +147,14 @@ struct _EventPagePrivate {
gboolean updating;
EAlarmList *alarm_list_store;
-
+
gboolean sendoptions_shown;
ESendOptionsDialog *sod;
char *old_summary;
CalUnits alarm_units;
int alarm_interval;
-
+
/* This is TRUE if both the start & end timezone are the same. If the
start timezone is then changed, we updated the end timezone to the
same value, since 99% of events start and end in one timezone. */
@@ -176,7 +176,7 @@ static gboolean event_page_fill_timezones (CompEditorPage *page, GHashTable *tim
static void event_page_set_summary (CompEditorPage *page, const char *summary);
static void event_page_set_dates (CompEditorPage *page, CompEditorPageDates *dates);
static void notify_dates_changed (EventPage *epage, struct icaltimetype *start_tt, struct icaltimetype *end_tt);
-static gboolean check_start_before_end (struct icaltimetype *start_tt, icaltimezone *start_zone,
+static gboolean check_start_before_end (struct icaltimetype *start_tt, icaltimezone *start_zone,
struct icaltimetype *end_tt, icaltimezone *end_zone, gboolean adjust_end_time);
static void set_attendees (ECalComponent *comp, const GPtrArray *attendees);
static void hour_sel_changed ( GtkSpinButton *widget, EventPage *epage);
@@ -258,14 +258,14 @@ event_page_init (EventPage *epage)
priv->ia = NULL;
priv->default_address = NULL;
priv->invite = NULL;
-
+
priv->model = NULL;
priv->list_view = NULL;
-
+
priv->updating = FALSE;
-
+
priv->alarm_interval = -1;
-
+
priv->sendoptions_shown = FALSE;
priv->is_meeting = FALSE;
priv->sync_timezones = FALSE;
@@ -277,7 +277,7 @@ static void
cleanup_attendees (GPtrArray *attendees)
{
int i;
-
+
for (i = 0; i < attendees->len; i++)
g_object_unref (g_ptr_array_index (attendees, i));
}
@@ -295,7 +295,7 @@ event_page_finalize (GObject *object)
epage = EVENT_PAGE (object);
priv = epage->priv;
-
+
for (l = priv->address_strings; l != NULL; l = l->next)
g_free (l->data);
g_list_free (priv->address_strings);
@@ -305,7 +305,7 @@ event_page_finalize (GObject *object)
cleanup_attendees (priv->deleted_attendees);
g_ptr_array_free (priv->deleted_attendees, TRUE);
-
+
if (priv->main)
g_object_unref (priv->main);
@@ -446,7 +446,7 @@ set_all_day (EventPage *epage, gboolean all_day)
priv = epage->priv;
set_all_day_event_menu (epage, all_day);
-
+
/* TODO implement for in end time selector */
if (all_day)
gtk_option_menu_set_history (GTK_OPTION_MENU (priv->end_time_selector), 1);
@@ -476,7 +476,7 @@ update_time (EventPage *epage, ECalComponentDateTime *start_date, ECalComponentD
if (!e_cal_get_timezone (COMP_EDITOR_PAGE (epage)->client,
start_date->tzid, &start_zone, NULL)) {
g_warning ("Couldn't get timezone from server: %s",
- start_date->tzid ? start_date->tzid : "");
+ start_date->tzid ? start_date->tzid : "");
}
}
@@ -490,7 +490,7 @@ update_time (EventPage *epage, ECalComponentDateTime *start_date, ECalComponentD
*end_tt = *start_tt;
icaltime_adjust (end_tt, 1, 0, 0, 0);
}
-
+
if (start_tt->is_date && end_tt->is_date) {
all_day_event = TRUE;
if (icaltime_compare_date_only (*end_tt, *start_tt) > 0) {
@@ -527,23 +527,23 @@ update_time (EventPage *epage, ECalComponentDateTime *start_date, ECalComponentD
are the same. */
g_signal_handlers_block_matched (priv->start_timezone, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, epage);
g_signal_handlers_block_matched (priv->end_timezone, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, epage);
-
+
if (start_zone)
e_timezone_entry_set_timezone (E_TIMEZONE_ENTRY (priv->start_timezone),
start_zone);
def_zone = calendar_config_get_icaltimezone ();
if (!def_zone || !start_zone || strcmp (icaltimezone_get_tzid(def_zone), icaltimezone_get_tzid (start_zone)))
homezone = FALSE;
-
+
event_page_set_show_timezone (epage, (calendar_config_get_show_timezone()|| !homezone) & !all_day_event);
-
+
/*unblock the endtimezone widget*/
g_signal_handlers_unblock_matched (priv->end_timezone, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, epage);
g_signal_handlers_unblock_matched (priv->start_timezone, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, epage);
- priv->sync_timezones = TRUE;
+ priv->sync_timezones = TRUE;
- update_end_time_selector (epage);
+ update_end_time_selector (epage);
}
/* Fills the widgets with default values */
@@ -582,13 +582,13 @@ clear_widgets (EventPage *epage)
/* Alarm */
e_dialog_option_menu_set (priv->alarm_time, ALARM_NONE, alarm_map);
-
+
/* Categories */
e_dialog_editable_set (priv->categories, NULL);
}
static gboolean
-is_custom_alarm (ECalComponentAlarm *ca, char *old_summary, CalUnits user_units, int user_interval, int *alarm_type)
+is_custom_alarm (ECalComponentAlarm *ca, char *old_summary, CalUnits user_units, int user_interval, int *alarm_type)
{
ECalComponentAlarmTrigger trigger;
ECalComponentAlarmRepeat repeat;
@@ -598,7 +598,7 @@ is_custom_alarm (ECalComponentAlarm *ca, char *old_summary, CalUnits user_units,
icalproperty *icalprop;
icalattach *attach;
gboolean needs_desc = FALSE;
-
+
e_cal_component_alarm_get_action (ca, &action);
if (action != E_CAL_COMPONENT_ALARM_DISPLAY)
return TRUE;
@@ -619,7 +619,7 @@ is_custom_alarm (ECalComponentAlarm *ca, char *old_summary, CalUnits user_units,
icalprop = icalcomponent_get_next_property (icalcomp, ICAL_X_PROPERTY);
}
- if (!needs_desc) {
+ if (!needs_desc) {
e_cal_component_alarm_get_description (ca, &desc);
if (!desc.value || !old_summary || strcmp (desc.value, old_summary))
return TRUE;
@@ -628,14 +628,14 @@ is_custom_alarm (ECalComponentAlarm *ca, char *old_summary, CalUnits user_units,
e_cal_component_alarm_get_repeat (ca, &repeat);
if (repeat.repetitions != 0)
return TRUE;
-
+
if (e_cal_component_alarm_has_attendees (ca))
return TRUE;
-
+
e_cal_component_alarm_get_trigger (ca, &trigger);
if (trigger.type != E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_START)
return TRUE;
-
+
if (trigger.u.rel_duration.is_neg != 1)
return TRUE;
@@ -652,7 +652,7 @@ is_custom_alarm (ECalComponentAlarm *ca, char *old_summary, CalUnits user_units,
*alarm_type = ALARM_1_DAY;
return FALSE;
}
-
+
if (trigger.u.rel_duration.days == 0
&& trigger.u.rel_duration.hours == 1
&& trigger.u.rel_duration.minutes == 0) {
@@ -660,47 +660,47 @@ is_custom_alarm (ECalComponentAlarm *ca, char *old_summary, CalUnits user_units,
*alarm_type = ALARM_1_HOUR;
return FALSE;
}
-
+
if (trigger.u.rel_duration.days == 0
&& trigger.u.rel_duration.hours == 0
&& trigger.u.rel_duration.minutes == 15) {
if (alarm_type)
- *alarm_type = ALARM_15_MINUTES;
+ *alarm_type = ALARM_15_MINUTES;
return FALSE;
}
if (user_interval != -1) {
switch (user_units) {
- case CAL_DAYS:
+ case CAL_DAYS:
if (trigger.u.rel_duration.days == user_interval
&& trigger.u.rel_duration.hours == 0
&& trigger.u.rel_duration.minutes == 0) {
if (alarm_type)
- *alarm_type = ALARM_USER_TIME;
+ *alarm_type = ALARM_USER_TIME;
return FALSE;
}
break;
-
+
case CAL_HOURS:
if (trigger.u.rel_duration.days == 0
&& trigger.u.rel_duration.hours == user_interval
&& trigger.u.rel_duration.minutes == 0) {
if (alarm_type)
- *alarm_type = ALARM_USER_TIME;
+ *alarm_type = ALARM_USER_TIME;
return FALSE;
}
break;
-
+
case CAL_MINUTES:
if (trigger.u.rel_duration.days == 0
&& trigger.u.rel_duration.hours == 0
&& trigger.u.rel_duration.minutes == user_interval) {
if (alarm_type)
- *alarm_type = ALARM_USER_TIME;
+ *alarm_type = ALARM_USER_TIME;
return FALSE;
}
break;
- }
+ }
}
return TRUE;
@@ -711,7 +711,7 @@ is_custom_alarm_uid_list (ECalComponent *comp, GList *alarms, char *old_summary,
{
ECalComponentAlarm *ca;
gboolean result;
-
+
if (g_list_length (alarms) > 1)
return TRUE;
@@ -723,13 +723,13 @@ is_custom_alarm_uid_list (ECalComponent *comp, GList *alarms, char *old_summary,
}
static gboolean
-is_custom_alarm_store (EAlarmList *alarm_list_store, char *old_summary, CalUnits user_units, int user_interval, int *alarm_type)
+is_custom_alarm_store (EAlarmList *alarm_list_store, char *old_summary, CalUnits user_units, int user_interval, int *alarm_type)
{
const ECalComponentAlarm *alarm;
GtkTreeModel *model;
GtkTreeIter iter;
gboolean valid_iter;
-
+
model = GTK_TREE_MODEL (alarm_list_store);
valid_iter = gtk_tree_model_get_iter_first (model, &iter);
@@ -743,7 +743,7 @@ is_custom_alarm_store (EAlarmList *alarm_list_store, char *old_summary, CalUnit
valid_iter = gtk_tree_model_iter_next (model, &iter);
if (valid_iter)
return TRUE;
-
+
return FALSE;
}
@@ -779,7 +779,7 @@ event_page_set_view_rsvp (EventPage *epage, gboolean state)
e_meeting_list_view_column_set_visible (priv->list_view, "RSVP", state);
}
-void
+void
event_page_set_classification (EventPage *epage, ECalComponentClassification class)
{
epage->priv->classification = class;
@@ -790,7 +790,7 @@ create_image_event_box (const char *image_text, const char *tip_text)
{
GtkWidget *image, *box;
GtkTooltips *tip;
-
+
box = gtk_event_box_new ();
tip = gtk_tooltips_new ();
image = e_icon_factory_get_image (image_text, E_ICON_SIZE_MENU);
@@ -799,7 +799,7 @@ create_image_event_box (const char *image_text, const char *tip_text)
gtk_widget_show_all (box);
gtk_tooltips_set_tip (tip, box, tip_text, NULL);
- return box;
+ return box;
}
static void
@@ -807,36 +807,36 @@ sensitize_widgets (EventPage *epage)
{
gboolean read_only, custom, alarm, sens = TRUE, sensitize;
EventPagePrivate *priv;
- gboolean delegate;
-
+ gboolean delegate;
+
priv = epage->priv;
if (COMP_EDITOR_PAGE (epage)->flags & COMP_EDITOR_MEETING)
sens = COMP_EDITOR_PAGE (epage)->flags & COMP_EDITOR_PAGE_USER_ORG;
if (!e_cal_is_read_only (COMP_EDITOR_PAGE (epage)->client, &read_only, NULL))
read_only = TRUE;
-
+
delegate = COMP_EDITOR_PAGE (epage)->flags & COMP_EDITOR_PAGE_DELEGATE;
-
+
sensitize = !read_only && sens;
alarm = e_dialog_option_menu_get (priv->alarm_time, alarm_map) != ALARM_NONE;
- custom = is_custom_alarm_store (priv->alarm_list_store, priv->old_summary, priv->alarm_units, priv->alarm_interval, NULL) ||
+ custom = is_custom_alarm_store (priv->alarm_list_store, priv->old_summary, priv->alarm_units, priv->alarm_interval, NULL) ||
e_dialog_option_menu_get (priv->alarm_time, alarm_map) == ALARM_CUSTOM ? TRUE:FALSE;
if (alarm && !priv->alarm_icon) {
priv->alarm_icon = create_image_event_box ("stock_bell", _("This event has alarms"));
gtk_box_pack_start ((GtkBox *)priv->status_icons, priv->alarm_icon, FALSE, FALSE, 6);
}
-
- /* The list of organizers is set to be non-editable. Otherwise any
- * change in the displayed list causes an 'Account not found' error.
+
+ /* The list of organizers is set to be non-editable. Otherwise any
+ * change in the displayed list causes an 'Account not found' error.
*/
gtk_editable_set_editable (GTK_EDITABLE (GTK_COMBO (priv->organizer)->entry), FALSE);
gtk_editable_set_editable (GTK_EDITABLE (priv->summary), !read_only);
gtk_editable_set_editable (GTK_EDITABLE (priv->location), sensitize);
- gtk_widget_set_sensitive (priv->alarm_box, custom);
+ gtk_widget_set_sensitive (priv->alarm_box, custom);
gtk_widget_set_sensitive (priv->start_time, sensitize);
gtk_widget_set_sensitive (priv->start_timezone, sensitize);
gtk_widget_set_sensitive (priv->end_time, sensitize);
@@ -848,9 +848,9 @@ sensitize_widgets (EventPage *epage)
if ( (COMP_EDITOR_PAGE(epage)->flags) & COMP_EDITOR_PAGE_NEW_ITEM ) {
if (priv->all_day_event)
gtk_option_menu_set_history (GTK_OPTION_MENU (priv->end_time_selector), 1);
- else
+ else
gtk_option_menu_set_history (GTK_OPTION_MENU (priv->end_time_selector), 0);
- } else
+ } else
gtk_option_menu_set_history (GTK_OPTION_MENU (priv->end_time_selector), 1);
gtk_widget_set_sensitive (priv->hour_selector, sensitize);
@@ -868,7 +868,7 @@ sensitize_widgets (EventPage *epage)
e_meeting_list_view_set_editable (priv->list_view, (!read_only && sens) || delegate);
gtk_widget_set_sensitive (priv->remove, (!read_only && sens) || delegate);
gtk_widget_set_sensitive (priv->invite, (!read_only && sens) || delegate);
- gtk_widget_set_sensitive (GTK_WIDGET (priv->list_view), !read_only);
+ gtk_widget_set_sensitive (GTK_WIDGET (priv->list_view), !read_only);
bonobo_ui_component_set_prop (priv->uic, "/commands/InsertAttachments", "sensitive", sensitize ? "1" : "0"
, NULL);
@@ -905,9 +905,9 @@ sensitize_widgets (EventPage *epage)
gtk_widget_show (priv->list_box);
gtk_widget_show (priv->attendee_box);
gtk_widget_show (priv->organizer);
- gtk_label_set_text_with_mnemonic ((GtkLabel *) priv->org_cal_label, _("Or_ganizer:"));
+ gtk_label_set_text_with_mnemonic ((GtkLabel *) priv->org_cal_label, _("Or_ganizer:"));
}
-
+
}
void
@@ -928,7 +928,7 @@ event_page_show_options (EventPage *page)
page->priv->sendoptions_shown = TRUE;
}
-void
+void
event_page_set_meeting (EventPage *page, gboolean set)
{
g_return_if_fail (IS_EVENT_PAGE (page));
@@ -937,7 +937,7 @@ event_page_set_meeting (EventPage *page, gboolean set)
sensitize_widgets (page);
}
-void
+void
event_page_set_delegate (EventPage *page, gboolean set)
{
g_return_if_fail (IS_EVENT_PAGE (page));
@@ -950,17 +950,17 @@ event_page_set_delegate (EventPage *page, gboolean set)
static EAccount *
get_current_account (EventPage *epage)
-{
+{
EventPagePrivate *priv;
EIterator *it;
const char *str;
-
+
priv = epage->priv;
str = gtk_entry_get_text (GTK_ENTRY (GTK_COMBO (priv->organizer)->entry));
if (!str)
return NULL;
-
+
for (it = e_list_get_iterator((EList *)priv->accounts); e_iterator_is_valid(it); e_iterator_next(it)) {
EAccount *a = (EAccount *)e_iterator_get(it);
char *full = g_strdup_printf("%s <%s>", a->id->name, a->id->address);
@@ -971,12 +971,12 @@ get_current_account (EventPage *epage)
return a;
}
-
+
g_free (full);
}
g_object_unref (it);
-
- return NULL;
+
+ return NULL;
}
/* fill_widgets handler for the event page */
@@ -994,7 +994,7 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
gchar *backend_addr = NULL;
GSList *l;
gboolean validated = TRUE;
-
+
g_return_val_if_fail (page->client != NULL, FALSE);
epage = EVENT_PAGE (page);
@@ -1005,15 +1005,15 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
/* Don't send off changes during this time */
priv->updating = TRUE;
-
+
/* Clean out old data */
if (priv->comp != NULL)
g_object_unref (priv->comp);
priv->comp = NULL;
-
+
cleanup_attendees (priv->deleted_attendees);
g_ptr_array_set_size (priv->deleted_attendees, 0);
-
+
/* Clean the page */
clear_widgets (epage);
@@ -1021,18 +1021,18 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
/* Component for cancellation */
priv->comp = e_cal_component_clone (comp);
-
+
e_cal_component_get_summary (comp, &text);
e_dialog_editable_set (priv->summary, text.value);
priv->old_summary = g_strdup (text.value);
-
+
e_cal_component_get_location (comp, &location);
e_dialog_editable_set (priv->location, location);
e_cal_component_get_description_list (comp, &l);
if (l && l->data) {
ECalComponentText *dtext;
-
+
dtext = l->data;
gtk_text_buffer_set_text (gtk_text_view_get_buffer (GTK_TEXT_VIEW (priv->description)),
dtext->value ? dtext->value : "", -1);
@@ -1043,9 +1043,9 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
set_subscriber_info_string (epage, backend_addr);
if (priv->is_meeting) {
- ECalComponentOrganizer organizer;
+ ECalComponentOrganizer organizer;
- priv->user_add = itip_get_comp_attendee (comp, COMP_EDITOR_PAGE (epage)->client);
+ priv->user_add = itip_get_comp_attendee (comp, COMP_EDITOR_PAGE (epage)->client);
/* Organizer strings */
event_page_select_organizer (epage, backend_addr);
@@ -1057,7 +1057,7 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
const gchar *strip = itip_strip_mailto (organizer.value);
gchar *string;
GList *list = NULL;
-
+
if (itip_organizer_is_user (comp, page->client) || itip_sentby_is_user (comp)) {
if (e_cal_get_static_capability (
page->client,
@@ -1105,7 +1105,7 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
if (!(backend_addr && *backend_addr) || !g_ascii_strcasecmp (backend_addr, a->id->address)) {
e_meeting_attendee_set_address (priv->ia, g_strdup_printf ("MAILTO:%s", a->id->address));
e_meeting_attendee_set_cn (priv->ia, g_strdup (a->id->name));
- } else {
+ } else {
e_meeting_attendee_set_address (priv->ia, g_strdup_printf ("MAILTO:%s", backend_addr));
e_meeting_attendee_set_sentby (priv->ia, g_strdup_printf ("MAILTO:%s", a->id->address));
}
@@ -1120,7 +1120,7 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
}
}
- if (backend_addr)
+ if (backend_addr)
g_free (backend_addr);
/* Start and end times */
@@ -1134,7 +1134,7 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
validated = FALSE;
} else
update_time (epage, &start_date, &end_date);
-
+
e_cal_component_free_datetime (&start_date);
e_cal_component_free_datetime (&end_date);
@@ -1175,22 +1175,22 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
/* Alarms */
g_signal_handlers_block_matched (priv->alarm_time, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, epage);
g_signal_handlers_block_matched (priv->alarm_list_store, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, epage);
-
+
if (e_cal_component_has_alarms (comp)) {
GList *alarms, *list;
int alarm_type;
-
+
alarms = e_cal_component_get_alarm_uids (comp);
if (!is_custom_alarm_uid_list (comp, alarms, priv->old_summary, priv->alarm_units, priv->alarm_interval, &alarm_type))
e_dialog_option_menu_set (priv->alarm_time, alarm_type, alarm_map);
- else
+ else
e_dialog_option_menu_set (priv->alarm_time, ALARM_CUSTOM, alarm_map);
-
+
for (list = alarms; list != NULL; list = list->next) {
ECalComponentAlarm *ca;
-
+
ca = e_cal_component_get_alarm (comp, list->data);
- e_alarm_list_append (priv->alarm_list_store, NULL, ca);
+ e_alarm_list_append (priv->alarm_list_store, NULL, ca);
e_cal_component_alarm_free (ca);
}
@@ -1204,14 +1204,14 @@ event_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
/* Categories */
e_cal_component_get_categories (comp, &categories);
e_dialog_editable_set (priv->categories, categories);
-
+
/* Source */
e_source_combo_box_set_active (
E_SOURCE_COMBO_BOX (priv->source_selector),
e_cal_get_source (page->client));
e_cal_component_get_uid (comp, &uid);
- if (!(COMP_EDITOR_PAGE (epage)->flags & COMP_EDITOR_PAGE_DELEGATE)
+ if (!(COMP_EDITOR_PAGE (epage)->flags & COMP_EDITOR_PAGE_DELEGATE)
&& !(COMP_EDITOR_PAGE (epage)->flags && COMP_EDITOR_PAGE_NEW_ITEM)) {
event_page_hide_options (epage);
}
@@ -1377,7 +1377,7 @@ event_page_fill_component (CompEditorPage *page, ECalComponent *comp)
e_cal_component_set_transparency (comp, busy ? E_CAL_COMPONENT_TRANSP_OPAQUE : E_CAL_COMPONENT_TRANSP_TRANSPARENT);
/* send options */
- if (priv->sendoptions_shown && priv->sod)
+ if (priv->sendoptions_shown && priv->sod)
e_sendoptions_utils_fill_component (priv->sod, comp);
/* Alarm */
@@ -1389,19 +1389,19 @@ event_page_fill_component (CompEditorPage *page, ECalComponent *comp)
gboolean valid_iter;
model = GTK_TREE_MODEL (priv->alarm_list_store);
-
+
for (valid_iter = gtk_tree_model_get_iter_first (model, &iter); valid_iter;
valid_iter = gtk_tree_model_iter_next (model, &iter)) {
ECalComponentAlarm *alarm, *alarm_copy;
icalcomponent *icalcomp;
icalproperty *icalprop;
-
+
alarm = (ECalComponentAlarm *) e_alarm_list_get_alarm (priv->alarm_list_store, &iter);
if (!alarm) {
g_warning ("alarm is NULL\n");
continue;
}
-
+
/* We set the description of the alarm if it's got
* the X-EVOLUTION-NEEDS-DESCRIPTION property.
*/
@@ -1438,51 +1438,51 @@ event_page_fill_component (CompEditorPage *page, ECalComponent *comp)
int alarm_type;
ca = e_cal_component_alarm_new ();
-
+
e_cal_component_get_summary (comp, &summary);
-
+
if (summary.value)
e_cal_component_alarm_set_description (ca, &summary);
-
+
e_cal_component_alarm_set_action (ca, E_CAL_COMPONENT_ALARM_DISPLAY);
memset (&trigger, 0, sizeof (ECalComponentAlarmTrigger));
- trigger.type = E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_START;
+ trigger.type = E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_START;
trigger.u.rel_duration.is_neg = 1;
-
+
alarm_type = e_dialog_option_menu_get (priv->alarm_time, alarm_map);
switch (alarm_type) {
case ALARM_15_MINUTES:
trigger.u.rel_duration.minutes = 15;
break;
-
+
case ALARM_1_HOUR:
trigger.u.rel_duration.hours = 1;
break;
-
+
case ALARM_1_DAY:
trigger.u.rel_duration.days = 1;
break;
case ALARM_USER_TIME:
switch (calendar_config_get_default_reminder_units ()) {
- case CAL_DAYS:
+ case CAL_DAYS:
trigger.u.rel_duration.days = priv->alarm_interval;
break;
-
+
case CAL_HOURS:
trigger.u.rel_duration.hours = priv->alarm_interval;
break;
-
+
case CAL_MINUTES:
trigger.u.rel_duration.minutes = priv->alarm_interval;
break;
}
break;
-
+
default:
break;
- }
+ }
e_cal_component_alarm_set_trigger (ca, trigger);
e_cal_component_add_alarm (comp, ca);
@@ -1495,9 +1495,9 @@ event_page_fill_component (CompEditorPage *page, ECalComponent *comp)
if (!priv->existing) {
EAccount *a;
gchar *backend_addr = NULL, *org_addr = NULL, *sentby = NULL;
-
+
e_cal_get_cal_address (priv->client, &backend_addr, NULL);
-
+
/* Find the identity for the organizer or sentby field */
a = get_current_account (epage);
@@ -1505,14 +1505,14 @@ event_page_fill_component (CompEditorPage *page, ECalComponent *comp)
if (a == NULL) {
e_notice (page, GTK_MESSAGE_ERROR,
_("The organizer selected no longer has an account."));
- return FALSE;
+ return FALSE;
}
if (a->id->address == NULL || strlen (a->id->address) == 0) {
e_notice (page, GTK_MESSAGE_ERROR,
_("An organizer is required."));
return FALSE;
- }
+ }
if (!(backend_addr && *backend_addr) || !g_ascii_strcasecmp (backend_addr, a->id->address)) {
org_addr = g_strdup_printf ("MAILTO:%s", a->id->address);
@@ -1569,7 +1569,7 @@ event_page_fill_component (CompEditorPage *page, ECalComponent *comp)
}
e_cal_component_set_attendee_list (comp, attendee_list);
e_cal_component_free_attendee_list (attendee_list);
- } else
+ } else
set_attendees (comp, e_meeting_store_get_attendees (priv->model));
}
@@ -1613,7 +1613,7 @@ event_page_set_summary (CompEditorPage *page, const char *summary)
static void
event_page_set_dates (CompEditorPage *page, CompEditorPageDates *dates)
-{
+{
update_time (EVENT_PAGE (page), dates->start, dates->end);
}
@@ -1665,7 +1665,7 @@ void update_end_time_selector (EventPage *epage)
e_date_edit_get_time_of_day (E_DATE_EDIT (priv->end_time),
&end_tt.hour,
&end_tt.minute);
-
+
end_timet = icaltime_as_timet (end_tt);
start_timet = icaltime_as_timet (start_tt);
@@ -1726,7 +1726,7 @@ edit_clicked_cb (GtkButton *btn, EventPage *epage)
GtkTreePath *path = NULL;
GtkTreeViewColumn *focus_col;
gint row = 0;
-
+
priv = epage->priv;
gtk_tree_view_get_cursor (GTK_TREE_VIEW (priv->list_view), &path, NULL);
@@ -1754,16 +1754,16 @@ add_clicked_cb (GtkButton *btn, EventPage *epage)
}
static gboolean
-existing_attendee (EMeetingAttendee *ia, ECalComponent *comp)
+existing_attendee (EMeetingAttendee *ia, ECalComponent *comp)
{
GSList *attendees, *l;
const gchar *ia_address;
const gchar *ia_sentby = NULL;
-
+
ia_address = itip_strip_mailto (e_meeting_attendee_get_address (ia));
if (!ia_address)
return FALSE;
-
+
if (e_meeting_attendee_is_set_sentby (ia))
ia_sentby = itip_strip_mailto (e_meeting_attendee_get_sentby (ia));
@@ -1773,7 +1773,7 @@ existing_attendee (EMeetingAttendee *ia, ECalComponent *comp)
ECalComponentAttendee *attendee = l->data;
const char *address;
const char *sentby = NULL;
-
+
address = itip_strip_mailto (attendee->value);
if (attendee->sentby)
sentby = itip_strip_mailto (attendee->sentby);
@@ -1783,19 +1783,19 @@ existing_attendee (EMeetingAttendee *ia, ECalComponent *comp)
return TRUE;
}
}
-
+
e_cal_component_free_attendee_list (attendees);
-
+
return FALSE;
}
static void
-remove_attendee (EventPage *epage, EMeetingAttendee *ia)
+remove_attendee (EventPage *epage, EMeetingAttendee *ia)
{
EventPagePrivate *priv;
int pos = 0;
gboolean delegate = (COMP_EDITOR_PAGE (epage)->flags & COMP_EDITOR_PAGE_DELEGATE);
-
+
priv = epage->priv;
/* If the user deletes the organizer attendee explicitly,
@@ -1803,22 +1803,22 @@ remove_attendee (EventPage *epage, EMeetingAttendee *ia)
if (ia == priv->ia) {
g_object_unref (priv->ia);
priv->ia = NULL;
- }
-
+ }
+
/* If this was a delegatee, no longer delegate */
if (e_meeting_attendee_is_set_delfrom (ia)) {
EMeetingAttendee *ib;
-
+
ib = e_meeting_store_find_attendee (priv->model, e_meeting_attendee_get_delfrom (ia), &pos);
if (ib != NULL) {
e_meeting_attendee_set_delto (ib, NULL);
-
- if (!delegate)
+
+ if (!delegate)
e_meeting_attendee_set_edit_level (ib, E_MEETING_ATTENDEE_EDIT_FULL);
- }
+ }
}
-
- /* Handle deleting all attendees in the delegation chain */
+
+ /* Handle deleting all attendees in the delegation chain */
while (ia != NULL) {
EMeetingAttendee *ib = NULL;
@@ -1826,16 +1826,16 @@ remove_attendee (EventPage *epage, EMeetingAttendee *ia)
g_object_ref (ia);
g_ptr_array_add (priv->deleted_attendees, ia);
}
-
+
if (e_meeting_attendee_get_delto (ia) != NULL)
ib = e_meeting_store_find_attendee (priv->model, e_meeting_attendee_get_delto (ia), NULL);
-
+
e_meeting_list_view_remove_attendee_from_name_selector (priv->list_view, ia);
e_meeting_store_remove_attendee (priv->model, ia);
ia = ib;
}
-
+
sensitize_widgets (epage);
}
@@ -1851,7 +1851,7 @@ remove_clicked_cb (GtkButton *btn, EventPage *epage)
GtkTreeModel *model = NULL;
gboolean valid_iter;
char *address;
-
+
priv = epage->priv;
selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (priv->list_view));
@@ -1861,10 +1861,10 @@ remove_clicked_cb (GtkButton *btn, EventPage *epage)
return;
}
paths = g_list_reverse (paths);
-
+
for (tmp = paths; tmp; tmp=tmp->next) {
path = tmp->data;
-
+
gtk_tree_model_get_iter (GTK_TREE_MODEL(priv->model), &iter, path);
gtk_tree_model_get (GTK_TREE_MODEL (priv->model), &iter, E_MEETING_STORE_ADDRESS_COL, &address, -1);
@@ -1874,35 +1874,35 @@ remove_clicked_cb (GtkButton *btn, EventPage *epage)
g_warning ("Cannot delete attendee\n");
continue;
} else if (e_meeting_attendee_get_edit_level (ia) != E_MEETING_ATTENDEE_EDIT_FULL) {
- g_warning("Not enough rights to delete attendee: %s\n", e_meeting_attendee_get_address(ia));
+ g_warning("Not enough rights to delete attendee: %s\n", e_meeting_attendee_get_address(ia));
continue;
}
-
+
remove_attendee (epage, ia);
}
-
+
/* Select closest item after removal */
valid_iter = gtk_tree_model_get_iter (GTK_TREE_MODEL (priv->model), &iter, path);
if (!valid_iter) {
gtk_tree_path_prev (path);
valid_iter = gtk_tree_model_get_iter (GTK_TREE_MODEL (priv->model), &iter, path);
}
-
+
if (valid_iter) {
gtk_tree_selection_unselect_all (selection);
gtk_tree_selection_select_iter (selection, &iter);
}
-
+
g_list_foreach (paths, (GFunc) gtk_tree_path_free, NULL);
g_list_free (paths);
}
static void
-invite_cb (GtkWidget *widget, gpointer data)
+invite_cb (GtkWidget *widget, gpointer data)
{
EventPage *page;
EventPagePrivate *priv;
-
+
page = EVENT_PAGE (data);
priv = page->priv;
@@ -1912,7 +1912,7 @@ invite_cb (GtkWidget *widget, gpointer data)
static void
attendee_added_cb (EMeetingListView *emlv, EMeetingAttendee *ia, gpointer user_data)
{
- EventPage *epage = EVENT_PAGE (user_data);
+ EventPage *epage = EVENT_PAGE (user_data);
EventPagePrivate *priv;
gboolean delegate = (COMP_EDITOR_PAGE (epage)->flags & COMP_EDITOR_PAGE_DELEGATE);
@@ -1922,15 +1922,15 @@ attendee_added_cb (EMeetingListView *emlv, EMeetingAttendee *ia, gpointer user_d
if (existing_attendee (ia, priv->comp))
e_meeting_store_remove_attendee (priv->model, ia);
else {
- if (!e_cal_get_static_capability (COMP_EDITOR_PAGE(epage)->client,
+ if (!e_cal_get_static_capability (COMP_EDITOR_PAGE(epage)->client,
CAL_STATIC_CAPABILITY_DELEGATE_TO_MANY)) {
const char *delegator_id = e_meeting_attendee_get_delfrom (ia);
EMeetingAttendee *delegator;
delegator = e_meeting_store_find_attendee (priv->model, delegator_id, NULL);
- e_meeting_attendee_set_delto (delegator,
+ e_meeting_attendee_set_delto (delegator,
g_strdup (e_meeting_attendee_get_address (ia)));
-
+
e_meeting_attendee_set_delfrom (ia, g_strdup_printf ("MAILTO:%s", delegator_id));
gtk_widget_set_sensitive (priv->invite, FALSE);
gtk_widget_set_sensitive (priv->add, FALSE);
@@ -1954,7 +1954,7 @@ static void
popup_delete_cb (EPopup *ep, EPopupItem *pitem, void *data)
{
EventPage *epage = data;
-
+
remove_clicked_cb (NULL, epage);
}
@@ -1967,7 +1967,7 @@ enum {
static EPopupItem context_menu_items[] = {
{ E_POPUP_ITEM, "10.delete", N_("_Remove"), popup_delete_cb, NULL, GTK_STOCK_REMOVE, ATTENDEE_CAN_DELETE },
- { E_POPUP_ITEM, "15.add", N_("_Add "), popup_add_cb, NULL, GTK_STOCK_ADD, ATTENDEE_CAN_ADD },
+ { E_POPUP_ITEM, "15.add", N_("_Add "), popup_add_cb, NULL, GTK_STOCK_ADD, ATTENDEE_CAN_ADD },
};
static void
@@ -2000,7 +2000,7 @@ button_press_event (GtkWidget *widget, GdkEventButton *event, EventPage *epage)
GtkTreeSelection *selection;
if (gtk_tree_model_get_iter (GTK_TREE_MODEL (priv->model), &iter, path)) {
-
+
gtk_tree_model_get (GTK_TREE_MODEL (priv->model), &iter, E_MEETING_STORE_ADDRESS_COL, &address, -1);
ia = e_meeting_store_find_attendee (priv->model, address, &priv->row);
g_free (address);
@@ -2009,7 +2009,7 @@ button_press_event (GtkWidget *widget, GdkEventButton *event, EventPage *epage)
selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (priv->list_view));
gtk_tree_selection_unselect_all (selection);
gtk_tree_selection_select_path (selection, path);
-
+
if (e_meeting_attendee_get_edit_level (ia) == E_MEETING_ATTENDEE_EDIT_FULL)
disable_mask &= ~ATTENDEE_CAN_DELETE;
}
@@ -2025,7 +2025,7 @@ button_press_event (GtkWidget *widget, GdkEventButton *event, EventPage *epage)
for (i=0;i<sizeof(context_menu_items)/sizeof(context_menu_items[0]);i++)
menus = g_slist_prepend(menus, &context_menu_items[i]);
-
+
e_popup_add_items((EPopup *)ep, menus, NULL, context_popup_free, epage);
menu = e_popup_create_menu_once((EPopup *)ep, NULL, disable_mask);
gtk_menu_popup (menu, NULL, NULL, NULL, NULL, event->button, event->time);
@@ -2035,9 +2035,9 @@ button_press_event (GtkWidget *widget, GdkEventButton *event, EventPage *epage)
static gboolean
list_view_event (EMeetingListView *list_view, GdkEvent *event, EventPage *epage) {
-
+
EventPagePrivate *priv= epage->priv;
-
+
if (event->type == GDK_2BUTTON_PRESS && COMP_EDITOR_PAGE (epage)->flags & COMP_EDITOR_PAGE_USER_ORG) {
EMeetingAttendee *attendee;
@@ -2051,7 +2051,7 @@ list_view_event (EMeetingListView *list_view, GdkEvent *event, EventPage *epage)
return TRUE;
}
- return FALSE;
+ return FALSE;
}
@@ -2059,7 +2059,7 @@ static gboolean
list_key_press (EMeetingListView *list_view, GdkEventKey *event, EventPage *epage)
{
if (event->keyval == GDK_Delete) {
-
+
remove_clicked_cb (NULL, epage);
return TRUE;
@@ -2104,14 +2104,14 @@ event_page_set_all_day_event (EventPage *epage, gboolean all_day)
/* TODO implement the for portion in end time selector */
gtk_widget_set_sensitive (priv->end_time_selector, !all_day);
- if (all_day)
+ if (all_day)
gtk_option_menu_set_history (GTK_OPTION_MENU (priv->end_time_selector), 1);
- else
+ else
gtk_option_menu_set_history (GTK_OPTION_MENU (priv->end_time_selector), 0);
-
+
if (all_day) {
bonobo_ui_component_set_prop (epage->priv->uic, "/commands/ViewTimeZone", "sensitive", "0", NULL);
-
+
/* Round down to the start of the day. */
start_tt.hour = 0;
start_tt.minute = 0;
@@ -2129,7 +2129,7 @@ event_page_set_all_day_event (EventPage *epage, gboolean all_day)
icaltimezone *start_zone;
bonobo_ui_component_set_prop (epage->priv->uic, "/commands/ViewTimeZone", "sensitive", "1", NULL);
-
+
if (end_tt.year == start_tt.year
&& end_tt.month == start_tt.month
&& end_tt.day == start_tt.day) {
@@ -2155,7 +2155,7 @@ event_page_set_all_day_event (EventPage *epage, gboolean all_day)
&end_tt, start_zone,
TRUE);
}
-
+
event_page_set_show_timezone (epage, calendar_config_get_show_timezone() & !all_day);
g_signal_handlers_block_matched (priv->start_time, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, epage);
g_signal_handlers_block_matched (priv->end_time, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, epage);
@@ -2196,17 +2196,17 @@ event_page_show_alarm (EventPage *epage)
gtk_widget_show (epage->priv->alarm_dialog);
}
-void
+void
event_page_set_show_timezone (EventPage *epage, gboolean state)
{
if (state) {
gtk_widget_show_all (epage->priv->start_timezone);
- gtk_widget_show (epage->priv->timezone_label);
+ gtk_widget_show (epage->priv->timezone_label);
} else {
gtk_widget_hide (epage->priv->start_timezone);
gtk_widget_hide (epage->priv->timezone_label);
}
-
+
}
void
@@ -2214,7 +2214,7 @@ event_page_set_show_categories (EventPage *epage, gboolean state)
{
if (state) {
gtk_widget_show (epage->priv->categories_btn);
- gtk_widget_show (epage->priv->categories);
+ gtk_widget_show (epage->priv->categories);
} else {
gtk_widget_hide (epage->priv->categories_btn);
gtk_widget_hide (epage->priv->categories);
@@ -2222,7 +2222,7 @@ event_page_set_show_categories (EventPage *epage, gboolean state)
}
/*If the msg has some value set, the icon should always be set */
-void
+void
event_page_set_info_string (EventPage *epage, const gchar *icon, const gchar *msg)
{
EventPagePrivate *priv;
@@ -2232,10 +2232,10 @@ event_page_set_info_string (EventPage *epage, const gchar *icon, const gchar *ms
gtk_image_set_from_stock (GTK_IMAGE (priv->info_icon), icon, GTK_ICON_SIZE_BUTTON);
gtk_label_set_text (GTK_LABEL(priv->info_string), msg);
- if (msg && icon)
- gtk_widget_show (priv->info_hbox);
- else
- gtk_widget_hide (priv->info_hbox);
+ if (msg && icon)
+ gtk_widget_show (priv->info_hbox);
+ else
+ gtk_widget_hide (priv->info_hbox);
}
/* Gets the widgets from the XML file and returns if they are all available. */
@@ -2285,7 +2285,7 @@ get_widgets (EventPage *epage)
g_object_ref (priv->main);
gtk_container_remove (GTK_CONTAINER (priv->main->parent), priv->main);
- priv->categories = GW ("categories");
+ priv->categories = GW ("categories");
priv->categories_btn = GW ("categories-button");
priv->organizer = GW ("organizer");
priv->summary = GW ("summary");
@@ -2302,30 +2302,30 @@ get_widgets (EventPage *epage)
priv->remove = GW ("remove-attendee");
priv->edit = GW ("edit-attendee");
priv->list_box = GW ("list-box");
-
+
priv->calendar_label = GW ("calendar-label");
priv->attendee_box = GW ("attendee-box");
priv->org_cal_label = GW ("org-cal-label");
priv->list_view = e_meeting_list_view_new (priv->model);
-
+
sw = gtk_scrolled_window_new (NULL, NULL);
gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (sw), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (sw), GTK_SHADOW_IN);
gtk_widget_show (sw);
gtk_container_add (GTK_CONTAINER (sw), GTK_WIDGET (priv->list_view));
gtk_box_pack_start (GTK_BOX (priv->list_box), sw, TRUE, TRUE, 0);
-
+
/* Glade's visibility flag doesn't seem to work for custom widgets */
priv->start_time = GW ("start-time");
gtk_widget_show (priv->start_time);
-
+
priv->time_hour = GW ("time-hour");
priv->hour_selector = GW ("hour_selector");
priv->minute_selector = GW ("minute_selector");
priv->end_time_selector = GW ("end-time-selector");
-
+
priv->end_time = GW ("end-time");
gtk_widget_show_all (priv->time_hour);
gtk_widget_hide (priv->end_time);
@@ -2374,13 +2374,13 @@ summary_changed_cb (GtkEditable *editable, gpointer data)
EventPage *epage;
EventPagePrivate *priv;
gchar *summary;
-
+
epage = EVENT_PAGE (data);
priv = epage->priv;
-
+
if (priv->updating)
return;
-
+
summary = e_dialog_editable_get (GTK_WIDGET (editable));
comp_editor_page_notify_summary_changed (COMP_EDITOR_PAGE (epage),
summary);
@@ -2401,7 +2401,7 @@ notify_dates_changed (EventPage *epage, struct icaltimetype *start_tt,
gboolean all_day_event;
icaltimezone *start_zone = NULL;
priv = epage->priv;
-
+
all_day_event = priv->all_day_event;
start_dt.value = start_tt;
@@ -2485,7 +2485,7 @@ times_updated (EventPage *epage, gboolean adjust_end_time)
gboolean date_set, all_day_event;
gboolean set_start_date = FALSE, set_end_date = FALSE;
icaltimezone *start_zone;
-
+
priv = epage->priv;
if (priv->updating)
@@ -2575,7 +2575,7 @@ static void
start_date_changed_cb (GtkWidget *dedit, gpointer data)
{
EventPage *epage;
-
+
epage = EVENT_PAGE (data);
hour_minute_changed (epage);
@@ -2590,7 +2590,7 @@ static void
end_date_changed_cb (GtkWidget *dedit, gpointer data)
{
EventPage *epage;
-
+
epage = EVENT_PAGE (data);
times_updated (epage, FALSE);
@@ -2654,9 +2654,9 @@ event_page_sendoptions_clicked_cb (EventPage *epage)
E_SOURCE_COMBO_BOX (priv->source_selector));
e_sendoptions_utils_set_default_data (priv->sod, source, "calendar");
priv->sod->data->initialized = TRUE;
- }
+ }
- if (e_cal_get_static_capability (COMP_EDITOR_PAGE (epage)->client,
+ if (e_cal_get_static_capability (COMP_EDITOR_PAGE (epage)->client,
CAL_STATIC_CAPABILITY_NO_GEN_OPTIONS)) {
e_sendoptions_set_need_general_options (priv->sod, FALSE);
}
@@ -2671,10 +2671,10 @@ field_changed_cb (GtkWidget *widget, gpointer data)
{
EventPage *epage;
EventPagePrivate *priv;
-
+
epage = EVENT_PAGE (data);
priv = epage->priv;
-
+
if (!priv->updating)
comp_editor_page_notify_changed (COMP_EDITOR_PAGE (epage));
}
@@ -2693,7 +2693,7 @@ source_changed_cb (ESourceComboBox *source_combo_box, EventPage *epage)
client = auth_new_cal_from_source (source, E_CAL_SOURCE_TYPE_EVENT);
if (client) {
icaltimezone *zone;
-
+
zone = calendar_config_get_icaltimezone ();
e_cal_set_default_timezone (client, zone, NULL);
}
@@ -2727,7 +2727,7 @@ source_changed_cb (ESourceComboBox *source_combo_box, EventPage *epage)
gchar *backend_addr = NULL;
e_cal_get_cal_address(client, &backend_addr, NULL);
-
+
if (priv->is_meeting)
event_page_select_organizer (epage, backend_addr);
@@ -2747,13 +2747,13 @@ set_subscriber_info_string (EventPage *epage, const char *backend_address)
{
ECal *client = COMP_EDITOR_PAGE (epage)->client;
ESource *source;
-
+
source = e_cal_get_source (client);
-
+
if (e_source_get_property (source, "subscriber"))
- /* Translators: This string is used when we are creating an Event
+ /* Translators: This string is used when we are creating an Event
(meeting or appointment) on behalf of some other user */
- event_page_set_info_string (epage, GTK_STOCK_DIALOG_INFO,
+ event_page_set_info_string (epage, GTK_STOCK_DIALOG_INFO,
g_strdup_printf(_("You are acting on behalf of %s"), backend_address));
else
event_page_set_info_string (epage, NULL, NULL);
@@ -2764,7 +2764,7 @@ alarm_changed_cb (GtkWidget *widget, gpointer data)
{
EventPage *epage;
EventPagePrivate *priv;
-
+
epage = EVENT_PAGE (data);
priv = epage->priv;
@@ -2774,43 +2774,43 @@ alarm_changed_cb (GtkWidget *widget, gpointer data)
icalcomponent *icalcomp;
icalproperty *icalprop;
int alarm_type;
-
- ca = e_cal_component_alarm_new ();
-
+
+ ca = e_cal_component_alarm_new ();
+
e_cal_component_alarm_set_action (ca, E_CAL_COMPONENT_ALARM_DISPLAY);
memset (&trigger, 0, sizeof (ECalComponentAlarmTrigger));
- trigger.type = E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_START;
+ trigger.type = E_CAL_COMPONENT_ALARM_TRIGGER_RELATIVE_START;
trigger.u.rel_duration.is_neg = 1;
-
+
alarm_type = e_dialog_option_menu_get (priv->alarm_time, alarm_map);
switch (alarm_type) {
case ALARM_15_MINUTES:
e_alarm_list_clear (priv->alarm_list_store);
trigger.u.rel_duration.minutes = 15;
break;
-
+
case ALARM_1_HOUR:
e_alarm_list_clear (priv->alarm_list_store);
trigger.u.rel_duration.hours = 1;
break;
-
+
case ALARM_1_DAY:
- e_alarm_list_clear (priv->alarm_list_store);
+ e_alarm_list_clear (priv->alarm_list_store);
trigger.u.rel_duration.days = 1;
break;
case ALARM_USER_TIME:
- e_alarm_list_clear (priv->alarm_list_store);
+ e_alarm_list_clear (priv->alarm_list_store);
switch (calendar_config_get_default_reminder_units ()) {
- case CAL_DAYS:
+ case CAL_DAYS:
trigger.u.rel_duration.days = priv->alarm_interval;
break;
-
+
case CAL_HOURS:
trigger.u.rel_duration.hours = priv->alarm_interval;
break;
-
+
case CAL_MINUTES:
trigger.u.rel_duration.minutes = priv->alarm_interval;
break;
@@ -2818,14 +2818,14 @@ alarm_changed_cb (GtkWidget *widget, gpointer data)
break;
case ALARM_CUSTOM:
gtk_widget_set_sensitive (priv->alarm_box, TRUE);
-
+
default:
break;
}
-
+
if (alarm_type != ALARM_CUSTOM) {
e_cal_component_alarm_set_trigger (ca, trigger);
-
+
icalcomp = e_cal_component_alarm_get_icalcomponent (ca);
icalprop = icalproperty_new_x ("1");
icalproperty_set_x_name (icalprop, "X-EVOLUTION-NEEDS-DESCRIPTION");
@@ -2843,24 +2843,24 @@ alarm_changed_cb (GtkWidget *widget, gpointer data)
gtk_container_remove (GTK_CONTAINER (priv->status_icons), priv->alarm_icon);
priv->alarm_icon = NULL;
}
- }
-
- sensitize_widgets (epage);
+ }
+
+ sensitize_widgets (epage);
}
-static void
+static void
alarm_store_inserted_cb (EAlarmList *alarm_list_store, GtkTreePath *path, GtkTreeIter *iter, gpointer data)
{
field_changed_cb (NULL, data);
}
-static void
+static void
alarm_store_deleted_cb (EAlarmList *alarm_list_store, GtkTreePath *path, gpointer data)
{
field_changed_cb (NULL, data);
}
-static void
+static void
alarm_store_changed_cb (EAlarmList *alarm_list_store, GtkTreePath *path, GtkTreeIter *iter, gpointer data)
{
field_changed_cb (NULL, data);
@@ -2877,18 +2877,18 @@ alarm_custom_clicked_cb (GtkWidget *widget, gpointer data)
GtkTreeIter iter;
gboolean valid_iter;
GtkWidget *toplevel;
-
+
epage = EVENT_PAGE (data);
priv = epage->priv;
/* Make a copy of the list store in case the user cancels */
temp_list_store = e_alarm_list_new ();
model = GTK_TREE_MODEL (priv->alarm_list_store);
-
+
for (valid_iter = gtk_tree_model_get_iter_first (model, &iter); valid_iter;
valid_iter = gtk_tree_model_iter_next (model, &iter)) {
ECalComponentAlarm *alarm;
-
+
alarm = (ECalComponentAlarm *) e_alarm_list_get_alarm (priv->alarm_list_store, &iter);
if (alarm == NULL) {
g_warning ("alarm is NULL\n");
@@ -2896,18 +2896,18 @@ alarm_custom_clicked_cb (GtkWidget *widget, gpointer data)
}
e_alarm_list_append (temp_list_store, NULL, alarm);
- }
-
+ }
+
toplevel = gtk_widget_get_toplevel (priv->main);
if (alarm_list_dialog_run (toplevel, COMP_EDITOR_PAGE (epage)->client, temp_list_store)) {
g_object_unref (priv->alarm_list_store);
priv->alarm_list_store = temp_list_store;
- comp_editor_page_notify_changed (COMP_EDITOR_PAGE (epage));
+ comp_editor_page_notify_changed (COMP_EDITOR_PAGE (epage));
} else {
g_object_unref (temp_list_store);
- }
-
+ }
+
/* If the user erases everything, uncheck the alarm toggle */
valid_iter = gtk_tree_model_get_iter_first (GTK_TREE_MODEL (priv->alarm_list_store), &iter);
@@ -2925,7 +2925,7 @@ init_widgets (EventPage *epage)
char *menu_label = NULL;
GtkTreeSelection *selection;
GtkWidget *cus_item, *menu;
-
+
priv = epage->priv;
/* Make sure the EDateEdit widgets use our timezones to get the
@@ -2967,7 +2967,7 @@ init_widgets (EventPage *epage)
/* Categories */
g_signal_connect((priv->categories_btn), "clicked",
G_CALLBACK (categories_clicked_cb), epage);
-
+
/* Source selector */
g_signal_connect((priv->source_selector), "changed",
G_CALLBACK (source_changed_cb), epage);
@@ -2984,19 +2984,19 @@ init_widgets (EventPage *epage)
g_signal_connect((priv->start_timezone), "changed",
G_CALLBACK (start_timezone_changed_cb), epage);
- e_meeting_list_view_column_set_visible (priv->list_view, "Attendee ",
+ e_meeting_list_view_column_set_visible (priv->list_view, "Attendee ",
TRUE);
e_meeting_list_view_column_set_visible (priv->list_view, "Role", calendar_config_get_show_role());
e_meeting_list_view_column_set_visible (priv->list_view, "RSVP", calendar_config_get_show_rsvp());
e_meeting_list_view_column_set_visible (priv->list_view, "Status", calendar_config_get_show_status());
e_meeting_list_view_column_set_visible (priv->list_view, "Type", calendar_config_get_show_type());
-
+
selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (priv->list_view));
gtk_tree_selection_set_mode (selection, GTK_SELECTION_MULTIPLE);
g_signal_connect (G_OBJECT (priv->list_view), "button_press_event", G_CALLBACK (button_press_event), epage);
g_signal_connect (G_OBJECT (priv->list_view), "event", G_CALLBACK (list_view_event), epage);
- g_signal_connect (priv->list_view, "key_press_event", G_CALLBACK (list_key_press), epage);
+ g_signal_connect (priv->list_view, "key_press_event", G_CALLBACK (list_key_press), epage);
/* Add attendee button */
g_signal_connect (priv->add, "clicked", G_CALLBACK (add_clicked_cb), epage);
@@ -3008,7 +3008,7 @@ init_widgets (EventPage *epage)
g_signal_connect (priv->edit, "clicked", G_CALLBACK (edit_clicked_cb), epage);
/* Contacts button */
- g_signal_connect(priv->invite, "clicked", G_CALLBACK (invite_cb), epage);
+ g_signal_connect(priv->invite, "clicked", G_CALLBACK (invite_cb), epage);
/* Alarm dialog */
g_signal_connect (GTK_DIALOG (priv->alarm_dialog), "response", G_CALLBACK (gtk_widget_hide), priv->alarm_dialog);
@@ -3020,7 +3020,7 @@ init_widgets (EventPage *epage)
gtk_window_set_modal (GTK_WINDOW (priv->alarm_dialog), TRUE);
/* Meeting List View */
- g_signal_connect (priv->list_view, "attendee_added", G_CALLBACK (attendee_added_cb), epage);
+ g_signal_connect (priv->list_view, "attendee_added", G_CALLBACK (attendee_added_cb), epage);
gtk_widget_show (GTK_WIDGET (priv->list_view));
@@ -3031,7 +3031,7 @@ init_widgets (EventPage *epage)
} else {
gtk_widget_show (priv->categories_btn);
gtk_widget_show (priv->categories);
- }
+ }
/* End time selector */
gtk_option_menu_set_history (GTK_OPTION_MENU (priv->end_time_selector), 1);
@@ -3049,24 +3049,24 @@ init_widgets (EventPage *epage)
priv->alarm_units = calendar_config_get_default_reminder_units ();
priv->alarm_interval = calendar_config_get_default_reminder_interval ();
- menu_label = "";
+ menu_label = "";
switch (priv->alarm_units) {
case CAL_DAYS:
if (priv->alarm_interval != 1) {
menu_label = g_strdup_printf (ngettext("%d day before appointment", "%d days before appointment", priv->alarm_interval), priv->alarm_interval);
- }
+ }
break;
-
+
case CAL_HOURS:
if (priv->alarm_interval != 1) {
menu_label = g_strdup_printf (ngettext("%d hour before appointment", "%d hours before appointment", priv->alarm_interval), priv->alarm_interval);
- }
+ }
break;
-
+
case CAL_MINUTES:
if (priv->alarm_interval != 15) {
menu_label = g_strdup_printf (ngettext("%d minute before appointment", "%d minutes before appointment", priv->alarm_interval), priv->alarm_interval);
- }
+ }
break;
}
@@ -3076,23 +3076,23 @@ init_widgets (EventPage *epage)
}
menu = gtk_option_menu_get_menu (GTK_OPTION_MENU (priv->alarm_time));
- gtk_menu_shell_append (GTK_MENU_SHELL (menu), cus_item);
+ gtk_menu_shell_append (GTK_MENU_SHELL (menu), cus_item);
cus_item = gtk_menu_item_new_with_label (_("Customize"));
gtk_widget_show (cus_item);
menu = gtk_option_menu_get_menu (GTK_OPTION_MENU (priv->alarm_time));
gtk_menu_shell_append (GTK_MENU_SHELL (menu), cus_item);
-
+
cus_item = gtk_menu_item_new_with_label (_("None"));
gtk_widget_show (cus_item);
menu = gtk_option_menu_get_menu (GTK_OPTION_MENU (priv->alarm_time));
gtk_menu_shell_prepend (GTK_MENU_SHELL (menu), cus_item);
-
+
g_signal_connect (priv->alarm_time, "changed",
G_CALLBACK (field_changed_cb), epage);
g_signal_connect (priv->alarm_time, "changed",
G_CALLBACK (alarm_changed_cb), epage);
-
+
/* Belongs to priv->description */
g_signal_connect((text_buffer), "changed",
G_CALLBACK (field_changed_cb), epage);
@@ -3180,9 +3180,9 @@ event_page_select_organizer (EventPage *epage, const char *backend_address)
/**
* event_page_construct:
* @epage: An event page.
- *
+ *
* Constructs an event page by loading its Glade data.
- *
+ *
* Return value: The same object as @epage, or NULL if the widgets could not be
* created.
**/
@@ -3206,13 +3206,13 @@ event_page_construct (EventPage *epage, EMeetingStore *model, ECal *client)
g_free (gladefile);
if (!priv->xml) {
- g_message ("event_page_construct(): "
+ g_message ("event_page_construct(): "
"Could not load the Glade XML file!");
return NULL;
}
if (!get_widgets (epage)) {
- g_message ("event_page_construct(): "
+ g_message ("event_page_construct(): "
"Could not find all widgets in the XML file!");
return NULL;
}
@@ -3222,10 +3222,10 @@ event_page_construct (EventPage *epage, EMeetingStore *model, ECal *client)
e_iterator_is_valid(it);
e_iterator_next(it)) {
gchar *full = NULL;
-
+
a = (EAccount *)e_iterator_get(it);
-
+
/* skip disabled accounts */
if (!a->enabled)
continue;
@@ -3234,7 +3234,7 @@ event_page_construct (EventPage *epage, EMeetingStore *model, ECal *client)
priv->address_strings = g_list_append(priv->address_strings, full);
}
-
+
g_object_unref(it);
if (priv->address_strings)
@@ -3243,7 +3243,7 @@ event_page_construct (EventPage *epage, EMeetingStore *model, ECal *client)
g_warning ("No potential organizers!");
if (!init_widgets (epage)) {
- g_message ("event_page_construct(): "
+ g_message ("event_page_construct(): "
"Could not initialize the widgets!");
return NULL;
}
@@ -3253,9 +3253,9 @@ event_page_construct (EventPage *epage, EMeetingStore *model, ECal *client)
/**
* event_page_new:
- *
+ *
* Creates a new event page.
- *
+ *
* Return value: A newly-created event page, or NULL if the page could
* not be created.
**/
@@ -3329,22 +3329,22 @@ set_attendees (ECalComponent *comp, const GPtrArray *attendees)
{
GSList *comp_attendees = NULL, *l;
int i;
-
+
for (i = 0; i < attendees->len; i++) {
EMeetingAttendee *ia = g_ptr_array_index (attendees, i);
ECalComponentAttendee *ca;
-
+
ca = e_meeting_attendee_as_e_cal_component_attendee (ia);
-
+
comp_attendees = g_slist_prepend (comp_attendees, ca);
-
+
}
comp_attendees = g_slist_reverse (comp_attendees);
-
+
e_cal_component_set_attendee_list (comp, comp_attendees);
for (l = comp_attendees; l != NULL; l = l->next)
- g_free (l->data);
+ g_free (l->data);
g_slist_free (comp_attendees);
}
@@ -3360,9 +3360,9 @@ event_page_get_cancel_comp (EventPage *page)
if (priv->deleted_attendees->len == 0)
return NULL;
-
+
set_attendees (priv->comp, priv->deleted_attendees);
-
+
return e_cal_component_clone (priv->comp);
}
diff --git a/calendar/gui/dialogs/memo-editor.c b/calendar/gui/dialogs/memo-editor.c
index b6a7de8cf1..1c5b28c512 100644
--- a/calendar/gui/dialogs/memo-editor.c
+++ b/calendar/gui/dialogs/memo-editor.c
@@ -41,8 +41,8 @@
struct _MemoEditorPrivate {
MemoPage *memo_page;
-
- gboolean updating;
+
+ gboolean updating;
};
static void memo_editor_set_e_cal (CompEditor *editor, ECal *client);
@@ -99,11 +99,11 @@ menu_show_categories_cb (BonoboUIComponent *component,
gpointer user_data)
{
MemoEditor *me = (MemoEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- memo_page_set_show_categories (me->priv->memo_page, atoi(state));
+ memo_page_set_show_categories (me->priv->memo_page, atoi(state));
calendar_config_set_show_categories (atoi(state));
}
@@ -133,7 +133,7 @@ menu_class_private_cb (BonoboUIComponent *ui_component,
MemoEditor *me = (MemoEditor *) user_data;
if (state[0] == '0')
return;
-
+
comp_editor_page_notify_changed (COMP_EDITOR_PAGE (me->priv->memo_page));
memo_page_set_classification (me->priv->memo_page, E_CAL_COMPONENT_CLASS_PRIVATE);
}
@@ -161,11 +161,11 @@ memo_editor_init (MemoEditor *me)
CompEditor *editor = COMP_EDITOR(me);
gboolean status;
char *xmlfile;
-
+
priv = g_new0 (MemoEditorPrivate, 1);
me->priv = priv;
- priv->updating = FALSE;
+ priv->updating = FALSE;
bonobo_ui_component_freeze (editor->uic, NULL);
@@ -174,7 +174,7 @@ memo_editor_init (MemoEditor *me)
xmlfile,
"evolution-memo-editor", NULL);
g_free (xmlfile);
-
+
status = calendar_config_get_show_categories ();
bonobo_ui_component_set_prop (
editor->uic, "/commands/ViewCategories",
@@ -196,7 +196,7 @@ memo_editor_init (MemoEditor *me)
editor->uic, "ActionClassConfidential",
menu_class_confidential_cb, editor);
- bonobo_ui_component_thaw (editor->uic, NULL);
+ bonobo_ui_component_thaw (editor->uic, NULL);
/* TODO add help stuff */
/* comp_editor_set_help_section (COMP_EDITOR (me), "usage-calendar-memo"); */
@@ -209,12 +209,12 @@ memo_editor_construct (MemoEditor *me, ECal *client)
CompEditor *editor = COMP_EDITOR (me);
gboolean read_only = FALSE;
guint32 flags = comp_editor_get_flags (editor);
-
+
priv = me->priv;
priv->memo_page = memo_page_new (editor->uic, flags);
g_object_ref_sink (priv->memo_page);
- comp_editor_append_page (COMP_EDITOR (me),
+ comp_editor_append_page (COMP_EDITOR (me),
COMP_EDITOR_PAGE (priv->memo_page),
_("Memo"), TRUE);
g_signal_connect (G_OBJECT (priv->memo_page), "client_changed",
@@ -222,11 +222,11 @@ memo_editor_construct (MemoEditor *me, ECal *client)
if (!e_cal_is_read_only (client, &read_only, NULL))
read_only = TRUE;
-
+
bonobo_ui_component_set_prop (editor->uic, "/Toolbar/ecal3", "hidden", "1", NULL);
comp_editor_set_e_cal (COMP_EDITOR (me), client);
-
-
+
+
init_widgets (me);
@@ -273,7 +273,7 @@ memo_editor_finalize (GObject *object)
g_object_unref (priv->memo_page);
priv->memo_page = NULL;
}
-
+
g_free (priv);
if (G_OBJECT_CLASS (memo_editor_parent_class)->finalize)
diff --git a/calendar/gui/dialogs/memo-page.c b/calendar/gui/dialogs/memo-page.c
index 6255b7aef6..d89e7a4049 100644
--- a/calendar/gui/dialogs/memo-page.c
+++ b/calendar/gui/dialogs/memo-page.c
@@ -83,7 +83,7 @@ struct _MemoPagePrivate {
GtkWidget *to_button;
GtkWidget *to_hbox;
GtkWidget *to_entry;
-
+
/* Summary */
GtkWidget *summary_label;
GtkWidget *summary_entry;
@@ -91,7 +91,7 @@ struct _MemoPagePrivate {
/* Start date */
GtkWidget *start_label;
GtkWidget *start_date;
-
+
GtkWidget *categories_btn;
GtkWidget *categories;
@@ -129,10 +129,10 @@ G_DEFINE_TYPE (MemoPage, memo_page, TYPE_COMP_EDITOR_PAGE)
/**
* memo_page_get_type:
- *
+ *
* Registers the #TaskPage class if necessary, and returns the type ID
* associated to it.
- *
+ *
* Return value: The type ID of the #TaskPage class.
**/
@@ -150,7 +150,7 @@ memo_page_class_init (MemoPageClass *klass)
editor_page_class->focus_main_widget = memo_page_focus_main_widget;
editor_page_class->fill_widgets = memo_page_fill_widgets;
editor_page_class->fill_component = memo_page_fill_component;
-
+
object_class->finalize = memo_page_finalize;
}
@@ -194,7 +194,7 @@ memo_page_finalize (GObject *object)
mpage = MEMO_PAGE (object);
priv = mpage->priv;
-
+
for (l = priv->address_strings; l != NULL; l = l->next)
g_free (l->data);
g_list_free (priv->address_strings);
@@ -286,7 +286,7 @@ clear_widgets (MemoPage *mpage)
e_dialog_editable_set (priv->categories, NULL);
}
-void
+void
memo_page_set_classification (MemoPage *page, ECalComponentClassification class)
{
page->priv->classification = class;
@@ -297,32 +297,32 @@ sensitize_widgets (MemoPage *mpage)
{
gboolean read_only, sens = FALSE, sensitize;
MemoPagePrivate *priv;
-
+
priv = mpage->priv;
if (!e_cal_is_read_only (COMP_EDITOR_PAGE (mpage)->client, &read_only, NULL))
read_only = TRUE;
-
+
if (COMP_EDITOR_PAGE (mpage)->flags & COMP_EDITOR_IS_SHARED)
sens = COMP_EDITOR_PAGE (mpage)->flags & COMP_EDITOR_PAGE_USER_ORG;
else
sens = TRUE;
sensitize = (!read_only && sens);
-
+
priv = mpage->priv;
- /* The list of organizers is set to be non-editable. Otherwise any
- * change in the displayed list causes an 'Account not found' error.
+ /* The list of organizers is set to be non-editable. Otherwise any
+ * change in the displayed list causes an 'Account not found' error.
*/
gtk_editable_set_editable (GTK_EDITABLE (GTK_COMBO (priv->org_combo)->entry), FALSE);
-
+
gtk_text_view_set_editable (GTK_TEXT_VIEW (priv->memo_content), sensitize);
gtk_widget_set_sensitive (priv->start_date, sensitize);
gtk_widget_set_sensitive (priv->categories_btn, !read_only);
gtk_editable_set_editable (GTK_EDITABLE (priv->categories), !read_only);
gtk_editable_set_editable (GTK_EDITABLE (priv->summary_entry), sensitize);
-
+
if (COMP_EDITOR_PAGE (mpage)->flags & COMP_EDITOR_IS_SHARED) {
if (priv->to_entry) {
gtk_editable_set_editable (GTK_EDITABLE (priv->to_entry), !read_only);
@@ -357,18 +357,18 @@ memo_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
priv = mpage->priv;
priv->updating = TRUE;
-
+
/* Clean the screen */
clear_widgets (mpage);
/* Summary */
e_cal_component_get_summary (comp, &text);
e_dialog_editable_set (priv->summary_entry, text.value);
-
+
e_cal_component_get_description_list (comp, &l);
if (l && l->data) {
ECalComponentText *dtext;
-
+
dtext = l->data;
gtk_text_buffer_set_text (gtk_text_view_get_buffer (GTK_TEXT_VIEW (priv->memo_content)),
dtext->value ? dtext->value : "", -1);
@@ -398,7 +398,7 @@ memo_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
break;
}
case E_CAL_COMPONENT_CLASS_PRIVATE:
- {
+ {
cl = E_CAL_COMPONENT_CLASS_PRIVATE;
break;
}
@@ -446,7 +446,7 @@ memo_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
}
}
- if (backend_addr)
+ if (backend_addr)
g_free (backend_addr);
/* Source */
@@ -461,7 +461,7 @@ memo_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
return TRUE;
}
-static gboolean
+static gboolean
fill_comp_with_recipients (ENameSelector *name_selector, ECalComponent *comp)
{
EDestinationStore *destination_store;
@@ -504,16 +504,16 @@ fill_comp_with_recipients (ENameSelector *name_selector, ECalComponent *comp)
break;
}
}
-
+
if (book) {
GList *contacts = NULL;
EContact *n_con = NULL;
char *qu;
EBookQuery *query;
- qu = g_strdup_printf ("(is \"full_name\" \"%s\")",
+ qu = g_strdup_printf ("(is \"full_name\" \"%s\")",
(char *) e_contact_get (contact, E_CONTACT_FULL_NAME));
- query = e_book_query_from_string (qu);
+ query = e_book_query_from_string (qu);
if (!e_book_get_contacts (book, query, &contacts, NULL)) {
g_warning ("Could not get contact from the book \n");
@@ -524,7 +524,7 @@ fill_comp_with_recipients (ENameSelector *name_selector, ECalComponent *comp)
e_destination_set_contact (des, n_con, 0);
list_dests = e_destination_list_get_dests (des);
- g_list_foreach (contacts, (GFunc) g_object_unref, NULL);
+ g_list_foreach (contacts, (GFunc) g_object_unref, NULL);
g_list_free (contacts);
}
@@ -538,22 +538,22 @@ fill_comp_with_recipients (ENameSelector *name_selector, ECalComponent *comp)
card_dest.data = destination;
list_dests = &card_dest;
}
- }
-
+ }
+
for (l = list_dests; l; l = l->next) {
EDestination *dest = l->data;
const char *name, *attendee = NULL;
-
+
name = e_destination_get_name (dest);
/* If we couldn't get the attendee prior, get the email address as the default */
if (attendee == NULL || *attendee == '\0') {
attendee = e_destination_get_email (dest);
}
-
+
if (attendee == NULL || *attendee == '\0')
continue;
-
+
if (!str) {
str = g_string_new (NULL);
g_string_prepend (str, attendee);
@@ -571,7 +571,7 @@ fill_comp_with_recipients (ENameSelector *name_selector, ECalComponent *comp)
icalprop = icalproperty_new_x (str->str);
icalproperty_set_x_name (icalprop, "X-EVOLUTION-RECIPIENTS");
icalcomponent_add_property (icalcomp, icalprop);
-
+
g_string_free (str, FALSE);
return TRUE;
} else
@@ -580,17 +580,17 @@ fill_comp_with_recipients (ENameSelector *name_selector, ECalComponent *comp)
static EAccount *
get_current_account (MemoPage *page)
-{
+{
MemoPagePrivate *priv;
EIterator *it;
const char *str;
-
+
priv = page->priv;
str = gtk_entry_get_text (GTK_ENTRY (GTK_COMBO (priv->org_combo)->entry));
if (!str)
return NULL;
-
+
for (it = e_list_get_iterator((EList *)priv->accounts); e_iterator_is_valid(it); e_iterator_next(it)) {
EAccount *a = (EAccount *)e_iterator_get(it);
char *full = g_strdup_printf("%s <%s>", a->id->name, a->id->address);
@@ -601,12 +601,12 @@ get_current_account (MemoPage *page)
return a;
}
-
+
g_free (full);
}
g_object_unref (it);
-
- return NULL;
+
+ return NULL;
}
/* fill_component handler for the memo page */
@@ -686,7 +686,7 @@ memo_page_fill_component (CompEditorPage *page, ECalComponent *comp)
l.next = NULL;
e_cal_component_set_description_list (comp, &l);
-
+
g_free(txt);
}
@@ -708,7 +708,7 @@ memo_page_fill_component (CompEditorPage *page, ECalComponent *comp)
&start_tt.month,
&start_tt.day))
e_cal_component_set_dtstart (comp, &start_date);
- else
+ else
e_cal_component_set_dtstart (comp, NULL);
/* Classification. */
@@ -730,7 +730,7 @@ memo_page_fill_component (CompEditorPage *page, ECalComponent *comp)
EAccount *a;
gchar *backend_addr = NULL, *org_addr = NULL, *sentby = NULL;
-
+
e_cal_get_cal_address (page->client, &backend_addr, NULL);
/* Find the identity for the organizer or sentby field */
@@ -740,14 +740,14 @@ memo_page_fill_component (CompEditorPage *page, ECalComponent *comp)
if (a == NULL) {
e_notice (page, GTK_MESSAGE_ERROR,
_("The organizer selected no longer has an account."));
- return FALSE;
+ return FALSE;
}
if (a->id->address == NULL || strlen (a->id->address) == 0) {
e_notice (page, GTK_MESSAGE_ERROR,
_("An organizer is required."));
return FALSE;
- }
+ }
if (!(backend_addr && *backend_addr) || !g_ascii_strcasecmp (backend_addr, a->id->address)) {
org_addr = g_strdup_printf ("MAILTO:%s", a->id->address);
@@ -778,7 +778,7 @@ memo_page_set_show_categories (MemoPage *page, gboolean state)
{
if (state) {
gtk_widget_show (page->priv->categories_btn);
- gtk_widget_show (page->priv->categories);
+ gtk_widget_show (page->priv->categories);
} else {
gtk_widget_hide (page->priv->categories_btn);
gtk_widget_hide (page->priv->categories);
@@ -786,7 +786,7 @@ memo_page_set_show_categories (MemoPage *page, gboolean state)
}
/*If the msg has some value set, the icon should always be set */
-void
+void
memo_page_set_info_string (MemoPage *mpage, const gchar *icon, const gchar *msg)
{
MemoPagePrivate *priv;
@@ -797,9 +797,9 @@ memo_page_set_info_string (MemoPage *mpage, const gchar *icon, const gchar *msg)
gtk_label_set_text (GTK_LABEL(priv->info_string), msg);
if (msg && icon)
- gtk_widget_show (priv->info_hbox);
+ gtk_widget_show (priv->info_hbox);
else
- gtk_widget_hide (priv->info_hbox);
+ gtk_widget_hide (priv->info_hbox);
}
/* Gets the widgets from the XML file and returns if they are all available. */
@@ -837,7 +837,7 @@ get_widgets (MemoPage *mpage)
priv->org_label = GW ("org-label");
priv->org_combo = GW ("org-combo");
-
+
priv->to_button = GW ("to-button");
priv->to_hbox = GW ("to-hbox");
@@ -846,7 +846,7 @@ get_widgets (MemoPage *mpage)
priv->start_label = GW ("start-label");
priv->start_date = GW ("start-date");
-
+
priv->memo_content = GW ("memo_content");
priv->categories_btn = GW ("categories-button");
@@ -885,10 +885,10 @@ field_changed_cb (GtkWidget *widget, gpointer data)
{
MemoPage *mpage;
MemoPagePrivate *priv;
-
+
mpage = MEMO_PAGE (data);
priv = mpage->priv;
-
+
if (!priv->updating)
comp_editor_page_notify_changed (COMP_EDITOR_PAGE (mpage));
}
@@ -948,13 +948,13 @@ set_subscriber_info_string (MemoPage *mpage, const char *backend_address)
{
ECal *client = COMP_EDITOR_PAGE (mpage)->client;
ESource *source;
-
+
source = e_cal_get_source (client);
-
+
if (e_source_get_property (source, "subscriber"))
- /* Translators: This string is used when we are creating a Memo
+ /* Translators: This string is used when we are creating a Memo
on behalf of some other user */
- memo_page_set_info_string (mpage, GTK_STOCK_DIALOG_INFO,
+ memo_page_set_info_string (mpage, GTK_STOCK_DIALOG_INFO,
g_strdup_printf(_("You are acting on behalf of %s"), backend_address));
else
memo_page_set_info_string (mpage, NULL, NULL);
@@ -991,13 +991,13 @@ summary_changed_cb (GtkEditable *editable, gpointer data)
MemoPage *mpage;
MemoPagePrivate *priv;
gchar *summary;
-
+
mpage = MEMO_PAGE (data);
priv = mpage->priv;
-
+
if (priv->updating)
return;
-
+
summary = e_dialog_editable_get (GTK_WIDGET (editable));
comp_editor_page_notify_summary_changed (COMP_EDITOR_PAGE (mpage),
summary);
@@ -1005,12 +1005,12 @@ summary_changed_cb (GtkEditable *editable, gpointer data)
}
static void
-to_button_clicked_cb (GtkButton *button, gpointer data)
+to_button_clicked_cb (GtkButton *button, gpointer data)
{
MemoPage *page = data;
MemoPagePrivate *priv = page->priv;
ENameSelectorDialog *name_selector_dialog;
-
+
name_selector_dialog = e_name_selector_peek_dialog (priv->name_selector);
gtk_widget_show (GTK_WIDGET (name_selector_dialog));
}
@@ -1058,7 +1058,7 @@ init_widgets (MemoPage *mpage)
/* Source selector */
g_signal_connect((priv->source_selector), "changed",
G_CALLBACK (source_changed_cb), mpage);
-
+
/* Connect the default signal handler to use to make sure the "changed"
field gets set whenever a field is changed. */
@@ -1068,13 +1068,13 @@ init_widgets (MemoPage *mpage)
g_signal_connect((priv->categories), "changed",
G_CALLBACK (field_changed_cb), mpage);
-
+
g_signal_connect((priv->summary_entry), "changed",
G_CALLBACK (field_changed_cb), mpage);
-
+
g_signal_connect((priv->source_selector), "changed",
G_CALLBACK (field_changed_cb), mpage);
-
+
g_signal_connect((priv->start_date), "changed",
G_CALLBACK (field_changed_cb), mpage);
@@ -1082,13 +1082,13 @@ init_widgets (MemoPage *mpage)
ENameSelectorDialog *name_selector_dialog;
name_selector_dialog = e_name_selector_peek_dialog (priv->name_selector);
-
+
g_signal_connect (name_selector_dialog, "response",
G_CALLBACK (response_cb), mpage);
g_signal_connect ((priv->to_button), "clicked", G_CALLBACK (to_button_clicked_cb), mpage);
g_signal_connect ((priv->to_entry), "changed", G_CALLBACK (field_changed_cb), mpage);
}
-
+
memo_page_set_show_categories (mpage, calendar_config_get_show_categories());
return TRUE;
@@ -1099,7 +1099,7 @@ get_to_entry (ENameSelector *name_selector)
{
ENameSelectorModel *name_selector_model;
ENameSelectorEntry *name_selector_entry;
-
+
name_selector_model = e_name_selector_peek_model (name_selector);
e_name_selector_model_add_section (name_selector_model, "To", _("To"), NULL);
name_selector_entry = (ENameSelectorEntry *)e_name_selector_peek_section_list (name_selector, "To");
@@ -1128,9 +1128,9 @@ memo_page_select_organizer (MemoPage *mpage, const char *backend_address)
if (source)
user_addr = e_source_get_property (source, "subscriber");
- if (user_addr)
+ if (user_addr)
subscribed_cal = TRUE;
- else
+ else
user_addr = backend_address;
priv->default_address = NULL;
@@ -1156,9 +1156,9 @@ memo_page_select_organizer (MemoPage *mpage, const char *backend_address)
/**
* memo_page_construct:
* @mpage: An memo page.
- *
+ *
* Constructs an memo page by loading its Glade data.
- *
+ *
* Return value: The same object as @mpage, or NULL if the widgets could not be
* created.
**/
@@ -1213,7 +1213,7 @@ memo_page_construct (MemoPage *mpage)
gtk_widget_show (priv->org_label);
gtk_widget_show (priv->org_combo);
-
+
if (flags & COMP_EDITOR_PAGE_NEW_ITEM) {
priv->name_selector = e_name_selector_new ();
priv->to_entry = get_to_entry (priv->name_selector);
@@ -1225,7 +1225,7 @@ memo_page_construct (MemoPage *mpage)
}
if (!init_widgets (mpage)) {
- g_message ("memo_page_construct(): "
+ g_message ("memo_page_construct(): "
"Could not initialize the widgets!");
return NULL;
}
@@ -1235,9 +1235,9 @@ memo_page_construct (MemoPage *mpage)
/**
* memo_page_new:
- *
+ *
* Creates a new memo page.
- *
+ *
* Return value: A newly-created task page, or NULL if the page could
* not be created.
**/
diff --git a/calendar/gui/dialogs/recur-comp.c b/calendar/gui/dialogs/recur-comp.c
index 4f11f9536d..ecf1436abc 100644
--- a/calendar/gui/dialogs/recur-comp.c
+++ b/calendar/gui/dialogs/recur-comp.c
@@ -41,16 +41,16 @@ recur_component_dialog (ECal *client,
GtkWidget *placeholder, *vbox;
ECalComponentVType vtype;
gboolean ret;
-
+
g_return_val_if_fail (E_IS_CAL_COMPONENT (comp), FALSE);
vtype = e_cal_component_get_vtype (comp);
-
+
switch (vtype) {
case E_CAL_COMPONENT_EVENT:
if (!delegated)
str = g_strdup_printf (_("You are modifying a recurring event. What would you like to modify?"));
- else
+ else
str = g_strdup_printf (_("You are delegating a recurring event. What would you like to delegate?"));
break;
diff --git a/calendar/gui/dialogs/recurrence-page.c b/calendar/gui/dialogs/recurrence-page.c
index 93a9fd05ba..c86137a5a5 100644
--- a/calendar/gui/dialogs/recurrence-page.c
+++ b/calendar/gui/dialogs/recurrence-page.c
@@ -148,7 +148,7 @@ struct _RecurrencePagePrivate {
GtkWidget *recurs;
gboolean custom;
-
+
GtkWidget *params;
GtkWidget *interval_value;
GtkWidget *interval_unit;
@@ -170,7 +170,7 @@ struct _RecurrencePagePrivate {
GtkWidget *month_num_menu;
enum month_num_options month_num;
-
+
/* For ending date, created by hand */
GtkWidget *ending_date_edit;
struct icaltimetype ending_date_tt;
@@ -193,7 +193,7 @@ struct _RecurrencePagePrivate {
/* For the recurrence preview, the actual widget */
GtkWidget *preview_calendar;
EMiniCalendarConfig *preview_calendar_config;
-
+
gboolean updating;
};
@@ -354,7 +354,7 @@ clear_widgets (RecurrencePage *rpage)
priv = rpage->priv;
priv->custom = FALSE;
-
+
priv->weekday_day_mask = 0;
priv->month_index = 1;
@@ -382,7 +382,7 @@ clear_widgets (RecurrencePage *rpage)
menu = gtk_option_menu_get_menu (GTK_OPTION_MENU (priv->ending_menu));
g_signal_handlers_block_matched (menu, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, rpage);
- e_dialog_option_menu_set (priv->ending_menu,
+ e_dialog_option_menu_set (priv->ending_menu,
ENDING_FOR,
ending_types_map);
g_signal_handlers_unblock_matched (menu, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, rpage);
@@ -476,12 +476,12 @@ sensitize_recur_widgets (RecurrencePage *rpage)
GtkWidget *label;
priv = rpage->priv;
-
+
if (COMP_EDITOR_PAGE (rpage)->flags & COMP_EDITOR_PAGE_MEETING)
sens = COMP_EDITOR_PAGE (rpage)->flags & COMP_EDITOR_PAGE_USER_ORG;
recurs = e_dialog_toggle_get (priv->recurs);
-
+
/* We can't preview that well for instances right now */
if (e_cal_component_is_instance (priv->comp))
gtk_widget_set_sensitive (priv->preview_calendar, FALSE);
@@ -524,13 +524,13 @@ sensitize_buttons (RecurrencePage *rpage)
priv = rpage->priv;
if (COMP_EDITOR_PAGE (rpage)->flags & COMP_EDITOR_PAGE_MEETING)
sensitize = COMP_EDITOR_PAGE (rpage)->flags & COMP_EDITOR_PAGE_USER_ORG;
-
+
selected_rows = gtk_tree_selection_count_selected_rows (
gtk_tree_view_get_selection (GTK_TREE_VIEW (priv->exception_list)));
if (!e_cal_is_read_only (COMP_EDITOR_PAGE (rpage)->client, &read_only, NULL))
read_only = TRUE;
-
+
if (!read_only) {
e_cal_component_get_uid (priv->comp, &uid);
@@ -646,7 +646,7 @@ simple_recur_to_comp (RecurrencePage *rpage, ECalComponent *comp)
case ICAL_MONTHLY_RECURRENCE: {
enum month_num_options month_num;
enum month_day_options month_day;
-
+
g_return_if_fail (GTK_BIN (priv->special)->child != NULL);
g_return_if_fail (priv->month_day_menu != NULL);
g_return_if_fail (GTK_IS_OPTION_MENU (priv->month_day_menu));
@@ -662,7 +662,7 @@ simple_recur_to_comp (RecurrencePage *rpage, ECalComponent *comp)
month_num = -1;
else
month_num++;
-
+
switch (month_day) {
case MONTH_DAY_NTH:
if (month_num == -1)
@@ -786,7 +786,7 @@ fill_component (RecurrencePage *rpage, ECalComponent *comp)
model = GTK_TREE_MODEL (priv->exception_list_store);
recurs = e_dialog_toggle_get (priv->recurs);
-
+
if (recurs && priv->custom) {
/* We just keep whatever the component has currently */
} else if (recurs) {
@@ -844,7 +844,7 @@ preview_recur (RecurrencePage *rpage)
ECalComponentDateTime cdt;
GSList *l;
icaltimezone *zone = NULL;
-
+
priv = rpage->priv;
/* If our component has not been set yet through ::fill_widgets(), we
@@ -955,7 +955,7 @@ month_num_submenu_selection_done_cb (GtkMenuShell *menu_shell, gpointer data)
{
GtkWidget *item;
int month_index;
-
+
item = gtk_menu_get_active (GTK_MENU (menu_shell));
item = gtk_menu_get_active (GTK_MENU (gtk_menu_item_get_submenu (GTK_MENU_ITEM (item))));
@@ -969,14 +969,14 @@ make_recur_month_num_submenu (const char *title, int start, int end)
{
GtkWidget *submenu, *item;
int i;
-
+
submenu = gtk_menu_new ();
for (i = start; i < end; i++) {
item = gtk_menu_item_new_with_label (_(e_cal_recur_nth[i]));
gtk_menu_shell_append(GTK_MENU_SHELL(submenu), item);
gtk_object_set_user_data (GTK_OBJECT (item), GINT_TO_POINTER (i + 1));
gtk_widget_show (item);
- }
+ }
item = gtk_menu_item_new_with_label (_(title));
gtk_widget_show (item);
@@ -990,28 +990,28 @@ make_recur_month_num_menu (int month_index)
{
static const char *options[] = {
/* TRANSLATORS: Entire string is for example: This appointment recurs/Every [x] month(s) on the [first] [Monday] [forever]'
- * (dropdown menu options are in [square brackets]). This means that after 'first', either the string 'day' or
+ * (dropdown menu options are in [square brackets]). This means that after 'first', either the string 'day' or
* the name of a week day (like 'Monday' or 'Friday') always follow.
*/
N_("first"),
/* TRANSLATORS: here, "second" is the ordinal number (like "third"), not the time division (like "minute")
* Entire string is for example: This appointment recurs/Every [x] month(s) on the [second] [Monday] [forever]'
- * (dropdown menu options are in [square brackets]). This means that after 'second', either the string 'day' or
+ * (dropdown menu options are in [square brackets]). This means that after 'second', either the string 'day' or
* the name of a week day (like 'Monday' or 'Friday') always follow.
*/
N_("second"),
/* TRANSLATORS: Entire string is for example: This appointment recurs/Every [x] month(s) on the [third] [Monday] [forever]'
- * (dropdown menu options are in [square brackets]). This means that after 'third', either the string 'day' or
+ * (dropdown menu options are in [square brackets]). This means that after 'third', either the string 'day' or
* the name of a week day (like 'Monday' or 'Friday') always follow.
*/
N_("third"),
/* TRANSLATORS: Entire string is for example: This appointment recurs/Every [x] month(s) on the [fourth] [Monday] [forever]'
- * (dropdown menu options are in [square brackets]). This means that after 'fourth', either the string 'day' or
+ * (dropdown menu options are in [square brackets]). This means that after 'fourth', either the string 'day' or
* the name of a week day (like 'Monday' or 'Friday') always follow.
*/
N_("fourth"),
/* TRANSLATORS: Entire string is for example: This appointment recurs/Every [x] month(s) on the [last] [Monday] [forever]'
- * (dropdown menu options are in [square brackets]). This means that after 'last', either the string 'day' or
+ * (dropdown menu options are in [square brackets]). This means that after 'last', either the string 'day' or
* the name of a week day (like 'Monday' or 'Friday') always follow.
*/
N_("last")
@@ -1044,20 +1044,20 @@ make_recur_month_num_menu (int month_index)
gtk_menu_shell_append(GTK_MENU_SHELL(menu), submenu_item);
gtk_widget_show (submenu_item);
- /* TRANSLATORS: This is a submenu option string to split the date range into three submenus to choose the exact day of
- * the month to setup an appointment recurrence. The entire string is for example: This appointment recurs/Every [x] month(s)
+ /* TRANSLATORS: This is a submenu option string to split the date range into three submenus to choose the exact day of
+ * the month to setup an appointment recurrence. The entire string is for example: This appointment recurs/Every [x] month(s)
* on the [Other date] [1st to 10th] [7th] [forever]' (dropdown menu options are in [square brackets]).
*/
item = make_recur_month_num_submenu (_("1st to 10th"), 0, 10);
gtk_menu_shell_append(GTK_MENU_SHELL(submenu), item);
- /* TRANSLATORS: This is a submenu option string to split the date range into three submenus to choose the exact day of
- * the month to setup an appointment recurrence. The entire string is for example: This appointment recurs/Every [x] month(s)
+ /* TRANSLATORS: This is a submenu option string to split the date range into three submenus to choose the exact day of
+ * the month to setup an appointment recurrence. The entire string is for example: This appointment recurs/Every [x] month(s)
* on the [Other date] [11th to 20th] [17th] [forever]' (dropdown menu options are in [square brackets]).
*/
item = make_recur_month_num_submenu (_("11th to 20th"), 10, 20);
gtk_menu_shell_append(GTK_MENU_SHELL(submenu), item);
- /* TRANSLATORS: This is a submenu option string to split the date range into three submenus to choose the exact day of
- * the month to setup an appointment recurrence. The entire string is for example: This appointment recurs/Every [x] month(s)
+ /* TRANSLATORS: This is a submenu option string to split the date range into three submenus to choose the exact day of
+ * the month to setup an appointment recurrence. The entire string is for example: This appointment recurs/Every [x] month(s)
* on the [Other date] [21th to 31th] [27th] [forever]' (dropdown menu options are in [square brackets]).
*/
item = make_recur_month_num_submenu (_("21st to 31st"), 20, 31);
@@ -1081,7 +1081,7 @@ make_recur_month_menu (void)
{
static const char *options[] = {
/* For Translator : 'day' is part of the sentence of the form 'appointment recurs/Every [x] month(s) on the [first] [day] [forever]'
- (dropdown menu options are in [square brackets]). This means that after 'first', either the string 'day' or
+ (dropdown menu options are in [square brackets]). This means that after 'first', either the string 'day' or
the name of a week day (like 'Monday' or 'Friday') always follow. */
N_("day"),
N_("Monday"),
@@ -1144,7 +1144,7 @@ month_num_menu_selection_done_cb (GtkMenuShell *menu_shell, gpointer data)
e_dialog_option_menu_set (priv->month_num_menu, 0, month_num_options_map);
e_dialog_option_menu_set (priv->month_num_menu, month_num, month_num_options_map);
}
-
+
if (month_num == MONTH_NUM_DAY && month_day != MONTH_DAY_NTH)
e_dialog_option_menu_set (priv->month_day_menu,
MONTH_DAY_NTH,
@@ -1171,7 +1171,7 @@ month_day_menu_selection_done_cb (GtkMenuShell *menu_shell, gpointer data)
rpage = RECURRENCE_PAGE (data);
priv = rpage->priv;
-
+
month_num = e_dialog_option_menu_get (priv->month_num_menu,
month_num_options_map);
month_day = e_dialog_option_menu_get (priv->month_day_menu,
@@ -1220,7 +1220,7 @@ make_monthly_special (RecurrencePage *rpage)
hbox = gtk_hbox_new (FALSE, 2);
gtk_container_add (GTK_CONTAINER (priv->special), hbox);
- /* TRANSLATORS: Entire string is for example: 'This appointment recurs/Every [x] month(s) on the [second] [Tuesday] [forever]'
+ /* TRANSLATORS: Entire string is for example: 'This appointment recurs/Every [x] month(s) on the [second] [Tuesday] [forever]'
* (dropdown menu options are in [square brackets])."
*/
label = gtk_label_new (_("on the"));
@@ -1359,11 +1359,11 @@ make_ending_until_special (RecurrencePage *rpage)
gtk_widget_show_all (GTK_WIDGET (de));
/* Set the value */
-
+
if (COMP_EDITOR_PAGE (rpage)->flags & COMP_EDITOR_PAGE_NEW_ITEM) {
e_cal_component_get_dtstart (priv->comp, &dt_start);
/* Setting the default until time to 2 weeks */
- icaltime_adjust (dt_start.value, 14, 0, 0, 0);
+ icaltime_adjust (dt_start.value, 14, 0, 0, 0);
e_date_edit_set_date (de, dt_start.value->year, dt_start.value->month, dt_start.value->day);
e_cal_component_free_datetime (&dt_start);
} else {
@@ -1502,7 +1502,7 @@ fill_ending_date (RecurrencePage *rpage, struct icalrecurrencetype *r)
ECal *client = COMP_EDITOR_PAGE (rpage)->client;
ECalComponentDateTime dt;
icaltimezone *from_zone, *to_zone;
-
+
e_cal_component_get_dtstart (priv->comp, &dt);
if (dt.value->is_date)
@@ -1566,7 +1566,7 @@ recurrence_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
rpage = RECURRENCE_PAGE (page);
priv = rpage->priv;
- /* Keep a copy of the component so that we can expand the recurrence
+ /* Keep a copy of the component so that we can expand the recurrence
* set for the preview.
*/
@@ -1577,7 +1577,7 @@ recurrence_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
if (!e_cal_component_has_organizer (comp))
page->flags |= COMP_EDITOR_PAGE_USER_ORG;
-
+
/* Don't send off changes during this time */
priv->updating = TRUE;
@@ -1763,7 +1763,7 @@ recurrence_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
if (nth == -1) {
ECalComponentDateTime dt;
-
+
e_cal_component_get_dtstart (comp, &dt);
priv->month_index = dt.value->day;
priv->month_num = MONTH_NUM_LAST;
@@ -1772,7 +1772,7 @@ recurrence_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
priv->month_num = MONTH_NUM_DAY;
}
priv->month_day = MONTH_DAY_NTH;
-
+
} else if (n_by_day == 1) {
enum icalrecurrencetype_weekday weekday;
int pos;
@@ -1828,7 +1828,7 @@ recurrence_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
if (pos == -1)
priv->month_num = MONTH_NUM_LAST;
- else
+ else
priv->month_num = pos - 1;
priv->month_day = month_day;
} else
@@ -1936,7 +1936,7 @@ recurrence_page_set_dates (CompEditorPage *page, CompEditorPageDates *dates)
dt.tzid = dates->start->tzid;
e_cal_component_set_dtstart (priv->comp, &dt);
}
-
+
if (dates->end) {
icaltime = *dates->end->value;
dt.tzid = dates->end->tzid;
@@ -1948,7 +1948,7 @@ recurrence_page_set_dates (CompEditorPage *page, CompEditorPageDates *dates)
if (mask != priv->weekday_blocked_day_mask) {
priv->weekday_day_mask = priv->weekday_day_mask | mask;
priv->weekday_blocked_day_mask = mask;
-
+
if (priv->weekday_picker != NULL) {
weekday_picker_set_days (WEEKDAY_PICKER (priv->weekday_picker),
priv->weekday_day_mask);
@@ -1972,7 +1972,7 @@ recurrence_page_set_dates (CompEditorPage *page, CompEditorPageDates *dates)
g_date_free (start);
g_date_free (end);
}
-
+
/* Make sure the preview gets updated. */
preview_recur (rpage);
}
@@ -2005,26 +2005,26 @@ get_widgets (RecurrencePage *rpage)
g_object_ref (priv->main);
gtk_container_remove (GTK_CONTAINER (priv->main->parent), priv->main);
-
+
priv->recurs = GW ("recurs");
priv->params = GW ("params");
-
+
priv->interval_value = GW ("interval-value");
priv->interval_unit = GW ("interval-unit");
priv->special = GW ("special");
priv->ending_menu = GW ("ending-menu");
priv->ending_special = GW ("ending-special");
priv->custom_warning_bin = GW ("custom-warning-bin");
-
+
priv->exception_list = GW ("exception-list");
priv->exception_add = GW ("exception-add");
priv->exception_modify = GW ("exception-modify");
priv->exception_delete = GW ("exception-delete");
-
+
priv->preview_bin = GW ("preview-bin");
#undef GW
-
+
return (priv->recurs
&& priv->params
&& priv->interval_value
@@ -2077,7 +2077,7 @@ type_toggled_cb (GtkToggleButton *toggle, gpointer data)
if (!gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (priv->recurs)) || read_only)
gtk_widget_set_sensitive (priv->exception_add, FALSE);
- else
+ else
gtk_widget_set_sensitive (priv->exception_add, TRUE);
}
@@ -2127,7 +2127,7 @@ create_exception_dialog (RecurrencePage *rpage, const char *title, GtkWidget **d
{
RecurrencePagePrivate *priv;
GtkWidget *dialog, *toplevel;
-
+
priv = rpage->priv;
toplevel = gtk_widget_get_toplevel (priv->main);
@@ -2140,7 +2140,7 @@ create_exception_dialog (RecurrencePage *rpage, const char *title, GtkWidget **d
*date_edit = comp_editor_new_date_edit (TRUE, FALSE, TRUE);
gtk_widget_show (*date_edit);
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), *date_edit, FALSE, TRUE, 6);
-
+
return dialog;
}
@@ -2151,33 +2151,33 @@ exception_add_cb (GtkWidget *widget, gpointer data)
RecurrencePage *rpage;
GtkWidget *dialog, *date_edit;
gboolean date_set;
-
+
rpage = RECURRENCE_PAGE (data);
dialog = create_exception_dialog (rpage, _("Add exception"), &date_edit);
-
+
if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_ACCEPT) {
ECalComponentDateTime dt;
struct icaltimetype icaltime = icaltime_null_time ();
field_changed (rpage);
-
+
dt.value = &icaltime;
-
+
/* We use DATE values for exceptions, so we don't need a TZID. */
dt.tzid = NULL;
icaltime.is_date = 1;
-
+
date_set = e_date_edit_get_date (E_DATE_EDIT (date_edit),
&icaltime.year,
&icaltime.month,
&icaltime.day);
g_return_if_fail (date_set);
-
+
append_exception (rpage, &dt);
preview_recur (rpage);
}
-
+
gtk_widget_destroy (dialog);
}
@@ -2202,34 +2202,34 @@ exception_modify_cb (GtkWidget *widget, gpointer data)
}
current_dt = e_date_time_list_get_date_time (priv->exception_list_store, &iter);
-
+
dialog = create_exception_dialog (rpage, _("Modify exception"), &date_edit);
- e_date_edit_set_date (E_DATE_EDIT (date_edit),
+ e_date_edit_set_date (E_DATE_EDIT (date_edit),
current_dt->value->year, current_dt->value->month, current_dt->value->day);
-
+
if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_ACCEPT) {
ECalComponentDateTime dt;
struct icaltimetype icaltime = icaltime_null_time ();
struct icaltimetype *tt;
field_changed (rpage);
-
+
dt.value = &icaltime;
tt = dt.value;
- e_date_edit_get_date (E_DATE_EDIT (date_edit),
+ e_date_edit_get_date (E_DATE_EDIT (date_edit),
&tt->year, &tt->month, &tt->day);
tt->hour = 0;
tt->minute = 0;
tt->second = 0;
tt->is_date = 1;
-
+
/* No TZID, since we are using a DATE value now. */
dt.tzid = NULL;
-
+
e_date_time_list_set_date_time (priv->exception_list_store, &iter, &dt);
preview_recur (rpage);
}
-
+
gtk_widget_destroy (dialog);
}
@@ -2303,7 +2303,7 @@ field_changed (RecurrencePage *rpage)
RecurrencePagePrivate *priv;
priv = rpage->priv;
-
+
if (!priv->updating)
comp_editor_page_notify_changed (COMP_EDITOR_PAGE (rpage));
}
@@ -2349,13 +2349,13 @@ init_widgets (RecurrencePage *rpage)
rpage);
/* Recurrence units */
-
+
g_signal_connect(GTK_OPTION_MENU (priv->interval_unit), "changed",
G_CALLBACK (interval_selection_done_cb),
rpage);
/* Recurrence ending */
-
+
g_signal_connect(GTK_OPTION_MENU (priv->ending_menu), "changed",
G_CALLBACK (ending_selection_done_cb), rpage);
diff --git a/calendar/gui/dialogs/save-comp.c b/calendar/gui/dialogs/save-comp.c
index 08736ff7b1..7ea90d5a7b 100644
--- a/calendar/gui/dialogs/save-comp.c
+++ b/calendar/gui/dialogs/save-comp.c
@@ -30,11 +30,11 @@
/**
* save_component_dialog:
* @parent: Window to use as the transient dialog's parent.
- * @comp: Pointer to the EcalComponent
+ * @comp: Pointer to the EcalComponent
*
* Pops up a dialog box asking the user whether he wants to save changes for
* a calendar component.
- *
+ *
* Return value: the response_id of the button selected.
**/
diff --git a/calendar/gui/dialogs/schedule-page.c b/calendar/gui/dialogs/schedule-page.c
index e7e4e0ad31..36afc0ba7a 100644
--- a/calendar/gui/dialogs/schedule-page.c
+++ b/calendar/gui/dialogs/schedule-page.c
@@ -46,7 +46,7 @@
/* Private part of the SchedulePage structure */
-struct _SchedulePagePrivate {
+struct _SchedulePagePrivate {
/* Glade XML data */
GladeXML *xml;
@@ -55,10 +55,10 @@ struct _SchedulePagePrivate {
/* Model */
EMeetingStore *model;
-
+
/* Selector */
EMeetingTimeSelector *sel;
-
+
/* The timezone we use. Note that we use the same timezone for the
start and end date. We convert the end date if it is passed in in
another timezone. */
@@ -125,7 +125,7 @@ schedule_page_finalize (GObject *object)
{
SchedulePage *spage;
SchedulePagePrivate *priv;
-
+
g_return_if_fail (object != NULL);
g_return_if_fail (IS_SCHEDULE_PAGE (object));
@@ -199,7 +199,7 @@ client_changed_cb (CompEditorPage *page, ECal *client, gpointer user_data)
/* Set date/time */
static void
-update_time (SchedulePage *spage, ECalComponentDateTime *start_date, ECalComponentDateTime *end_date)
+update_time (SchedulePage *spage, ECalComponentDateTime *start_date, ECalComponentDateTime *end_date)
{
SchedulePagePrivate *priv;
struct icaltimetype start_tt, end_tt;
@@ -228,7 +228,7 @@ update_time (SchedulePage *spage, ECalComponentDateTime *start_date, ECalCompone
/* FIXME: Handle error better. */
g_warning ("Couldn't get timezone from server: %s",
end_date->tzid ? end_date->tzid : "");
- }
+ }
}
start_tt = *start_date->value;
@@ -237,15 +237,15 @@ update_time (SchedulePage *spage, ECalComponentDateTime *start_date, ECalCompone
icaltime_adjust (&end_tt, 1, 0, 0, 0);
} else {
end_tt = *end_date->value;
- }
-
+ }
+
/* If the end zone is not the same as the start zone, we convert it. */
priv->zone = start_zone;
if (start_zone != end_zone) {
icaltimezone_convert_time (&end_tt, end_zone, start_zone);
}
e_meeting_store_set_zone (priv->model, priv->zone);
-
+
all_day = (start_tt.is_date && end_tt.is_date) ? TRUE : FALSE;
/* For All Day Events, if DTEND is after DTSTART, we subtract 1 day
@@ -268,7 +268,7 @@ update_time (SchedulePage *spage, ECalComponentDateTime *start_date, ECalCompone
}
-
+
/* Fills the widgets with default values */
static void
clear_widgets (SchedulePage *spage)
@@ -301,10 +301,10 @@ schedule_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
validated = FALSE;
else
update_time (spage, &start_date, &end_date);
-
+
e_cal_component_free_datetime (&start_date);
e_cal_component_free_datetime (&end_date);
-
+
priv->updating = FALSE;
sensitize_widgets (spage);
@@ -324,12 +324,12 @@ schedule_page_set_dates (CompEditorPage *page, CompEditorPageDates *dates)
{
SchedulePage *spage;
SchedulePagePrivate *priv;
-
+
spage = SCHEDULE_PAGE (page);
priv = spage->priv;
priv->updating = TRUE;
-
+
update_time (spage, dates->start, dates->end);
priv->updating = FALSE;
@@ -370,7 +370,7 @@ get_widgets (SchedulePage *spage)
}
static gboolean
-init_widgets (SchedulePage *spage)
+init_widgets (SchedulePage *spage)
{
SchedulePagePrivate *priv;
@@ -398,20 +398,20 @@ schedule_page_set_meeting_time (SchedulePage *spage, icaltimetype *start_tt, ica
}
}
- e_meeting_time_selector_set_meeting_time (priv->sel, start_tt->year, start_tt->month, start_tt->day,
+ e_meeting_time_selector_set_meeting_time (priv->sel, start_tt->year, start_tt->month, start_tt->day,
start_tt->hour, start_tt->minute, end_tt->year, end_tt->month, end_tt->day, end_tt->hour,
end_tt->minute);
e_meeting_time_selector_set_all_day (priv->sel, all_day);
-
+
}
/**
* schedule_page_construct:
* @spage: An schedule page.
- *
+ *
* Constructs an schedule page by loading its Glade data.
- *
- * Return value: The same object as @spage, or NULL if the widgets could not
+ *
+ * Return value: The same object as @spage, or NULL if the widgets could not
* be created.
**/
SchedulePage *
@@ -419,7 +419,7 @@ schedule_page_construct (SchedulePage *spage, EMeetingStore *ems)
{
SchedulePagePrivate *priv;
char *gladefile;
-
+
priv = spage->priv;
gladefile = g_build_filename (EVOLUTION_GLADEDIR,
@@ -443,7 +443,7 @@ schedule_page_construct (SchedulePage *spage, EMeetingStore *ems)
/* Model */
g_object_ref (ems);
priv->model = ems;
-
+
/* Selector */
priv->sel = E_MEETING_TIME_SELECTOR (e_meeting_time_selector_new (ems));
gtk_widget_set_size_request ((GtkWidget *) priv->sel, -1, 400);
@@ -456,7 +456,7 @@ schedule_page_construct (SchedulePage *spage, EMeetingStore *ems)
gtk_box_pack_start (GTK_BOX (priv->main), GTK_WIDGET (priv->sel), TRUE, TRUE, 6);
if (!init_widgets (spage)) {
- g_message ("schedule_page_construct(): "
+ g_message ("schedule_page_construct(): "
"Could not initialize the widgets!");
return NULL;
}
@@ -468,9 +468,9 @@ schedule_page_construct (SchedulePage *spage, EMeetingStore *ems)
/**
* schedule_page_new:
- *
+ *
* Creates a new schedule page.
- *
+ *
* Return value: A newly-created schedule page, or NULL if the page could
* not be created.
**/
@@ -492,12 +492,12 @@ void
schedule_page_update_free_busy (SchedulePage *spage)
{
SchedulePagePrivate *priv;
-
+
g_return_if_fail (spage != NULL);
g_return_if_fail (IS_SCHEDULE_PAGE (spage));
-
+
priv = spage->priv;
-
+
e_meeting_time_selector_refresh_free_busy (priv->sel, 0, TRUE);
}
@@ -508,7 +508,7 @@ schedule_page_set_name_selector (SchedulePage *spage, ENameSelector *name_select
g_return_if_fail (spage != NULL);
g_return_if_fail (IS_SCHEDULE_PAGE (spage));
-
+
priv = spage->priv;
e_meeting_list_view_set_name_selector (priv->sel->list_view, name_selector);
@@ -523,12 +523,12 @@ times_changed_cb (GtkWidget *widget, gpointer data)
ECalComponentDateTime start_dt, end_dt;
struct icaltimetype start_tt = icaltime_null_time ();
struct icaltimetype end_tt = icaltime_null_time ();
-
+
priv = spage->priv;
if (priv->updating)
return;
-
+
e_date_edit_get_date (E_DATE_EDIT (priv->sel->start_date_edit),
&start_tt.year,
&start_tt.month,
@@ -562,7 +562,7 @@ times_changed_cb (GtkWidget *widget, gpointer data)
}
dates.start = &start_dt;
- dates.end = &end_dt;
+ dates.end = &end_dt;
dates.due = NULL;
dates.complete = NULL;
diff --git a/calendar/gui/dialogs/select-source-dialog.c b/calendar/gui/dialogs/select-source-dialog.c
index db15963717..7fef786e0f 100644
--- a/calendar/gui/dialogs/select-source-dialog.c
+++ b/calendar/gui/dialogs/select-source-dialog.c
@@ -64,13 +64,13 @@ select_source_dialog (GtkWindow *parent, ECalSourceType obj_type)
icon_list = e_icon_factory_get_icon_list ("stock_todo");
else if (obj_type == E_CAL_SOURCE_TYPE_JOURNAL)
icon_list = e_icon_factory_get_icon_list ("stock_journal");
-
+
if (icon_list) {
gtk_window_set_icon_list (GTK_WINDOW (dialog), icon_list);
g_list_foreach (icon_list, (GFunc) g_object_unref, NULL);
g_list_free (icon_list);
}
-
+
if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_OK) {
selected_source = e_source_selector_dialog_peek_primary_selection (E_SOURCE_SELECTOR_DIALOG (dialog));
if (selected_source) {
diff --git a/calendar/gui/dialogs/send-comp.c b/calendar/gui/dialogs/send-comp.c
index 4be26333a4..0db1be872a 100644
--- a/calendar/gui/dialogs/send-comp.c
+++ b/calendar/gui/dialogs/send-comp.c
@@ -30,10 +30,10 @@
/**
* send_component_dialog:
- *
+ *
* Pops up a dialog box asking the user whether he wants to send a
* iTip/iMip message
- *
+ *
* Return value: TRUE if the user clicked Yes, FALSE otherwise.
**/
gboolean
@@ -41,10 +41,10 @@ send_component_dialog (GtkWindow *parent, ECal *client, ECalComponent *comp, gbo
{
ECalComponentVType vtype;
const char *id;
-
+
if (e_cal_get_save_schedules (client))
return FALSE;
-
+
vtype = e_cal_component_get_vtype (comp);
switch (vtype) {
@@ -68,7 +68,7 @@ send_component_dialog (GtkWindow *parent, ECal *client, ECalComponent *comp, gbo
"Cannot handle object of type %d", vtype);
return FALSE;
}
-
+
if (e_error_run (parent, id, NULL) == GTK_RESPONSE_YES)
return TRUE;
else
@@ -80,7 +80,7 @@ send_component_prompt_subject (GtkWindow *parent, ECal *client, ECalComponent *c
{
ECalComponentVType vtype;
const char *id;
-
+
vtype = e_cal_component_get_vtype (comp);
switch (vtype) {
@@ -100,7 +100,7 @@ send_component_prompt_subject (GtkWindow *parent, ECal *client, ECalComponent *c
"Cannot handle object of type %d", vtype);
return FALSE;
}
-
+
if (e_error_run (parent, id, NULL) == GTK_RESPONSE_YES)
return TRUE;
else
diff --git a/calendar/gui/dialogs/task-details-page.c b/calendar/gui/dialogs/task-details-page.c
index 572e2909d2..b9d5ace108 100644
--- a/calendar/gui/dialogs/task-details-page.c
+++ b/calendar/gui/dialogs/task-details-page.c
@@ -133,7 +133,7 @@ task_details_page_init (TaskDetailsPage *tdpage)
priv->status = NULL;
priv->priority = NULL;
priv->percent_complete = NULL;
-
+
priv->date_completed_label = NULL;
priv->completed_date = NULL;
@@ -264,12 +264,12 @@ sensitize_widgets (TaskDetailsPage *tdpage)
{
gboolean read_only;
TaskDetailsPagePrivate *priv;
-
+
priv = tdpage->priv;
if (!e_cal_is_read_only (COMP_EDITOR_PAGE (tdpage)->client, &read_only, NULL))
read_only = TRUE;
-
+
gtk_widget_set_sensitive (priv->status, !read_only);
gtk_widget_set_sensitive (priv->priority, !read_only);
gtk_widget_set_sensitive (priv->percent_complete, !read_only);
@@ -294,10 +294,10 @@ task_details_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
priv = tdpage->priv;
priv->updating = TRUE;
-
+
/* Clean the screen */
clear_widgets (tdpage);
-
+
/* Percent Complete. */
e_cal_component_get_percent (comp, &percent);
if (percent) {
@@ -361,7 +361,7 @@ task_details_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
/* URL */
e_cal_component_get_url (comp, &url);
e_dialog_editable_set (priv->url, url);
-
+
priv->updating = FALSE;
sensitize_widgets (tdpage);
@@ -382,7 +382,7 @@ task_details_page_fill_component (CompEditorPage *page, ECalComponent *comp)
char *url;
gboolean date_set;
icaltimezone *zone = calendar_config_get_icaltimezone ();
-
+
tdpage = TASK_DETAILS_PAGE (page);
priv = tdpage->priv;
@@ -426,7 +426,7 @@ task_details_page_fill_component (CompEditorPage *page, ECalComponent *comp)
icaltimezone_convert_time (&icaltoday, zone,
icaltimezone_get_utc_timezone());
- if (icaltime_compare_date_only (icalcomplete, icaltoday) > 0) {
+ if (icaltime_compare_date_only (icalcomplete, icaltoday) > 0) {
comp_editor_page_display_validation_error (page, _("Completed date is wrong"), priv->completed_date);
return FALSE;
}
@@ -513,7 +513,7 @@ get_widgets (TaskDetailsPage *tdpage)
gtk_widget_show (priv->url_entry);
priv->url = e_url_entry_get_entry (E_URL_ENTRY (priv->url_entry));
atk_object_set_name (gtk_widget_get_accessible (priv->url), _("Web Page"));
-
+
#undef GW
return (priv->status
@@ -540,10 +540,10 @@ complete_date_changed (TaskDetailsPage *tdpage, time_t ctime, gboolean complete)
dates.start = NULL;
dates.end = NULL;
- dates.due = NULL;
+ dates.due = NULL;
if (complete)
dates.complete = &completed_tt;
-
+
/* Notify upstream */
comp_editor_page_notify_dates_changed (COMP_EDITOR_PAGE (tdpage),
&dates);
@@ -593,7 +593,7 @@ date_changed_cb (EDateEdit *dedit, gpointer data)
}
e_dialog_spin_set (priv->percent_complete, 100);
}
-
+
priv->updating = FALSE;
/* Notify upstream */
@@ -607,7 +607,7 @@ status_changed (GtkMenu *menu, TaskDetailsPage *tdpage)
TaskDetailsPagePrivate *priv;
icalproperty_status status;
time_t ctime = -1;
-
+
priv = tdpage->priv;
if (priv->updating)
@@ -647,12 +647,12 @@ percent_complete_changed (GtkAdjustment *adj, TaskDetailsPage *tdpage)
icalproperty_status status;
gboolean complete;
time_t ctime = -1;
-
+
priv = tdpage->priv;
if (priv->updating)
return;
-
+
priv->updating = TRUE;
percent = e_dialog_spin_get_int (priv->percent_complete);
@@ -684,7 +684,7 @@ field_changed_cb (GtkWidget *widget, gpointer data)
{
TaskDetailsPage *tdpage;
TaskDetailsPagePrivate *priv;
-
+
tdpage = TASK_DETAILS_PAGE (data);
priv = tdpage->priv;
@@ -748,10 +748,10 @@ client_changed_cb (CompEditorPage *page, ECal *client, gpointer user_data)
/**
* task_details_page_construct:
* @tdpage: An task details page.
- *
+ *
* Constructs an task page by loading its Glade data.
- *
- * Return value: The same object as @tdpage, or NULL if the widgets could not
+ *
+ * Return value: The same object as @tdpage, or NULL if the widgets could not
* be created.
**/
TaskDetailsPage *
@@ -790,9 +790,9 @@ task_details_page_construct (TaskDetailsPage *tdpage)
/**
* task_details_page_new:
- *
+ *
* Creates a new task details page.
- *
+ *
* Return value: A newly-created task details page, or NULL if the page could
* not be created.
**/
diff --git a/calendar/gui/dialogs/task-editor.c b/calendar/gui/dialogs/task-editor.c
index 84512eaba1..8c9ee465e6 100644
--- a/calendar/gui/dialogs/task-editor.c
+++ b/calendar/gui/dialogs/task-editor.c
@@ -44,13 +44,13 @@
struct _TaskEditorPrivate {
TaskPage *task_page;
TaskDetailsPage *task_details_page;
-
+
GtkWidget *task_details_window;
EMeetingStore *model;
-
+
gboolean assignment_shown;
gboolean is_assigned;
- gboolean updating;
+ gboolean updating;
};
@@ -111,11 +111,11 @@ menu_view_role_cb (BonoboUIComponent *component,
gpointer user_data)
{
TaskEditor *te = (TaskEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- task_page_set_view_role (te->priv->task_page, atoi(state));
- calendar_config_set_show_role (atoi(state));
+ task_page_set_view_role (te->priv->task_page, atoi(state));
+ calendar_config_set_show_role (atoi(state));
}
static void
@@ -126,12 +126,12 @@ menu_view_status_cb (BonoboUIComponent *component,
gpointer user_data)
{
TaskEditor *te = (TaskEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
task_page_set_view_status (te->priv->task_page, atoi(state));
- calendar_config_set_show_status (atoi(state));
+ calendar_config_set_show_status (atoi(state));
}
static void
@@ -142,11 +142,11 @@ menu_view_type_cb (BonoboUIComponent *component,
gpointer user_data)
{
TaskEditor *te = (TaskEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- task_page_set_view_type (te->priv->task_page, atoi(state));
- calendar_config_set_show_type (atoi(state));
+ task_page_set_view_type (te->priv->task_page, atoi(state));
+ calendar_config_set_show_type (atoi(state));
}
static void
@@ -157,11 +157,11 @@ menu_view_rsvp_cb (BonoboUIComponent *component,
gpointer user_data)
{
TaskEditor *te = (TaskEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- task_page_set_view_rsvp (te->priv->task_page, atoi(state));
- calendar_config_set_show_rsvp (atoi(state));
+ task_page_set_view_rsvp (te->priv->task_page, atoi(state));
+ calendar_config_set_show_rsvp (atoi(state));
}
static void
@@ -172,10 +172,10 @@ menu_show_time_zone_cb (BonoboUIComponent *component,
gpointer user_data)
{
TaskEditor *te = (TaskEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- task_page_set_show_timezone (te->priv->task_page, atoi(state));
+ task_page_set_show_timezone (te->priv->task_page, atoi(state));
calendar_config_set_show_timezone (atoi(state));
}
@@ -187,11 +187,11 @@ menu_show_categories_cb (BonoboUIComponent *component,
gpointer user_data)
{
TaskEditor *te = (TaskEditor *) user_data;
-
+
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
- task_page_set_show_categories (te->priv->task_page, atoi(state));
+ task_page_set_show_categories (te->priv->task_page, atoi(state));
calendar_config_set_show_categories (atoi(state));
}
@@ -221,7 +221,7 @@ menu_class_private_cb (BonoboUIComponent *ui_component,
TaskEditor *te = (TaskEditor *) user_data;
if (state[0] == '0')
return;
-
+
comp_editor_page_notify_changed (COMP_EDITOR_PAGE (te->priv->task_page));
task_page_set_classification (te->priv->task_page, E_CAL_COMPONENT_CLASS_PRIVATE);
}
@@ -236,7 +236,7 @@ menu_class_confidential_cb (BonoboUIComponent *ui_component,
TaskEditor *te = (TaskEditor *) user_data;
if (state[0] == '0')
return;
-
+
comp_editor_page_notify_changed (COMP_EDITOR_PAGE (te->priv->task_page));
task_page_set_classification (te->priv->task_page, E_CAL_COMPONENT_CLASS_CONFIDENTIAL);
}
@@ -250,7 +250,7 @@ menu_option_status_cb (BonoboUIComponent *ui_component,
gpointer user_data)
{
TaskEditor *te = (TaskEditor *) user_data;
-
+
gtk_widget_show (te->priv->task_details_window);
}
@@ -260,7 +260,7 @@ menu_insert_send_options_cmd (BonoboUIComponent *uic,
const char *path)
{
TaskEditor *te = (TaskEditor *) data;
-
+
task_page_sendoptions_clicked_cb (te->priv->task_page);
}
@@ -270,8 +270,8 @@ menu_show_time_zone_cmd (BonoboUIComponent *uic,
const char *path)
{ /* TODO implement it
TaskEditor *te = (TaskEditor *) data;
-
- task_page_set_show_timezone (te->priv->task_page, atoi(state));
+
+ task_page_set_show_timezone (te->priv->task_page, atoi(state));
calendar_config_set_show_timezone (atoi(state)); */
}
@@ -281,25 +281,25 @@ menu_option_status_cmd (BonoboUIComponent *uic,
const char *path)
{
TaskEditor *te = (TaskEditor *) data;
-
+
gtk_widget_show (te->priv->task_details_window);
}
static BonoboUIVerb verbs [] = {
- BONOBO_UI_VERB ("ViewTimeZone", menu_show_time_zone_cmd),
+ BONOBO_UI_VERB ("ViewTimeZone", menu_show_time_zone_cmd),
BONOBO_UI_VERB ("OptionStatus", menu_option_status_cmd),
BONOBO_UI_VERB ("InsertSendOptions", menu_insert_send_options_cmd),
BONOBO_UI_VERB_END
};
static EPixmap pixmaps[] = {
- E_PIXMAP ("/commands/OptionStatus", "stock_view-details", E_ICON_SIZE_MENU),
+ E_PIXMAP ("/commands/OptionStatus", "stock_view-details", E_ICON_SIZE_MENU),
E_PIXMAP ("/commands/ViewTimeZone", "stock_timezone", E_ICON_SIZE_MENU),
- E_PIXMAP ("/Toolbar/ViewTimeZone", "stock_timezone", E_ICON_SIZE_LARGE_TOOLBAR),
- E_PIXMAP ("/Toolbar/OptionStatus", "stock_view-details", E_ICON_SIZE_LARGE_TOOLBAR),
-
+ E_PIXMAP ("/Toolbar/ViewTimeZone", "stock_timezone", E_ICON_SIZE_LARGE_TOOLBAR),
+ E_PIXMAP ("/Toolbar/OptionStatus", "stock_view-details", E_ICON_SIZE_LARGE_TOOLBAR),
+
E_PIXMAP_END
};
@@ -312,13 +312,13 @@ task_editor_init (TaskEditor *te)
CompEditor *editor = COMP_EDITOR(te);
gboolean status;
char *xmlfile;
-
+
priv = g_new0 (TaskEditorPrivate, 1);
te->priv = priv;
priv->model = E_MEETING_STORE (e_meeting_store_new ());
priv->assignment_shown = TRUE;
- priv->updating = FALSE;
+ priv->updating = FALSE;
priv->is_assigned = FALSE;
bonobo_ui_component_freeze (editor->uic, NULL);
@@ -341,7 +341,7 @@ task_editor_init (TaskEditor *te)
bonobo_ui_component_add_listener (
editor->uic, "ViewStatus",
menu_view_status_cb, editor);
-
+
/* Show hide the type fields */
status = calendar_config_get_show_type ();
bonobo_ui_component_set_prop (
@@ -399,14 +399,14 @@ task_editor_init (TaskEditor *te)
menu_class_confidential_cb, editor);
bonobo_ui_component_add_listener (
- editor->uic, "OptionStatus",
+ editor->uic, "OptionStatus",
menu_option_status_cb, editor);
-
+
e_pixmaps_update (editor->uic, pixmaps);
- bonobo_ui_component_thaw (editor->uic, NULL);
+ bonobo_ui_component_thaw (editor->uic, NULL);
+
-
comp_editor_set_help_section (COMP_EDITOR (te), "usage-calendar-todo");
}
@@ -416,12 +416,12 @@ task_editor_construct (TaskEditor *te, ECal *client)
TaskEditorPrivate *priv;
gboolean read_only = FALSE;
CompEditor *editor = COMP_EDITOR (te);
-
+
priv = te->priv;
priv->task_page = task_page_new (priv->model, client, editor->uic);
g_object_ref_sink (priv->task_page);
- comp_editor_append_page (COMP_EDITOR (te),
+ comp_editor_append_page (COMP_EDITOR (te),
COMP_EDITOR_PAGE (priv->task_page),
_("_Task"), TRUE);
g_signal_connect (G_OBJECT (priv->task_page), "client_changed",
@@ -433,27 +433,27 @@ task_editor_construct (TaskEditor *te, ECal *client)
NULL);
g_signal_connect (priv->task_details_window, "response", G_CALLBACK(gtk_widget_hide), NULL);
g_signal_connect (priv->task_details_window, "delete-event", G_CALLBACK(gtk_widget_hide), NULL);
-
+
priv->task_details_page = task_details_page_new ();
g_object_ref_sink (priv->task_details_page);
- gtk_container_add ((GtkContainer *) GTK_DIALOG(priv->task_details_window)->vbox,
+ gtk_container_add ((GtkContainer *) GTK_DIALOG(priv->task_details_window)->vbox,
comp_editor_page_get_widget ((CompEditorPage *)priv->task_details_page));
gtk_widget_show_all (gtk_bin_get_child (GTK_BIN (priv->task_details_window) ) );
/* gtk_widget_hide (priv->task_details_window); */
comp_editor_append_page (editor, COMP_EDITOR_PAGE (priv->task_details_page), NULL, FALSE);
-
+
if (!e_cal_is_read_only (client, &read_only, NULL))
read_only = TRUE;
if (priv->is_assigned) {
if (e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_REQ_SEND_OPTIONS))
task_page_show_options (priv->task_page);
-
+
task_page_set_assignment (priv->task_page, TRUE);
comp_editor_set_group_item (COMP_EDITOR (te), TRUE);
} else {
task_page_set_assignment (priv->task_page, FALSE);
-
+
bonobo_ui_component_set_prop (editor->uic, "/commands/InsertSendOptions", "hidden", "1", NULL);
bonobo_ui_component_set_prop (editor->uic, "/commands/ViewRole", "hidden", "1", NULL);
bonobo_ui_component_set_prop (editor->uic, "/commands/ViewRSVP", "hidden", "1", NULL);
@@ -492,7 +492,7 @@ task_editor_edit_comp (CompEditor *editor, ECalComponent *comp)
ECalComponentOrganizer organizer;
ECal *client;
GSList *attendees = NULL;
-
+
te = TASK_EDITOR (editor);
priv = te->priv;
@@ -506,12 +506,12 @@ task_editor_edit_comp (CompEditor *editor, ECalComponent *comp)
/* Get meeting related stuff */
e_cal_component_get_organizer (comp, &organizer);
e_cal_component_get_attendee_list (comp, &attendees);
-
+
if (attendees != NULL) {
GSList *l;
int row;
-
- task_page_hide_options (priv->task_page);
+
+ task_page_hide_options (priv->task_page);
task_page_set_assignment (priv->task_page, TRUE);
for (l = attendees; l != NULL; l = l->next) {
@@ -522,7 +522,7 @@ task_editor_edit_comp (CompEditor *editor, ECalComponent *comp)
/* If we aren't the organizer or the attendee is just delegating, don't allow editing */
if (!comp_editor_get_user_org (editor) || e_meeting_attendee_is_set_delto (ia))
e_meeting_attendee_set_edit_level (ia, E_MEETING_ATTENDEE_EDIT_NONE);
- e_meeting_store_add_attendee (priv->model, ia);
+ e_meeting_store_add_attendee (priv->model, ia);
g_object_unref(ia);
}
@@ -551,10 +551,10 @@ task_editor_edit_comp (CompEditor *editor, ECalComponent *comp)
if (ia != NULL)
e_meeting_attendee_set_edit_level (ia, E_MEETING_ATTENDEE_EDIT_NONE);
}
-
-
+
+
comp_editor_set_group_item (COMP_EDITOR (te), TRUE);
- priv->assignment_shown = TRUE;
+ priv->assignment_shown = TRUE;
}
e_cal_component_free_attendee_list (attendees);
@@ -576,12 +576,12 @@ task_editor_send_comp (CompEditor *editor, ECalComponentItipMethod method)
if (method == E_CAL_COMPONENT_METHOD_PUBLISH ||
method == E_CAL_COMPONENT_METHOD_CANCEL)
goto parent;
-
+
comp = task_page_get_cancel_comp (priv->task_page);
if (comp != NULL) {
ECal *client;
gboolean result;
-
+
client = e_meeting_store_get_e_cal (priv->model);
result = itip_send_comp (E_CAL_COMPONENT_METHOD_CANCEL, comp,
client, NULL, NULL, NULL);
@@ -620,12 +620,12 @@ task_editor_finalize (GObject *object)
g_object_unref (priv->task_details_page);
priv->task_details_page = NULL;
}
-
+
if (priv->model) {
g_object_unref (priv->model);
priv->model = NULL;
}
-
+
g_free (priv);
if (G_OBJECT_CLASS (task_editor_parent_class)->finalize)
@@ -685,7 +685,7 @@ model_changed (TaskEditor *te)
if (!te->priv->updating) {
comp_editor_set_changed (COMP_EDITOR (te), TRUE);
comp_editor_set_needs_send (COMP_EDITOR (te), TRUE);
- }
+ }
}
static void
diff --git a/calendar/gui/dialogs/task-page.c b/calendar/gui/dialogs/task-page.c
index e6db2e932e..c929d32ea3 100644
--- a/calendar/gui/dialogs/task-page.c
+++ b/calendar/gui/dialogs/task-page.c
@@ -63,13 +63,13 @@ struct _TaskPagePrivate {
/* Bonobo Controller for the menu/toolbar */
BonoboUIComponent *uic;
-
+
/* Widgets from the Glade file */
GtkWidget *main;
EAccountList *accounts;
GList *address_strings;
- EMeetingAttendee *ia;
+ EMeetingAttendee *ia;
char *default_address;
char *user_add;
ECalComponent *comp;
@@ -81,7 +81,7 @@ struct _TaskPagePrivate {
/* Lists of attendees */
GPtrArray *deleted_attendees;
-
+
/* Generic informative messages placeholder */
GtkWidget *info_hbox;
GtkWidget *info_icon;
@@ -94,7 +94,7 @@ struct _TaskPagePrivate {
GtkWidget *start_date;
GtkWidget *timezone;
GtkWidget *timezone_label;
-
+
GtkWidget *description;
ECalComponentClassification classification;
@@ -123,7 +123,7 @@ struct _TaskPagePrivate {
/* For handling who the organizer is */
gboolean user_org;
gboolean existing;
-
+
gboolean updating;
gboolean sendoptions_shown;
gboolean is_assignment;
@@ -207,7 +207,7 @@ task_page_init (TaskPage *tpage)
priv->updating = FALSE;
priv->sendoptions_shown = FALSE;
priv->is_assignment = FALSE;
-
+
priv->deleted_attendees = g_ptr_array_new ();
priv->comp = NULL;
@@ -217,16 +217,16 @@ task_page_init (TaskPage *tpage)
priv->ia = NULL;
priv->default_address = NULL;
priv->invite = NULL;
-
+
priv->model = NULL;
- priv->list_view = NULL;
+ priv->list_view = NULL;
}
static void
cleanup_attendees (GPtrArray *attendees)
{
int i;
-
+
for (i = 0; i < attendees->len; i++)
g_object_unref (g_ptr_array_index (attendees, i));
}
@@ -256,7 +256,7 @@ task_page_finalize (GObject *object)
g_object_unref (priv->xml);
priv->xml = NULL;
}
-
+
if (priv->sod) {
g_object_unref (priv->sod);
priv->sod = NULL;
@@ -264,7 +264,7 @@ task_page_finalize (GObject *object)
if (priv->comp != NULL)
g_object_unref (priv->comp);
-
+
cleanup_attendees (priv->deleted_attendees);
g_ptr_array_free (priv->deleted_attendees, TRUE);
@@ -383,7 +383,7 @@ task_page_set_view_rsvp (TaskPage *page, gboolean state)
e_meeting_list_view_column_set_visible (priv->list_view, "RSVP", state);
}
-void
+void
task_page_set_classification (TaskPage *page, ECalComponentClassification class)
{
page->priv->classification = class;
@@ -394,19 +394,19 @@ sensitize_widgets (TaskPage *tpage)
{
gboolean read_only, sens = TRUE, sensitize;
TaskPagePrivate *priv;
-
+
priv = tpage->priv;
if (!e_cal_is_read_only (COMP_EDITOR_PAGE (tpage)->client, &read_only, NULL))
read_only = TRUE;
-
+
if (COMP_EDITOR_PAGE (tpage)->flags & COMP_EDITOR_IS_ASSIGNED)
sens = COMP_EDITOR_PAGE (tpage)->flags & COMP_EDITOR_PAGE_USER_ORG;
sensitize = (!read_only && sens);
- /* The list of organizers is set to be non-editable. Otherwise any
- * change in the displayed list causes an 'Account not found' error.
+ /* The list of organizers is set to be non-editable. Otherwise any
+ * change in the displayed list causes an 'Account not found' error.
*/
gtk_editable_set_editable (GTK_EDITABLE (GTK_COMBO (priv->organizer)->entry), FALSE);
@@ -424,7 +424,7 @@ sensitize_widgets (TaskPage *tpage)
e_meeting_list_view_set_editable (priv->list_view, (!read_only && sens));
gtk_widget_set_sensitive (priv->remove, (!read_only && sens));
gtk_widget_set_sensitive (priv->invite, (!read_only && sens));
- gtk_widget_set_sensitive (GTK_WIDGET (priv->list_view), !read_only);
+ gtk_widget_set_sensitive (GTK_WIDGET (priv->list_view), !read_only);
bonobo_ui_component_set_prop (priv->uic, "/commands/InsertAttachments", "sensitive", sensitize ? "1" : "0"
, NULL);
@@ -443,7 +443,7 @@ sensitize_widgets (TaskPage *tpage)
bonobo_ui_component_set_prop (priv->uic, "/commands/OptionStatus", "sensitive", sensitize ? "1" : "0"
, NULL);
-
+
if (!priv->is_assignment) {
gtk_widget_hide (priv->calendar_label);
gtk_widget_hide (priv->list_box);
@@ -452,12 +452,12 @@ sensitize_widgets (TaskPage *tpage)
gtk_widget_hide (priv->invite);
gtk_label_set_text_with_mnemonic ((GtkLabel *) priv->org_cal_label, _("_Group:"));
} else {
- gtk_widget_show (priv->invite);
+ gtk_widget_show (priv->invite);
gtk_widget_show (priv->calendar_label);
gtk_widget_show (priv->list_box);
gtk_widget_show (priv->attendee_box);
gtk_widget_show (priv->organizer);
- gtk_label_set_text_with_mnemonic ((GtkLabel *) priv->org_cal_label, _("Or_ganizer:"));
+ gtk_label_set_text_with_mnemonic ((GtkLabel *) priv->org_cal_label, _("Or_ganizer:"));
}
}
void
@@ -468,13 +468,13 @@ task_page_hide_options (TaskPage *page)
bonobo_ui_component_set_prop (page->priv->uic, "/commands/InsertSendOptions", "hidden", "1", NULL);
page->priv->sendoptions_shown = FALSE;
-
+
}
void
task_page_show_options (TaskPage *page)
{
g_return_if_fail (IS_TASK_PAGE (page));
-
+
bonobo_ui_component_set_prop (page->priv->uic, "/commands/InsertSendOptions", "hidden", "0", NULL);
page->priv->sendoptions_shown = TRUE;
}
@@ -490,17 +490,17 @@ task_page_set_assignment (TaskPage *page, gboolean set)
static EAccount *
get_current_account (TaskPage *page)
-{
+{
TaskPagePrivate *priv;
EIterator *it;
const char *str;
-
+
priv = page->priv;
str = gtk_entry_get_text (GTK_ENTRY (GTK_COMBO (priv->organizer)->entry));
if (!str)
return NULL;
-
+
for (it = e_list_get_iterator((EList *)priv->accounts); e_iterator_is_valid(it); e_iterator_next(it)) {
EAccount *a = (EAccount *)e_iterator_get(it);
char *full = g_strdup_printf("%s <%s>", a->id->name, a->id->address);
@@ -511,12 +511,12 @@ get_current_account (TaskPage *page)
return a;
}
-
+
g_free (full);
}
g_object_unref (it);
-
- return NULL;
+
+ return NULL;
}
/* fill_widgets handler for the task page */
@@ -543,10 +543,10 @@ task_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
if (priv->comp != NULL)
g_object_unref (priv->comp);
priv->comp = NULL;
-
+
cleanup_attendees (priv->deleted_attendees);
g_ptr_array_set_size (priv->deleted_attendees, 0);
-
+
/* Component for cancellation */
priv->comp = e_cal_component_clone (comp);
@@ -554,7 +554,7 @@ task_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
clear_widgets (tpage);
priv->user_add = itip_get_comp_attendee (comp, page->client);
-
+
/* Summary, description(s) */
e_cal_component_get_summary (comp, &text);
e_dialog_editable_set (priv->summary, text.value);
@@ -562,7 +562,7 @@ task_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
e_cal_component_get_description_list (comp, &l);
if (l && l->data) {
ECalComponentText *dtext;
-
+
dtext = l->data;
gtk_text_buffer_set_text (gtk_text_view_get_buffer (GTK_TEXT_VIEW (priv->description)),
dtext->value ? dtext->value : "", -1);
@@ -608,14 +608,14 @@ task_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
g_warning ("Couldn't get timezone from server: %s",
d.tzid ? d.tzid : "");
}
-
+
e_timezone_entry_set_timezone (E_TIMEZONE_ENTRY (priv->timezone),
zone ? zone : default_zone);
task_page_set_show_timezone (tpage, calendar_config_get_show_timezone());
if (!(COMP_EDITOR_PAGE (tpage)->flags & COMP_EDITOR_PAGE_NEW_ITEM) && !zone) {
task_page_set_show_timezone (tpage, FALSE);
- bonobo_ui_component_set_prop (priv->uic, "/commands/ViewTimeZone",
+ bonobo_ui_component_set_prop (priv->uic, "/commands/ViewTimeZone",
"state", "0", NULL);
}
@@ -684,9 +684,9 @@ task_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
set_subscriber_info_string (tpage, backend_addr);
if (priv->is_assignment) {
- ECalComponentOrganizer organizer;
-
- priv->user_add = itip_get_comp_attendee (comp, COMP_EDITOR_PAGE (tpage)->client);
+ ECalComponentOrganizer organizer;
+
+ priv->user_add = itip_get_comp_attendee (comp, COMP_EDITOR_PAGE (tpage)->client);
/* Organizer strings */
task_page_select_organizer (tpage, backend_addr);
@@ -737,7 +737,7 @@ task_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
if (!(backend_addr && *backend_addr) || !g_ascii_strcasecmp (backend_addr, a->id->address)) {
e_meeting_attendee_set_address (priv->ia, g_strdup_printf ("MAILTO:%s", a->id->address));
e_meeting_attendee_set_cn (priv->ia, g_strdup (a->id->name));
- } else {
+ } else {
e_meeting_attendee_set_address (priv->ia, g_strdup_printf ("MAILTO:%s", backend_addr));
e_meeting_attendee_set_sentby (priv->ia, g_strdup_printf ("MAILTO:%s", a->id->address));
}
@@ -751,7 +751,7 @@ task_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
}
}
- if (backend_addr)
+ if (backend_addr)
g_free (backend_addr);
priv->updating = FALSE;
@@ -766,22 +766,22 @@ set_attendees (ECalComponent *comp, const GPtrArray *attendees)
{
GSList *comp_attendees = NULL, *l;
int i;
-
+
for (i = 0; i < attendees->len; i++) {
EMeetingAttendee *ia = g_ptr_array_index (attendees, i);
ECalComponentAttendee *ca;
-
+
ca = e_meeting_attendee_as_e_cal_component_attendee (ia);
-
+
comp_attendees = g_slist_prepend (comp_attendees, ca);
-
+
}
comp_attendees = g_slist_reverse (comp_attendees);
-
+
e_cal_component_set_attendee_list (comp, comp_attendees);
-
+
for (l = comp_attendees; l != NULL; l = l->next)
- g_free (l->data);
+ g_free (l->data);
g_slist_free (comp_attendees);
}
@@ -906,12 +906,12 @@ task_page_fill_component (CompEditorPage *page, ECalComponent *comp)
} else {
e_cal_component_set_dtstart (comp, NULL);
}
-
+
/* Classification. */
e_cal_component_set_classification (comp, priv->classification);
-
+
/* send options */
- if (priv->sendoptions_shown && priv->sod)
+ if (priv->sendoptions_shown && priv->sod)
e_sendoptions_utils_fill_component (priv->sod, comp);
/* Categories */
@@ -941,14 +941,14 @@ task_page_fill_component (CompEditorPage *page, ECalComponent *comp)
if (a == NULL) {
e_notice (page, GTK_MESSAGE_ERROR,
_("The organizer selected no longer has an account."));
- return FALSE;
+ return FALSE;
}
if (a->id->address == NULL || strlen (a->id->address) == 0) {
e_notice (page, GTK_MESSAGE_ERROR,
_("An organizer is required."));
return FALSE;
- }
+ }
if (!(backend_addr && *backend_addr) || !g_ascii_strcasecmp (backend_addr, a->id->address)) {
org_addr = g_strdup_printf ("MAILTO:%s", a->id->address);
@@ -1004,7 +1004,7 @@ task_page_fill_component (CompEditorPage *page, ECalComponent *comp)
}
e_cal_component_set_attendee_list (comp, attendee_list);
e_cal_component_free_attendee_list (attendee_list);
- } else
+ } else
set_attendees (comp, e_meeting_store_get_attendees (priv->model));
}
@@ -1043,16 +1043,16 @@ static void edit_clicked_cb (GtkButton *btn, TaskPage *tpage)
static gboolean
-existing_attendee (EMeetingAttendee *ia, ECalComponent *comp)
+existing_attendee (EMeetingAttendee *ia, ECalComponent *comp)
{
GSList *attendees, *l;
const gchar *ia_address;
const gchar *ia_sentby = NULL;
-
+
ia_address = itip_strip_mailto (e_meeting_attendee_get_address (ia));
if (!ia_address)
return FALSE;
-
+
if (e_meeting_attendee_is_set_sentby (ia))
ia_sentby = itip_strip_mailto (e_meeting_attendee_get_sentby (ia));
@@ -1062,7 +1062,7 @@ existing_attendee (EMeetingAttendee *ia, ECalComponent *comp)
ECalComponentAttendee *attendee = l->data;
const char *address;
const char *sentby = NULL;
-
+
address = itip_strip_mailto (attendee->value);
if (attendee->sentby)
sentby = itip_strip_mailto (attendee->sentby);
@@ -1072,19 +1072,19 @@ existing_attendee (EMeetingAttendee *ia, ECalComponent *comp)
return TRUE;
}
}
-
+
e_cal_component_free_attendee_list (attendees);
-
+
return FALSE;
}
static void
-remove_attendee (TaskPage *page, EMeetingAttendee *ia)
+remove_attendee (TaskPage *page, EMeetingAttendee *ia)
{
TaskPagePrivate *priv;
int pos = 0;
gboolean delegate = (COMP_EDITOR_PAGE (page)->flags & COMP_EDITOR_PAGE_DELEGATE);
-
+
priv = page->priv;
/* If the user deletes the organizer attendee explicitly,
@@ -1092,22 +1092,22 @@ remove_attendee (TaskPage *page, EMeetingAttendee *ia)
if (ia == priv->ia) {
g_object_unref (priv->ia);
priv->ia = NULL;
- }
-
+ }
+
/* If this was a delegatee, no longer delegate */
if (e_meeting_attendee_is_set_delfrom (ia)) {
EMeetingAttendee *ib;
-
+
ib = e_meeting_store_find_attendee (priv->model, e_meeting_attendee_get_delfrom (ia), &pos);
if (ib != NULL) {
e_meeting_attendee_set_delto (ib, NULL);
-
- if (!delegate)
+
+ if (!delegate)
e_meeting_attendee_set_edit_level (ib, E_MEETING_ATTENDEE_EDIT_FULL);
- }
+ }
}
-
- /* Handle deleting all attendees in the delegation chain */
+
+ /* Handle deleting all attendees in the delegation chain */
while (ia != NULL) {
EMeetingAttendee *ib = NULL;
@@ -1115,14 +1115,14 @@ remove_attendee (TaskPage *page, EMeetingAttendee *ia)
g_object_ref (ia);
g_ptr_array_add (priv->deleted_attendees, ia);
}
-
+
if (e_meeting_attendee_get_delto (ia) != NULL)
ib = e_meeting_store_find_attendee (priv->model, e_meeting_attendee_get_delto (ia), NULL);
e_meeting_store_remove_attendee (priv->model, ia);
ia = ib;
}
-
+
sensitize_widgets (page);
}
@@ -1138,7 +1138,7 @@ remove_clicked_cb (GtkButton *btn, TaskPage *page)
GtkTreeModel *model = NULL;
gboolean valid_iter;
char *address;
-
+
priv = page->priv;
selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (priv->list_view));
@@ -1148,10 +1148,10 @@ remove_clicked_cb (GtkButton *btn, TaskPage *page)
return;
}
paths = g_list_reverse (paths);
-
+
for (tmp = paths; tmp; tmp=tmp->next) {
path = tmp->data;
-
+
gtk_tree_model_get_iter (GTK_TREE_MODEL(priv->model), &iter, path);
gtk_tree_model_get (GTK_TREE_MODEL (priv->model), &iter, E_MEETING_STORE_ADDRESS_COL, &address, -1);
@@ -1161,35 +1161,35 @@ remove_clicked_cb (GtkButton *btn, TaskPage *page)
g_warning ("Cannot delete attendee\n");
continue;
} else if (e_meeting_attendee_get_edit_level (ia) != E_MEETING_ATTENDEE_EDIT_FULL) {
- g_warning("Not enough rights to delete attendee: %s\n", e_meeting_attendee_get_address(ia));
+ g_warning("Not enough rights to delete attendee: %s\n", e_meeting_attendee_get_address(ia));
continue;
}
-
+
remove_attendee (page, ia);
}
-
+
/* Select closest item after removal */
valid_iter = gtk_tree_model_get_iter (GTK_TREE_MODEL (priv->model), &iter, path);
if (!valid_iter) {
gtk_tree_path_prev (path);
valid_iter = gtk_tree_model_get_iter (GTK_TREE_MODEL (priv->model), &iter, path);
}
-
+
if (valid_iter) {
gtk_tree_selection_unselect_all (selection);
gtk_tree_selection_select_iter (selection, &iter);
}
-
+
g_list_foreach (paths, (GFunc) gtk_tree_path_free, NULL);
g_list_free (paths);
}
static void
-invite_cb (GtkWidget *widget, gpointer data)
+invite_cb (GtkWidget *widget, gpointer data)
{
TaskPage *page;
TaskPagePrivate *priv;
-
+
page = TASK_PAGE (data);
priv = page->priv;
@@ -1199,7 +1199,7 @@ invite_cb (GtkWidget *widget, gpointer data)
static void
attendee_added_cb (EMeetingListView *emlv, EMeetingAttendee *ia, gpointer user_data)
{
- TaskPage *page = TASK_PAGE (user_data);
+ TaskPage *page = TASK_PAGE (user_data);
TaskPagePrivate *priv;
gboolean delegate = (COMP_EDITOR_PAGE (page)->flags & COMP_EDITOR_PAGE_DELEGATE);
@@ -1209,13 +1209,13 @@ attendee_added_cb (EMeetingListView *emlv, EMeetingAttendee *ia, gpointer user_d
if (existing_attendee (ia, priv->comp))
e_meeting_store_remove_attendee (priv->model, ia);
else {
- if (!e_cal_get_static_capability (COMP_EDITOR_PAGE(page)->client,
+ if (!e_cal_get_static_capability (COMP_EDITOR_PAGE(page)->client,
CAL_STATIC_CAPABILITY_DELEGATE_TO_MANY)) {
const char *delegator_id = e_meeting_attendee_get_delfrom (ia);
EMeetingAttendee *delegator;
delegator = e_meeting_store_find_attendee (priv->model, delegator_id, NULL);
- e_meeting_attendee_set_delto (delegator,
+ e_meeting_attendee_set_delto (delegator,
g_strdup (e_meeting_attendee_get_address (ia)));
gtk_widget_set_sensitive (priv->invite, FALSE);
@@ -1253,7 +1253,7 @@ enum {
static EPopupItem context_menu_items[] = {
{ E_POPUP_ITEM, "10.delete", N_("_Remove"), popup_delete_cb, NULL, GTK_STOCK_REMOVE, ATTENDEE_CAN_DELETE },
- { E_POPUP_ITEM, "15.add", N_("_Add "), popup_add_cb, NULL, GTK_STOCK_ADD, ATTENDEE_CAN_ADD },
+ { E_POPUP_ITEM, "15.add", N_("_Add "), popup_add_cb, NULL, GTK_STOCK_ADD, ATTENDEE_CAN_ADD },
};
static void
@@ -1287,7 +1287,7 @@ button_press_event (GtkWidget *widget, GdkEventButton *event, TaskPage *page)
GtkTreeSelection *selection;
if (gtk_tree_model_get_iter (GTK_TREE_MODEL (priv->model), &iter, path)) {
-
+
gtk_tree_model_get (GTK_TREE_MODEL (priv->model), &iter, E_MEETING_STORE_ADDRESS_COL, &address, -1);
ia = e_meeting_store_find_attendee (priv->model, address, &priv->row);
g_free (address);
@@ -1296,7 +1296,7 @@ button_press_event (GtkWidget *widget, GdkEventButton *event, TaskPage *page)
selection = gtk_tree_view_get_selection ((GtkTreeView *) priv->list_view);
gtk_tree_selection_unselect_all (selection);
gtk_tree_selection_select_path (selection, path);
-
+
if (e_meeting_attendee_get_edit_level (ia) == E_MEETING_ATTENDEE_EDIT_FULL)
disable_mask &= ~ATTENDEE_CAN_DELETE;
}
@@ -1312,7 +1312,7 @@ button_press_event (GtkWidget *widget, GdkEventButton *event, TaskPage *page)
for (i=0;i<sizeof(context_menu_items)/sizeof(context_menu_items[0]);i++)
menus = g_slist_prepend(menus, &context_menu_items[i]);
-
+
e_popup_add_items((EPopup *)ep, menus, NULL, context_popup_free, page);
menu = e_popup_create_menu_once((EPopup *)ep, NULL, disable_mask);
gtk_menu_popup (menu, NULL, NULL, NULL, NULL, event->button, event->time);
@@ -1322,9 +1322,9 @@ button_press_event (GtkWidget *widget, GdkEventButton *event, TaskPage *page)
static gboolean
list_view_event (EMeetingListView *list_view, GdkEvent *event, TaskPage *page) {
-
+
TaskPagePrivate *priv= page->priv;
-
+
if (event->type == GDK_2BUTTON_PRESS && COMP_EDITOR_PAGE (page)->flags & COMP_EDITOR_PAGE_USER_ORG) {
EMeetingAttendee *attendee;
@@ -1338,7 +1338,7 @@ list_view_event (EMeetingListView *list_view, GdkEvent *event, TaskPage *page) {
return TRUE;
}
- return FALSE;
+ return FALSE;
}
@@ -1346,7 +1346,7 @@ static gboolean
list_key_press (EMeetingListView *list_view, GdkEventKey *event, TaskPage *page)
{
if (event->keyval == GDK_Delete) {
-
+
remove_clicked_cb (NULL, page);
return TRUE;
@@ -1359,17 +1359,17 @@ list_key_press (EMeetingListView *list_view, GdkEventKey *event, TaskPage *page)
return FALSE;
}
-void
+void
task_page_set_show_timezone (TaskPage *page, gboolean state)
{
if (state) {
gtk_widget_show_all (page->priv->timezone);
- gtk_widget_show (page->priv->timezone_label);
+ gtk_widget_show (page->priv->timezone_label);
} else {
gtk_widget_hide (page->priv->timezone);
gtk_widget_hide (page->priv->timezone_label);
}
-
+
}
void
@@ -1377,7 +1377,7 @@ task_page_set_show_categories (TaskPage *page, gboolean state)
{
if (state) {
gtk_widget_show (page->priv->categories_btn);
- gtk_widget_show (page->priv->categories);
+ gtk_widget_show (page->priv->categories);
} else {
gtk_widget_hide (page->priv->categories_btn);
gtk_widget_hide (page->priv->categories);
@@ -1406,7 +1406,7 @@ task_page_fill_timezones (CompEditorPage *page, GHashTable *timezones)
}
/*If the msg has some value set, the icon should always be set */
-void
+void
task_page_set_info_string (TaskPage *tpage, const gchar *icon, const gchar *msg)
{
TaskPagePrivate *priv;
@@ -1417,9 +1417,9 @@ task_page_set_info_string (TaskPage *tpage, const gchar *icon, const gchar *msg)
gtk_label_set_text (GTK_LABEL(priv->info_string), msg);
if (msg && icon)
- gtk_widget_show (priv->info_hbox);
+ gtk_widget_show (priv->info_hbox);
else
- gtk_widget_hide (priv->info_hbox);
+ gtk_widget_hide (priv->info_hbox);
}
/* set_summary handler for the task page */
@@ -1503,7 +1503,7 @@ get_widgets (TaskPage *tpage)
priv->org_cal_label = GW ("org-task-label");
priv->list_view = e_meeting_list_view_new (priv->model);
-
+
selection = gtk_tree_view_get_selection ((GtkTreeView *) priv->list_view);
gtk_tree_selection_set_mode (selection, GTK_SELECTION_MULTIPLE);
gtk_widget_show (GTK_WIDGET (priv->list_view));
@@ -1516,7 +1516,7 @@ get_widgets (TaskPage *tpage)
gtk_box_pack_start (GTK_BOX (priv->list_box), sw, TRUE, TRUE, 0);
priv->source_selector = GW ("source");
-
+
#undef GW
return (priv->summary
@@ -1537,21 +1537,21 @@ summary_changed_cb (GtkEditable *editable, gpointer data)
TaskPage *tpage;
TaskPagePrivate *priv;
gchar *summary;
-
+
tpage = TASK_PAGE (data);
priv = tpage->priv;
-
+
if (priv->updating)
return;
-
+
summary = e_dialog_editable_get (GTK_WIDGET (editable));
- comp_editor_page_notify_summary_changed (COMP_EDITOR_PAGE (tpage),
+ comp_editor_page_notify_summary_changed (COMP_EDITOR_PAGE (tpage),
summary);
g_free (summary);
}
/* Callback used when the start or due date widgets change. We notify the
- * other pages in the task editor, so they can update any labels.
+ * other pages in the task editor, so they can update any labels.
*/
static void
date_changed_cb (EDateEdit *dedit, gpointer data)
@@ -1616,7 +1616,7 @@ date_changed_cb (EDateEdit *dedit, gpointer data)
due_dt.value = &due_tt;
dates.due = &due_dt;
dates.complete = NULL;
-
+
/* Notify upstream */
comp_editor_page_notify_dates_changed (COMP_EDITOR_PAGE (tpage),
&dates);
@@ -1627,7 +1627,7 @@ timezone_changed_cb (EDateEdit *dedit, gpointer data)
{
TaskPage *tpage;
TaskPagePrivate *priv;
-
+
tpage = TASK_PAGE (data);
priv = tpage->priv;
@@ -1652,7 +1652,7 @@ categories_clicked_cb (GtkWidget *button, gpointer data)
e_categories_config_open_dialog_for_entry (GTK_ENTRY (entry));
}
/* sets the current focused widget */
-static gboolean
+static gboolean
widget_focus_in_cb (GtkWidget *widget, GdkEventFocus *event, gpointer data)
{
TaskPage *tpage;
@@ -1679,10 +1679,10 @@ field_changed_cb (GtkWidget *widget, gpointer data)
{
TaskPage *tpage;
TaskPagePrivate *priv;
-
+
tpage = TASK_PAGE (data);
priv = tpage->priv;
-
+
if (!priv->updating)
comp_editor_page_notify_changed (COMP_EDITOR_PAGE (tpage));
}
@@ -1746,7 +1746,7 @@ times_updated (TaskPage *tpage, gboolean adjust_end_time)
gboolean date_set;
gboolean set_start_date = FALSE, set_end_date = FALSE, adjust_by_hour;
icaltimezone *zone;
-
+
priv = tpage->priv;
if (priv->updating)
@@ -1851,11 +1851,11 @@ source_changed_cb (ESourceComboBox *source_combo_box, TaskPage *tpage)
client = auth_new_cal_from_source (source, E_CAL_SOURCE_TYPE_TODO);
if (client) {
icaltimezone *zone;
-
+
zone = calendar_config_get_icaltimezone ();
e_cal_set_default_timezone (client, zone, NULL);
}
-
+
if (!client || !e_cal_open (client, FALSE, NULL)) {
GtkWidget *dialog;
@@ -1886,7 +1886,7 @@ source_changed_cb (ESourceComboBox *source_combo_box, TaskPage *tpage)
gchar *backend_addr = NULL;
e_cal_get_cal_address(client, &backend_addr, NULL);
-
+
if (priv->is_assignment)
task_page_select_organizer (tpage, backend_addr);
@@ -1904,13 +1904,13 @@ set_subscriber_info_string (TaskPage *tpage, const char *backend_address)
{
ECal *client = COMP_EDITOR_PAGE (tpage)->client;
ESource *source;
-
+
source = e_cal_get_source (client);
-
+
if (e_source_get_property (source, "subscriber"))
- /* Translators: This string is used when we are creating a Task
+ /* Translators: This string is used when we are creating a Task
on behalf of some other user */
- task_page_set_info_string (tpage, GTK_STOCK_DIALOG_INFO,
+ task_page_set_info_string (tpage, GTK_STOCK_DIALOG_INFO,
g_strdup_printf(_("You are acting on behalf of %s"), backend_address));
else
task_page_set_info_string (tpage, NULL, NULL);
@@ -1924,7 +1924,7 @@ task_page_sendoptions_clicked_cb (TaskPage *tpage)
ESource *source;
priv = tpage->priv;
-
+
if (!priv->sod) {
priv->sod = e_sendoptions_dialog_new ();
priv->sod->data->initialized = TRUE;
@@ -1932,12 +1932,12 @@ task_page_sendoptions_clicked_cb (TaskPage *tpage)
E_SOURCE_COMBO_BOX (priv->source_selector));
e_sendoptions_utils_set_default_data (priv->sod, source, "task");
}
-
- if (e_cal_get_static_capability (COMP_EDITOR_PAGE (tpage)->client,
+
+ if (e_cal_get_static_capability (COMP_EDITOR_PAGE (tpage)->client,
CAL_STATIC_CAPABILITY_NO_GEN_OPTIONS)) {
e_sendoptions_set_need_general_options (priv->sod, FALSE);
}
-
+
toplevel = gtk_widget_get_toplevel (priv->main);
e_sendoptions_dialog_run (priv->sod, toplevel, E_ITEM_TASK);
}
@@ -1960,7 +1960,7 @@ init_widgets (TaskPage *tpage)
e_date_edit_set_get_time_callback (E_DATE_EDIT (priv->due_date),
(EDateEditGetTimeCallback) comp_editor_get_current_time,
tpage, NULL);
-
+
/* Generic informative messages */
gtk_widget_hide (priv->info_hbox);
@@ -1985,7 +1985,7 @@ init_widgets (TaskPage *tpage)
/* Categories button */
g_signal_connect((priv->categories_btn), "clicked",
G_CALLBACK (categories_clicked_cb), tpage);
-
+
/* Source selector */
g_signal_connect (priv->source_selector, "changed", G_CALLBACK (source_changed_cb), tpage);
@@ -2020,8 +2020,8 @@ init_widgets (TaskPage *tpage)
G_CALLBACK (field_changed_cb), tpage);
g_signal_connect (G_OBJECT (priv->list_view), "button_press_event", G_CALLBACK (button_press_event), tpage);
g_signal_connect (G_OBJECT (priv->list_view), "event", G_CALLBACK (list_view_event), tpage);
- g_signal_connect (priv->list_view, "key_press_event", G_CALLBACK (list_key_press), tpage);
-
+ g_signal_connect (priv->list_view, "key_press_event", G_CALLBACK (list_key_press), tpage);
+
/* Add attendee button */
g_signal_connect (priv->add, "clicked", G_CALLBACK (add_clicked_cb), tpage);
@@ -2032,24 +2032,24 @@ init_widgets (TaskPage *tpage)
g_signal_connect (priv->remove, "clicked", G_CALLBACK (remove_clicked_cb), tpage);
/* Contacts button */
- g_signal_connect(priv->invite, "clicked", G_CALLBACK (invite_cb), tpage);
+ g_signal_connect(priv->invite, "clicked", G_CALLBACK (invite_cb), tpage);
/* Meeting List View */
- g_signal_connect (priv->list_view, "attendee_added", G_CALLBACK (attendee_added_cb), tpage);
-
+ g_signal_connect (priv->list_view, "attendee_added", G_CALLBACK (attendee_added_cb), tpage);
+
/* Set the default timezone, so the timezone entry may be hidden. */
zone = calendar_config_get_icaltimezone ();
e_timezone_entry_set_default_timezone (E_TIMEZONE_ENTRY (priv->timezone), zone);
-
+
task_page_set_show_timezone (tpage, calendar_config_get_show_timezone());
- e_meeting_list_view_column_set_visible (priv->list_view, "Attendee ",
+ e_meeting_list_view_column_set_visible (priv->list_view, "Attendee ",
TRUE);
e_meeting_list_view_column_set_visible (priv->list_view, "Role", calendar_config_get_show_role());
e_meeting_list_view_column_set_visible (priv->list_view, "RSVP", calendar_config_get_show_rsvp());
e_meeting_list_view_column_set_visible (priv->list_view, "Status", calendar_config_get_show_status());
e_meeting_list_view_column_set_visible (priv->list_view, "Type", calendar_config_get_show_type());
-
+
task_page_set_show_categories (tpage, calendar_config_get_show_categories());
return TRUE;
@@ -2080,7 +2080,7 @@ task_page_select_organizer (TaskPage *tpage, const char *backend_address)
if (user_addr)
subscribed_cal = TRUE;
- else
+ else
user_addr = (backend_address && *backend_address) ? backend_address : NULL;
priv->default_address = NULL;
@@ -2107,9 +2107,9 @@ task_page_select_organizer (TaskPage *tpage, const char *backend_address)
/**
* task_page_construct:
* @tpage: An task page.
- *
+ *
* Constructs an task page by loading its Glade data.
- *
+ *
* Return value: The same object as @tpage, or NULL if the widgets could not be
* created.
**/
@@ -2120,7 +2120,7 @@ task_page_construct (TaskPage *tpage, EMeetingStore *model, ECal *client)
EIterator *it;
EAccount *a;
char *gladefile;
-
+
priv = tpage->priv;
g_object_ref (model);
priv->model = model;
@@ -2149,7 +2149,7 @@ task_page_construct (TaskPage *tpage, EMeetingStore *model, ECal *client)
e_iterator_is_valid(it);
e_iterator_next(it)) {
gchar *full = NULL;
-
+
a = (EAccount *)e_iterator_get(it);
if (!a->enabled)
@@ -2159,7 +2159,7 @@ task_page_construct (TaskPage *tpage, EMeetingStore *model, ECal *client)
priv->address_strings = g_list_append(priv->address_strings, full);
}
-
+
g_object_unref(it);
if (priv->address_strings)
@@ -2168,7 +2168,7 @@ task_page_construct (TaskPage *tpage, EMeetingStore *model, ECal *client)
g_warning ("No potential organizers!");
if (!init_widgets (tpage)) {
- g_message ("task_page_construct(): "
+ g_message ("task_page_construct(): "
"Could not initialize the widgets!");
return NULL;
}
@@ -2178,9 +2178,9 @@ task_page_construct (TaskPage *tpage, EMeetingStore *model, ECal *client)
/**
* task_page_new:
- *
+ *
* Creates a new task page.
- *
+ *
* Return value: A newly-created task page, or NULL if the page could
* not be created.
**/
@@ -2194,7 +2194,7 @@ task_page_new (EMeetingStore *model, ECal *client, BonoboUIComponent *uic)
g_object_unref (tpage);
return NULL;
}
-
+
tpage->priv->uic = uic;
return tpage;
@@ -2212,9 +2212,9 @@ task_page_get_cancel_comp (TaskPage *page)
if (priv->deleted_attendees->len == 0)
return NULL;
-
+
set_attendees (priv->comp, priv->deleted_attendees);
-
+
return e_cal_component_clone (priv->comp);
}
diff --git a/calendar/gui/e-alarm-list.c b/calendar/gui/e-alarm-list.c
index e3d9ece911..1a3dd3dc08 100644
--- a/calendar/gui/e-alarm-list.c
+++ b/calendar/gui/e-alarm-list.c
@@ -229,7 +229,7 @@ e_alarm_list_finalize (GObject *object)
}
/* Fulfill the GtkTreeModel requirements */
-static GtkTreeModelFlags
+static GtkTreeModelFlags
e_alarm_list_get_flags (GtkTreeModel *tree_model)
{
g_return_val_if_fail (E_IS_ALARM_LIST (tree_model), 0);
@@ -473,20 +473,20 @@ get_alarm_string (ECalComponentAlarm *alarm)
if (dur) {
if (trigger.u.rel_duration.is_neg)
- /*Translator: The first %s refers to the base, which would be actions like
+ /*Translator: The first %s refers to the base, which would be actions like
* "Play a Sound". Second %s refers to the duration string e.g:"15 minutes"*/
str = g_strdup_printf (_("%s %s before the start of the appointment"),
base, dur);
else
- /*Translator: The first %s refers to the base, which would be actions like
+ /*Translator: The first %s refers to the base, which would be actions like
* "Play a Sound". Second %s refers to the duration string e.g:"15 minutes"*/
str = g_strdup_printf (_("%s %s after the start of the appointment"),
base, dur);
g_free (dur);
} else
- /*Translator: The %s refers to the base, which would be actions like
- * "Play a sound" */
+ /*Translator: The %s refers to the base, which would be actions like
+ * "Play a sound" */
str = g_strdup_printf (_("%s at the start of the appointment"), base);
break;
@@ -496,20 +496,20 @@ get_alarm_string (ECalComponentAlarm *alarm)
if (dur) {
if (trigger.u.rel_duration.is_neg)
- /* Translator: The first %s refers to the base, which would be actions like
+ /* Translator: The first %s refers to the base, which would be actions like
* "Play a Sound". Second %s refers to the duration string e.g:"15 minutes" */
str = g_strdup_printf (_("%s %s before the end of the appointment"),
base, dur);
else
- /* Translator: The first %s refers to the base, which would be actions like
+ /* Translator: The first %s refers to the base, which would be actions like
* "Play a Sound". Second %s refers to the duration string e.g:"15 minutes" */
str = g_strdup_printf (_("%s %s after the end of the appointment"),
base, dur);
g_free (dur);
} else
- /* Translator: The %s refers to the base, which would be actions like
- * "Play a sound" */
+ /* Translator: The %s refers to the base, which would be actions like
+ * "Play a sound" */
str = g_strdup_printf (_("%s at the end of the appointment"), base);
break;
@@ -532,7 +532,7 @@ get_alarm_string (ECalComponentAlarm *alarm)
e_time_format_date_and_time (&tm, calendar_config_get_24_hour_format (),
FALSE, FALSE, buf, sizeof (buf));
- /* Translator: The first %s refers to the base, which would be actions like
+ /* Translator: The first %s refers to the base, which would be actions like
* "Play a Sound". Second %s is an absolute time, e.g. "10:00AM" */
str = g_strdup_printf (_("%s at %s"), base, buf);
@@ -540,7 +540,7 @@ get_alarm_string (ECalComponentAlarm *alarm)
case E_CAL_COMPONENT_ALARM_TRIGGER_NONE:
default:
- /* Translator: The %s refers to the base, which would be actions like
+ /* Translator: The %s refers to the base, which would be actions like
* "Play a sound". "Trigger types" are absolute or relative dates */
str = g_strdup_printf (_("%s for an unknown trigger type"), base);
break;
diff --git a/calendar/gui/e-cal-component-memo-preview.c b/calendar/gui/e-cal-component-memo-preview.c
index 7469a37070..90a96f0c9e 100644
--- a/calendar/gui/e-cal-component-memo-preview.c
+++ b/calendar/gui/e-cal-component-memo-preview.c
@@ -112,7 +112,7 @@ timet_to_str_with_zone (ECalComponentDateTime *dt, ECal *ecal, icaltimezone *def
struct icaltimetype itt;
icaltimezone *zone;
struct tm tm;
- char buf[256];
+ char buf[256];
if (dt->tzid) {
/* If we can't find the zone, we'll guess its "local" */
@@ -123,13 +123,13 @@ timet_to_str_with_zone (ECalComponentDateTime *dt, ECal *ecal, icaltimezone *def
} else {
zone = NULL;
}
-
-
+
+
itt = *dt->value;
if (zone)
icaltimezone_convert_time (&itt, zone, default_zone);
tm = icaltimetype_to_tm (&itt);
-
+
e_time_format_date_and_time (&tm, calendar_config_get_24_hour_format (),
FALSE, FALSE, buf, sizeof (buf));
@@ -164,8 +164,8 @@ write_html (GtkHTMLStream *stream, ECal *ecal, ECalComponent *comp, icaltimezone
if (l) {
GSList *node;
GString *string = g_string_new (NULL);
-
-
+
+
gtk_html_stream_printf(stream, "<H3>%s: ", _("Categories"));
for (node = l; node != NULL; node = node->next) {
@@ -189,12 +189,12 @@ write_html (GtkHTMLStream *stream, ECal *ecal, ECalComponent *comp, icaltimezone
}
}
}
-
+
if (string->len > 0)
gtk_html_stream_printf(stream, "%s", string->str);
g_string_free (string, TRUE);
-
+
gtk_html_stream_printf(stream, "</H3>");
e_cal_component_free_categories_list (l);
@@ -202,7 +202,7 @@ write_html (GtkHTMLStream *stream, ECal *ecal, ECalComponent *comp, icaltimezone
/* Start table */
gtk_html_stream_printf (stream, "<TABLE BORDER=\"0\" WIDTH=\"80%%\">"
- "<TR><TD VALIGN=\"TOP\" ALIGN=\"RIGHT\" WIDTH=\"15%%\"></TD></TR>");
+ "<TR><TD VALIGN=\"TOP\" ALIGN=\"RIGHT\" WIDTH=\"15%%\"></TD></TR>");
/* write start date */
e_cal_component_get_dtstart (comp, &dt);
@@ -261,7 +261,7 @@ write_html (GtkHTMLStream *stream, ECal *ecal, ECalComponent *comp, icaltimezone
gtk_html_stream_printf (stream, "<TR><TD VALIGN=\"TOP\" ALIGN=\"RIGHT\"><B>%s</B></TD>", _("Web Page:"));
gtk_html_stream_printf (stream, "<TD><A HREF=\"%s\">%s</A></TD></TR>", str, str);
}
-
+
gtk_html_stream_printf (stream, "</TABLE>");
/* close document */
@@ -273,7 +273,7 @@ e_cal_component_memo_preview_init (ECalComponentMemoPreview *preview)
{
ECalComponentMemoPreviewPrivate *priv;
GtkWidget *scroll;
-
+
priv = g_new0 (ECalComponentMemoPreviewPrivate, 1);
preview->priv = priv;
@@ -297,7 +297,7 @@ e_cal_component_memo_preview_init (ECalComponentMemoPreview *preview)
gtk_container_add (GTK_CONTAINER (scroll), priv->html);
gtk_container_add (GTK_CONTAINER (preview), scroll);
gtk_widget_show_all (scroll);
-
+
priv->zone = icaltimezone_get_utc_timezone ();
}
@@ -327,9 +327,9 @@ static void
e_cal_component_memo_preview_class_init (ECalComponentMemoPreviewClass *klass)
{
GtkObjectClass *object_class;
-
+
object_class = (GtkObjectClass *) klass;
-
+
object_class->destroy = e_cal_component_memo_preview_destroy;
}
@@ -347,7 +347,7 @@ icaltimezone *
e_cal_component_memo_preview_get_default_timezone (ECalComponentMemoPreview *preview)
{
ECalComponentMemoPreviewPrivate *priv;
-
+
g_return_val_if_fail (preview != NULL, NULL);
g_return_val_if_fail (E_IS_CAL_COMPONENT_MEMO_PREVIEW (preview), NULL);
@@ -360,13 +360,13 @@ void
e_cal_component_memo_preview_set_default_timezone (ECalComponentMemoPreview *preview, icaltimezone *zone)
{
ECalComponentMemoPreviewPrivate *priv;
-
+
g_return_if_fail (preview != NULL);
g_return_if_fail (E_IS_CAL_COMPONENT_MEMO_PREVIEW (preview));
g_return_if_fail (zone != NULL);
priv = preview->priv;
-
+
priv->zone = zone;
}
@@ -382,7 +382,7 @@ e_cal_component_memo_preview_display (ECalComponentMemoPreview *preview, ECal *e
g_return_if_fail (E_IS_CAL_COMPONENT (comp));
priv = preview->priv;
-
+
stream = gtk_html_begin (GTK_HTML (priv->html));
write_html (stream, ecal, comp, priv->zone);
gtk_html_stream_close (stream, GTK_HTML_STREAM_OK);
@@ -395,9 +395,9 @@ e_cal_component_memo_preview_clear (ECalComponentMemoPreview *preview)
g_return_if_fail (preview != NULL);
g_return_if_fail (E_IS_CAL_COMPONENT_MEMO_PREVIEW (preview));
-
+
priv = preview->priv;
-
+
gtk_html_load_empty (GTK_HTML (priv->html));
}
diff --git a/calendar/gui/e-cal-component-preview.c b/calendar/gui/e-cal-component-preview.c
index f48d6198fb..b46069917c 100644
--- a/calendar/gui/e-cal-component-preview.c
+++ b/calendar/gui/e-cal-component-preview.c
@@ -110,7 +110,7 @@ timet_to_str_with_zone (ECalComponentDateTime *dt, ECal *ecal, icaltimezone *def
struct icaltimetype itt;
icaltimezone *zone;
struct tm tm;
- char buf[256];
+ char buf[256];
if (dt->tzid) {
/* If we can't find the zone, we'll guess its "local" */
@@ -121,13 +121,13 @@ timet_to_str_with_zone (ECalComponentDateTime *dt, ECal *ecal, icaltimezone *def
} else {
zone = NULL;
}
-
-
+
+
itt = *dt->value;
if (zone)
icaltimezone_convert_time (&itt, zone, default_zone);
tm = icaltimetype_to_tm (&itt);
-
+
e_time_format_date_and_time (&tm, calendar_config_get_24_hour_format (),
FALSE, FALSE, buf, sizeof (buf));
@@ -184,7 +184,7 @@ write_html (GtkHTMLStream *stream, ECal *ecal, ECalComponent *comp, icaltimezone
/* Start table */
gtk_html_stream_printf (stream, "<TABLE BORDER=\"0\" WIDTH=\"80%%\">"
- "<TR><TD VALIGN=\"TOP\" ALIGN=\"RIGHT\" WIDTH=\"15%%\"></TD></TR>");
+ "<TR><TD VALIGN=\"TOP\" ALIGN=\"RIGHT\" WIDTH=\"15%%\"></TD></TR>");
/* write location */
e_cal_component_get_location (comp, &location);
@@ -213,7 +213,7 @@ write_html (GtkHTMLStream *stream, ECal *ecal, ECalComponent *comp, icaltimezone
e_cal_component_free_datetime (&dt);
g_free (str);
}
-
+
/* write Due Date */
e_cal_component_get_due (comp, &dt);
if (dt.value != NULL) {
@@ -224,7 +224,7 @@ write_html (GtkHTMLStream *stream, ECal *ecal, ECalComponent *comp, icaltimezone
e_cal_component_free_datetime (&dt);
g_free (str);
}
-
+
/* write status */
gtk_html_stream_printf (stream, "<TR><TD VALIGN=\"TOP\" ALIGN=\"RIGHT\"><B>%s</B></TD>", _("Status:"));
e_cal_component_get_status (comp, &status);
@@ -307,7 +307,7 @@ write_html (GtkHTMLStream *stream, ECal *ecal, ECalComponent *comp, icaltimezone
gtk_html_stream_printf (stream, "<TR><TD VALIGN=\"TOP\" ALIGN=\"RIGHT\"><B>%s</B></TD>", _("Web Page:"));
gtk_html_stream_printf (stream, "<TD><A HREF=\"%s\">%s</A></TD></TR>", str, str);
}
-
+
gtk_html_stream_printf (stream, "</TABLE>");
/* close document */
@@ -319,7 +319,7 @@ e_cal_component_preview_init (ECalComponentPreview *preview)
{
ECalComponentPreviewPrivate *priv;
GtkWidget *scroll;
-
+
priv = g_new0 (ECalComponentPreviewPrivate, 1);
preview->priv = priv;
@@ -343,7 +343,7 @@ e_cal_component_preview_init (ECalComponentPreview *preview)
gtk_container_add (GTK_CONTAINER (scroll), priv->html);
gtk_container_add (GTK_CONTAINER (preview), scroll);
gtk_widget_show_all (scroll);
-
+
priv->zone = icaltimezone_get_utc_timezone ();
}
@@ -373,9 +373,9 @@ static void
e_cal_component_preview_class_init (ECalComponentPreviewClass *klass)
{
GtkObjectClass *object_class;
-
+
object_class = (GtkObjectClass *) klass;
-
+
object_class->destroy = e_cal_component_preview_destroy;
}
@@ -393,7 +393,7 @@ icaltimezone *
e_cal_component_preview_get_default_timezone (ECalComponentPreview *preview)
{
ECalComponentPreviewPrivate *priv;
-
+
g_return_val_if_fail (preview != NULL, NULL);
g_return_val_if_fail (E_IS_CAL_COMPONENT_PREVIEW (preview), NULL);
@@ -406,13 +406,13 @@ void
e_cal_component_preview_set_default_timezone (ECalComponentPreview *preview, icaltimezone *zone)
{
ECalComponentPreviewPrivate *priv;
-
+
g_return_if_fail (preview != NULL);
g_return_if_fail (E_IS_CAL_COMPONENT_PREVIEW (preview));
g_return_if_fail (zone != NULL);
priv = preview->priv;
-
+
priv->zone = zone;
}
@@ -428,8 +428,8 @@ e_cal_component_preview_display (ECalComponentPreview *preview, ECal *ecal, ECal
g_return_if_fail (E_IS_CAL_COMPONENT (comp));
priv = preview->priv;
-
- stream = gtk_html_begin (GTK_HTML (priv->html));
+
+ stream = gtk_html_begin (GTK_HTML (priv->html));
write_html (stream, ecal, comp, priv->zone);
gtk_html_stream_close (stream, GTK_HTML_STREAM_OK);
}
@@ -441,9 +441,9 @@ e_cal_component_preview_clear (ECalComponentPreview *preview)
g_return_if_fail (preview != NULL);
g_return_if_fail (E_IS_CAL_COMPONENT_PREVIEW (preview));
-
+
priv = preview->priv;
-
+
gtk_html_load_empty (GTK_HTML (priv->html));
}
diff --git a/calendar/gui/e-cal-list-view-config.c b/calendar/gui/e-cal-list-view-config.c
index 13e9bf174c..be8128a14d 100644
--- a/calendar/gui/e-cal-list-view-config.c
+++ b/calendar/gui/e-cal-list-view-config.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Rodrigo Moya <rodrigo@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -44,7 +44,7 @@ e_cal_list_view_config_set_property (GObject *object, guint property_id, const G
ECalListViewConfig *view_config;
view_config = E_CAL_LIST_VIEW_CONFIG (object);
-
+
switch (property_id) {
case PROP_VIEW:
e_cal_list_view_config_set_view (view_config, g_value_get_object (value));
@@ -61,7 +61,7 @@ e_cal_list_view_config_get_property (GObject *object, guint property_id, GValue
ECalListViewConfig *view_config;
view_config = E_CAL_LIST_VIEW_CONFIG (object);
-
+
switch (property_id) {
case PROP_VIEW:
g_value_set_object (value, e_cal_list_view_config_get_view (view_config));
@@ -76,9 +76,9 @@ static void
e_cal_list_view_config_dispose (GObject *object)
{
ECalListViewConfig *view_config = E_CAL_LIST_VIEW_CONFIG (object);
-
+
e_cal_list_view_config_set_view (view_config, NULL);
-
+
if (G_OBJECT_CLASS (e_cal_list_view_config_parent_class)->dispose)
G_OBJECT_CLASS (e_cal_list_view_config_parent_class)->dispose (object);
}
@@ -88,11 +88,11 @@ e_cal_list_view_config_finalize (GObject *object)
{
ECalListViewConfig *view_config = E_CAL_LIST_VIEW_CONFIG (object);
ECalListViewConfigPrivate *priv;
-
+
priv = view_config->priv;
g_free (priv);
-
+
if (G_OBJECT_CLASS (e_cal_list_view_config_parent_class)->finalize)
G_OBJECT_CLASS (e_cal_list_view_config_parent_class)->finalize (object);
}
@@ -102,7 +102,7 @@ e_cal_list_view_config_class_init (ECalListViewConfigClass *klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
GParamSpec *spec;
-
+
/* Method override */
gobject_class->set_property = e_cal_list_view_config_set_property;
gobject_class->get_property = e_cal_list_view_config_get_property;
@@ -125,14 +125,14 @@ ECalListViewConfig *
e_cal_list_view_config_new (ECalListView *list_view)
{
ECalListViewConfig *view_config;
-
+
view_config = g_object_new (e_cal_list_view_config_get_type (), "view", list_view, NULL);
return view_config;
}
ECalListView *
-e_cal_list_view_config_get_view (ECalListViewConfig *view_config)
+e_cal_list_view_config_get_view (ECalListViewConfig *view_config)
{
ECalListViewConfigPrivate *priv;
@@ -140,16 +140,16 @@ e_cal_list_view_config_get_view (ECalListViewConfig *view_config)
g_return_val_if_fail (E_IS_CAL_LIST_VIEW_CONFIG (view_config), NULL);
priv = view_config->priv;
-
+
return priv->view;
}
static void
-set_timezone (ECalListView *list_view)
+set_timezone (ECalListView *list_view)
{
icaltimezone *zone;
-
- zone = calendar_config_get_icaltimezone ();
+
+ zone = calendar_config_get_icaltimezone ();
e_calendar_view_set_timezone (E_CALENDAR_VIEW (list_view), zone);
}
@@ -158,14 +158,14 @@ timezone_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer
{
ECalListViewConfig *view_config = data;
ECalListViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_timezone (priv->view);
}
static void
-set_twentyfour_hour (ECalListView *list_view)
+set_twentyfour_hour (ECalListView *list_view)
{
gboolean use_24_hour;
@@ -179,29 +179,29 @@ twentyfour_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gp
{
ECalListViewConfig *view_config = data;
ECalListViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_twentyfour_hour (priv->view);
}
void
-e_cal_list_view_config_set_view (ECalListViewConfig *view_config, ECalListView *list_view)
+e_cal_list_view_config_set_view (ECalListViewConfig *view_config, ECalListView *list_view)
{
ECalListViewConfigPrivate *priv;
guint not;
GList *l;
-
+
g_return_if_fail (view_config != NULL);
g_return_if_fail (E_IS_CAL_LIST_VIEW_CONFIG (view_config));
priv = view_config->priv;
-
+
if (priv->view) {
g_object_unref (priv->view);
priv->view = NULL;
}
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
@@ -211,17 +211,17 @@ e_cal_list_view_config_set_view (ECalListViewConfig *view_config, ECalListView *
/* If the new view is NULL, return right now */
if (!list_view)
return;
-
+
priv->view = g_object_ref (list_view);
/* Time zone */
set_timezone (list_view);
-
+
not = calendar_config_add_notification_timezone (timezone_changed_cb, view_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* 24 Hour format */
- set_twentyfour_hour (list_view);
+ set_twentyfour_hour (list_view);
not = calendar_config_add_notification_24_hour_format (twentyfour_hour_changed_cb, view_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
diff --git a/calendar/gui/e-cal-list-view-config.h b/calendar/gui/e-cal-list-view-config.h
index 2ecef1ebff..e3c7f54a2c 100644
--- a/calendar/gui/e-cal-list-view-config.h
+++ b/calendar/gui/e-cal-list-view-config.h
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -30,7 +30,7 @@ G_BEGIN_DECLS
#define E_CAL_LIST_VIEW_CONFIG(obj) GTK_CHECK_CAST (obj, e_cal_list_view_config_get_type (), ECalListViewConfig)
#define E_CAL_LIST_VIEW_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_cal_list_view_config_get_type (), ECalListViewConfigClass)
#define E_IS_CAL_LIST_VIEW_CONFIG(obj) GTK_CHECK_TYPE (obj, e_cal_list_view_config_get_type ())
-
+
typedef struct _ECalListViewConfig ECalListViewConfig;
typedef struct _ECalListViewConfigClass ECalListViewConfigClass;
typedef struct _ECalListViewConfigPrivate ECalListViewConfigPrivate;
diff --git a/calendar/gui/e-cal-list-view.c b/calendar/gui/e-cal-list-view.c
index 7d67db489f..89ea2cd56a 100644
--- a/calendar/gui/e-cal-list-view.c
+++ b/calendar/gui/e-cal-list-view.c
@@ -293,7 +293,7 @@ setup_e_table (ECalListView *cal_list_view)
"double_click", G_CALLBACK (e_cal_list_view_on_table_double_click), cal_list_view);
g_signal_connect (e_table_scrolled_get_table (cal_list_view->table_scrolled),
"right-click", G_CALLBACK (e_cal_list_view_on_table_right_click), cal_list_view);
- g_signal_connect_after (e_table_scrolled_get_table (cal_list_view->table_scrolled),
+ g_signal_connect_after (e_table_scrolled_get_table (cal_list_view->table_scrolled),
"cursor_change", G_CALLBACK (e_cal_list_view_cursor_change_cb), cal_list_view);
/* Attach and show widget */
@@ -322,7 +322,7 @@ e_cal_list_view_new (void)
{
ECalListView *cal_list_view;
ECalModel *model;
-
+
model = E_CAL_MODEL (e_cal_model_calendar_new ());
e_cal_model_set_flags (model, E_CAL_MODEL_FLAGS_EXPAND_RECURRENCES);
@@ -388,16 +388,16 @@ e_cal_list_view_popup_menu (GtkWidget *widget)
return TRUE;
}
-static gboolean
-find_meeting (icalcomponent *icalcomp)
+static gboolean
+find_meeting (icalcomponent *icalcomp)
{
icalproperty *prop = NULL;
prop = icalcomponent_get_first_property (icalcomp, ICAL_ATTENDEE_PROPERTY);
-
+
return prop ? TRUE: FALSE;
}
-
+
static gboolean
e_cal_list_view_on_table_double_click (GtkWidget *table, gint row, gint col, GdkEvent *event,
@@ -408,7 +408,7 @@ e_cal_list_view_on_table_double_click (GtkWidget *table, gint row, gint col, Gdk
comp_data = e_cal_model_get_component_at (e_calendar_view_get_model (E_CALENDAR_VIEW (cal_list_view)), row);
e_calendar_view_edit_appointment (E_CALENDAR_VIEW (cal_list_view), comp_data->client,
- comp_data->icalcomp, find_meeting (comp_data->icalcomp));
+ comp_data->icalcomp, find_meeting (comp_data->icalcomp));
return TRUE;
}
diff --git a/calendar/gui/e-cal-list-view.h b/calendar/gui/e-cal-list-view.h
index d70271e24e..82af6480e9 100644
--- a/calendar/gui/e-cal-list-view.h
+++ b/calendar/gui/e-cal-list-view.h
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Authors:
+/*
+ * Authors:
* Hans Petter Jansson <hpj@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-cal-menu.c b/calendar/gui/e-cal-menu.c
index 554500a0a7..3fa178f569 100644
--- a/calendar/gui/e-cal-menu.c
+++ b/calendar/gui/e-cal-menu.c
@@ -109,12 +109,12 @@ ECalMenu *e_cal_menu_new(const char *menuid)
/**
* e_cal_menu_target_new_select:
* @folder: The selection will ref this for the life of it.
- * @folder_uri:
+ * @folder_uri:
* @uids: The selection will free this when done with it.
- *
+ *
* Create a new selection popup target.
- *
- * Return value:
+ *
+ * Return value:
**/
ECalMenuTargetSelect *
e_cal_menu_target_new_select(ECalMenu *eabp, struct _ECalModel *model, GPtrArray *events)
@@ -146,9 +146,9 @@ e_cal_menu_target_new_select(ECalMenu *eabp, struct _ECalModel *model, GPtrArray
if (!e_cal_get_static_capability (comp_data->client, CAL_STATIC_CAPABILITY_NO_TASK_ASSIGNMENT)
&& !e_cal_get_static_capability (comp_data->client, CAL_STATIC_CAPABILITY_NO_CONV_TO_ASSIGN_TASK)
- && !icalcomponent_get_first_property (comp_data->icalcomp, ICAL_ATTENDEE_PROPERTY))
+ && !icalcomponent_get_first_property (comp_data->icalcomp, ICAL_ATTENDEE_PROPERTY))
mask &= ~E_CAL_MENU_SELECT_ASSIGNABLE;
-
+
if (!icalcomponent_get_first_property (comp_data->icalcomp, ICAL_COMPLETED_PROPERTY))
mask &= ~ E_CAL_MENU_SELECT_NOTCOMPLETE;
@@ -278,7 +278,7 @@ GType
e_cal_menu_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(ECalMenuHookClass), NULL, NULL, (GClassInitFunc) ecalph_class_init, NULL, NULL,
@@ -288,6 +288,6 @@ e_cal_menu_hook_get_type(void)
ecalph_parent_class = g_type_class_ref(e_menu_hook_get_type());
type = g_type_register_static(e_menu_hook_get_type(), "ECalMenuHook", &info, 0);
}
-
+
return type;
}
diff --git a/calendar/gui/e-cal-menu.h b/calendar/gui/e-cal-menu.h
index d7298da5b1..b915ac3b19 100644
--- a/calendar/gui/e-cal-menu.h
+++ b/calendar/gui/e-cal-menu.h
@@ -43,7 +43,7 @@ enum _e_cal_menu_target_t {
/**
* enum _e_cal_menu_target_select_t - ECalPopupTargetSelect qualifiers.
- *
+ *
* @E_CAL_MENU_SELECT_ONE: Only one item is selected.
* @E_CAL_MENU_SELECT_MANY: More than one item selected.
* @E_CAL_MENU_SELECT_ANY: One or more items selected.
diff --git a/calendar/gui/e-cal-model-calendar.c b/calendar/gui/e-cal-model-calendar.c
index 19e257523a..0a91d29a16 100644
--- a/calendar/gui/e-cal-model-calendar.c
+++ b/calendar/gui/e-cal-model-calendar.c
@@ -137,7 +137,7 @@ get_dtend (ECalModelCalendar *model, ECalModelComponent *comp_data)
if (model_zone)
icaltimezone_convert_time (&tt_end, zone, model_zone);
} else
- tt_end = icaltime_from_timet_with_zone (comp_data->instance_end, tt_end.is_date,
+ tt_end = icaltime_from_timet_with_zone (comp_data->instance_end, tt_end.is_date,
model_zone);
}
@@ -226,7 +226,7 @@ set_dtend (ECalModelComponent *comp_data, const void *value)
icalproperty *prop;
icalparameter *param;
const char *tzid;
-
+
prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_DTEND_PROPERTY);
if (prop)
param = icalproperty_get_first_parameter (prop, ICAL_TZID_PARAMETER);
@@ -243,7 +243,7 @@ set_dtend (ECalModelComponent *comp_data, const void *value)
return;
}
-
+
/* If the TZID is set to "UTC", we set the is_utc flag. */
tzid = dv->zone ? icaltimezone_get_tzid (dv->zone) : "UTC";
if (tzid && !strcmp (tzid, "UTC"))
@@ -384,7 +384,7 @@ ecmc_set_value_at (ETableModel *etm, int col, int row, const void *value)
comp_data->client, NULL, NULL, NULL);
} else {
g_warning (G_STRLOC ": Could not modify the object!");
-
+
/* FIXME Show error dialog */
}
diff --git a/calendar/gui/e-cal-model-memos.c b/calendar/gui/e-cal-model-memos.c
index 877e3fb8ec..b5821823de 100644
--- a/calendar/gui/e-cal-model-memos.c
+++ b/calendar/gui/e-cal-model-memos.c
@@ -157,7 +157,7 @@ ecmm_set_value_at (ETableModel *etm, int col, int row, const void *value)
/* TODO ask about mod type */
if (!e_cal_modify_object (comp_data->client, comp_data->icalcomp, CALOBJ_MOD_ALL, NULL)) {
g_warning (G_STRLOC ": Could not modify the object!");
-
+
/* TODO Show error dialog */
}
}
diff --git a/calendar/gui/e-cal-model-tasks.c b/calendar/gui/e-cal-model-tasks.c
index 66e7c536d5..b74283e328 100644
--- a/calendar/gui/e-cal-model-tasks.c
+++ b/calendar/gui/e-cal-model-tasks.c
@@ -246,7 +246,7 @@ get_completed (ECalModelComponent *comp_data)
comp_data->completed->tt = tt_completed;
if (icaltime_get_tzid (tt_completed)
- && e_cal_get_timezone (comp_data->client, icaltime_get_tzid (tt_completed), &zone, NULL))
+ && e_cal_get_timezone (comp_data->client, icaltime_get_tzid (tt_completed), &zone, NULL))
comp_data->completed->zone = zone;
else
comp_data->completed->zone = NULL;
@@ -276,7 +276,7 @@ get_due (ECalModelComponent *comp_data)
comp_data->due->tt = tt_due;
if (icaltime_get_tzid (tt_due)
- && e_cal_get_timezone (comp_data->client, icaltime_get_tzid (tt_due), &zone, NULL))
+ && e_cal_get_timezone (comp_data->client, icaltime_get_tzid (tt_due), &zone, NULL))
comp_data->due->zone = zone;
else
comp_data->due->zone = NULL;
@@ -384,7 +384,7 @@ is_complete (ECalModelComponent *comp_data)
prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_STATUS_PROPERTY);
if (prop && icalproperty_get_status (prop) == ICAL_STATUS_COMPLETED)
return TRUE;
-
+
return FALSE;
}
@@ -418,10 +418,10 @@ get_due_status (ECalModelTasks *model, ECalModelComponent *comp_data)
due_tt = icalproperty_get_due (prop);
if (due_tt.is_date) {
int cmp;
-
+
now_tt = icaltime_current_time_with_zone (e_cal_model_get_timezone (E_CAL_MODEL (model)));
cmp = icaltime_compare_date_only (due_tt, now_tt);
-
+
if (cmp < 0)
return E_CAL_MODEL_TASKS_DUE_OVERDUE;
else if (cmp == 0)
@@ -442,7 +442,7 @@ get_due_status (ECalModelTasks *model, ECalModelComponent *comp_data)
now_tt = icaltime_current_time_with_zone (zone);
- if (icaltime_compare (due_tt, now_tt) <= 0)
+ if (icaltime_compare (due_tt, now_tt) <= 0)
return E_CAL_MODEL_TASKS_DUE_OVERDUE;
else
if (icaltime_compare_date_only (due_tt, now_tt) == 0)
@@ -554,7 +554,7 @@ set_due (ECalModelComponent *comp_data, const void *value)
icalproperty *prop;
icalparameter *param;
const char *tzid;
-
+
prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_DUE_PROPERTY);
if (prop)
param = icalproperty_get_first_parameter (prop, ICAL_TZID_PARAMETER);
@@ -571,7 +571,7 @@ set_due (ECalModelComponent *comp_data, const void *value)
return;
}
-
+
/* If the TZID is set to "UTC", we set the is_utc flag. */
tzid = dv->zone ? icaltimezone_get_tzid (dv->zone) : "UTC";
if (tzid && !strcmp (tzid, "UTC"))
@@ -641,7 +641,7 @@ set_geo (ECalModelComponent *comp_data, const char *value)
prop = icalproperty_new_geo (geo);
icalcomponent_add_property (comp_data->icalcomp, prop);
}
-
+
}
}
@@ -691,7 +691,7 @@ set_status (ECalModelComponent *comp_data, const char *value)
case ICAL_STATUS_COMPLETED:
ensure_task_complete (comp_data, -1);
- break;
+ break;
default:
break;
}
@@ -731,12 +731,12 @@ set_percent (ECalModelComponent *comp_data, const void *value)
icalcomponent_remove_property (comp_data->icalcomp, prop);
icalproperty_free (prop);
}
-
+
if (percent > 0)
set_status (comp_data, _("In Progress"));
}
}
-
+
}
static void
@@ -904,7 +904,7 @@ static void
ecmt_free_value (ETableModel *etm, int col, void *value)
{
g_return_if_fail (col >= 0 && col < E_CAL_MODEL_TASKS_FIELD_LAST);
-
+
if (col < E_CAL_MODEL_FIELD_LAST) {
E_TABLE_MODEL_CLASS (e_cal_model_tasks_parent_class)->free_value (etm, col, value);
return;
@@ -1060,7 +1060,7 @@ ecmt_fill_component_from_model (ECalModel *model, ECalModelComponent *comp_data,
ETableModel *source_model, gint row)
{
void *value;
-
+
g_return_if_fail (E_IS_CAL_MODEL_TASKS (model));
g_return_if_fail (comp_data != NULL);
g_return_if_fail (E_IS_TABLE_MODEL (source_model));
@@ -1076,7 +1076,7 @@ ecmt_fill_component_from_model (ECalModel *model, ECalModelComponent *comp_data,
if (GPOINTER_TO_INT (value) != 100 && GPOINTER_TO_INT (value) != 0)
set_status (comp_data, e_table_model_value_at (source_model, E_CAL_MODEL_TASKS_FIELD_STATUS, row));
}
-
+
set_due (comp_data,
e_table_model_value_at (source_model, E_CAL_MODEL_TASKS_FIELD_DUE, row));
set_geo (comp_data,
@@ -1114,7 +1114,7 @@ void e_cal_model_tasks_mark_comp_complete (ECalModelTasks *model, ECalModelCompo
ensure_task_complete (comp_data, -1);
/*e_table_model_row_changed (E_TABLE_MODEL (model), model_row);*/
-
+
commit_component_changes (comp_data);
}
@@ -1131,15 +1131,15 @@ void e_cal_model_tasks_mark_comp_incomplete (ECalModelTasks *model, ECalModelCom
g_return_if_fail (model != NULL);
g_return_if_fail (comp_data != NULL);
-
+
/* we will receive changes when committed, so don't do this */
/*e_table_model_pre_change (E_TABLE_MODEL (model));*/
/* Status */
- prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_STATUS_PROPERTY);
- if (prop)
+ prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_STATUS_PROPERTY);
+ if (prop)
icalproperty_set_status (prop, ICAL_STATUS_NEEDSACTION);
- else
+ else
icalcomponent_add_property (comp_data->icalcomp, icalproperty_new_status (ICAL_STATUS_NEEDSACTION));
/*complete property*/
@@ -1198,7 +1198,7 @@ e_cal_model_tasks_update_due_tasks (ECalModelTasks *model)
{
comp_data = e_cal_model_get_component_at (E_CAL_MODEL (model), row);
status = get_due_status (E_CAL_MODEL_TASKS (model), comp_data);
- if((status == E_CAL_MODEL_TASKS_DUE_TODAY) || (status == E_CAL_MODEL_TASKS_DUE_OVERDUE))
+ if((status == E_CAL_MODEL_TASKS_DUE_TODAY) || (status == E_CAL_MODEL_TASKS_DUE_OVERDUE))
{
e_table_model_pre_change (E_TABLE_MODEL (model));
e_table_model_row_changed (E_TABLE_MODEL (model), row);
diff --git a/calendar/gui/e-cal-model.c b/calendar/gui/e-cal-model.c
index 36466c1ac1..ec387e43eb 100644
--- a/calendar/gui/e-cal-model.c
+++ b/calendar/gui/e-cal-model.c
@@ -47,7 +47,7 @@ struct _ECalModelPrivate {
/* The default client in the list */
ECal *default_client;
-
+
/* Array for storing the objects. Each element is of type ECalModelComponent */
GPtrArray *objects;
@@ -58,7 +58,7 @@ struct _ECalModelPrivate {
/* The time range to display */
time_t start;
time_t end;
-
+
/* The search regular expression */
gchar *search_sexp;
@@ -141,7 +141,7 @@ e_cal_model_class_init (ECalModelClass *klass)
G_STRUCT_OFFSET (ECalModelClass, time_range_changed),
NULL, NULL,
e_calendar_marshal_VOID__LONG_LONG,
- G_TYPE_NONE, 2, G_TYPE_LONG, G_TYPE_LONG);
+ G_TYPE_NONE, 2, G_TYPE_LONG, G_TYPE_LONG);
signals[ROW_APPENDED] =
g_signal_new ("row_appended",
@@ -225,13 +225,13 @@ e_cal_model_dispose (GObject *object)
if (priv->clients) {
while (priv->clients != NULL) {
ECalModelClient *client_data = (ECalModelClient *) priv->clients->data;
-
+
g_signal_handlers_disconnect_matched (client_data->client, G_SIGNAL_MATCH_DATA,
0, 0, NULL, NULL, model);
if (client_data->query)
g_signal_handlers_disconnect_matched (client_data->query, G_SIGNAL_MATCH_DATA,
0, 0, NULL, NULL, model);
-
+
priv->clients = g_list_remove (priv->clients, client_data);
@@ -349,7 +349,7 @@ get_description (ECalModelComponent *comp_data)
g_string_free (str, TRUE);
str = NULL;
}
-
+
prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_DESCRIPTION_PROPERTY);
if (prop) {
str = g_string_new (NULL);
@@ -475,7 +475,7 @@ ecm_value_at (ETableModel *etm, int col, int row)
g_object_unref (comp);
return GINT_TO_POINTER (retval);
}
-
+
if (e_cal_component_has_recurrences (comp))
retval = 1;
else if (itip_organizer_is_user (comp, comp_data->client))
@@ -600,7 +600,7 @@ set_dtstart (ECalModel *model, ECalModelComponent *comp_data, const void *value)
icalproperty *prop;
icalparameter *param;
const char *tzid;
-
+
prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_DTSTART_PROPERTY);
if (prop)
param = icalproperty_get_first_parameter (prop, ICAL_TZID_PARAMETER);
@@ -617,7 +617,7 @@ set_dtstart (ECalModel *model, ECalModelComponent *comp_data, const void *value)
return;
}
-
+
/* If the TZID is set to "UTC", we set the is_utc flag. */
tzid = dv->zone ? icaltimezone_get_tzid (dv->zone) : "UTC";
if (tzid && !strcmp (tzid, "UTC"))
@@ -705,7 +705,7 @@ ecm_set_value_at (ETableModel *etm, int col, int row, const void *value)
/* FIXME ask about mod type */
if (!e_cal_modify_object (comp_data->client, comp_data->icalcomp, CALOBJ_MOD_ALL, NULL)) {
g_warning (G_STRLOC ": Could not modify the object!");
-
+
/* FIXME Show error dialog */
}
}
@@ -723,7 +723,7 @@ e_cal_model_test_row_editable (ECalModel *model, int row)
{
gboolean readonly;
ECal *cal = NULL;
-
+
if (row != -1) {
ECalModelComponent *comp_data;
@@ -815,7 +815,7 @@ ecm_append_row (ETableModel *etm, ETableModel *source, int row)
icalcomponent_free (comp_data.icalcomp);
- g_signal_emit (G_OBJECT (model), signals[ROW_APPENDED], 0);
+ g_signal_emit (G_OBJECT (model), signals[ROW_APPENDED], 0);
}
static void *
@@ -1012,7 +1012,7 @@ ecm_get_color_for_component (ECalModel *model, ECalModelComponent *comp_data)
comp_data->color = g_strdup (color_spec);
return comp_data->color;
}
-
+
for (i = 0; i < G_N_ELEMENTS (assigned_colors); i++) {
GList *l;
@@ -1111,7 +1111,7 @@ e_cal_model_set_timezone (ECalModel *model, icaltimezone *zone)
{
ECalModelPrivate *priv;
GList *l;
-
+
g_return_if_fail (E_IS_CAL_MODEL (model));
priv = model->priv;
@@ -1121,7 +1121,7 @@ e_cal_model_set_timezone (ECalModel *model, icaltimezone *zone)
for (l = priv->clients; l; l = l->next)
e_cal_set_default_timezone (((ECalModelClient *)l->data)->client, priv->zone, NULL);
-
+
/* the timezone affects the times shown for date fields,
so we need to redisplay everything */
e_table_model_changed (E_TABLE_MODEL (model));
@@ -1180,7 +1180,7 @@ e_cal_model_get_default_client (ECalModel *model)
g_return_val_if_fail (model != NULL, NULL);
g_return_val_if_fail (E_IS_CAL_MODEL (model), NULL);
-
+
priv = model->priv;
/* FIXME Should we force the client to be open? */
@@ -1202,7 +1202,7 @@ e_cal_model_set_default_client (ECalModel *model, ECal *client)
{
ECalModelPrivate *priv;
ECalModelClient *client_data;
-
+
g_return_if_fail (model != NULL);
g_return_if_fail (E_IS_CAL_MODEL (model));
g_return_if_fail (client != NULL);
@@ -1219,12 +1219,12 @@ e_cal_model_set_default_client (ECalModel *model, ECal *client)
remove_client (model, client_data);
}
}
-
+
/* Make sure its in the model */
client_data = add_new_client (model, client, FALSE);
- /* Store the default client */
- priv->default_client = client_data->client;
+ /* Store the default client */
+ priv->default_client = client_data->client;
}
/**
@@ -1274,7 +1274,7 @@ find_client_data (ECalModel *model, ECal *client)
{
ECalModelPrivate *priv;
GList *l;
-
+
priv = model->priv;
for (l = priv->clients; l != NULL; l = l->next) {
@@ -1282,7 +1282,7 @@ find_client_data (ECalModel *model, ECal *client)
if (client_data->client == client)
return client_data;
- }
+ }
return NULL;
}
@@ -1305,7 +1305,7 @@ search_by_id_and_client (ECalModelPrivate *priv, ECal *client, const ECalCompone
if (uid && *uid) {
if ((!client || comp_data->client == client) && !strcmp (id->uid, uid)) {
if (has_rid) {
- if (!(rid && *rid && !strcmp (rid, id->rid)))
+ if (!(rid && *rid && !strcmp (rid, id->rid)))
continue;
}
return comp_data;
@@ -1316,7 +1316,7 @@ search_by_id_and_client (ECalModelPrivate *priv, ECal *client, const ECalCompone
return NULL;
}
-
+
typedef struct {
ECal *client;
ECalView *query;
@@ -1345,15 +1345,15 @@ add_instance_cb (ECalComponent *comp, time_t instance_start, time_t instance_end
e_cal_get_timezone (rdata->client, datetime.tzid, &zone, NULL);
time = icaltime_from_timet_with_zone (instance_start, FALSE, zone ? zone : priv->zone);
to_set.value = &time;
- to_set.tzid = datetime.tzid;
+ to_set.tzid = datetime.tzid;
e_cal_component_set_dtstart (comp, &to_set);
-
+
/* set the right instance end date to component*/
e_cal_component_get_dtend (comp, &datetime);
e_cal_get_timezone (rdata->client, datetime.tzid, &zone, NULL);
time = icaltime_from_timet_with_zone (instance_end, FALSE, zone ? zone : priv->zone);
to_set.value = &time;
- to_set.tzid = datetime.tzid;
+ to_set.tzid = datetime.tzid;
e_cal_component_set_dtend (comp, &to_set);
comp_data = g_new0 (ECalModelComponent, 1);
@@ -1476,16 +1476,16 @@ e_cal_view_objects_removed_cb (ECalView *query, GList *ids, gpointer user_data)
ECalModelPrivate *priv;
ECalModel *model = (ECalModel *) user_data;
GList *l;
-
+
priv = model->priv;
-
+
for (l = ids; l; l = l->next) {
ECalModelComponent *comp_data = NULL;
ECalComponentId *id = l->data;
int pos;
e_table_model_pre_change (E_TABLE_MODEL (model));
-
+
/* make sure we remove all objects with this UID */
while ((comp_data = search_by_id_and_client (priv, e_cal_view_get_client (query), id))) {
pos = get_position_in_array (priv->objects, comp_data);
@@ -1505,7 +1505,7 @@ e_cal_view_progress_cb (ECalView *query, const char *message, int percent, gpoin
g_return_if_fail (E_IS_CAL_MODEL (model));
- g_signal_emit (G_OBJECT (model), signals[CAL_VIEW_PROGRESS], 0, message,
+ g_signal_emit (G_OBJECT (model), signals[CAL_VIEW_PROGRESS], 0, message,
percent, e_cal_get_source_type (client));
}
@@ -1532,7 +1532,7 @@ update_e_cal_view_for_client (ECalModel *model, ECalModelClient *client_data)
/* Skip if this client has not finished loading yet */
if (e_cal_get_load_state (client_data->client) != E_CAL_LOAD_LOADED)
return;
-
+
/* free the previous query, if any */
if (client_data->query) {
g_signal_handlers_disconnect_matched (client_data->query, G_SIGNAL_MATCH_DATA,
@@ -1547,12 +1547,12 @@ update_e_cal_view_for_client (ECalModel *model, ECalModelClient *client_data)
/* Don't create the new query if we won't use it */
if (!client_data->do_query)
return;
-
+
if (!e_cal_get_query (client_data->client, priv->full_sexp, &client_data->query, NULL)) {
g_warning (G_STRLOC ": Unable to get query");
return;
- }
+ }
g_signal_connect (client_data->query, "objects_added", G_CALLBACK (e_cal_view_objects_added_cb), model);
g_signal_connect (client_data->query, "objects_modified", G_CALLBACK (e_cal_view_objects_modified_cb), model);
@@ -1583,19 +1583,19 @@ cal_opened_cb (ECal *client, ECalendarStatus status, gpointer user_data)
e_cal_open_async (client, FALSE);
return;
}
-
+
if (status != E_CALENDAR_STATUS_OK) {
e_cal_model_remove_client (model, client);
return;
}
-
+
/* Stop listening for this calendar to be opened */
g_signal_handlers_disconnect_matched (client, G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, 0, 0, NULL, cal_opened_cb, model);
client_data = find_client_data (model, client);
g_return_if_fail (client_data);
-
+
update_e_cal_view_for_client (model, client_data);
}
@@ -1605,20 +1605,20 @@ add_new_client (ECalModel *model, ECal *client, gboolean do_query)
{
ECalModelPrivate *priv;
ECalModelClient *client_data;
-
+
priv = model->priv;
/* Look to see if we already have this client */
- client_data = find_client_data (model, client);
+ client_data = find_client_data (model, client);
if (client_data) {
if (client_data->do_query)
return client_data;
else
client_data->do_query = do_query;
-
+
goto load;
}
-
+
client_data = g_new0 (ECalModelClient, 1);
client_data->client = g_object_ref (client);
client_data->query = NULL;
@@ -1651,14 +1651,14 @@ e_cal_model_add_client (ECalModel *model, ECal *client)
g_return_if_fail (E_IS_CAL_MODEL (model));
g_return_if_fail (E_IS_CAL (client));
/* Check this return value or drop the assignment? */
- client_data = add_new_client (model, client, TRUE);
+ client_data = add_new_client (model, client, TRUE);
}
static void
remove_client_objects (ECalModel *model, ECalModelClient *client_data)
{
int i;
-
+
/* remove all objects belonging to this client */
for (i = model->priv->objects->len; i > 0; i--) {
ECalModelComponent *comp_data = (ECalModelComponent *) g_ptr_array_index (model->priv->objects, i - 1);
@@ -1689,7 +1689,7 @@ remove_client (ECalModel *model, ECalModelClient *client_data)
* was also a source), keep it around but don't query it */
if (model->priv->default_client == client_data->client && client_data->do_query) {
client_data->do_query = FALSE;
-
+
return;
}
@@ -1710,7 +1710,7 @@ void
e_cal_model_remove_client (ECalModel *model, ECal *client)
{
ECalModelClient *client_data;
-
+
g_return_if_fail (E_IS_CAL_MODEL (model));
g_return_if_fail (E_IS_CAL (client));
@@ -1743,7 +1743,7 @@ redo_queries (ECalModel *model)
char *iso_start, *iso_end;
GList *l;
int len;
-
+
priv = model->priv;
if (priv->full_sexp)
@@ -1752,28 +1752,28 @@ redo_queries (ECalModel *model)
if (priv->start != -1 && priv->end != -1) {
iso_start = isodate_from_time_t (priv->start);
iso_end = isodate_from_time_t (priv->end);
-
+
priv->full_sexp = g_strdup_printf ("(and (occur-in-time-range? (make-time \"%s\")"
" (make-time \"%s\"))"
" %s)",
- iso_start, iso_end,
+ iso_start, iso_end,
priv->search_sexp ? priv->search_sexp : "");
} else if (priv->search_sexp) {
priv->full_sexp = g_strdup (priv->search_sexp);
} else {
priv->full_sexp = g_strdup ("#f");
- }
-
+ }
+
/* clean up the current contents */
e_table_model_pre_change (E_TABLE_MODEL (model));
len = priv->objects->len;
e_table_model_rows_deleted (E_TABLE_MODEL (model), 0, len);
clear_objects_array (priv);
-
+
/* update the query for all clients */
for (l = priv->clients; l != NULL; l = l->next) {
ECalModelClient *client_data;
-
+
client_data = (ECalModelClient *) l->data;
update_e_cal_view_for_client (model, client_data);
}
@@ -1783,15 +1783,15 @@ void
e_cal_model_get_time_range (ECalModel *model, time_t *start, time_t *end)
{
ECalModelPrivate *priv;
-
+
g_return_if_fail (model != NULL);
g_return_if_fail (E_IS_CAL_MODEL (model));
priv = model->priv;
-
+
if (start)
*start = priv->start;
-
+
if (end)
*end = priv->end;
}
@@ -1800,7 +1800,7 @@ void
e_cal_model_set_time_range (ECalModel *model, time_t start, time_t end)
{
ECalModelPrivate *priv;
-
+
g_return_if_fail (model != NULL);
g_return_if_fail (E_IS_CAL_MODEL (model));
g_return_if_fail (start >= 0 && end >= 0);
@@ -1810,7 +1810,7 @@ e_cal_model_set_time_range (ECalModel *model, time_t start, time_t end)
if (priv->start == start && priv->end == end)
return;
-
+
priv->start = start;
priv->end = end;
@@ -1822,12 +1822,12 @@ const char *
e_cal_model_get_search_query (ECalModel *model)
{
ECalModelPrivate *priv;
-
+
g_return_val_if_fail (model != NULL, NULL);
g_return_val_if_fail (E_IS_CAL_MODEL (model), NULL);
priv = model->priv;
-
+
return priv->search_sexp;
}
@@ -1874,7 +1874,7 @@ e_cal_model_set_search_query_with_time_range (ECalModel *model, const char *sexp
priv->search_sexp = g_strdup (sexp);
do_query = TRUE;
}
-
+
if (!(priv->start == start && priv->end == end)) {
priv->start = start;
priv->end = end;
@@ -2013,7 +2013,7 @@ e_cal_model_get_component_for_uid (ECalModel *model, const ECalComponentId *id)
priv = model->priv;
return search_by_id_and_client (priv, NULL, id);
-}
+}
/**
* e_cal_model_date_value_to_string
@@ -2059,7 +2059,7 @@ static ECellDateEditValue *
copy_ecdv (ECellDateEditValue *ecdv)
{
ECellDateEditValue *new_ecdv;
-
+
new_ecdv = g_new0 (ECellDateEditValue, 1);
new_ecdv->tt = ecdv ? ecdv->tt : icaltime_null_time ();
new_ecdv->zone = ecdv ? ecdv->zone : NULL;
@@ -2207,7 +2207,7 @@ e_cal_model_set_instance_times (ECalModelComponent *comp_data, const icaltimezon
else {
icalparameter *param = NULL;
icalproperty *prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_DTSTART_PROPERTY);
-
+
if (prop) {
param = icalproperty_get_first_parameter (prop, ICAL_TZID_PARAMETER);
@@ -2223,7 +2223,7 @@ e_cal_model_set_instance_times (ECalModelComponent *comp_data, const icaltimezon
}
}
}
-
+
comp_data->instance_start = icaltime_as_timet_with_zone (start_time, zone);
if (end_time.zone)
@@ -2231,7 +2231,7 @@ e_cal_model_set_instance_times (ECalModelComponent *comp_data, const icaltimezon
else {
icalparameter *param = NULL;
icalproperty *prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_DTSTART_PROPERTY);
-
+
if (prop) {
param = icalproperty_get_first_parameter (prop, ICAL_TZID_PARAMETER);
diff --git a/calendar/gui/e-cal-popup.c b/calendar/gui/e-cal-popup.c
index 983f922958..caa69f015a 100644
--- a/calendar/gui/e-cal-popup.c
+++ b/calendar/gui/e-cal-popup.c
@@ -129,7 +129,7 @@ temp_save_part(CamelMimePart *part, char *path, gboolean file)
g_free (utf8_mfilename);
filename = (const char *) mfilename;
}
-
+
path = g_build_filename(tmpdir, filename, NULL);
g_free(mfilename);
}
@@ -173,12 +173,12 @@ ecalp_part_popup_saveas(EPopup *ep, EPopupItem *item, void *data)
mfilename = g_strdup(filename);
e_filename_make_safe(mfilename);
filename = mfilename;
- }
+ }
file = e_file_dialog_save (_("Save As..."), filename);
-
+
if (file)
temp_save_part (part, file, TRUE);
-
+
g_free (file);
g_free (mfilename);
}
@@ -189,10 +189,10 @@ ecalp_part_popup_save_selected(EPopup *ep, EPopupItem *item, void *data)
GSList *parts;
EPopupTarget *t = ep->target;
char *dir, *path;
-
+
dir = e_file_dialog_save_folder (_("Select folder to save selected attachments..."));
parts = ((ECalPopupTargetAttachments *) t)->attachments;
-
+
for (;parts; parts=parts->next) {
path = temp_save_part (((EAttachment *)parts->data)->body, dir, FALSE);
/* Probably we 'll do some reporting in next release, like listing the saved files and locations */
@@ -215,7 +215,7 @@ ecalp_part_popup_set_background(EPopup *ep, EPopupItem *item, void *data)
return;
filename = g_strdup(camel_mime_part_get_filename(part));
-
+
/* if filename is blank, create a default filename based on MIME type */
if (!filename || !filename[0]) {
CamelContentType *ct;
@@ -226,13 +226,13 @@ ecalp_part_popup_set_background(EPopup *ep, EPopupItem *item, void *data)
}
e_filename_make_safe(filename);
-
+
path = g_build_filename(g_get_home_dir(), ".gnome2", "wallpapers", filename, NULL);
-
+
extension = strrchr(filename, '.');
if (extension)
*extension++ = 0;
-
+
/* if file exists, stick a (number) on the end */
while (g_file_test(path, G_FILE_TEST_EXISTS)) {
char *name;
@@ -241,35 +241,35 @@ ecalp_part_popup_set_background(EPopup *ep, EPopupItem *item, void *data)
path = g_build_filename(g_get_home_dir(), ".gnome2", "wallpapers", name, NULL);
g_free(name);
}
-
+
g_free(filename);
-
+
if (temp_save_part(part, path, TRUE)) {
gconf = gconf_client_get_default();
-
- /* if the filename hasn't changed, blank the filename before
+
+ /* if the filename hasn't changed, blank the filename before
* setting it so that gconf detects a change and updates it */
- if ((str = gconf_client_get_string(gconf, "/desktop/gnome/background/picture_filename", NULL)) != NULL
+ if ((str = gconf_client_get_string(gconf, "/desktop/gnome/background/picture_filename", NULL)) != NULL
&& strcmp (str, path) == 0) {
gconf_client_set_string(gconf, "/desktop/gnome/background/picture_filename", "", NULL);
}
-
+
g_free (str);
gconf_client_set_string(gconf, "/desktop/gnome/background/picture_filename", path, NULL);
-
+
/* if GNOME currently doesn't display a picture, set to "wallpaper"
* display mode, otherwise leave it alone */
- if ((str = gconf_client_get_string(gconf, "/desktop/gnome/background/picture_options", NULL)) == NULL
+ if ((str = gconf_client_get_string(gconf, "/desktop/gnome/background/picture_options", NULL)) == NULL
|| strcmp(str, "none") == 0) {
gconf_client_set_string(gconf, "/desktop/gnome/background/picture_options", "wallpaper", NULL);
}
-
+
gconf_client_suggest_sync(gconf, NULL);
-
+
g_free(str);
g_object_unref(gconf);
}
-
+
g_free(path);
}
@@ -296,7 +296,7 @@ ecalp_apps_open_in(EPopup *ep, EPopupItem *item, void *data)
GnomeVFSMimeApplication *app = item->user_data;
char *uri;
GList *uris = NULL;
-
+
uri = gnome_vfs_get_uri_from_local_path(path);
uris = g_list_append(uris, uri);
@@ -330,7 +330,7 @@ ecalp_standard_items_free(EPopup *ep, GSList *items, void *data)
g_slist_free(items);
}
-static void
+static void
ecalp_standard_menu_factory (EPopup *ecalp, void *data)
{
int i, len;
@@ -359,18 +359,18 @@ ecalp_standard_menu_factory (EPopup *ecalp, void *data)
filename = camel_mime_part_get_filename(attachment->body);
- break; }
+ break; }
default:
items = NULL;
- len = 0;
+ len = 0;
}
if (mime_type) {
apps = gnome_vfs_mime_get_all_applications(mime_type);
-
+
if (apps == NULL && strcmp(mime_type, "application/octet-stream") == 0) {
const char *name_type;
-
+
if (filename) {
/* GNOME-VFS will misidentify TNEF attachments as MPEG */
if (!strcmp (filename, "winmail.dat"))
@@ -464,12 +464,12 @@ ECalPopup *e_cal_popup_new(const char *menuid)
static icalproperty *
get_attendee_prop (icalcomponent *icalcomp, const char *address)
{
-
+
icalproperty *prop;
if (!(address && *address))
return NULL;
-
+
for (prop = icalcomponent_get_first_property (icalcomp, ICAL_ATTENDEE_PROPERTY);
prop;
prop = icalcomponent_get_next_property (icalcomp, ICAL_ATTENDEE_PROPERTY)) {
@@ -481,14 +481,14 @@ get_attendee_prop (icalcomponent *icalcomp, const char *address)
}
return NULL;
}
-
-static gboolean
+
+static gboolean
is_delegated (icalcomponent *icalcomp, char *user_email)
{
icalproperty *prop;
icalparameter *param;
const char *delto = NULL;
-
+
prop = get_attendee_prop (icalcomp, user_email);
if (prop) {
@@ -496,8 +496,8 @@ is_delegated (icalcomponent *icalcomp, char *user_email)
delto = icalparameter_get_delegatedto (param);
} else
return FALSE;
-
- prop = get_attendee_prop (icalcomp, itip_strip_mailto (delto));
+
+ prop = get_attendee_prop (icalcomp, itip_strip_mailto (delto));
if (prop) {
const char *delfrom;
@@ -512,20 +512,20 @@ is_delegated (icalcomponent *icalcomp, char *user_email)
return TRUE;
}
- return FALSE;
+ return FALSE;
}
static gboolean
-needs_to_accept (icalcomponent *icalcomp, char *user_email)
+needs_to_accept (icalcomponent *icalcomp, char *user_email)
{
icalproperty *prop;
icalparameter *param;
icalparameter_partstat status;
-
+
prop = get_attendee_prop (icalcomp, user_email);
/* It might be a mailing list */
- if (!prop)
+ if (!prop)
return TRUE;
param = icalproperty_get_first_parameter (prop, ICAL_PARTSTAT_PARAMETER);
status = icalparameter_get_partstat (param);
@@ -543,10 +543,10 @@ needs_to_accept (icalcomponent *icalcomp, char *user_email)
* @events: An array of pointers to ECalModelComponent items. These
* items must be copied. They, and the @events array will be freed by
* the popup menu automatically.
- *
+ *
* Create a new selection popup target.
- *
- * Return value:
+ *
+ * Return value:
**/
ECalPopupTargetSelect *
e_cal_popup_target_new_select(ECalPopup *eabp, struct _ECalModel *model, GPtrArray *events)
@@ -555,13 +555,13 @@ e_cal_popup_target_new_select(ECalPopup *eabp, struct _ECalModel *model, GPtrArr
guint32 mask = ~0;
ECal *client;
gboolean read_only, user_org = FALSE;
-
+
/* FIXME: This is duplicated in e-cal-menu */
t->model = model;
g_object_ref(t->model);
t->events = events;
-
+
if (t->events->len == 0) {
client = e_cal_model_get_default_client(t->model);
} else {
@@ -583,7 +583,7 @@ e_cal_popup_target_new_select(ECalPopup *eabp, struct _ECalModel *model, GPtrArr
/* Now check for any incomplete tasks and set the flags*/
for (; i < t->events->len; i++) {
ECalModelComponent *comp_data = (ECalModelComponent *)t->events->pdata[i];
- if (!icalcomponent_get_first_property (comp_data->icalcomp, ICAL_COMPLETED_PROPERTY))
+ if (!icalcomponent_get_first_property (comp_data->icalcomp, ICAL_COMPLETED_PROPERTY))
mask &= ~E_CAL_POPUP_SELECT_NOTCOMPLETE;
else
mask &= ~E_CAL_POPUP_SELECT_COMPLETE;
@@ -640,7 +640,7 @@ e_cal_popup_target_new_select(ECalPopup *eabp, struct _ECalModel *model, GPtrArr
if (icalcomponent_get_first_property (comp_data->icalcomp, ICAL_COMPLETED_PROPERTY))
mask &= ~E_CAL_POPUP_SELECT_COMPLETE;
-
+
g_object_unref (comp);
g_free (user_email);
}
@@ -649,8 +649,8 @@ e_cal_popup_target_new_select(ECalPopup *eabp, struct _ECalModel *model, GPtrArr
if (!read_only)
mask &= ~E_CAL_POPUP_SELECT_EDITABLE;
-
-
+
+
if (!e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_NO_TASK_ASSIGNMENT)
&& !e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_NO_CONV_TO_ASSIGN_TASK))
mask &= ~E_CAL_POPUP_SELECT_ASSIGNABLE;
@@ -697,7 +697,7 @@ e_cal_popup_target_new_source(ECalPopup *eabp, ESourceSelector *selector)
/* check for e_target_selector's offline_status property here */
offline = e_source_get_property (source, "offline");
- if (offline && strcmp (offline,"1") == 0) {
+ if (offline && strcmp (offline,"1") == 0) {
/* set the menu item to Mark Offline - */
mask &= ~E_CAL_POPUP_SOURCE_NO_OFFLINE;
} else {
@@ -708,7 +708,7 @@ e_cal_popup_target_new_source(ECalPopup *eabp, ESourceSelector *selector)
mask |= E_CAL_POPUP_SOURCE_OFFLINE;
}
g_free (uri);
-
+
source = e_source_selector_peek_primary_selection (selector);
/*check for delete_status property here*/
delete = e_source_get_property (source, "delete");
@@ -729,13 +729,13 @@ e_cal_popup_target_new_source(ECalPopup *eabp, ESourceSelector *selector)
/**
* e_cal_popup_target_new_attachments:
- * @ecp:
+ * @ecp:
* @attachments: A list of CalAttachment objects, reffed for
* the list. Will be unreff'd once finished with.
- *
+ *
* Owns the list @attachments and their items after they're passed in.
- *
- * Return value:
+ *
+ * Return value:
**/
ECalPopupTargetAttachments *
e_cal_popup_target_new_attachments(ECalPopup *ecp, CompEditor *editor, GSList *attachments)
@@ -752,10 +752,10 @@ e_cal_popup_target_new_attachments(ECalPopup *ecp, CompEditor *editor, GSList *a
if (error->code != E_CALENDAR_STATUS_BUSY)
read_only = TRUE;
g_error_free (error);
- }
+ }
- if (!read_only && (!(flags & COMP_EDITOR_MEETING) ||
- (flags & COMP_EDITOR_NEW_ITEM) ||
+ if (!read_only && (!(flags & COMP_EDITOR_MEETING) ||
+ (flags & COMP_EDITOR_NEW_ITEM) ||
(flags & COMP_EDITOR_USER_ORG)))
mask &= ~ E_CAL_POPUP_ATTACHMENTS_MODIFY;
@@ -771,7 +771,7 @@ e_cal_popup_target_new_attachments(ECalPopup *ecp, CompEditor *editor, GSList *a
if (len > 1)
mask &= ~ E_CAL_POPUP_ATTACHMENTS_MULTIPLE;
-
+
t->target.mask = mask;
return t;
@@ -820,7 +820,7 @@ static const EPopupHookTargetMask ecalph_select_masks[] = {
{ "meeting", E_CAL_POPUP_SELECT_MEETING },
{ "assignable", E_CAL_POPUP_SELECT_ASSIGNABLE },
{ "hasurl", E_CAL_POPUP_SELECT_HASURL },
- { "delegate", E_CAL_POPUP_SELECT_DELEGATABLE },
+ { "delegate", E_CAL_POPUP_SELECT_DELEGATABLE },
{ "accept", E_CAL_POPUP_SELECT_ACCEPTABLE },
{ "not-complete", E_CAL_POPUP_SELECT_NOTCOMPLETE },
{ "no-save-schedules", E_CAL_POPUP_SELECT_NOSAVESCHEDULES },
@@ -833,9 +833,9 @@ static const EPopupHookTargetMask ecalph_source_masks[] = {
{ "system", E_CAL_POPUP_SOURCE_SYSTEM },
{ "user", E_CAL_POPUP_SOURCE_USER },
{ "offline", E_CAL_POPUP_SOURCE_OFFLINE},
- { "no-offline", E_CAL_POPUP_SOURCE_NO_OFFLINE},
+ { "no-offline", E_CAL_POPUP_SOURCE_NO_OFFLINE},
{ "delete", E_CAL_POPUP_SOURCE_DELETE},
- { "no-delete", E_CAL_POPUP_SOURCE_NO_DELETE},
+ { "no-delete", E_CAL_POPUP_SOURCE_NO_DELETE},
{ NULL }
};
@@ -882,7 +882,7 @@ GType
e_cal_popup_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(ECalPopupHookClass), NULL, NULL, (GClassInitFunc) ecalph_class_init, NULL, NULL,
@@ -892,6 +892,6 @@ e_cal_popup_hook_get_type(void)
ecalph_parent_class = g_type_class_ref(e_popup_hook_get_type());
type = g_type_register_static(e_popup_hook_get_type(), "ECalPopupHook", &info, 0);
}
-
+
return type;
}
diff --git a/calendar/gui/e-cal-popup.h b/calendar/gui/e-cal-popup.h
index 70e61fefa6..ee3e94413f 100644
--- a/calendar/gui/e-cal-popup.h
+++ b/calendar/gui/e-cal-popup.h
@@ -39,7 +39,7 @@ struct _ECalendarView;
/**
* enum _e_cal_popup_target_t - A list of mail popup target types.
- *
+ *
* @E_CAL_POPUP_TARGET_SELECT: A selection of cards
* @E_CAL_POPUP_TARGET_SOURCE: A source selection.
*
@@ -53,7 +53,7 @@ enum _e_cal_popup_target_t {
/**
* enum _e_cal_popup_target_select_t - ECalPopupTargetSelect qualifiers.
- *
+ *
* @E_CAL_POPUP_SELECT_ONE: Only one item is selected.
* @E_CAL_POPUP_SELECT_MANY: More than one item selected.
* @E_CAL_POPUP_SELECT_ANY: One ore more items are selected.
@@ -92,10 +92,10 @@ enum _e_cal_popup_target_select_t {
/**
* enum _e_cal_popup_target_source_t - ECalPopupTargetSource qualifiers.
- *
+ *
* @E_CAL_POPUP_SOURCE_PRIMARY: Has a primary selection.
* @E_CAL_POPUP_SOURCE_SYSTEM: Is a 'system' folder.
- *
+ *
**/
enum _e_cal_popup_target_source_t {
E_CAL_POPUP_SOURCE_PRIMARY = 1<<0,
@@ -109,10 +109,10 @@ enum _e_cal_popup_target_source_t {
/**
* enum _e_cal_popup_target_attachments_t - ECalPopupTargetAttachments qualifiers.
- *
+ *
* @E_CAL_POPUP_ATTACHMENTS_ONE: There is one and only one attachment selected.
* @E_CAL_POPUP_ATTACHMENTS_MANY: There is one or more attachments selected.
- *
+ *
**/
enum _e_cal_popup_target_attachments_t {
E_CAL_POPUP_ATTACHMENTS_ONE = 1<<0, /* only 1 selected */
@@ -128,7 +128,7 @@ typedef struct _ECalPopupTargetAttachments ECalPopupTargetAttachments;
/**
* struct _ECalPopupTargetSelect - A list of address cards.
- *
+ *
* @target: Superclass. target.widget is an ECalendarView.
* @model: The ECalModel.
* @events: The selected events. These are ECalModelComponent's.
@@ -148,7 +148,7 @@ struct _ECalPopupTargetSelect {
/**
* struct _ECalPopupTargetSource - A source target.
- *
+ *
* @target: Superclass.
* @selector: Selector holding the source selection.
*
@@ -162,7 +162,7 @@ struct _ECalPopupTargetSource {
/**
* struct _ECalPopupTargetAttachments - A list of calendar attachments.
- *
+ *
* @target: Superclass.
* @attachments: A GSList list of CalAttachments.
*
@@ -193,7 +193,7 @@ ECalPopup *e_cal_popup_new(const char *menuid);
ECalPopupTargetSelect *e_cal_popup_target_new_select(ECalPopup *eabp, struct _ECalModel *model, GPtrArray *events);
ECalPopupTargetSource *e_cal_popup_target_new_source(ECalPopup *eabp, struct _ESourceSelector *selector);
-ECalPopupTargetAttachments * e_cal_popup_target_new_attachments (ECalPopup *ecp,
+ECalPopupTargetAttachments * e_cal_popup_target_new_attachments (ECalPopup *ecp,
CompEditor *editor, GSList *attachments);
/* ********************************************************************** */
diff --git a/calendar/gui/e-calendar-table-config.c b/calendar/gui/e-calendar-table-config.c
index 588098950b..5750ceb8c9 100644
--- a/calendar/gui/e-calendar-table-config.c
+++ b/calendar/gui/e-calendar-table-config.c
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -28,7 +28,7 @@ struct _ECalendarTableConfigPrivate {
ECalendarTable *table;
ECellDateEditConfig *cell_config;
-
+
GList *notifications;
};
@@ -46,7 +46,7 @@ e_calendar_table_config_set_property (GObject *object, guint property_id, const
ECalendarTableConfig *table_config;
table_config = E_CALENDAR_TABLE_CONFIG (object);
-
+
switch (property_id) {
case PROP_TABLE:
e_calendar_table_config_set_table (table_config, g_value_get_object (value));
@@ -63,7 +63,7 @@ e_calendar_table_config_get_property (GObject *object, guint property_id, GValue
ECalendarTableConfig *table_config;
table_config = E_CALENDAR_TABLE_CONFIG (object);
-
+
switch (property_id) {
case PROP_TABLE:
g_value_set_object (value, e_calendar_table_config_get_table (table_config));
@@ -78,9 +78,9 @@ static void
e_calendar_table_config_dispose (GObject *object)
{
ECalendarTableConfig *table_config = E_CALENDAR_TABLE_CONFIG (object);
-
+
e_calendar_table_config_set_table (table_config, NULL);
-
+
if (G_OBJECT_CLASS (e_calendar_table_config_parent_class)->dispose)
G_OBJECT_CLASS (e_calendar_table_config_parent_class)->dispose (object);
}
@@ -90,11 +90,11 @@ e_calendar_table_config_finalize (GObject *object)
{
ECalendarTableConfig *table_config = E_CALENDAR_TABLE_CONFIG (object);
ECalendarTableConfigPrivate *priv;
-
+
priv = table_config->priv;
g_free (priv);
-
+
if (G_OBJECT_CLASS (e_calendar_table_config_parent_class)->finalize)
G_OBJECT_CLASS (e_calendar_table_config_parent_class)->finalize (object);
}
@@ -104,7 +104,7 @@ e_calendar_table_config_class_init (ECalendarTableConfigClass *klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
GParamSpec *spec;
-
+
/* Method override */
gobject_class->set_property = e_calendar_table_config_set_property;
gobject_class->get_property = e_calendar_table_config_get_property;
@@ -127,14 +127,14 @@ ECalendarTableConfig *
e_calendar_table_config_new (ECalendarTable *table)
{
ECalendarTableConfig *table_config;
-
+
table_config = g_object_new (e_calendar_table_config_get_type (), "table", table, NULL);
return table_config;
}
ECalendarTable *
-e_calendar_table_config_get_table (ECalendarTableConfig *table_config)
+e_calendar_table_config_get_table (ECalendarTableConfig *table_config)
{
ECalendarTableConfigPrivate *priv;
@@ -142,17 +142,17 @@ e_calendar_table_config_get_table (ECalendarTableConfig *table_config)
g_return_val_if_fail (E_IS_CALENDAR_TABLE_CONFIG (table_config), NULL);
priv = table_config->priv;
-
+
return priv->table;
}
static void
-set_timezone (ECalendarTable *table)
+set_timezone (ECalendarTable *table)
{
ECalModel *model;
icaltimezone *zone;
-
- zone = calendar_config_get_icaltimezone ();
+
+ zone = calendar_config_get_icaltimezone ();
model = e_calendar_table_get_model (table);
if (model)
e_cal_model_set_timezone (model, zone);
@@ -163,14 +163,14 @@ timezone_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer
{
ECalendarTableConfig *table_config = data;
ECalendarTableConfigPrivate *priv;
-
+
priv = table_config->priv;
-
+
set_timezone (priv->table);
}
static void
-set_twentyfour_hour (ECalendarTable *table)
+set_twentyfour_hour (ECalendarTable *table)
{
ECalModel *model;
gboolean use_24_hour;
@@ -187,24 +187,24 @@ twentyfour_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gp
{
ECalendarTableConfig *table_config = data;
ECalendarTableConfigPrivate *priv;
-
+
priv = table_config->priv;
-
+
set_twentyfour_hour (priv->table);
}
void
-e_calendar_table_config_set_table (ECalendarTableConfig *table_config, ECalendarTable *table)
+e_calendar_table_config_set_table (ECalendarTableConfig *table_config, ECalendarTable *table)
{
ECalendarTableConfigPrivate *priv;
guint not;
GList *l;
-
+
g_return_if_fail (table_config != NULL);
g_return_if_fail (E_IS_CALENDAR_TABLE_CONFIG (table_config));
priv = table_config->priv;
-
+
if (priv->table) {
g_object_unref (priv->table);
priv->table = NULL;
@@ -214,7 +214,7 @@ e_calendar_table_config_set_table (ECalendarTableConfig *table_config, ECalendar
g_object_unref (priv->cell_config);
priv->cell_config = NULL;
}
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
@@ -224,17 +224,17 @@ e_calendar_table_config_set_table (ECalendarTableConfig *table_config, ECalendar
/* If the new view is NULL, return right now */
if (!table)
return;
-
+
priv->table = g_object_ref (table);
/* Time zone */
set_timezone (table);
-
+
not = calendar_config_add_notification_timezone (timezone_changed_cb, table_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* 24 Hour format */
- set_twentyfour_hour (table);
+ set_twentyfour_hour (table);
not = calendar_config_add_notification_24_hour_format (twentyfour_hour_changed_cb, table_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
diff --git a/calendar/gui/e-calendar-table-config.h b/calendar/gui/e-calendar-table-config.h
index c11f3a0681..93b1dadf9b 100644
--- a/calendar/gui/e-calendar-table-config.h
+++ b/calendar/gui/e-calendar-table-config.h
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -30,7 +30,7 @@ G_BEGIN_DECLS
#define E_CALENDAR_TABLE_CONFIG(obj) GTK_CHECK_CAST (obj, e_calendar_table_config_get_type (), ECalendarTableConfig)
#define E_CALENDAR_TABLE_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_calendar_table_config_get_type (), ECalendarTableConfigClass)
#define E_IS_CALENDAR_TABLE_CONFIG(obj) GTK_CHECK_TYPE (obj, e_calendar_table_config_get_type ())
-
+
typedef struct _ECalendarTableConfig ECalendarTableConfig;
typedef struct _ECalendarTableConfigClass ECalendarTableConfigClass;
typedef struct _ECalendarTableConfigPrivate ECalendarTableConfigPrivate;
diff --git a/calendar/gui/e-calendar-table.c b/calendar/gui/e-calendar-table.c
index 1d8d48ab13..60d4dba6e4 100644
--- a/calendar/gui/e-calendar-table.c
+++ b/calendar/gui/e-calendar-table.c
@@ -221,7 +221,7 @@ priority_compare_cb (gconstpointer a, gconstpointer b)
}
static void
-row_appended_cb (ECalModel *model, ECalendarTable *cal_table)
+row_appended_cb (ECalModel *model, ECalendarTable *cal_table)
{
g_signal_emit (cal_table, signals[USER_CREATED], 0);
}
@@ -481,9 +481,9 @@ e_calendar_table_new (void)
/**
* e_calendar_table_get_model:
* @cal_table: A calendar table.
- *
+ *
* Queries the calendar data model that a calendar table is using.
- *
+ *
* Return value: A calendar model.
**/
ECalModel *
@@ -514,9 +514,9 @@ e_calendar_table_destroy (GtkObject *object)
/**
* e_calendar_table_get_table:
* @cal_table: A calendar table.
- *
+ *
* Queries the #ETable widget that the calendar table is using.
- *
+ *
* Return value: The #ETable widget that the calendar table uses to display its
* data.
**/
@@ -544,7 +544,7 @@ e_calendar_table_open_selected (ECalendarTable *cal_table)
/**
* e_calendar_table_complete_selected:
* @cal_table: A calendar table
- *
+ *
* Marks the selected items as completed
**/
void
@@ -637,8 +637,8 @@ delete_selected_components (ECalendarTable *cal_table)
for (l = objs; l; l = l->next) {
ECalModelComponent *comp_data = (ECalModelComponent *) l->data;
GError *error = NULL;
-
- e_cal_remove_object (comp_data->client,
+
+ e_cal_remove_object (comp_data->client,
icalcomponent_get_uid (comp_data->icalcomp), &error);
delete_error_dialog (error, E_CAL_COMPONENT_TODO);
g_clear_error (&error);
@@ -663,7 +663,7 @@ add_retract_data (ECalComponent *comp, const char *retract_comment)
icalcomponent_add_property (icalcomp, icalprop);
}
-static gboolean
+static gboolean
check_for_retract (ECalComponent *comp, ECal *client)
{
ECalComponentOrganizer org;
@@ -671,13 +671,13 @@ check_for_retract (ECalComponent *comp, ECal *client)
const char *strip = NULL;
gboolean ret_val = FALSE;
- if (!(e_cal_component_has_attendees (comp) &&
+ if (!(e_cal_component_has_attendees (comp) &&
e_cal_get_save_schedules (client)))
return ret_val;
e_cal_component_get_organizer (comp, &org);
strip = itip_strip_mailto (org.value);
-
+
if (e_cal_get_cal_address (client, &email, NULL) && !g_ascii_strcasecmp (email, strip)) {
ret_val = TRUE;
}
@@ -692,7 +692,7 @@ check_for_retract (ECalComponent *comp, ECal *client)
/**
* e_calendar_table_delete_selected:
* @cal_table: A calendar table.
- *
+ *
* Deletes the selected components in the table; asks the user first.
**/
void
@@ -725,7 +725,7 @@ e_calendar_table_delete_selected (ECalendarTable *cal_table)
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (comp_data->icalcomp));
}
-
+
if ((n_selected == 1) && comp && check_for_retract (comp, comp_data->client)) {
char *retract_comment = NULL;
gboolean retract = FALSE;
@@ -739,7 +739,7 @@ e_calendar_table_delete_selected (ECalendarTable *cal_table)
add_retract_data (comp, retract_comment);
icalcomp = e_cal_component_get_icalcomponent (comp);
icalcomponent_set_method (icalcomp, ICAL_METHOD_CANCEL);
- if (!e_cal_send_objects (comp_data->client, icalcomp, &users,
+ if (!e_cal_send_objects (comp_data->client, icalcomp, &users,
&mod_comp, &error)) {
delete_error_dialog (error, E_CAL_COMPONENT_TODO);
g_clear_error (&error);
@@ -770,10 +770,10 @@ e_calendar_table_delete_selected (ECalendarTable *cal_table)
/**
* e_calendar_table_get_selected:
- * @cal_table:
- *
+ * @cal_table:
+ *
* Get the currently selected ECalModelComponent's on the table.
- *
+ *
* Return value: A GSList of the components, which should be
* g_slist_free'd when finished with.
**/
@@ -860,7 +860,7 @@ e_calendar_table_copy_clipboard (ECalendarTable *cal_table)
ETable *etable;
GtkClipboard *clipboard;
char *comp_str;
-
+
g_return_if_fail (E_IS_CALENDAR_TABLE (cal_table));
/* create temporary VCALENDAR object */
@@ -877,7 +877,7 @@ e_calendar_table_copy_clipboard (ECalendarTable *cal_table)
} else {
gtk_clipboard_set_can_store (clipboard, target_types + 1, n_target_types - 1);
}
-
+
/* free memory */
icalcomponent_free (cal_table->tmp_vcal);
cal_table->tmp_vcal = NULL;
@@ -911,7 +911,7 @@ clipboard_get_calendar_data (ECalendarTable *cal_table, const gchar *text)
}
client = e_cal_model_get_default_client (cal_table->model);
-
+
e_calendar_table_set_status_message (cal_table, _("Updating objects"), -1);
if (kind == ICAL_VCALENDAR_COMPONENT) {
@@ -965,7 +965,7 @@ clipboard_paste_received_cb (GtkClipboard *clipboard,
GtkSelectionData *selection_data,
gpointer data)
{
- ECalendarTable *cal_table = E_CALENDAR_TABLE (data);
+ ECalendarTable *cal_table = E_CALENDAR_TABLE (data);
ETable *e_table = e_table_scrolled_get_table (E_TABLE_SCROLLED (cal_table->etable));
GnomeCanvas *canvas = e_table->table_canvas;
GnomeCanvasItem *item = GNOME_CANVAS (canvas)->focused_item;
@@ -1018,7 +1018,7 @@ e_calendar_table_open_task (ECalendarTable *cal_table, ECal *client, icalcompone
CompEditor *tedit;
const char *uid;
guint32 flags = 0;
-
+
uid = icalcomponent_get_uid (icalcomp);
tedit = e_comp_editor_registry_find (comp_editor_registry, uid);
@@ -1031,17 +1031,17 @@ e_calendar_table_open_task (ECalendarTable *cal_table, ECal *client, icalcompone
if (assign) {
flags |= COMP_EDITOR_IS_ASSIGNED;
- if (itip_organizer_is_user (comp, client) ||
+ if (itip_organizer_is_user (comp, client) ||
!e_cal_component_has_attendees (comp))
flags |= COMP_EDITOR_USER_ORG;
}
tedit = COMP_EDITOR (task_editor_new (client, flags));
comp_editor_edit_comp (tedit, comp);
-
+
if (flags & COMP_EDITOR_IS_ASSIGNED)
task_editor_show_assignment (TASK_EDITOR (tedit));
-
+
e_comp_editor_registry_add (comp_editor_registry, tedit, FALSE);
}
comp_editor_focus (tedit);
@@ -1061,7 +1061,7 @@ open_task_by_row (ECalendarTable *cal_table, int row)
static void
e_calendar_table_on_double_click (ETable *table,
- gint row,
+ gint row,
gint col,
GdkEvent *event,
ECalendarTable *cal_table)
@@ -1091,15 +1091,15 @@ e_calendar_table_on_save_as (EPopup *ep, EPopupItem *pitem, void *data)
ECalModelComponent *comp_data;
char *filename;
char *ical_string;
-
+
comp_data = e_calendar_table_get_selected_comp (cal_table);
if (comp_data == NULL)
return;
-
+
filename = e_file_dialog_save (_("Save as..."), NULL);
if (filename == NULL)
return;
-
+
ical_string = e_cal_get_component_as_string (comp_data->client, comp_data->icalcomp);
if (ical_string == NULL) {
g_warning ("Couldn't convert item to a string");
@@ -1107,7 +1107,7 @@ e_calendar_table_on_save_as (EPopup *ep, EPopupItem *pitem, void *data)
}
e_write_file_uri (filename, ical_string);
-
+
g_free (ical_string);
}
@@ -1121,7 +1121,7 @@ e_calendar_table_on_print_task (EPopup *ep, EPopupItem *pitem, void *data)
comp_data = e_calendar_table_get_selected_comp (cal_table);
if (comp_data == NULL)
return;
-
+
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (comp_data->icalcomp));
print_comp (comp, comp_data->client, GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG);
@@ -1306,7 +1306,7 @@ on_new_task (EPopup *ep, EPopupItem *pitem, void *data)
return;
e_tasks_new_task (tasks);
-
+
}
/* Callback for the "delete tasks" menu item */
@@ -1321,14 +1321,14 @@ delete_cb (EPopup *ep, EPopupItem *pitem, void *data)
static EPopupItem tasks_popup_items [] = {
{ E_POPUP_ITEM, "00.newtask", N_("New _Task"), on_new_task, NULL, "stock_task", 0, 0},
{ E_POPUP_BAR, "01.bar" },
-
+
{ E_POPUP_ITEM, "03.open", N_("_Open"), e_calendar_table_on_open_task, NULL, GTK_STOCK_OPEN, E_CAL_POPUP_SELECT_ONE },
{ E_POPUP_ITEM, "05.openweb", N_("Open _Web Page"), open_url_cb, NULL, NULL, E_CAL_POPUP_SELECT_ONE, E_CAL_POPUP_SELECT_HASURL },
{ E_POPUP_ITEM, "10.saveas", N_("_Save As..."), e_calendar_table_on_save_as, NULL, GTK_STOCK_SAVE_AS, E_CAL_POPUP_SELECT_ONE },
{ E_POPUP_ITEM, "20.print", N_("_Print..."), e_calendar_table_on_print_task, NULL, GTK_STOCK_PRINT, E_CAL_POPUP_SELECT_ONE },
{ E_POPUP_BAR, "30.bar" },
-
+
{ E_POPUP_ITEM, "40.cut", N_("C_ut"), e_calendar_table_on_cut, NULL, GTK_STOCK_CUT, 0, E_CAL_POPUP_SELECT_EDITABLE },
{ E_POPUP_ITEM, "50.copy", N_("_Copy"), e_calendar_table_on_copy, NULL, GTK_STOCK_COPY, 0, 0 },
{ E_POPUP_ITEM, "60.paste", N_("_Paste"), e_calendar_table_on_paste, NULL, GTK_STOCK_PASTE, 0, E_CAL_POPUP_SELECT_EDITABLE },
@@ -1432,7 +1432,7 @@ e_calendar_table_on_key_press (ETable *table,
} else if ((event->keyval == GDK_o)
&&(event->state & GDK_CONTROL_MASK)) {
open_task_by_row (cal_table, row);
- return TRUE;
+ return TRUE;
}
return FALSE;
@@ -1514,7 +1514,7 @@ show_completed_rows (ECalModel *model, GList *clients_list, char *show_sexp, GPt
g_ptr_array_add (comp_objects, comp_data);
e_table_model_row_inserted (E_TABLE_MODEL (model), comp_objects->len - 1);
- }
+ }
e_cal_component_free_id (id);
g_object_unref (comp);
}
@@ -1603,7 +1603,7 @@ e_calendar_table_set_status_message (ECalendarTable *cal_table, const gchar *mes
if (!cal_table->activity_handler)
return;
-
+
if (!message || !*message) {
if (cal_table->activity_id != 0) {
e_activity_handler_operation_finished (cal_table->activity_handler, cal_table->activity_id);
@@ -1611,7 +1611,7 @@ e_calendar_table_set_status_message (ECalendarTable *cal_table, const gchar *mes
}
} else if (cal_table->activity_id == 0) {
char *client_id = g_strdup_printf ("%p", cal_table);
-
+
if (progress_icon == NULL)
progress_icon = e_icon_factory_get_icon (EVOLUTION_TASKS_PROGRESS_IMAGE, E_ICON_SIZE_STATUS);
@@ -1620,9 +1620,9 @@ e_calendar_table_set_status_message (ECalendarTable *cal_table, const gchar *mes
g_free (client_id);
} else {
-
+
double progress;
-
+
if (percent < 0)
progress = -1.0;
else {
@@ -1653,7 +1653,7 @@ e_calendar_table_process_completed_tasks (ECalendarTable *table, GList *clients_
g_mutex_lock (mutex);
- model = e_calendar_table_get_model (table);
+ model = e_calendar_table_get_model (table);
comp_objects = e_cal_model_get_object_array (model);
hide_sexp = calendar_config_get_hide_completed_tasks_sexp (TRUE);
diff --git a/calendar/gui/e-calendar-table.h b/calendar/gui/e-calendar-table.h
index a769cf54dd..b9ebf872a2 100644
--- a/calendar/gui/e-calendar-table.h
+++ b/calendar/gui/e-calendar-table.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 2000, Ximian, Inc.
* Copyright 2000, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -108,7 +108,7 @@ void e_calendar_table_set_activity_handler (ECalendarTable *cal_table,
void e_calendar_table_set_status_message (ECalendarTable *cal_table,
const gchar *message,
int percent);
-void e_calendar_table_open_task (ECalendarTable *cal_table,
+void e_calendar_table_open_task (ECalendarTable *cal_table,
ECal *client,
icalcomponent *icalcomp,
gboolean assign);
diff --git a/calendar/gui/e-calendar-view.c b/calendar/gui/e-calendar-view.c
index 7f84d6e540..c4f4117bba 100644
--- a/calendar/gui/e-calendar-view.c
+++ b/calendar/gui/e-calendar-view.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Rodrigo Moya <rodrigo@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -124,7 +124,7 @@ e_calendar_view_set_property (GObject *object, guint property_id, const GValue *
ECalendarView *cal_view;
cal_view = E_CALENDAR_VIEW (object);
-
+
switch (property_id) {
case PROP_MODEL:
e_calendar_view_set_model (cal_view, E_CAL_MODEL (g_value_get_object (value)));
@@ -178,7 +178,7 @@ e_calendar_view_class_init (ECalendarViewClass *klass)
klass->update_query = NULL;
klass->open_event = e_calendar_view_open_event;
- g_object_class_install_property (gobject_class, PROP_MODEL,
+ g_object_class_install_property (gobject_class, PROP_MODEL,
g_param_spec_object ("model", NULL, NULL, E_TYPE_CAL_MODEL,
G_PARAM_READABLE | G_PARAM_WRITABLE));
@@ -260,15 +260,15 @@ e_calendar_view_class_init (ECalendarViewClass *klass)
gtk_binding_entry_add_signal (binding_set, GDK_o,
GDK_CONTROL_MASK,
"open_event", 0);
-
+
/* init the accessibility support for e_day_view */
e_cal_view_a11y_init ();
}
void
-e_calendar_view_add_event (ECalendarView *cal_view, ECal *client, time_t dtstart,
- icaltimezone *default_zone, icalcomponent *icalcomp, gboolean in_top_canvas)
+e_calendar_view_add_event (ECalendarView *cal_view, ECal *client, time_t dtstart,
+ icaltimezone *default_zone, icalcomponent *icalcomp, gboolean in_top_canvas)
{
ECalComponent *comp;
struct icaltimetype itime, old_dtstart, old_dtend;
@@ -305,7 +305,7 @@ e_calendar_view_add_event (ECalendarView *cal_view, ECal *client, time_t dtstart
case GNOME_CAL_WORK_WEEK_VIEW:
if (start_offset == 0 && end_offset == 0 && in_top_canvas)
all_day_event = TRUE;
-
+
if (all_day_event) {
ic_dur = ic_oneday;
} else if (icaldurationtype_as_int (ic_dur) >= 60*60*24
@@ -341,7 +341,7 @@ e_calendar_view_add_event (ECalendarView *cal_view, ECal *client, time_t dtstart
default:
g_return_if_reached ();
}
-
+
itime = icaltime_from_timet_with_zone (new_dtstart, FALSE, default_zone);
if (all_day_event)
@@ -554,7 +554,7 @@ void
e_calendar_view_set_activity_handler (ECalendarView *cal_view, EActivityHandler *activity_handler)
{
ECalendarViewPrivate *priv;
-
+
g_return_if_fail (E_IS_CALENDAR_VIEW (cal_view));
priv = cal_view->priv;
@@ -566,14 +566,14 @@ void
e_calendar_view_set_status_message (ECalendarView *cal_view, const gchar *message, int percent)
{
ECalendarViewPrivate *priv;
-
+
g_return_if_fail (E_IS_CALENDAR_VIEW (cal_view));
priv = cal_view->priv;
if (!priv->activity_handler)
return;
-
+
if (!message || !*message) {
if (priv->activity_id != 0) {
e_activity_handler_operation_finished (priv->activity_handler, priv->activity_id);
@@ -590,7 +590,7 @@ e_calendar_view_set_status_message (ECalendarView *cal_view, const gchar *messag
g_free (client_id);
} else {
double progress;
-
+
if (percent < 0)
progress = -1.0;
else {
@@ -678,7 +678,7 @@ e_calendar_view_cut_clipboard (ECalendarView *cal_view)
ECalComponent *comp;
ECalendarViewEvent *event = (ECalendarViewEvent *) l->data;
GError *error = NULL;
-
+
if (!event)
continue;
@@ -704,14 +704,14 @@ e_calendar_view_cut_clipboard (ECalendarView *cal_view)
&error);
icalcomponent_free (icalcomp);
} else
- e_cal_remove_object_with_mod (event->comp_data->client, uid, NULL,
+ e_cal_remove_object_with_mod (event->comp_data->client, uid, NULL,
CALOBJ_MOD_ALL, &error);
} else
e_cal_remove_object (event->comp_data->client, uid, &error);
delete_error_dialog (error, E_CAL_COMPONENT_EVENT);
g_clear_error (&error);
-
+
g_object_unref (comp);
}
@@ -819,11 +819,11 @@ clipboard_get_text_cb (GtkClipboard *clipboard, const gchar *text, ECalendarView
if (e_cal_util_component_has_recurrences (subcomp)) {
icalproperty *icalprop = icalcomponent_get_first_property (subcomp, ICAL_RRULE_PROPERTY);
- if (icalprop)
+ if (icalprop)
icalproperty_remove_parameter_by_name (icalprop, "X-EVOLUTION-ENDDATE");
}
-
- e_calendar_view_add_event (cal_view, client, selected_time_start,
+
+ e_calendar_view_add_event (cal_view, client, selected_time_start,
default_zone, subcomp, in_top_canvas);
} else if (child_kind == ICAL_VTIMEZONE_COMPONENT) {
icaltimezone *zone;
@@ -831,10 +831,10 @@ clipboard_get_text_cb (GtkClipboard *clipboard, const gchar *text, ECalendarView
zone = icaltimezone_new ();
icaltimezone_set_component (zone, subcomp);
e_cal_add_timezone (client, zone, NULL);
-
+
icaltimezone_free (zone, 1);
}
-
+
subcomp = icalcomponent_get_next_component (
icalcomp, ICAL_ANY_COMPONENT);
}
@@ -871,7 +871,7 @@ add_retract_data (ECalComponent *comp, const char *retract_comment, CalObjModTyp
icalproperty_set_x_name (icalprop, "X-EVOLUTION-RETRACT-COMMENT");
icalcomponent_add_property (icalcomp, icalprop);
- if (mod == CALOBJ_MOD_ALL)
+ if (mod == CALOBJ_MOD_ALL)
icalprop = icalproperty_new_x ("All");
else
icalprop = icalproperty_new_x ("This");
@@ -879,7 +879,7 @@ add_retract_data (ECalComponent *comp, const char *retract_comment, CalObjModTyp
icalcomponent_add_property (icalcomp, icalprop);
}
-static gboolean
+static gboolean
check_for_retract (ECalComponent *comp, ECal *client)
{
ECalComponentOrganizer org;
@@ -887,13 +887,13 @@ check_for_retract (ECalComponent *comp, ECal *client)
const char *strip = NULL;
gboolean ret_val = FALSE;
- if (!(e_cal_component_has_attendees (comp) &&
+ if (!(e_cal_component_has_attendees (comp) &&
e_cal_get_save_schedules (client)))
return ret_val;
e_cal_component_get_organizer (comp, &org);
strip = itip_strip_mailto (org.value);
-
+
if (e_cal_get_cal_address (client, &email, NULL) && !g_ascii_strcasecmp (email, strip)) {
ret_val = TRUE;
}
@@ -916,8 +916,8 @@ delete_event (ECalendarView *cal_view, ECalendarViewEvent *event)
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (event->comp_data->icalcomp));
vtype = e_cal_component_get_vtype (comp);
-
- /*FIXME remove it once the we dont set the recurrence id for all the generated instances */
+
+ /*FIXME remove it once the we dont set the recurrence id for all the generated instances */
if (!e_cal_get_static_capability (event->comp_data->client, CAL_STATIC_CAPABILITY_RECURRENCES_NO_MASTER))
e_cal_component_set_recurid (comp, NULL);
@@ -933,7 +933,7 @@ delete_event (ECalendarView *cal_view, ECalendarViewEvent *event)
add_retract_data (comp, retract_comment, CALOBJ_MOD_ALL);
icalcomp = e_cal_component_get_icalcomponent (comp);
icalcomponent_set_method (icalcomp, ICAL_METHOD_CANCEL);
- if (!e_cal_send_objects (event->comp_data->client, icalcomp, &users,
+ if (!e_cal_send_objects (event->comp_data->client, icalcomp, &users,
&mod_comp, &error)) {
delete_error_dialog (error, E_CAL_COMPONENT_EVENT);
g_clear_error (&error);
@@ -949,12 +949,12 @@ delete_event (ECalendarView *cal_view, ECalendarViewEvent *event)
}
}
}
- } else
+ } else
delete = delete_component_dialog (comp, FALSE, 1, vtype, GTK_WIDGET (cal_view));
if (delete) {
const char *uid;
-
+
if ((itip_organizer_is_user (comp, event->comp_data->client) || itip_sentby_is_user (comp))
&& cancel_component_dialog ((GtkWindow *) gtk_widget_get_toplevel (GTK_WIDGET (cal_view)),
event->comp_data->client,
@@ -967,9 +967,9 @@ delete_event (ECalendarView *cal_view, ECalendarViewEvent *event)
g_object_unref (comp);
return;
}
-
+
if (e_cal_util_component_is_instance (event->comp_data->icalcomp) || e_cal_util_component_has_recurrences (event->comp_data->icalcomp))
- e_cal_remove_object_with_mod (event->comp_data->client, uid,
+ e_cal_remove_object_with_mod (event->comp_data->client, uid,
e_cal_component_get_recurid_as_string (comp), CALOBJ_MOD_ALL, &error);
else
e_cal_remove_object (event->comp_data->client, uid, &error);
@@ -1026,7 +1026,7 @@ e_calendar_view_delete_selected_occurrence (ECalendarView *cal_view)
ECalComponentVType vtype;
gboolean delete = FALSE;
GError *error = NULL;
-
+
selected = e_calendar_view_get_selected_events (cal_view);
if (!selected)
return;
@@ -1047,7 +1047,7 @@ e_calendar_view_delete_selected_occurrence (ECalendarView *cal_view)
add_retract_data (comp, retract_comment, CALOBJ_MOD_THIS);
icalcomp = e_cal_component_get_icalcomponent (comp);
icalcomponent_set_method (icalcomp, ICAL_METHOD_CANCEL);
- if (!e_cal_send_objects (event->comp_data->client, icalcomp, &users,
+ if (!e_cal_send_objects (event->comp_data->client, icalcomp, &users,
&mod_comp, &error)) {
delete_error_dialog (error, E_CAL_COMPONENT_EVENT);
g_clear_error (&error);
@@ -1061,7 +1061,7 @@ e_calendar_view_delete_selected_occurrence (ECalendarView *cal_view)
}
}
}
- } else
+ } else
delete = delete_component_dialog (comp, FALSE, 1, vtype, GTK_WIDGET (cal_view));
if (delete) {
@@ -1079,14 +1079,14 @@ e_calendar_view_delete_selected_occurrence (ECalendarView *cal_view)
e_cal_get_timezone (event->comp_data->client, dt.tzid, &zone, &error);
if (error) {
- zone = e_calendar_view_get_timezone (cal_view);
+ zone = e_calendar_view_get_timezone (cal_view);
g_clear_error(&error);
}
- } else
+ } else
zone = e_calendar_view_get_timezone (cal_view);
- if (is_instance)
+ if (is_instance)
rid = e_cal_component_get_recurid_as_string (comp);
e_cal_component_free_datetime (&dt);
@@ -1115,13 +1115,13 @@ e_calendar_view_delete_selected_occurrence (ECalendarView *cal_view)
else {
struct icaltimetype instance_rid;
- instance_rid = icaltime_from_timet_with_zone (event->comp_data->instance_start,
+ instance_rid = icaltime_from_timet_with_zone (event->comp_data->instance_start,
TRUE, zone ? zone : icaltimezone_get_utc_timezone ());
e_cal_util_remove_instances (event->comp_data->icalcomp, instance_rid, CALOBJ_MOD_THIS);
e_cal_modify_object (event->comp_data->client, event->comp_data->icalcomp, CALOBJ_MOD_THIS,
&error);
}
-
+
delete_error_dialog (error, E_CAL_COMPONENT_EVENT);
g_clear_error (&error);
}
@@ -1193,7 +1193,7 @@ on_edit_appointment (EPopup *ep, EPopupItem *pitem, void *data)
if (event)
e_calendar_view_edit_appointment (cal_view, event->comp_data->client,
- event->comp_data->icalcomp,
+ event->comp_data->icalcomp,
icalcomponent_get_first_property(event->comp_data->icalcomp, ICAL_ATTENDEE_PROPERTY) != NULL);
g_list_free (selected);
@@ -1216,7 +1216,7 @@ on_save_as (EPopup *ep, EPopupItem *pitem, void *data)
char *filename;
char *ical_string;
ECalendarViewEvent *event;
-
+
selected = e_calendar_view_get_selected_events (cal_view);
if (!selected)
return;
@@ -1224,7 +1224,7 @@ on_save_as (EPopup *ep, EPopupItem *pitem, void *data)
filename = e_file_dialog_save (_("Save as..."), NULL);
if (filename == NULL)
return;
-
+
event = (ECalendarViewEvent *) selected->data;
ical_string = e_cal_get_component_as_string (event->comp_data->client, event->comp_data->icalcomp);
if (ical_string == NULL) {
@@ -1267,19 +1267,19 @@ transfer_item_to (ECalendarViewEvent *event, ECal *dest_client, gboolean remove_
char *new_uid;
icalcomponent *orig_icalcomp;
icalproperty *icalprop;
-
+
uid = icalcomponent_get_uid (event->comp_data->icalcomp);
/* put the new object into the destination calendar */
if (e_cal_get_object (dest_client, uid, NULL, &orig_icalcomp, NULL)) {
icalcomponent_free (orig_icalcomp);
-
-
- if (!e_cal_modify_object (dest_client, event->comp_data->icalcomp, CALOBJ_MOD_ALL, NULL))
+
+
+ if (!e_cal_modify_object (dest_client, event->comp_data->icalcomp, CALOBJ_MOD_ALL, NULL))
return;
} else {
orig_icalcomp = icalcomponent_new_clone (event->comp_data->icalcomp);
-
+
icalprop = icalproperty_new_x ("1");
icalproperty_set_x_name (icalprop, "X-EVOLUTION-MOVE-CALENDAR");
icalcomponent_add_property (orig_icalcomp, icalprop);
@@ -1306,7 +1306,7 @@ transfer_item_to (ECalendarViewEvent *event, ECal *dest_client, gboolean remove_
/* remove the item from the source calendar */
if (remove_item) {
if (e_cal_util_component_is_instance (event->comp_data->icalcomp) || e_cal_util_component_is_instance (event->comp_data->icalcomp))
- e_cal_remove_object_with_mod (event->comp_data->client, uid,
+ e_cal_remove_object_with_mod (event->comp_data->client, uid,
NULL, CALOBJ_MOD_ALL, NULL);
else
e_cal_remove_object (event->comp_data->client, uid, NULL);
@@ -1389,7 +1389,7 @@ on_meeting (EPopup *ep, EPopupItem *pitem, void *data)
static void
set_attendee_status_for_delegate (icalcomponent *icalcomp, ECal *client)
{
- icalproperty *prop;
+ icalproperty *prop;
icalparameter *param;
char *address = NULL;
ECalComponent *comp;
@@ -1397,9 +1397,9 @@ set_attendee_status_for_delegate (icalcomponent *icalcomp, ECal *client)
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (icalcomp));
-
- address = itip_get_comp_attendee (comp, client);
-
+
+ address = itip_get_comp_attendee (comp, client);
+
for (prop = icalcomponent_get_first_property (icalcomp, ICAL_ATTENDEE_PROPERTY);
prop;
@@ -1412,17 +1412,17 @@ set_attendee_status_for_delegate (icalcomponent *icalcomp, ECal *client)
param = icalparameter_new_partstat (ICAL_PARTSTAT_DELEGATED);
icalproperty_set_parameter (prop, param);
-
+
found = TRUE;
break;
- }
+ }
}
/* We couldn find the attendee in the component, so add a new attendee */
if (!found) {
char *temp = g_strdup_printf ("MAILTO:%s", address);
-
+
prop = icalproperty_new_attendee ((const char *) temp);
icalcomponent_add_property (icalcomp, prop);
@@ -1457,7 +1457,7 @@ on_delegate (EPopup *ep, EPopupItem *pitem, void *data)
selected = e_calendar_view_get_selected_events (cal_view);
if (selected) {
ECalendarViewEvent *event = (ECalendarViewEvent *) selected->data;
-
+
clone = icalcomponent_new_clone (event->comp_data->icalcomp);
set_attendee_status_for_delegate (clone, event->comp_data->client);
@@ -1552,7 +1552,7 @@ on_unrecur_appointment (EPopup *ep, EPopupItem *pitem, void *data)
ECal *client;
char *new_uid;
ECalComponentId *id = NULL;
-
+
selected = e_calendar_view_get_selected_events (cal_view);
if (!selected)
return;
@@ -1570,13 +1570,13 @@ on_unrecur_appointment (EPopup *ep, EPopupItem *pitem, void *data)
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (event->comp_data->icalcomp));
id = e_cal_component_get_id (comp);
-
+
/* For the unrecurred instance we duplicate the original object,
create a new uid for it, get rid of the recurrence rules, and set
the start & end times to the instances times. */
new_comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (new_comp, icalcomponent_new_clone (event->comp_data->icalcomp));
-
+
new_uid = e_cal_component_gen_uid ();
e_cal_component_set_uid (new_comp, new_uid);
g_free (new_uid);
@@ -1600,7 +1600,7 @@ on_unrecur_appointment (EPopup *ep, EPopupItem *pitem, void *data)
/* Now update both ECalComponents. Note that we do this last since at
* present the updates happen synchronously so our event may disappear.
*/
-
+
if (!e_cal_remove_object_with_mod (client, id->uid, id->rid, CALOBJ_MOD_THIS,
NULL))
g_message ("on_unrecur_appointment(): Could not remove the old object!");
@@ -1665,7 +1665,7 @@ static EPopupItem ecv_main_items [] = {
{ E_POPUP_BAR, "60." },
/* FIXME: hook in this somehow */
{ E_POPUP_SUBMENU, "60.view", N_("_Current View") },
-
+
{ E_POPUP_ITEM, "61.today", N_("Select T_oday"), on_goto_today, NULL, "go-today" },
{ E_POPUP_ITEM, "62.todate", N_("_Select Date..."), on_goto_date, NULL, GTK_STOCK_JUMP_TO },
};
@@ -1762,7 +1762,7 @@ e_calendar_view_create_popup_menu (ECalendarView *cal_view)
return e_popup_create_menu_once((EPopup *)ep, (EPopupTarget *)t, 0);
}
-void
+void
e_calendar_view_open_event (ECalendarView *cal_view)
{
GList *selected;
@@ -1815,18 +1815,18 @@ e_calendar_view_new_appointment_for (ECalendarView *cal_view,
g_warning ("Default client not loaded \n");
return;
}
-
+
if (e_cal_is_read_only (default_client, &readonly, NULL) && readonly) {
GtkWidget *widget;
-
+
widget = e_error_new (NULL, "calendar:prompt-read-only-cal", NULL);
-
- g_signal_connect ((GtkDialog *)widget, "response", G_CALLBACK (gtk_widget_destroy),
+
+ g_signal_connect ((GtkDialog *)widget, "response", G_CALLBACK (gtk_widget_destroy),
widget);
gtk_widget_show (widget);
return;
}
-
+
dt.value = &itt;
if (all_day)
dt.tzid = NULL;
@@ -1873,7 +1873,7 @@ e_calendar_view_new_appointment_for (ECalendarView *cal_view,
flags |= COMP_EDITOR_MEETING;
flags |= COMP_EDITOR_USER_ORG;
}
-
+
open_event_with_flags (cal_view, default_client,
icalcomp, flags);
@@ -2011,7 +2011,7 @@ e_calendar_view_edit_appointment (ECalendarView *cal_view,
gboolean meeting)
{
guint32 flags = 0;
-
+
g_return_if_fail (E_IS_CALENDAR_VIEW (cal_view));
g_return_if_fail (E_IS_CAL (client));
g_return_if_fail (icalcomp != NULL);
@@ -2025,7 +2025,7 @@ e_calendar_view_edit_appointment (ECalendarView *cal_view,
g_object_unref (comp);
}
-
+
open_event_with_flags (cal_view, client, icalcomp, flags);
}
@@ -2056,7 +2056,7 @@ tooltip_grab (GtkWidget *tooltip, GdkEventKey *event, ECalendarView *view)
gdk_keyboard_ungrab(GDK_CURRENT_TIME);
gtk_widget_destroy (widget);
g_object_set_data (G_OBJECT (view), "tooltip-window", NULL);
-
+
return FALSE;
}
@@ -2075,7 +2075,7 @@ get_label (struct icaltimetype *tt, icaltimezone *f_zone, icaltimezone *t_zone)
return g_strdup (buffer);
}
-void
+void
e_calendar_view_move_tip (GtkWidget *widget, int x, int y)
{
GtkRequisition requisition;
@@ -2083,7 +2083,7 @@ e_calendar_view_move_tip (GtkWidget *widget, int x, int y)
GdkScreen *screen;
GdkScreen *pointer_screen;
gint monitor_num, px, py;
- GdkRectangle monitor;
+ GdkRectangle monitor;
screen = gtk_widget_get_screen (widget);
@@ -2093,7 +2093,7 @@ e_calendar_view_move_tip (GtkWidget *widget, int x, int y)
gdk_display_get_pointer (gdk_screen_get_display (screen),
&pointer_screen, &px, &py, NULL);
- if (pointer_screen != screen)
+ if (pointer_screen != screen)
{
px = x;
py = y;
@@ -2110,10 +2110,10 @@ e_calendar_view_move_tip (GtkWidget *widget, int x, int y)
y = y - h - 36;
gtk_window_move (GTK_WINDOW (widget), x, y);
- gtk_widget_show (widget);
+ gtk_widget_show (widget);
}
-/*
+/*
* It is expected to show the tooltips in this below format
*
* <B>SUBJECT OF THE MEETING</B>
@@ -2128,7 +2128,7 @@ e_calendar_view_get_tooltips (ECalendarViewEventData *data)
GtkWidget *label, *box, *hbox, *ebox, *frame;
const char *str;
char *tmp, *tmp1, *tmp2;
- ECalComponentOrganizer organiser;
+ ECalComponentOrganizer organiser;
ECalComponentDateTime dtstart, dtend;
icalcomponent *clone_comp;
time_t t_start, t_end;
@@ -2136,7 +2136,7 @@ e_calendar_view_get_tooltips (ECalendarViewEventData *data)
GtkStyle *style = gtk_widget_get_default_style ();
GtkWidget *widget = (GtkWidget *) g_object_get_data (G_OBJECT (data->cal_view), "tooltip-window");
ECalComponent *newcomp = e_cal_component_new ();
- icaltimezone *zone, *default_zone;
+ icaltimezone *zone, *default_zone;
ECal *client = NULL;
gboolean free_text = FALSE;
@@ -2181,21 +2181,21 @@ e_calendar_view_get_tooltips (ECalendarViewEventData *data)
gtk_container_add ((GtkContainer *)ebox, hbox);
gtk_widget_modify_bg (ebox, GTK_STATE_NORMAL, &(style->bg[GTK_STATE_SELECTED]));
gtk_widget_modify_fg (label, GTK_STATE_NORMAL, &(style->text[GTK_STATE_SELECTED]));
-
+
gtk_box_pack_start ((GtkBox *)box, ebox, FALSE, FALSE, 0);
g_free (tmp);
-
+
e_cal_component_get_organizer (newcomp, &organiser);
if (organiser.cn) {
- char *ptr ;
+ char *ptr ;
ptr = strchr(organiser.value, ':');
-
+
if (ptr) {
ptr++;
/* To Translators: It will display "Organiser: NameOfTheUser <email@ofuser.com>" */
tmp = g_strdup_printf (_("Organizer: %s <%s>"), organiser.cn, ptr);
}
- else
+ else
/* With SunOne accouts, there may be no ':' in organiser.value*/
tmp = g_strdup_printf (_("Organizer: %s"), organiser.cn);
@@ -2208,7 +2208,7 @@ e_calendar_view_get_tooltips (ECalendarViewEventData *data)
g_free (tmp);
}
-
+
e_cal_component_get_location (newcomp, &str);
if (str) {
@@ -2225,24 +2225,24 @@ e_calendar_view_get_tooltips (ECalendarViewEventData *data)
}
e_cal_component_get_dtstart (newcomp, &dtstart);
e_cal_component_get_dtend (newcomp, &dtend);
-
+
if (dtstart.tzid) {
zone = icalcomponent_get_timezone (e_cal_component_get_icalcomponent (newcomp), dtstart.tzid);
- if (!zone)
+ if (!zone)
e_cal_get_timezone (client, dtstart.tzid, &zone, NULL);
if (!zone)
zone = default_zone;
-
+
} else {
zone = NULL;
}
t_start = icaltime_as_timet_with_zone (*dtstart.value, zone);
t_end = icaltime_as_timet_with_zone (*dtend.value, zone);
-
+
tmp1 = get_label(dtstart.value, zone, default_zone);
tmp = calculate_time (t_start, t_end);
-
+
/* To Translators: It will display "Time: ActualStartDateAndTime (DurationOfTheMeeting)"*/
tmp2 = g_strdup_printf(_("Time: %s %s"), tmp1, tmp);
hbox = gtk_hbox_new (FALSE, 0);
@@ -2250,7 +2250,7 @@ e_calendar_view_get_tooltips (ECalendarViewEventData *data)
ebox = gtk_event_box_new ();
gtk_container_add ((GtkContainer *)ebox, hbox);
gtk_box_pack_start ((GtkBox *)box, ebox, FALSE, FALSE, 0);
-
+
g_free (tmp);
g_free (tmp2);
g_free (tmp1);
@@ -2258,12 +2258,12 @@ e_calendar_view_get_tooltips (ECalendarViewEventData *data)
pevent->tooltip = gtk_window_new (GTK_WINDOW_POPUP);
frame = gtk_frame_new (NULL);
gtk_frame_set_shadow_type ((GtkFrame *)frame, GTK_SHADOW_IN);
-
+
gtk_window_move ((GtkWindow *)pevent->tooltip, pevent->x +16, pevent->y+16);
gtk_container_add ((GtkContainer *)frame, box);
gtk_container_add ((GtkContainer *)pevent->tooltip, frame);
-
- gtk_widget_show_all (pevent->tooltip);
+
+ gtk_widget_show_all (pevent->tooltip);
e_calendar_view_move_tip (pevent->tooltip, pevent->x +16, pevent->y+16);
@@ -2320,7 +2320,7 @@ e_calendar_view_get_icalcomponent_summary (ECal *ecal, icalcomponent *icalcomp,
struct icaltimetype dtstart, dtnow;
icalcomponent *item_icalcomp = NULL;
- if (e_cal_get_object (ecal,
+ if (e_cal_get_object (ecal,
icalcomponent_get_uid (icalcomp),
icalcomponent_get_relcalid (icalcomp),
&item_icalcomp,
@@ -2345,8 +2345,8 @@ draw_curved_rectangle (cairo_t *cr, double x0, double y0,
double radius)
{
double x1, y1;
-
- x1 = x0 + rect_width;
+
+ x1 = x0 + rect_width;
y1 = y0 + rect_height;
if (!rect_width || !rect_height)
diff --git a/calendar/gui/e-calendar-view.h b/calendar/gui/e-calendar-view.h
index eb887b1ce5..f25366d392 100644
--- a/calendar/gui/e-calendar-view.h
+++ b/calendar/gui/e-calendar-view.h
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Rodrigo Moya <rodrigo@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -56,7 +56,7 @@ typedef enum {
E_CAL_VIEW_MOVE_LEFT,
E_CAL_VIEW_MOVE_RIGHT,
E_CAL_VIEW_MOVE_PAGE_UP,
- E_CAL_VIEW_MOVE_PAGE_DOWN
+ E_CAL_VIEW_MOVE_PAGE_DOWN
} ECalViewMoveDirection;
#define E_CALENDAR_VIEW_EVENT_FIELDS \
@@ -70,12 +70,12 @@ typedef enum {
GtkWidget *tooltip; \
gint timeout; \
GdkColor *color; \
- gint x,y;
+ gint x,y;
typedef struct {
E_CALENDAR_VIEW_EVENT_FIELDS
} ECalendarViewEvent;
-
+
typedef struct _ECalendarView ECalendarView;
typedef struct _ECalendarViewClass ECalendarViewClass;
typedef struct _ECalendarViewPrivate ECalendarViewPrivate;
@@ -143,7 +143,7 @@ void e_calendar_view_delete_selected_occurrence (ECalendarView *cal_vi
GtkMenu *e_calendar_view_create_popup_menu (ECalendarView *cal_view);
-void e_calendar_view_add_event (ECalendarView *cal_view, ECal *client, time_t dtstart,
+void e_calendar_view_add_event (ECalendarView *cal_view, ECal *client, time_t dtstart,
icaltimezone *default_zone, icalcomponent *icalcomp, gboolean in_top_canvas);
void e_calendar_view_new_appointment_for (ECalendarView *cal_view,
time_t dtstart,
diff --git a/calendar/gui/e-cell-date-edit-config.c b/calendar/gui/e-cell-date-edit-config.c
index f894da0e2b..ddccce408e 100644
--- a/calendar/gui/e-cell-date-edit-config.c
+++ b/calendar/gui/e-cell-date-edit-config.c
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -28,7 +28,7 @@ struct _ECellDateEditConfigPrivate {
ECellDateEdit *cell;
EMiniCalendarConfig *mini_config;
-
+
GList *notifications;
};
@@ -46,7 +46,7 @@ e_cell_date_edit_config_set_property (GObject *object, guint property_id, const
ECellDateEditConfig *view_config;
view_config = E_CELL_DATE_EDIT_CONFIG (object);
-
+
switch (property_id) {
case PROP_CELL:
e_cell_date_edit_config_set_cell (view_config, g_value_get_object (value));
@@ -63,7 +63,7 @@ e_cell_date_edit_config_get_property (GObject *object, guint property_id, GValue
ECellDateEditConfig *view_config;
view_config = E_CELL_DATE_EDIT_CONFIG (object);
-
+
switch (property_id) {
case PROP_CELL:
g_value_set_object (value, e_cell_date_edit_config_get_cell (view_config));
@@ -78,9 +78,9 @@ static void
e_cell_date_edit_config_dispose (GObject *object)
{
ECellDateEditConfig *view_config = E_CELL_DATE_EDIT_CONFIG (object);
-
+
e_cell_date_edit_config_set_cell (view_config, NULL);
-
+
if (G_OBJECT_CLASS (e_cell_date_edit_config_parent_class)->dispose)
G_OBJECT_CLASS (e_cell_date_edit_config_parent_class)->dispose (object);
}
@@ -90,11 +90,11 @@ e_cell_date_edit_config_finalize (GObject *object)
{
ECellDateEditConfig *view_config = E_CELL_DATE_EDIT_CONFIG (object);
ECellDateEditConfigPrivate *priv;
-
+
priv = view_config->priv;
g_free (priv);
-
+
if (G_OBJECT_CLASS (e_cell_date_edit_config_parent_class)->finalize)
G_OBJECT_CLASS (e_cell_date_edit_config_parent_class)->finalize (object);
}
@@ -104,7 +104,7 @@ e_cell_date_edit_config_class_init (ECellDateEditConfigClass *klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
GParamSpec *spec;
-
+
/* Method override */
gobject_class->set_property = e_cell_date_edit_config_set_property;
gobject_class->get_property = e_cell_date_edit_config_get_property;
@@ -127,14 +127,14 @@ ECellDateEditConfig *
e_cell_date_edit_config_new (ECellDateEdit *cell)
{
ECellDateEditConfig *view_config;
-
+
view_config = g_object_new (e_cell_date_edit_config_get_type (), "cell", cell, NULL);
return view_config;
}
ECellDateEdit *
-e_cell_date_edit_config_get_cell (ECellDateEditConfig *view_config)
+e_cell_date_edit_config_get_cell (ECellDateEditConfig *view_config)
{
ECellDateEditConfigPrivate *priv;
@@ -142,17 +142,17 @@ e_cell_date_edit_config_get_cell (ECellDateEditConfig *view_config)
g_return_val_if_fail (E_IS_CELL_DATE_EDIT_CONFIG (view_config), NULL);
priv = view_config->priv;
-
+
return priv->cell;
}
static void
-set_timezone (ECellDateEdit *cell)
+set_timezone (ECellDateEdit *cell)
{
ECellDateEditText *cell_text;
ECellPopup *cell_popup;
icaltimezone *zone;
-
+
zone = calendar_config_get_icaltimezone ();
cell_popup = E_CELL_POPUP (cell);
@@ -165,14 +165,14 @@ timezone_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer
{
ECellDateEditConfig *view_config = data;
ECellDateEditConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_timezone (priv->cell);
}
static void
-set_twentyfour_hour (ECellDateEdit *cell)
+set_twentyfour_hour (ECellDateEdit *cell)
{
ECellDateEditText *cell_text;
ECellPopup *cell_popup;
@@ -196,14 +196,14 @@ twentyfour_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gp
{
ECellDateEditConfig *view_config = data;
ECellDateEditConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_twentyfour_hour (priv->cell);
}
static void
-set_range (ECellDateEdit *cell)
+set_range (ECellDateEdit *cell)
{
int start_hour, end_hour;
@@ -219,7 +219,7 @@ set_range (ECellDateEdit *cell)
start_hour = end_hour;
/* We use the default 0 - 24 now. */
-#if 0
+#if 0
g_object_set (G_OBJECT (cell),
"lower_hour", start_hour,
"upper_hour", end_hour,
@@ -232,9 +232,9 @@ day_start_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpo
{
ECellDateEditConfig *view_config = data;
ECellDateEditConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_range (priv->cell);
}
@@ -243,9 +243,9 @@ day_end_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpoin
{
ECellDateEditConfig *view_config = data;
ECellDateEditConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_range (priv->cell);
}
@@ -254,24 +254,24 @@ day_end_minute_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpo
{
ECellDateEditConfig *view_config = data;
ECellDateEditConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_range (priv->cell);
}
void
-e_cell_date_edit_config_set_cell (ECellDateEditConfig *view_config, ECellDateEdit *cell)
+e_cell_date_edit_config_set_cell (ECellDateEditConfig *view_config, ECellDateEdit *cell)
{
ECellDateEditConfigPrivate *priv;
guint not;
GList *l;
-
+
g_return_if_fail (view_config != NULL);
g_return_if_fail (E_IS_CELL_DATE_EDIT_CONFIG (view_config));
priv = view_config->priv;
-
+
if (priv->cell) {
g_object_unref (priv->cell);
priv->cell = NULL;
@@ -281,7 +281,7 @@ e_cell_date_edit_config_set_cell (ECellDateEditConfig *view_config, ECellDateEdi
g_object_unref (priv->mini_config);
priv->mini_config = NULL;
}
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
@@ -291,17 +291,17 @@ e_cell_date_edit_config_set_cell (ECellDateEditConfig *view_config, ECellDateEdi
/* If the new view is NULL, return right now */
if (!cell)
return;
-
+
priv->cell = g_object_ref (cell);
/* Time zone */
set_timezone (cell);
-
+
not = calendar_config_add_notification_timezone (timezone_changed_cb, view_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* 24 Hour format */
- set_twentyfour_hour (cell);
+ set_twentyfour_hour (cell);
not = calendar_config_add_notification_24_hour_format (twentyfour_hour_changed_cb, view_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
@@ -317,5 +317,5 @@ e_cell_date_edit_config_set_cell (ECellDateEditConfig *view_config, ECellDateEdi
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* The mini calendar */
- priv->mini_config = e_mini_calendar_config_new (E_CALENDAR (cell->calendar));
+ priv->mini_config = e_mini_calendar_config_new (E_CALENDAR (cell->calendar));
}
diff --git a/calendar/gui/e-cell-date-edit-config.h b/calendar/gui/e-cell-date-edit-config.h
index 1391650396..c42260b956 100644
--- a/calendar/gui/e-cell-date-edit-config.h
+++ b/calendar/gui/e-cell-date-edit-config.h
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -31,7 +31,7 @@ G_BEGIN_DECLS
#define E_CELL_DATE_EDIT_CONFIG(obj) GTK_CHECK_CAST (obj, e_cell_date_edit_config_get_type (), ECellDateEditConfig)
#define E_CELL_DATE_EDIT_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_cell_date_edit_config_get_type (), ECellDateEditConfigClass)
#define E_IS_CELL_DATE_EDIT_CONFIG(obj) GTK_CHECK_TYPE (obj, e_cell_date_edit_config_get_type ())
-
+
typedef struct _ECellDateEditConfig ECellDateEditConfig;
typedef struct _ECellDateEditConfigClass ECellDateEditConfigClass;
typedef struct _ECellDateEditConfigPrivate ECellDateEditConfigPrivate;
diff --git a/calendar/gui/e-cell-date-edit-text.c b/calendar/gui/e-cell-date-edit-text.c
index b69b5915c2..9aedf58c42 100644
--- a/calendar/gui/e-cell-date-edit-text.c
+++ b/calendar/gui/e-cell-date-edit-text.c
@@ -35,7 +35,7 @@
#include <unistd.h>
#include <string.h>
#include <libgnomeui/gnome-messagebox.h>
-#include <libgnomeui/gnome-stock-icons.h>
+#include <libgnomeui/gnome-stock-icons.h>
#include <glib/gi18n.h>
#include <libedataserver/e-time-utils.h>
#include <libedataserver/e-data-server-util.h>
@@ -219,7 +219,7 @@ e_cell_date_edit_text_new (const char *fontname,
ECellDateEditText *ecd = g_object_new (e_cell_date_edit_text_get_type (), NULL);
e_cell_text_construct (E_CELL_TEXT (ecd), fontname, justify);
-
+
return (ECell *) ecd;
}
diff --git a/calendar/gui/e-comp-editor-registry.c b/calendar/gui/e-comp-editor-registry.c
index 19438d0301..609f254243 100644
--- a/calendar/gui/e-comp-editor-registry.c
+++ b/calendar/gui/e-comp-editor-registry.c
@@ -64,7 +64,7 @@ e_comp_editor_registry_dispose (GObject *obj)
reg = E_COMP_EDITOR_REGISTRY (obj);
priv = reg->priv;
-
+
if (priv->editors) {
g_hash_table_destroy (priv->editors);
priv->editors = NULL;
@@ -122,14 +122,14 @@ e_comp_editor_registry_add (ECompEditorRegistry *reg, CompEditor *editor, gboole
ECompEditorRegistryData *rdata;
ECalComponent *comp;
const char *uid;
-
+
g_return_if_fail (reg != NULL);
g_return_if_fail (E_IS_COMP_EDITOR_REGISTRY (reg));
g_return_if_fail (editor != NULL);
g_return_if_fail (IS_COMP_EDITOR (editor));
priv = reg->priv;
-
+
comp = comp_editor_get_comp (editor);
e_cal_component_get_uid (comp, &uid);
@@ -150,7 +150,7 @@ e_comp_editor_registry_find (ECompEditorRegistry *reg, const char *uid)
{
ECompEditorRegistryPrivate *priv;
ECompEditorRegistryData *rdata;
-
+
g_return_val_if_fail (reg != NULL, NULL);
g_return_val_if_fail (E_IS_COMP_EDITOR_REGISTRY (reg), NULL);
g_return_val_if_fail (uid != NULL, NULL);
@@ -160,7 +160,7 @@ e_comp_editor_registry_find (ECompEditorRegistry *reg, const char *uid)
rdata = g_hash_table_lookup (priv->editors, uid);
if (rdata != NULL)
return rdata->editor;
-
+
return NULL;
}
@@ -172,16 +172,16 @@ foreach_close_cb (gpointer key, gpointer value, gpointer data)
rdata = value;
g_signal_handlers_block_matched (rdata->editor, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, data);
-
+
comp_editor_focus (rdata->editor);
if (!comp_editor_close (rdata->editor)) {
g_signal_handlers_unblock_matched (rdata->editor, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, data);
return FALSE;
}
-
+
g_free (rdata->uid);
g_free (rdata);
-
+
return TRUE;
}
@@ -189,7 +189,7 @@ gboolean
e_comp_editor_registry_close_all (ECompEditorRegistry *reg)
{
ECompEditorRegistryPrivate *priv;
-
+
g_return_val_if_fail (reg != NULL, FALSE);
g_return_val_if_fail (E_IS_COMP_EDITOR_REGISTRY (reg), FALSE);
@@ -198,12 +198,12 @@ e_comp_editor_registry_close_all (ECompEditorRegistry *reg)
g_hash_table_foreach_remove (priv->editors, foreach_close_cb, reg);
if (g_hash_table_size (priv->editors) != 0)
return FALSE;
-
+
return TRUE;
}
static void
-editor_destroy_cb (gpointer data, GObject *where_object_was)
+editor_destroy_cb (gpointer data, GObject *where_object_was)
{
ECompEditorRegistryData *rdata = data;
diff --git a/calendar/gui/e-date-edit-config.c b/calendar/gui/e-date-edit-config.c
index f3c9895fe7..bc3752f3ca 100644
--- a/calendar/gui/e-date-edit-config.c
+++ b/calendar/gui/e-date-edit-config.c
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -43,7 +43,7 @@ e_date_edit_config_set_property (GObject *object, guint property_id, const GValu
EDateEditConfig *edit_config;
edit_config = E_DATE_EDIT_CONFIG (object);
-
+
switch (property_id) {
case PROP_EDIT:
e_date_edit_config_set_edit (edit_config, g_value_get_object (value));
@@ -60,7 +60,7 @@ e_date_edit_config_get_property (GObject *object, guint property_id, GValue *val
EDateEditConfig *edit_config;
edit_config = E_DATE_EDIT_CONFIG (object);
-
+
switch (property_id) {
case PROP_EDIT:
g_value_set_object (value, e_date_edit_config_get_edit (edit_config));
@@ -75,9 +75,9 @@ static void
e_date_edit_config_dispose (GObject *object)
{
EDateEditConfig *edit_config = E_DATE_EDIT_CONFIG (object);
-
+
e_date_edit_config_set_edit (edit_config, NULL);
-
+
if (G_OBJECT_CLASS (e_date_edit_config_parent_class)->dispose)
G_OBJECT_CLASS (e_date_edit_config_parent_class)->dispose (object);
}
@@ -87,11 +87,11 @@ e_date_edit_config_finalize (GObject *object)
{
EDateEditConfig *edit_config = E_DATE_EDIT_CONFIG (object);
EDateEditConfigPrivate *priv;
-
+
priv = edit_config->priv;
g_free (priv);
-
+
if (G_OBJECT_CLASS (e_date_edit_config_parent_class)->finalize)
G_OBJECT_CLASS (e_date_edit_config_parent_class)->finalize (object);
}
@@ -101,7 +101,7 @@ e_date_edit_config_class_init (EDateEditConfigClass *klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
GParamSpec *spec;
-
+
/* Method override */
gobject_class->set_property = e_date_edit_config_set_property;
gobject_class->get_property = e_date_edit_config_get_property;
@@ -124,14 +124,14 @@ EDateEditConfig *
e_date_edit_config_new (EDateEdit *date_edit)
{
EDateEditConfig *edit_config;
-
+
edit_config = g_object_new (e_date_edit_config_get_type (), "edit", date_edit, NULL);
return edit_config;
}
EDateEdit *
-e_date_edit_config_get_edit (EDateEditConfig *edit_config)
+e_date_edit_config_get_edit (EDateEditConfig *edit_config)
{
EDateEditConfigPrivate *priv;
@@ -139,14 +139,14 @@ e_date_edit_config_get_edit (EDateEditConfig *edit_config)
g_return_val_if_fail (E_IS_DATE_EDIT_CONFIG (edit_config), NULL);
priv = edit_config->priv;
-
+
return priv->edit;
}
static void
-set_week_start (EDateEdit *date_edit)
+set_week_start (EDateEdit *date_edit)
{
- int week_start_day;
+ int week_start_day;
week_start_day = calendar_config_get_week_start_day ();
@@ -161,14 +161,14 @@ week_start_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointe
{
EDateEditConfig *edit_config = data;
EDateEditConfigPrivate *priv;
-
+
priv = edit_config->priv;
-
+
set_week_start (priv->edit);
}
static void
-set_twentyfour_hour (EDateEdit *date_edit)
+set_twentyfour_hour (EDateEdit *date_edit)
{
gboolean use_24_hour;
@@ -182,14 +182,14 @@ twentyfour_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gp
{
EDateEditConfig *edit_config = data;
EDateEditConfigPrivate *priv;
-
+
priv = edit_config->priv;
-
+
set_twentyfour_hour (priv->edit);
}
static void
-set_dnav_show_week_no (EDateEdit *date_edit)
+set_dnav_show_week_no (EDateEdit *date_edit)
{
gboolean show_week_no;
@@ -203,28 +203,28 @@ dnav_show_week_no_changed_cb (GConfClient *client, guint id, GConfEntry *entry,
{
EDateEditConfig *edit_config = data;
EDateEditConfigPrivate *priv;
-
+
priv = edit_config->priv;
-
+
set_dnav_show_week_no (priv->edit);
}
void
-e_date_edit_config_set_edit (EDateEditConfig *edit_config, EDateEdit *date_edit)
+e_date_edit_config_set_edit (EDateEditConfig *edit_config, EDateEdit *date_edit)
{
EDateEditConfigPrivate *priv;
guint not;
GList *l;
-
+
g_return_if_fail (edit_config != NULL);
g_return_if_fail (E_IS_DATE_EDIT_CONFIG (edit_config));
priv = edit_config->priv;
-
+
if (priv->edit) {
g_object_unref (priv->edit);
priv->edit = NULL;
}
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
@@ -234,17 +234,17 @@ e_date_edit_config_set_edit (EDateEditConfig *edit_config, EDateEdit *date_edit)
/* If the new edit is NULL, return right now */
if (!date_edit)
return;
-
+
priv->edit = g_object_ref (date_edit);
/* Week start */
- set_week_start (date_edit);
+ set_week_start (date_edit);
not = calendar_config_add_notification_week_start_day (week_start_changed_cb, edit_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* 24 Hour format */
- set_twentyfour_hour (date_edit);
+ set_twentyfour_hour (date_edit);
not = calendar_config_add_notification_24_hour_format (twentyfour_hour_changed_cb, edit_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
diff --git a/calendar/gui/e-date-edit-config.h b/calendar/gui/e-date-edit-config.h
index 8b675ec772..1cff692461 100644
--- a/calendar/gui/e-date-edit-config.h
+++ b/calendar/gui/e-date-edit-config.h
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -30,7 +30,7 @@ G_BEGIN_DECLS
#define E_DATE_EDIT_CONFIG(obj) GTK_CHECK_CAST (obj, e_date_edit_config_get_type (), EDateEditConfig)
#define E_DATE_EDIT_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_date_edit_config_get_type (), EDateEditConfigClass)
#define E_IS_DATE_EDIT_CONFIG(obj) GTK_CHECK_TYPE (obj, e_date_edit_config_get_type ())
-
+
typedef struct _EDateEditConfig EDateEditConfig;
typedef struct _EDateEditConfigClass EDateEditConfigClass;
typedef struct _EDateEditConfigPrivate EDateEditConfigPrivate;
diff --git a/calendar/gui/e-day-view-config.c b/calendar/gui/e-day-view-config.c
index bad45b62a6..4d52f55ec6 100644
--- a/calendar/gui/e-day-view-config.c
+++ b/calendar/gui/e-day-view-config.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Rodrigo Moya <rodrigo@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -44,7 +44,7 @@ e_day_view_config_set_property (GObject *object, guint property_id, const GValue
EDayViewConfig *view_config;
view_config = E_DAY_VIEW_CONFIG (object);
-
+
switch (property_id) {
case PROP_VIEW:
e_day_view_config_set_view (view_config, g_value_get_object (value));
@@ -61,7 +61,7 @@ e_day_view_config_get_property (GObject *object, guint property_id, GValue *valu
EDayViewConfig *view_config;
view_config = E_DAY_VIEW_CONFIG (object);
-
+
switch (property_id) {
case PROP_VIEW:
g_value_set_object (value, e_day_view_config_get_view (view_config));
@@ -78,7 +78,7 @@ e_day_view_config_dispose (GObject *object)
EDayViewConfig *view_config = E_DAY_VIEW_CONFIG (object);
e_day_view_config_set_view (view_config, NULL);
-
+
if (G_OBJECT_CLASS (e_day_view_config_parent_class)->dispose)
G_OBJECT_CLASS (e_day_view_config_parent_class)->dispose (object);
}
@@ -88,11 +88,11 @@ e_day_view_config_finalize (GObject *object)
{
EDayViewConfig *view_config = E_DAY_VIEW_CONFIG (object);
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
g_free (priv);
-
+
if (G_OBJECT_CLASS (e_day_view_config_parent_class)->finalize)
G_OBJECT_CLASS (e_day_view_config_parent_class)->finalize (object);
}
@@ -102,7 +102,7 @@ e_day_view_config_class_init (EDayViewConfigClass *klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
GParamSpec *spec;
-
+
/* Method override */
gobject_class->set_property = e_day_view_config_set_property;
gobject_class->get_property = e_day_view_config_get_property;
@@ -125,14 +125,14 @@ EDayViewConfig *
e_day_view_config_new (EDayView *day_view)
{
EDayViewConfig *view_config;
-
+
view_config = g_object_new (e_day_view_config_get_type (), "view", day_view, NULL);
return view_config;
}
EDayView *
-e_day_view_config_get_view (EDayViewConfig *view_config)
+e_day_view_config_get_view (EDayViewConfig *view_config)
{
EDayViewConfigPrivate *priv;
@@ -140,16 +140,16 @@ e_day_view_config_get_view (EDayViewConfig *view_config)
g_return_val_if_fail (E_IS_DAY_VIEW_CONFIG (view_config), NULL);
priv = view_config->priv;
-
+
return priv->view;
}
static void
-set_timezone (EDayView *day_view)
+set_timezone (EDayView *day_view)
{
icaltimezone *zone;
-
- zone = calendar_config_get_icaltimezone ();
+
+ zone = calendar_config_get_icaltimezone ();
e_calendar_view_set_timezone (E_CALENDAR_VIEW (day_view), zone);
}
@@ -158,16 +158,16 @@ timezone_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_timezone (priv->view);
}
static void
-set_week_start (EDayView *day_view)
+set_week_start (EDayView *day_view)
{
- int week_start_day;
+ int week_start_day;
week_start_day = calendar_config_get_week_start_day ();
@@ -182,14 +182,14 @@ week_start_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointe
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_week_start (priv->view);
}
static void
-set_twentyfour_hour (EDayView *day_view)
+set_twentyfour_hour (EDayView *day_view)
{
gboolean use_24_hour;
@@ -206,16 +206,16 @@ twentyfour_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gp
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_twentyfour_hour (priv->view);
}
static void
-set_working_days (EDayView *day_view)
+set_working_days (EDayView *day_view)
{
- CalWeekdays working_days;
+ CalWeekdays working_days;
working_days = calendar_config_get_working_days ();
@@ -227,19 +227,19 @@ working_days_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpoin
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_working_days (priv->view);
}
static void
-set_day_start_hour (EDayView *day_view)
+set_day_start_hour (EDayView *day_view)
{
int start_hour, start_minute, end_hour, end_minute;
e_day_view_get_working_day (day_view, &start_hour, &start_minute, &end_hour, &end_minute);
-
+
start_hour = calendar_config_get_day_start_hour ();
e_day_view_set_working_day (day_view, start_hour, start_minute, end_hour, end_minute);
@@ -250,19 +250,19 @@ day_start_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpo
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_day_start_hour (priv->view);
}
static void
-set_day_start_minute (EDayView *day_view)
+set_day_start_minute (EDayView *day_view)
{
int start_hour, start_minute, end_hour, end_minute;
e_day_view_get_working_day (day_view, &start_hour, &start_minute, &end_hour, &end_minute);
-
+
start_minute = calendar_config_get_day_start_minute ();
e_day_view_set_working_day (day_view, start_hour, start_minute, end_hour, end_minute);
@@ -273,19 +273,19 @@ day_start_minute_changed_cb (GConfClient *client, guint id, GConfEntry *entry, g
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_day_start_minute (priv->view);
}
static void
-set_day_end_hour (EDayView *day_view)
+set_day_end_hour (EDayView *day_view)
{
int start_hour, start_minute, end_hour, end_minute;
e_day_view_get_working_day (day_view, &start_hour, &start_minute, &end_hour, &end_minute);
-
+
end_hour = calendar_config_get_day_end_hour ();
e_day_view_set_working_day (day_view, start_hour, start_minute, end_hour, end_minute);
@@ -296,20 +296,20 @@ day_end_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpoin
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_day_end_hour (priv->view);
}
static void
-set_day_end_minute (EDayView *day_view)
+set_day_end_minute (EDayView *day_view)
{
int start_hour, start_minute, end_hour, end_minute;
e_day_view_get_working_day (day_view, &start_hour, &start_minute, &end_hour, &end_minute);
-
+
end_minute = calendar_config_get_day_end_minute ();
e_day_view_set_working_day (day_view, start_hour, start_minute, end_hour, end_minute);
@@ -320,16 +320,16 @@ day_end_minute_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpo
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_day_end_minute (priv->view);
}
static void
-set_time_divisions (EDayView *day_view)
+set_time_divisions (EDayView *day_view)
{
- int time_divisions;
+ int time_divisions;
time_divisions = calendar_config_get_time_divisions ();
@@ -341,14 +341,14 @@ time_divisions_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpo
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_time_divisions (priv->view);
}
static void
-set_marcus_bains (EDayView *day_view)
+set_marcus_bains (EDayView *day_view)
{
gboolean show_marcus_bains_line;
const char *dayview_color, *timebar_color;
@@ -363,14 +363,14 @@ marcus_bains_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpoin
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_marcus_bains (priv->view);
}
static void
-set_show_event_end (EDayView *day_view)
+set_show_event_end (EDayView *day_view)
{
gboolean show_event_end;
@@ -384,30 +384,30 @@ show_event_end_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpo
{
EDayViewConfig *view_config = data;
EDayViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_show_event_end (priv->view);
}
void
-e_day_view_config_set_view (EDayViewConfig *view_config, EDayView *day_view)
+e_day_view_config_set_view (EDayViewConfig *view_config, EDayView *day_view)
{
EDayViewConfigPrivate *priv;
gint not_1, not_2, mbnot;
guint not;
GList *l;
-
+
g_return_if_fail (view_config != NULL);
g_return_if_fail (E_IS_DAY_VIEW_CONFIG (view_config));
priv = view_config->priv;
-
+
if (priv->view) {
g_object_unref (priv->view);
priv->view = NULL;
}
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
@@ -417,27 +417,27 @@ e_day_view_config_set_view (EDayViewConfig *view_config, EDayView *day_view)
/* If the new view is NULL, return right now */
if (!day_view)
return;
-
+
priv->view = g_object_ref (day_view);
/* Time zone */
set_timezone (day_view);
-
+
not = calendar_config_add_notification_timezone (timezone_changed_cb, view_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* Week start */
- set_week_start (day_view);
+ set_week_start (day_view);
not = calendar_config_add_notification_week_start_day (week_start_changed_cb, view_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* 24 Hour format */
- set_twentyfour_hour (day_view);
+ set_twentyfour_hour (day_view);
not = calendar_config_add_notification_24_hour_format (twentyfour_hour_changed_cb, view_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
-
+
/* Working days */
set_working_days (day_view);
diff --git a/calendar/gui/e-day-view-config.h b/calendar/gui/e-day-view-config.h
index c75069bb2f..372d50262c 100644
--- a/calendar/gui/e-day-view-config.h
+++ b/calendar/gui/e-day-view-config.h
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -30,7 +30,7 @@ G_BEGIN_DECLS
#define E_DAY_VIEW_CONFIG(obj) GTK_CHECK_CAST (obj, e_day_view_config_get_type (), EDayViewConfig)
#define E_DAY_VIEW_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_day_view_config_get_type (), EDayViewConfigClass)
#define E_IS_DAY_VIEW_CONFIG(obj) GTK_CHECK_TYPE (obj, e_day_view_config_get_type ())
-
+
typedef struct _EDayViewConfig EDayViewConfig;
typedef struct _EDayViewConfigClass EDayViewConfigClass;
typedef struct _EDayViewConfigPrivate EDayViewConfigPrivate;
diff --git a/calendar/gui/e-day-view-layout.c b/calendar/gui/e-day-view-layout.c
index 4536d67952..6bd9887b5b 100644
--- a/calendar/gui/e-day-view-layout.c
+++ b/calendar/gui/e-day-view-layout.c
@@ -89,7 +89,7 @@ static void
e_day_view_layout_long_event (EDayViewEvent *event,
guint8 *grid,
gint days_shown,
- time_t *day_starts,
+ time_t *day_starts,
gint *rows_in_top_display)
{
gint start_day, end_day, free_row, day, row;
@@ -318,7 +318,7 @@ e_day_view_expand_day_event (EDayViewEvent *event,
gboolean
e_day_view_find_long_event_days (EDayViewEvent *event,
gint days_shown,
- time_t *day_starts,
+ time_t *day_starts,
gint *start_day_return,
gint *end_day_return)
{
diff --git a/calendar/gui/e-day-view-layout.h b/calendar/gui/e-day-view-layout.h
index d5aa51ab8a..b2fcec4aac 100644
--- a/calendar/gui/e-day-view-layout.h
+++ b/calendar/gui/e-day-view-layout.h
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 2001, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-day-view-main-item.c b/calendar/gui/e-day-view-main-item.c
index 6b6ffef8a9..58212f0d8e 100644
--- a/calendar/gui/e-day-view-main-item.c
+++ b/calendar/gui/e-day-view-main-item.c
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -125,7 +125,7 @@ e_day_view_main_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
EDayViewMainItem *dvmitem;
dvmitem = E_DAY_VIEW_MAIN_ITEM (o);
-
+
switch (arg_id){
case ARG_DAY_VIEW:
dvmitem->day_view = GTK_VALUE_POINTER (*arg);
@@ -190,7 +190,7 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
day_start_tt = icaltime_from_timet_with_zone (day_view->day_starts[day], FALSE,
e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
weekday = icaltime_day_of_week (day_start_tt) - 1;
-
+
work_day = day_view->working_days & (1 << weekday);
day_x = day_view->day_offsets[day] - x;
@@ -313,7 +313,7 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
if (day_view->marcus_bains_day_view_color && gdk_color_parse (day_view->marcus_bains_day_view_color, &mb_color)) {
GdkColormap *colormap;
-
+
colormap = gtk_widget_get_colormap (GTK_WIDGET (day_view));
if (gdk_colormap_alloc_color (colormap, &mb_color, TRUE, TRUE)) {
gdk_gc_set_foreground (gc, &mb_color);
@@ -322,7 +322,7 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
zone = e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view));
time_now = icaltime_current_time_with_zone (zone);
-
+
for (day = 0; day < day_view->days_shown; day++) {
day_start = icaltime_from_timet_with_zone (day_view->day_starts[day], FALSE, zone);
@@ -804,7 +804,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
icon_x += icon_x_inc;
icon_y += icon_y_inc;
}
-
+
gdk_gc_set_clip_mask (gc, NULL);
}
@@ -854,7 +854,7 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
day_start_tt = icaltime_from_timet_with_zone (day_view->day_starts[day], FALSE,
e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
weekday = icaltime_day_of_week (day_start_tt) - 1;
-
+
work_day = day_view->working_days & (1 << weekday);
day_x = day_view->day_offsets[day] - x;
@@ -863,24 +863,24 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
if (work_day) {
cairo_save (cr);
gdk_cairo_set_source_color (cr, &day_view->colors[E_DAY_VIEW_COLOR_BG_NOT_WORKING]);
-
- cairo_rectangle (cr, day_x, 0 - y, day_w,
+
+ cairo_rectangle (cr, day_x, 0 - y, day_w,
work_day_start_y - (0 - y));
cairo_fill (cr);
cairo_restore (cr);
cairo_save (cr);
gdk_cairo_set_source_color (cr, &day_view->colors[E_DAY_VIEW_COLOR_BG_WORKING]);
-
- cairo_rectangle (cr, day_x, work_day_start_y, day_w,
+
+ cairo_rectangle (cr, day_x, work_day_start_y, day_w,
work_day_end_y - work_day_start_y);
cairo_fill (cr);
cairo_restore (cr);
cairo_save (cr);
gdk_cairo_set_source_color (cr, &day_view->colors[E_DAY_VIEW_COLOR_BG_NOT_WORKING]);
-
- cairo_rectangle (cr, day_x, work_day_end_y, day_w,
+
+ cairo_rectangle (cr, day_x, work_day_end_y, day_w,
height - work_day_end_y);
cairo_fill (cr);
cairo_restore (cr);
@@ -918,17 +918,17 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
if (GTK_WIDGET_HAS_FOCUS(day_view)) {
cairo_save (cr);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_BG_SELECTED]);
- cairo_rectangle (cr, rect_x, rect_y, rect_width,
+ cairo_rectangle (cr, rect_x, rect_y, rect_width,
rect_height);
cairo_fill (cr);
cairo_restore (cr);
} else {
cairo_save (cr);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_BG_SELECTED_UNFOCUSSED]);
- cairo_rectangle (cr, rect_x, rect_y, rect_width,
+ cairo_rectangle (cr, rect_x, rect_y, rect_width,
rect_height);
cairo_fill (cr);
cairo_restore (cr);
@@ -941,9 +941,9 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
grid_x2 = day_view->day_offsets[day_view->days_shown] - x;
cairo_save(cr);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_BG_GRID]);
-
+
for (row = 0, row_y = 0 - y;
row < day_view->rows && row_y < height;
row++, row_y += day_view->row_height) {
@@ -967,26 +967,26 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
continue;
cairo_save (cr);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_BG_GRID]);
cairo_move_to (cr, grid_x1, grid_y1);
cairo_line_to (cr, grid_x1, grid_y2);
cairo_stroke (cr);
-
- gdk_cairo_set_source_color (cr,
+
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_BG_GRID]);
cairo_move_to (cr, grid_x1 + E_DAY_VIEW_BAR_WIDTH - 1, grid_y1);
cairo_line_to (cr, grid_x1 + E_DAY_VIEW_BAR_WIDTH - 1, grid_y2);
cairo_stroke (cr);
-
+
cairo_set_source_rgb (cr, 1, 1, 1);
cairo_rectangle (cr, grid_x1 + 1, grid_y1,
E_DAY_VIEW_BAR_WIDTH - 2, grid_y2 - grid_y1);
-
+
cairo_fill (cr);
-
+
cairo_restore (cr);
/* Fill in the bars when the user is busy. */
@@ -1017,19 +1017,19 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
GdkColor mb_color;
cairo_save (cr);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_MARCUS_BAINS_LINE]);
if (day_view->marcus_bains_day_view_color && gdk_color_parse (day_view->marcus_bains_day_view_color, &mb_color)) {
GdkColormap *colormap;
-
+
colormap = gtk_widget_get_colormap (GTK_WIDGET (day_view));
if (gdk_colormap_alloc_color (colormap, &mb_color, TRUE, TRUE))
gdk_cairo_set_source_color (cr, &mb_color);
}
zone = e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view));
time_now = icaltime_current_time_with_zone (zone);
-
+
for (day = 0; day < day_view->days_shown; day++) {
day_start = icaltime_from_timet_with_zone (day_view->day_starts[day], FALSE, zone);
@@ -1048,7 +1048,7 @@ e_day_view_main_item_draw (GnomeCanvasItem *canvas_item, GdkDrawable *drawable,
}
cairo_restore (cr);
}
- cairo_destroy (cr);
+ cairo_destroy (cr);
}
@@ -1069,8 +1069,8 @@ e_day_view_main_item_draw_events_in_vbars (EDayViewMainItem *dvmitem,
cr = gdk_cairo_create (drawable);
cairo_save (cr);
-
- gdk_cairo_set_source_color (cr,
+
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_EVENT_BACKGROUND]);
grid_x = day_view->day_offsets[day] + 1 - x;
@@ -1088,7 +1088,7 @@ e_day_view_main_item_draw_events_in_vbars (EDayViewMainItem *dvmitem,
colormap = gtk_widget_get_colormap (GTK_WIDGET (day_view));
if (gdk_colormap_alloc_color (colormap, &bg_color, TRUE, TRUE)) {
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&bg_color);
}
}
@@ -1117,7 +1117,7 @@ e_day_view_main_item_draw_events_in_vbars (EDayViewMainItem *dvmitem,
cairo_rectangle (cr, grid_x, bar_y,
E_DAY_VIEW_BAR_WIDTH - 2, bar_h);
-
+
cairo_fill (cr);
g_object_unref (comp);
@@ -1145,7 +1145,7 @@ e_day_view_main_item_draw_long_events_in_vbars (EDayViewMainItem *dvmitem,
cr = gdk_cairo_create (drawable);
cairo_save (cr);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_EVENT_BACKGROUND]);
for (event_num = 0; event_num < day_view->long_events->len;
@@ -1201,7 +1201,7 @@ e_day_view_main_item_draw_long_events_in_vbars (EDayViewMainItem *dvmitem,
if (bar_y1 < height && bar_y2 > 0 && bar_y2 > bar_y1) {
cairo_rectangle (cr, grid_x, bar_y1,
E_DAY_VIEW_BAR_WIDTH - 2, bar_y2 - bar_y1);
-
+
cairo_fill (cr);
}
}
@@ -1273,7 +1273,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
day_view = dvmitem->day_view;
cr = gdk_cairo_create (drawable);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_EVENT_VBAR]);
gc = day_view->main_gc;
@@ -1299,7 +1299,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
return;
/* Get the position of the event. If it is not shown skip it.*/
- if (!e_day_view_get_event_position (day_view, day, event_num,
+ if (!e_day_view_get_event_position (day_view, day, event_num,
&item_x, &item_y,
&item_w, &item_h))
return;
@@ -1353,7 +1353,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
cairo_fill (cr);
cairo_pattern_destroy (pat);
- /* Arc at the right */
+ /* Arc at the right */
pat = cairo_pattern_create_radial (item_x + item_w - E_DAY_VIEW_BAR_WIDTH + 3, item_y + 13.5, 5.0,
item_x + item_w - E_DAY_VIEW_BAR_WIDTH + 5, item_y + 13.5, 12.0);
cairo_pattern_add_color_stop_rgba (pat, 1, 1, 1, 1, 0.3);
@@ -1422,40 +1422,40 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
cairo_move_to (cr, item_x + item_w - E_DAY_VIEW_BAR_WIDTH + 9, item_y + item_h - 6);
cairo_line_to (cr, item_x + item_w - E_DAY_VIEW_BAR_WIDTH + 10, item_y + item_h - 6);
cairo_stroke (cr);
-
+
cairo_restore (cr);
-
+
/* Black border */
cairo_save (cr);
- x0 = item_x + E_DAY_VIEW_BAR_WIDTH + 9;
+ x0 = item_x + E_DAY_VIEW_BAR_WIDTH + 9;
y0 = item_y + 10;
rect_width = MAX (item_w - E_DAY_VIEW_BAR_WIDTH - 7, 0);
rect_height = item_h - 7;
- radius = 20;
+ radius = 20;
draw_curved_rectangle (cr, x0, y0, rect_width, rect_height, radius);
cairo_set_source_rgb (cr, 0, 0, 0);
cairo_fill (cr);
cairo_restore (cr);
-
+
/* Extra Grid lines when clicked */
cairo_save (cr);
- x0 = item_x + E_DAY_VIEW_BAR_WIDTH + 1;
+ x0 = item_x + E_DAY_VIEW_BAR_WIDTH + 1;
y0 = item_y + 2;
rect_width = MAX (item_w - E_DAY_VIEW_BAR_WIDTH - 3, 0);
rect_height = item_h - 4.;
- radius = 16;
+ radius = 16;
draw_curved_rectangle (cr, x0, y0, rect_width, rect_height, radius);
cairo_set_source_rgb (cr, 1, 1, 1);
cairo_fill (cr);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_BG_GRID]);
for (row_y = y0;
@@ -1469,18 +1469,18 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
}
}
cairo_restore (cr);
- }
+ }
}
/* Draw the background of the event with white to play with transparency */
cairo_save (cr);
- x0 = item_x + E_DAY_VIEW_BAR_WIDTH + 1;
+ x0 = item_x + E_DAY_VIEW_BAR_WIDTH + 1;
y0 = item_y + 2;
rect_width = MAX (item_w - E_DAY_VIEW_BAR_WIDTH - 3, 0);
rect_height = item_h - 4.;
- radius = 16;
+ radius = 16;
draw_curved_rectangle (cr, x0, y0, rect_width, rect_height, radius);
@@ -1492,12 +1492,12 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
/* Here we draw the border in event color */
cairo_save (cr);
- x0 = item_x + E_DAY_VIEW_BAR_WIDTH;
+ x0 = item_x + E_DAY_VIEW_BAR_WIDTH;
y0 = item_y + 1.;
rect_width = MAX (item_w - E_DAY_VIEW_BAR_WIDTH - 1., 0);
rect_height = item_h - 2.;
- radius = 16;
+ radius = 16;
draw_curved_rectangle (cr, x0, y0, rect_width,rect_height, radius);
cairo_set_line_width (cr, 2.);
@@ -1514,24 +1514,24 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
rect_width = item_w - E_DAY_VIEW_BAR_WIDTH - 4.5;
rect_height = item_h - 5.5;
- radius = 14;
-
+ radius = 14;
+
draw_curved_rectangle (cr, x0, y0, rect_width, rect_height, radius);
date_fraction = rect_height / day_view->row_height;
interval = event->end_minute - event->start_minute;
- if ((interval/day_view->mins_per_row) >= 2)
+ if ((interval/day_view->mins_per_row) >= 2)
short_event = FALSE;
else if ((interval%day_view->mins_per_row)==0) {
if (((event->end_minute%day_view->mins_per_row) == 0) || ((event->start_minute%day_view->mins_per_row) == 0))
- short_event = TRUE;
+ short_event = TRUE;
}
else
short_event = FALSE;
if (day_view->editing_event_day == day
- && day_view->editing_event_num == event_num)
+ && day_view->editing_event_num == event_num)
short_event = TRUE;
if (gradient) {
@@ -1558,10 +1558,10 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
cairo_set_line_width (cr, 0.5);
cairo_stroke (cr);
cairo_restore (cr);
-
+
/* Draw the right edge of the vertical bar. */
cairo_save (cr);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_BG_GRID]);
cairo_set_line_width (cr, 0.7);
cairo_move_to (cr, item_x + E_DAY_VIEW_BAR_WIDTH - 1, item_y + 1);
@@ -1569,7 +1569,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
cairo_stroke (cr);
cairo_restore (cr);
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_EVENT_VBAR]);
/* Draw the vertical colored bar showing when the appointment
@@ -1583,7 +1583,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
if (day_view->resize_drag_pos != E_CALENDAR_VIEW_POS_NONE
&& day_view->resize_event_day == day
&& day_view->resize_event_num == event_num) {
- resize_flag = TRUE;
+ resize_flag = TRUE;
if (day_view->resize_drag_pos == E_CALENDAR_VIEW_POS_TOP_EDGE)
bar_y1 = item_y + 1;
@@ -1592,7 +1592,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
bar_y2 = item_y + item_h - 1;
end_minute = event->end_minute;
-
+
end_hour = end_minute / 60;
end_minute = end_minute % 60;
@@ -1600,7 +1600,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
&end_display_hour,
&end_resize_suffix,
&end_suffix_width);
-
+
cairo_save (cr);
cairo_rectangle (cr, item_x + E_DAY_VIEW_BAR_WIDTH + 1.75, item_y + 2.75,
item_w - E_DAY_VIEW_BAR_WIDTH - 4.5,
@@ -1612,7 +1612,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
cairo_translate (cr, item_x + item_w - E_DAY_VIEW_BAR_WIDTH - 32, item_y + item_h - 8);
end_resize_time = g_strdup_printf ("%2i:%02i",
end_display_hour, end_minute);
-
+
} else {
cairo_translate (cr, item_x + item_w - E_DAY_VIEW_BAR_WIDTH - 48, item_y + item_h - 8);
end_resize_time = g_strdup_printf ("%2i:%02i%s",
@@ -1633,7 +1633,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
if (bar_y2 > scroll_flag)
event->end_minute += day_view->mins_per_row;
- else if (bar_y2 < scroll_flag)
+ else if (bar_y2 < scroll_flag)
event->end_minute -= day_view->mins_per_row;
if (!short_event)
@@ -1673,7 +1673,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
text = g_strdup_printf
("%2i:%02i-%2i:%02i",
start_display_hour, start_minute,
- end_display_hour, end_minute);
+ end_display_hour, end_minute);
} else {
if (format_time) {
/* 24 hour format without end time. */
@@ -1687,7 +1687,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
/* 12 hour format with end time. */
text = g_strdup_printf
("%2i:%02i%s-%2i:%02i%s",
- start_display_hour, start_minute,
+ start_display_hour, start_minute,
start_suffix,
end_display_hour, end_minute, end_suffix);
} else {
@@ -1754,7 +1754,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
}
}
- gdk_cairo_set_source_color (cr,
+ gdk_cairo_set_source_color (cr,
&day_view->colors[E_DAY_VIEW_COLOR_EVENT_VBAR]);
/* Draw the reminder & recurrence icons, if needed. */
@@ -1823,17 +1823,17 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
cairo_paint (cr);
cairo_close_path (cr);
cairo_restore (cr);
-
+
icon_x += icon_x_inc;
icon_y += icon_y_inc;
- }
+ }
if (draw_recurrence_icon) {
max_icon_w = item_x + item_w - icon_x
- E_DAY_VIEW_EVENT_BORDER_WIDTH;
max_icon_h = item_y + item_h - icon_y
- E_DAY_VIEW_EVENT_BORDER_HEIGHT;
-
+
cairo_save (cr);
cairo_rectangle (cr, icon_x, icon_y, max_icon_w, max_icon_h);
cairo_clip (cr);
@@ -1842,7 +1842,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
cairo_paint (cr);
cairo_close_path (cr);
cairo_restore (cr);
-
+
icon_x += icon_x_inc;
icon_y += icon_y_inc;
}
@@ -1877,7 +1877,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
cairo_paint (cr);
cairo_close_path (cr);
cairo_restore (cr);
-
+
icon_x += icon_x_inc;
icon_y += icon_y_inc;
}
@@ -1893,7 +1893,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
gdk_cairo_set_source_pixbuf (cr, day_view->meeting_icon, icon_x, icon_y);
cairo_paint (cr);
cairo_restore (cr);
-
+
icon_x += icon_x_inc;
icon_y += icon_y_inc;
}
@@ -1912,7 +1912,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
- E_DAY_VIEW_EVENT_BORDER_WIDTH;
max_icon_h = item_y + item_h - icon_y
- E_DAY_VIEW_EVENT_BORDER_HEIGHT;
-
+
gdk_gc_set_clip_origin (gc, icon_x, icon_y);
if (mask != NULL)
gdk_gc_set_clip_mask (gc, mask);
@@ -1931,7 +1931,7 @@ e_day_view_main_item_draw_day_event (EDayViewMainItem *dvmitem,
icon_x += icon_x_inc;
icon_y += icon_y_inc;
}
-
+
gdk_gc_set_clip_mask (gc, NULL);
}
diff --git a/calendar/gui/e-day-view-main-item.h b/calendar/gui/e-day-view-main-item.h
index 1162926480..7e64cb5927 100644
--- a/calendar/gui/e-day-view-main-item.h
+++ b/calendar/gui/e-day-view-main-item.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-day-view-time-item.c b/calendar/gui/e-day-view-time-item.c
index 56642db245..5c06fe6ea7 100644
--- a/calendar/gui/e-day-view-time-item.c
+++ b/calendar/gui/e-day-view-time-item.c
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -141,7 +141,7 @@ e_day_view_time_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
EDayViewTimeItem *dvtmitem;
dvtmitem = E_DAY_VIEW_TIME_ITEM (o);
-
+
switch (arg_id){
case ARG_DAY_VIEW:
dvtmitem->day_view = GTK_VALUE_POINTER (*arg);
@@ -333,12 +333,12 @@ e_day_view_time_item_draw (GnomeCanvasItem *canvas_item,
struct icaltimetype time_now;
int marcus_bains_y;
GdkColor mb_color;
-
+
gdk_gc_set_foreground (gc, &day_view->colors[E_DAY_VIEW_COLOR_MARCUS_BAINS_LINE]);
if (day_view->marcus_bains_time_bar_color && gdk_color_parse (day_view->marcus_bains_time_bar_color, &mb_color)) {
GdkColormap *colormap;
-
+
colormap = gtk_widget_get_colormap (GTK_WIDGET (day_view));
if (gdk_colormap_alloc_color (colormap, &mb_color, TRUE, TRUE)) {
gdk_gc_set_foreground (gc, &mb_color);
@@ -557,13 +557,13 @@ e_day_view_time_item_draw (GnomeCanvasItem *canvas_item,
struct icaltimetype time_now;
int marcus_bains_y;
GdkColor mb_color;
-
+
cairo_save (cr);
gdk_cairo_set_source_color (cr, &day_view->colors[E_DAY_VIEW_COLOR_MARCUS_BAINS_LINE]);
if (day_view->marcus_bains_time_bar_color && gdk_color_parse (day_view->marcus_bains_time_bar_color, &mb_color)) {
GdkColormap *colormap;
-
+
colormap = gtk_widget_get_colormap (GTK_WIDGET (day_view));
if (gdk_colormap_alloc_color (colormap, &mb_color, TRUE, TRUE)) {
gdk_cairo_set_source_color (cr, &mb_color);
@@ -625,7 +625,7 @@ e_day_view_time_item_draw (GnomeCanvasItem *canvas_item,
layout = pango_cairo_create_layout (cr);
pango_layout_set_text (layout, buffer, -1);
pango_layout_get_pixel_size (layout, &minute_width, NULL);
- cairo_translate (cr, minute_x2 - minute_width, row_y + small_font_y_offset);
+ cairo_translate (cr, minute_x2 - minute_width, row_y + small_font_y_offset);
pango_cairo_update_layout (cr, layout);
pango_cairo_show_layout (cr, layout);
cairo_restore (cr);
@@ -800,7 +800,7 @@ e_day_view_time_item_show_popup_menu (EDayViewTimeItem *dvtmitem,
for (i = 0; i < num_divisions; i++) {
g_snprintf (buffer, sizeof (buffer),
- /* TO TRANSLATORS: %02i is the number of minutes; this is a context menu entry
+ /* TO TRANSLATORS: %02i is the number of minutes; this is a context menu entry
* to change the length of the time division in the calendar day view, e.g.
* a day is displayed in 24 "60 minute divisions" or 48 "30 minute divisions"
*/
diff --git a/calendar/gui/e-day-view-time-item.h b/calendar/gui/e-day-view-time-item.h
index c587db68d3..b897eb26f0 100644
--- a/calendar/gui/e-day-view-time-item.h
+++ b/calendar/gui/e-day-view-time-item.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-day-view-top-item.c b/calendar/gui/e-day-view-top-item.c
index e348e8cc50..e04c3e2345 100644
--- a/calendar/gui/e-day-view-top-item.c
+++ b/calendar/gui/e-day-view-top-item.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -124,7 +124,7 @@ e_day_view_top_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
EDayViewTopItem *dvtitem;
dvtitem = E_DAY_VIEW_TOP_ITEM (o);
-
+
switch (arg_id){
case ARG_DAY_VIEW:
dvtitem->day_view = GTK_VALUE_POINTER (*arg);
@@ -798,7 +798,7 @@ e_day_view_top_item_draw (GnomeCanvasItem *canvas_item,
clip_rect.y = 2 - y;
clip_rect.width = day_view->day_widths[day];
clip_rect.height = item_height - 2;
-
+
gdk_gc_set_clip_rectangle (fg_gc, &clip_rect);
layout = gtk_widget_create_pango_layout (GTK_WIDGET (day_view), buffer);
@@ -952,7 +952,7 @@ e_day_view_top_item_draw_long_event (EDayViewTopItem *dvtitem,
/* Fill the background with white to play with transparency */
cairo_save (cr);
- x0 = item_x - x + 4;
+ x0 = item_x - x + 4;
y0 = item_y + 1 - y;
rect_width = item_w - 8;
rect_height = item_h - 2;
@@ -969,7 +969,7 @@ e_day_view_top_item_draw_long_event (EDayViewTopItem *dvtitem,
/* Draw the border around the event */
cairo_save (cr);
- x0 = item_x - x + 4;
+ x0 = item_x - x + 4;
y0 = item_y + 1 - y;
rect_width = item_w - 8;
rect_height = item_h - 2;
@@ -987,15 +987,15 @@ e_day_view_top_item_draw_long_event (EDayViewTopItem *dvtitem,
cairo_save (cr);
- x0 = item_x - x + 5.5;
+ x0 = item_x - x + 5.5;
y0 = item_y + 2.5 - y;
rect_width = item_w - 11;
rect_height = item_h - 5;
- radius = 10;
+ radius = 10;
draw_curved_rectangle (cr, x0, y0, rect_width, rect_height, radius);
-
+
if (gradient){
pat = cairo_pattern_create_linear (item_x - x + 5.5, item_y + 2.5 - y,
item_x - x + 5, item_y - y + item_h + 7.5);
@@ -1155,7 +1155,7 @@ e_day_view_top_item_draw_long_event (EDayViewTopItem *dvtitem,
gdk_cairo_set_source_pixbuf (cr, day_view->recurrence_icon, icon_x, icon_y);
cairo_paint (cr);
cairo_restore (cr);
-
+
icon_x -= icon_x_inc;
}
@@ -1164,7 +1164,7 @@ e_day_view_top_item_draw_long_event (EDayViewTopItem *dvtitem,
gdk_cairo_set_source_pixbuf (cr, day_view->attach_icon, icon_x, icon_y);
cairo_paint (cr);
cairo_restore (cr);
-
+
icon_x -= icon_x_inc;
}
if (icon_x <= max_icon_x && e_cal_component_has_alarms (comp)) {
@@ -1172,7 +1172,7 @@ e_day_view_top_item_draw_long_event (EDayViewTopItem *dvtitem,
gdk_cairo_set_source_pixbuf (cr, day_view->reminder_icon, icon_x, icon_y);
cairo_paint (cr);
cairo_restore (cr);
-
+
icon_x -= icon_x_inc;
}
@@ -1181,11 +1181,11 @@ e_day_view_top_item_draw_long_event (EDayViewTopItem *dvtitem,
gdk_cairo_set_source_pixbuf (cr, day_view->meeting_icon, icon_x, icon_y);
cairo_paint (cr);
cairo_restore (cr);
-
+
icon_x -= icon_x_inc;
}
- /* draw categories icons */
+ /* draw categories icons */
e_cal_component_get_categories_list (comp, &categories_list);
for (elem = categories_list; elem; elem = elem->next) {
char *category;
@@ -1273,7 +1273,7 @@ e_day_view_top_item_draw_triangle (EDayViewTopItem *dvtitem,
gdk_cairo_set_source_color (cr, &bg_color);
} else {
gdk_cairo_set_source_color (cr, &day_view->colors[E_DAY_VIEW_COLOR_LONG_EVENT_BACKGROUND]);
- }
+ }
} else {
gdk_cairo_set_source_color (cr, &day_view->colors[E_DAY_VIEW_COLOR_LONG_EVENT_BACKGROUND]);
}
diff --git a/calendar/gui/e-day-view-top-item.h b/calendar/gui/e-day-view-top-item.h
index f267a98d55..2d21a42f35 100644
--- a/calendar/gui/e-day-view-top-item.h
+++ b/calendar/gui/e-day-view-top-item.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-day-view.c b/calendar/gui/e-day-view.c
index 0eccaa3922..598404b673 100644
--- a/calendar/gui/e-day-view.c
+++ b/calendar/gui/e-day-view.c
@@ -500,7 +500,7 @@ time_range_changed_cb (ECalModel *model, time_t start_time, time_t end_time, gpo
} else {
lower = e_day_view_find_work_week_start (day_view, start_time);
}
-
+
/* See if we need to change the days shown. */
if (lower != day_view->lower)
e_day_view_recalc_day_starts (day_view, lower);
@@ -614,9 +614,9 @@ model_rows_deleted_cb (ETableModel *etm, int row, int count, gpointer user_data)
{
EDayView *day_view = E_DAY_VIEW (user_data);
int i;
-
+
e_day_view_stop_editing_event (day_view);
-
+
for (i = row + count; i > row; i--) {
gint day, event_num;
const char *uid, *rid = NULL;
@@ -638,7 +638,7 @@ model_rows_deleted_cb (ETableModel *etm, int row, int count, gpointer user_data)
if (e_day_view_find_event_from_uid (day_view, comp_data->client, uid, rid, &day, &event_num))
e_day_view_remove_event_cb (day_view, day, event_num, NULL);
}
-
+
gtk_widget_queue_draw (day_view->top_canvas);
gtk_widget_queue_draw (day_view->main_canvas);
e_day_view_queue_layout (day_view);
@@ -676,7 +676,7 @@ e_day_view_init (EDayView *day_view)
gint day;
GnomeCanvasGroup *canvas_group;
ECalModel *model;
-
+
GTK_WIDGET_SET_FLAGS (day_view, GTK_CAN_FOCUS);
day_view->long_events = g_array_new (FALSE, FALSE,
@@ -920,7 +920,7 @@ e_day_view_init (EDayView *day_view)
day_view->drag_rect_item =
gnome_canvas_item_new (canvas_group,
- gnome_canvas_rect_get_type (),
+ gnome_canvas_rect_get_type (),
"width_pixels", 1,
NULL);
gnome_canvas_item_hide (day_view->drag_rect_item);
@@ -1027,7 +1027,7 @@ e_day_view_init (EDayView *day_view)
GnomeCanvasGroup *canvas_group;
ECalModel *model;
GtkWidget *w;
-
+
GTK_WIDGET_SET_FLAGS (day_view, GTK_CAN_FOCUS);
day_view->long_events = g_array_new (FALSE, FALSE,
@@ -1093,7 +1093,7 @@ e_day_view_init (EDayView *day_view)
day_view->last_edited_comp_string = NULL;
-
+
day_view->selection_start_row = -1;
day_view->selection_start_day = -1;
day_view->selection_end_row = -1;
@@ -1129,7 +1129,7 @@ e_day_view_init (EDayView *day_view)
* Top Canvas
*/
w = gtk_vbox_new (FALSE, 0);
-
+
day_view->top_dates_canvas = e_canvas_new ();
gtk_box_pack_start (GTK_BOX (w), day_view->top_dates_canvas, TRUE, TRUE, 0);
day_view->top_canvas = e_canvas_new ();
@@ -1255,7 +1255,7 @@ e_day_view_init (EDayView *day_view)
day_view->drag_rect_item =
gnome_canvas_item_new (canvas_group,
- gnome_canvas_rect_get_type (),
+ gnome_canvas_rect_get_type (),
"width_pixels", 1,
NULL);
gnome_canvas_item_hide (day_view->drag_rect_item);
@@ -1379,7 +1379,7 @@ e_day_view_new (void)
day_view = g_object_new (e_day_view_get_type (), NULL);
e_cal_model_set_flags (e_calendar_view_get_model (E_CALENDAR_VIEW (day_view)), E_CAL_MODEL_FLAGS_EXPAND_RECURRENCES);
-
+
return GTK_WIDGET (day_view);
}
@@ -1427,7 +1427,7 @@ e_day_view_destroy (GtkObject *object)
g_array_free (day_view->long_events, TRUE);
day_view->long_events = NULL;
}
-
+
for (day = 0; day < E_DAY_VIEW_MAX_DAYS; day++) {
if (day_view->events[day]) {
g_array_free (day_view->events[day], TRUE);
@@ -1454,9 +1454,9 @@ e_day_view_realize (GtkWidget *widget)
colormap = gtk_widget_get_colormap (widget);
/* Allocate the colors. */
-
+
e_day_view_set_colors(day_view, widget);
-
+
gdk_gc_set_colormap (day_view->main_gc, colormap);
/* Create the pixmaps. */
@@ -1464,7 +1464,7 @@ e_day_view_realize (GtkWidget *widget)
day_view->recurrence_icon = e_icon_factory_get_icon ("view-refresh", E_ICON_SIZE_MENU);
day_view->timezone_icon = e_icon_factory_get_icon ("stock_timezone", E_ICON_SIZE_MENU);
day_view->meeting_icon = e_icon_factory_get_icon ("stock_people", E_ICON_SIZE_MENU);
- day_view->attach_icon = e_icon_factory_get_icon ("mail-attachment", E_ICON_SIZE_MENU);
+ day_view->attach_icon = e_icon_factory_get_icon ("mail-attachment", E_ICON_SIZE_MENU);
/* Set the canvas item colors. */
@@ -1528,9 +1528,9 @@ e_day_view_realize (GtkWidget *widget)
colormap = gtk_widget_get_colormap (widget);
/* Allocate the colors. */
-
+
e_day_view_set_colors(day_view, widget);
-
+
gdk_gc_set_colormap (day_view->main_gc, colormap);
/* Create the pixmaps. */
@@ -1538,7 +1538,7 @@ e_day_view_realize (GtkWidget *widget)
day_view->recurrence_icon = e_icon_factory_get_icon ("view-refresh", E_ICON_SIZE_MENU);
day_view->timezone_icon = e_icon_factory_get_icon ("stock_timezone", E_ICON_SIZE_MENU);
day_view->meeting_icon = e_icon_factory_get_icon ("stock_people", E_ICON_SIZE_MENU);
- day_view->attach_icon = e_icon_factory_get_icon ("mail-attachment", E_ICON_SIZE_MENU);
+ day_view->attach_icon = e_icon_factory_get_icon ("mail-attachment", E_ICON_SIZE_MENU);
/* Set the canvas item colors. */
@@ -1611,9 +1611,9 @@ static GdkColor
e_day_view_get_text_color (EDayView *day_view, EDayViewEvent *event, GtkWidget *widget)
{
GdkColor color, bg_color;
- guint16 red, green, blue;
+ guint16 red, green, blue;
gdouble cc = 65535.0;
-
+
red = day_view->colors[E_DAY_VIEW_COLOR_EVENT_BACKGROUND].red;
green = day_view->colors[E_DAY_VIEW_COLOR_EVENT_BACKGROUND].green;
blue = day_view->colors[E_DAY_VIEW_COLOR_EVENT_BACKGROUND].blue;
@@ -1741,13 +1741,13 @@ e_day_view_style_set (GtkWidget *widget,
layout = pango_layout_new (pango_context);
/* Create the large font. */
- if (day_view->large_font_desc != NULL)
+ if (day_view->large_font_desc != NULL)
pango_font_description_free (day_view->large_font_desc);
day_view->large_font_desc = pango_font_description_copy (font_desc);
pango_font_description_set_size (day_view->large_font_desc,
E_DAY_VIEW_LARGE_FONT_PTSIZE * PANGO_SCALE);
-
+
/* Create the small fonts. */
if (day_view->small_font_desc != NULL)
pango_font_description_free (day_view->small_font_desc);
@@ -1934,13 +1934,13 @@ e_day_view_style_set (GtkWidget *widget,
layout = pango_layout_new (pango_context);
/* Create the large font. */
- if (day_view->large_font_desc != NULL)
+ if (day_view->large_font_desc != NULL)
pango_font_description_free (day_view->large_font_desc);
day_view->large_font_desc = pango_font_description_copy (font_desc);
pango_font_description_set_size (day_view->large_font_desc,
E_DAY_VIEW_LARGE_FONT_PTSIZE * PANGO_SCALE);
-
+
/* Create the small fonts. */
if (day_view->small_font_desc != NULL)
pango_font_description_free (day_view->small_font_desc);
@@ -2391,23 +2391,23 @@ e_day_view_remove_event_cb (EDayView *day_view,
static void
set_text_as_bold (EDayViewEvent *event)
{
- ECalComponent *comp;
+ ECalComponent *comp;
char *address;
GSList *attendees, *l;
ECalComponentAttendee *at = NULL;
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (event->comp_data->icalcomp));
- address = itip_get_comp_attendee (comp, event->comp_data->client);
+ address = itip_get_comp_attendee (comp, event->comp_data->client);
e_cal_component_get_attendee_list (comp, &attendees);
for (l = attendees; l; l = l->next) {
ECalComponentAttendee *attendee = l->data;
if (g_str_equal (itip_strip_mailto (attendee->value), address)) {
- at = attendee;
+ at = attendee;
break;
- }
+ }
}
/* The attendee has not yet accepted the meeting, display the summary as bolded .
@@ -2519,8 +2519,8 @@ e_day_view_update_event_label (EDayView *day_view,
"text", text,
NULL);
-/* if (e_cal_get_static_capability (event->comp_data->client, CAL_STATIC_CAPABILITY_HAS_UNACCEPTED_MEETING)
- && e_cal_util_component_has_attendee (event->comp_data->icalcomp))
+/* if (e_cal_get_static_capability (event->comp_data->client, CAL_STATIC_CAPABILITY_HAS_UNACCEPTED_MEETING)
+ && e_cal_util_component_has_attendee (event->comp_data->icalcomp))
set_text_as_bold (event); */
if (free_text)
@@ -2555,11 +2555,11 @@ e_day_view_update_event_label (EDayView *day_view,
interval = event->end_minute - event->start_minute;
- if ((interval/day_view->mins_per_row) >= 2)
+ if ((interval/day_view->mins_per_row) >= 2)
short_event = FALSE;
else if ((interval%day_view->mins_per_row)==0) {
if (((event->end_minute%day_view->mins_per_row)==0) || ((event->start_minute%day_view->mins_per_row)==0)){
- short_event = TRUE;
+ short_event = TRUE;
}
} else
short_event = FALSE;
@@ -2575,8 +2575,8 @@ e_day_view_update_event_label (EDayView *day_view,
"text", text,
NULL);
-/* if (e_cal_get_static_capability (event->comp_data->client, CAL_STATIC_CAPABILITY_HAS_UNACCEPTED_MEETING)
- && e_cal_util_component_has_attendee (event->comp_data->icalcomp))
+/* if (e_cal_get_static_capability (event->comp_data->client, CAL_STATIC_CAPABILITY_HAS_UNACCEPTED_MEETING)
+ && e_cal_util_component_has_attendee (event->comp_data->icalcomp))
set_text_as_bold (event); */
if (free_text)
@@ -2608,8 +2608,8 @@ e_day_view_update_long_event_label (EDayView *day_view,
if (free_text)
g_free ((gchar*)summary);
-/* if (e_cal_get_static_capability (event->comp_data->client, CAL_STATIC_CAPABILITY_HAS_UNACCEPTED_MEETING)
- && e_cal_util_component_has_attendee (event->comp_data->icalcomp))
+/* if (e_cal_get_static_capability (event->comp_data->client, CAL_STATIC_CAPABILITY_HAS_UNACCEPTED_MEETING)
+ && e_cal_util_component_has_attendee (event->comp_data->icalcomp))
set_text_as_bold (event); */
}
@@ -3251,15 +3251,15 @@ e_day_view_set_marcus_bains (EDayView *day_view,
(day_view->marcus_bains_day_view_color != dayview_color) |
(day_view->marcus_bains_time_bar_color != timebar_color)) {
- if (day_view->marcus_bains_day_view_color)
+ if (day_view->marcus_bains_day_view_color)
g_free (day_view->marcus_bains_day_view_color);
- if (day_view->marcus_bains_time_bar_color)
+ if (day_view->marcus_bains_time_bar_color)
g_free (day_view->marcus_bains_time_bar_color);
-
+
day_view->show_marcus_bains_line = show_line;
- if (dayview_color)
+ if (dayview_color)
day_view->marcus_bains_day_view_color = g_strdup (dayview_color);
- else
+ else
day_view->marcus_bains_day_view_color = NULL;
if (timebar_color)
@@ -3339,7 +3339,7 @@ e_day_view_set_week_start_day (EDayView *day_view,
static void
e_day_view_recalc_work_week (EDayView *day_view)
-{
+{
time_t lower;
/* If we aren't showing the work week, just return. */
@@ -3347,7 +3347,7 @@ e_day_view_recalc_work_week (EDayView *day_view)
return;
e_day_view_recalc_work_week_days_shown (day_view);
-
+
/* If the date isn't set, just return. */
if (day_view->lower == 0 && day_view->upper == 0)
return;
@@ -3463,7 +3463,7 @@ e_day_view_on_top_canvas_button_press (GtkWidget *widget,
if (day_view->drag_event_num != -1)
day_view->drag_event_num = -1;
-
+
/* Convert the coords to the main canvas window, or return if the
window is not found. */
if (!e_day_view_convert_event_coords (day_view, (GdkEvent*) event,
@@ -3523,7 +3523,7 @@ e_day_view_on_top_canvas_button_press (GtkWidget *widget,
e_day_view_start_selection (day_view, day, -1);
e_day_view_finish_selection (day_view);
}
-
+
e_day_view_on_event_right_click (day_view, event, -1, -1);
}
@@ -3602,7 +3602,7 @@ e_day_view_on_main_canvas_button_press (GtkWidget *widget,
if (day_view->drag_event_num != -1)
day_view->drag_event_num = -1;
-
+
/* Convert the coords to the main canvas window, or return if the
window is not found. */
if (!e_day_view_convert_event_coords (day_view, (GdkEvent*) event,
@@ -3660,14 +3660,14 @@ e_day_view_on_main_canvas_button_press (GtkWidget *widget,
if (!GTK_WIDGET_HAS_FOCUS (day_view))
gtk_widget_grab_focus (GTK_WIDGET (day_view));
-
+
if ((day < day_view->selection_start_day || day > day_view->selection_end_day)
|| (day == day_view->selection_start_day && row < day_view->selection_start_row)
|| (day == day_view->selection_end_day && row > day_view->selection_end_row)) {
e_day_view_start_selection (day_view, day, row);
e_day_view_finish_selection (day_view);
}
-
+
e_day_view_on_event_right_click (day_view, event, -1, -1);
}
@@ -3723,7 +3723,7 @@ e_day_view_on_time_canvas_scroll (GtkWidget *widget,
gtk_widget_destroy (tool_window);
g_object_set_data (G_OBJECT (day_view), "tooltip-window", NULL);
}
-
+
switch (scroll->direction) {
case GDK_SCROLL_UP:
e_day_view_scroll (day_view, E_DAY_VIEW_WHEEL_MOUSE_STEP_SIZE);
@@ -3765,7 +3765,7 @@ e_day_view_on_long_event_button_press (EDayView *day_view,
e = &g_array_index (day_view->long_events, EDayViewEvent, event_num);
e_day_view_set_selected_time_range_in_top_visible (day_view, e->start, e->end);
-
+
e_day_view_on_event_right_click (day_view, event,
E_DAY_VIEW_LONG_EVENT,
event_num);
@@ -3805,7 +3805,7 @@ e_day_view_on_event_button_press (EDayView *day_view,
e = &g_array_index (day_view->events[day], EDayViewEvent, event_num);
e_day_view_set_selected_time_range_visible (day_view, e->start, e->end);
-
+
e_day_view_on_event_right_click (day_view, event,
day, event_num);
@@ -4178,14 +4178,14 @@ e_day_view_on_event_double_click (EDayView *day_view,
if (day == -1)
event = &g_array_index (day_view->long_events, EDayViewEvent,
event_num);
- else
+ else
event = &g_array_index (day_view->events[day], EDayViewEvent,
event_num);
attendee_prop = icalcomponent_get_first_property (event->comp_data->icalcomp, ICAL_ATTENDEE_PROPERTY);
e_calendar_view_edit_appointment ((ECalendarView *)day_view,
- event->comp_data->client,
+ event->comp_data->client,
event->comp_data->icalcomp, attendee_prop ? TRUE:FALSE);
}
@@ -4195,9 +4195,9 @@ popup_destroyed_cb (gpointer data, GObject *where_object_was)
EDayView *day_view = data;
day_view->popup_event_day = -1;
- day_view->popup_event_num = -1;
+ day_view->popup_event_num = -1;
}
-
+
static void
e_day_view_show_popup_menu (EDayView *day_view,
GdkEvent *gdk_event,
@@ -4976,7 +4976,7 @@ e_day_view_finish_long_event_resize (EDayView *day_view)
CalObjModType mod = CALOBJ_MOD_ALL;
GtkWindow *toplevel;
int is_date;
-
+
event_num = day_view->resize_event_num;
event = &g_array_index (day_view->long_events, EDayViewEvent,
event_num);
@@ -5017,7 +5017,7 @@ e_day_view_finish_long_event_resize (EDayView *day_view)
e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
e_cal_component_set_dtend (comp, &date);
}
-
+
e_cal_component_commit_sequence (comp);
if (e_cal_component_is_instance (comp)) {
if (!recur_component_dialog (client, comp, &mod, NULL, FALSE)) {
@@ -5047,13 +5047,13 @@ e_day_view_finish_long_event_resize (EDayView *day_view)
e_cal_component_commit_sequence (comp);
}
}
-
+
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (day_view)));
e_calendar_view_modify_and_send (comp, client, mod, toplevel, TRUE);
-
+
out:
gnome_canvas_item_hide (day_view->resize_long_event_rect_item);
-
+
day_view->resize_drag_pos = E_CALENDAR_VIEW_POS_NONE;
g_object_unref (comp);
@@ -5157,12 +5157,12 @@ e_day_view_finish_resize (EDayView *day_view)
e_cal_component_set_exrule_list (comp, NULL);
}
}
-
+
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (day_view)));
e_cal_component_commit_sequence (comp);
e_calendar_view_modify_and_send (comp, client, mod, toplevel, TRUE);
- out:
+ out:
g_object_unref (comp);
}
@@ -5216,7 +5216,7 @@ e_day_view_finish_long_event_resize (EDayView *day_view)
CalObjModType mod = CALOBJ_MOD_ALL;
GtkWindow *toplevel;
int is_date;
-
+
event_num = day_view->resize_event_num;
event = &g_array_index (day_view->long_events, EDayViewEvent,
event_num);
@@ -5257,7 +5257,7 @@ e_day_view_finish_long_event_resize (EDayView *day_view)
e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
e_cal_component_set_dtend (comp, &date);
}
-
+
e_cal_component_commit_sequence (comp);
if (e_cal_component_is_instance (comp)) {
if (!recur_component_dialog (client, comp, &mod, NULL, FALSE)) {
@@ -5287,10 +5287,10 @@ e_day_view_finish_long_event_resize (EDayView *day_view)
e_cal_component_commit_sequence (comp);
}
}
-
+
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (day_view)));
e_calendar_view_modify_and_send (comp, client, mod, toplevel, TRUE);
-
+
out:
day_view->resize_drag_pos = E_CALENDAR_VIEW_POS_NONE;
@@ -5391,12 +5391,12 @@ e_day_view_finish_resize (EDayView *day_view)
e_cal_component_set_exrule_list (comp, NULL);
}
}
-
+
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (day_view)));
e_cal_component_commit_sequence (comp);
e_calendar_view_modify_and_send (comp, client, mod, toplevel, TRUE);
- out:
+ out:
g_object_unref (comp);
}
@@ -6106,14 +6106,14 @@ e_day_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
const char *uid;
AddEventData add_event_data;
gboolean read_only = TRUE;
-
+
g_return_val_if_fail (widget != NULL, FALSE);
g_return_val_if_fail (E_IS_DAY_VIEW (widget), FALSE);
g_return_val_if_fail (event != NULL, FALSE);
day_view = E_DAY_VIEW (widget);
keyval = event->keyval;
-
+
/* The Escape key aborts a resize operation. */
if (day_view->resize_drag_pos != E_CALENDAR_VIEW_POS_NONE) {
if (keyval == GDK_Escape) {
@@ -6122,7 +6122,7 @@ e_day_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
}
return FALSE;
}
-
+
/* Alt + Arrow Keys to move a selected event through time lines */
if (((event->state & GDK_SHIFT_MASK) != GDK_SHIFT_MASK)
&&((event->state & GDK_CONTROL_MASK) != GDK_CONTROL_MASK)
@@ -6137,7 +6137,7 @@ e_day_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
return e_day_view_event_move ((ECalendarView *) day_view, E_CAL_VIEW_MOVE_RIGHT);
}
- /*Go to the start/end of a work day*/
+ /*Go to the start/end of a work day*/
if ((keyval == GDK_Home)
&&((event->state & GDK_SHIFT_MASK) != GDK_SHIFT_MASK)
&&((event->state & GDK_CONTROL_MASK) != GDK_CONTROL_MASK)
@@ -6152,8 +6152,8 @@ e_day_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
e_day_view_goto_end_of_work_day (day_view);
return TRUE;
}
-
- /* In DayView, Shift+Home/End, Change the duration to the time that begins/ends the current work day */
+
+ /* In DayView, Shift+Home/End, Change the duration to the time that begins/ends the current work day */
if ((keyval == GDK_Home)
&&((event->state & GDK_SHIFT_MASK) == GDK_SHIFT_MASK)
&&((event->state & GDK_CONTROL_MASK) != GDK_CONTROL_MASK)
@@ -6169,7 +6169,7 @@ e_day_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
return TRUE;
}
-
+
/* Handle the cursor keys for moving & extending the selection. */
stop_emission = TRUE;
if (event->state & GDK_SHIFT_MASK) {
@@ -6244,9 +6244,9 @@ e_day_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
|| (event->length == 0)
|| (keyval == GDK_Tab))) {
return FALSE;
- }
+ }
- /* Add a new event covering the selected range */
+ /* Add a new event covering the selected range */
icalcomp = e_cal_model_create_component_with_defaults (model);
if (!icalcomp)
return FALSE;
@@ -6267,12 +6267,12 @@ e_day_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
start_dt.tzid = NULL;
start_tt.is_date = 1;
end_tt.is_date = 1;
-
+
/* Editor default in day/work-week view - top canvas */
e_cal_component_set_transparency (comp, E_CAL_COMPONENT_TRANSP_TRANSPARENT);
} else {
start_dt.tzid = icaltimezone_get_tzid (e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
-
+
/* Editor default in day/work-week view - main canvas */
e_cal_component_set_transparency (comp, E_CAL_COMPONENT_TRANSP_OPAQUE);
}
@@ -6322,23 +6322,23 @@ e_day_view_key_press (GtkWidget *widget, GdkEventKey *event)
static void
e_day_view_goto_start_of_work_day (EDayView *day_view)
{
- g_return_if_fail(day_view!=NULL);
+ g_return_if_fail(day_view!=NULL);
if (day_view->selection_in_top_canvas)
return;
- else
- day_view->selection_start_row =
- e_day_view_convert_time_to_row (day_view,
- day_view->work_day_start_hour,
+ else
+ day_view->selection_start_row =
+ e_day_view_convert_time_to_row (day_view,
+ day_view->work_day_start_hour,
day_view->work_day_start_minute);
day_view->selection_end_row = day_view->selection_start_row;
e_day_view_ensure_rows_visible (day_view,
day_view->selection_start_row,
day_view->selection_end_row);
-
+
e_day_view_update_calendar_selection_time (day_view);
-
+
gtk_widget_queue_draw (day_view->top_canvas);
gtk_widget_queue_draw (day_view->top_dates_canvas);
gtk_widget_queue_draw (day_view->main_canvas);
@@ -6353,11 +6353,11 @@ e_day_view_goto_end_of_work_day (EDayView *day_view)
return;
else
day_view->selection_start_row =
- e_day_view_convert_time_to_row (day_view,
- day_view->work_day_end_hour-1,
+ e_day_view_convert_time_to_row (day_view,
+ day_view->work_day_end_hour-1,
day_view->work_day_end_minute+30);
day_view->selection_end_row = day_view->selection_start_row;
-
+
e_day_view_ensure_rows_visible (day_view,
day_view->selection_start_row,
day_view->selection_end_row);
@@ -6374,20 +6374,20 @@ static void
e_day_view_change_duration_to_start_of_work_day (EDayView *day_view)
{
g_return_if_fail(day_view != NULL);
-
+
if (day_view->selection_in_top_canvas)
return;
else {
/* These are never used after being set? */
gint work_start_row,work_end_row,selection_start_row,selection_end_row;
-
+
work_start_row =
- e_day_view_convert_time_to_row (day_view,
- day_view->work_day_start_hour,
+ e_day_view_convert_time_to_row (day_view,
+ day_view->work_day_start_hour,
day_view->work_day_start_minute);
work_end_row =
- e_day_view_convert_time_to_row (day_view,
- day_view->work_day_end_hour - 1,
+ e_day_view_convert_time_to_row (day_view,
+ day_view->work_day_end_hour - 1,
day_view->work_day_end_minute + 30);
selection_start_row = day_view->selection_start_row;
selection_end_row = day_view->selection_end_row;
@@ -6395,7 +6395,7 @@ e_day_view_change_duration_to_start_of_work_day (EDayView *day_view)
day_view->selection_end_row = work_start_row - 1;
else day_view->selection_start_row = work_start_row;
}
-
+
e_day_view_ensure_rows_visible (day_view,
day_view->selection_start_row,
day_view->selection_end_row);
@@ -6412,17 +6412,17 @@ static void
e_day_view_change_duration_to_end_of_work_day (EDayView *day_view)
{
g_return_if_fail(day_view != NULL);
-
+
if (day_view->selection_in_top_canvas)
return;
- else {
- gint work_start_row,work_end_row,selection_start_row,selection_end_row;
+ else {
+ gint work_start_row,work_end_row,selection_start_row,selection_end_row;
work_start_row =
- e_day_view_convert_time_to_row (day_view,
- day_view->work_day_start_hour,
+ e_day_view_convert_time_to_row (day_view,
+ day_view->work_day_start_hour,
day_view->work_day_start_minute);
- work_end_row = e_day_view_convert_time_to_row (day_view,
- day_view->work_day_end_hour-1,
+ work_end_row = e_day_view_convert_time_to_row (day_view,
+ day_view->work_day_end_hour-1,
day_view->work_day_end_minute+30);
selection_start_row = day_view->selection_start_row;
selection_end_row = day_view->selection_end_row;
@@ -6437,9 +6437,9 @@ e_day_view_change_duration_to_end_of_work_day (EDayView *day_view)
e_day_view_ensure_rows_visible (day_view,
day_view->selection_start_row,
day_view->selection_end_row);
-
+
e_day_view_update_calendar_selection_time (day_view);
-
+
gtk_widget_queue_draw (day_view->top_canvas);
gtk_widget_queue_draw (day_view->top_dates_canvas);
gtk_widget_queue_draw (day_view->main_canvas);
@@ -6604,7 +6604,7 @@ e_day_view_get_extreme_long_event (EDayView *day_view, gboolean first,
* @event_num_out: out value, event number of the event found.
* -1 for no event found.
*
- * Decide on which event the focus should go next.
+ * Decide on which event the focus should go next.
* if ((day_out == -1) && (event_num_out == -1)) is true, focus should go
* to day_view widget itself.
*
@@ -7046,7 +7046,7 @@ e_day_view_start_editing_event (EDayView *day_view,
"text", initial_text,
NULL);
if (initial_text)
- g_free (initial_text);
+ g_free (initial_text);
}
}
@@ -7121,7 +7121,7 @@ tooltip_get_view_event (EDayView *day_view, int day, int event_num)
} else {
pevent = &g_array_index (day_view->events[day], EDayViewEvent,
event_num);
- }
+ }
return pevent;
}
@@ -7145,7 +7145,7 @@ tooltip_destroy (EDayView *day_view, GnomeCanvasItem *item)
pevent->timeout = -1;
}
- g_object_set_data (G_OBJECT (day_view), "tooltip-window", NULL);
+ g_object_set_data (G_OBJECT (day_view), "tooltip-window", NULL);
}
}
@@ -7202,7 +7202,7 @@ e_day_view_on_text_item_event (GnomeCanvasItem *item,
if (day_view->drag_event_num != -1)
day_view->drag_event_num = -1;
-
+
case GDK_BUTTON_PRESS:
tooltip_destroy (day_view, item);
/* Only let the EText handle the event while editing. */
@@ -7245,7 +7245,7 @@ e_day_view_on_text_item_event (GnomeCanvasItem *item,
&event_num);
} else {
int tmp;
-
+
pos = e_day_view_convert_position_in_top_canvas (day_view,
event_x, event_y,
&tmp, &event_num);
@@ -7263,7 +7263,7 @@ e_day_view_on_text_item_event (GnomeCanvasItem *item,
if (day_view->drag_event_num != -1)
break;
-
+
pevent = tooltip_get_view_event (day_view, day, event_num);
g_object_set_data (G_OBJECT (item), "event-num", GINT_TO_POINTER (event_num));
g_object_set_data (G_OBJECT (item), "event-day", GINT_TO_POINTER (day));
@@ -7278,7 +7278,7 @@ e_day_view_on_text_item_event (GnomeCanvasItem *item,
data->event_num = event_num;
data->get_view_event = (ECalendarViewEvent * (*)(ECalendarView *, int, int)) tooltip_get_view_event;
pevent->timeout = g_timeout_add (500, (GSourceFunc)e_calendar_view_get_tooltips, data);
-
+
return TRUE;
}
case GDK_LEAVE_NOTIFY:
@@ -7291,11 +7291,11 @@ e_day_view_on_text_item_event (GnomeCanvasItem *item,
int day = GPOINTER_TO_INT(g_object_get_data ((GObject *)item, "event-day"));
pevent = tooltip_get_view_event (day_view, day, event_num);
-
+
pevent->x = ((GdkEventMotion *)event)->x_root;
pevent->y = ((GdkEventMotion *)event)->y_root;
pevent->tooltip = (GtkWidget *)g_object_get_data (G_OBJECT (day_view), "tooltip-window");
-
+
if (pevent->tooltip) {
e_calendar_view_move_tip (pevent->tooltip, pevent->x+16, pevent->y+16);
}
@@ -7305,11 +7305,11 @@ e_day_view_on_text_item_event (GnomeCanvasItem *item,
default:
break;
}
-
+
return FALSE;
}
-static gboolean
+static gboolean
e_day_view_event_move (ECalendarView *cal_view, ECalViewMoveDirection direction)
{
EDayViewEvent *event;
@@ -7335,7 +7335,7 @@ e_day_view_event_move (ECalendarView *cal_view, ECalViewMoveDirection direction)
resize_end_row = (event->end_minute - 1) / day_view->mins_per_row;
if (resize_end_row < resize_start_row)
resize_end_row = resize_start_row;
-
+
switch (direction) {
case E_CAL_VIEW_MOVE_UP:
if (resize_start_row <= 0)
@@ -7343,7 +7343,7 @@ e_day_view_event_move (ECalendarView *cal_view, ECalViewMoveDirection direction)
resize_start_row--;
resize_end_row--;
start_dt = e_day_view_convert_grid_position_to_time (day_view, day, resize_start_row);
- end_dt = e_day_view_convert_grid_position_to_time (day_view, day, resize_end_row + 1);
+ end_dt = e_day_view_convert_grid_position_to_time (day_view, day, resize_end_row + 1);
break;
case E_CAL_VIEW_MOVE_DOWN:
if (resize_end_row >= day_view->rows - 1)
@@ -7351,17 +7351,17 @@ e_day_view_event_move (ECalendarView *cal_view, ECalViewMoveDirection direction)
resize_start_row++;
resize_end_row++;
start_dt = e_day_view_convert_grid_position_to_time (day_view, day, resize_start_row);
- end_dt = e_day_view_convert_grid_position_to_time (day_view, day, resize_end_row + 1);
+ end_dt = e_day_view_convert_grid_position_to_time (day_view, day, resize_end_row + 1);
break;
case E_CAL_VIEW_MOVE_LEFT:
- if (day <= 0)
+ if (day <= 0)
return TRUE;
start_dt = e_day_view_convert_grid_position_to_time (day_view, day, resize_start_row);
end_dt = e_day_view_convert_grid_position_to_time (day_view, day, resize_end_row + 1);
start_time = icaltime_from_timet (start_dt, 0);
end_time = icaltime_from_timet (end_dt, 0);
icaltime_adjust (&start_time ,-1,0,0,0);
- icaltime_adjust (&end_time ,-1,0,0,0);
+ icaltime_adjust (&end_time ,-1,0,0,0);
start_dt = icaltime_as_timet (start_time);
end_dt = icaltime_as_timet (end_time);
break;
@@ -7373,14 +7373,14 @@ e_day_view_event_move (ECalendarView *cal_view, ECalViewMoveDirection direction)
start_time = icaltime_from_timet (start_dt, 0);
end_time = icaltime_from_timet (end_dt, 0);
icaltime_adjust (&start_time ,1,0,0,0);
- icaltime_adjust (&end_time ,1,0,0,0);
+ icaltime_adjust (&end_time ,1,0,0,0);
start_dt = icaltime_as_timet (start_time);
end_dt = icaltime_as_timet (end_time);
- break;
+ break;
default:
return FALSE;
}
-
+
e_day_view_change_event_time (day_view, start_dt, end_dt);
e_day_view_ensure_rows_visible (day_view, resize_start_row, resize_end_row);
@@ -7421,7 +7421,7 @@ e_day_view_change_event_time (EDayView *day_view, time_t start_dt, time_t end_dt
/* FIXME: Should probably keep the timezone of the original start
and end times. */
date.tzid = icaltimezone_get_tzid (e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
-
+
*date.value = icaltime_from_timet_with_zone (start_dt, FALSE,
e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
e_cal_component_set_dtstart (comp, &date);
@@ -7430,12 +7430,12 @@ e_day_view_change_event_time (EDayView *day_view, time_t start_dt, time_t end_dt
e_cal_component_set_dtend (comp, &date);
e_cal_component_commit_sequence (comp);
-
+
if (day_view->last_edited_comp_string != NULL) {
g_free (day_view->last_edited_comp_string);
day_view->last_edited_comp_string = NULL;
}
-
+
day_view->last_edited_comp_string = e_cal_component_get_as_string (comp);
gnome_canvas_item_hide (day_view->resize_rect_item);
@@ -7456,13 +7456,13 @@ e_day_view_change_event_time (EDayView *day_view, time_t start_dt, time_t end_dt
e_cal_component_set_exrule_list (comp, NULL);
}
}
-
+
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (day_view)));
e_cal_component_commit_sequence (comp);
e_calendar_view_modify_and_send (comp, client, mod, toplevel, TRUE);
-out:
+out:
g_object_unref (comp);
}
#endif
@@ -7501,7 +7501,7 @@ e_day_view_change_event_time (EDayView *day_view, time_t start_dt, time_t end_dt
/* FIXME: Should probably keep the timezone of the original start
and end times. */
date.tzid = icaltimezone_get_tzid (e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
-
+
*date.value = icaltime_from_timet_with_zone (start_dt, FALSE,
e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
e_cal_component_set_dtstart (comp, &date);
@@ -7510,12 +7510,12 @@ e_day_view_change_event_time (EDayView *day_view, time_t start_dt, time_t end_dt
e_cal_component_set_dtend (comp, &date);
e_cal_component_commit_sequence (comp);
-
+
if (day_view->last_edited_comp_string != NULL) {
g_free (day_view->last_edited_comp_string);
day_view->last_edited_comp_string = NULL;
}
-
+
day_view->last_edited_comp_string = e_cal_component_get_as_string (comp);
day_view->resize_drag_pos = E_CALENDAR_VIEW_POS_NONE;
@@ -7533,18 +7533,18 @@ e_day_view_change_event_time (EDayView *day_view, time_t start_dt, time_t end_dt
e_cal_component_set_exrule_list (comp, NULL);
}
}
-
+
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (day_view)));
e_cal_component_commit_sequence (comp);
e_calendar_view_modify_and_send (comp, client, mod, toplevel, TRUE);
-out:
+out:
g_object_unref (comp);
}
#endif
-static void
+static void
e_day_view_change_event_end_time_up (EDayView *day_view)
{
EDayViewEvent *event;
@@ -7575,12 +7575,12 @@ e_day_view_change_event_end_time_up (EDayView *day_view)
}
-static void
+static void
e_day_view_change_event_end_time_down (EDayView *day_view)
{
EDayViewEvent *event;
gint day, event_num, resize_start_row, resize_end_row;
-
+
day = day_view->editing_event_day;
event_num = day_view->editing_event_num;
if ((day == -1) || (day == E_DAY_VIEW_LONG_EVENT))
@@ -7665,7 +7665,7 @@ e_day_view_on_editing_stopped (EDayView *day_view,
ECalComponent *comp;
ECal *client;
gboolean on_server;
-
+
/* Note: the item we are passed here isn't reliable, so we just stop
the edit of whatever item was being edited. We also receive this
event twice for some reason. */
@@ -7711,12 +7711,12 @@ e_day_view_on_editing_stopped (EDayView *day_view,
client = event->comp_data->client;
on_server = cal_comp_is_on_server (comp, client);
-
+
if (string_is_empty (text) && !on_server) {
const char *uid;
-
+
e_cal_component_get_uid (comp, &uid);
-
+
e_day_view_foreach_event_with_uid (day_view, uid,
e_day_view_remove_event_cb, NULL);
e_day_view_check_layout (day_view);
@@ -7796,12 +7796,12 @@ e_day_view_on_editing_stopped (EDayView *day_view,
e_cal_component_commit_sequence (comp);
}
}
-
+
/* FIXME When sending here, what exactly should we send? */
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (day_view)));
e_calendar_view_modify_and_send (comp, client, mod, toplevel, FALSE);
}
-
+
}
out:
@@ -7825,7 +7825,7 @@ e_day_view_on_editing_stopped (EDayView *day_view,
ECalComponent *comp;
ECal *client;
gboolean on_server;
-
+
/* Note: the item we are passed here isn't reliable, so we just stop
the edit of whatever item was being edited. We also receive this
event twice for some reason. */
@@ -7868,12 +7868,12 @@ e_day_view_on_editing_stopped (EDayView *day_view,
client = event->comp_data->client;
on_server = cal_comp_is_on_server (comp, client);
-
+
if (string_is_empty (text) && !on_server) {
const char *uid;
-
+
e_cal_component_get_uid (comp, &uid);
-
+
e_day_view_foreach_event_with_uid (day_view, uid,
e_day_view_remove_event_cb, NULL);
e_day_view_check_layout (day_view);
@@ -7953,12 +7953,12 @@ e_day_view_on_editing_stopped (EDayView *day_view,
e_cal_component_commit_sequence (comp);
}
}
-
+
/* FIXME When sending here, what exactly should we send? */
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (day_view)));
e_calendar_view_modify_and_send (comp, client, mod, toplevel, FALSE);
}
-
+
}
gtk_widget_queue_draw (day_view->main_canvas);
@@ -9095,14 +9095,14 @@ e_day_view_on_top_canvas_drag_data_received (GtkWidget *widget,
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (day_view)));
e_calendar_view_modify_and_send (comp, client, mod, toplevel, FALSE);
-
+
g_object_unref (comp);
return;
}
}
- if ((data->length >= 0) && (data->format == 8)
+ if ((data->length >= 0) && (data->format == 8)
&& !drag_from_same_window) {
/* We are dragging between different window */
@@ -9115,7 +9115,7 @@ e_day_view_on_top_canvas_drag_data_received (GtkWidget *widget,
pos = e_day_view_convert_position_in_top_canvas (day_view,
x, y, &day,
NULL);
- if (pos == E_CALENDAR_VIEW_POS_OUTSIDE)
+ if (pos == E_CALENDAR_VIEW_POS_OUTSIDE)
goto error;
comp_str = (char *) data->data;
@@ -9140,7 +9140,7 @@ e_day_view_on_top_canvas_drag_data_received (GtkWidget *widget,
while (subcomp) {
child_kind = icalcomponent_isa (subcomp);
if (child_kind == ICAL_VEVENT_COMPONENT)
- e_calendar_view_add_event (E_CALENDAR_VIEW (day_view), client, dtstart,
+ e_calendar_view_add_event (E_CALENDAR_VIEW (day_view), client, dtstart,
default_zone, subcomp, TRUE);
else if (child_kind == ICAL_VTIMEZONE_COMPONENT) {
icaltimezone *zone;
@@ -9148,10 +9148,10 @@ e_day_view_on_top_canvas_drag_data_received (GtkWidget *widget,
zone = icaltimezone_new ();
icaltimezone_set_component (zone, subcomp);
e_cal_add_timezone (client, zone, NULL);
-
+
icaltimezone_free (zone, 1);
}
-
+
subcomp = icalcomponent_get_next_component (
icalcomp, ICAL_ANY_COMPONENT);
}
@@ -9161,7 +9161,7 @@ e_day_view_on_top_canvas_drag_data_received (GtkWidget *widget,
} else {
e_calendar_view_add_event (E_CALENDAR_VIEW (day_view), client, dtstart, default_zone, icalcomp, TRUE);
}
-
+
gtk_drag_finish (context, TRUE, TRUE, time);
return;
}
@@ -9194,7 +9194,7 @@ e_day_view_on_main_canvas_drag_data_received (GtkWidget *widget,
if (day_view->drag_event_day != -1)
drag_from_same_window = TRUE;
- else
+ else
drag_from_same_window = FALSE;
client = e_cal_model_get_default_client (e_calendar_view_get_model (E_CALENDAR_VIEW (day_view)));
@@ -9256,7 +9256,7 @@ e_day_view_on_main_canvas_drag_data_received (GtkWidget *widget,
g_object_unref (comp);
return;
}
-
+
date.value = &itt;
date.tzid = icaltimezone_get_tzid (e_calendar_view_get_timezone (E_CALENDAR_VIEW (day_view)));
@@ -9304,7 +9304,7 @@ e_day_view_on_main_canvas_drag_data_received (GtkWidget *widget,
}
}
- if ((data->length >= 0) && (data->format == 8)
+ if ((data->length >= 0) && (data->format == 8)
&& !drag_from_same_window) {
/* We are dragging between different window */
@@ -9317,7 +9317,7 @@ e_day_view_on_main_canvas_drag_data_received (GtkWidget *widget,
pos = e_day_view_convert_position_in_main_canvas (day_view,
x, y, &day,
&row, NULL);
- if (pos == E_CALENDAR_VIEW_POS_OUTSIDE)
+ if (pos == E_CALENDAR_VIEW_POS_OUTSIDE)
goto error;
comp_str = (char *) data->data;
@@ -9342,7 +9342,7 @@ e_day_view_on_main_canvas_drag_data_received (GtkWidget *widget,
while (subcomp) {
child_kind = icalcomponent_isa (subcomp);
if (child_kind == ICAL_VEVENT_COMPONENT)
- e_calendar_view_add_event (E_CALENDAR_VIEW (day_view), client, dtstart,
+ e_calendar_view_add_event (E_CALENDAR_VIEW (day_view), client, dtstart,
default_zone, subcomp, FALSE);
else if (child_kind == ICAL_VTIMEZONE_COMPONENT) {
icaltimezone *zone;
@@ -9350,10 +9350,10 @@ e_day_view_on_main_canvas_drag_data_received (GtkWidget *widget,
zone = icaltimezone_new ();
icaltimezone_set_component (zone, subcomp);
e_cal_add_timezone (client, zone, NULL);
-
+
icaltimezone_free (zone, 1);
}
-
+
subcomp = icalcomponent_get_next_component (
icalcomp, ICAL_ANY_COMPONENT);
}
diff --git a/calendar/gui/e-day-view.h b/calendar/gui/e-day-view.h
index 7ee92005ba..b7fed463ca 100644
--- a/calendar/gui/e-day-view.h
+++ b/calendar/gui/e-day-view.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -379,7 +379,7 @@ struct _EDayView
/* The event for which a popup menu is being displayed, as above. */
gint popup_event_day;
gint popup_event_num;
-
+
/* The currently selected region. If selection_start_day is -1 there is
no current selection. If start_row or end_row is -1 then the
selection is in the top canvas. */
diff --git a/calendar/gui/e-itip-control.c b/calendar/gui/e-itip-control.c
index 3ba297b893..0142968b8a 100644
--- a/calendar/gui/e-itip-control.c
+++ b/calendar/gui/e-itip-control.c
@@ -64,7 +64,7 @@ struct _EItipControlPrivate {
GtkWidget *html;
ESourceList *source_lists[E_CAL_SOURCE_TYPE_LAST];
- GHashTable *ecals[E_CAL_SOURCE_TYPE_LAST];
+ GHashTable *ecals[E_CAL_SOURCE_TYPE_LAST];
ECal *current_ecal;
ECalSourceType type;
@@ -85,7 +85,7 @@ struct _EItipControlPrivate {
GtkWidget *widget;
gpointer pointer;
} vbox;
-
+
char *vcalendar;
ECalComponent *comp;
icalcomponent *main_comp;
@@ -129,9 +129,9 @@ static void
e_itip_control_class_init (EItipControlClass *klass)
{
GtkObjectClass *gtkobject_class;
-
+
gtkobject_class = GTK_OBJECT_CLASS (klass);
-
+
gtkobject_class->destroy = e_itip_control_destroy;
}
@@ -140,15 +140,15 @@ set_ok_sens (EItipControl *itip)
{
EItipControlPrivate *priv;
gboolean read_only = TRUE;
-
+
priv = itip->priv;
if (!priv->ok.widget)
return;
-
+
if (priv->current_ecal)
e_cal_is_read_only (priv->current_ecal, &read_only, NULL);
-
+
gtk_widget_set_sensitive (priv->ok.widget, priv->current_ecal != NULL && !read_only);
}
@@ -164,7 +164,7 @@ cal_opened_cb (ECal *ecal, ECalendarStatus status, gpointer data)
source_type = e_cal_get_source_type (ecal);
source = e_cal_get_source (ecal);
-
+
g_signal_handlers_disconnect_matched (ecal, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, cal_opened_cb, NULL);
if (status != E_CALENDAR_STATUS_OK) {
@@ -187,23 +187,23 @@ start_calendar_server (EItipControl *itip, ESource *source, ECalSourceType type,
icaltimezone *zone;
priv = itip->priv;
-
+
ecal = g_hash_table_lookup (priv->ecals[type], e_source_peek_uid (source));
if (ecal) {
priv->current_ecal = ecal;
set_ok_sens (itip);
- return ecal;
+ return ecal;
}
-
+
ecal = auth_new_cal_from_source (source, type);
-
+
zone = calendar_config_get_icaltimezone ();
e_cal_set_default_timezone (ecal, zone, NULL);
-
+
g_signal_connect (G_OBJECT (ecal), "cal_opened", G_CALLBACK (func), data);
g_hash_table_insert (priv->ecals[type], g_strdup (e_source_peek_uid (source)), ecal);
-
+
e_cal_open_async (ecal, TRUE);
return ecal;
@@ -214,7 +214,7 @@ start_calendar_server_by_uid (EItipControl *itip, const char *uid, ECalSourceTyp
{
EItipControlPrivate *priv;
int i;
-
+
priv = itip->priv;
for (i = 0; i < E_CAL_SOURCE_TYPE_LAST; i++) {
@@ -224,12 +224,12 @@ start_calendar_server_by_uid (EItipControl *itip, const char *uid, ECalSourceTyp
if (source)
return start_calendar_server (itip, source, type, cal_opened_cb, itip);
}
-
+
return NULL;
}
typedef struct {
- EItipControl *itip;
+ EItipControl *itip;
char *uid;
int count;
gboolean show_selector;
@@ -242,7 +242,7 @@ source_changed_cb (ESourceComboBox *escb, EItipControl *itip)
ESource *source;
source = e_source_combo_box_get_active (escb);
-
+
if (priv->ok.widget)
gtk_widget_set_sensitive (priv->ok.widget, FALSE);
@@ -262,9 +262,9 @@ find_cal_opened_cb (ECal *ecal, ECalendarStatus status, gpointer data)
source = e_cal_get_source (ecal);
priv = fd->itip->priv;
-
+
fd->count--;
-
+
g_signal_handlers_disconnect_matched (ecal, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, find_cal_opened_cb, NULL);
if (status != E_CALENDAR_STATUS_OK) {
@@ -275,7 +275,7 @@ find_cal_opened_cb (ECal *ecal, ECalendarStatus status, gpointer data)
if (e_cal_get_object (ecal, fd->uid, NULL, &icalcomp, NULL)) {
icalcomponent_free (icalcomp);
-
+
priv->current_ecal = ecal;
set_ok_sens (fd->itip);
}
@@ -296,8 +296,8 @@ find_cal_opened_cb (ECal *ecal, ECalendarStatus status, gpointer data)
default:
uid = NULL;
g_return_if_reached ();
- }
-
+ }
+
if (uid) {
source = e_source_list_peek_source_by_uid (priv->source_lists[priv->type], uid);
g_free (uid);
@@ -321,7 +321,7 @@ find_cal_opened_cb (ECal *ecal, ECalendarStatus status, gpointer data)
} else {
/* FIXME Display error message to user */
}
-
+
g_free (fd->uid);
g_free (fd);
}
@@ -336,23 +336,23 @@ find_server (EItipControl *itip, ECalComponent *comp, gboolean show_selector)
const char *uid;
priv = itip->priv;
-
+
e_cal_component_get_uid (comp, &uid);
groups = e_source_list_peek_groups (priv->source_lists[priv->type]);
for (l = groups; l; l = l->next) {
ESourceGroup *group;
GSList *sources, *m;
-
+
group = l->data;
sources = e_source_group_peek_sources (group);
for (m = sources; m; m = m->next) {
ESource *source;
ECal *ecal;
-
+
source = m->data;
-
+
if (!fd) {
fd = g_new0 (EItipControlFindData, 1);
fd->itip = itip;
@@ -361,8 +361,8 @@ find_server (EItipControl *itip, ECalComponent *comp, gboolean show_selector)
}
fd->count++;
/* Check this return too? */
- ecal = start_calendar_server (itip, source, priv->type, find_cal_opened_cb, fd);
- }
+ ecal = start_calendar_server (itip, source, priv->type, find_cal_opened_cb, fd);
+ }
}
}
@@ -374,7 +374,7 @@ cleanup_ecal (void *data)
/* Clean up any signals */
g_signal_handlers_disconnect_matched (ecal, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, cal_opened_cb, NULL);
g_signal_handlers_disconnect_matched (ecal, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, find_cal_opened_cb, NULL);
-
+
g_object_unref (ecal);
}
@@ -383,9 +383,9 @@ html_destroyed (gpointer data)
{
EItipControl *itip = data;
EItipControlPrivate *priv;
-
+
priv = itip->priv;
-
+
priv->html = NULL;
}
@@ -408,7 +408,7 @@ e_itip_control_init (EItipControl *itip)
priv->source_lists[E_CAL_SOURCE_TYPE_EVENT] = e_source_list_new_for_gconf_default ("/apps/evolution/calendar/sources");
priv->source_lists[E_CAL_SOURCE_TYPE_TODO] = e_source_list_new_for_gconf_default ("/apps/evolution/tasks/sources");
-
+
/* Initialize the ecal hashes */
for (i = 0; i < E_CAL_SOURCE_TYPE_LAST; i++)
priv->ecals[i] = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, cleanup_ecal);
@@ -421,10 +421,10 @@ e_itip_control_init (EItipControl *itip)
priv->delegator_name = NULL;
priv->my_address = NULL;
priv->view_only = 0;
-
+
/* Html Widget */
priv->html = gtk_html_new ();
- gtk_html_set_default_content_type (GTK_HTML (priv->html),
+ gtk_html_set_default_content_type (GTK_HTML (priv->html),
"text/html; charset=utf-8");
gtk_html_load_from_string (GTK_HTML (priv->html), " ", 1);
gtk_widget_show (priv->html);
@@ -494,32 +494,32 @@ e_itip_control_destroy (GtkObject *obj)
{
EItipControl *itip = E_ITIP_CONTROL (obj);
EItipControlPrivate *priv;
-
+
priv = itip->priv;
if (priv) {
int i;
clean_up (itip);
-
+
priv->accounts = NULL;
-
+
for (i = 0; i < E_CAL_SOURCE_TYPE_LAST; i++) {
if (priv->ecals[i]) {
g_hash_table_destroy (priv->ecals[i]);
priv->ecals[i] = NULL;
}
}
-
+
if (priv->html) {
g_signal_handlers_disconnect_matched (priv->html, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, itip);
g_object_weak_unref (G_OBJECT (priv->html), (GWeakNotify)html_destroyed, itip);
}
-
+
g_free (priv);
itip->priv = NULL;
}
-
+
(* GTK_OBJECT_CLASS (e_itip_control_parent_class)->destroy) (obj);
}
@@ -535,9 +535,9 @@ find_my_address (EItipControl *itip, icalcomponent *ical_comp, icalparameter_par
EItipControlPrivate *priv;
icalproperty *prop;
char *my_alt_address = NULL;
-
+
priv = itip->priv;
-
+
for (prop = icalcomponent_get_first_property (ical_comp, ICAL_ATTENDEE_PROPERTY);
prop != NULL;
prop = icalcomponent_get_next_property (ical_comp, ICAL_ATTENDEE_PROPERTY)) {
@@ -556,7 +556,7 @@ find_my_address (EItipControl *itip, icalcomponent *ical_comp, icalparameter_par
attendee = NULL;
attendee_clean = NULL;
}
-
+
param = icalproperty_get_first_parameter (prop, ICAL_CN_PARAMETER);
if (param != NULL) {
name = icalparameter_get_cn (param);
@@ -569,10 +569,10 @@ find_my_address (EItipControl *itip, icalcomponent *ical_comp, icalparameter_par
if (priv->delegator_address) {
char *delegator_clean;
-
+
delegator_clean = g_strdup (itip_strip_mailto (attendee));
delegator_clean = g_strstrip (delegator_clean);
-
+
/* If the mailer told us the address to use, use that */
if (delegator_clean != NULL
&& !g_ascii_strcasecmp (attendee_clean, delegator_clean)) {
@@ -590,7 +590,7 @@ find_my_address (EItipControl *itip, icalcomponent *ical_comp, icalparameter_par
it = e_list_get_iterator((EList *)priv->accounts);
while (e_iterator_is_valid(it)) {
const EAccount *account = e_iterator_get(it);
-
+
/* Check for a matching address */
if (attendee_clean != NULL
&& !g_ascii_strcasecmp (account->id->address, attendee_clean)) {
@@ -605,17 +605,17 @@ find_my_address (EItipControl *itip, icalcomponent *ical_comp, icalparameter_par
g_object_unref(it);
return;
}
-
+
/* Check for a matching cname to fall back on */
- if (name_clean != NULL
+ if (name_clean != NULL
&& !g_ascii_strcasecmp (account->id->name, name_clean))
my_alt_address = g_strdup (attendee_clean);
-
+
e_iterator_next(it);
}
g_object_unref(it);
}
-
+
g_free (attendee_clean);
g_free (name_clean);
}
@@ -654,7 +654,7 @@ find_attendee (icalcomponent *ical_comp, const char *address)
}
g_free (text);
}
-
+
return prop;
}
@@ -789,7 +789,7 @@ write_recurrence_piece (EItipControl *itip, ECalComponent *comp,
if (r->by_day[0] == ICAL_RECURRENCE_ARRAY_MAX) {
/* For Translators: In this can also be translated as "With the period of %d
week/weeks", where %d is a number. The entire sentence is of the form "Recurring:
- Every %d week/weeks" */
+ Every %d week/weeks" */
/* For Translators : 'Every week' is event Recurring every week */
/* For Translators : 'Every %d weeks' is event Recurring every %d weeks. %d is a digit */
sprintf (buffer, ngettext("Every week", "Every %d weeks", r->interval), r->interval);
@@ -837,7 +837,7 @@ write_recurrence_piece (EItipControl *itip, ECalComponent *comp,
size -= len;
/* For Translators: In this can also be translated as "With the period of %d
month/months", where %d is a number. The entire sentence is of the form "Recurring:
- Every %d month/months" */
+ Every %d month/months" */
/* For Translators : 'every month' is part of the sentence 'event recurring on the (nth) day of every month.' */
/* For Translators : 'every %d months' is part of the sentence 'event recurring on the (nth) day of every %d months.'
%d is a digit */
@@ -847,7 +847,7 @@ write_recurrence_piece (EItipControl *itip, ECalComponent *comp,
case ICAL_YEARLY_RECURRENCE:
/* For Translators: In this can also be translated as "With the period of %d
year/years", where %d is a number. The entire sentence is of the form "Recurring:
- Every %d year/years" */
+ Every %d year/years" */
/* For Translators : 'Every year' is event Recurring every year */
/* For Translators : 'Every %d years' is event Recurring every %d years. %d is a digit */
sprintf (buffer, ngettext("Every year", "Every %d years", r->interval), r->interval);
@@ -1035,7 +1035,7 @@ write_html (EItipControl *itip, const gchar *itip_desc, const gchar *itip_title,
if (priv->html == NULL)
return;
-
+
/* Html widget */
html_stream = gtk_html_begin (GTK_HTML (priv->html));
gtk_html_stream_printf (html_stream,
@@ -1101,9 +1101,9 @@ write_html (EItipControl *itip, const gchar *itip_desc, const gchar *itip_title,
else
html = g_strdup_printf (itip_desc, _("An unknown person"));
}
-
+
break;
-
+
case ICAL_METHOD_PUBLISH:
case ICAL_METHOD_ADD:
case ICAL_METHOD_CANCEL:
@@ -1146,28 +1146,28 @@ write_html (EItipControl *itip, const gchar *itip_desc, const gchar *itip_title,
g_free (str);
if (text.value)
g_free (html);
-
+
/* Location */
e_cal_component_get_location (priv->comp, &string);
if (string != NULL) {
html = e_text_to_html_full (string, E_TEXT_TO_HTML_CONVERT_NL, 0);
- gtk_html_stream_printf (html_stream, "<b>%s</b><br>%s<br><br>",
+ gtk_html_stream_printf (html_stream, "<b>%s</b><br>%s<br><br>",
_("Location:"), html);
g_free (html);
}
-
+
/* Status */
if (priv->method == ICAL_METHOD_REPLY) {
GSList *alist;
e_cal_component_get_attendee_list (priv->comp, &alist);
-
+
if (alist != NULL) {
ECalComponentAttendee *a = alist->data;
gtk_html_stream_printf (html_stream, "<b>%s</b><br>",
_("Status:"));
-
+
switch (a->status) {
case ICAL_PARTSTAT_ACCEPTED:
gtk_html_stream_printf (html_stream, "%s<br><br>",
@@ -1186,10 +1186,10 @@ write_html (EItipControl *itip, const gchar *itip_desc, const gchar *itip_title,
_("Unknown"));
}
}
-
+
e_cal_component_free_attendee_list (alist);
}
-
+
/* Description */
e_cal_component_get_description_list (priv->comp, &l);
if (l)
@@ -1214,7 +1214,7 @@ write_html (EItipControl *itip, const gchar *itip_desc, const gchar *itip_title,
gtk_html_write (GTK_HTML (priv->html), html_stream, options, strlen (options));
}
}
-
+
const_html = "</td></tr></table>";
gtk_html_write (GTK_HTML (priv->html), html_stream, const_html, strlen(const_html));
@@ -1259,7 +1259,7 @@ get_refresh_options (void)
static char*
get_cancel_options (gboolean found, icalcomponent_kind kind)
-{
+{
if (!found) {
switch (kind) {
case ICAL_VEVENT_COMPONENT:
@@ -1268,7 +1268,7 @@ get_cancel_options (gboolean found, icalcomponent_kind kind)
return g_strdup_printf ("<i>%s</i>", _("The task has been canceled, however it could not be found in your task lists"));
default:
g_return_val_if_reached (NULL);
- }
+ }
}
return g_strdup_printf ("<object classid=\"itip:cancel_options\"></object>");
@@ -1276,14 +1276,14 @@ get_cancel_options (gboolean found, icalcomponent_kind kind)
static ECalComponent *
-get_real_item (EItipControl *itip)
+get_real_item (EItipControl *itip)
{
EItipControlPrivate *priv;
ECalComponent *comp;
icalcomponent *icalcomp;
gboolean found = FALSE;
const char *uid;
-
+
priv = itip->priv;
e_cal_component_get_uid (priv->comp, &uid);
@@ -1306,13 +1306,13 @@ static void
adjust_item (EItipControl *itip, ECalComponent *comp)
{
ECalComponent *real_comp;
-
+
real_comp = get_real_item (itip);
if (real_comp != NULL) {
ECalComponentText text;
const char *string;
GSList *l;
-
+
e_cal_component_get_summary (real_comp, &text);
e_cal_component_set_summary (comp, &text);
e_cal_component_get_location (real_comp, &string);
@@ -1320,11 +1320,11 @@ adjust_item (EItipControl *itip, ECalComponent *comp)
e_cal_component_get_description_list (real_comp, &l);
e_cal_component_set_description_list (comp, l);
e_cal_component_free_text_list (l);
-
+
g_object_unref (real_comp);
} else {
ECalComponentText text = {_("Unknown"), NULL};
-
+
e_cal_component_set_summary (comp, &text);
}
}
@@ -1336,7 +1336,7 @@ show_current_event (EItipControl *itip)
const gchar *itip_title, *itip_desc;
char *options;
gboolean show_selector = FALSE;
-
+
priv = itip->priv;
priv->type = E_CAL_SOURCE_TYPE_EVENT;
@@ -1401,7 +1401,7 @@ show_current_event (EItipControl *itip)
if (priv->calendar_uid)
priv->current_ecal = start_calendar_server_by_uid (itip, priv->calendar_uid, priv->type);
- else
+ else
find_server (itip, priv->comp, show_selector);
}
@@ -1412,7 +1412,7 @@ show_current_todo (EItipControl *itip)
const gchar *itip_title, *itip_desc;
char *options;
gboolean show_selector = FALSE;
-
+
priv = itip->priv;
priv->type = E_CAL_SOURCE_TYPE_TODO;
@@ -1478,7 +1478,7 @@ show_current_todo (EItipControl *itip)
if (priv->calendar_uid)
priv->current_ecal = start_calendar_server_by_uid (itip, priv->calendar_uid, priv->type);
- else
+ else
find_server (itip, priv->comp, show_selector);
}
@@ -1529,7 +1529,7 @@ get_next (icalcompiter *iter)
if (ret == NULL)
break;
kind = icalcomponent_isa (ret);
- } while (ret != NULL
+ } while (ret != NULL
&& kind != ICAL_VEVENT_COMPONENT
&& kind != ICAL_VTODO_COMPONENT
&& kind != ICAL_VFREEBUSY_COMPONENT);
@@ -1549,7 +1549,7 @@ show_current (EItipControl *itip)
priv = itip->priv;
g_object_ref (itip);
-
+
if (priv->comp)
g_object_unref (priv->comp);
priv->current_ecal = NULL;
@@ -1573,7 +1573,7 @@ show_current (EItipControl *itip)
prop = icalcomponent_get_next_property (priv->ical_comp, ICAL_X_PROPERTY);
}
-
+
/* Strip out alarms for security purposes */
alarm_iter = icalcomponent_begin_component (priv->ical_comp, ICAL_VALARM_COMPONENT);
while ((alarm_comp = icalcompiter_deref (&alarm_iter)) != NULL) {
@@ -1615,10 +1615,10 @@ show_current (EItipControl *itip)
case CAL_MINUTES:
trigger.u.rel_duration.minutes = interval;
break;
- case CAL_HOURS:
+ case CAL_HOURS:
trigger.u.rel_duration.hours = interval;
break;
- case CAL_DAYS:
+ case CAL_DAYS:
trigger.u.rel_duration.days = interval;
break;
default:
@@ -1671,7 +1671,7 @@ e_itip_control_set_data (EItipControl *itip, const gchar *text)
gtk_html_load_from_string (GTK_HTML (priv->html), " ", 1);
return;
}
-
+
priv->vcalendar = g_strdup (text);
priv->top_level = e_cal_util_new_top_level ();
@@ -1709,7 +1709,7 @@ e_itip_control_set_data (EItipControl *itip, const gchar *text)
}
if (priv->ical_comp == NULL) {
- write_error_html (itip, _("The attachment has no viewable calendar items"));
+ write_error_html (itip, _("The attachment has no viewable calendar items"));
return;
}
@@ -1877,7 +1877,7 @@ change_status (icalcomponent *ical_comp, const char *address, icalparameter_part
icalproperty_add_parameter (prop, param);
} else {
icalparameter *param;
-
+
if (address != NULL) {
prop = icalproperty_new_attendee (address);
icalcomponent_add_property (ical_comp, prop);
@@ -1891,16 +1891,16 @@ change_status (icalcomponent *ical_comp, const char *address, icalparameter_part
EAccount *a;
a = itip_addresses_get_default ();
-
+
prop = icalproperty_new_attendee (a->id->address);
icalcomponent_add_property (ical_comp, prop);
-
+
param = icalparameter_new_cn (a->id->name);
- icalproperty_add_parameter (prop, param);
+ icalproperty_add_parameter (prop, param);
param = icalparameter_new_role (ICAL_ROLE_REQPARTICIPANT);
icalproperty_add_parameter (prop, param);
-
+
param = icalparameter_new_partstat (status);
icalproperty_add_parameter (prop, param);
}
@@ -1969,9 +1969,9 @@ update_attendee_status (EItipControl *itip)
const char *uid;
GtkWidget *dialog;
GError *error = NULL;
-
+
priv = itip->priv;
-
+
/* Obtain our version */
e_cal_component_get_uid (priv->comp, &uid);
if (e_cal_get_object (priv->current_ecal, uid, NULL, &icalcomp, NULL)) {
@@ -2027,7 +2027,7 @@ update_attendee_status (EItipControl *itip)
change_status (icalcomp,
itip_strip_mailto (a->value),
a->status);
- e_cal_component_rescan (comp);
+ e_cal_component_rescan (comp);
}
}
}
@@ -2074,7 +2074,7 @@ send_item (EItipControl *itip)
priv = itip->priv;
comp = get_real_item (itip);
-
+
if (comp != NULL) {
itip_send_comp (E_CAL_COMPONENT_METHOD_REQUEST, comp, priv->current_ecal, NULL, NULL, NULL);
g_object_unref (comp);
@@ -2181,32 +2181,32 @@ url_requested_cb (GtkHTML *html, const gchar *url, GtkHTMLStream *handle, gpoint
static void
option_activated_cb (GtkWidget *widget, gpointer data)
{
- EItipControl *itip = E_ITIP_CONTROL (data);
+ EItipControl *itip = E_ITIP_CONTROL (data);
EItipControlPrivate *priv;
-
+
priv = itip->priv;
priv->action = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (widget), ACTION_DATA));
}
static void
-add_option (EItipControl *itip, GtkWidget *menu, const char *text, char action)
+add_option (EItipControl *itip, GtkWidget *menu, const char *text, char action)
{
GtkWidget *item;
-
+
item = gtk_menu_item_new_with_label (text);
g_signal_connect (item, "activate", G_CALLBACK (option_activated_cb), itip);
g_object_set_data (G_OBJECT (item), ACTION_DATA, GINT_TO_POINTER ((int)action));
gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
gtk_widget_show (item);
-
+
}
static void
insert_boxes (GtkHTMLEmbedded *eb, EItipControl *itip)
{
EItipControlPrivate *priv;
-
+
priv = itip->priv;
priv->vbox.widget = gtk_vbox_new (FALSE, 12);
@@ -2222,39 +2222,39 @@ insert_boxes (GtkHTMLEmbedded *eb, EItipControl *itip)
}
static void
-insert_label (GtkWidget *hbox)
+insert_label (GtkWidget *hbox)
{
GtkWidget *label;
char *text;
-
+
text = g_strdup_printf ("<b>%s</b>", _("Choose an action:"));
label = gtk_label_new (NULL);
gtk_label_set_markup (GTK_LABEL (label), text);
g_free (text);
gtk_box_pack_start (GTK_BOX (hbox), label, FALSE, TRUE, 0);
- gtk_widget_show (label);
+ gtk_widget_show (label);
}
static void
rsvp_clicked_cb (GtkWidget *widget, gpointer data)
{
- EItipControl *itip = E_ITIP_CONTROL (data);
+ EItipControl *itip = E_ITIP_CONTROL (data);
EItipControlPrivate *priv;
-
+
priv = itip->priv;
priv->rsvp = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget));
}
static void
-insert_rsvp (GtkWidget *hbox, EItipControl *itip)
+insert_rsvp (GtkWidget *hbox, EItipControl *itip)
{
EItipControlPrivate *priv;
GtkWidget *btn;
priv = itip->priv;
-
+
/* To translators: RSVP means "please reply" */
btn = gtk_check_button_new_with_label ("RSVP");
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (btn), TRUE);
@@ -2263,15 +2263,15 @@ insert_rsvp (GtkWidget *hbox, EItipControl *itip)
g_signal_connect (btn, "clicked", G_CALLBACK (rsvp_clicked_cb), itip);
gtk_box_pack_start (GTK_BOX (hbox), btn, FALSE, TRUE, 0);
- gtk_widget_show (btn);
+ gtk_widget_show (btn);
}
static void
-insert_ok (GtkWidget *hbox, EItipControl *itip)
+insert_ok (GtkWidget *hbox, EItipControl *itip)
{
EItipControlPrivate *priv;
priv = itip->priv;
-
+
priv->ok.widget = gtk_button_new_from_stock (GTK_STOCK_OK);
g_object_add_weak_pointer (G_OBJECT (priv->ok.widget), &priv->ok.pointer);
@@ -2280,7 +2280,7 @@ insert_ok (GtkWidget *hbox, EItipControl *itip)
set_ok_sens (itip);
gtk_box_pack_start (GTK_BOX (hbox), priv->ok.widget, FALSE, TRUE, 0);
- gtk_widget_show (priv->ok.widget);
+ gtk_widget_show (priv->ok.widget);
}
static gboolean
@@ -2288,19 +2288,19 @@ publish_options_object (EItipControl *itip, GtkHTML *html, GtkHTMLEmbedded *eb)
{
EItipControlPrivate *priv;
GtkWidget *option, *menu;
-
+
priv = itip->priv;
insert_boxes (eb, itip);
insert_label (priv->hbox.widget);
option = gtk_option_menu_new ();
-
+
menu = gtk_menu_new ();
add_option (itip, menu, _("Update"), 'U');
priv->action = 'U';
-
+
gtk_option_menu_set_menu (GTK_OPTION_MENU (option), menu);
gtk_box_pack_start (GTK_BOX (priv->hbox.widget), option, FALSE, TRUE, 0);
@@ -2316,21 +2316,21 @@ request_options_object (EItipControl *itip, GtkHTML *html, GtkHTMLEmbedded *eb)
{
EItipControlPrivate *priv;
GtkWidget *option, *menu;
-
+
priv = itip->priv;
insert_boxes (eb, itip);
insert_label (priv->hbox.widget);
-
+
option = gtk_option_menu_new ();
-
+
menu = gtk_menu_new ();
add_option (itip, menu, _("Accept"), 'A');
add_option (itip, menu, _("Tentatively accept"), 'T');
add_option (itip, menu, _("Decline"), 'D');
priv->action = 'A';
-
+
gtk_option_menu_set_menu (GTK_OPTION_MENU (option), menu);
gtk_box_pack_start (GTK_BOX (priv->hbox.widget), option, FALSE, TRUE, 0);
@@ -2347,19 +2347,19 @@ freebusy_options_object (EItipControl *itip, GtkHTML *html, GtkHTMLEmbedded *eb)
{
EItipControlPrivate *priv;
GtkWidget *option, *menu;
-
+
priv = itip->priv;
insert_boxes (eb, itip);
insert_label (priv->hbox.widget);
option = gtk_option_menu_new ();
-
+
menu = gtk_menu_new ();
add_option (itip, menu, _("Send Free/Busy Information"), 'F');
priv->action = 'F';
-
+
gtk_option_menu_set_menu (GTK_OPTION_MENU (option), menu);
gtk_container_add (GTK_CONTAINER (priv->hbox.widget), option);
@@ -2375,19 +2375,19 @@ reply_options_object (EItipControl *itip, GtkHTML *html, GtkHTMLEmbedded *eb)
{
EItipControlPrivate *priv;
GtkWidget *option, *menu;
-
+
priv = itip->priv;
insert_boxes (eb, itip);
insert_label (priv->hbox.widget);
option = gtk_option_menu_new ();
-
+
menu = gtk_menu_new ();
add_option (itip, menu, _("Update respondent status"), 'R');
priv->action = 'R';
-
+
gtk_option_menu_set_menu (GTK_OPTION_MENU (option), menu);
gtk_container_add (GTK_CONTAINER (priv->hbox.widget), option);
@@ -2403,19 +2403,19 @@ refresh_options_object (EItipControl *itip, GtkHTML *html, GtkHTMLEmbedded *eb)
{
EItipControlPrivate *priv;
GtkWidget *option, *menu;
-
+
priv = itip->priv;
insert_boxes (eb, itip);
insert_label (priv->hbox.widget);
option = gtk_option_menu_new ();
-
+
menu = gtk_menu_new ();
add_option (itip, menu, _("Send Latest Information"), 'S');
priv->action = 'R';
-
+
gtk_option_menu_set_menu (GTK_OPTION_MENU (option), menu);
gtk_container_add (GTK_CONTAINER (priv->hbox.widget), option);
@@ -2431,19 +2431,19 @@ cancel_options_object (EItipControl *itip, GtkHTML *html, GtkHTMLEmbedded *eb)
{
EItipControlPrivate *priv;
GtkWidget *option, *menu;
-
+
priv = itip->priv;
insert_boxes (eb, itip);
insert_label (priv->hbox.widget);
option = gtk_option_menu_new ();
-
+
menu = gtk_menu_new ();
add_option (itip, menu, _("Cancel"), 'C');
priv->action = 'C';
-
+
gtk_option_menu_set_menu (GTK_OPTION_MENU (option), menu);
gtk_container_add (GTK_CONTAINER (priv->hbox.widget), option);
@@ -2455,7 +2455,7 @@ cancel_options_object (EItipControl *itip, GtkHTML *html, GtkHTMLEmbedded *eb)
}
static gboolean
-object_requested_cb (GtkHTML *html, GtkHTMLEmbedded *eb, gpointer data)
+object_requested_cb (GtkHTML *html, GtkHTMLEmbedded *eb, gpointer data)
{
EItipControl *itip = E_ITIP_CONTROL (data);
@@ -2471,7 +2471,7 @@ object_requested_cb (GtkHTML *html, GtkHTMLEmbedded *eb, gpointer data)
return refresh_options_object (itip, html, eb);
else if (!strcmp (eb->classid, "itip:cancel_options"))
return cancel_options_object (itip, html, eb);
-
+
return FALSE;
}
@@ -2492,7 +2492,7 @@ ok_clicked_cb (GtkWidget *widget, gpointer data)
update_item (itip);
break;
case 'A':
- status = change_status (priv->ical_comp, priv->my_address,
+ status = change_status (priv->ical_comp, priv->my_address,
ICAL_PARTSTAT_ACCEPTED);
if (status) {
e_cal_component_rescan (priv->comp);
@@ -2539,43 +2539,43 @@ ok_clicked_cb (GtkWidget *widget, gpointer data)
icalvalue *value;
const char *attendee;
GSList *l, *list = NULL;
-
+
comp = e_cal_component_clone (priv->comp);
if (comp == NULL)
return;
-
+
if (priv->my_address == NULL)
find_my_address (itip, priv->ical_comp, NULL);
g_return_if_fail (priv->my_address != NULL);
-
+
ical_comp = e_cal_component_get_icalcomponent (comp);
-
+
for (prop = icalcomponent_get_first_property (ical_comp, ICAL_ATTENDEE_PROPERTY);
prop != NULL;
prop = icalcomponent_get_next_property (ical_comp, ICAL_ATTENDEE_PROPERTY))
{
char *text;
-
+
value = icalproperty_get_value (prop);
if (!value)
continue;
-
+
attendee = icalvalue_get_string (value);
-
+
text = g_strdup (itip_strip_mailto (attendee));
text = g_strstrip (text);
if (g_ascii_strcasecmp (priv->my_address, text))
list = g_slist_prepend (list, prop);
g_free (text);
}
-
+
for (l = list; l; l = l->next) {
prop = l->data;
icalcomponent_remove_property (ical_comp, prop);
icalproperty_free (prop);
}
g_slist_free (list);
-
+
e_cal_component_rescan (comp);
itip_send_comp (E_CAL_COMPONENT_METHOD_REPLY, comp, priv->current_ecal, priv->top_level, NULL, NULL);
diff --git a/calendar/gui/e-itip-control.h b/calendar/gui/e-itip-control.h
index faab0cc8cd..82cc42376c 100644
--- a/calendar/gui/e-itip-control.h
+++ b/calendar/gui/e-itip-control.h
@@ -59,7 +59,7 @@ gint e_itip_control_get_data_size (EItipControl *itip);
void e_itip_control_set_from_address (EItipControl *itip,
const gchar *address);
const gchar *e_itip_control_get_from_address (EItipControl *itip);
-void e_itip_control_set_view_only (EItipControl *itip,
+void e_itip_control_set_view_only (EItipControl *itip,
gboolean view_only);
gboolean e_itip_control_get_view_only (EItipControl *itip);
void e_itip_control_set_delegator_address (EItipControl *itip,
diff --git a/calendar/gui/e-meeting-attendee.c b/calendar/gui/e-meeting-attendee.c
index 269fdf298e..2239ee1b46 100644
--- a/calendar/gui/e-meeting-attendee.c
+++ b/calendar/gui/e-meeting-attendee.c
@@ -42,7 +42,7 @@ struct _EMeetingAttendeePrivate {
gchar *delfrom;
icalparameter_partstat status;
-
+
gchar *sentby;
gchar *cn;
gchar *language;
@@ -58,7 +58,7 @@ struct _EMeetingAttendeePrivate {
EMeetingTime busy_periods_end;
gboolean start_busy_range_set;
gboolean end_busy_range_set;
-
+
gint longest_period_in_days;
};
@@ -98,16 +98,16 @@ string_test (gchar *string)
}
static gboolean
-string_is_set (gchar *string)
+string_is_set (gchar *string)
{
if (string != NULL && *string != '\0')
return TRUE;
-
+
return FALSE;
}
static void
-notify_changed (EMeetingAttendee *ia)
+notify_changed (EMeetingAttendee *ia)
{
g_signal_emit_by_name (G_OBJECT (ia), "changed");
}
@@ -131,16 +131,16 @@ e_meeting_attendee_init (EMeetingAttendee *ia)
priv->delto = string_test (NULL);
priv->delfrom = string_test (NULL);
-
+
priv->status = ICAL_PARTSTAT_NONE;
-
+
priv->sentby = string_test (NULL);
priv->cn = string_test (NULL);
priv->language = string_test (NULL);
priv->edit_level = E_MEETING_ATTENDEE_EDIT_FULL;
priv->has_calendar_info = FALSE;
-
+
priv->busy_periods = g_array_new (FALSE, FALSE, sizeof (EMeetingFreeBusyPeriod));
priv->busy_periods_sorted = FALSE;
@@ -154,7 +154,7 @@ e_meeting_attendee_init (EMeetingAttendee *ia)
priv->start_busy_range_set = FALSE;
priv->end_busy_range_set = FALSE;
-
+
priv->longest_period_in_days = 0;
}
@@ -177,9 +177,9 @@ e_meeting_attendee_finalize (GObject *obj)
g_free (priv->sentby);
g_free (priv->cn);
g_free (priv->language);
-
+
g_array_free (priv->busy_periods, TRUE);
-
+
g_free (priv);
if (G_OBJECT_CLASS (e_meeting_attendee_parent_class)->finalize)
@@ -196,7 +196,7 @@ GObject *
e_meeting_attendee_new_from_e_cal_component_attendee (ECalComponentAttendee *ca)
{
EMeetingAttendee *ia;
-
+
ia = E_MEETING_ATTENDEE (g_object_new (E_TYPE_MEETING_ATTENDEE, NULL));
e_meeting_attendee_set_address (ia, g_strdup (ca->value));
@@ -210,7 +210,7 @@ e_meeting_attendee_new_from_e_cal_component_attendee (ECalComponentAttendee *ca)
e_meeting_attendee_set_sentby (ia, g_strdup (ca->sentby));
e_meeting_attendee_set_cn (ia, g_strdup (ca->cn));
e_meeting_attendee_set_language (ia, g_strdup (ca->language));
-
+
return G_OBJECT (ia);
}
@@ -221,7 +221,7 @@ e_meeting_attendee_as_e_cal_component_attendee (EMeetingAttendee *ia)
ECalComponentAttendee *ca;
priv = ia->priv;
-
+
ca = g_new0 (ECalComponentAttendee, 1);
ca->value = priv->address;
@@ -243,9 +243,9 @@ const gchar *
e_meeting_attendee_get_fburi (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->fburi;
}
@@ -253,12 +253,12 @@ void
e_meeting_attendee_set_fburi (EMeetingAttendee *ia, gchar *fburi)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
if (priv->fburi != NULL)
g_free (priv->fburi);
-
+
priv->fburi = string_test (fburi);
notify_changed (ia);
@@ -268,9 +268,9 @@ const gchar *
e_meeting_attendee_get_address (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->address;
}
@@ -278,12 +278,12 @@ void
e_meeting_attendee_set_address (EMeetingAttendee *ia, gchar *address)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
if (priv->address != NULL)
g_free (priv->address);
-
+
priv->address = string_test (address);
notify_changed (ia);
@@ -293,9 +293,9 @@ gboolean
e_meeting_attendee_is_set_address (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return string_is_set (priv->address);
}
@@ -303,9 +303,9 @@ const gchar *
e_meeting_attendee_get_member (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->member;
}
@@ -313,12 +313,12 @@ void
e_meeting_attendee_set_member (EMeetingAttendee *ia, gchar *member)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
if (priv->member != NULL)
g_free (priv->member);
-
+
priv->member = string_test (member);
notify_changed (ia);
@@ -328,7 +328,7 @@ gboolean
e_meeting_attendee_is_set_member (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
return string_is_set (priv->member);
@@ -338,19 +338,19 @@ icalparameter_cutype
e_meeting_attendee_get_cutype (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->cutype;
}
-void
+void
e_meeting_attendee_set_cutype (EMeetingAttendee *ia, icalparameter_cutype cutype)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
priv->cutype = cutype;
notify_changed (ia);
@@ -360,9 +360,9 @@ icalparameter_role
e_meeting_attendee_get_role (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->role;
}
@@ -370,21 +370,21 @@ void
e_meeting_attendee_set_role (EMeetingAttendee *ia, icalparameter_role role)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
priv->role = role;
notify_changed (ia);
}
-gboolean
+gboolean
e_meeting_attendee_get_rsvp (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->rsvp;
}
@@ -392,9 +392,9 @@ void
e_meeting_attendee_set_rsvp (EMeetingAttendee *ia, gboolean rsvp)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
priv->rsvp = rsvp;
notify_changed (ia);
@@ -404,9 +404,9 @@ const gchar *
e_meeting_attendee_get_delto (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->delto;
}
@@ -414,12 +414,12 @@ void
e_meeting_attendee_set_delto (EMeetingAttendee *ia, gchar *delto)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
if (priv->delto != NULL)
g_free (priv->delto);
-
+
priv->delto = string_test (delto);
notify_changed (ia);
@@ -429,7 +429,7 @@ gboolean
e_meeting_attendee_is_set_delto (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
return string_is_set (priv->delto);
@@ -439,9 +439,9 @@ const gchar *
e_meeting_attendee_get_delfrom (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->delfrom;
}
@@ -449,12 +449,12 @@ void
e_meeting_attendee_set_delfrom (EMeetingAttendee *ia, gchar *delfrom)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
if (priv->delfrom != NULL)
g_free (priv->delfrom);
-
+
priv->delfrom = string_test (delfrom);
notify_changed (ia);
@@ -464,7 +464,7 @@ gboolean
e_meeting_attendee_is_set_delfrom (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
return string_is_set (priv->delfrom);
@@ -474,9 +474,9 @@ icalparameter_partstat
e_meeting_attendee_get_status (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->status;
}
@@ -484,9 +484,9 @@ void
e_meeting_attendee_set_status (EMeetingAttendee *ia, icalparameter_partstat status)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
priv->status = status;
notify_changed (ia);
@@ -496,9 +496,9 @@ const gchar *
e_meeting_attendee_get_sentby (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->sentby;
}
@@ -506,12 +506,12 @@ void
e_meeting_attendee_set_sentby (EMeetingAttendee *ia, gchar *sentby)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
if (priv->sentby != NULL)
g_free (priv->sentby);
-
+
priv->sentby = string_test (sentby);
notify_changed (ia);
@@ -521,7 +521,7 @@ gboolean
e_meeting_attendee_is_set_sentby (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
return string_is_set (priv->sentby);
@@ -531,9 +531,9 @@ const gchar *
e_meeting_attendee_get_cn (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->cn;
}
@@ -541,12 +541,12 @@ void
e_meeting_attendee_set_cn (EMeetingAttendee *ia, gchar *cn)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
if (priv->cn != NULL)
g_free (priv->cn);
-
+
priv->cn = string_test (cn);
notify_changed (ia);
@@ -556,7 +556,7 @@ gboolean
e_meeting_attendee_is_set_cn (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
return string_is_set (priv->cn);
@@ -566,9 +566,9 @@ const gchar *
e_meeting_attendee_get_language (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->language;
}
@@ -576,12 +576,12 @@ void
e_meeting_attendee_set_language (EMeetingAttendee *ia, gchar *language)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
if (priv->language != NULL)
g_free (priv->language);
-
+
priv->language = string_test (language);
notify_changed (ia);
@@ -591,7 +591,7 @@ gboolean
e_meeting_attendee_is_set_language (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
return string_is_set (priv->language);
@@ -601,7 +601,7 @@ EMeetingAttendeeType
e_meeting_attendee_get_atype (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
if (priv->cutype == ICAL_CUTYPE_ROOM
@@ -611,7 +611,7 @@ e_meeting_attendee_get_atype (EMeetingAttendee *ia)
if (priv->role == ICAL_ROLE_CHAIR
|| priv->role == ICAL_ROLE_REQPARTICIPANT)
return E_MEETING_ATTENDEE_REQUIRED_PERSON;
-
+
return E_MEETING_ATTENDEE_OPTIONAL_PERSON;
}
@@ -620,7 +620,7 @@ EMeetingAttendeeEditLevel
e_meeting_attendee_get_edit_level (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
g_return_val_if_fail (ia != NULL, E_MEETING_ATTENDEE_EDIT_NONE);
g_return_val_if_fail (E_IS_MEETING_ATTENDEE (ia), E_MEETING_ATTENDEE_EDIT_NONE);
@@ -629,11 +629,11 @@ e_meeting_attendee_get_edit_level (EMeetingAttendee *ia)
return priv->edit_level;
}
-void
+void
e_meeting_attendee_set_edit_level (EMeetingAttendee *ia, EMeetingAttendeeEditLevel level)
{
EMeetingAttendeePrivate *priv;
-
+
g_return_if_fail (ia != NULL);
g_return_if_fail (E_IS_MEETING_ATTENDEE (ia));
@@ -684,7 +684,7 @@ static void
ensure_periods_sorted (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
if (priv->busy_periods_sorted)
@@ -701,7 +701,7 @@ gboolean
e_meeting_attendee_get_has_calendar_info (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
return priv->has_calendar_info;
@@ -711,7 +711,7 @@ void
e_meeting_attendee_set_has_calendar_info (EMeetingAttendee *ia, gboolean has_calendar_info)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
priv->has_calendar_info = has_calendar_info;
@@ -721,12 +721,12 @@ const GArray *
e_meeting_attendee_get_busy_periods (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
ensure_periods_sorted (ia);
-
- return priv->busy_periods;
+
+ return priv->busy_periods;
}
gint
@@ -738,7 +738,7 @@ e_meeting_attendee_find_first_busy_period (EMeetingAttendee *ia, GDate *date)
GDate tmp_date;
priv = ia->priv;
-
+
/* Make sure the busy periods have been sorted. */
ensure_periods_sorted (ia);
@@ -756,12 +756,12 @@ e_meeting_attendee_find_first_busy_period (EMeetingAttendee *ia, GDate *date)
while (lower < upper) {
middle = (lower + upper) >> 1;
-
+
period = &g_array_index (priv->busy_periods,
EMeetingFreeBusyPeriod, middle);
cmp = g_date_compare (&tmp_date, &period->start.date);
-
+
if (cmp == 0)
break;
else if (cmp < 0)
@@ -793,7 +793,7 @@ e_meeting_attendee_find_first_busy_period (EMeetingAttendee *ia, GDate *date)
}
gboolean
-e_meeting_attendee_add_busy_period (EMeetingAttendee *ia,
+e_meeting_attendee_add_busy_period (EMeetingAttendee *ia,
gint start_year,
gint start_month,
gint start_day,
@@ -816,7 +816,7 @@ e_meeting_attendee_add_busy_period (EMeetingAttendee *ia,
g_return_val_if_fail (busy_type < E_MEETING_FREE_BUSY_LAST, FALSE);
priv = ia->priv;
-
+
/* Check the dates are valid. */
if (!g_date_valid_dmy (start_day, start_month, start_year))
return FALSE;
@@ -850,13 +850,13 @@ e_meeting_attendee_add_busy_period (EMeetingAttendee *ia,
if (!g_date_valid (&priv->busy_periods_start.date)) {
priv->busy_periods_start.date = period.start.date;
priv->busy_periods_start.hour = period.start.hour;
- priv->busy_periods_start.minute = period.start.minute;
+ priv->busy_periods_start.minute = period.start.minute;
} else {
switch (g_date_compare (&period.start.date, &priv->busy_periods_start.date)) {
case -1:
priv->busy_periods_start.date = period.start.date;
priv->busy_periods_start.hour = period.start.hour;
- priv->busy_periods_start.minute = period.start.minute;
+ priv->busy_periods_start.minute = period.start.minute;
break;
case 0:
if (period.start.hour < priv->busy_periods_start.hour
@@ -864,7 +864,7 @@ e_meeting_attendee_add_busy_period (EMeetingAttendee *ia,
&& period.start.minute < priv->busy_periods_start.minute)) {
priv->busy_periods_start.date = period.start.date;
priv->busy_periods_start.hour = period.start.hour;
- priv->busy_periods_start.minute = period.start.minute;
+ priv->busy_periods_start.minute = period.start.minute;
break;
}
break;
@@ -875,7 +875,7 @@ e_meeting_attendee_add_busy_period (EMeetingAttendee *ia,
if (!g_date_valid (&priv->busy_periods_end.date)) {
priv->busy_periods_end.date = period.end.date;
priv->busy_periods_end.hour = period.end.hour;
- priv->busy_periods_end.minute = period.end.minute;
+ priv->busy_periods_end.minute = period.end.minute;
} else {
switch (g_date_compare (&period.end.date, &priv->busy_periods_end.date)) {
case 0:
@@ -884,19 +884,19 @@ e_meeting_attendee_add_busy_period (EMeetingAttendee *ia,
&& period.end.minute > priv->busy_periods_end.minute)) {
priv->busy_periods_end.date = period.end.date;
priv->busy_periods_end.hour = period.end.hour;
- priv->busy_periods_end.minute = period.end.minute;
+ priv->busy_periods_end.minute = period.end.minute;
break;
}
break;
case 1:
priv->busy_periods_end.date = period.end.date;
priv->busy_periods_end.hour = period.end.hour;
- priv->busy_periods_end.minute = period.end.minute;
+ priv->busy_periods_end.minute = period.end.minute;
break;
}
}
}
-
+
g_array_append_val (priv->busy_periods, period);
priv->has_calendar_info = TRUE;
priv->busy_periods_sorted = FALSE;
@@ -911,7 +911,7 @@ EMeetingTime
e_meeting_attendee_get_start_busy_range (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
return priv->busy_periods_start;
@@ -921,9 +921,9 @@ EMeetingTime
e_meeting_attendee_get_end_busy_range (EMeetingAttendee *ia)
{
EMeetingAttendeePrivate *priv;
-
+
priv = ia->priv;
-
+
return priv->busy_periods_end;
}
@@ -936,11 +936,11 @@ e_meeting_attendee_set_start_busy_range (EMeetingAttendee *ia,
gint start_minute)
{
EMeetingAttendeePrivate *priv;
-
+
g_return_val_if_fail (E_IS_MEETING_ATTENDEE (ia), FALSE);
priv = ia->priv;
-
+
/* Check the dates are valid. */
if (!g_date_valid_dmy (start_day, start_month, start_year))
return FALSE;
@@ -956,7 +956,7 @@ e_meeting_attendee_set_start_busy_range (EMeetingAttendee *ia,
priv->busy_periods_start.minute = start_minute;
priv->start_busy_range_set = TRUE;
-
+
return TRUE;
}
@@ -969,11 +969,11 @@ e_meeting_attendee_set_end_busy_range (EMeetingAttendee *ia,
gint end_minute)
{
EMeetingAttendeePrivate *priv;
-
+
g_return_val_if_fail (E_IS_MEETING_ATTENDEE (ia), FALSE);
priv = ia->priv;
-
+
/* Check the dates are valid. */
if (!g_date_valid_dmy (end_day, end_month, end_year))
return FALSE;
@@ -989,7 +989,7 @@ e_meeting_attendee_set_end_busy_range (EMeetingAttendee *ia,
priv->busy_periods_end.minute = end_minute;
priv->end_busy_range_set = TRUE;
-
+
return TRUE;
}
@@ -1002,7 +1002,7 @@ e_meeting_attendee_clear_busy_periods (EMeetingAttendee *ia)
g_return_if_fail (E_IS_MEETING_ATTENDEE (ia));
priv = ia->priv;
-
+
g_array_set_size (priv->busy_periods, 0);
priv->busy_periods_sorted = TRUE;
diff --git a/calendar/gui/e-meeting-attendee.h b/calendar/gui/e-meeting-attendee.h
index 56f66123e5..5c8dc98e81 100644
--- a/calendar/gui/e-meeting-attendee.h
+++ b/calendar/gui/e-meeting-attendee.h
@@ -137,7 +137,7 @@ void e_meeting_attendee_set_fburi (EMeetingAttendee *ia, gchar *fburi);
const GArray *e_meeting_attendee_get_busy_periods (EMeetingAttendee *ia);
gint e_meeting_attendee_find_first_busy_period (EMeetingAttendee *ia, GDate *date);
-gboolean e_meeting_attendee_add_busy_period (EMeetingAttendee *ia,
+gboolean e_meeting_attendee_add_busy_period (EMeetingAttendee *ia,
gint start_year,
gint start_month,
gint start_day,
diff --git a/calendar/gui/e-meeting-list-view.c b/calendar/gui/e-meeting-list-view.c
index 235e988907..8d1a97208d 100644
--- a/calendar/gui/e-meeting-list-view.c
+++ b/calendar/gui/e-meeting-list-view.c
@@ -1,4 +1,4 @@
-/*
+/*
* e-meeting-list-view.c
*
* Authors: Mike Kestner <mkestner@ximian.com>
@@ -67,9 +67,9 @@ static guint e_meeting_list_view_signals[LAST_SIGNAL] = { 0 };
static void name_selector_dialog_close_cb (ENameSelectorDialog *dialog, gint response, gpointer data);
-static char *sections[] = {N_("Chair Persons"),
- N_("Required Participants"),
- N_("Optional Participants"),
+static char *sections[] = {N_("Chair Persons"),
+ N_("Required Participants"),
+ N_("Optional Participants"),
N_("Resources"),
NULL};
static icalparameter_role roles[] = {ICAL_ROLE_CHAIR,
@@ -111,14 +111,14 @@ e_meeting_list_view_class_init (EMeetingListViewClass *klass)
object_class->finalize = e_meeting_list_view_finalize;
- e_meeting_list_view_signals [ATTENDEE_ADDED] =
- g_signal_new ("attendee_added",
+ e_meeting_list_view_signals [ATTENDEE_ADDED] =
+ g_signal_new ("attendee_added",
G_TYPE_FROM_CLASS (klass),
G_SIGNAL_RUN_LAST,
G_STRUCT_OFFSET (EMeetingListViewClass, attendee_added),
NULL, NULL,
g_cclosure_marshal_VOID__POINTER,
- G_TYPE_NONE, 1,
+ G_TYPE_NONE, 1,
G_TYPE_POINTER);
}
@@ -142,7 +142,7 @@ e_meeting_list_view_init (EMeetingListView *view)
priv = g_new0 (EMeetingListViewPrivate, 1);
view->priv = priv;
-
+
priv->renderers = g_hash_table_new (g_direct_hash, g_int_equal);
priv->name_selector = e_name_selector_new ();
@@ -216,12 +216,12 @@ value_edited (GtkTreeView *view, gint col, const gchar *path, const gchar *text)
EMeetingStore *model = E_MEETING_STORE (gtk_tree_view_get_model (view));
GtkTreePath *treepath = gtk_tree_path_new_from_string (path);
int row = gtk_tree_path_get_indices (treepath)[0];
-
+
e_meeting_store_set_value (model, row, col, text);
gtk_tree_path_free (treepath);
}
-static guint
+static guint
get_index_from_role (icalparameter_role role)
{
switch (role) {
@@ -238,7 +238,7 @@ get_index_from_role (icalparameter_role role)
}
}
-void
+void
e_meeting_list_view_add_attendee_to_name_selector (EMeetingListView *view, EMeetingAttendee *ma)
{
EDestinationStore *destination_store;
@@ -260,7 +260,7 @@ e_meeting_list_view_add_attendee_to_name_selector (EMeetingListView *view, EMeet
g_object_unref (des);
}
-void
+void
e_meeting_list_view_remove_attendee_from_name_selector (EMeetingListView *view, EMeetingAttendee *ma)
{
GList *destinations, *l;
@@ -269,18 +269,18 @@ e_meeting_list_view_remove_attendee_from_name_selector (EMeetingListView *view,
const char *madd = NULL;
EMeetingListViewPrivate *priv;
guint i = 1;
-
+
priv = view->priv;
-
+
name_selector_model = e_name_selector_peek_model (priv->name_selector);
i = get_index_from_role (e_meeting_attendee_get_role (ma));
e_name_selector_model_peek_section (name_selector_model, sections [i],
NULL, &destination_store);
destinations = e_destination_store_list_destinations (destination_store);
madd = itip_strip_mailto (e_meeting_attendee_get_address (ma));
-
+
for (l = destinations; l; l = g_list_next (l)) {
- const char *attendee = NULL;
+ const char *attendee = NULL;
EDestination *des = l->data;
@@ -299,14 +299,14 @@ e_meeting_list_view_remove_attendee_from_name_selector (EMeetingListView *view,
}
} else {
attendee = e_destination_get_email (des);
-
+
if (madd && attendee && g_str_equal (madd, attendee)) {
attendee = e_destination_get_email (des);
e_destination_store_remove_destination (destination_store, des);
}
}
}
-
+
g_list_free (destinations);
}
@@ -327,13 +327,13 @@ attendee_edited_cb (GtkCellRenderer *renderer, const gchar *path, GList *address
for (l = addresses, m = names; l && m; l = l->next, m = m->next) {
char *name = m->data, *email = l->data;
-
- if (!((name && *name) || (email && *email)))
+
+ if (!((name && *name) || (email && *email)))
continue;
-
+
if (e_meeting_store_find_attendee (model, email, NULL) != NULL)
continue;
-
+
attendee = e_meeting_store_add_attendee_with_defaults (model);
e_meeting_attendee_set_address (attendee, g_strdup_printf ("MAILTO:%s", (char *)l->data));
e_meeting_attendee_set_cn (attendee, g_strdup (m->data));
@@ -354,7 +354,7 @@ attendee_edited_cb (GtkCellRenderer *renderer, const gchar *path, GList *address
existing_attendee);
e_meeting_store_remove_attendee (model, existing_attendee);
}
-
+
} else if (g_list_length (addresses) == 1) {
char *name = names->data, *email = addresses->data;
int existing_row;
@@ -385,7 +385,7 @@ attendee_edited_cb (GtkCellRenderer *renderer, const gchar *path, GList *address
} else {
if (existing_attendee) {
const char *address = e_meeting_attendee_get_address (existing_attendee);
-
+
if (address && *address)
return;
@@ -398,12 +398,12 @@ attendee_edited_cb (GtkCellRenderer *renderer, const gchar *path, GList *address
gtk_tree_path_free (treepath);
- if (!removed)
- g_signal_emit_by_name (G_OBJECT (view), "attendee_added", (gpointer) existing_attendee);
+ if (!removed)
+ g_signal_emit_by_name (G_OBJECT (view), "attendee_added", (gpointer) existing_attendee);
}
static void
-attendee_editing_canceled_cb (GtkCellRenderer *renderer, GtkTreeView *view)
+attendee_editing_canceled_cb (GtkCellRenderer *renderer, GtkTreeView *view)
{
EMeetingStore *model = E_MEETING_STORE (gtk_tree_view_get_model (view));
GtkTreePath *path;
@@ -414,14 +414,14 @@ attendee_editing_canceled_cb (GtkCellRenderer *renderer, GtkTreeView *view)
gtk_tree_view_get_cursor (view, &path, NULL);
if (!path)
return;
-
+
row = gtk_tree_path_get_indices (path)[0];
existing_attendee = e_meeting_store_find_attendee_at_row (model, row);
if (existing_attendee) {
if (!e_meeting_attendee_is_set_cn (existing_attendee) && !e_meeting_attendee_is_set_address (existing_attendee))
e_meeting_store_remove_attendee (model, existing_attendee);
}
-
+
gtk_tree_path_free (path);
}
@@ -472,7 +472,7 @@ build_table (EMeetingListView *lview)
GHashTable *edit_table;
GtkTreeViewColumn *col;
int pos;
-
+
priv = lview->priv;
edit_table = priv->renderers;
gtk_tree_view_set_headers_visible (view, TRUE);
@@ -493,8 +493,8 @@ build_table (EMeetingListView *lview)
g_object_set (col, "min-width", 50, NULL);
g_signal_connect (renderer, "cell_edited", G_CALLBACK (attendee_edited_cb), view);
g_signal_connect (renderer, "editing-canceled", G_CALLBACK (attendee_editing_canceled_cb), view);
- g_hash_table_insert (edit_table, GINT_TO_POINTER (E_MEETING_STORE_ATTENDEE_COL), renderer);
-
+ g_hash_table_insert (edit_table, GINT_TO_POINTER (E_MEETING_STORE_ATTENDEE_COL), renderer);
+
renderer = e_cell_renderer_combo_new ();
g_object_set (G_OBJECT (renderer), "list", get_type_strings (), "editable", TRUE, NULL);
pos = gtk_tree_view_insert_column_with_attributes (view, -1, _("Type"), renderer,
@@ -504,8 +504,8 @@ build_table (EMeetingListView *lview)
gtk_tree_view_column_set_resizable (col, TRUE);
gtk_tree_view_column_set_reorderable(col, TRUE);
g_signal_connect (renderer, "edited", G_CALLBACK (type_edited_cb), view);
- g_hash_table_insert (edit_table, GINT_TO_POINTER (E_MEETING_STORE_TYPE_COL), renderer);
-
+ g_hash_table_insert (edit_table, GINT_TO_POINTER (E_MEETING_STORE_TYPE_COL), renderer);
+
renderer = e_cell_renderer_combo_new ();
g_object_set (G_OBJECT (renderer), "list", get_role_strings (), "editable", TRUE, NULL);
pos = gtk_tree_view_insert_column_with_attributes (view, -1, _("Role"), renderer,
@@ -539,7 +539,7 @@ build_table (EMeetingListView *lview)
gtk_tree_view_column_set_reorderable(col, TRUE);
g_signal_connect (renderer, "edited", G_CALLBACK (status_edited_cb), view);
g_hash_table_insert (edit_table, GINT_TO_POINTER (E_MEETING_STORE_STATUS_COL), renderer);
-
+
priv->renderers = edit_table;
}
@@ -568,11 +568,11 @@ change_edit_cols_for_user (gpointer key, gpointer value, gpointer user_data)
}
}
-static void
+static void
change_edit_cols_for_organizer (gpointer key, gpointer value, gpointer user_data)
{
GtkCellRenderer *renderer = (GtkCellRenderer *) value;
- guint edit_level = GPOINTER_TO_INT (user_data);
+ guint edit_level = GPOINTER_TO_INT (user_data);
g_object_set (G_OBJECT (renderer), "editable", GINT_TO_POINTER (edit_level), NULL);
}
@@ -584,45 +584,45 @@ row_activated_cb (GtkTreeSelection *selection, EMeetingListView *view)
int row;
EMeetingAttendeeEditLevel el;
gint edit_level;
- GtkTreeModel *model;
+ GtkTreeModel *model;
GtkTreePath *path = NULL;
GList *paths=NULL;
priv = view->priv;
-
- if (!(paths = gtk_tree_selection_get_selected_rows (selection, &model)))
+
+ if (!(paths = gtk_tree_selection_get_selected_rows (selection, &model)))
return;
if (g_list_length (paths) > 1)
return;
path = g_list_nth_data (paths, 0);
if (!path)
return;
-
+
row = gtk_tree_path_get_indices (path)[0];
existing_attendee = e_meeting_store_find_attendee_at_row (priv->store, row);
el = e_meeting_attendee_get_edit_level (existing_attendee);
-
+
switch (el)
{
case E_MEETING_ATTENDEE_EDIT_NONE:
edit_level = FALSE;
g_hash_table_foreach (priv->renderers, change_edit_cols_for_organizer, GINT_TO_POINTER (edit_level));
break;
-
+
case E_MEETING_ATTENDEE_EDIT_FULL:
edit_level = TRUE;
g_hash_table_foreach (priv->renderers, change_edit_cols_for_organizer, GINT_TO_POINTER (edit_level));
break;
-
+
case E_MEETING_ATTENDEE_EDIT_STATUS:
edit_level = FALSE;
g_hash_table_foreach (priv->renderers, change_edit_cols_for_user, GINT_TO_POINTER (edit_level));
break;
}
-
+
}
-
+
EMeetingListView *
e_meeting_list_view_new (EMeetingStore *store)
@@ -664,7 +664,7 @@ e_meeting_list_view_edit (EMeetingListView *emlv, EMeetingAttendee *attendee)
EMeetingListViewPrivate *priv;
GtkTreePath *path;
GtkTreeViewColumn *focus_col;
-
+
priv = emlv->priv;
g_return_if_fail (emlv != NULL);
@@ -672,13 +672,13 @@ e_meeting_list_view_edit (EMeetingListView *emlv, EMeetingAttendee *attendee)
g_return_if_fail (attendee != NULL);
path = e_meeting_store_find_attendee_path (priv->store, attendee);
- focus_col = gtk_tree_view_get_column (GTK_TREE_VIEW (emlv), 0);
-
+ focus_col = gtk_tree_view_get_column (GTK_TREE_VIEW (emlv), 0);
+
if (path) {
gtk_tree_view_set_cursor (GTK_TREE_VIEW (emlv), path, focus_col, TRUE);
gtk_tree_path_free (path);
- }
+ }
}
static void
@@ -717,16 +717,16 @@ process_section (EMeetingListView *view, GList *destinations, icalparameter_role
break;
}
}
-
+
if (book) {
GList *contacts;
EContact *n_con = NULL;
char *qu;
EBookQuery *query;
- qu = g_strdup_printf ("(is \"full_name\" \"%s\")",
+ qu = g_strdup_printf ("(is \"full_name\" \"%s\")",
(char *) e_contact_get (contact, E_CONTACT_FULL_NAME));
- query = e_book_query_from_string (qu);
+ query = e_book_query_from_string (qu);
if (!e_book_get_contacts (book, query, &contacts, NULL)) {
g_warning ("Could not get contact from the book \n");
@@ -738,7 +738,7 @@ process_section (EMeetingListView *view, GList *destinations, icalparameter_role
e_destination_set_contact (des, n_con, 0);
list_dests = e_destination_list_get_dests (des);
- g_list_foreach (contacts, (GFunc) g_object_unref, NULL);
+ g_list_foreach (contacts, (GFunc) g_object_unref, NULL);
g_list_free (contacts);
}
@@ -752,14 +752,14 @@ process_section (EMeetingListView *view, GList *destinations, icalparameter_role
card_dest.data = destination;
list_dests = &card_dest;
}
- }
-
+ }
+
for (l = list_dests; l; l = l->next) {
EDestination *dest = l->data;
EContact *contact;
const char *name, *attendee = NULL;
char *attr = NULL, *fburi = NULL;
-
+
name = e_destination_get_name (dest);
/* Get the field as attendee from the backend */
@@ -786,12 +786,12 @@ process_section (EMeetingListView *view, GList *destinations, icalparameter_role
if (attendee == NULL || *attendee == '\0')
continue;
-
+
contact = e_destination_get_contact (dest);
- if (contact)
+ if (contact)
fburi = e_contact_get (contact, E_CONTACT_FREEBUSY_URL);
-
-
+
+
if (e_meeting_store_find_attendee (priv->store, attendee, NULL) == NULL) {
EMeetingAttendee *ia = e_meeting_store_add_attendee_with_defaults (priv->store);
@@ -800,7 +800,7 @@ process_section (EMeetingListView *view, GList *destinations, icalparameter_role
if (role == ICAL_ROLE_NONPARTICIPANT)
e_meeting_attendee_set_cutype (ia, ICAL_CUTYPE_RESOURCE);
e_meeting_attendee_set_cn (ia, g_strdup (name));
-
+
if (fburi)
e_meeting_attendee_set_fburi (ia, fburi);
} else {
@@ -816,7 +816,7 @@ process_section (EMeetingListView *view, GList *destinations, icalparameter_role
g_object_unref (des);
des = NULL;
}
-
+
}
}
@@ -841,10 +841,10 @@ name_selector_dialog_close_cb (ENameSelectorDialog *dialog, gint response, gpoin
name_selector_model = e_name_selector_peek_model (view->priv->name_selector);
store = E_MEETING_STORE (gtk_tree_view_get_model (GTK_TREE_VIEW (view)));
attendees = e_meeting_store_get_attendees (store);
-
+
/* get all the email ids of the attendees */
g_ptr_array_foreach ((GPtrArray *)attendees, (GFunc) add_to_list, &la);
-
+
for (i = 0; sections[i] != NULL; i++) {
EDestinationStore *destination_store;
GList *destinations;
@@ -886,7 +886,7 @@ e_meeting_list_view_invite_others_dialog (EMeetingListView *view)
gtk_widget_show (GTK_WIDGET (dialog));
}
-void
+void
e_meeting_list_view_set_editable (EMeetingListView *lview, gboolean set)
{
EMeetingListViewPrivate *priv = lview->priv;
@@ -896,24 +896,24 @@ e_meeting_list_view_set_editable (EMeetingListView *lview, gboolean set)
g_hash_table_foreach (priv->renderers, change_edit_cols_for_organizer, GINT_TO_POINTER (edit_level));
}
-ENameSelector *
-e_meeting_list_view_get_name_selector (EMeetingListView *lview)
+ENameSelector *
+e_meeting_list_view_get_name_selector (EMeetingListView *lview)
{
EMeetingListViewPrivate *priv;
-
+
g_return_val_if_fail (lview != NULL, NULL);
g_return_val_if_fail (E_IS_MEETING_LIST_VIEW (lview), NULL);
priv = lview->priv;
- return priv->name_selector;
+ return priv->name_selector;
}
void
e_meeting_list_view_set_name_selector (EMeetingListView *lview, ENameSelector *name_selector)
{
EMeetingListViewPrivate *priv;
-
+
g_return_if_fail (lview != NULL);
g_return_if_fail (E_IS_MEETING_LIST_VIEW (lview));
@@ -923,7 +923,7 @@ e_meeting_list_view_set_name_selector (EMeetingListView *lview, ENameSelector *n
g_object_unref (priv->name_selector);
priv->name_selector = NULL;
}
-
+
priv->name_selector = g_object_ref (name_selector);
}
diff --git a/calendar/gui/e-meeting-list-view.h b/calendar/gui/e-meeting-list-view.h
index fc49fe6014..f565381382 100644
--- a/calendar/gui/e-meeting-list-view.h
+++ b/calendar/gui/e-meeting-list-view.h
@@ -1,4 +1,4 @@
-/*
+/*
* e-meeting-list-view.h
*
* Author: Mike Kestner <mkestner@ximian.com>
diff --git a/calendar/gui/e-meeting-store.c b/calendar/gui/e-meeting-store.c
index 65a4930d57..2703836049 100644
--- a/calendar/gui/e-meeting-store.c
+++ b/calendar/gui/e-meeting-store.c
@@ -1,4 +1,4 @@
-/*
+/*
* e-meeting-store.c
*
* Copyright (C) 2001-2003 Ximian, Inc.
@@ -47,7 +47,7 @@ struct _EMeetingStorePrivate {
ECal *client;
icaltimezone *zone;
-
+
char *fb_uri;
GPtrArray *refresh_queue;
@@ -67,13 +67,13 @@ struct _EMeetingStoreQueueData {
EMeetingAttendee *attendee;
gboolean refreshing;
-
+
EMeetingTime start;
EMeetingTime end;
char buffer[BUF_SIZE];
GString *string;
-
+
GPtrArray *call_backs;
GPtrArray *data;
};
@@ -134,7 +134,7 @@ text_to_role (const char *role)
}
static char *
-role_to_text (icalparameter_role role)
+role_to_text (icalparameter_role role)
{
switch (role) {
case ICAL_ROLE_CHAIR:
@@ -160,7 +160,7 @@ text_to_boolean (const char *role)
}
static char *
-boolean_to_text (gboolean b)
+boolean_to_text (gboolean b)
{
if (b)
return _("Yes");
@@ -190,7 +190,7 @@ text_to_partstat (const char *partstat)
}
static char *
-partstat_to_text (icalparameter_partstat partstat)
+partstat_to_text (icalparameter_partstat partstat)
{
switch (partstat) {
case ICAL_PARTSTAT_NEEDSACTION:
@@ -290,7 +290,7 @@ get_path (GtkTreeModel *model, GtkTreeIter *iter)
gtk_tree_path_append_index (result, row);
return result;
}
-
+
static void
get_value (GtkTreeModel *model, GtkTreeIter *iter, int col, GValue *value)
{
@@ -303,13 +303,13 @@ get_value (GtkTreeModel *model, GtkTreeIter *iter, int col, GValue *value)
g_return_if_fail (col >= 0 && col < E_MEETING_STORE_COLUMN_COUNT);
row = GPOINTER_TO_INT (iter->user_data);
- store = E_MEETING_STORE (model);
+ store = E_MEETING_STORE (model);
g_return_if_fail (iter->stamp == store->priv->stamp);
g_return_if_fail (ROW_VALID (E_MEETING_STORE (model), row));
attendee = g_ptr_array_index (store->priv->attendees, row);
-
+
switch (col) {
case E_MEETING_STORE_ADDRESS_COL:
g_value_init (value, G_TYPE_STRING);
@@ -387,14 +387,14 @@ iter_children (GtkTreeModel *model, GtkTreeIter *iter, GtkTreeIter *parent)
g_return_val_if_fail (E_IS_MEETING_STORE (model), FALSE);
- store = E_MEETING_STORE (model);
+ store = E_MEETING_STORE (model);
if (parent || store->priv->attendees->len <= 0)
return FALSE;
iter->stamp = store->priv->stamp;
iter->user_data = GINT_TO_POINTER (0);
-
+
return TRUE;
}
@@ -408,7 +408,7 @@ static int
iter_n_children (GtkTreeModel *model, GtkTreeIter *iter)
{
g_return_val_if_fail (E_IS_MEETING_STORE (model), -1);
-
+
if (!iter)
return E_MEETING_STORE (model)->priv->attendees->len;
@@ -424,7 +424,7 @@ iter_nth_child (GtkTreeModel *model, GtkTreeIter *iter, GtkTreeIter *parent, int
g_return_val_if_fail (E_IS_MEETING_STORE (model), FALSE);
- store = E_MEETING_STORE (model);
+ store = E_MEETING_STORE (model);
if (parent || !ROW_VALID (store, n))
return FALSE;
@@ -477,7 +477,7 @@ e_meeting_store_set_value (EMeetingStore *store, int row, int col, const gchar *
e_meeting_attendee_set_cutype (attendee, text_to_type (val));
if (type == ICAL_CUTYPE_RESOURCE) {
e_meeting_attendee_set_role (attendee, ICAL_ROLE_NONPARTICIPANT);
- }
+ }
break;
case E_MEETING_STORE_ROLE_COL:
e_meeting_attendee_set_role (attendee, text_to_role (val));
@@ -504,13 +504,13 @@ e_meeting_store_set_value (EMeetingStore *store, int row, int col, const gchar *
}
static void
-refresh_queue_remove (EMeetingStore *store, EMeetingAttendee *attendee)
+refresh_queue_remove (EMeetingStore *store, EMeetingAttendee *attendee)
{
EMeetingStorePrivate *priv;
EMeetingStoreQueueData *qdata;
-
+
priv = store->priv;
-
+
/* Free the queue data */
qdata = g_hash_table_lookup (priv->refresh_data, itip_strip_mailto (e_meeting_attendee_get_address (attendee)));
if (qdata) {
@@ -533,12 +533,12 @@ ems_finalize (GObject *obj)
EMeetingStore *store = E_MEETING_STORE (obj);
EMeetingStorePrivate *priv;
int i;
-
+
priv = store->priv;
for (i = 0; i < priv->attendees->len; i++)
g_object_unref (g_ptr_array_index (priv->attendees, i));
- g_ptr_array_free (priv->attendees, TRUE);
+ g_ptr_array_free (priv->attendees, TRUE);
if (priv->client != NULL)
g_object_unref (priv->client);
@@ -547,7 +547,7 @@ ems_finalize (GObject *obj)
refresh_queue_remove (store, g_ptr_array_index (priv->refresh_queue, 0));
g_ptr_array_free (priv->refresh_queue, TRUE);
g_hash_table_destroy (priv->refresh_data);
-
+
if (priv->refresh_idle_id)
g_source_remove (priv->refresh_idle_id);
@@ -580,11 +580,11 @@ ems_init (EMeetingStore *store)
store->priv = priv;
priv->attendees = g_ptr_array_new ();
-
+
priv->zone = calendar_config_get_icaltimezone ();
priv->fb_uri = calendar_config_get_free_busy_template ();
-
+
priv->refresh_queue = g_ptr_array_new ();
priv->refresh_data = g_hash_table_new (g_str_hash, g_str_equal);
@@ -609,18 +609,18 @@ e_meeting_store_get_type (void)
sizeof (EMeetingStore),
0,
(GInstanceInitFunc) ems_init };
-
+
static const GInterfaceInfo tree_model_info = {
(GInterfaceInitFunc) ems_tree_model_init,
NULL,
NULL };
-
- ems_type = g_type_register_static (GTK_TYPE_LIST_STORE,
+
+ ems_type = g_type_register_static (GTK_TYPE_LIST_STORE,
"EMeetingStore",
&ems_info, 0);
-
- g_type_add_interface_static (ems_type,
- GTK_TYPE_TREE_MODEL,
+
+ g_type_add_interface_static (ems_type,
+ GTK_TYPE_TREE_MODEL,
&tree_model_info);
}
@@ -645,7 +645,7 @@ e_meeting_store_set_e_cal (EMeetingStore *store, ECal *client)
{
if (store->priv->client != NULL)
g_object_unref (store->priv->client);
-
+
if (client != NULL)
g_object_ref (client);
store->priv->client = client;
@@ -668,14 +668,14 @@ e_meeting_store_set_zone (EMeetingStore *store, icaltimezone *zone)
}
gchar *
-e_meeting_store_get_fb_uri (EMeetingStore *store)
+e_meeting_store_get_fb_uri (EMeetingStore *store)
{
g_return_val_if_fail (E_IS_MEETING_STORE (store), NULL);
return g_strdup (store->priv->fb_uri);
}
-void
+void
e_meeting_store_set_fb_uri (EMeetingStore *store, const gchar *fb_uri)
{
g_return_if_fail (E_IS_MEETING_STORE (store));
@@ -691,14 +691,14 @@ attendee_changed_cb (EMeetingAttendee *attendee, gpointer data)
GtkTreePath *path;
GtkTreeIter iter;
gint row = -1, i;
-
+
for (i = 0; i < store->priv->attendees->len; i++) {
if (attendee == g_ptr_array_index (store->priv->attendees, i)) {
row = i;
break;
}
}
-
+
if (row == -1)
return;
@@ -734,7 +734,7 @@ e_meeting_store_add_attendee_with_defaults (EMeetingStore *store)
{
EMeetingAttendee *attendee;
char *str;
-
+
attendee = E_MEETING_ATTENDEE (e_meeting_attendee_new ());
e_meeting_attendee_set_address (attendee, g_strdup (""));
@@ -745,11 +745,11 @@ e_meeting_store_add_attendee_with_defaults (EMeetingStore *store)
g_free (str);
str = g_strdup (_("Required Participant"));
e_meeting_attendee_set_role (attendee, text_to_role (str));
- g_free (str);
+ g_free (str);
str = g_strdup (_("Yes"));
e_meeting_attendee_set_rsvp (attendee, text_to_boolean (str));
g_free (str);
-
+
e_meeting_attendee_set_delto (attendee, g_strdup (""));
e_meeting_attendee_set_delfrom (attendee, g_strdup (""));
@@ -776,11 +776,11 @@ e_meeting_store_remove_attendee (EMeetingStore *store, EMeetingAttendee *attende
row = i;
break;
}
- }
-
+ }
+
if (row != -1) {
- g_ptr_array_remove_index (store->priv->attendees, row);
+ g_ptr_array_remove_index (store->priv->attendees, row);
g_object_unref (attendee);
path = gtk_tree_path_new ();
@@ -815,15 +815,15 @@ e_meeting_store_find_attendee (EMeetingStore *store, const gchar *address, gint
{
EMeetingAttendee *attendee;
int i;
-
+
if (address == NULL)
return NULL;
-
+
for (i = 0; i < store->priv->attendees->len; i++) {
const gchar *attendee_address;
-
+
attendee = g_ptr_array_index (store->priv->attendees, i);
-
+
attendee_address = e_meeting_attendee_get_address (attendee);
if (attendee_address && !g_ascii_strcasecmp (itip_strip_mailto (attendee_address), itip_strip_mailto (address))) {
if (row != NULL)
@@ -850,29 +850,29 @@ e_meeting_store_find_attendee_path (EMeetingStore *store, EMeetingAttendee *atte
{
GtkTreePath *path;
gint row = -1, i;
-
+
for (i = 0; i < store->priv->attendees->len; i++) {
if (attendee == g_ptr_array_index (store->priv->attendees, i)) {
row = i;
break;
}
}
-
+
if (row == -1)
return NULL;
path = gtk_tree_path_new ();
gtk_tree_path_append_index (path, row);
- return path;
+ return path;
}
-gint
+gint
e_meeting_store_count_actual_attendees (EMeetingStore *store)
{
g_return_val_if_fail (E_IS_MEETING_STORE (store), 0);
- return store->priv->attendees->len;
+ return store->priv->attendees->len;
}
const GPtrArray *
@@ -893,7 +893,7 @@ find_zone (icalproperty *ip, icalcomponent *tz_top_level)
if (tz_top_level == NULL)
return NULL;
-
+
param = icalproperty_get_first_parameter (ip, ICAL_TZID_PARAMETER);
if (param == NULL)
return NULL;
@@ -913,10 +913,10 @@ find_zone (icalproperty *ip, icalcomponent *tz_top_level)
zone = icaltimezone_new ();
clone = icalcomponent_new_clone (sub_comp);
icaltimezone_set_component (zone, clone);
-
+
return zone;
}
-
+
icalcompiter_next (&iter);
}
@@ -924,7 +924,7 @@ find_zone (icalproperty *ip, icalcomponent *tz_top_level)
}
static void
-process_callbacks (EMeetingStoreQueueData *qdata)
+process_callbacks (EMeetingStoreQueueData *qdata)
{
EMeetingStore *store;
int i;
@@ -937,7 +937,7 @@ process_callbacks (EMeetingStoreQueueData *qdata)
call_back = g_ptr_array_index (qdata->call_backs, i);
data = g_ptr_array_index (qdata->data, i);
-
+
g_idle_add ((GSourceFunc) call_back, data);
}
@@ -956,12 +956,12 @@ process_free_busy_comp (EMeetingAttendee *attendee,
icalcomponent *tz_top_level)
{
icalproperty *ip;
-
+
ip = icalcomponent_get_first_property (fb_comp, ICAL_DTSTART_PROPERTY);
if (ip != NULL) {
struct icaltimetype dtstart;
icaltimezone *ds_zone;
-
+
dtstart = icalproperty_get_dtstart (ip);
if (!dtstart.is_utc)
ds_zone = find_zone (ip, tz_top_level);
@@ -975,12 +975,12 @@ process_free_busy_comp (EMeetingAttendee *attendee,
dtstart.hour,
dtstart.minute);
}
-
+
ip = icalcomponent_get_first_property (fb_comp, ICAL_DTEND_PROPERTY);
if (ip != NULL) {
struct icaltimetype dtend;
icaltimezone *de_zone;
-
+
dtend = icalproperty_get_dtend (ip);
if (!dtend.is_utc)
de_zone = find_zone (ip, tz_top_level);
@@ -994,19 +994,19 @@ process_free_busy_comp (EMeetingAttendee *attendee,
dtend.hour,
dtend.minute);
}
-
+
ip = icalcomponent_get_first_property (fb_comp, ICAL_FREEBUSY_PROPERTY);
while (ip != NULL) {
icalparameter *param;
struct icalperiodtype fb;
EMeetingFreeBusyType busy_type = E_MEETING_FREE_BUSY_LAST;
icalparameter_fbtype fbtype = ICAL_FBTYPE_BUSY;
-
+
fb = icalproperty_get_freebusy (ip);
param = icalproperty_get_first_parameter (ip, ICAL_FBTYPE_PARAMETER);
if (param != NULL)
fbtype = icalparameter_get_fbtype (param);
-
+
switch (fbtype) {
case ICAL_FBTYPE_BUSY:
busy_type = E_MEETING_FREE_BUSY_BUSY;
@@ -1023,7 +1023,7 @@ process_free_busy_comp (EMeetingAttendee *attendee,
default:
break;
}
-
+
if (busy_type != E_MEETING_FREE_BUSY_LAST) {
icaltimezone *utc_zone = icaltimezone_get_utc_timezone ();
@@ -1042,7 +1042,7 @@ process_free_busy_comp (EMeetingAttendee *attendee,
fb.end.minute,
busy_type);
}
-
+
ip = icalcomponent_get_next_property (fb_comp, ICAL_FREEBUSY_PROPERTY);
}
}
@@ -1065,19 +1065,19 @@ process_free_busy (EMeetingStoreQueueData *qdata, char *text)
}
kind = icalcomponent_isa (main_comp);
- if (kind == ICAL_VCALENDAR_COMPONENT) {
+ if (kind == ICAL_VCALENDAR_COMPONENT) {
icalcompiter iter;
icalcomponent *tz_top_level, *sub_comp;
tz_top_level = e_cal_util_new_top_level ();
-
+
iter = icalcomponent_begin_component (main_comp, ICAL_VTIMEZONE_COMPONENT);
while ((sub_comp = icalcompiter_deref (&iter)) != NULL) {
icalcomponent *clone;
-
+
clone = icalcomponent_new_clone (sub_comp);
icalcomponent_add_component (tz_top_level, clone);
-
+
icalcompiter_next (&iter);
}
@@ -1091,15 +1091,15 @@ process_free_busy (EMeetingStoreQueueData *qdata, char *text)
} else if (kind == ICAL_VFREEBUSY_COMPONENT) {
process_free_busy_comp (attendee, main_comp, priv->zone, NULL);
}
-
+
icalcomponent_free (main_comp);
process_callbacks (qdata);
}
-/*
- * Replace all instances of from_value in string with to_value
- * In the returned newly allocated string.
+/*
+ * Replace all instances of from_value in string with to_value
+ * In the returned newly allocated string.
*/
static gchar *
replace_string (gchar *string, gchar *from_value, gchar *to_value)
@@ -1142,13 +1142,13 @@ freebusy_async (gpointer data)
GnomeVFSAsyncHandle *handle;
if (fbd->client) {
- /* FIXME this a work around for getting all th free busy information for the users
+ /* FIXME this a work around for getting all th free busy information for the users
we should be able to get free busy asynchronously */
- g_static_mutex_lock (&mutex);
+ g_static_mutex_lock (&mutex);
priv->num_queries++;
e_cal_get_free_busy (fbd->client, fbd->users, fbd->startt, fbd->endt, &(fbd->fb_data), NULL);
priv->num_queries--;
- g_static_mutex_unlock (&mutex);
+ g_static_mutex_unlock (&mutex);
g_list_foreach (fbd->users, (GFunc)g_free, NULL);
g_list_free (fbd->users);
@@ -1156,7 +1156,7 @@ freebusy_async (gpointer data)
if (fbd->fb_data != NULL) {
ECalComponent *comp = fbd->fb_data->data;
char *comp_str;
-
+
comp_str = e_cal_component_get_as_string (comp);
process_free_busy (fbd->qdata, comp_str);
g_free (comp_str);
@@ -1177,14 +1177,14 @@ freebusy_async (gpointer data)
if (fburi) {
priv->num_queries++;
- gnome_vfs_async_open (&handle, fburi, GNOME_VFS_OPEN_READ,
- GNOME_VFS_PRIORITY_DEFAULT, start_async_read,
+ gnome_vfs_async_open (&handle, fburi, GNOME_VFS_OPEN_READ,
+ GNOME_VFS_PRIORITY_DEFAULT, start_async_read,
fbd->qdata);
g_free (fburi);
} else if (default_fb_uri != NULL && !g_str_equal (default_fb_uri, "")) {
gchar *tmp_fb_uri;
gchar **split_email;
-
+
split_email = g_strsplit (fbd->email, "@", 2);
tmp_fb_uri = replace_string (default_fb_uri, USER_SUB, split_email[0]);
@@ -1192,10 +1192,10 @@ freebusy_async (gpointer data)
default_fb_uri = replace_string (tmp_fb_uri, DOMAIN_SUB, split_email[1]);
priv->num_queries++;
- gnome_vfs_async_open (&handle, default_fb_uri, GNOME_VFS_OPEN_READ,
- GNOME_VFS_PRIORITY_DEFAULT, start_async_read,
+ gnome_vfs_async_open (&handle, default_fb_uri, GNOME_VFS_OPEN_READ,
+ GNOME_VFS_PRIORITY_DEFAULT, start_async_read,
fbd->qdata);
-
+
g_free (tmp_fb_uri);
g_strfreev (split_email);
g_free (default_fb_uri);
@@ -1212,7 +1212,7 @@ freebusy_async (gpointer data)
static gboolean
refresh_busy_periods (gpointer data)
-{
+{
EMeetingStore *store = E_MEETING_STORE (data);
EMeetingStorePrivate *priv;
EMeetingAttendee *attendee = NULL;
@@ -1221,7 +1221,7 @@ refresh_busy_periods (gpointer data)
GThread *thread;
GError *error = NULL;
FreeBusyAsyncData *fbd;
-
+
priv = store->priv;
/* Check to see if there are any remaining attendees in the queue */
@@ -1242,27 +1242,27 @@ refresh_busy_periods (gpointer data)
priv->refresh_idle_id = 0;
return FALSE;
}
-
+
/* Indicate we are trying to refresh it */
qdata->refreshing = TRUE;
/* We take a ref in case we get destroyed in the gui during a callback */
g_object_ref (qdata->store);
-
+
fbd = g_new0 (FreeBusyAsyncData, 1);
fbd->client = priv->client;
fbd->attendee = attendee;
fbd->users = NULL;
- fbd->fb_data = NULL;
+ fbd->fb_data = NULL;
fbd->qdata = qdata;
fbd->fb_uri = priv->fb_uri;
fbd->store = store;
fbd->email = g_strdup (itip_strip_mailto (e_meeting_attendee_get_address (attendee)));
- /* Check the server for free busy data */
+ /* Check the server for free busy data */
if (priv->client) {
struct icaltimetype itt;
-
+
itt = icaltime_null_time ();
itt.year = g_date_get_year (&qdata->start.date);
itt.month = g_date_get_month (&qdata->start.date);
@@ -1308,13 +1308,13 @@ refresh_busy_periods (gpointer data)
return TRUE;
}
-
+
static void
refresh_queue_add (EMeetingStore *store, int row,
EMeetingTime *start,
EMeetingTime *end,
EMeetingStoreRefreshCallback call_back,
- gpointer data)
+ gpointer data)
{
EMeetingStorePrivate *priv;
EMeetingAttendee *attendee;
@@ -1330,7 +1330,7 @@ refresh_queue_add (EMeetingStore *store, int row,
/* check the queue if the attendee is already in there*/
for (i = 0; i < priv->refresh_queue->len; i++) {
if (attendee == g_ptr_array_index (priv->refresh_queue, i))
- return;
+ return;
if (!strcmp (e_meeting_attendee_get_address (attendee), e_meeting_attendee_get_address (g_ptr_array_index (priv->refresh_queue, i))))
return;
@@ -1399,16 +1399,16 @@ async_read (GnomeVFSAsyncHandle *handle,
gnome_vfs_async_close (handle, async_close, qdata);
return;
}
-
+
((char *)buffer)[read] = '\0';
qdata->string = g_string_append (qdata->string, buffer);
-
+
if (result == GNOME_VFS_ERROR_EOF) {
gnome_vfs_async_close (handle, async_close, qdata);
return;
}
- gnome_vfs_async_read (handle, qdata->buffer, buf_size, async_read, qdata);
+ gnome_vfs_async_read (handle, qdata->buffer, buf_size, async_read, qdata);
}
static void
@@ -1438,14 +1438,14 @@ e_meeting_store_refresh_all_busy_periods (EMeetingStore *store,
gpointer data)
{
int i;
-
+
g_return_if_fail (E_IS_MEETING_STORE (store));
-
+
for (i = 0; i < store->priv->attendees->len; i++)
refresh_queue_add (store, i, start, end, call_back, data);
}
-void
+void
e_meeting_store_refresh_busy_periods (EMeetingStore *store,
int row,
EMeetingTime *start,
diff --git a/calendar/gui/e-meeting-store.h b/calendar/gui/e-meeting-store.h
index d3998b033b..7f111f4676 100644
--- a/calendar/gui/e-meeting-store.h
+++ b/calendar/gui/e-meeting-store.h
@@ -1,4 +1,4 @@
-/*
+/*
* e-meeting-store.h
*
* Copyright (C) 2003 Ximian, Inc.
diff --git a/calendar/gui/e-meeting-time-sel-item.c b/calendar/gui/e-meeting-time-sel-item.c
index e1de77024d..211d4c71bd 100644
--- a/calendar/gui/e-meeting-time-sel-item.c
+++ b/calendar/gui/e-meeting-time-sel-item.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@gtk.org>
*
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -132,7 +132,7 @@ static void
e_meeting_time_selector_item_init (EMeetingTimeSelectorItem *mts_item)
{
GnomeCanvasItem *item = GNOME_CANVAS_ITEM (mts_item);
-
+
mts_item->mts = NULL;
mts_item->main_gc = NULL;
@@ -182,7 +182,7 @@ e_meeting_time_selector_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
EMeetingTimeSelectorItem *mts_item;
mts_item = E_MEETING_TIME_SELECTOR_ITEM (o);
-
+
switch (arg_id){
case ARG_MEETING_TIME_SELECTOR:
mts_item->mts = GTK_VALUE_POINTER (*arg);
@@ -281,7 +281,7 @@ e_meeting_time_selector_item_draw (GnomeCanvasItem *item, GdkDrawable *drawable,
gdk_cairo_set_source_color (cr, &mts->all_attendees_bg_color);
cairo_rectangle (cr, 0, mts->row_height * 2 - y,
width, mts->row_height);
- cairo_fill (cr);
+ cairo_fill (cr);
} else {
gdk_cairo_set_source_color (cr, &mts->bg_color);
cairo_rectangle (cr, 0, 0, width, height);
@@ -300,11 +300,11 @@ e_meeting_time_selector_item_draw (GnomeCanvasItem *item, GdkDrawable *drawable,
gdk_cairo_set_source_color (cr, &mts->meeting_time_bg_color);
if (is_display_top){
cairo_rectangle (cr, meeting_start_x + 1 - x, mts->row_height * 2 - y,
- meeting_end_x - meeting_start_x - 2, mts->row_height);
+ meeting_end_x - meeting_start_x - 2, mts->row_height);
cairo_fill (cr);
} else {
cairo_rectangle (cr, meeting_start_x + 1 - x, 0,
- meeting_end_x - meeting_start_x - 2, height);
+ meeting_end_x - meeting_start_x - 2, height);
cairo_fill (cr);
}
cairo_restore (cr);
@@ -671,7 +671,7 @@ e_meeting_time_selector_item_paint_busy_periods (EMeetingTimeSelectorItem *mts_i
gdk_gc_set_foreground (gc, &mts->busy_colors[busy_type]);
red = mts->busy_colors[busy_type].red;
green = mts->busy_colors[busy_type].green;
- blue = mts->busy_colors[busy_type].blue;
+ blue = mts->busy_colors[busy_type].blue;
cairo_set_source_rgba (cr, red/cc, green/cc, blue/cc, 0.8);
e_meeting_time_selector_item_paint_attendee_busy_periods (mts_item, drawable, x, y, width, row, first_period, busy_type, cr);
}
@@ -920,7 +920,7 @@ e_meeting_time_selector_item_button_press (EMeetingTimeSelectorItem *mts_item,
end_time = start_time;
g_date_add_days (&end_time.date, 1);
}
-
+
/* Fix any overflows. */
e_meeting_time_selector_fix_time_overflows (&end_time);
@@ -1047,11 +1047,11 @@ e_meeting_time_selector_item_calculate_busy_range (EMeetingTimeSelector *mts,
EMeetingAttendee *ia;
EMeetingTime busy_periods_start;
EMeetingTime busy_periods_end;
-
+
ia = e_meeting_store_find_attendee_at_row (mts->model, row);
busy_periods_start = e_meeting_attendee_get_start_busy_range (ia);
busy_periods_end = e_meeting_attendee_get_end_busy_range (ia);
-
+
*start_x = -1;
*end_x = -1;
@@ -1066,7 +1066,7 @@ e_meeting_time_selector_item_calculate_busy_range (EMeetingTimeSelector *mts,
return TRUE;
}
-void
+void
e_meeting_time_selector_item_set_normal_cursor (EMeetingTimeSelectorItem *mts_item)
{
g_return_if_fail (IS_E_MEETING_TIME_SELECTOR_ITEM (mts_item));
diff --git a/calendar/gui/e-meeting-time-sel-item.h b/calendar/gui/e-meeting-time-sel-item.h
index e4cf050f80..1ef96699d2 100644
--- a/calendar/gui/e-meeting-time-sel-item.h
+++ b/calendar/gui/e-meeting-time-sel-item.h
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@gtk.org>
*
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-meeting-time-sel.c b/calendar/gui/e-meeting-time-sel.c
index 035ddaaa4e..cadb1d3c9a 100644
--- a/calendar/gui/e-meeting-time-sel.c
+++ b/calendar/gui/e-meeting-time-sel.c
@@ -1,15 +1,15 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Authors :
+/*
+ * Authors :
* Damon Chaplin <damon@gtk.org>
* Rodrigo Moya <rodrigo@novell.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 2004, Novell, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -69,22 +69,22 @@
/* An array of hour strings for 24 hour time, "0:00" .. "23:00". */
const gchar *EMeetingTimeSelectorHours[24] = {
- "0:00", "1:00", "2:00", "3:00", "4:00", "5:00", "6:00", "7:00",
- "8:00", "9:00", "10:00", "11:00", "12:00", "13:00", "14:00", "15:00",
+ "0:00", "1:00", "2:00", "3:00", "4:00", "5:00", "6:00", "7:00",
+ "8:00", "9:00", "10:00", "11:00", "12:00", "13:00", "14:00", "15:00",
"16:00", "17:00", "18:00", "19:00", "20:00", "21:00", "22:00", "23:00"
};
/* An array of hour strings for 12 hour time, "12:00am" .. "11:00pm". */
const gchar *EMeetingTimeSelectorHours12[24] = {
- "12:00am", "1:00am", "2:00am", "3:00am", "4:00am", "5:00am", "6:00am",
- "7:00am", "8:00am", "9:00am", "10:00am", "11:00am", "12:00pm",
+ "12:00am", "1:00am", "2:00am", "3:00am", "4:00am", "5:00am", "6:00am",
+ "7:00am", "8:00am", "9:00am", "10:00am", "11:00am", "12:00pm",
"1:00pm", "2:00pm", "3:00pm", "4:00pm", "5:00pm", "6:00pm", "7:00pm",
"8:00pm", "9:00pm", "10:00pm", "11:00pm"
};
/* The number of days shown in the entire canvas. */
-#define E_MEETING_TIME_SELECTOR_DAYS_SHOWN 35
-#define E_MEETING_TIME_SELECTOR_DAYS_START_BEFORE 7
+#define E_MEETING_TIME_SELECTOR_DAYS_SHOWN 35
+#define E_MEETING_TIME_SELECTOR_DAYS_START_BEFORE 7
#define E_MEETING_TIME_SELECTOR_FB_DAYS_BEFORE 7
#define E_MEETING_TIME_SELECTOR_FB_DAYS_AFTER 28
@@ -222,10 +222,10 @@ e_meeting_time_selector_class_init (EMeetingTimeSelectorClass * klass)
object_class = (GtkObjectClass *) klass;
widget_class = (GtkWidgetClass *) klass;
- mts_signals [CHANGED] =
+ mts_signals [CHANGED] =
gtk_signal_new ("changed", GTK_RUN_FIRST,
G_TYPE_FROM_CLASS (object_class),
- GTK_SIGNAL_OFFSET (EMeetingTimeSelectorClass,
+ GTK_SIGNAL_OFFSET (EMeetingTimeSelectorClass,
changed),
gtk_signal_default_marshaller,
GTK_TYPE_NONE, 0);
@@ -257,7 +257,7 @@ e_meeting_time_selector_init (EMeetingTimeSelector * mts)
mts->list_view = NULL;
- mts->fb_uri_not =
+ mts->fb_uri_not =
calendar_config_add_notification_free_busy_template ((GConfClientNotifyFunc) free_busy_template_changed_cb,
mts);
@@ -310,7 +310,7 @@ e_meeting_time_selector_construct (EMeetingTimeSelector * mts, EMeetingStore *em
mts->attendees_vbox_spacer = gtk_vbox_new (FALSE, 0);
gtk_box_pack_start (GTK_BOX (vbox), mts->attendees_vbox_spacer, FALSE, FALSE, 0);
gtk_widget_show (mts->attendees_vbox_spacer);
-
+
mts->attendees_vbox = gtk_vbox_new (FALSE, 0);
gtk_box_pack_start (GTK_BOX (vbox), mts->attendees_vbox, TRUE, TRUE, 0);
gtk_widget_show (mts->attendees_vbox);
@@ -331,10 +331,10 @@ e_meeting_time_selector_construct (EMeetingTimeSelector * mts, EMeetingStore *em
e_meeting_list_view_column_set_visible (mts->list_view, "RSVP", FALSE);
e_meeting_list_view_column_set_visible (mts->list_view, "Status", FALSE);
e_meeting_list_view_column_set_visible (mts->list_view, "Type", FALSE);
-
+
gtk_widget_show (GTK_WIDGET (mts->list_view));
-
+
sw = gtk_scrolled_window_new (NULL, NULL);
gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (sw), GTK_POLICY_NEVER, GTK_POLICY_AUTOMATIC);
gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (sw), GTK_SHADOW_IN);
@@ -609,7 +609,7 @@ e_meeting_time_selector_construct (EMeetingTimeSelector * mts, EMeetingStore *em
e_date_edit_set_show_time (E_DATE_EDIT (mts->start_date_edit), TRUE);
e_date_edit_set_use_24_hour_format (E_DATE_EDIT (mts->start_date_edit),
calendar_config_get_24_hour_format ());
-
+
gtk_table_attach (GTK_TABLE (table), mts->start_date_edit,
1, 2, 0, 1, GTK_FILL, 0, 0, 0);
gtk_widget_show (mts->start_date_edit);
@@ -683,7 +683,7 @@ e_meeting_time_selector_construct (EMeetingTimeSelector * mts, EMeetingStore *em
e_meeting_time_selector_recalc_grid (mts);
e_meeting_time_selector_ensure_meeting_time_shown (mts);
e_meeting_time_selector_update_start_date_edit (mts);
- e_meeting_time_selector_update_end_date_edit (mts);
+ e_meeting_time_selector_update_end_date_edit (mts);
e_meeting_time_selector_update_date_popup_menus (mts);
gtk_signal_emit (GTK_OBJECT (mts), mts_signals [CHANGED]);
@@ -759,7 +759,7 @@ e_meeting_time_selector_alloc_named_color (EMeetingTimeSelector * mts,
const char *name, GdkColor *c)
{
GdkColormap *colormap;
-
+
g_return_if_fail (name != NULL);
g_return_if_fail (c != NULL);
@@ -810,7 +810,7 @@ e_meeting_time_selector_new (EMeetingStore *ems)
mts = GTK_WIDGET (g_object_new (e_meeting_time_selector_get_type (), NULL));
e_meeting_time_selector_construct (E_MEETING_TIME_SELECTOR (mts), ems);
-
+
return mts;
}
@@ -823,17 +823,17 @@ e_meeting_time_selector_destroy (GtkObject *object)
mts = E_MEETING_TIME_SELECTOR (object);
e_meeting_time_selector_remove_timeout (mts);
-
+
if (mts->stipple) {
g_object_unref (mts->stipple);
mts->stipple = NULL;
}
-
+
if (mts->model) {
g_object_unref (mts->model);
mts->model = NULL;
}
-
+
mts->display_top = NULL;
mts->display_main = NULL;
@@ -842,7 +842,7 @@ e_meeting_time_selector_destroy (GtkObject *object)
if (mts->fb_refresh_not != 0) {
g_source_remove (mts->fb_refresh_not);
}
-
+
if (GTK_OBJECT_CLASS (e_meeting_time_selector_parent_class)->destroy)
(*GTK_OBJECT_CLASS (e_meeting_time_selector_parent_class)->destroy)(object);
}
@@ -886,7 +886,7 @@ get_cell_height (GtkTreeView *tree)
gtk_tree_view_column_cell_get_size (column, NULL,
NULL, NULL,
NULL, &height);
-
+
return height;
}
@@ -914,7 +914,7 @@ e_meeting_time_selector_style_set (GtkWidget *widget,
font_metrics = pango_context_get_metrics (pango_context, font_desc,
pango_context_get_language (pango_context));
layout = pango_layout_new (pango_context);
-
+
/* Calculate the widths of the hour strings in the style's font. */
max_hour_width = 0;
for (hour = 0; hour < 24; hour++) {
@@ -926,16 +926,16 @@ e_meeting_time_selector_style_set (GtkWidget *widget,
pango_layout_get_pixel_size (layout, &mts->hour_widths [hour], NULL);
max_hour_width = MAX (max_hour_width, mts->hour_widths[hour]);
}
-
+
mts->row_height = get_cell_height (GTK_TREE_VIEW (mts->list_view));
mts->col_width = max_hour_width + 6;
e_meeting_time_selector_save_position (mts, &saved_time);
e_meeting_time_selector_recalc_grid (mts);
e_meeting_time_selector_restore_position (mts, &saved_time);
-
+
gtk_widget_set_size_request (mts->display_top, -1, mts->row_height * 3 + 4);
-
+
/*
* FIXME: I can't find a way to get the treeview header heights
* other than the below but it isn't nice to realize that widget here
@@ -946,7 +946,7 @@ e_meeting_time_selector_style_set (GtkWidget *widget,
NULL, &maxheight);
gtk_widget_set_size_request (mts->attendees_vbox_spacer, 1, mts->row_height * 3 - maxheight);
- */
+ */
gtk_widget_set_size_request (mts->attendees_vbox_spacer, 1, mts->row_height * 2 - 6);
@@ -1102,7 +1102,7 @@ e_meeting_time_selector_set_all_day (EMeetingTimeSelector *mts,
EMeetingTime saved_time;
mts->all_day = all_day;
-
+
e_date_edit_set_show_time (E_DATE_EDIT (mts->start_date_edit),
!all_day);
e_date_edit_set_show_time (E_DATE_EDIT (mts->end_date_edit),
@@ -1169,7 +1169,7 @@ e_meeting_time_selector_set_working_hours (EMeetingTimeSelector *mts,
mts->day_end_hour = day_start_hour + 1;
mts->day_end_minute = day_start_minute;
}
-
+
e_meeting_time_selector_save_position (mts, &saved_time);
e_meeting_time_selector_recalc_grid (mts);
e_meeting_time_selector_restore_position (mts, &saved_time);
@@ -1201,8 +1201,8 @@ e_meeting_time_selector_set_zoomed_out (EMeetingTimeSelector *mts,
gtk_widget_queue_draw (mts->display_main);
}
-static gboolean
-e_meeting_time_selector_refresh_cb (gpointer data)
+static gboolean
+e_meeting_time_selector_refresh_cb (gpointer data)
{
EMeetingTimeSelector *mts = data;
@@ -1211,7 +1211,7 @@ e_meeting_time_selector_refresh_cb (gpointer data)
mts->last_cursor_set = GDK_LEFT_PTR;
e_meeting_time_selector_item_set_normal_cursor (E_MEETING_TIME_SELECTOR_ITEM (mts->item_top));
e_meeting_time_selector_item_set_normal_cursor (E_MEETING_TIME_SELECTOR_ITEM (mts->item_main));
- }
+ }
if (mts->display_top != NULL)
gtk_widget_queue_draw (mts->display_top);
@@ -1227,7 +1227,7 @@ void
e_meeting_time_selector_refresh_free_busy (EMeetingTimeSelector *mts, int row, gboolean all)
{
EMeetingTime start, end;
-
+
start = mts->meeting_start_time;
g_date_subtract_days (&start.date, E_MEETING_TIME_SELECTOR_FB_DAYS_BEFORE);
start.hour = 0;
@@ -1235,7 +1235,7 @@ e_meeting_time_selector_refresh_free_busy (EMeetingTimeSelector *mts, int row, g
end = mts->meeting_end_time;
g_date_add_days (&end.date, E_MEETING_TIME_SELECTOR_FB_DAYS_AFTER);
end.hour = 0;
- end.minute = 0;
+ end.minute = 0;
/* set the cursor to Busy, We need to reset it to normal once the free busy
queries are complete */
@@ -1249,18 +1249,18 @@ e_meeting_time_selector_refresh_free_busy (EMeetingTimeSelector *mts, int row, g
* notification */
if (all) {
int i;
-
+
for (i = 0; i < e_meeting_store_count_actual_attendees (mts->model); i++)
gtk_object_ref (GTK_OBJECT (mts));
} else {
gtk_object_ref (GTK_OBJECT (mts));
}
-
+
if (all)
- e_meeting_store_refresh_all_busy_periods (mts->model, &start, &end,
+ e_meeting_store_refresh_all_busy_periods (mts->model, &start, &end,
e_meeting_time_selector_refresh_cb, mts);
else
- e_meeting_store_refresh_busy_periods (mts->model, row, &start, &end,
+ e_meeting_store_refresh_busy_periods (mts->model, row, &start, &end,
e_meeting_time_selector_refresh_cb, mts);
}
@@ -1554,7 +1554,7 @@ e_meeting_time_selector_autopick (EMeetingTimeSelector *mts,
/* Get the current meeting duration in days + hours + minutes. */
e_meeting_time_selector_calculate_time_difference (&mts->meeting_start_time, &mts->meeting_end_time, &duration_days, &duration_hours, &duration_minutes);
-
+
/* Find the first appropriate start time. */
start_time = mts->meeting_start_time;
if (forward)
@@ -1706,10 +1706,10 @@ e_meeting_time_selector_find_nearest_interval (EMeetingTimeSelector *mts,
} else {
g_date_add_days (&start_time->date, 1);
start_time->hour = 0;
- start_time->minute = 0;
+ start_time->minute = 0;
}
e_meeting_time_selector_fix_time_overflows (start_time);
-
+
*end_time = *start_time;
e_meeting_time_selector_adjust_time (end_time, days, hours, mins);
@@ -1752,7 +1752,7 @@ e_meeting_time_selector_find_nearest_interval (EMeetingTimeSelector *mts,
start_time->minute += 29;
start_time->minute -= start_time->minute % 30;
}
-
+
e_meeting_time_selector_fix_time_overflows (start_time);
*end_time = *start_time;
@@ -1795,7 +1795,7 @@ e_meeting_time_selector_find_nearest_interval_backward (EMeetingTimeSelector *mt
} else {
g_date_subtract_days (&start_time->date, 1);
start_time->hour = 0;
- start_time->minute = 0;
+ start_time->minute = 0;
}
*end_time = *start_time;
@@ -1839,7 +1839,7 @@ e_meeting_time_selector_find_nearest_interval_backward (EMeetingTimeSelector *mt
} else {
start_time->minute -= start_time->minute % 30;
}
-
+
*end_time = *start_time;
e_meeting_time_selector_adjust_time (end_time, days, hours, mins);
}
@@ -2408,7 +2408,7 @@ e_meeting_time_selector_drag_meeting_time (EMeetingTimeSelector *mts,
if (drag_time.hour > 12)
g_date_add_days (&drag_time.date, 1);
drag_time.hour = 0;
- drag_time.minute = 0;
+ drag_time.minute = 0;
}
e_meeting_time_selector_fix_time_overflows (&drag_time);
@@ -2437,7 +2437,7 @@ e_meeting_time_selector_drag_meeting_time (EMeetingTimeSelector *mts,
&& mts->dragging_position == E_MEETING_TIME_SELECTOR_POS_END
&& e_meeting_time_compare_times (&mts->meeting_start_time, &drag_time) == 0)
return;
-
+
*time_to_set = drag_time;
/* Check if the start time and end time need to be switched. */
@@ -2454,7 +2454,7 @@ e_meeting_time_selector_drag_meeting_time (EMeetingTimeSelector *mts,
set_both_times = TRUE;
}
-
+
/* Mark the calculated positions as invalid. */
mts->meeting_positions_valid = FALSE;
@@ -2661,7 +2661,7 @@ static void
e_meeting_time_selector_update_end_date_edit (EMeetingTimeSelector *mts)
{
GDate date;
-
+
date = mts->meeting_end_time.date;
if (mts->all_day)
g_date_subtract_days (&date, 1);
@@ -2702,7 +2702,7 @@ e_meeting_time_selector_ensure_meeting_time_shown (EMeetingTimeSelector *mts)
time.minute = 0;
start_x = e_meeting_time_selector_calculate_time_position (mts, &time);
}
-
+
gnome_canvas_get_scroll_offsets (GNOME_CANVAS (mts->display_main),
&scroll_x, &scroll_y);
canvas_width = mts->display_main->allocation.width;
@@ -2905,18 +2905,18 @@ static gboolean
free_busy_timeout_refresh (gpointer data)
{
char *fb_uri;
-
+
EMeetingTimeSelector *mts = E_MEETING_TIME_SELECTOR (data);
fb_uri = calendar_config_get_free_busy_template ();
e_meeting_store_set_fb_uri (mts->model, fb_uri);
g_free (fb_uri);
-
+
/* Update all free/busy info, so we use the new template uri */
e_meeting_time_selector_refresh_free_busy (mts, 0, TRUE);
mts->fb_refresh_not = 0;
-
+
return FALSE;
}
@@ -2930,10 +2930,10 @@ free_busy_template_changed_cb (GConfClient *client,
/* Wait REFRESH_PAUSE before refreshing, using the latest uri value */
if (mts->fb_refresh_not != 0) {
- g_source_remove (mts->fb_refresh_not);
+ g_source_remove (mts->fb_refresh_not);
}
- mts->fb_refresh_not = g_timeout_add (REFRESH_PAUSE,
- free_busy_timeout_refresh,
+ mts->fb_refresh_not = g_timeout_add (REFRESH_PAUSE,
+ free_busy_timeout_refresh,
data);
}
diff --git a/calendar/gui/e-meeting-time-sel.h b/calendar/gui/e-meeting-time-sel.h
index e071df37fe..9b95c7d767 100644
--- a/calendar/gui/e-meeting-time-sel.h
+++ b/calendar/gui/e-meeting-time-sel.h
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@gtk.org>
*
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -118,11 +118,11 @@ struct _EMeetingTimeSelector
with PACK_START if necessary. */
GtkWidget *attendees_vbox;
GtkWidget *attendees_vbox_spacer;
-
+
/* The etable and model */
EMeetingStore *model;
EMeetingListView *list_view;
-
+
/* The canvas displaying the dates, times, and the summary
'All Attendees' free/busy display. */
GtkWidget *display_top;
@@ -190,7 +190,7 @@ struct _EMeetingTimeSelector
/* True if we are selecting all day events */
gboolean all_day;
-
+
/* If this is TRUE we only show hours between day_start_hour and
day_end_hour, defaults to TRUE (9am-6pm). */
gboolean working_hours_only;
diff --git a/calendar/gui/e-memo-table-config.c b/calendar/gui/e-memo-table-config.c
index 15e19eb392..8f3729c61e 100644
--- a/calendar/gui/e-memo-table-config.c
+++ b/calendar/gui/e-memo-table-config.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
* Nathan Owens <pianocomp81@yahoo.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -29,7 +29,7 @@ struct _EMemoTableConfigPrivate {
EMemoTable *table;
ECellDateEditConfig *cell_config;
-
+
GList *notifications;
};
@@ -47,7 +47,7 @@ e_memo_table_config_set_property (GObject *object, guint property_id, const GVal
EMemoTableConfig *table_config;
table_config = E_MEMO_TABLE_CONFIG (object);
-
+
switch (property_id) {
case PROP_TABLE:
e_memo_table_config_set_table (table_config, g_value_get_object (value));
@@ -64,7 +64,7 @@ e_memo_table_config_get_property (GObject *object, guint property_id, GValue *va
EMemoTableConfig *table_config;
table_config = E_MEMO_TABLE_CONFIG (object);
-
+
switch (property_id) {
case PROP_TABLE:
g_value_set_object (value, e_memo_table_config_get_table (table_config));
@@ -81,7 +81,7 @@ e_memo_table_config_dispose (GObject *object)
EMemoTableConfig *table_config = E_MEMO_TABLE_CONFIG (object);
e_memo_table_config_set_table (table_config, NULL);
-
+
if (G_OBJECT_CLASS (e_memo_table_config_parent_class)->dispose)
G_OBJECT_CLASS (e_memo_table_config_parent_class)->dispose (object);
}
@@ -91,11 +91,11 @@ e_memo_table_config_finalize (GObject *object)
{
EMemoTableConfig *table_config = E_MEMO_TABLE_CONFIG (object);
EMemoTableConfigPrivate *priv;
-
+
priv = table_config->priv;
g_free (priv);
-
+
if (G_OBJECT_CLASS (e_memo_table_config_parent_class)->finalize)
G_OBJECT_CLASS (e_memo_table_config_parent_class)->finalize (object);
}
@@ -128,14 +128,14 @@ EMemoTableConfig *
e_memo_table_config_new (EMemoTable *table)
{
EMemoTableConfig *table_config;
-
+
table_config = g_object_new (e_memo_table_config_get_type (), "table", table, NULL);
return table_config;
}
EMemoTable *
-e_memo_table_config_get_table (EMemoTableConfig *table_config)
+e_memo_table_config_get_table (EMemoTableConfig *table_config)
{
EMemoTableConfigPrivate *priv;
@@ -143,16 +143,16 @@ e_memo_table_config_get_table (EMemoTableConfig *table_config)
g_return_val_if_fail (E_IS_MEMO_TABLE_CONFIG (table_config), NULL);
priv = table_config->priv;
-
+
return priv->table;
}
static void
-set_timezone (EMemoTable *table)
+set_timezone (EMemoTable *table)
{
ECalModel *model;
icaltimezone *zone;
-
+
zone = calendar_config_get_icaltimezone ();
model = e_memo_table_get_model (table);
if (model)
@@ -164,14 +164,14 @@ timezone_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer
{
EMemoTableConfig *table_config = data;
EMemoTableConfigPrivate *priv;
-
+
priv = table_config->priv;
-
+
set_timezone (priv->table);
}
static void
-set_twentyfour_hour (EMemoTable *table)
+set_twentyfour_hour (EMemoTable *table)
{
ECalModel *model;
gboolean use_24_hour;
@@ -188,29 +188,29 @@ twentyfour_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gp
{
EMemoTableConfig *table_config = data;
EMemoTableConfigPrivate *priv;
-
+
priv = table_config->priv;
-
+
set_twentyfour_hour (priv->table);
}
void
-e_memo_table_config_set_table (EMemoTableConfig *table_config, EMemoTable *table)
+e_memo_table_config_set_table (EMemoTableConfig *table_config, EMemoTable *table)
{
EMemoTableConfigPrivate *priv;
guint not;
GList *l;
-
+
g_return_if_fail (table_config != NULL);
g_return_if_fail (E_IS_MEMO_TABLE_CONFIG (table_config));
priv = table_config->priv;
-
+
if (priv->table) {
g_object_unref (priv->table);
priv->table = NULL;
}
-
+
if (priv->cell_config) {
g_object_unref (priv->cell_config);
priv->cell_config = NULL;
@@ -225,17 +225,17 @@ e_memo_table_config_set_table (EMemoTableConfig *table_config, EMemoTable *table
/* If the new view is NULL, return right now */
if (!table)
return;
-
+
priv->table = g_object_ref (table);
/* Time zone */
set_timezone (table);
-
+
not = calendar_config_add_notification_timezone (timezone_changed_cb, table_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* 24 Hour format */
- set_twentyfour_hour (table);
+ set_twentyfour_hour (table);
not = calendar_config_add_notification_24_hour_format (twentyfour_hour_changed_cb, table_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
diff --git a/calendar/gui/e-memo-table-config.h b/calendar/gui/e-memo-table-config.h
index 15e9a06d3a..ce4006df48 100644
--- a/calendar/gui/e-memo-table-config.h
+++ b/calendar/gui/e-memo-table-config.h
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
* Nathan Owens <pianocomp81@yahoo.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -31,7 +31,7 @@ G_BEGIN_DECLS
#define E_MEMO_TABLE_CONFIG(obj) GTK_CHECK_CAST (obj, e_memo_table_config_get_type (), EMemoTableConfig)
#define E_MEMO_TABLE_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_memo_table_config_get_type (), EMemoTableConfigClass)
#define E_IS_MEMO_TABLE_CONFIG(obj) GTK_CHECK_TYPE (obj, e_memo_table_config_get_type ())
-
+
typedef struct _EMemoTableConfig EMemoTableConfig;
typedef struct _EMemoTableConfigClass EMemoTableConfigClass;
typedef struct _EMemoTableConfigPrivate EMemoTableConfigPrivate;
diff --git a/calendar/gui/e-memo-table.c b/calendar/gui/e-memo-table.c
index 4ac8147fdf..aaf451244c 100644
--- a/calendar/gui/e-memo-table.c
+++ b/calendar/gui/e-memo-table.c
@@ -178,7 +178,7 @@ date_compare_cb (gconstpointer a, gconstpointer b)
}
static void
-row_appended_cb (ECalModel *model, EMemoTable *memo_table)
+row_appended_cb (ECalModel *model, EMemoTable *memo_table)
{
g_signal_emit (memo_table, signals[USER_CREATED], 0);
}
@@ -236,7 +236,7 @@ e_memo_table_init (EMemoTable *memo_table)
/* Sorting */
e_table_extras_add_compare (extras, "date-compare",
date_compare_cb);
-
+
/* Create pixmaps */
if (!icon_pixbufs[0])
@@ -274,7 +274,7 @@ e_memo_table_init (EMemoTable *memo_table)
g_signal_connect (e_table, "right_click", G_CALLBACK (e_memo_table_on_right_click), memo_table);
g_signal_connect (e_table, "key_press", G_CALLBACK (e_memo_table_on_key_press), memo_table);
g_signal_connect (e_table, "popup_menu", G_CALLBACK (e_memo_table_on_popup_menu), memo_table);
-
+
a11y = gtk_widget_get_accessible (GTK_WIDGET(e_table));
if (a11y)
atk_object_set_name (a11y, _("Memos"));
@@ -301,9 +301,9 @@ e_memo_table_new (void)
/**
* e_memo_table_get_model:
* @memo_table: A calendar table.
- *
+ *
* Queries the calendar data model that a calendar table is using.
- *
+ *
* Return value: A memo model.
**/
ECalModel *
@@ -334,9 +334,9 @@ e_memo_table_destroy (GtkObject *object)
/**
* e_memo_table_get_table:
* @memo_table: A calendar table.
- *
+ *
* Queries the #ETable widget that the calendar table is using.
- *
+ *
* Return value: The #ETable widget that the calendar table uses to display its
* data.
**/
@@ -371,7 +371,7 @@ get_selected_row_cb (int model_row, gpointer data)
*row = model_row;
}
-/*
+/*
* Returns the component that is selected in the table; only works if there is
* one and only one selected row.
*/
@@ -441,8 +441,8 @@ delete_selected_components (EMemoTable *memo_table)
for (l = objs; l; l = l->next) {
ECalModelComponent *comp_data = (ECalModelComponent *) l->data;
GError *error = NULL;
-
- e_cal_remove_object (comp_data->client,
+
+ e_cal_remove_object (comp_data->client,
icalcomponent_get_uid (comp_data->icalcomp), &error);
delete_error_dialog (error, E_CAL_COMPONENT_JOURNAL);
g_clear_error (&error);
@@ -455,10 +455,10 @@ delete_selected_components (EMemoTable *memo_table)
/**
* e_memo_table_get_selected:
- * @memo_table:
- *
+ * @memo_table:
+ *
* Get the currently selected ECalModelComponent's on the table.
- *
+ *
* Return value: A GSList of the components, which should be
* g_slist_free'd when finished with.
**/
@@ -471,7 +471,7 @@ e_memo_table_get_selected (EMemoTable *memo_table)
/**
* e_memo_table_delete_selected:
* @memo_table: A memo table.
- *
+ *
* Deletes the selected components in the table; asks the user first.
**/
void
@@ -502,7 +502,7 @@ e_memo_table_delete_selected (EMemoTable *memo_table)
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (comp_data->icalcomp));
}
-
+
if (delete_component_dialog (comp, FALSE, n_selected, E_CAL_COMPONENT_JOURNAL,
GTK_WIDGET (memo_table)))
delete_selected_components (memo_table);
@@ -589,7 +589,7 @@ e_memo_table_copy_clipboard (EMemoTable *memo_table)
ETable *etable;
GtkClipboard *clipboard;
char *comp_str;
-
+
g_return_if_fail (E_IS_MEMO_TABLE (memo_table));
/* create temporary VCALENDAR object */
@@ -606,7 +606,7 @@ e_memo_table_copy_clipboard (EMemoTable *memo_table)
} else {
gtk_clipboard_set_can_store (clipboard, target_types + 1, n_target_types - 1);
}
-
+
/* free memory */
icalcomponent_free (memo_table->tmp_vcal);
memo_table->tmp_vcal = NULL;
@@ -638,7 +638,7 @@ clipboard_get_calendar_data (EMemoTable *memo_table, const gchar *text)
}
client = e_cal_model_get_default_client (memo_table->model);
-
+
e_memo_table_set_status_message (memo_table, _("Updating objects"));
if (kind == ICAL_VCALENDAR_COMPONENT) {
@@ -690,7 +690,7 @@ clipboard_paste_received_cb (GtkClipboard *clipboard,
GtkSelectionData *selection_data,
gpointer data)
{
- EMemoTable *memo_table = E_MEMO_TABLE (data);
+ EMemoTable *memo_table = E_MEMO_TABLE (data);
ETable *e_table = e_table_scrolled_get_table (E_TABLE_SCROLLED (memo_table->etable));
GnomeCanvas *canvas = e_table->table_canvas;
GnomeCanvasItem *item = GNOME_CANVAS (canvas)->focused_item;
@@ -743,7 +743,7 @@ open_memo (EMemoTable *memo_table, ECalModelComponent *comp_data)
{
CompEditor *medit;
const char *uid;
-
+
uid = icalcomponent_get_uid (comp_data->icalcomp);
medit = e_comp_editor_registry_find (comp_editor_registry, uid);
@@ -763,10 +763,10 @@ open_memo (EMemoTable *memo_table, ECalModelComponent *comp_data)
medit = COMP_EDITOR (memo_editor_new (comp_data->client, flags));
comp_editor_edit_comp (medit, comp);
-
+
e_comp_editor_registry_add (comp_editor_registry, medit, FALSE);
}
-
+
comp_editor_focus (medit);
}
@@ -782,7 +782,7 @@ open_memo_by_row (EMemoTable *memo_table, int row)
static void
e_memo_table_on_double_click (ETable *table,
- gint row,
+ gint row,
gint col,
GdkEvent *event,
EMemoTable *memo_table)
@@ -809,22 +809,22 @@ e_memo_table_on_save_as (EPopup *ep, EPopupItem *pitem, void *data)
ECalModelComponent *comp_data;
char *filename;
char *ical_string;
-
+
comp_data = get_selected_comp (memo_table);
if (comp_data == NULL)
return;
-
+
filename = e_file_dialog_save (_("Save as..."), NULL);
if (filename == NULL)
return;
-
+
ical_string = e_cal_get_component_as_string (comp_data->client, comp_data->icalcomp);
if (ical_string == NULL) {
g_warning ("Couldn't convert item to a string");
return;
}
- e_write_file_uri (filename, ical_string);
+ e_write_file_uri (filename, ical_string);
g_free (ical_string);
}
@@ -838,7 +838,7 @@ e_memo_table_on_print_memo (EPopup *ep, EPopupItem *pitem, void *data)
comp_data = get_selected_comp (memo_table);
if (comp_data == NULL)
return;
-
+
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (comp_data->icalcomp));
print_comp (comp, comp_data->client, GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG);
@@ -866,7 +866,7 @@ static void
e_memo_table_on_paste (EPopup *ep, EPopupItem *pitem, void *data)
{
EMemoTable *memo_table = E_MEMO_TABLE (data);
-
+
e_memo_table_paste_clipboard (memo_table);
}
@@ -923,7 +923,7 @@ static EPopupItem memos_popup_items [] = {
{ E_POPUP_ITEM, "20.print", N_("_Print..."), e_memo_table_on_print_memo, NULL, GTK_STOCK_PRINT, E_CAL_POPUP_SELECT_ONE },
{ E_POPUP_BAR, "30.bar" },
-
+
{ E_POPUP_ITEM, "40.cut", N_("C_ut"), e_memo_table_on_cut, NULL, GTK_STOCK_CUT, 0, E_CAL_POPUP_SELECT_EDITABLE },
{ E_POPUP_ITEM, "50.copy", N_("_Copy"), e_memo_table_on_copy, NULL, GTK_STOCK_COPY, 0, 0 },
{ E_POPUP_ITEM, "60.paste", N_("_Paste"), e_memo_table_on_paste, NULL, GTK_STOCK_PASTE, 0, E_CAL_POPUP_SELECT_EDITABLE },
@@ -1022,7 +1022,7 @@ e_memo_table_on_key_press (ETable *table,
} else if ((event->keyval == GDK_o)
&&(event->state & GDK_CONTROL_MASK)) {
open_memo_by_row (memo_table, row);
- return TRUE;
+ return TRUE;
}
return FALSE;
@@ -1110,7 +1110,7 @@ e_memo_table_set_status_message (EMemoTable *memo_table, const gchar *message)
if (!memo_table->activity_handler)
return;
-
+
if (!message || !*message) {
if (memo_table->activity_id != 0) {
e_activity_handler_operation_finished (memo_table->activity_handler, memo_table->activity_id);
@@ -1118,7 +1118,7 @@ e_memo_table_set_status_message (EMemoTable *memo_table, const gchar *message)
}
} else if (memo_table->activity_id == 0) {
char *client_id = g_strdup_printf ("%p", memo_table);
-
+
if (progress_icon == NULL)
progress_icon = e_icon_factory_get_icon (EVOLUTION_MEMOS_PROGRESS_IMAGE, E_ICON_SIZE_STATUS);
diff --git a/calendar/gui/e-memo-table.h b/calendar/gui/e-memo-table.h
index 5168735c58..5ce2f03cbc 100644
--- a/calendar/gui/e-memo-table.h
+++ b/calendar/gui/e-memo-table.h
@@ -1,15 +1,15 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
* Nathan Owens <pianocomp81@yahoo.com>
*
* Copyright 2000, Ximian, Inc.
* Copyright 2000, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-memos.c b/calendar/gui/e-memos.c
index a028f5e47b..6d5120787d 100644
--- a/calendar/gui/e-memos.c
+++ b/calendar/gui/e-memos.c
@@ -68,13 +68,13 @@ struct _EMemosPrivate {
ECal *default_client;
ECalView *query;
-
+
EConfigListener *config_listener;
-
+
/* The EMemoTable showing the memos. */
GtkWidget *memos_view;
EMemoTableConfig *memos_view_config;
-
+
/* Calendar search bar for memos */
GtkWidget *search_bar;
@@ -83,11 +83,11 @@ struct _EMemosPrivate {
/* The preview */
GtkWidget *preview;
-
+
gchar *current_uid;
char *sexp;
guint update_timeout;
-
+
/* View instance and the view menus handler */
GalViewInstance *view_instance;
GalViewMenus *view_menus;
@@ -141,27 +141,27 @@ table_cursor_change_cb (ETable *etable, int row, gpointer data)
priv = memos->priv;
n_selected = e_table_selected_count (etable);
-
+
/* update the HTML widget */
if (n_selected != 1) {
e_cal_component_memo_preview_clear (E_CAL_COMPONENT_MEMO_PREVIEW (priv->preview));
return;
}
-
+
model = e_memo_table_get_model (E_MEMO_TABLE (priv->memos_view));
-
+
comp_data = e_cal_model_get_component_at (model, e_table_get_cursor_row (etable));
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (comp_data->icalcomp));
e_cal_component_memo_preview_display (E_CAL_COMPONENT_MEMO_PREVIEW (priv->preview), comp_data->client, comp);
-
+
e_cal_component_get_uid (comp, &uid);
if (priv->current_uid)
g_free (priv->current_uid);
priv->current_uid = g_strdup (uid);
-
+
g_object_unref (comp);
}
@@ -182,10 +182,10 @@ table_selection_change_cb (ETable *etable, gpointer data)
static void
user_created_cb (GtkWidget *view, EMemos *memos)
{
- EMemosPrivate *priv;
+ EMemosPrivate *priv;
EMemoTable *memo_table;
ECal *ecal;
-
+
priv = memos->priv;
memo_table = E_MEMO_TABLE (priv->memos_view);
@@ -213,9 +213,9 @@ search_bar_sexp_changed_cb (CalSearchBar *cal_search, const char *sexp, gpointer
if (priv->sexp)
g_free (priv->sexp);
-
+
priv->sexp = g_strdup (sexp);
-
+
update_view (memos);
}
@@ -243,14 +243,14 @@ vpaned_resized_cb (GtkWidget *widget, GdkEventButton *event, EMemos *memos)
}
static void
-set_timezone (EMemos *memos)
+set_timezone (EMemos *memos)
{
EMemosPrivate *priv;
icaltimezone *zone;
GList *l;
-
+
priv = memos->priv;
-
+
zone = calendar_config_get_icaltimezone ();
for (l = priv->clients_list; l != NULL; l = l->next) {
ECal *client = l->data;
@@ -272,7 +272,7 @@ static void
timezone_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer data)
{
EMemos *memos = data;
-
+
set_timezone (memos);
}
@@ -281,19 +281,19 @@ update_view (EMemos *memos)
{
EMemosPrivate *priv;
ECalModel *model;
-
+
priv = memos->priv;
model = e_memo_table_get_model (E_MEMO_TABLE (priv->memos_view));
-
+
e_cal_model_set_search_query (model, priv->sexp);
-
+
e_cal_component_memo_preview_clear (E_CAL_COMPONENT_MEMO_PREVIEW (priv->preview));
}
static gboolean
update_view_cb (EMemos *memos)
-{
+{
update_view (memos);
return TRUE;
@@ -333,10 +333,10 @@ setup_config (EMemos *memos)
guint not;
priv = memos->priv;
-
+
/* Timezone */
set_timezone (memos);
-
+
not = calendar_config_add_notification_timezone (timezone_changed_cb, memos);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
}
@@ -458,7 +458,7 @@ table_drag_data_get (ETable *table,
}
}
-static void
+static void
table_drag_data_delete (ETable *table,
int row,
int col,
@@ -501,7 +501,7 @@ setup_widgets (EMemos *memos)
G_CALLBACK (search_bar_sexp_changed_cb), memos);
g_signal_connect (priv->search_bar, "category_changed",
G_CALLBACK (search_bar_category_changed_cb), memos);
-
+
/* TODO Why doesn't this work?? */
config_categories_changed_cb (priv->config_listener, "/apps/evolution/general/category_master_list", memos);
@@ -522,13 +522,13 @@ setup_widgets (EMemos *memos)
/* create the memo list */
priv->memos_view = e_memo_table_new ();
priv->memos_view_config = e_memo_table_config_new (E_MEMO_TABLE (priv->memos_view));
-
+
g_signal_connect (priv->memos_view, "user_created", G_CALLBACK (user_created_cb), memos);
etable = e_table_scrolled_get_table (
E_TABLE_SCROLLED (E_MEMO_TABLE (priv->memos_view)->etable));
e_table_set_state (etable, E_MEMOS_TABLE_DEFAULT_STATE);
-
+
gtk_paned_add1 (GTK_PANED (priv->paned), priv->memos_view);
gtk_widget_show (priv->memos_view);
@@ -536,7 +536,7 @@ setup_widgets (EMemos *memos)
e_table_drag_source_set (etable, GDK_BUTTON1_MASK,
list_drag_types, num_list_drag_types,
GDK_ACTION_MOVE|GDK_ACTION_COPY|GDK_ACTION_ASK);
-
+
g_signal_connect (etable, "table_drag_data_get",
G_CALLBACK(table_drag_data_get), memos);
g_signal_connect (etable, "table_drag_data_delete",
@@ -570,7 +570,7 @@ e_memos_class_init (EMemosClass *klass)
e_memos_signals[SELECTION_CHANGED] =
gtk_signal_new ("selection_changed",
GTK_RUN_LAST,
- G_TYPE_FROM_CLASS (object_class),
+ G_TYPE_FROM_CLASS (object_class),
GTK_SIGNAL_OFFSET (EMemosClass, selection_changed),
g_cclosure_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
@@ -634,17 +634,17 @@ static void
e_memos_init (EMemos *memos)
{
EMemosPrivate *priv;
-
+
priv = g_new0 (EMemosPrivate, 1);
memos->priv = priv;
setup_config (memos);
setup_widgets (memos);
-
+
priv->config_listener = e_config_listener_new ();
g_signal_connect (priv->config_listener, "key_changed", G_CALLBACK (config_categories_changed_cb), memos);
- priv->clients = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_object_unref);
+ priv->clients = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_object_unref);
priv->query = NULL;
priv->view_instance = NULL;
priv->view_menus = NULL;
@@ -716,7 +716,7 @@ e_memos_destroy (GtkObject *object)
g_object_unref (priv->config_listener);
priv->config_listener = NULL;
}
-
+
/* disconnect from signals on all the clients */
for (l = priv->clients_list; l != NULL; l = l->next) {
g_signal_handlers_disconnect_matched (l->data, G_SIGNAL_MATCH_DATA,
@@ -734,7 +734,7 @@ e_memos_destroy (GtkObject *object)
g_free (priv->current_uid);
priv->current_uid = NULL;
}
-
+
if (priv->sexp) {
g_free (priv->sexp);
priv->sexp = NULL;
@@ -744,12 +744,12 @@ e_memos_destroy (GtkObject *object)
g_source_remove (priv->update_timeout);
priv->update_timeout = 0;
}
-
+
if (priv->memos_view_config) {
g_object_unref (priv->memos_view_config);
priv->memos_view_config = NULL;
}
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
priv->notifications = NULL;
@@ -777,7 +777,7 @@ set_status_message (EMemos *memos, const char *message, ...)
}
priv = memos->priv;
-
+
e_memo_table_set_status_message (E_MEMO_TABLE (priv->memos_view), msg_string);
}
@@ -812,7 +812,7 @@ backend_died_cb (ECal *client, gpointer data)
EMemos *memos;
EMemosPrivate *priv;
ESource *source;
-
+
memos = E_MEMOS (data);
priv = memos->priv;
@@ -824,10 +824,10 @@ backend_died_cb (ECal *client, gpointer data)
gtk_signal_emit (GTK_OBJECT (memos), e_memos_signals[SOURCE_REMOVED], source);
e_memo_table_set_status_message (E_MEMO_TABLE (e_memos_get_calendar_table (memos)), NULL);
-
+
e_error_run (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (memos))),
"calendar:memos-crashed", NULL);
-
+
g_object_unref (source);
}
@@ -894,7 +894,7 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, EMemos *memos)
case E_CALENDAR_STATUS_OK :
g_signal_handlers_disconnect_matched (ecal, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, default_client_cal_opened_cb, NULL);
model = e_memo_table_get_model (E_MEMO_TABLE (priv->memos_view));
-
+
set_timezone (memos);
e_cal_model_set_default_client (model, ecal);
set_status_message (memos, NULL);
@@ -940,7 +940,7 @@ void
e_memos_open_memo (EMemos *memos)
{
EMemoTable *cal_table;
-
+
cal_table = e_memos_get_calendar_table (memos);
e_memo_table_open_selected (cal_table);
}
@@ -972,10 +972,10 @@ e_memos_add_memo_source (EMemos *memos, ESource *source)
return TRUE;
} else {
ESource *default_source;
-
+
if (priv->default_client) {
default_source = e_cal_get_source (priv->default_client);
-
+
/* We don't have it but the default client is it */
if (!strcmp (e_source_peek_uid (default_source), uid))
client = g_object_ref (priv->default_client);
@@ -993,7 +993,7 @@ e_memos_add_memo_source (EMemos *memos, ESource *source)
/* g_signal_connect (G_OBJECT (client), "categories_changed", G_CALLBACK (client_categories_changed_cb), memos); */
g_signal_connect (G_OBJECT (client), "backend_died", G_CALLBACK (backend_died_cb), memos);
- /* add the client to internal structure */
+ /* add the client to internal structure */
g_hash_table_insert (priv->clients, g_strdup (uid) , client);
priv->clients_list = g_list_prepend (priv->clients_list, client);
@@ -1020,19 +1020,19 @@ e_memos_remove_memo_source (EMemos *memos, ESource *source)
uid = e_source_peek_uid (source);
client = g_hash_table_lookup (priv->clients, uid);
- if (!client)
+ if (!client)
return TRUE;
-
+
priv->clients_list = g_list_remove (priv->clients_list, client);
g_signal_handlers_disconnect_matched (client, G_SIGNAL_MATCH_DATA,
- 0, 0, NULL, NULL, memos);
+ 0, 0, NULL, NULL, memos);
model = e_memo_table_get_model (E_MEMO_TABLE (priv->memos_view));
e_cal_model_remove_client (model, client);
g_hash_table_remove (priv->clients, uid);
-
+
gtk_signal_emit (GTK_OBJECT (memos), e_memos_signals[SOURCE_REMOVED], source);
@@ -1044,7 +1044,7 @@ e_memos_set_default_source (EMemos *memos, ESource *source)
{
EMemosPrivate *priv;
ECal *ecal;
-
+
g_return_val_if_fail (memos != NULL, FALSE);
g_return_val_if_fail (E_IS_MEMOS (memos), FALSE);
g_return_val_if_fail (E_IS_SOURCE (source), FALSE);
@@ -1073,20 +1073,20 @@ ECal *
e_memos_get_default_client (EMemos *memos)
{
EMemosPrivate *priv;
-
+
g_return_val_if_fail (memos != NULL, NULL);
g_return_val_if_fail (E_IS_MEMOS (memos), NULL);
priv = memos->priv;
- return e_cal_model_get_default_client (e_memo_table_get_model (E_MEMO_TABLE (priv->memos_view)));
+ return e_cal_model_get_default_client (e_memo_table_get_model (E_MEMO_TABLE (priv->memos_view)));
}
/**
* e_memos_delete_selected:
* @memos: A memos control widget.
- *
+ *
* Deletes the selected memos in the memo list.
**/
void
@@ -1128,7 +1128,7 @@ display_view_cb (GalViewInstance *instance, GalView *view, gpointer data)
* e_memos_setup_view_menus:
* @memos: A memos widget.
* @uic: UI controller to use for the menus.
- *
+ *
* Sets up the #GalView menus for a memos control. This function should be
* called from the Bonobo control activation callback for this memos control.
* Also, the menus should be discarded using e_memos_discard_view_menus().
@@ -1164,7 +1164,7 @@ e_memos_setup_view_menus (EMemos *memos, BonoboUIComponent *uic)
dir0 = g_build_filename (EVOLUTION_GALVIEWSDIR,
"memos",
NULL);
- dir1 = g_build_filename (memos_component_peek_base_directory (memos_component_peek ()),
+ dir1 = g_build_filename (memos_component_peek_base_directory (memos_component_peek ()),
"memos", "views", NULL);
gal_view_collection_set_storage_directories (collection,
dir0,
@@ -1204,7 +1204,7 @@ e_memos_setup_view_menus (EMemos *memos, BonoboUIComponent *uic)
/**
* e_memos_discard_view_menus:
* @memos: A memos widget.
- *
+ *
* Discards the #GalView menus used by a memos control. This function should be
* called from the Bonobo control deactivation callback for this memos control.
* The menus should have been set up with e_memos_setup_view_menus().
@@ -1234,9 +1234,9 @@ e_memos_discard_view_menus (EMemos *memos)
/**
* e_memos_get_calendar_table:
* @memos: A memos widget.
- *
+ *
* Queries the #EMemoTable contained in a memos widget.
- *
+ *
* Return value: The #EMemoTable that the memos widget uses to display its
* information.
**/
diff --git a/calendar/gui/e-mini-calendar-config.c b/calendar/gui/e-mini-calendar-config.c
index 9325d60cd9..7165811a2f 100644
--- a/calendar/gui/e-mini-calendar-config.c
+++ b/calendar/gui/e-mini-calendar-config.c
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -43,7 +43,7 @@ e_mini_calendar_config_set_property (GObject *object, guint property_id, const G
EMiniCalendarConfig *mini_config;
mini_config = E_MINI_CALENDAR_CONFIG (object);
-
+
switch (property_id) {
case PROP_CALENDAR:
e_mini_calendar_config_set_calendar (mini_config, g_value_get_object (value));
@@ -60,7 +60,7 @@ e_mini_calendar_config_get_property (GObject *object, guint property_id, GValue
EMiniCalendarConfig *mini_config;
mini_config = E_MINI_CALENDAR_CONFIG (object);
-
+
switch (property_id) {
case PROP_CALENDAR:
g_value_set_object (value, e_mini_calendar_config_get_calendar (mini_config));
@@ -75,9 +75,9 @@ static void
e_mini_calendar_config_dispose (GObject *object)
{
EMiniCalendarConfig *mini_config = E_MINI_CALENDAR_CONFIG (object);
-
+
e_mini_calendar_config_set_calendar (mini_config, NULL);
-
+
if (G_OBJECT_CLASS (e_mini_calendar_config_parent_class)->dispose)
G_OBJECT_CLASS (e_mini_calendar_config_parent_class)->dispose (object);
}
@@ -87,11 +87,11 @@ e_mini_calendar_config_finalize (GObject *object)
{
EMiniCalendarConfig *mini_config = E_MINI_CALENDAR_CONFIG (object);
EMiniCalendarConfigPrivate *priv;
-
+
priv = mini_config->priv;
g_free (priv);
-
+
if (G_OBJECT_CLASS (e_mini_calendar_config_parent_class)->finalize)
G_OBJECT_CLASS (e_mini_calendar_config_parent_class)->finalize (object);
}
@@ -101,7 +101,7 @@ e_mini_calendar_config_class_init (EMiniCalendarConfigClass *klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
GParamSpec *spec;
-
+
/* Method override */
gobject_class->set_property = e_mini_calendar_config_set_property;
gobject_class->get_property = e_mini_calendar_config_get_property;
@@ -124,14 +124,14 @@ EMiniCalendarConfig *
e_mini_calendar_config_new (ECalendar *mini_cal)
{
EMiniCalendarConfig *mini_config;
-
+
mini_config = g_object_new (e_mini_calendar_config_get_type (), "calendar", mini_cal, NULL);
return mini_config;
}
ECalendar *
-e_mini_calendar_config_get_calendar (EMiniCalendarConfig *mini_config)
+e_mini_calendar_config_get_calendar (EMiniCalendarConfig *mini_config)
{
EMiniCalendarConfigPrivate *priv;
@@ -139,14 +139,14 @@ e_mini_calendar_config_get_calendar (EMiniCalendarConfig *mini_config)
g_return_val_if_fail (E_IS_MINI_CALENDAR_CONFIG (mini_config), NULL);
priv = mini_config->priv;
-
+
return priv->mini_cal;
}
static void
-set_week_start (ECalendar *mini_cal)
+set_week_start (ECalendar *mini_cal)
{
- int week_start_day;
+ int week_start_day;
week_start_day = calendar_config_get_week_start_day ();
@@ -163,14 +163,14 @@ week_start_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointe
{
EMiniCalendarConfig *mini_config = data;
EMiniCalendarConfigPrivate *priv;
-
+
priv = mini_config->priv;
-
+
set_week_start (priv->mini_cal);
}
static void
-set_dnav_show_week_no (ECalendar *mini_cal)
+set_dnav_show_week_no (ECalendar *mini_cal)
{
gboolean show_week_no;
@@ -186,29 +186,29 @@ dnav_show_week_no_changed_cb (GConfClient *client, guint id, GConfEntry *entry,
{
EMiniCalendarConfig *mini_config = data;
EMiniCalendarConfigPrivate *priv;
-
+
priv = mini_config->priv;
-
+
set_dnav_show_week_no (priv->mini_cal);
}
void
-e_mini_calendar_config_set_calendar (EMiniCalendarConfig *mini_config, ECalendar *mini_cal)
+e_mini_calendar_config_set_calendar (EMiniCalendarConfig *mini_config, ECalendar *mini_cal)
{
EMiniCalendarConfigPrivate *priv;
guint not;
GList *l;
-
+
g_return_if_fail (mini_config != NULL);
g_return_if_fail (E_IS_MINI_CALENDAR_CONFIG (mini_config));
priv = mini_config->priv;
-
+
if (priv->mini_cal) {
g_object_unref (priv->mini_cal);
priv->mini_cal = NULL;
}
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
@@ -218,7 +218,7 @@ e_mini_calendar_config_set_calendar (EMiniCalendarConfig *mini_config, ECalendar
/* If the new view is NULL, return right now */
if (!mini_cal)
return;
-
+
priv->mini_cal = g_object_ref (mini_cal);
/* Week start */
diff --git a/calendar/gui/e-mini-calendar-config.h b/calendar/gui/e-mini-calendar-config.h
index a8ece07fbf..de252cdf25 100644
--- a/calendar/gui/e-mini-calendar-config.h
+++ b/calendar/gui/e-mini-calendar-config.h
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -30,7 +30,7 @@ G_BEGIN_DECLS
#define E_MINI_CALENDAR_CONFIG(obj) GTK_CHECK_CAST (obj, e_mini_calendar_config_get_type (), EMiniCalendarConfig)
#define E_MINI_CALENDAR_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_mini_calendar_config_get_type (), EMiniCalendarConfigClass)
#define E_IS_MINI_CALENDAR_CONFIG(obj) GTK_CHECK_TYPE (obj, e_mini_calendar_config_get_type ())
-
+
typedef struct _EMiniCalendarConfig EMiniCalendarConfig;
typedef struct _EMiniCalendarConfigClass EMiniCalendarConfigClass;
typedef struct _EMiniCalendarConfigPrivate EMiniCalendarConfigPrivate;
diff --git a/calendar/gui/e-select-names-editable.c b/calendar/gui/e-select-names-editable.c
index 74f4e16d50..c258c7f43c 100644
--- a/calendar/gui/e-select-names-editable.c
+++ b/calendar/gui/e-select-names-editable.c
@@ -6,7 +6,7 @@
* Copyright (C) 2003 Ximian Inc.
*
* This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -60,7 +60,7 @@ static void
esne_class_init (GObjectClass *klass)
{
klass->finalize = esne_finalize;
-
+
parent_class = E_NAME_SELECTOR_ENTRY_CLASS (g_type_class_peek_parent (klass));
}
@@ -68,7 +68,7 @@ GType
e_select_names_editable_get_type (void)
{
static GType esne_type = 0;
-
+
if (!esne_type) {
static const GTypeInfo esne_info = {
sizeof (ESelectNamesEditableClass),
@@ -84,15 +84,15 @@ e_select_names_editable_get_type (void)
static const GInterfaceInfo cell_editable_info = {
(GInterfaceInitFunc) esne_cell_editable_init,
- NULL,
- NULL
+ NULL,
+ NULL
};
-
+
esne_type = g_type_register_static (E_TYPE_NAME_SELECTOR_ENTRY, "ESelectNamesEditable", &esne_info, 0);
-
+
g_type_add_interface_static (esne_type, GTK_TYPE_CELL_EDITABLE, &cell_editable_info);
}
-
+
return esne_type;
}
@@ -141,7 +141,7 @@ e_select_names_editable_get_emails (ESelectNamesEditable *esne)
return NULL;
destination = destinations->data;
- if (e_destination_is_evolution_list (destination)) {
+ if (e_destination_is_evolution_list (destination)) {
const GList *list_dests, *l;
list_dests = e_destination_list_get_dests (destination);
@@ -151,7 +151,7 @@ e_select_names_editable_get_emails (ESelectNamesEditable *esne)
} else {
/* check if the contact is contact list, it does not contain all the email ids */
/* we dont expand it currently, TODO do we need to expand it by getting it from addressbook*/
- if (e_destination_get_contact (destination) &&
+ if (e_destination_get_contact (destination) &&
e_contact_get (e_destination_get_contact (destination), E_CONTACT_IS_LIST)) {
/* If its a contact_list which is not expanded, it wont have a email id,
so we can use the name as the email id */
@@ -202,10 +202,10 @@ e_select_names_editable_get_names (ESelectNamesEditable *esne)
if (!destinations)
return NULL;
- destination = destinations->data;
+ destination = destinations->data;
if (e_destination_is_evolution_list (destination)) {
const GList *list_dests, *l;
-
+
list_dests = e_destination_list_get_dests (destination);
for (l = list_dests; l != NULL; l = g_list_next (l)) {
result = g_list_append (result, g_strdup (e_destination_get_name (l->data)));
@@ -238,7 +238,7 @@ e_select_names_editable_set_address (ESelectNamesEditable *esne, const gchar *na
e_destination_set_name (destination, name);
e_destination_set_email (destination, email);
-
+
if (!destinations)
e_destination_store_append_destination (destination_store, destination);
g_object_unref (destination);
diff --git a/calendar/gui/e-select-names-editable.h b/calendar/gui/e-select-names-editable.h
index c2c7c2e3e9..5177bba391 100644
--- a/calendar/gui/e-select-names-editable.h
+++ b/calendar/gui/e-select-names-editable.h
@@ -6,7 +6,7 @@
* Copyright (C) 2003 Ximian Inc.
*
* This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-select-names-renderer.c b/calendar/gui/e-select-names-renderer.c
index 4cbc49bd05..e1c001cdc5 100644
--- a/calendar/gui/e-select-names-renderer.c
+++ b/calendar/gui/e-select-names-renderer.c
@@ -6,7 +6,7 @@
* Copyright (C) 2003 Ximian Inc.
*
* This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -61,13 +61,13 @@ e_select_names_renderer_editing_done (GtkCellEditable *editable, ESelectNamesRen
g_signal_handlers_disconnect_matched (editable, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, cell);
if (GTK_ENTRY (editable)->editing_canceled) {
- gtk_cell_renderer_stop_editing (GTK_CELL_RENDERER (cell), TRUE);
+ gtk_cell_renderer_stop_editing (GTK_CELL_RENDERER (cell), TRUE);
goto cleanup;
}
-
+
addresses = e_select_names_editable_get_emails (E_SELECT_NAMES_EDITABLE (editable));
names = e_select_names_editable_get_names (E_SELECT_NAMES_EDITABLE (editable));
-
+
g_signal_emit (cell, signals [CELL_EDITED], 0, cell->priv->path, addresses, names);
g_list_foreach (addresses, (GFunc)g_free, NULL);
@@ -97,14 +97,14 @@ e_select_names_renderer_start_editing (GtkCellRenderer *cell, GdkEvent *event, G
ESelectNamesRenderer *sn_cell = E_SELECT_NAMES_RENDERER (cell);
GtkCellRendererText *text_cell = GTK_CELL_RENDERER_TEXT (cell);
ESelectNamesEditable *editable;
-
+
if (!text_cell->editable)
return NULL;
editable = E_SELECT_NAMES_EDITABLE (e_select_names_editable_new ());
gtk_entry_set_has_frame (GTK_ENTRY (editable), FALSE);
gtk_entry_set_alignment (GTK_ENTRY (editable), cell->xalign);
- if (sn_cell->priv->email && *sn_cell->priv->email)
+ if (sn_cell->priv->email && *sn_cell->priv->email)
e_select_names_editable_set_address (editable, sn_cell->priv->name, sn_cell->priv->email);
gtk_widget_show (GTK_WIDGET (editable));
@@ -182,7 +182,7 @@ e_select_names_renderer_class_init (ESelectNamesRendererClass *class)
{
GtkCellRendererClass *cell_class = GTK_CELL_RENDERER_CLASS (class);
GObjectClass *obj_class = G_OBJECT_CLASS (class);
-
+
obj_class->finalize = e_select_names_renderer_finalize;
obj_class->get_property = e_select_names_renderer_get_property;
obj_class->set_property = e_select_names_renderer_set_property;
diff --git a/calendar/gui/e-select-names-renderer.h b/calendar/gui/e-select-names-renderer.h
index e15b307e5f..8087977ace 100644
--- a/calendar/gui/e-select-names-renderer.h
+++ b/calendar/gui/e-select-names-renderer.h
@@ -6,7 +6,7 @@
* Copyright (C) 2003 Ximian Inc.
*
* This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -49,10 +49,10 @@ struct _ESelectNamesRendererClass
{
GtkCellRendererTextClass parent_class;
- void (* cell_edited) (ESelectNamesRenderer *renderer,
- const gchar *path,
- GList *addresses,
- GList *names);
+ void (* cell_edited) (ESelectNamesRenderer *renderer,
+ const gchar *path,
+ GList *addresses,
+ GList *names);
};
GType e_select_names_renderer_get_type (void);
diff --git a/calendar/gui/e-tasks.c b/calendar/gui/e-tasks.c
index a2faca60f4..b127fdab30 100644
--- a/calendar/gui/e-tasks.c
+++ b/calendar/gui/e-tasks.c
@@ -69,13 +69,13 @@ struct _ETasksPrivate {
ECal *default_client;
ECalView *query;
-
+
EConfigListener *config_listener;
/* The ECalendarTable showing the tasks. */
GtkWidget *tasks_view;
ECalendarTableConfig *tasks_view_config;
-
+
/* Calendar search bar for tasks */
GtkWidget *search_bar;
@@ -87,11 +87,11 @@ struct _ETasksPrivate {
/* The preview */
GtkWidget *preview;
-
+
gchar *current_uid;
char *sexp;
guint update_timeout;
-
+
/* View instance and the view menus handler */
GalViewInstance *view_instance;
GalViewMenus *view_menus;
@@ -145,27 +145,27 @@ table_cursor_change_cb (ETable *etable, int row, gpointer data)
priv = tasks->priv;
n_selected = e_table_selected_count (etable);
-
+
/* update the HTML widget */
if (n_selected != 1) {
e_cal_component_preview_clear (E_CAL_COMPONENT_PREVIEW (priv->preview));
return;
}
-
+
model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->tasks_view));
-
+
comp_data = e_cal_model_get_component_at (model, e_table_get_cursor_row (etable));
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (comp_data->icalcomp));
e_cal_component_preview_display (E_CAL_COMPONENT_PREVIEW (priv->preview), comp_data->client, comp);
-
+
e_cal_component_get_uid (comp, &uid);
if (priv->current_uid)
g_free (priv->current_uid);
priv->current_uid = g_strdup (uid);
-
+
g_object_unref (comp);
}
@@ -226,7 +226,7 @@ search_bar_sexp_changed_cb (CalSearchBar *cal_search, const char *sexp, gpointer
if (priv->sexp)
g_free (priv->sexp);
-
+
priv->sexp = g_strdup (sexp);
update_view (tasks);
@@ -256,14 +256,14 @@ vpaned_resized_cb (GtkWidget *widget, GdkEventButton *event, ETasks *tasks)
}
static void
-set_timezone (ETasks *tasks)
+set_timezone (ETasks *tasks)
{
ETasksPrivate *priv;
icaltimezone *zone;
GList *l;
-
+
priv = tasks->priv;
-
+
zone = calendar_config_get_icaltimezone ();
for (l = priv->clients_list; l != NULL; l = l->next) {
ECal *client = l->data;
@@ -271,7 +271,7 @@ set_timezone (ETasks *tasks)
e_cal_set_default_timezone (client, zone, NULL);
}
- if (priv->default_client)
+ if (priv->default_client)
/* FIXME Error checking */
e_cal_set_default_timezone (priv->default_client, zone, NULL);
@@ -283,7 +283,7 @@ static void
timezone_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer data)
{
ETasks *tasks = data;
-
+
set_timezone (tasks);
}
@@ -294,11 +294,11 @@ update_view (ETasks *tasks)
ECalModel *model;
char *real_sexp = NULL;
char *new_sexp = NULL;
-
+
priv = tasks->priv;
model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->tasks_view));
-
+
if ((new_sexp = calendar_config_get_hide_completed_tasks_sexp (FALSE)) != NULL) {
real_sexp = g_strdup_printf ("(and %s %s)", new_sexp, priv->sexp);
e_cal_model_set_search_query (model, real_sexp);
@@ -325,7 +325,7 @@ process_completed_tasks (ETasks *tasks, gboolean config_changed)
static gboolean
update_view_cb (ETasks *tasks)
-{
+{
ECalModel *model;
model = e_calendar_table_get_model (E_CALENDAR_TABLE (tasks->priv->tasks_view));
@@ -373,16 +373,16 @@ model_row_changed_cb (ETableModel *etm, int row, gpointer data)
static void
view_progress_cb (ECalModel *model, const char *message, int percent, ECalSourceType type, ETasks *tasks)
{
- e_calendar_table_set_status_message (E_CALENDAR_TABLE (e_tasks_get_calendar_table (tasks)),
+ e_calendar_table_set_status_message (E_CALENDAR_TABLE (e_tasks_get_calendar_table (tasks)),
message, percent);
}
static void
view_done_cb (ECalModel *model, ECalendarStatus status, ECalSourceType type, ETasks *tasks)
{
- e_calendar_table_set_status_message (E_CALENDAR_TABLE (e_tasks_get_calendar_table (tasks)),
+ e_calendar_table_set_status_message (E_CALENDAR_TABLE (e_tasks_get_calendar_table (tasks)),
NULL, -1);
-
+
}
static void
@@ -407,24 +407,24 @@ setup_config (ETasks *tasks)
guint not;
priv = tasks->priv;
-
+
/* Timezone */
set_timezone (tasks);
-
+
not = calendar_config_add_notification_timezone (timezone_changed_cb, tasks);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
-
- not = calendar_config_add_notification_hide_completed_tasks (config_hide_completed_tasks_changed_cb,
+
+ not = calendar_config_add_notification_hide_completed_tasks (config_hide_completed_tasks_changed_cb,
tasks);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
-
- not = calendar_config_add_notification_hide_completed_tasks_units (config_hide_completed_tasks_changed_cb,
+
+ not = calendar_config_add_notification_hide_completed_tasks_units (config_hide_completed_tasks_changed_cb,
tasks);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
-
- not = calendar_config_add_notification_hide_completed_tasks_value (config_hide_completed_tasks_changed_cb,
+
+ not = calendar_config_add_notification_hide_completed_tasks_value (config_hide_completed_tasks_changed_cb,
tasks);
- priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
+ priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
not = calendar_config_add_notification_preview_state (config_preview_state_changed_cb, tasks);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
@@ -570,7 +570,7 @@ table_drag_end (ETable *table,
}
*/
-static void
+static void
table_drag_data_delete (ETable *table,
int row,
int col,
@@ -635,7 +635,7 @@ setup_widgets (ETasks *tasks)
priv->tasks_view = e_calendar_table_new ();
g_object_set_data (G_OBJECT (priv->tasks_view), "tasks", tasks);
priv->tasks_view_config = e_calendar_table_config_new (E_CALENDAR_TABLE (priv->tasks_view));
-
+
g_signal_connect (priv->tasks_view, "user_created", G_CALLBACK (user_created_cb), tasks);
etable = e_table_scrolled_get_table (
@@ -648,7 +648,7 @@ setup_widgets (ETasks *tasks)
e_table_drag_source_set (etable, GDK_BUTTON1_MASK,
list_drag_types, num_list_drag_types,
GDK_ACTION_MOVE|GDK_ACTION_COPY|GDK_ACTION_ASK);
-
+
g_signal_connect (etable, "table_drag_data_get",
G_CALLBACK(table_drag_data_get), tasks);
g_signal_connect (etable, "table_drag_data_delete",
@@ -670,11 +670,11 @@ setup_widgets (ETasks *tasks)
g_signal_connect (etable, "selection_change", G_CALLBACK (table_selection_change_cb), tasks);
/* Timeout check to hide completed items */
- priv->update_timeout = g_timeout_add_full (G_PRIORITY_LOW, 60000, (GSourceFunc) update_view_cb, tasks, NULL);
+ priv->update_timeout = g_timeout_add_full (G_PRIORITY_LOW, 60000, (GSourceFunc) update_view_cb, tasks, NULL);
/* create the task detail */
priv->preview = e_cal_component_preview_new ();
- e_cal_component_preview_set_default_timezone (E_CAL_COMPONENT_PREVIEW (priv->preview), calendar_config_get_icaltimezone ());
+ e_cal_component_preview_set_default_timezone (E_CAL_COMPONENT_PREVIEW (priv->preview), calendar_config_get_icaltimezone ());
gtk_paned_add2 (GTK_PANED (priv->paned), priv->preview);
state = calendar_config_get_preview_state ();
@@ -684,7 +684,7 @@ setup_widgets (ETasks *tasks)
model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->tasks_view));
g_signal_connect (G_OBJECT (model), "model_row_changed",
G_CALLBACK (model_row_changed_cb), tasks);
-
+
g_signal_connect (G_OBJECT (model), "cal_view_progress",
G_CALLBACK (view_progress_cb), tasks);
g_signal_connect (G_OBJECT (model), "cal_view_done",
@@ -702,7 +702,7 @@ e_tasks_class_init (ETasksClass *class)
e_tasks_signals[SELECTION_CHANGED] =
gtk_signal_new ("selection_changed",
GTK_RUN_LAST,
- G_TYPE_FROM_CLASS (object_class),
+ G_TYPE_FROM_CLASS (object_class),
GTK_SIGNAL_OFFSET (ETasksClass, selection_changed),
g_cclosure_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
@@ -766,7 +766,7 @@ static void
e_tasks_init (ETasks *tasks)
{
ETasksPrivate *priv;
-
+
priv = g_new0 (ETasksPrivate, 1);
tasks->priv = priv;
@@ -776,7 +776,7 @@ e_tasks_init (ETasks *tasks)
setup_config (tasks);
setup_widgets (tasks);
- priv->clients = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_object_unref);
+ priv->clients = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_object_unref);
priv->query = NULL;
priv->view_instance = NULL;
priv->view_menus = NULL;
@@ -850,7 +850,7 @@ e_tasks_destroy (GtkObject *object)
g_free (priv->current_uid);
priv->current_uid = NULL;
}
-
+
if (priv->sexp) {
g_free (priv->sexp);
priv->sexp = NULL;
@@ -860,12 +860,12 @@ e_tasks_destroy (GtkObject *object)
g_source_remove (priv->update_timeout);
priv->update_timeout = 0;
}
-
+
if (priv->tasks_view_config) {
g_object_unref (priv->tasks_view_config);
priv->tasks_view_config = NULL;
}
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
priv->notifications = NULL;
@@ -893,7 +893,7 @@ set_status_message (ETasks *tasks, const char *message, ...)
}
priv = tasks->priv;
-
+
e_calendar_table_set_status_message (E_CALENDAR_TABLE (priv->tasks_view), msg_string, -1);
}
@@ -929,7 +929,7 @@ backend_died_cb (ECal *client, gpointer data)
ETasks *tasks;
ETasksPrivate *priv;
ESource *source;
-
+
tasks = E_TASKS (data);
priv = tasks->priv;
@@ -941,10 +941,10 @@ backend_died_cb (ECal *client, gpointer data)
gtk_signal_emit (GTK_OBJECT (tasks), e_tasks_signals[SOURCE_REMOVED], source);
e_calendar_table_set_status_message (E_CALENDAR_TABLE (e_tasks_get_calendar_table (tasks)), NULL, -1);
-
+
e_error_run (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (tasks))),
"calendar:tasks-crashed", NULL);
-
+
g_object_unref (source);
}
@@ -1009,7 +1009,7 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, ETasks *tasks)
case E_CALENDAR_STATUS_OK :
g_signal_handlers_disconnect_matched (ecal, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, default_client_cal_opened_cb, NULL);
model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->tasks_view));
-
+
e_cal_model_set_default_client (model, ecal);
set_status_message (tasks, NULL);
break;
@@ -1046,11 +1046,11 @@ open_ecal (ETasks *tasks, ECal *cal, gboolean only_if_exists, open_func of)
icaltimezone *zone;
priv = tasks->priv;
-
+
zone = calendar_config_get_icaltimezone ();
e_cal_set_default_timezone (cal, zone, NULL);
-
+
set_status_message (tasks, _("Opening tasks at %s"), e_cal_get_uri (cal));
g_signal_connect (G_OBJECT (cal), "cal_opened", G_CALLBACK (of), tasks);
@@ -1063,7 +1063,7 @@ void
e_tasks_open_task (ETasks *tasks)
{
ECalendarTable *cal_table;
-
+
cal_table = e_tasks_get_calendar_table (tasks);
e_calendar_table_open_selected (cal_table);
}
@@ -1077,7 +1077,7 @@ e_tasks_new_task (ETasks *tasks)
const char *category;
ECal *ecal;
guint32 flags = 0;
-
+
g_return_if_fail (E_IS_TASKS (tasks));
priv = tasks->priv;
@@ -1086,9 +1086,9 @@ e_tasks_new_task (ETasks *tasks)
ecal = e_tasks_get_default_client (tasks);
if (!ecal)
return;
-
+
flags |= COMP_EDITOR_NEW_ITEM | COMP_EDITOR_USER_ORG;
-
+
comp = cal_comp_task_new_with_defaults (ecal);
category = cal_search_bar_get_category (CAL_SEARCH_BAR (priv->search_bar));
@@ -1117,32 +1117,32 @@ e_tasks_show_preview (ETasks *tasks, gboolean state)
ETable *etable;
const char *uid;
int n_selected;
-
+
etable = e_table_scrolled_get_table (E_TABLE_SCROLLED (E_CALENDAR_TABLE (priv->tasks_view)->etable));
n_selected = e_table_selected_count (etable);
-
+
if (n_selected != 1) {
e_cal_component_preview_clear (E_CAL_COMPONENT_PREVIEW (priv->preview));
} else {
model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->tasks_view));
-
+
comp_data = e_cal_model_get_component_at (model, e_table_get_cursor_row (etable));
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (comp_data->icalcomp));
-
+
e_cal_component_preview_display (E_CAL_COMPONENT_PREVIEW (priv->preview), comp_data->client, comp);
-
+
e_cal_component_get_uid (comp, &uid);
if (priv->current_uid)
g_free (priv->current_uid);
priv->current_uid = g_strdup (uid);
-
+
g_object_unref (comp);
}
gtk_widget_show (priv->preview);
} else {
- e_cal_component_preview_clear (E_CAL_COMPONENT_PREVIEW (priv->preview));
+ e_cal_component_preview_clear (E_CAL_COMPONENT_PREVIEW (priv->preview));
gtk_widget_hide (priv->preview);
}
}
@@ -1168,10 +1168,10 @@ e_tasks_add_todo_source (ETasks *tasks, ESource *source)
return TRUE;
} else {
ESource *default_source;
-
+
if (priv->default_client) {
default_source = e_cal_get_source (priv->default_client);
-
+
/* We don't have it but the default client is it */
if (!strcmp (e_source_peek_uid (default_source), uid))
client = g_object_ref (priv->default_client);
@@ -1188,7 +1188,7 @@ e_tasks_add_todo_source (ETasks *tasks, ESource *source)
g_signal_connect (G_OBJECT (client), "backend_error", G_CALLBACK (backend_error_cb), tasks);
g_signal_connect (G_OBJECT (client), "backend_died", G_CALLBACK (backend_died_cb), tasks);
- /* add the client to internal structure */
+ /* add the client to internal structure */
g_hash_table_insert (priv->clients, g_strdup (uid) , client);
priv->clients_list = g_list_prepend (priv->clients_list, client);
@@ -1215,19 +1215,19 @@ e_tasks_remove_todo_source (ETasks *tasks, ESource *source)
uid = e_source_peek_uid (source);
client = g_hash_table_lookup (priv->clients, uid);
- if (!client)
+ if (!client)
return TRUE;
-
+
priv->clients_list = g_list_remove (priv->clients_list, client);
g_signal_handlers_disconnect_matched (client, G_SIGNAL_MATCH_DATA,
- 0, 0, NULL, NULL, tasks);
+ 0, 0, NULL, NULL, tasks);
model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->tasks_view));
e_cal_model_remove_client (model, client);
g_hash_table_remove (priv->clients, uid);
-
+
gtk_signal_emit (GTK_OBJECT (tasks), e_tasks_signals[SOURCE_REMOVED], source);
@@ -1239,7 +1239,7 @@ e_tasks_set_default_source (ETasks *tasks, ESource *source)
{
ETasksPrivate *priv;
ECal *ecal;
-
+
g_return_val_if_fail (tasks != NULL, FALSE);
g_return_val_if_fail (E_IS_TASKS (tasks), FALSE);
g_return_val_if_fail (E_IS_SOURCE (source), FALSE);
@@ -1268,19 +1268,19 @@ ECal *
e_tasks_get_default_client (ETasks *tasks)
{
ETasksPrivate *priv;
-
+
g_return_val_if_fail (tasks != NULL, NULL);
g_return_val_if_fail (E_IS_TASKS (tasks), NULL);
priv = tasks->priv;
- return e_cal_model_get_default_client (e_calendar_table_get_model (E_CALENDAR_TABLE (priv->tasks_view)));
+ return e_cal_model_get_default_client (e_calendar_table_get_model (E_CALENDAR_TABLE (priv->tasks_view)));
}
/**
* e_tasks_complete_selected:
* @tasks: A tasks control widget
- *
+ *
* Marks the selected tasks complete
**/
void
@@ -1304,7 +1304,7 @@ e_tasks_complete_selected (ETasks *tasks)
/**
* e_tasks_delete_selected:
* @tasks: A tasks control widget.
- *
+ *
* Deletes the selected tasks in the task list.
**/
void
@@ -1329,7 +1329,7 @@ e_tasks_delete_selected (ETasks *tasks)
/**
* e_tasks_expunge:
* @tasks: A tasks control widget
- *
+ *
* Removes all tasks marked as completed
**/
void
@@ -1338,7 +1338,7 @@ e_tasks_delete_completed (ETasks *tasks)
ETasksPrivate *priv;
char *sexp;
GList *l;
-
+
g_return_if_fail (tasks != NULL);
g_return_if_fail (E_IS_TASKS (tasks));
@@ -1346,23 +1346,23 @@ e_tasks_delete_completed (ETasks *tasks)
sexp = g_strdup ("(is-completed?)");
- set_status_message (tasks, _("Expunging"));
+ set_status_message (tasks, _("Expunging"));
for (l = priv->clients_list; l != NULL; l = l->next) {
ECal *client = l->data;
GList *objects, *m;
gboolean read_only = TRUE;
-
+
e_cal_is_read_only (client, &read_only, NULL);
if (read_only)
continue;
-
+
if (!e_cal_get_object_list (client, sexp, &objects, NULL)) {
g_warning (G_STRLOC ": Could not get the objects");
-
+
continue;
}
-
+
for (m = objects; m; m = m->next) {
/* FIXME Better error handling */
e_cal_remove_object (client, icalcomponent_get_uid (m->data), NULL);
@@ -1396,7 +1396,7 @@ display_view_cb (GalViewInstance *instance, GalView *view, gpointer data)
* e_tasks_setup_view_menus:
* @tasks: A tasks widget.
* @uic: UI controller to use for the menus.
- *
+ *
* Sets up the #GalView menus for a tasks control. This function should be
* called from the Bonobo control activation callback for this tasks control.
* Also, the menus should be discarded using e_tasks_discard_view_menus().
@@ -1432,7 +1432,7 @@ e_tasks_setup_view_menus (ETasks *tasks, BonoboUIComponent *uic)
dir0 = g_build_filename (EVOLUTION_GALVIEWSDIR,
"tasks",
NULL);
- dir1 = g_build_filename (tasks_component_peek_base_directory (tasks_component_peek ()),
+ dir1 = g_build_filename (tasks_component_peek_base_directory (tasks_component_peek ()),
"tasks", "views", NULL);
gal_view_collection_set_storage_directories (collection,
dir0,
@@ -1472,7 +1472,7 @@ e_tasks_setup_view_menus (ETasks *tasks, BonoboUIComponent *uic)
/**
* e_tasks_discard_view_menus:
* @tasks: A tasks widget.
- *
+ *
* Discards the #GalView menus used by a tasks control. This function should be
* called from the Bonobo control deactivation callback for this tasks control.
* The menus should have been set up with e_tasks_setup_view_menus().
@@ -1510,7 +1510,7 @@ e_tasks_open_task_id (ETasks *tasks,
if (!src_uid || !comp_uid)
return;
-
+
for (l = tasks->priv->clients_list; l != NULL; l = l->next) {
ESource *client_src;
@@ -1521,7 +1521,7 @@ e_tasks_open_task_id (ETasks *tasks,
break;
}
- if (!client)
+ if (!client)
return;
e_cal_get_object (client, comp_uid, comp_rid, &icalcomp, NULL);
@@ -1539,9 +1539,9 @@ e_tasks_open_task_id (ETasks *tasks,
/**
* e_tasks_get_calendar_table:
* @tasks: A tasks widget.
- *
+ *
* Queries the #ECalendarTable contained in a tasks widget.
- *
+ *
* Return value: The #ECalendarTable that the tasks widget uses to display its
* information.
**/
diff --git a/calendar/gui/e-timezone-entry.c b/calendar/gui/e-timezone-entry.c
index 81bbcbaf66..86f8b81261 100644
--- a/calendar/gui/e-timezone-entry.c
+++ b/calendar/gui/e-timezone-entry.c
@@ -86,7 +86,7 @@ e_timezone_entry_class_init (ETimezoneEntryClass *class)
{
GtkObjectClass *object_class = (GtkObjectClass *) class;
GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (class) ;
-
+
object_class = (GtkObjectClass*) class;
widget_class->mnemonic_activate = e_timezone_entry_mnemonic_activate;
@@ -125,7 +125,7 @@ e_timezone_entry_init (ETimezoneEntry *tentry)
gtk_box_pack_start (GTK_BOX (tentry), priv->entry, TRUE, TRUE, 0);
gtk_widget_show (priv->entry);
g_signal_connect (priv->entry, "changed", G_CALLBACK (on_entry_changed), tentry);
-
+
priv->button = gtk_button_new ();
g_signal_connect (priv->button, "clicked", G_CALLBACK (on_button_clicked), tentry);
gtk_box_pack_start (GTK_BOX (tentry), priv->button, FALSE, FALSE, 6);
@@ -146,7 +146,7 @@ e_timezone_entry_init (ETimezoneEntry *tentry)
*
* Description: Creates a new #ETimezoneEntry widget which can be used
* to provide an easy to use way for entering dates and times.
- *
+ *
* Returns: a new #ETimezoneEntry widget.
*/
GtkWidget *
@@ -330,8 +330,8 @@ e_timezone_entry_set_entry (ETimezoneEntry *tentry)
gtk_entry_set_text (GTK_ENTRY (priv->entry), name_buffer);
/* do we need to hide the timezone entry at all? i know this overrules the previous case of hiding the timezone
- * entry field when we select the default timezone
- */
+ * entry field when we select the default timezone
+ */
gtk_widget_show (priv->entry);
g_free (name_buffer);
@@ -343,13 +343,13 @@ e_timezone_entry_mnemonic_activate (GtkWidget *widget,
gboolean group_cycling)
{
GtkButton *button = NULL;
-
+
if (GTK_WIDGET_CAN_FOCUS (widget)) {
button = GTK_BUTTON (((ETimezoneEntryPrivate *) ((ETimezoneEntry *) widget)->priv)->button);
if (button != NULL)
gtk_widget_grab_focus (GTK_WIDGET (button));
}
-
+
return TRUE;
}
diff --git a/calendar/gui/e-timezone-entry.h b/calendar/gui/e-timezone-entry.h
index 8c941077ad..3593b59008 100644
--- a/calendar/gui/e-timezone-entry.h
+++ b/calendar/gui/e-timezone-entry.h
@@ -30,11 +30,11 @@
*/
#ifndef __E_TIMEZONE_ENTRY_H_
-#define __E_TIMEZONE_ENTRY_H_
+#define __E_TIMEZONE_ENTRY_H_
#include <gtk/gtkhbox.h>
#include <libecal/e-cal.h>
-
+
G_BEGIN_DECLS
diff --git a/calendar/gui/e-week-view-config.c b/calendar/gui/e-week-view-config.c
index de2c9a895b..40404da915 100644
--- a/calendar/gui/e-week-view-config.c
+++ b/calendar/gui/e-week-view-config.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Rodrigo Moya <rodrigo@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -44,7 +44,7 @@ e_week_view_config_set_property (GObject *object, guint property_id, const GValu
EWeekViewConfig *view_config;
view_config = E_WEEK_VIEW_CONFIG (object);
-
+
switch (property_id) {
case PROP_VIEW:
e_week_view_config_set_view (view_config, g_value_get_object (value));
@@ -61,7 +61,7 @@ e_week_view_config_get_property (GObject *object, guint property_id, GValue *val
EWeekViewConfig *view_config;
view_config = E_WEEK_VIEW_CONFIG (object);
-
+
switch (property_id) {
case PROP_VIEW:
g_value_set_object (value, e_week_view_config_get_view (view_config));
@@ -78,7 +78,7 @@ e_week_view_config_dispose (GObject *object)
EWeekViewConfig *view_config = E_WEEK_VIEW_CONFIG (object);
e_week_view_config_set_view (view_config, NULL);
-
+
if (G_OBJECT_CLASS (e_week_view_config_parent_class)->dispose)
G_OBJECT_CLASS (e_week_view_config_parent_class)->dispose (object);
}
@@ -88,11 +88,11 @@ e_week_view_config_finalize (GObject *object)
{
EWeekViewConfig *view_config = E_WEEK_VIEW_CONFIG (object);
EWeekViewConfigPrivate *priv;
-
+
priv = view_config->priv;
g_free (priv);
-
+
if (G_OBJECT_CLASS (e_week_view_config_parent_class)->finalize)
G_OBJECT_CLASS (e_week_view_config_parent_class)->finalize (object);
}
@@ -102,7 +102,7 @@ e_week_view_config_class_init (EWeekViewConfigClass *klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
GParamSpec *spec;
-
+
/* Method override */
gobject_class->set_property = e_week_view_config_set_property;
gobject_class->get_property = e_week_view_config_get_property;
@@ -125,14 +125,14 @@ EWeekViewConfig *
e_week_view_config_new (EWeekView *week_view)
{
EWeekViewConfig *view_config;
-
+
view_config = g_object_new (e_week_view_config_get_type (), "view", week_view, NULL);
return view_config;
}
EWeekView *
-e_week_view_config_get_view (EWeekViewConfig *view_config)
+e_week_view_config_get_view (EWeekViewConfig *view_config)
{
EWeekViewConfigPrivate *priv;
@@ -140,16 +140,16 @@ e_week_view_config_get_view (EWeekViewConfig *view_config)
g_return_val_if_fail (E_IS_WEEK_VIEW_CONFIG (view_config), NULL);
priv = view_config->priv;
-
+
return priv->view;
}
static void
-set_timezone (EWeekView *week_view)
+set_timezone (EWeekView *week_view)
{
icaltimezone *zone;
-
- zone = calendar_config_get_icaltimezone ();
+
+ zone = calendar_config_get_icaltimezone ();
e_calendar_view_set_timezone (E_CALENDAR_VIEW (week_view), zone);
}
@@ -158,16 +158,16 @@ timezone_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer
{
EWeekViewConfig *view_config = data;
EWeekViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_timezone (priv->view);
}
static void
-set_week_start (EWeekView *week_view)
+set_week_start (EWeekView *week_view)
{
- int week_start_week;
+ int week_start_week;
week_start_week = calendar_config_get_week_start_day ();
@@ -182,14 +182,14 @@ week_start_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointe
{
EWeekViewConfig *view_config = data;
EWeekViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_week_start (priv->view);
}
static void
-set_twentyfour_hour (EWeekView *week_view)
+set_twentyfour_hour (EWeekView *week_view)
{
gboolean use_24_hour;
@@ -203,14 +203,14 @@ twentyfour_hour_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gp
{
EWeekViewConfig *view_config = data;
EWeekViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_twentyfour_hour (priv->view);
}
static void
-set_show_event_end (EWeekView *week_view)
+set_show_event_end (EWeekView *week_view)
{
gboolean show_event_end;
@@ -224,14 +224,14 @@ show_event_end_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpo
{
EWeekViewConfig *view_config = data;
EWeekViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_show_event_end (priv->view);
}
static void
-set_compress_weekend (EWeekView *week_view)
+set_compress_weekend (EWeekView *week_view)
{
gboolean compress_weekend;
@@ -245,29 +245,29 @@ compress_weekend_changed_cb (GConfClient *client, guint id, GConfEntry *entry, g
{
EWeekViewConfig *view_config = data;
EWeekViewConfigPrivate *priv;
-
+
priv = view_config->priv;
-
+
set_compress_weekend (priv->view);
}
void
-e_week_view_config_set_view (EWeekViewConfig *view_config, EWeekView *week_view)
+e_week_view_config_set_view (EWeekViewConfig *view_config, EWeekView *week_view)
{
EWeekViewConfigPrivate *priv;
guint not;
GList *l;
-
+
g_return_if_fail (view_config != NULL);
g_return_if_fail (E_IS_WEEK_VIEW_CONFIG (view_config));
priv = view_config->priv;
-
+
if (priv->view) {
g_object_unref (priv->view);
priv->view = NULL;
}
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
@@ -277,26 +277,26 @@ e_week_view_config_set_view (EWeekViewConfig *view_config, EWeekView *week_view)
/* If the new view is NULL, return right now */
if (!week_view)
return;
-
+
priv->view = g_object_ref (week_view);
/* Time zone */
set_timezone (week_view);
-
+
not = calendar_config_add_notification_timezone (timezone_changed_cb, view_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
-
+
/* Week start */
- set_week_start (week_view);
+ set_week_start (week_view);
not = calendar_config_add_notification_week_start_day (week_start_changed_cb, view_config);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* 24 Hour format */
- set_twentyfour_hour (week_view);
+ set_twentyfour_hour (week_view);
not = calendar_config_add_notification_24_hour_format (twentyfour_hour_changed_cb, view_config);
- priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
+ priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* Show event end */
set_show_event_end (week_view);
diff --git a/calendar/gui/e-week-view-config.h b/calendar/gui/e-week-view-config.h
index 2cbedf51e3..f79679837c 100644
--- a/calendar/gui/e-week-view-config.h
+++ b/calendar/gui/e-week-view-config.h
@@ -1,12 +1,12 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* JP Rosevear <jpr@ximian.com>
*
* Copyright 2003, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -30,7 +30,7 @@ G_BEGIN_DECLS
#define E_WEEK_VIEW_CONFIG(obj) GTK_CHECK_CAST (obj, e_week_view_config_get_type (), EWeekViewConfig)
#define E_WEEK_VIEW_CONFIG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, e_week_view_config_get_type (), EWeekViewConfigClass)
#define E_IS_WEEK_VIEW_CONFIG(obj) GTK_CHECK_TYPE (obj, e_week_view_config_get_type ())
-
+
typedef struct _EWeekViewConfig EWeekViewConfig;
typedef struct _EWeekViewConfigClass EWeekViewConfigClass;
typedef struct _EWeekViewConfigPrivate EWeekViewConfigPrivate;
diff --git a/calendar/gui/e-week-view-event-item.c b/calendar/gui/e-week-view-event-item.c
index 8ac563191a..f31932b050 100644
--- a/calendar/gui/e-week-view-event-item.c
+++ b/calendar/gui/e-week-view-event-item.c
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 2001, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -143,7 +143,7 @@ e_week_view_event_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
item = GNOME_CANVAS_ITEM (o);
wveitem = E_WEEK_VIEW_EVENT_ITEM (o);
-
+
switch (arg_id){
case ARG_EVENT_NUM:
wveitem->event_num = GTK_VALUE_INT (*arg);
@@ -270,7 +270,7 @@ e_week_view_event_item_draw (GnomeCanvasItem *canvas_item,
/* Get the start & end times in 24-hour format. */
start_hour = event->start_minute / 60;
start_minute = event->start_minute % 60;
-
+
/* Modulo 24 because a midnight end time will be '24' */
end_hour = (event->end_minute / 60) % 24;
end_minute = event->end_minute % 60;
@@ -617,17 +617,17 @@ e_week_view_event_item_draw_icons (EWeekViewEventItem *wveitem,
draw_recurrence_icon = TRUE;
num_icons++;
}
-
+
if (e_cal_component_has_attachments (comp)) {
draw_attach_icon = TRUE;
num_icons++;
}
-
+
if (e_cal_component_has_organizer (comp)) {
draw_meeting_icon = TRUE;
num_icons++;
}
-
+
if (event->different_timezone) {
draw_timezone_icon = TRUE;
num_icons++;
@@ -664,7 +664,7 @@ e_week_view_event_item_draw_icons (EWeekViewEventItem *wveitem,
0, 0);
icon_x += icon_x_inc;
}
-
+
if (draw_recurrence_icon && icon_x + E_WEEK_VIEW_ICON_WIDTH <= x2) {
gdk_gc_set_clip_mask (gc, NULL);
gdk_draw_pixbuf (drawable, gc,
@@ -870,7 +870,7 @@ e_week_view_event_item_draw (GnomeCanvasItem *canvas_item,
/* Get the start & end times in 24-hour format. */
start_hour = event->start_minute / 60;
start_minute = event->start_minute % 60;
-
+
/* Modulo 24 because a midnight end time will be '24' */
end_hour = (event->end_minute / 60) % 24;
end_minute = event->end_minute % 60;
@@ -886,7 +886,7 @@ e_week_view_event_item_draw (GnomeCanvasItem *canvas_item,
time_x = x1 + E_WEEK_VIEW_EVENT_L_PAD + 1;
rect_x = x1 + E_WEEK_VIEW_EVENT_L_PAD;
rect_w = x2 - x1 - E_WEEK_VIEW_EVENT_L_PAD - E_WEEK_VIEW_EVENT_R_PAD + 1;
-
+
if (gdk_color_parse (e_cal_model_get_color_for_component (e_calendar_view_get_model (E_CALENDAR_VIEW (week_view)),
event->comp_data),
&bg_color)) {
@@ -906,17 +906,17 @@ e_week_view_event_item_draw (GnomeCanvasItem *canvas_item,
red = week_view->colors[E_WEEK_VIEW_COLOR_EVENT_BACKGROUND].green;
green = week_view->colors[E_WEEK_VIEW_COLOR_EVENT_BACKGROUND].green;
blue = week_view->colors[E_WEEK_VIEW_COLOR_EVENT_BACKGROUND].green;
- }
+ }
/* Here we draw the border around the event*/
cairo_save (cr);
- cx0 = rect_x;
+ cx0 = rect_x;
cy0 = y1 + 1;
rect_width = rect_w;
rect_height = y2 - y1 - 1;
- radius = 12;
+ radius = 12;
draw_curved_rectangle (cr, cx0, cy0, rect_width, rect_height, radius);
@@ -924,17 +924,17 @@ e_week_view_event_item_draw (GnomeCanvasItem *canvas_item,
cairo_set_source_rgb (cr, red/cc, green/cc, blue/cc);
cairo_stroke (cr);
cairo_restore (cr);
-
+
/* Fill it in the Event */
cairo_save (cr);
- cx0 = rect_x + 1.5;
+ cx0 = rect_x + 1.5;
cy0 = y1 + 2.75;
rect_width = rect_w - 3.;
rect_height = y2 - y1 - 4.5;
- radius = 8;
+ radius = 8;
draw_curved_rectangle (cr, cx0, cy0, rect_width, rect_height, radius);
@@ -1045,16 +1045,16 @@ e_week_view_event_item_draw (GnomeCanvasItem *canvas_item,
red = week_view->colors[E_WEEK_VIEW_COLOR_EVENT_BACKGROUND].green;
green = week_view->colors[E_WEEK_VIEW_COLOR_EVENT_BACKGROUND].green;
blue = week_view->colors[E_WEEK_VIEW_COLOR_EVENT_BACKGROUND].green;
- }
+ }
/* Here we draw the border around the event */
- cx0 = rect_x;
+ cx0 = rect_x;
cy0 = y1 + 1;
rect_width = rect_w;
rect_height = y2 - y1 - 1;
- radius = 12;
+ radius = 12;
draw_curved_rectangle (cr, cx0, cy0, rect_width, rect_height, radius);
@@ -1067,12 +1067,12 @@ e_week_view_event_item_draw (GnomeCanvasItem *canvas_item,
cairo_save (cr);
- cx0 = rect_x + 1.5;
+ cx0 = rect_x + 1.5;
cy0 = y1 + 2.75;
rect_width = rect_w - 3.;
rect_height = y2 - y1 - 4.5;
- radius = 8;
+ radius = 8;
draw_curved_rectangle (cr, cx0, cy0, rect_width, rect_height, radius);
@@ -1254,7 +1254,7 @@ e_week_view_draw_time (EWeekView *week_view,
time_x,
time_y_small_font,
layout);
-
+
pango_layout_set_font_description (layout, style->font_desc);
time_x += week_view->small_digit_width * 2;
@@ -1262,7 +1262,7 @@ e_week_view_draw_time (EWeekView *week_view,
/* Draw the 'am'/'pm' suffix, if 12-hour format. */
if (!e_calendar_view_get_use_24_hour_format (E_CALENDAR_VIEW (week_view))) {
pango_layout_set_text (layout, suffix, -1);
-
+
gdk_draw_layout (drawable, gc,
time_x,
time_y_normal_font,
@@ -1329,7 +1329,7 @@ e_week_view_event_item_draw_icons (EWeekViewEventItem *wveitem,
draw_recurrence_icon = TRUE;
num_icons++;
}
-
+
if (e_cal_component_has_attachments (comp)) {
draw_attach_icon = TRUE;
num_icons++;
@@ -1339,7 +1339,7 @@ e_week_view_event_item_draw_icons (EWeekViewEventItem *wveitem,
draw_meeting_icon = TRUE;
num_icons++;
}
-
+
if (event->different_timezone) {
draw_timezone_icon = TRUE;
num_icons++;
@@ -1371,7 +1371,7 @@ e_week_view_event_item_draw_icons (EWeekViewEventItem *wveitem,
icon_x += icon_x_inc;
}
-
+
if (draw_recurrence_icon && icon_x + E_WEEK_VIEW_ICON_WIDTH <= x2) {
cairo_save (cr);
gdk_cairo_set_source_pixbuf (cr, week_view->recurrence_icon, icon_x, icon_y);
diff --git a/calendar/gui/e-week-view-event-item.h b/calendar/gui/e-week-view-event-item.h
index 404359cd50..59440ef291 100644
--- a/calendar/gui/e-week-view-event-item.h
+++ b/calendar/gui/e-week-view-event-item.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 2001, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-week-view-layout.h b/calendar/gui/e-week-view-layout.h
index 0d42429bd1..9f51f53bd8 100644
--- a/calendar/gui/e-week-view-layout.h
+++ b/calendar/gui/e-week-view-layout.h
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 2001, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-week-view-main-item.c b/calendar/gui/e-week-view-main-item.c
index abfc0993cd..9f214af1d2 100644
--- a/calendar/gui/e-week-view-main-item.c
+++ b/calendar/gui/e-week-view-main-item.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -110,7 +110,7 @@ e_week_view_main_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
EWeekViewMainItem *wvmitem;
wvmitem = E_WEEK_VIEW_MAIN_ITEM (o);
-
+
switch (arg_id){
case ARG_WEEK_VIEW:
wvmitem->week_view = GTK_VALUE_POINTER (*arg);
@@ -281,7 +281,7 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem,
width - 5, line_y - y);
}
}
-
+
/* Display the date in the top of the cell.
In the week view, display the long format "10 January" in all cells,
or abbreviate it to "10 Jan" or "10" if that doesn't fit.
@@ -338,10 +338,10 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem,
} else if (week_view->multi_week_view) {
struct icaltimetype tt;
- /* Check if we are drawing today */
+ /* Check if we are drawing today */
tt = icaltime_from_timet_with_zone (time (NULL), FALSE,
e_calendar_view_get_timezone (E_CALENDAR_VIEW (week_view)));
- if (g_date_get_year (date) == tt.year
+ if (g_date_get_year (date) == tt.year
&& g_date_get_month (date) == tt.month
&& g_date_get_day (date) == tt.day) {
gdk_gc_set_foreground (gc, &week_view->colors[E_WEEK_VIEW_COLOR_TODAY]);
@@ -357,11 +357,11 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem,
g_date_strftime (buffer, sizeof (buffer),
format_string ? format_string : "<b>%d</b>", date);
layout = gtk_widget_create_pango_layout (GTK_WIDGET (week_view), buffer);
- pango_layout_set_markup (layout, buffer, strlen(buffer));
+ pango_layout_set_markup (layout, buffer, strlen(buffer));
} else {
g_date_strftime (buffer, sizeof (buffer),
format_string ? format_string : "%d", date);
- layout = gtk_widget_create_pango_layout (GTK_WIDGET (week_view), buffer);
+ layout = gtk_widget_create_pango_layout (GTK_WIDGET (week_view), buffer);
}
pango_layout_get_pixel_size (layout, &date_width, NULL);
@@ -440,9 +440,9 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem,
month starts (defaults are white for odd - January, March, ... and
light gray for even). In the week view the background is always the
same color, the color used for the odd months in the month view. */
- if (week_view->multi_week_view && (month % 2 == 0))
+ if (week_view->multi_week_view && (month % 2 == 0))
bg_color = &week_view->colors[E_WEEK_VIEW_COLOR_EVEN_MONTHS];
- else
+ else
bg_color = &week_view->colors[E_WEEK_VIEW_COLOR_ODD_MONTHS];
cairo_save (cr);
@@ -481,7 +481,7 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem,
gdk_cairo_set_source_color (cr, &week_view->colors[E_WEEK_VIEW_COLOR_SELECTED]);
}
- if (week_view->multi_week_view) {
+ if (week_view->multi_week_view) {
cairo_rectangle (cr, x + 2, y + 1,
width - 5,
E_WEEK_VIEW_DATE_T_PAD - 1 +
@@ -493,9 +493,9 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem,
width - 5, line_y - y);
cairo_fill (cr);
}
- }
- cairo_restore (cr);
-
+ }
+ cairo_restore (cr);
+
/* Display the date in the top of the cell.
In the week view, display the long format "10 January" in all cells,
or abbreviate it to "10 Jan" or "10" if that doesn't fit.
@@ -553,10 +553,10 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem,
} else if (week_view->multi_week_view) {
struct icaltimetype tt;
- /* Check if we are drawing today */
+ /* Check if we are drawing today */
tt = icaltime_from_timet_with_zone (time (NULL), FALSE,
e_calendar_view_get_timezone (E_CALENDAR_VIEW (week_view)));
- if (g_date_get_year (date) == tt.year
+ if (g_date_get_year (date) == tt.year
&& g_date_get_month (date) == tt.month
&& g_date_get_day (date) == tt.day) {
gdk_cairo_set_source_color (cr, &week_view->colors[E_WEEK_VIEW_COLOR_TODAY]);
@@ -577,7 +577,7 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem,
layout = pango_cairo_create_layout (cr);
pango_layout_set_font_description (layout, font_desc);
pango_layout_set_text (layout, buffer, -1);
- pango_layout_set_markup (layout, buffer, strlen(buffer));
+ pango_layout_set_markup (layout, buffer, strlen(buffer));
} else {
g_date_strftime (buffer, sizeof (buffer),
format_string ? format_string : "%d", date);
diff --git a/calendar/gui/e-week-view-main-item.h b/calendar/gui/e-week-view-main-item.h
index 551d0b4c68..f475024051 100644
--- a/calendar/gui/e-week-view-main-item.h
+++ b/calendar/gui/e-week-view-main-item.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 2001, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-week-view-titles-item.c b/calendar/gui/e-week-view-titles-item.c
index 0ff79a8eff..08f401e599 100644
--- a/calendar/gui/e-week-view-titles-item.c
+++ b/calendar/gui/e-week-view-titles-item.c
@@ -1,13 +1,13 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -96,7 +96,7 @@ e_week_view_titles_item_set_arg (GtkObject *o, GtkArg *arg, guint arg_id)
EWeekViewTitlesItem *wvtitem;
wvtitem = E_WEEK_VIEW_TITLES_ITEM (o);
-
+
switch (arg_id){
case ARG_WEEK_VIEW:
wvtitem->week_view = GTK_VALUE_POINTER (*arg);
diff --git a/calendar/gui/e-week-view-titles-item.h b/calendar/gui/e-week-view-titles-item.h
index 1b276b0da1..e70193b14b 100644
--- a/calendar/gui/e-week-view-titles-item.h
+++ b/calendar/gui/e-week-view-titles-item.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 2001, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
diff --git a/calendar/gui/e-week-view.c b/calendar/gui/e-week-view.c
index be189a0905..6915ec1b7d 100644
--- a/calendar/gui/e-week-view.c
+++ b/calendar/gui/e-week-view.c
@@ -251,10 +251,10 @@ time_range_changed_cb (ECalModel *model, time_t start_time, time_t end_time, gpo
/* Calculate the weekday of the given date, 0 = Mon. */
weekday = g_date_get_weekday (&date) - 1;
-
+
/* Convert it to an offset from the start of the display. */
week_start_offset = (weekday + 7 - week_view->display_start_day) % 7;
-
+
/* Set the day_offset to the result, so we move back to the
start of the week. */
day_offset = week_start_offset;
@@ -270,7 +270,7 @@ time_range_changed_cb (ECalModel *model, time_t start_time, time_t end_time, gpo
week_view->base_date = base_date;
update_adjustment_value = TRUE;
}
-
+
/* See if we need to update the first day shown. */
if (!g_date_valid (&week_view->first_day_shown)
|| g_date_compare (&week_view->first_day_shown, &base_date)) {
@@ -285,13 +285,13 @@ time_range_changed_cb (ECalModel *model, time_t start_time, time_t end_time, gpo
/* Reset the adjustment value to 0 if the base address has changed.
Note that we do this after updating first_day_shown so that our
signal handler will not try to reload the events. */
- if (update_adjustment_value)
+ if (update_adjustment_value)
gtk_adjustment_set_value (GTK_RANGE (week_view->vscrollbar)->adjustment, 0);
gtk_widget_queue_draw (week_view->main_canvas);
/* FIXME Preserve selection if possible */
- if (week_view->selection_start_day == -1 ||
+ if (week_view->selection_start_day == -1 ||
(week_view->multi_week_view ? week_view->weeks_shown * 7 : 7) <= week_view->selection_start_day)
e_week_view_set_selected_time_range (E_CALENDAR_VIEW (week_view), start_time, start_time);
}
@@ -390,9 +390,9 @@ model_rows_deleted_cb (ETableModel *etm, int row, int count, gpointer user_data)
{
EWeekView *week_view = E_WEEK_VIEW (user_data);
int i;
-
+
/* FIXME Stop editing? */
-
+
for (i = row + count; i > row; i--) {
gint event_num;
const char *uid, *rid = NULL;
@@ -426,7 +426,7 @@ timezone_changed_cb (ECalendarView *cal_view, icaltimezone *old_zone,
struct icaltimetype tt = icaltime_null_time ();
time_t lower;
EWeekView *week_view = (EWeekView *) cal_view;
-
+
g_return_if_fail (E_IS_WEEK_VIEW (week_view));
/* If we don't have a valid date set yet, just return. */
@@ -589,7 +589,7 @@ e_week_view_init (EWeekView *week_view)
/* Get the model */
model = e_calendar_view_get_model (E_CALENDAR_VIEW (week_view));
-
+
/* connect to ECalModel's signals */
g_signal_connect (G_OBJECT (model), "time_range_changed",
G_CALLBACK (time_range_changed_cb), week_view);
@@ -618,10 +618,10 @@ GtkWidget *
e_week_view_new (void)
{
GtkWidget *week_view;
-
+
week_view = GTK_WIDGET (g_object_new (e_week_view_get_type (), NULL));
e_cal_model_set_flags (e_calendar_view_get_model (E_CALENDAR_VIEW (week_view)), E_CAL_MODEL_FLAGS_EXPAND_RECURRENCES);
-
+
return week_view;
}
@@ -686,7 +686,7 @@ e_week_view_realize (GtkWidget *widget)
/* Allocate the colors. */
e_week_view_set_colors(week_view, widget);
-
+
gdk_gc_set_colormap (week_view->main_gc, colormap);
/* Create the pixmaps. */
@@ -780,9 +780,9 @@ static GdkColor
e_week_view_get_text_color (EWeekView *week_view, EWeekViewEvent *event, GtkWidget *widget)
{
GdkColor color, bg_color;
- guint16 red, green, blue;
+ guint16 red, green, blue;
gdouble cc = 65535.0;
-
+
red = week_view->colors[E_WEEK_VIEW_COLOR_EVENT_BACKGROUND].red;
green = week_view->colors[E_WEEK_VIEW_COLOR_EVENT_BACKGROUND].green;
blue = week_view->colors[E_WEEK_VIEW_COLOR_EVENT_BACKGROUND].blue;
@@ -1418,7 +1418,7 @@ e_week_view_set_selected_time_range_visible (EWeekView *week_view,
g_return_if_fail (E_IS_WEEK_VIEW (week_view));
time_to_gdate_with_zone (&date, start_time, e_calendar_view_get_timezone (E_CALENDAR_VIEW (week_view)));
-
+
/* Set the selection to the given days. */
week_view->selection_start_day = g_date_get_julian (&date)
- g_date_get_julian (&week_view->first_day_shown);
@@ -1848,23 +1848,23 @@ e_week_view_recalc_display_start_day (EWeekView *week_view)
static void
set_text_as_bold (EWeekViewEvent *event, EWeekViewEventSpan *span)
{
- ECalComponent *comp;
+ ECalComponent *comp;
char *address;
GSList *attendees, *l;
ECalComponentAttendee *at = NULL;
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (event->comp_data->icalcomp));
- address = itip_get_comp_attendee (comp, event->comp_data->client);
+ address = itip_get_comp_attendee (comp, event->comp_data->client);
e_cal_component_get_attendee_list (comp, &attendees);
for (l = attendees; l; l = l->next) {
ECalComponentAttendee *attendee = l->data;
if (g_str_equal (itip_strip_mailto (attendee->value), address)) {
- at = attendee;
+ at = attendee;
break;
- }
+ }
}
/* The attendee has not yet accepted the meeting, display the summary as bolded.
@@ -2115,7 +2115,7 @@ e_week_view_on_button_press (GtkWidget *widget,
/* FIXME: Optimise? */
gtk_widget_queue_draw (week_view->main_canvas);
}
-
+
e_week_view_show_popup_menu (week_view, event, -1);
}
@@ -2149,18 +2149,18 @@ e_week_view_on_scroll (GtkWidget *widget,
gfloat new_value;
GtkWidget *tool_window = g_object_get_data (G_OBJECT (week_view), "tooltip-window");
guint timeout;
-
+
timeout = GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (week_view), "tooltip-timeout"));
if (timeout) {
g_source_remove (timeout);
g_object_set_data (G_OBJECT (week_view), "tooltip-timeout", NULL);
}
-
+
if (tool_window) {
gtk_widget_destroy (tool_window);
g_object_set_data (G_OBJECT (week_view), "tooltip-window", NULL);
}
-
+
switch (scroll->direction){
case GDK_SCROLL_UP:
new_value = adj->value - adj->page_increment;
@@ -2171,10 +2171,10 @@ e_week_view_on_scroll (GtkWidget *widget,
default:
return FALSE;
}
-
+
new_value = CLAMP (new_value, adj->lower, adj->upper - adj->page_size);
gtk_adjustment_set_value (adj, new_value);
-
+
return TRUE;
}
@@ -2560,7 +2560,7 @@ tooltip_get_view_event (EWeekView *week_view, int day, int event_num)
EWeekViewEvent *pevent;
pevent = &g_array_index (week_view->events, EWeekViewEvent, event_num);
-
+
return pevent;
}
@@ -2570,20 +2570,20 @@ tooltip_destroy (EWeekView *week_view, GnomeCanvasItem *item)
int event_num = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (item), "event-num"));
EWeekViewEvent *pevent;
guint timeout;
-
+
timeout = GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (week_view), "tooltip-timeout"));
if (timeout) {
g_source_remove (timeout);
g_object_set_data (G_OBJECT (week_view), "tooltip-timeout", NULL);
}
-
+
pevent = tooltip_get_view_event (week_view, -1, event_num);
if (pevent) {
if (pevent->tooltip && g_object_get_data (G_OBJECT (week_view), "tooltip-window")) {
gtk_widget_destroy (pevent->tooltip);
pevent->tooltip = NULL;
}
-
+
g_object_set_data (G_OBJECT (week_view), "tooltip-window", NULL);
}
}
@@ -2595,36 +2595,36 @@ tooltip_event_cb (GnomeCanvasItem *item,
{
int event_num = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (item), "event-num"));
EWeekViewEvent *pevent;
-
+
pevent = tooltip_get_view_event (view, -1, event_num);
-
+
switch (event->type) {
case GDK_ENTER_NOTIFY:
{
ECalendarViewEventData *data;
-
+
data = g_malloc (sizeof (ECalendarViewEventData));
-
+
pevent->x = ((GdkEventCrossing *)event)->x_root;
pevent->y = ((GdkEventCrossing *)event)->y_root;
- pevent->tooltip = NULL;
+ pevent->tooltip = NULL;
data->cal_view = (ECalendarView *)view;
data->day = -1;
data->event_num = event_num;
data->get_view_event = (ECalendarViewEvent * (*)(ECalendarView *, int, int)) tooltip_get_view_event;
pevent->timeout = g_timeout_add (500, (GSourceFunc)e_calendar_view_get_tooltips, data);
- g_object_set_data ((GObject *)view, "tooltip-timeout", GUINT_TO_POINTER (pevent->timeout));
-
+ g_object_set_data ((GObject *)view, "tooltip-timeout", GUINT_TO_POINTER (pevent->timeout));
+
return TRUE;
}
case GDK_MOTION_NOTIFY:
pevent->x = ((GdkEventMotion *)event)->x_root;
pevent->y = ((GdkEventMotion *)event)->y_root;
pevent->tooltip = (GtkWidget *)g_object_get_data (G_OBJECT (view), "tooltip-window");
-
+
if (pevent->tooltip) {
- e_calendar_view_move_tip (pevent->tooltip, pevent->x+16, pevent->y+16);
+ e_calendar_view_move_tip (pevent->tooltip, pevent->x+16, pevent->y+16);
}
return TRUE;
@@ -2716,12 +2716,12 @@ e_week_view_reshape_event_span (EWeekView *week_view,
e_week_view_event_item_get_type (),
NULL);
}
-
+
g_object_set_data ((GObject *)span->background_item, "event-num", GINT_TO_POINTER (event_num));
g_signal_connect (span->background_item, "event",
G_CALLBACK (tooltip_event_cb),
week_view);
-
+
gnome_canvas_item_set (span->background_item,
"event_num", event_num,
"span_num", span_num,
@@ -2751,16 +2751,16 @@ e_week_view_reshape_event_span (EWeekView *week_view,
"fill_color_gdk", &color,
"im_context", E_CANVAS (week_view->main_canvas)->im_context,
NULL);
-
+
if (free_text)
g_free ((gchar*)summary);
-
-/* Uncomment once the pango fix is in
- if (e_cal_get_static_capability (event->comp_data->client, CAL_STATIC_CAPABILITY_HAS_UNACCEPTED_MEETING)
+
+/* Uncomment once the pango fix is in
+ if (e_cal_get_static_capability (event->comp_data->client, CAL_STATIC_CAPABILITY_HAS_UNACCEPTED_MEETING)
&& e_cal_util_component_has_attendee (event->comp_data->icalcomp)) {
set_text_as_bold (event, span);
} */
- g_object_set_data (G_OBJECT (span->text_item), "event-num", GINT_TO_POINTER (event_num));
+ g_object_set_data (G_OBJECT (span->text_item), "event-num", GINT_TO_POINTER (event_num));
g_signal_connect (span->text_item, "event",
G_CALLBACK (e_week_view_on_text_item_event),
week_view);
@@ -2921,7 +2921,7 @@ e_week_view_start_editing_event (EWeekView *week_view,
ETextEventProcessorCommand command;
ECalModelComponent *comp_data;
gboolean read_only;
-
+
/* If we are already editing the event, just return. */
if (event_num == week_view->editing_event_num
&& span_num == week_view->editing_span_num)
@@ -2946,14 +2946,14 @@ e_week_view_start_editing_event (EWeekView *week_view,
/* Save the comp_data value because we use that as our invariant */
comp_data = event->comp_data;
-
+
e_canvas_item_grab_focus (span->text_item, TRUE);
-
+
/* If the above focus caused things to redraw, then find the
* the event and the span again */
if (event_num < week_view->events->len)
event = &g_array_index (week_view->events, EWeekViewEvent, event_num);
-
+
if (event_num >= week_view->events->len || event->comp_data != comp_data) {
/* Unfocussing can cause a removal but not a new
* addition so just run backwards through the
@@ -2963,8 +2963,8 @@ e_week_view_start_editing_event (EWeekView *week_view,
if (event->comp_data == comp_data)
break;
}
- g_return_val_if_fail (event_num >= 0, FALSE);
- }
+ g_return_val_if_fail (event_num >= 0, FALSE);
+ }
span = &g_array_index (week_view->spans, EWeekViewEventSpan, event->spans_index + span_num);
/* Try to move the cursor to the end of the text. */
@@ -3021,7 +3021,7 @@ cancel_editing (EWeekView *week_view)
if (free_text)
g_free ((gchar*)summary);
-
+
/* Stop editing */
e_week_view_stop_editing_event (week_view);
}
@@ -3035,13 +3035,13 @@ e_week_view_on_text_item_event (GnomeCanvasItem *item,
gint event_num, span_num;
int nevent = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (item), "event-num"));
EWeekViewEvent *pevent;
-
+
pevent = tooltip_get_view_event (week_view, -1, nevent);
#if 0
g_print ("In e_week_view_on_text_item_event\n");
#endif
-
+
switch (gdkevent->type) {
case GDK_KEY_PRESS:
tooltip_destroy (week_view, item);
@@ -3168,13 +3168,13 @@ e_week_view_on_text_item_event (GnomeCanvasItem *item,
&nspan))
return FALSE;
-
- g_object_set_data ((GObject *)item, "event-num", GINT_TO_POINTER (nevent));
-
+
+ g_object_set_data ((GObject *)item, "event-num", GINT_TO_POINTER (nevent));
+
pevent = tooltip_get_view_event (week_view, -1, nevent);
data = g_malloc (sizeof (ECalendarViewEventData));
-
+
pevent->x = ((GdkEventCrossing *)gdkevent)->x_root;
pevent->y = ((GdkEventCrossing *)gdkevent)->y_root;
pevent->tooltip = NULL;
@@ -3183,24 +3183,24 @@ e_week_view_on_text_item_event (GnomeCanvasItem *item,
data->day = -1;
data->event_num = nevent;
data->get_view_event = (ECalendarViewEvent * (*)(ECalendarView *, int, int)) tooltip_get_view_event;
- pevent->timeout = g_timeout_add (500, (GSourceFunc)e_calendar_view_get_tooltips, data);
+ pevent->timeout = g_timeout_add (500, (GSourceFunc)e_calendar_view_get_tooltips, data);
g_object_set_data ((GObject *)week_view, "tooltip-timeout", GUINT_TO_POINTER (pevent->timeout));
-
+
return TRUE;
- }
+ }
case GDK_LEAVE_NOTIFY:
tooltip_destroy (week_view, item);
-
+
return FALSE;
case GDK_MOTION_NOTIFY:
pevent->x = ((GdkEventMotion *)gdkevent)->x_root;
pevent->y = ((GdkEventMotion *)gdkevent)->y_root;
pevent->tooltip = (GtkWidget *)g_object_get_data (G_OBJECT (week_view), "tooltip-window");
-
+
if (pevent->tooltip) {
- e_calendar_view_move_tip (pevent->tooltip, pevent->x+16, pevent->y+16);
+ e_calendar_view_move_tip (pevent->tooltip, pevent->x+16, pevent->y+16);
}
- return TRUE;
+ return TRUE;
case GDK_FOCUS_CHANGE:
if (gdkevent->focus_change.in) {
e_week_view_on_editing_started (week_view, item);
@@ -3242,7 +3242,7 @@ static gboolean e_week_view_event_move (ECalendarView *cal_view, ECalViewMoveDir
if (start_time.is_date && end_time.is_date)
is_all_day = TRUE;
- current_end_day = e_week_view_get_day_offset_of_event (week_view,end_dt);
+ current_end_day = e_week_view_get_day_offset_of_event (week_view,end_dt);
switch (direction) {
case E_CAL_VIEW_MOVE_UP:
@@ -3256,11 +3256,11 @@ static gboolean e_week_view_event_move (ECalendarView *cal_view, ECalViewMoveDir
break;
case E_CAL_VIEW_MOVE_RIGHT:
adjust_days = e_week_view_get_adjust_days_for_move_right (week_view,current_end_day);
- break;
+ break;
default:
break;
}
-
+
icaltime_adjust (&start_time ,adjust_days,0,0,0);
icaltime_adjust (&end_time ,adjust_days,0,0,0);
start_dt = icaltime_as_timet_with_zone (start_time,
@@ -3285,7 +3285,7 @@ static gboolean e_week_view_event_move (ECalendarView *cal_view, ECalViewMoveDir
return TRUE;
}
}
-
+
e_week_view_change_event_time (week_view, start_dt, end_dt, is_all_day);
return TRUE;
}
@@ -3294,7 +3294,7 @@ static gint
e_week_view_get_day_offset_of_event (EWeekView *week_view, time_t event_time)
{
time_t first_day = week_view->day_starts[0];
-
+
if (event_time - first_day < 0)
return -1;
else
@@ -3306,7 +3306,7 @@ e_week_view_scroll_a_step (EWeekView *week_view, ECalViewMoveDirection direction
{
GtkAdjustment *adj = GTK_RANGE (week_view->vscrollbar)->adjustment;
gfloat new_value;
-
+
switch (direction){
case E_CAL_VIEW_MOVE_UP:
new_value = adj->value - adj->step_increment;
@@ -3357,7 +3357,7 @@ e_week_view_change_event_time (EWeekView *week_view, time_t start_dt, time_t end
/* FIXME: Should probably keep the timezone of the original start
and end times. */
date.tzid = icaltimezone_get_tzid (e_calendar_view_get_timezone (E_CALENDAR_VIEW (week_view)));
-
+
*date.value = icaltime_from_timet_with_zone (start_dt, is_all_day,
e_calendar_view_get_timezone (E_CALENDAR_VIEW (week_view)));
e_cal_component_set_dtstart (comp, &date);
@@ -3366,12 +3366,12 @@ e_week_view_change_event_time (EWeekView *week_view, time_t start_dt, time_t end
e_cal_component_set_dtend (comp, &date);
e_cal_component_commit_sequence (comp);
-
+
if (week_view->last_edited_comp_string != NULL) {
g_free (week_view->last_edited_comp_string);
week_view->last_edited_comp_string = NULL;
}
-
+
week_view->last_edited_comp_string = e_cal_component_get_as_string (comp);
@@ -3388,13 +3388,13 @@ e_week_view_change_event_time (EWeekView *week_view, time_t start_dt, time_t end
e_cal_component_set_exrule_list (comp, NULL);
}
}
-
+
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (week_view)));
e_cal_component_commit_sequence (comp);
e_calendar_view_modify_and_send (comp, client, mod, toplevel, TRUE);
-out:
+out:
g_object_unref (comp);
}
@@ -3439,7 +3439,7 @@ e_week_view_on_editing_stopped (EWeekView *week_view,
ECal *client;
const char *uid;
gboolean on_server;
-
+
/* Note: the item we are passed here isn't reliable, so we just stop
the edit of whatever item was being edited. We also receive this
event twice for some reason. */
@@ -3470,10 +3470,10 @@ e_week_view_on_editing_stopped (EWeekView *week_view,
client = event->comp_data->client;
on_server = cal_comp_is_on_server (comp, client);
-
+
if (string_is_empty (text) && !on_server) {
e_cal_component_get_uid (comp, &uid);
- g_signal_handlers_disconnect_by_func(item, e_week_view_on_text_item_event, week_view);
+ g_signal_handlers_disconnect_by_func(item, e_week_view_on_text_item_event, week_view);
e_week_view_foreach_event_with_uid (week_view, uid,
e_week_view_remove_event_cb, NULL);
week_view->event_destroyed = TRUE;
@@ -3490,12 +3490,12 @@ e_week_view_on_editing_stopped (EWeekView *week_view,
span_num);
} else if (summary.value || !string_is_empty (text)) {
icalcomponent *icalcomp = e_cal_component_get_icalcomponent (comp);
-
+
summary.value = text;
summary.altrep = NULL;
e_cal_component_set_summary (comp, &summary);
e_cal_component_commit_sequence (comp);
-
+
if (!on_server) {
if (!e_cal_create_object (client, icalcomp, NULL, NULL))
g_message (G_STRLOC ": Could not create the object!");
@@ -3507,7 +3507,7 @@ e_week_view_on_editing_stopped (EWeekView *week_view,
} else {
CalObjModType mod = CALOBJ_MOD_ALL;
GtkWindow *toplevel;
-
+
if (e_cal_component_is_instance (comp)) {
if (!recur_component_dialog (client, comp, &mod, NULL, FALSE)) {
goto out;
@@ -3552,7 +3552,7 @@ e_week_view_on_editing_stopped (EWeekView *week_view,
e_cal_component_commit_sequence (comp);
}
}
-
+
/* FIXME When sending here, what exactly should we send? */
toplevel = GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (week_view)));
e_calendar_view_modify_and_send (comp, client, mod, toplevel, FALSE);
@@ -3681,7 +3681,7 @@ e_week_view_do_cursor_key_up (EWeekView *week_view)
{
if (week_view->selection_start_day <= 0)
return;
-
+
week_view->selection_start_day--;
week_view->selection_end_day = week_view->selection_start_day;
g_signal_emit_by_name (week_view, "selected_time_changed");
@@ -3694,7 +3694,7 @@ e_week_view_do_cursor_key_down (EWeekView *week_view)
if (week_view->selection_start_day == -1 ||
week_view->selection_start_day >= 6)
return;
-
+
week_view->selection_start_day++;
week_view->selection_end_day = week_view->selection_start_day;
g_signal_emit_by_name (week_view, "selected_time_changed");
@@ -3706,7 +3706,7 @@ e_week_view_do_cursor_key_left (EWeekView *week_view)
{
if (week_view->selection_start_day == -1)
return;
-
+
week_view->selection_start_day = map_left[week_view->selection_start_day];
week_view->selection_end_day = week_view->selection_start_day;
g_signal_emit_by_name (week_view, "selected_time_changed");
@@ -3718,7 +3718,7 @@ e_week_view_do_cursor_key_right (EWeekView *week_view)
{
if (week_view->selection_start_day == -1)
return;
-
+
week_view->selection_start_day = map_right[week_view->selection_start_day];
week_view->selection_end_day = week_view->selection_start_day;
g_signal_emit_by_name (week_view, "selected_time_changed");
@@ -3730,7 +3730,7 @@ e_month_view_do_cursor_key_up (EWeekView *week_view)
{
if (week_view->selection_start_day < 7)
return;
-
+
week_view->selection_start_day -= 7;
week_view->selection_end_day = week_view->selection_start_day;
g_signal_emit_by_name (week_view, "selected_time_changed");
@@ -3745,7 +3745,7 @@ e_month_view_do_cursor_key_down (EWeekView *week_view)
if (week_view->selection_start_day == -1 ||
week_view->selection_start_day >= (weeks_shown - 1) * 7)
return;
-
+
week_view->selection_start_day += 7;
week_view->selection_end_day = week_view->selection_start_day;
g_signal_emit_by_name (week_view, "selected_time_changed");
@@ -3757,7 +3757,7 @@ e_month_view_do_cursor_key_left (EWeekView *week_view)
{
if (week_view->selection_start_day <= 0)
return;
-
+
week_view->selection_start_day--;
week_view->selection_end_day = week_view->selection_start_day;
g_signal_emit_by_name (week_view, "selected_time_changed");
@@ -3772,7 +3772,7 @@ e_month_view_do_cursor_key_right (EWeekView *week_view)
if (week_view->selection_start_day == -1 ||
week_view->selection_start_day >= weeks_shown * 7 - 1)
return;
-
+
week_view->selection_start_day++;
week_view->selection_end_day = week_view->selection_start_day;
g_signal_emit_by_name (week_view, "selected_time_changed");
@@ -3858,7 +3858,7 @@ e_week_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
gboolean read_only = TRUE;
gboolean stop_emission;
GnomeCalendarViewType view_type;
-
+
g_return_val_if_fail (widget != NULL, FALSE);
g_return_val_if_fail (E_IS_WEEK_VIEW (widget), FALSE);
g_return_val_if_fail (event != NULL, FALSE);
@@ -3886,15 +3886,15 @@ e_week_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
case GDK_Page_Up:
if (!week_view->multi_week_view)
e_week_view_scroll_a_step (week_view, E_CAL_VIEW_MOVE_UP);
- else
+ else
e_week_view_scroll_a_step (week_view, E_CAL_VIEW_MOVE_PAGE_UP);
break;
case GDK_Page_Down:
if (!week_view->multi_week_view)
e_week_view_scroll_a_step (week_view, E_CAL_VIEW_MOVE_DOWN);
- else
+ else
e_week_view_scroll_a_step (week_view, E_CAL_VIEW_MOVE_PAGE_DOWN);
- break;
+ break;
case GDK_Up:
e_week_view_cursor_key_up (week_view, view_type);
break;
@@ -3914,7 +3914,7 @@ e_week_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
}
if (stop_emission)
return TRUE;
-
+
/*Navigation through days with arrow keys*/
if (((event->state & GDK_SHIFT_MASK) != GDK_SHIFT_MASK)
&&((event->state & GDK_CONTROL_MASK) != GDK_CONTROL_MASK)
@@ -3928,7 +3928,7 @@ e_week_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
else if (keyval == GDK_Right || keyval == GDK_KP_Right)
return e_week_view_event_move ((ECalendarView *) week_view, E_CAL_VIEW_MOVE_RIGHT);
}
-
+
if (week_view->selection_start_day == -1)
return FALSE;
@@ -3998,7 +3998,7 @@ e_week_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
event_num);
span = &g_array_index (week_view->spans, EWeekViewEventSpan,
wvevent->spans_index + 0);
-
+
/* If the event can't be fit on the screen, don't try to edit it. */
if (!span->text_item) {
e_week_view_foreach_event_with_uid (week_view, uid,
@@ -4007,7 +4007,7 @@ e_week_view_do_key_press (GtkWidget *widget, GdkEventKey *event)
e_week_view_start_editing_event (week_view, event_num, 0,
initial_text);
}
-
+
} else {
g_warning ("Couldn't find event to start editing.\n");
}
@@ -4076,7 +4076,7 @@ e_week_view_show_popup_menu (EWeekView *week_view,
gint event_num)
{
GtkMenu *popup;
-
+
week_view->popup_event_num = event_num;
popup = e_calendar_view_create_popup_menu (E_CALENDAR_VIEW (week_view));
diff --git a/calendar/gui/e-week-view.h b/calendar/gui/e-week-view.h
index 579ba43eb7..ca46060c37 100644
--- a/calendar/gui/e-week-view.h
+++ b/calendar/gui/e-week-view.h
@@ -1,14 +1,14 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Author :
+/*
+ * Author :
* Damon Chaplin <damon@ximian.com>
*
* Copyright 1999, Ximian, Inc.
* Copyright 2001, Ximian, Inc.
*
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of version 2 of the GNU General Public
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
@@ -108,7 +108,7 @@ typedef enum
E_WEEK_VIEW_COLOR_DATES,
E_WEEK_VIEW_COLOR_DATES_SELECTED,
E_WEEK_VIEW_COLOR_TODAY,
-
+
E_WEEK_VIEW_COLOR_LAST
} EWeekViewColors;
@@ -205,7 +205,7 @@ struct _EWeekView
gboolean multi_week_view;
gboolean update_base_date;
-
+
/* How many weeks we are showing. This is only relevant if
display_month is TRUE. */
gint weeks_shown;
@@ -336,7 +336,7 @@ struct _EWeekView
/* remember last selected interval when click and restore on double click,
if we double clicked inside that interval. */
- guint32 bc_event_time;
+ guint32 bc_event_time;
time_t before_click_dtstart;
time_t before_click_dtend;
};
diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c
index 140f84f3c7..768ed6e89b 100644
--- a/calendar/gui/gnome-cal.c
+++ b/calendar/gui/gnome-cal.c
@@ -96,7 +96,7 @@
/* Private part of the GnomeCalendar structure */
struct _GnomeCalendarPrivate {
/* The clients for display */
-
+
GHashTable *clients[E_CAL_SOURCE_TYPE_LAST];
GList *clients_list[E_CAL_SOURCE_TYPE_LAST];
ECal *default_client[E_CAL_SOURCE_TYPE_LAST];
@@ -109,7 +109,7 @@ struct _GnomeCalendarPrivate {
/* This is the last time explicitly selected by the user */
time_t base_view_time;
-
+
/* Widgets */
GtkWidget *search_bar;
@@ -119,13 +119,13 @@ struct _GnomeCalendarPrivate {
GtkWidget *vpane;
ECalendar *date_navigator;
- EMiniCalendarConfig *date_navigator_config;
+ EMiniCalendarConfig *date_navigator_config;
GtkWidget *todo;
ECalendarTableConfig *todo_config;
-
+
GtkWidget *memo;
EMemoTableConfig *memo_config;
-
+
GtkWidget *day_view;
GtkWidget *work_week_view;
GtkWidget *week_view;
@@ -147,7 +147,7 @@ struct _GnomeCalendarPrivate {
char *memo_sexp;
guint update_timeout;
guint update_marcus_bains_line_timeout;
-
+
/* This is the view currently shown. We use it to keep track of the
positions of the panes. range_selected is TRUE if a range of dates
was selected in the date navigator to show the view. */
@@ -155,7 +155,7 @@ struct _GnomeCalendarPrivate {
GObject *configs[GNOME_CAL_LAST_VIEW];
GnomeCalendarViewType current_view_type;
GList *notifications;
-
+
gboolean range_selected;
/* These are the saved positions of the panes. They are multiples of
@@ -175,7 +175,7 @@ struct _GnomeCalendarPrivate {
/* Our current week start */
int week_start;
-
+
/* Our current timezone. */
icaltimezone *zone;
@@ -453,7 +453,7 @@ gnome_calendar_class_init (GnomeCalendarClass *class)
"goto_date",1,
G_TYPE_ENUM,
GNOME_CAL_GOTO_SAME_DAY_OF_NEXT_WEEK);
-
+
/* Ctrl+Y/J/K/M/L to switch between
* DayView/WorkWeekView/WeekView/MonthView/ListView */
gtk_binding_entry_add_signal (binding_set, GDK_y,
@@ -518,7 +518,7 @@ dn_e_cal_view_objects_added_cb (ECalView *query, GList *objects, gpointer data)
GnomeCalendar *gcal;
GnomeCalendarPrivate *priv;
GList *l;
-
+
gcal = GNOME_CALENDAR (data);
priv = gcal->priv;
@@ -529,7 +529,7 @@ dn_e_cal_view_objects_added_cb (ECalView *query, GList *objects, gpointer data)
comp = e_cal_component_new ();
if (!e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (l->data))) {
g_object_unref (comp);
-
+
continue;
}
@@ -595,9 +595,9 @@ get_times_for_views (GnomeCalendar *gcal, GnomeCalendarViewType view_type, time_
gboolean has_working_days = FALSE;
guint offset;
struct icaltimetype tt = icaltime_null_time ();
-
+
priv = gcal->priv;
-
+
switch (view_type) {
case GNOME_CAL_DAY_VIEW:
shown = e_day_view_get_days_shown (E_DAY_VIEW (priv->views[view_type]));
@@ -667,7 +667,7 @@ get_times_for_views (GnomeCalendar *gcal, GnomeCalendarViewType view_type, time_
shown = e_week_view_get_weeks_shown (E_WEEK_VIEW (priv->views[view_type]));
/* FIXME We should be using the same day of the week enum every where */
display_start = (E_WEEK_VIEW (priv->views[view_type])->display_start_day + 1) % 7;
-
+
if (!priv->range_selected)
*start_time = time_month_begin_with_zone (*start_time, priv->zone);
*start_time = time_week_begin_with_zone (*start_time, display_start, priv->zone);
@@ -677,7 +677,7 @@ get_times_for_views (GnomeCalendar *gcal, GnomeCalendarViewType view_type, time_
/* FIXME What to do here? */
*start_time = time_month_begin_with_zone (*start_time, priv->zone);
*end_time = time_add_month_with_zone (*start_time, 1, priv->zone);
- break;
+ break;
default:
g_return_if_reached ();
}
@@ -1024,10 +1024,10 @@ gnome_calendar_emit_user_created_signal (gpointer instance, GnomeCalendar *gcal,
static void
user_created_cb (GtkWidget *view, GnomeCalendar *gcal)
{
- GnomeCalendarPrivate *priv;
+ GnomeCalendarPrivate *priv;
ECal *ecal;
-
- priv = gcal->priv;
+
+ priv = gcal->priv;
ecal = priv->user_created_cal;
if (!ecal) {
@@ -1115,9 +1115,9 @@ static void
connect_list_view_focus (GnomeCalendar *gcal, ECalListView *lv)
{
ETable *etable;
-
+
etable = e_table_scrolled_get_table (lv->table_scrolled);
-
+
g_signal_connect (etable->table_canvas, "focus_in_event",
G_CALLBACK (calendar_focus_change_cb), gcal);
g_signal_connect (etable->table_canvas, "focus_out_event",
@@ -1153,7 +1153,7 @@ set_week_start (GnomeCalendar *calendar)
GnomeCalendarPrivate *priv;
priv = calendar->priv;
-
+
priv->week_start = calendar_config_get_week_start_day ();
/* Only do this if views exist */
@@ -1168,7 +1168,7 @@ static void
week_start_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer data)
{
GnomeCalendar *calendar = data;
-
+
set_week_start (calendar);
}
@@ -1178,7 +1178,7 @@ set_working_days (GnomeCalendar *calendar)
GnomeCalendarPrivate *priv;
priv = calendar->priv;
-
+
/* Only do this if views exist */
if (priv->day_view && priv->work_week_view && priv->week_view && priv->month_view && priv->list_view) {
update_view_times (calendar, priv->base_view_time);
@@ -1191,18 +1191,18 @@ static void
working_days_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer data)
{
GnomeCalendar *calendar = data;
-
+
set_working_days (calendar);
}
static void
-set_timezone (GnomeCalendar *calendar)
+set_timezone (GnomeCalendar *calendar)
{
GnomeCalendarPrivate *priv;
int i;
-
+
priv = calendar->priv;
-
+
priv->zone = calendar_config_get_icaltimezone ();
for (i = 0; i < E_CAL_SOURCE_TYPE_LAST; i++) {
@@ -1210,13 +1210,13 @@ set_timezone (GnomeCalendar *calendar)
for (l = priv->clients_list[i]; l != NULL; l = l->next) {
ECal *client = l->data;
-
+
if (e_cal_get_load_state (client) == E_CAL_LOAD_LOADED)
/* FIXME Error checking */
e_cal_set_default_timezone (client, priv->zone, NULL);
}
- if (priv->default_client[i]
+ if (priv->default_client[i]
&& e_cal_get_load_state (priv->default_client[i]) == E_CAL_LOAD_LOADED)
/* FIXME Error checking */
e_cal_set_default_timezone (priv->default_client[i], priv->zone, NULL);
@@ -1227,7 +1227,7 @@ static void
timezone_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer data)
{
GnomeCalendar *calendar = data;
-
+
set_timezone (calendar);
}
@@ -1237,16 +1237,16 @@ update_todo_view (GnomeCalendar *gcal)
GnomeCalendarPrivate *priv;
ECalModel *model;
char *sexp = NULL;
-
+
priv = gcal->priv;
-
+
/* Set the query on the task pad */
if (priv->todo_sexp) {
g_free (priv->todo_sexp);
}
-
+
model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->todo));
-
+
if ((sexp = calendar_config_get_hide_completed_tasks_sexp (FALSE)) != NULL) {
priv->todo_sexp = g_strdup_printf ("(and %s %s)", sexp, priv->sexp);
e_cal_model_set_search_query (model, priv->todo_sexp);
@@ -1255,7 +1255,7 @@ update_todo_view (GnomeCalendar *gcal)
priv->todo_sexp = g_strdup (priv->sexp);
e_cal_model_set_search_query (model, priv->todo_sexp);
}
-
+
}
static void
@@ -1263,11 +1263,11 @@ update_memo_view (GnomeCalendar *gcal)
{
GnomeCalendarPrivate *priv;
ECalModel *model, *view_model;
- time_t start, end;
+ time_t start, end;
char *iso_start, *iso_end;
-
+
priv = gcal->priv;
-
+
/* Set the query on the memo pad*/
model = e_memo_table_get_model (E_MEMO_TABLE (priv->memo));
view_model = e_calendar_view_get_model(priv->views[priv->current_view_type]);
@@ -1280,11 +1280,11 @@ update_memo_view (GnomeCalendar *gcal)
if (priv->memo_sexp) {
g_free (priv->memo_sexp);
}
-
+
priv->memo_sexp = g_strdup_printf ("(not (has-start?)) or (and (occur-in-time-range? (make-time \"%s\")"
" (make-time \"%s\"))"
" %s)",
- iso_start, iso_end,
+ iso_start, iso_end,
priv->sexp ? priv->sexp : "");
e_cal_model_set_search_query (model, priv->memo_sexp);
@@ -1308,7 +1308,7 @@ process_completed_tasks (GnomeCalendar *gcal, gboolean config_changed)
static gboolean
update_todo_view_cb (GnomeCalendar *gcal)
-{
+{
ECalModel *model;
model = e_calendar_table_get_model (E_CALENDAR_TABLE (gcal->priv->todo));
@@ -1321,7 +1321,7 @@ update_todo_view_cb (GnomeCalendar *gcal)
static gboolean
update_marcus_bains_line_cb (GnomeCalendar *gcal)
-{
+{
GnomeCalendarPrivate *priv;
priv = gcal->priv;
@@ -1359,23 +1359,23 @@ setup_config (GnomeCalendar *calendar)
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* Timezone */
- set_timezone (calendar);
+ set_timezone (calendar);
not = calendar_config_add_notification_timezone (timezone_changed_cb, calendar);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
/* Hide completed tasks */
- not = calendar_config_add_notification_hide_completed_tasks (config_hide_completed_tasks_changed_cb,
+ not = calendar_config_add_notification_hide_completed_tasks (config_hide_completed_tasks_changed_cb,
calendar);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
-
- not = calendar_config_add_notification_hide_completed_tasks_units (config_hide_completed_tasks_changed_cb,
+
+ not = calendar_config_add_notification_hide_completed_tasks_units (config_hide_completed_tasks_changed_cb,
calendar);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
-
- not = calendar_config_add_notification_hide_completed_tasks_value (config_hide_completed_tasks_changed_cb,
+
+ not = calendar_config_add_notification_hide_completed_tasks_value (config_hide_completed_tasks_changed_cb,
calendar);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
-
+
/* Pane positions */
priv->hpane_pos = calendar_config_get_hpane_pos ();
priv->vpane_pos = calendar_config_get_vpane_pos ();
@@ -1384,7 +1384,7 @@ setup_config (GnomeCalendar *calendar)
}
static void
-update_adjustment (GnomeCalendar *gcal, GtkAdjustment *adjustment, EWeekView *week_view)
+update_adjustment (GnomeCalendar *gcal, GtkAdjustment *adjustment, EWeekView *week_view)
{
GDate date;
gint week_offset;
@@ -1424,13 +1424,13 @@ update_adjustment (GnomeCalendar *gcal, GtkAdjustment *adjustment, EWeekView *we
}
static void
-week_view_adjustment_changed_cb (GtkAdjustment *adjustment, GnomeCalendar *gcal)
+week_view_adjustment_changed_cb (GtkAdjustment *adjustment, GnomeCalendar *gcal)
{
- update_adjustment (gcal, adjustment, E_WEEK_VIEW (gcal->priv->week_view));
+ update_adjustment (gcal, adjustment, E_WEEK_VIEW (gcal->priv->week_view));
}
static void
-month_view_adjustment_changed_cb (GtkAdjustment *adjustment, GnomeCalendar *gcal)
+month_view_adjustment_changed_cb (GtkAdjustment *adjustment, GnomeCalendar *gcal)
{
update_adjustment (gcal, adjustment, E_WEEK_VIEW (gcal->priv->month_view));
}
@@ -1481,10 +1481,10 @@ view_done_cb (ECalModel *model, ECalendarStatus status, ECalSourceType type, Gno
} else if (type == E_CAL_SOURCE_TYPE_JOURNAL) {
e_memo_table_set_status_message (E_MEMO_TABLE (gcal->priv->memo), NULL);
}
-
+
}
-GtkWidget *
+GtkWidget *
gnome_calendar_get_tag (GnomeCalendar *gcal)
{
return GTK_WIDGET (gcal->priv->date_navigator);
@@ -1519,7 +1519,7 @@ setup_widgets (GnomeCalendar *gcal)
/* The main HPaned, with the notebook of calendar views on the left
and the ECalendar and ToDo list on the right. */
priv->hpane = gtk_hpaned_new ();
- g_signal_connect_after(priv->hpane, "realize",
+ g_signal_connect_after(priv->hpane, "realize",
G_CALLBACK(gnome_calendar_hpane_realized), gcal);
g_signal_connect (priv->hpane, "button_release_event",
G_CALLBACK (gnome_calendar_hpane_resized), gcal);
@@ -1550,7 +1550,7 @@ setup_widgets (GnomeCalendar *gcal)
G_CALLBACK (gnome_calendar_on_date_navigator_date_range_changed), gcal);
g_signal_connect (w, "scroll-event",
G_CALLBACK (gnome_calendar_date_navigator_scrolled), gcal);
-
+
/* The VPaned widget, to contain the ToDo list & Memo list */
priv->vpane = gtk_vpaned_new ();
g_signal_connect_after (priv->vpane, "realize",
@@ -1564,18 +1564,18 @@ setup_widgets (GnomeCalendar *gcal)
vbox = gtk_vbox_new (FALSE, 0);
sep = gtk_hseparator_new ();
gtk_box_pack_start ((GtkBox *)vbox, sep, FALSE, TRUE, 0);
-
+
label = gtk_label_new (NULL);
tmp = g_strdup_printf ("<b> %s </b>", _("Tasks"));
gtk_label_set_markup ((GtkLabel *)label, tmp);
g_free (tmp);
gtk_box_pack_start ((GtkBox *)vbox, label, FALSE, TRUE, 0);
-
+
priv->todo = e_calendar_table_new ();
priv->todo_config = e_calendar_table_config_new (E_CALENDAR_TABLE (priv->todo));
gtk_paned_pack1 (GTK_PANED (priv->vpane), vbox, FALSE, TRUE);
gtk_box_pack_end ((GtkBox *)vbox, priv->todo, TRUE, TRUE, 0);
-
+
gtk_widget_show (priv->todo);
gtk_widget_show (label);
gtk_widget_show (vbox);
@@ -1584,7 +1584,7 @@ setup_widgets (GnomeCalendar *gcal)
filename = g_build_filename (calendar_component_peek_config_directory (calendar_component_peek ()),
"TaskPad", NULL);
e_calendar_table_load_state (E_CALENDAR_TABLE (priv->todo), filename);
-
+
update_todo_view (gcal);
g_free (filename);
@@ -1596,14 +1596,14 @@ setup_widgets (GnomeCalendar *gcal)
g_signal_connect (etable, "selection_change",
G_CALLBACK (table_selection_change_cb), gcal);
-
+
g_signal_connect (e_calendar_table_get_model ((ECalendarTable *)priv->todo), "cal_view_progress",
G_CALLBACK (view_progress_cb), gcal);
g_signal_connect (e_calendar_table_get_model ((ECalendarTable *)priv->todo), "cal_view_done",
G_CALLBACK (view_done_cb), gcal);
/* Timeout check to hide completed items */
- priv->update_timeout = g_timeout_add_full (G_PRIORITY_LOW, 60000, (GSourceFunc) update_todo_view_cb, gcal, NULL);
+ priv->update_timeout = g_timeout_add_full (G_PRIORITY_LOW, 60000, (GSourceFunc) update_todo_view_cb, gcal, NULL);
/* The Day View. */
priv->day_view = e_day_view_new ();
@@ -1623,7 +1623,7 @@ setup_widgets (GnomeCalendar *gcal)
connect_day_view_focus (gcal, E_DAY_VIEW (priv->work_week_view));
/* The Marcus Bains line */
- priv->update_marcus_bains_line_timeout = g_timeout_add_full (G_PRIORITY_LOW, 60000, (GSourceFunc) update_marcus_bains_line_cb, gcal, NULL);
+ priv->update_marcus_bains_line_timeout = g_timeout_add_full (G_PRIORITY_LOW, 60000, (GSourceFunc) update_marcus_bains_line_cb, gcal, NULL);
/* The Week View. */
priv->week_view = e_week_view_new ();
@@ -1643,7 +1643,7 @@ setup_widgets (GnomeCalendar *gcal)
G_CALLBACK (view_progress_cb), gcal);
g_signal_connect (w_model, "cal_view_done",
G_CALLBACK (view_done_cb), gcal);
-
+
/* The Month View. */
priv->month_view = e_week_view_new ();
e_calendar_view_set_calendar (E_CALENDAR_VIEW (priv->month_view), gcal);
@@ -1659,7 +1659,7 @@ setup_widgets (GnomeCalendar *gcal)
g_signal_connect (adjustment, "value_changed",
G_CALLBACK (month_view_adjustment_changed_cb),
gcal);
-
+
/* The List View. */
priv->list_view = e_cal_list_view_new ();
@@ -1696,13 +1696,13 @@ setup_widgets (GnomeCalendar *gcal)
label = gtk_label_new (NULL);
tmp = g_strdup_printf ("<b> %s </b>", _("Memos"));
gtk_label_set_markup ((GtkLabel *)label, tmp);
- g_free (tmp);
+ g_free (tmp);
gtk_box_pack_start ((GtkBox *)vbox, label, FALSE, TRUE, 0);
priv->memo = e_memo_table_new ();
priv->memo_config = e_memo_table_config_new (E_MEMO_TABLE (priv->memo));
gtk_paned_pack2 (GTK_PANED (priv->vpane), vbox, TRUE, TRUE);
gtk_box_pack_end ((GtkBox *)vbox, priv->memo, TRUE, TRUE, 0);
-
+
gtk_widget_show (priv->memo);
gtk_widget_show (label);
gtk_widget_show (vbox);
@@ -1710,7 +1710,7 @@ setup_widgets (GnomeCalendar *gcal)
filename = g_build_filename (memos_component_peek_config_directory (memos_component_peek ()),
"MemoPad", NULL);
e_memo_table_load_state (E_MEMO_TABLE (priv->memo), filename);
-
+
update_memo_view (gcal);
g_free (filename);
@@ -1722,7 +1722,7 @@ setup_widgets (GnomeCalendar *gcal)
g_signal_connect (etable, "selection_change",
G_CALLBACK (memo_selection_change_cb), gcal);
-
+
g_signal_connect (e_memo_table_get_model ((EMemoTable *)priv->memo), "cal_view_progress",
G_CALLBACK (view_progress_cb), gcal);
g_signal_connect (e_memo_table_get_model ((EMemoTable *)priv->memo), "cal_view_done",
@@ -1731,7 +1731,7 @@ setup_widgets (GnomeCalendar *gcal)
/* make sure we set the initial time ranges for the views */
update_view_times (gcal, time (NULL));
- gnome_calendar_update_date_navigator (gcal);
+ gnome_calendar_update_date_navigator (gcal);
}
/* Object initialization function for the gnome calendar */
@@ -1740,13 +1740,13 @@ gnome_calendar_init (GnomeCalendar *gcal)
{
GnomeCalendarPrivate *priv;
int i;
-
+
priv = g_new0 (GnomeCalendarPrivate, 1);
gcal->priv = priv;
for (i = 0; i < E_CAL_SOURCE_TYPE_LAST; i++)
priv->clients[i] = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, g_object_unref);
-
+
priv->config_listener = e_config_listener_new ();
g_signal_connect (priv->config_listener, "key_changed", G_CALLBACK (config_categories_changed_cb), gcal);
@@ -1761,7 +1761,7 @@ gnome_calendar_init (GnomeCalendar *gcal)
priv->taskpad_menu = e_cal_menu_new("org.gnome.evolution.calendar.taskpad");
priv->memopad_menu = e_cal_menu_new ("org.gnome.evolution.calendar.memopad");
- priv->dn_queries = NULL;
+ priv->dn_queries = NULL;
priv->sexp = g_strdup ("#t"); /* Match all */
priv->todo_sexp = g_strdup ("#t");
priv->memo_sexp = g_strdup ("#t");
@@ -1815,11 +1815,11 @@ gnome_calendar_destroy (GtkObject *object)
priv->clients_list[i] = NULL;
if (priv->default_client[i]) {
- g_signal_handlers_disconnect_matched (priv->default_client[i],
+ g_signal_handlers_disconnect_matched (priv->default_client[i],
G_SIGNAL_MATCH_DATA,
0, 0, NULL, NULL, gcal);
g_object_unref (priv->default_client[i]);
- }
+ }
priv->default_client[i] = NULL;
}
@@ -1831,18 +1831,18 @@ gnome_calendar_destroy (GtkObject *object)
g_object_unref (priv->date_navigator_config);
g_object_unref (priv->todo_config);
g_object_unref (priv->memo_config);
-
+
for (l = priv->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
g_list_free (priv->notifications);
priv->notifications = NULL;
-
+
/* Save the TaskPad layout. */
filename = g_build_filename (calendar_component_peek_config_directory (calendar_component_peek ()),
"TaskPad", NULL);
e_calendar_table_save_state (E_CALENDAR_TABLE (priv->todo), filename);
g_free (filename);
-
+
/* Save the MemoPad layout. */
filename = g_build_filename (memos_component_peek_config_directory (memos_component_peek ()),
"MemoPad", NULL);
@@ -1864,7 +1864,7 @@ gnome_calendar_destroy (GtkObject *object)
g_free (priv->sexp);
priv->sexp = NULL;
}
-
+
if (priv->todo_sexp) {
g_free (priv->todo_sexp);
priv->todo_sexp = NULL;
@@ -1931,7 +1931,7 @@ gnome_calendar_destroy (GtkObject *object)
g_free (priv);
gcal->priv = NULL;
}
-
+
if (GTK_OBJECT_CLASS (gnome_calendar_parent_class)->destroy)
(* GTK_OBJECT_CLASS (gnome_calendar_parent_class)->destroy) (object);
}
@@ -1941,7 +1941,7 @@ notify_selected_time_changed (GnomeCalendar *gcal)
{
GnomeCalendarPrivate *priv;
int i;
-
+
priv = gcal->priv;
for (i = 0; i < GNOME_CAL_LAST_VIEW; i++) {
g_signal_emit_by_name (priv->views[i], "selected_time_changed");
@@ -1953,7 +1953,7 @@ gnome_calendar_goto_date (GnomeCalendar *gcal,
GnomeCalendarGotoDateType goto_date)
{
GnomeCalendarPrivate *priv;
- time_t new_time = 0;
+ time_t new_time = 0;
gboolean need_updating = FALSE;
g_return_if_fail (gcal != NULL);
@@ -2032,11 +2032,11 @@ gnome_calendar_goto (GnomeCalendar *gcal, time_t new_time)
update_view_times (gcal, new_time);
gnome_calendar_update_date_navigator (gcal);
gnome_calendar_notify_dates_shown_changed (gcal);
-
+
for (i = 0; i < GNOME_CAL_LAST_VIEW; i++) {
- if (E_CALENDAR_VIEW_CLASS (G_OBJECT_GET_CLASS (priv->views[i]))->set_selected_time_range)
+ if (E_CALENDAR_VIEW_CLASS (G_OBJECT_GET_CLASS (priv->views[i]))->set_selected_time_range)
E_CALENDAR_VIEW_CLASS (G_OBJECT_GET_CLASS (priv->views[i]))->set_selected_time_range (priv->views[i], new_time, new_time);
- }
+ }
}
@@ -2045,9 +2045,9 @@ update_view_times (GnomeCalendar *gcal, time_t start_time)
{
GnomeCalendarPrivate *priv;
int i;
-
+
priv = gcal->priv;
-
+
priv->base_view_time = start_time;
for (i = 0; i < GNOME_CAL_LAST_VIEW; i++) {
@@ -2245,7 +2245,7 @@ display_view (GnomeCalendar *gcal, GnomeCalendarViewType view_type, gboolean gra
case GNOME_CAL_DAY_VIEW:
if (!priv->range_selected)
e_day_view_set_days_shown (E_DAY_VIEW (priv->day_view), 1);
-
+
gtk_widget_show (GTK_WIDGET (gcal->priv->date_navigator));
break;
@@ -2270,7 +2270,7 @@ display_view (GnomeCalendar *gcal, GnomeCalendarViewType view_type, gboolean gra
case GNOME_CAL_LIST_VIEW:
if (!priv->lview_select_daten_range)
gtk_widget_hide (GTK_WIDGET (gcal->priv->date_navigator));
- else
+ else
gtk_widget_show (GTK_WIDGET (gcal->priv->date_navigator));
break;
@@ -2300,7 +2300,7 @@ static void gnome_calendar_change_view (GnomeCalendar *gcal, GnomeCalendarViewTy
{
if (gnome_calendar_get_view(gcal) == view_type)
return;
-
+
gnome_calendar_set_view(gcal, view_type);
}
@@ -2312,41 +2312,41 @@ display_view_cb (GalViewInstance *view_instance, GalView *view, gpointer data)
GnomeCalendarPrivate *priv;
CalendarView *cal_view;
GnomeCalendarViewType view_type;
-
+
gcal = GNOME_CALENDAR (data);
priv = gcal->priv;
-
+
if (GAL_IS_VIEW_ETABLE(view)) {
ETable *table;
-
+
view_type = GNOME_CAL_LIST_VIEW;
-
+
table = e_table_scrolled_get_table (E_CAL_LIST_VIEW (priv->list_view)->table_scrolled);
gal_view_etable_attach_table (GAL_VIEW_ETABLE (view), table);
} else if (IS_CALENDAR_VIEW (view)) {
cal_view = CALENDAR_VIEW (view);
-
+
view_type = calendar_view_get_view_type (cal_view);
} else {
g_error (G_STRLOC ": Unknown type of view for GnomeCalendar");
return;
}
-
+
display_view (gcal, view_type, TRUE);
gnome_calendar_update_date_navigator (gcal);
gnome_calendar_notify_dates_shown_changed (gcal);
if (!priv->lview_select_daten_range && priv->current_view_type != GNOME_CAL_LIST_VIEW)
update_query (gcal);
-
+
}
/**
* gnome_calendar_setup_view_menus:
* @gcal: A calendar.
* @uic: UI controller to use for the menus.
- *
+ *
* Sets up the #GalView menus for a calendar. This function should be called
* from the Bonobo control activation callback for this calendar. Also, the
* menus should be discarded using gnome_calendar_discard_view_menus().
@@ -2381,7 +2381,7 @@ gnome_calendar_setup_view_menus (GnomeCalendar *gcal, BonoboUIComponent *uic)
path0 = g_build_filename (EVOLUTION_GALVIEWSDIR,
"calendar",
NULL);
- path1 = g_build_filename (calendar_component_peek_base_directory (calendar_component_peek ()),
+ path1 = g_build_filename (calendar_component_peek_base_directory (calendar_component_peek ()),
"calendar", "views", NULL);
gal_view_collection_set_storage_directories (collection,
path0,
@@ -2437,7 +2437,7 @@ gnome_calendar_setup_view_menus (GnomeCalendar *gcal, BonoboUIComponent *uic)
/**
* gnome_calendar_discard_view_menus:
* @gcal: A calendar.
- *
+ *
* Discards the #GalView menus used by a calendar. This function should be
* called from the Bonobo control deactivation callback for this calendar. The
* menus should have been set up with gnome_calendar_setup_view_menus().
@@ -2651,7 +2651,7 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar *gcal)
break;
case E_CALENDAR_STATUS_REPOSITORY_OFFLINE:
if (source_type == E_CAL_SOURCE_TYPE_EVENT)
- e_error_run (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (gcal))),
+ e_error_run (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (gcal))),
"calendar:prompt-no-contents-offline-calendar", NULL);
default:
/* Make sure the source doesn't disappear on us */
@@ -2680,7 +2680,7 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar *gcal)
/* add client to the views */
for (i = 0; i < GNOME_CAL_LAST_VIEW; i++) {
ECalModel *model;
-
+
model = e_calendar_view_get_model (priv->views[i]);
e_cal_model_add_client (model, ecal);
}
@@ -2690,7 +2690,7 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar *gcal)
e_calendar_view_set_status_message (E_CALENDAR_VIEW (priv->week_view), NULL, -1);
break;
-
+
case E_CAL_SOURCE_TYPE_TODO :
msg = g_strdup_printf (_("Loading tasks at %s"), e_cal_get_uri (ecal));
e_calendar_table_set_status_message (E_CALENDAR_TABLE (priv->todo), msg, -1);
@@ -2706,7 +2706,7 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar *gcal)
g_free (msg);
e_cal_model_add_client (e_memo_table_get_model (E_MEMO_TABLE (priv->memo)), ecal);
e_memo_table_set_status_message (E_MEMO_TABLE (priv->memo), NULL);
- break;
+ break;
default:
g_return_if_reached ();
}
@@ -2730,7 +2730,7 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar
switch (source_type) {
case E_CAL_SOURCE_TYPE_EVENT:
e_calendar_view_set_status_message (E_CALENDAR_VIEW (priv->week_view), NULL, -1);
- break;
+ break;
case E_CAL_SOURCE_TYPE_TODO:
e_calendar_table_set_status_message (E_CALENDAR_TABLE (priv->todo), NULL, -1);
break;
@@ -2740,7 +2740,7 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar
default:
break;
}
-
+
switch (status) {
case E_CALENDAR_STATUS_OK:
break;
@@ -2751,7 +2751,7 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar
case E_CALENDAR_STATUS_INVALID_SERVER_VERSION :
e_error_run (NULL, "calendar:server-version", NULL);
status = E_CALENDAR_STATUS_OK;
- default:
+ default:
/* Make sure the source doesn't disappear on us */
g_object_ref (source);
@@ -2773,7 +2773,7 @@ default_client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar
g_signal_handlers_disconnect_matched (ecal, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, default_client_cal_opened_cb, NULL);
-
+
switch (source_type) {
case E_CAL_SOURCE_TYPE_EVENT:
for (i = 0; i < GNOME_CAL_LAST_VIEW; i++) {
@@ -2807,7 +2807,7 @@ open_ecal (GnomeCalendar *gcal, ECal *cal, gboolean only_if_exists, open_func of
zone = calendar_config_get_icaltimezone ();
e_cal_set_default_timezone (cal, zone, NULL);
-
+
msg = g_strdup_printf (_("Opening %s"), e_cal_get_uri (cal));
switch (e_cal_get_source_type (cal)) {
case E_CAL_SOURCE_TYPE_EVENT :
@@ -2874,15 +2874,15 @@ backend_died_cb (ECal *ecal, gpointer data)
/* Make sure the source doesn't go away on us since we use it below */
source_type = e_cal_get_source_type (ecal);
- source = g_object_ref (e_cal_get_source (ecal));
-
+ source = g_object_ref (e_cal_get_source (ecal));
+
priv->clients_list[source_type] = g_list_remove (priv->clients_list[source_type], ecal);
g_hash_table_remove (priv->clients[source_type], e_source_peek_uid (source));
switch (source_type) {
- case E_CAL_SOURCE_TYPE_EVENT:
+ case E_CAL_SOURCE_TYPE_EVENT:
id = "calendar:calendar-crashed";
-
+
e_calendar_view_set_status_message (E_CALENDAR_VIEW (priv->week_view), NULL, -1);
gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_REMOVED], source_type, source);
@@ -2890,15 +2890,15 @@ backend_died_cb (ECal *ecal, gpointer data)
case E_CAL_SOURCE_TYPE_TODO:
id = "calendar:tasks-crashed";
-
+
e_calendar_table_set_status_message (E_CALENDAR_TABLE (priv->todo), NULL, -1);
gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_REMOVED], source_type, source);
break;
-
+
case E_CAL_SOURCE_TYPE_JOURNAL:
id = "calendar:memos-crashed";
-
+
e_memo_table_set_status_message (E_MEMO_TABLE (priv->memo), NULL);
gtk_signal_emit (GTK_OBJECT (gcal), gnome_calendar_signals[SOURCE_REMOVED], source_type, source);
@@ -2908,7 +2908,7 @@ backend_died_cb (ECal *ecal, gpointer data)
}
g_object_unref (source);
-
+
e_error_run (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (gcal))), id, NULL);
}
@@ -2941,22 +2941,22 @@ gnome_calendar_new (void)
return GTK_WIDGET (gcal);
}
-void
+void
gnome_calendar_set_activity_handler (GnomeCalendar *cal, EActivityHandler *activity_handler)
{
GnomeCalendarPrivate *priv;
int i;
-
+
g_return_if_fail (cal != NULL);
g_return_if_fail (GNOME_IS_CALENDAR (cal));
priv = cal->priv;
priv->activity_handler = activity_handler;
-
+
for (i = 0; i < GNOME_CAL_LAST_VIEW; i++)
e_calendar_view_set_activity_handler (priv->views[i], activity_handler);
-
+
e_calendar_table_set_activity_handler (E_CALENDAR_TABLE (priv->todo), activity_handler);
}
@@ -3021,7 +3021,7 @@ gnome_calendar_add_source (GnomeCalendar *gcal, ECalSourceType source_type, ESou
{
GnomeCalendarPrivate *priv;
ECal *client;
-
+
g_return_val_if_fail (gcal != NULL, FALSE);
g_return_val_if_fail (GNOME_IS_CALENDAR (gcal), FALSE);
g_return_val_if_fail (E_IS_SOURCE (source), FALSE);
@@ -3035,7 +3035,7 @@ gnome_calendar_add_source (GnomeCalendar *gcal, ECalSourceType source_type, ESou
return TRUE;
} else {
ESource *default_source;
-
+
if (priv->default_client[source_type]) {
default_source = e_cal_get_source (priv->default_client[source_type]);
@@ -3045,14 +3045,14 @@ gnome_calendar_add_source (GnomeCalendar *gcal, ECalSourceType source_type, ESou
client = g_object_ref (priv->default_client[source_type]);
}
- /* Create a new one */
+ /* Create a new one */
if (!client) {
client = auth_new_cal_from_source (source, source_type);
if (!client)
return FALSE;
}
}
-
+
g_signal_connect (G_OBJECT (client), "backend_error", G_CALLBACK (backend_error_cb), gcal);
g_signal_connect (G_OBJECT (client), "backend_died", G_CALLBACK (backend_died_cb), gcal);
@@ -3081,7 +3081,7 @@ gboolean
gnome_calendar_remove_source (GnomeCalendar *gcal, ECalSourceType source_type, ESource *source)
{
gboolean result;
-
+
g_return_val_if_fail (gcal != NULL, FALSE);
g_return_val_if_fail (GNOME_IS_CALENDAR (gcal), FALSE);
g_return_val_if_fail (E_IS_SOURCE (source), FALSE);
@@ -3114,7 +3114,7 @@ gnome_calendar_remove_source_by_uid (GnomeCalendar *gcal, ECalSourceType source_
priv->clients_list[source_type] = g_list_remove (priv->clients_list[source_type], client);
g_signal_handlers_disconnect_matched (client, G_SIGNAL_MATCH_DATA,
- 0, 0, NULL, NULL, gcal);
+ 0, 0, NULL, NULL, gcal);
switch (source_type) {
case E_CAL_SOURCE_TYPE_EVENT:
@@ -3139,7 +3139,7 @@ gnome_calendar_remove_source_by_uid (GnomeCalendar *gcal, ECalSourceType source_
/* update date navigator query */
update_query (gcal);
break;
-
+
case E_CAL_SOURCE_TYPE_TODO:
model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->todo));
e_cal_model_remove_client (model, client);
@@ -3149,11 +3149,11 @@ gnome_calendar_remove_source_by_uid (GnomeCalendar *gcal, ECalSourceType source_
model = e_memo_table_get_model (E_MEMO_TABLE (priv->memo));
e_cal_model_remove_client (model, client);
break;
-
+
default:
g_return_val_if_reached (TRUE);
}
-
+
g_hash_table_remove (priv->clients[source_type], uid);
return TRUE;
@@ -3163,11 +3163,11 @@ gnome_calendar_remove_source_by_uid (GnomeCalendar *gcal, ECalSourceType source_
* gnome_calendar_set_default_source:
* @gcal: A calendar view
* @source: The #ESource to use as default
- *
+ *
* Set the default uri on the given calendar view, the default uri
* will be used as the default when creating events in the view.
- *
+ *
* Return value: TRUE if the uri was already added and is set, FALSE
* otherwise
**/
@@ -3176,7 +3176,7 @@ gnome_calendar_set_default_source (GnomeCalendar *gcal, ECalSourceType source_ty
{
GnomeCalendarPrivate *priv;
ECal *client;
-
+
g_return_val_if_fail (gcal != NULL, FALSE);
g_return_val_if_fail (GNOME_IS_CALENDAR (gcal), FALSE);
g_return_val_if_fail (E_IS_SOURCE (source), FALSE);
@@ -3195,7 +3195,7 @@ gnome_calendar_set_default_source (GnomeCalendar *gcal, ECalSourceType source_ty
if (!priv->default_client[source_type])
return FALSE;
}
-
+
open_ecal (gcal, priv->default_client[source_type], FALSE, default_client_cal_opened_cb);
@@ -3227,7 +3227,7 @@ gnome_calendar_get_selected_time_range (GnomeCalendar *gcal,
{
GnomeCalendarPrivate *priv;
ECalModel *model;
-
+
g_return_if_fail (gcal != NULL);
g_return_if_fail (GNOME_IS_CALENDAR (gcal));
@@ -3258,7 +3258,7 @@ gnome_calendar_new_task (GnomeCalendar *gcal, time_t *dtstart, time_t *dtend)
guint32 flags = 0;
ECalComponentDateTime dt;
struct icaltimetype itt;
-
+
g_return_if_fail (gcal != NULL);
g_return_if_fail (GNOME_IS_CALENDAR (gcal));
@@ -3267,7 +3267,7 @@ gnome_calendar_new_task (GnomeCalendar *gcal, time_t *dtstart, time_t *dtend)
ecal = e_cal_model_get_default_client (model);
if (!ecal)
return;
-
+
flags |= COMP_EDITOR_NEW_ITEM;
tedit = task_editor_new (ecal, flags);
@@ -3349,21 +3349,21 @@ gnome_calendar_update_date_navigator (GnomeCalendar *gcal)
if (priv->current_view_type == GNOME_CAL_LIST_VIEW && !priv->lview_select_daten_range)
return;
-
+
model = e_calendar_view_get_model (priv->views[priv->current_view_type]);
e_cal_model_get_time_range (model, &start, &end);
-
+
time_to_gdate_with_zone (&start_date, start, priv->zone);
if (priv->current_view_type == GNOME_CAL_MONTH_VIEW) {
EWeekView *week_view = E_WEEK_VIEW (priv->views[priv->current_view_type]);
- if (priv->week_start == 0
+ if (priv->week_start == 0
&& (!week_view->multi_week_view || week_view->compress_weekend))
g_date_add_days (&start_date, 1);
}
time_to_gdate_with_zone (&end_date, end, priv->zone);
g_date_subtract_days (&end_date, 1);
-
+
e_calendar_item_set_selection (priv->date_navigator->calitem,
&start_date, &end_date);
}
@@ -3381,12 +3381,12 @@ gnome_calendar_on_date_navigator_selection_changed (ECalendarItem *calitem, Gnom
struct icaltimetype tt;
priv = gcal->priv;
-
+
starts_on_week_start_day = FALSE;
model = e_calendar_view_get_model (priv->views[priv->current_view_type]);
e_cal_model_get_time_range (model, &start, &end);
-
+
time_to_gdate_with_zone (&start_date, start, priv->zone);
if (priv->current_view_type == GNOME_CAL_MONTH_VIEW) {
EWeekView *week_view = E_WEEK_VIEW (priv->views[priv->current_view_type]);
@@ -3403,7 +3403,7 @@ gnome_calendar_on_date_navigator_selection_changed (ECalendarItem *calitem, Gnom
if (!g_date_compare (&start_date, &new_start_date)
&& !g_date_compare (&end_date, &new_end_date))
return;
-
+
new_days_shown = g_date_get_julian (&new_end_date) - g_date_get_julian (&new_start_date) + 1;
/* If a complete week is selected we show the Week view.
@@ -3419,7 +3419,7 @@ gnome_calendar_on_date_navigator_selection_changed (ECalendarItem *calitem, Gnom
tt.month = g_date_get_month (&new_start_date);
tt.day = g_date_get_day (&new_start_date);
new_time = icaltime_as_timet_with_zone (tt, priv->zone);
-
+
/* Switch views as appropriate, and change the number of days or weeks
shown. */
if (new_days_shown > 9) {
@@ -3434,10 +3434,10 @@ gnome_calendar_on_date_navigator_selection_changed (ECalendarItem *calitem, Gnom
view_type = GNOME_CAL_LIST_VIEW;
} else if (new_days_shown == 7 && starts_on_week_start_day) {
view_type = GNOME_CAL_WEEK_VIEW;
- } else {
+ } else {
e_day_view_set_days_shown (E_DAY_VIEW (priv->day_view), new_days_shown);
-
- if (new_days_shown == 5 && starts_on_week_start_day
+
+ if (new_days_shown == 5 && starts_on_week_start_day
&& priv->current_view_type == GNOME_CAL_WORK_WEEK_VIEW)
view_type = GNOME_CAL_WORK_WEEK_VIEW;
else
@@ -3471,13 +3471,13 @@ gnome_calendar_hpane_realized (GtkWidget *w, GnomeCalendar *gcal)
}
}
-static void
+static void
gnome_calendar_date_navigator_scrolled (GtkWidget *widget, GdkEventScroll *event, gpointer user_data)
{
GnomeCalendar *gcal = user_data;
- ECalendarItem *calitem = gcal->priv->date_navigator->calitem;
+ ECalendarItem *calitem = gcal->priv->date_navigator->calitem;
GDate start_date, end_date;
-
+
if (e_calendar_item_get_selection (calitem, &start_date, &end_date)) {
switch (event->direction) {
case GDK_SCROLL_UP:
@@ -3489,8 +3489,8 @@ gnome_calendar_date_navigator_scrolled (GtkWidget *widget, GdkEventScroll *event
g_date_add_months (&end_date, 1);
break;
default:
- break;
-
+ break;
+
}
e_calendar_item_set_selection (calitem, &start_date, &end_date);
gnome_calendar_on_date_navigator_selection_changed (calitem, gcal);
@@ -3520,8 +3520,8 @@ gnome_calendar_hpane_resized (GtkWidget *w, GdkEventButton *e, GnomeCalendar *gc
gtk_widget_set_size_request (E_DAY_VIEW (priv->day_view)->time_canvas, times_width, -1);
else
gtk_widget_set_size_request (E_DAY_VIEW (priv->day_view)->time_canvas, priv->hpane_pos - 20, -1);
-
-
+
+
return FALSE;
}
static void
@@ -3673,10 +3673,10 @@ gnome_calendar_get_num_events_selected (GnomeCalendar *gcal)
/**
* gnome_calendar_get_num_tasks_selected:
* @gcal: A calendar view.
- *
+ *
* Queries the number of tasks that are currently selected in the task pad of a
* calendar view.
- *
+ *
* Return value: Number of selected tasks.
**/
gint
@@ -3772,16 +3772,16 @@ gnome_calendar_purge (GnomeCalendar *gcal, time_t older_than)
ECal *client = l->data;
GList *objects, *m;
gboolean read_only;
-
+
if (!e_cal_is_read_only (client, &read_only, NULL) || read_only)
continue;
-
+
if (!e_cal_get_object_list (client, sexp, &objects, NULL)) {
g_warning (G_STRLOC ": Could not get the objects");
-
+
continue;
}
-
+
for (m = objects; m; m = m->next) {
gboolean remove = TRUE;
@@ -3805,7 +3805,7 @@ gnome_calendar_purge (GnomeCalendar *gcal, time_t older_than)
if (!icaltime_is_null_time (recur_id) )
rid = icaltime_as_ical_string (recur_id);
-
+
e_cal_remove_object_with_mod (client, uid, rid, CALOBJ_MOD_ALL, &error);
} else {
e_cal_remove_object (client, uid, &error);
@@ -3842,15 +3842,15 @@ GtkWidget *
gnome_calendar_get_e_calendar_widget (GnomeCalendar *gcal)
{
g_return_val_if_fail (GNOME_IS_CALENDAR (gcal), NULL);
-
+
return GTK_WIDGET(gcal->priv->date_navigator);
}
-
+
GtkWidget *
gnome_calendar_get_search_bar_widget (GnomeCalendar *gcal)
{
g_return_val_if_fail (GNOME_IS_CALENDAR (gcal), NULL);
-
+
return GTK_WIDGET(gcal->priv->search_bar);
}
@@ -3858,28 +3858,28 @@ GtkWidget *
gnome_calendar_get_view_notebook_widget (GnomeCalendar *gcal)
{
g_return_val_if_fail (GNOME_IS_CALENDAR (gcal), NULL);
-
+
return GTK_WIDGET(gcal->priv->notebook);
}
ECalMenu *gnome_calendar_get_taskpad_menu (GnomeCalendar *gcal)
{
g_return_val_if_fail (GNOME_IS_CALENDAR (gcal), NULL);
-
+
return gcal->priv->taskpad_menu;
}
ECalMenu *gnome_calendar_get_calendar_menu (GnomeCalendar *gcal)
{
g_return_val_if_fail (GNOME_IS_CALENDAR (gcal), NULL);
-
+
return gcal->priv->calendar_menu;
}
ECalMenu *gnome_calendar_get_memopad_menu (GnomeCalendar *gcal)
{
g_return_val_if_fail (GNOME_IS_CALENDAR (gcal), NULL);
-
+
return gcal->priv->memopad_menu;
}
@@ -3897,7 +3897,7 @@ gnome_calendar_edit_appointment (GnomeCalendar *gcal,
if (!src_uid || !comp_uid)
return;
-
+
for (l = gcal->priv->clients_list[E_CAL_SOURCE_TYPE_EVENT]; l != NULL; l = l->next) {
ESource *client_src;
@@ -3908,7 +3908,7 @@ gnome_calendar_edit_appointment (GnomeCalendar *gcal,
break;
}
- if (!client)
+ if (!client)
return;
e_cal_get_object (client, comp_uid, comp_rid, &icalcomp, NULL);
@@ -3918,6 +3918,6 @@ gnome_calendar_edit_appointment (GnomeCalendar *gcal,
attendee_prop = icalcomponent_get_first_property (icalcomp, ICAL_ATTENDEE_PROPERTY);
e_calendar_view_edit_appointment (gcal->priv->views[gcal->priv->current_view_type],
- client, icalcomp, attendee_prop ? TRUE:FALSE);
+ client, icalcomp, attendee_prop ? TRUE:FALSE);
icalcomponent_free (icalcomp);
}
diff --git a/calendar/gui/gnome-cal.h b/calendar/gui/gnome-cal.h
index 8524545037..f370c5930a 100644
--- a/calendar/gui/gnome-cal.h
+++ b/calendar/gui/gnome-cal.h
@@ -135,7 +135,7 @@ void gnome_calendar_set_view (GnomeCalendar *gcal, GnomeCalendarViewType view_ty
GtkWidget *gnome_calendar_get_current_view_widget (GnomeCalendar *gcal);
ECalendarTable *gnome_calendar_get_task_pad (GnomeCalendar *gcal);
-GtkWidget *gnome_calendar_get_e_calendar_widget (GnomeCalendar *gcal);
+GtkWidget *gnome_calendar_get_e_calendar_widget (GnomeCalendar *gcal);
GtkWidget *gnome_calendar_get_search_bar_widget (GnomeCalendar *gcal);
GtkWidget *gnome_calendar_get_view_notebook_widget (GnomeCalendar *gcal);
GtkWidget *gnome_calendar_get_tag (GnomeCalendar *gcal);
diff --git a/calendar/gui/goto.c b/calendar/gui/goto.c
index c8cd424d8e..91715e3526 100644
--- a/calendar/gui/goto.c
+++ b/calendar/gui/goto.c
@@ -24,10 +24,10 @@
#include "tag-calendar.h"
#include "goto.h"
-typedef struct
+typedef struct
{
GladeXML *xml;
- GtkWidget *dialog;
+ GtkWidget *dialog;
GtkWidget *month;
GtkWidget *year;
@@ -38,7 +38,7 @@ typedef struct
gint year_val;
gint month_val;
gint day_val;
-
+
} GoToDialog;
static GoToDialog *dlg = NULL;
@@ -59,7 +59,7 @@ month_changed (GtkToggleButton *toggle, gpointer data)
{
GoToDialog *dlg = data;
GtkWidget *menu, *active;
-
+
menu = gtk_option_menu_get_menu (GTK_OPTION_MENU (dlg->month));
active = gtk_menu_get_active (GTK_MENU (menu));
dlg->month_val = g_list_index (GTK_MENU_SHELL (menu)->children, active);
@@ -72,7 +72,7 @@ ecal_date_range_changed (ECalendarItem *calitem, gpointer user_data)
{
GoToDialog *dlg = user_data;
ECal *client;
-
+
client = gnome_calendar_get_default_client (dlg->gcal);
if (client)
tag_calendar_by_client (dlg->ecal, client);
@@ -88,7 +88,7 @@ ecal_event (ECalendarItem *calitem, gpointer user_data)
GDate start_date, end_date;
struct icaltimetype tt = icaltime_null_time ();
time_t et;
-
+
e_calendar_item_get_selection (calitem, &start_date, &end_date);
tt.year = g_date_get_year (&start_date);
@@ -133,10 +133,10 @@ static void
create_ecal (GoToDialog *dlg)
{
ECalendarItem *calitem;
-
+
dlg->ecal = E_CALENDAR (e_calendar_new ());
calitem = dlg->ecal->calitem;
-
+
gnome_canvas_item_set (GNOME_CANVAS_ITEM (calitem),
"move_selection_when_moving", FALSE,
NULL);
@@ -148,7 +148,7 @@ create_ecal (GoToDialog *dlg)
e_calendar_item_set_get_time_callback (calitem,
get_current_time,
dlg, NULL);
-
+
ecal_date_range_changed (calitem, dlg);
}
@@ -179,12 +179,12 @@ get_widgets (GoToDialog *dlg)
}
static void
-goto_dialog_init_widgets (GoToDialog *dlg)
+goto_dialog_init_widgets (GoToDialog *dlg)
{
GtkWidget *menu;
GtkAdjustment *adj;
GList *l;
-
+
menu = gtk_option_menu_get_menu (GTK_OPTION_MENU (dlg->month));
for (l = GTK_MENU_SHELL (menu)->children; l != NULL; l = l->next)
g_signal_connect (menu, "selection_done", G_CALLBACK (month_changed), dlg);
@@ -208,9 +208,9 @@ goto_dialog (GnomeCalendar *gcal)
if (dlg) {
return;
}
-
+
dlg = g_new0 (GoToDialog, 1);
-
+
/* Load the content widgets */
gladefile = g_build_filename (EVOLUTION_GLADEDIR,
"goto-dialog.glade",
@@ -238,7 +238,7 @@ goto_dialog (GnomeCalendar *gcal)
gtk_option_menu_set_history (GTK_OPTION_MENU (dlg->month), dlg->month_val);
gtk_spin_button_set_value (GTK_SPIN_BUTTON (dlg->year), dlg->year_val);
-
+
create_ecal (dlg);
goto_dialog_init_widgets (dlg);
diff --git a/calendar/gui/itip-bonobo-control.c b/calendar/gui/itip-bonobo-control.c
index 03402776e6..d386f2ad58 100644
--- a/calendar/gui/itip-bonobo-control.c
+++ b/calendar/gui/itip-bonobo-control.c
@@ -78,11 +78,11 @@ stream_read (Bonobo_Stream stream)
memcpy (data + length, buffer->_buffer, buffer->_length);
length += buffer->_length;
data[length] = '\0';
-
+
CORBA_free (buffer);
#undef READ_CHUNK_SIZE
} while (1);
-
+
CORBA_free (buffer);
CORBA_exception_free (&ev);
@@ -101,15 +101,15 @@ typedef struct {
} idle_data;
static gboolean
-set_data_idle_cb (gpointer data)
-{
+set_data_idle_cb (gpointer data)
+{
idle_data *id = data;
-
+
e_itip_control_set_data (id->itip, id->text);
g_object_unref (id->itip);
g_free (id->text);
g_free (id);
-
+
return FALSE;
}
@@ -120,8 +120,8 @@ pstream_load (BonoboPersistStream *ps, const Bonobo_Stream stream,
{
EItipControl *itip = data;
idle_data *id;
-
- if (type && g_ascii_strcasecmp (type, "text/calendar") != 0 &&
+
+ if (type && g_ascii_strcasecmp (type, "text/calendar") != 0 &&
g_ascii_strcasecmp (type, "text/x-calendar") != 0) {
bonobo_exception_set (ev, ex_Bonobo_Persist_WrongDataType);
return;
@@ -135,7 +135,7 @@ pstream_load (BonoboPersistStream *ps, const Bonobo_Stream stream,
}
g_object_ref (itip);
id->itip = itip;
-
+
g_idle_add (set_data_idle_cb, id);
}
/*
@@ -150,8 +150,8 @@ pstream_save (BonoboPersistStream *ps, const Bonobo_Stream stream,
gchar *text;
gint len;
- if (type && g_ascii_strcasecmp (type, "text/calendar") != 0 &&
- g_ascii_strcasecmp (type, "text/x-calendar") != 0) {
+ if (type && g_ascii_strcasecmp (type, "text/calendar") != 0 &&
+ g_ascii_strcasecmp (type, "text/x-calendar") != 0) {
bonobo_exception_set (ev, ex_Bonobo_Persist_WrongDataType);
return;
}
@@ -169,9 +169,9 @@ pstream_save (BonoboPersistStream *ps, const Bonobo_Stream stream,
/* { */
/* EItipControl *itip = data; */
/* gint len; */
-
+
/* len = e_itip_control_get_data_size (itip); */
-
+
/* if (len > 0) */
/* return len; */
@@ -186,9 +186,9 @@ pstream_get_content_types (BonoboPersistStream *ps, void *closure,
}
static void
-get_prop (BonoboPropertyBag *bag,
+get_prop (BonoboPropertyBag *bag,
BonoboArg *arg,
- guint arg_id,
+ guint arg_id,
CORBA_Environment *ev,
gpointer user_data)
{
@@ -205,9 +205,9 @@ get_prop (BonoboPropertyBag *bag,
}
static void
-set_prop ( BonoboPropertyBag *bag,
+set_prop ( BonoboPropertyBag *bag,
const BonoboArg *arg,
- guint arg_id,
+ guint arg_id,
CORBA_Environment *ev,
gpointer user_data)
{
@@ -235,7 +235,7 @@ itip_bonobo_control_new (void)
itip = e_itip_control_new ();
gtk_widget_show (itip);
control = bonobo_control_new (itip);
-
+
/* create a property bag */
prop_bag = bonobo_property_bag_new (get_prop, set_prop, itip);
bonobo_property_bag_add (prop_bag, "from_address", FROM_ADDRESS_ARG_ID, BONOBO_ARG_STRING, NULL,
diff --git a/calendar/gui/itip-bonobo-control.h b/calendar/gui/itip-bonobo-control.h
index 42b1d03d8a..84a4fea8ef 100644
--- a/calendar/gui/itip-bonobo-control.h
+++ b/calendar/gui/itip-bonobo-control.h
@@ -3,7 +3,7 @@
* Copyright (C) 2000 Ximian, Inc.
* Copyright (C) 2000 Ximian, Inc.
*
- * Authors:
+ * Authors:
* Jesse Pavel <jpavel@ximian.com>
* JP Rosevear <jpr@ximian.com>
*
diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c
index 2cfd5244c3..63b0163ef9 100644
--- a/calendar/gui/itip-utils.c
+++ b/calendar/gui/itip-utils.c
@@ -93,7 +93,7 @@ itip_organizer_is_user (ECalComponent *comp, ECal *client)
ECalComponentOrganizer organizer;
const char *strip;
gboolean user_org = FALSE;
-
+
if (!e_cal_component_has_organizer (comp) || e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_NO_ORGANIZER))
return FALSE;
@@ -101,20 +101,20 @@ itip_organizer_is_user (ECalComponent *comp, ECal *client)
if (organizer.value != NULL) {
strip = itip_strip_mailto (organizer.value);
-
- if (e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_ORGANIZER_NOT_EMAIL_ADDRESS)) {
+
+ if (e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_ORGANIZER_NOT_EMAIL_ADDRESS)) {
char *email = NULL;
-
+
if (e_cal_get_cal_address (client, &email, NULL) && !g_ascii_strcasecmp (email, strip)) {
g_free (email);
-
+
return TRUE;
}
-
+
g_free (email);
return FALSE;
}
-
+
user_org = e_account_list_find(itip_addresses_get(), E_ACCOUNT_FIND_ID_ADDRESS, strip) != NULL;
}
@@ -127,7 +127,7 @@ itip_sentby_is_user (ECalComponent *comp)
ECalComponentOrganizer organizer;
const char *strip;
gboolean user_sentby = FALSE;
-
+
if (!e_cal_component_has_organizer (comp))
return FALSE;
@@ -141,7 +141,7 @@ itip_sentby_is_user (ECalComponent *comp)
}
static ECalComponentAttendee *
-get_attendee (GSList *attendees, char *address)
+get_attendee (GSList *attendees, char *address)
{
GSList *l;
@@ -152,15 +152,15 @@ get_attendee (GSList *attendees, char *address)
ECalComponentAttendee *attendee = l->data;
if (!g_ascii_strcasecmp (itip_strip_mailto (attendee->value), address)) {
- return attendee;
- }
+ return attendee;
+ }
}
return NULL;
}
static ECalComponentAttendee *
-get_attendee_if_attendee_sentby_is_user (GSList *attendees, char *address)
+get_attendee_if_attendee_sentby_is_user (GSList *attendees, char *address)
{
GSList *l;
@@ -168,8 +168,8 @@ get_attendee_if_attendee_sentby_is_user (GSList *attendees, char *address)
ECalComponentAttendee *attendee = l->data;
if (attendee->sentby && g_str_equal (itip_strip_mailto (attendee->sentby), address)) {
- return attendee;
- }
+ return attendee;
+ }
}
return NULL;
@@ -200,8 +200,8 @@ html_new_lines_for (char *string)
html_string[index++] = *temp;
temp++;
}
- temp++;
-
+ temp++;
+
html_string[index++] = '<';
html_string[index++] = 'b';
html_string[index++] = 'r';
@@ -216,9 +216,9 @@ html_new_lines_for (char *string)
html_string[index++] = *temp;
temp++;
}
-
+
html_string[index] = '\0';
-
+
return html_string;
}
@@ -232,14 +232,14 @@ itip_get_comp_attendee (ECalComponent *comp, ECal *client)
ECalComponentAttendee *attendee = NULL;
char *address = NULL;
- e_cal_component_get_attendee_list (comp, &attendees);
+ e_cal_component_get_attendee_list (comp, &attendees);
al = itip_addresses_get ();
-
+
if (client)
e_cal_get_cal_address (client, &address, NULL);
if (address && *address) {
- attendee = get_attendee (attendees, address);
+ attendee = get_attendee (attendees, address);
if (attendee) {
char *user_email = g_strdup (itip_strip_mailto (attendee->value));
@@ -268,15 +268,15 @@ itip_get_comp_attendee (ECalComponent *comp, ECal *client)
e_iterator_next(it)) {
a = (EAccount *) e_iterator_get(it);
- if (!a->enabled)
+ if (!a->enabled)
continue;
attendee = get_attendee (attendees, a->id->address);
if (attendee) {
char *user_email = g_strdup (itip_strip_mailto (attendee->value));
-
+
e_cal_component_free_attendee_list (attendees);
- return user_email;
+ return user_email;
}
/* If the account was not found in the attendees list, then let's
@@ -284,9 +284,9 @@ itip_get_comp_attendee (ECalComponent *comp, ECal *client)
attendee = get_attendee_if_attendee_sentby_is_user (attendees, a->id->address);
if (attendee) {
char *user_email = g_strdup (itip_strip_mailto (attendee->sentby));
-
+
e_cal_component_free_attendee_list (attendees);
- return user_email;
+ return user_email;
}
}
@@ -295,17 +295,17 @@ itip_get_comp_attendee (ECalComponent *comp, ECal *client)
/* FIXME do we have a better way ? */
a = itip_addresses_get_default ();
address = g_strdup ((a != NULL) ? a->id->address : "");
-
+
e_cal_component_free_attendee_list (attendees);
return address;
}
const gchar *
-itip_strip_mailto (const gchar *address)
+itip_strip_mailto (const gchar *address)
{
if (address == NULL)
return NULL;
-
+
if (!g_ascii_strncasecmp (address, "mailto:", 7))
address += 7;
@@ -329,7 +329,7 @@ get_label (struct icaltimetype *tt)
typedef struct {
GHashTable *tzids;
- icalcomponent *icomp;
+ icalcomponent *icomp;
ECal *client;
icalcomponent *zones;
} ItipUtilTZData;
@@ -338,7 +338,7 @@ typedef struct {
static void
foreach_tzid_callback (icalparameter *param, gpointer data)
{
- ItipUtilTZData *tz_data = data;
+ ItipUtilTZData *tz_data = data;
const char *tzid;
icaltimezone *zone = NULL;
icalcomponent *vtimezone_comp;
@@ -353,7 +353,7 @@ foreach_tzid_callback (icalparameter *param, gpointer data)
zone = icalcomponent_get_timezone (tz_data->zones, tzid);
if (zone == NULL)
zone = icaltimezone_get_builtin_timezone_from_tzid (tzid);
- if (zone == NULL && tz_data->client != NULL)
+ if (zone == NULL && tz_data->client != NULL)
e_cal_get_timezone (tz_data->client, tzid, &zone, NULL);
if (zone == NULL)
return;
@@ -364,7 +364,7 @@ foreach_tzid_callback (icalparameter *param, gpointer data)
return;
icalcomponent_add_component (tz_data->icomp, icalcomponent_new_clone (vtimezone_comp));
- g_hash_table_insert (tz_data->tzids, (char *)tzid, (char *)tzid);
+ g_hash_table_insert (tz_data->tzids, (char *)tzid, (char *)tzid);
}
static icalcomponent *
@@ -384,7 +384,7 @@ comp_toplevel_with_zones (ECalComponentItipMethod method, ECalComponent *comp, E
icomp = e_cal_component_get_icalcomponent (comp);
icomp = icalcomponent_new_clone (icomp);
-
+
tz_data.tzids = g_hash_table_new (g_str_hash, g_str_equal);
tz_data.icomp = top_level;
tz_data.client = client;
@@ -418,33 +418,33 @@ comp_from (ECalComponentItipMethod method, ECalComponent *comp)
GSList *attendees;
CORBA_char *str;
char *sender = NULL;
-
+
switch (method) {
case E_CAL_COMPONENT_METHOD_PUBLISH:
return CORBA_string_dup ("");
-
+
case E_CAL_COMPONENT_METHOD_REQUEST:
sender = itip_get_comp_attendee (comp, NULL);
if (sender) {
str = CORBA_string_dup (sender);
g_free (sender);
return str;
- }
-
- case E_CAL_COMPONENT_METHOD_REPLY:
+ }
+
+ case E_CAL_COMPONENT_METHOD_REPLY:
sender = itip_get_comp_attendee (comp, NULL);
if (sender) {
str = CORBA_string_dup (sender);
g_free (sender);
return str;
- }
+ }
if (!e_cal_component_has_attendees (comp))
return CORBA_string_dup ("");
case E_CAL_COMPONENT_METHOD_CANCEL:
- case E_CAL_COMPONENT_METHOD_ADD:
-
+ case E_CAL_COMPONENT_METHOD_ADD:
+
e_cal_component_get_organizer (comp, &organizer);
if (organizer.value == NULL) {
e_notice (NULL, GTK_MESSAGE_ERROR,
@@ -453,7 +453,7 @@ comp_from (ECalComponentItipMethod method, ECalComponent *comp)
}
return CORBA_string_dup (itip_strip_mailto (organizer.value));
-
+
default:
if (!e_cal_component_has_attendees (comp))
return CORBA_string_dup ("");
@@ -488,7 +488,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
e_cal_component_free_attendee_list (attendees);
return NULL;
}
-
+
to_list = GNOME_Evolution_Composer_RecipientList__alloc ();
to_list->_maximum = len;
to_list->_length = 0;
@@ -526,7 +526,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
else
recipient->name = CORBA_string_dup ("");
recipient->address = CORBA_string_dup (itip_strip_mailto (att->value));
-
+
to_list->_length++;
}
g_free (sender);
@@ -547,7 +547,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
e_cal_component_free_attendee_list (attendees);
return to_list;
}
-
+
to_list = GNOME_Evolution_Composer_RecipientList__alloc ();
to_list->_maximum = len;
to_list->_length = 0;
@@ -559,14 +559,14 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
for (l = attendees; l != NULL; l = l->next) {
ECalComponentAttendee *att = l->data;
-
+
recipient = &(to_list->_buffer[to_list->_length]);
if (att->cn)
recipient->name = CORBA_string_dup (att->cn);
else
recipient->name = CORBA_string_dup ("");
recipient->address = CORBA_string_dup (itip_strip_mailto (att->value));
-
+
to_list->_length++;
}
@@ -581,7 +581,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
to_list->_buffer = CORBA_sequence_GNOME_Evolution_Composer_Recipient_allocbuf (1);
recipient = &(to_list->_buffer[to_list->_length]);
-
+
e_cal_component_get_organizer (comp, &organizer);
if (organizer.value) {
recipient->name = CORBA_string_dup ("");
@@ -591,11 +591,11 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
} else {
recipient->address = CORBA_string_dup ("");
recipient->name = CORBA_string_dup ("");
- }
+ }
}
break;
-
-
+
+
case E_CAL_COMPONENT_METHOD_ADD:
case E_CAL_COMPONENT_METHOD_REFRESH:
case E_CAL_COMPONENT_METHOD_COUNTER:
@@ -606,7 +606,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
_("An organizer must be set."));
return NULL;
}
-
+
len = 2;
to_list = GNOME_Evolution_Composer_RecipientList__alloc ();
@@ -621,8 +621,8 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
else
recipient->name = CORBA_string_dup ("");
recipient->address = CORBA_string_dup (itip_strip_mailto (organizer.value));
-
- /* send the status to delegatee to the delegate also*/
+
+ /* send the status to delegatee to the delegate also*/
e_cal_component_get_attendee_list (comp, &attendees);
sender = itip_get_comp_attendee (comp, NULL);
@@ -642,7 +642,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
}
e_cal_component_free_attendee_list (attendees);
-
+
break;
case E_CAL_COMPONENT_METHOD_PUBLISH:
if(users) {
@@ -653,7 +653,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
to_list->_maximum = len;
to_list->_length = 0;
to_list->_buffer = CORBA_sequence_GNOME_Evolution_Composer_Recipient_allocbuf (len);
-
+
for (list = users; list != NULL; list = list->next) {
recipient = &(to_list->_buffer[to_list->_length]);
recipient->name = CORBA_string_dup ("");
@@ -670,9 +670,9 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users,
}
CORBA_sequence_set_release (to_list, TRUE);
- return to_list;
+ return to_list;
}
-
+
static CORBA_char *
comp_subject (ECalComponentItipMethod method, ECalComponent *comp)
{
@@ -684,7 +684,7 @@ comp_subject (ECalComponentItipMethod method, ECalComponent *comp)
ECalComponentAttendee *a = NULL;
e_cal_component_get_summary (comp, &caltext);
- if (caltext.value != NULL)
+ if (caltext.value != NULL)
description = caltext.value;
else {
switch (e_cal_component_get_vtype (comp)) {
@@ -717,7 +717,7 @@ comp_subject (ECalComponentItipMethod method, ECalComponent *comp)
for (l = alist; l != NULL ; l = l->next) {
a = l->data;
- if ((sender && *sender) && (g_ascii_strcasecmp (itip_strip_mailto (a->value), sender) || (a->sentby && g_ascii_strcasecmp (itip_strip_mailto (a->sentby), sender))))
+ if ((sender && *sender) && (g_ascii_strcasecmp (itip_strip_mailto (a->value), sender) || (a->sentby && g_ascii_strcasecmp (itip_strip_mailto (a->sentby), sender))))
break;
}
g_free (sender);
@@ -782,8 +782,8 @@ comp_subject (ECalComponentItipMethod method, ECalComponent *comp)
static CORBA_char *
comp_content_type (ECalComponent *comp, ECalComponentItipMethod method)
{
- char tmp[256];
-
+ char tmp[256];
+
sprintf (tmp, "text/calendar; name=\"%s\"; charset=utf-8; METHOD=%s",
e_cal_component_get_vtype (comp) == E_CAL_COMPONENT_FREEBUSY ?
"freebusy.ifb" : "calendar.ics", itip_methods[method]);
@@ -845,20 +845,20 @@ comp_description (ECalComponent *comp)
}
static gboolean
-comp_server_send (ECalComponentItipMethod method, ECalComponent *comp, ECal *client,
+comp_server_send (ECalComponentItipMethod method, ECalComponent *comp, ECal *client,
icalcomponent *zones, GList **users)
{
icalcomponent *top_level, *returned_icalcomp = NULL;
gboolean retval = TRUE;
GError *error = NULL;
-
+
top_level = comp_toplevel_with_zones (method, comp, client, zones);
if (!e_cal_send_objects (client, top_level, users, &returned_icalcomp, &error)) {
/* FIXME Really need a book problem status code */
if (error->code != E_CALENDAR_STATUS_OK) {
/* FIXME Better error message */
e_notice (NULL, GTK_MESSAGE_ERROR, "Unable to book");
-
+
retval = FALSE;
}
}
@@ -873,7 +873,7 @@ comp_server_send (ECalComponentItipMethod method, ECalComponent *comp, ECal *cli
}
static gboolean
-comp_limit_attendees (ECalComponent *comp)
+comp_limit_attendees (ECalComponent *comp)
{
icalcomponent *icomp;
icalproperty *prop;
@@ -897,7 +897,7 @@ comp_limit_attendees (ECalComponent *comp)
list = g_slist_prepend (list, prop);
continue;
}
-
+
attendee = icalproperty_get_value_as_string (prop);
if (!attendee)
continue;
@@ -918,7 +918,7 @@ comp_limit_attendees (ECalComponent *comp)
g_free(attendee_text);
g_free (attendee_sentby_text);
-
+
if (!match)
list = g_slist_prepend (list, prop);
match = FALSE;
@@ -941,7 +941,7 @@ comp_sentby (ECalComponent *comp, ECal *client)
ECalComponentOrganizer organizer;
GSList * attendees, *l;
char *user = NULL;
-
+
e_cal_component_get_organizer (comp, &organizer);
if (!organizer.value) {
EAccount *a = itip_addresses_get_default ();
@@ -950,10 +950,10 @@ comp_sentby (ECalComponent *comp, ECal *client)
organizer.sentby = NULL;
organizer.cn = a->id->name;
organizer.language = NULL;
-
+
e_cal_component_set_organizer (comp, &organizer);
g_free ((char *) organizer.value);
-
+
return;
}
@@ -967,15 +967,15 @@ comp_sentby (ECalComponent *comp, ECal *client)
return;
}
}
-
+
if (!itip_organizer_is_user (comp, client) && !itip_sentby_is_user (comp)) {
EAccount *a = itip_addresses_get_default ();
-
+
organizer.value = g_strdup (organizer.value);
organizer.sentby = g_strdup_printf ("MAILTO:%s", a->id->address);
organizer.cn = g_strdup (organizer.cn);
organizer.language = g_strdup (organizer.language);
-
+
e_cal_component_set_organizer (comp, &organizer);
g_free ((char *)organizer.value);
@@ -995,13 +995,13 @@ comp_minimal (ECalComponent *comp, gboolean attendee)
GSList *comments;
struct icaltimetype itt;
ECalComponentRange recur_id;
-
+
clone = e_cal_component_new ();
e_cal_component_set_new_vtype (clone, e_cal_component_get_vtype (comp));
if (attendee) {
GSList *attendees;
-
+
e_cal_component_get_attendee_list (comp, &attendees);
e_cal_component_set_attendee_list (clone, attendees);
@@ -1011,7 +1011,7 @@ comp_minimal (ECalComponent *comp, gboolean attendee)
goto error;
}
}
-
+
itt = icaltime_from_timet_with_zone (time (NULL), FALSE,
icaltimezone_get_utc_timezone ());
e_cal_component_set_dtstamp (clone, &itt);
@@ -1029,17 +1029,17 @@ comp_minimal (ECalComponent *comp, gboolean attendee)
e_cal_component_set_comment_list (clone, comments);
} else {
GSList *l = comments;
-
+
comments = g_slist_remove_link (comments, l);
e_cal_component_set_comment_list (clone, l);
e_cal_component_free_text_list (l);
}
e_cal_component_free_text_list (comments);
-
+
e_cal_component_get_recurid (comp, &recur_id);
if (recur_id.datetime.value != NULL)
e_cal_component_set_recurid (clone, &recur_id);
-
+
icomp = e_cal_component_get_icalcomponent (comp);
icomp_clone = e_cal_component_get_icalcomponent (clone);
for (prop = icalcomponent_get_first_property (icomp, ICAL_X_PROPERTY);
@@ -1047,13 +1047,13 @@ comp_minimal (ECalComponent *comp, gboolean attendee)
prop = icalcomponent_get_next_property (icomp, ICAL_X_PROPERTY))
{
icalproperty *p;
-
+
p = icalproperty_new_clone (prop);
icalcomponent_add_property (icomp_clone, p);
}
e_cal_component_rescan (clone);
-
+
return clone;
error:
@@ -1066,7 +1066,7 @@ comp_compliant (ECalComponentItipMethod method, ECalComponent *comp, ECal *clien
{
ECalComponent *clone, *temp_clone;
struct icaltimetype itt;
-
+
clone = e_cal_component_clone (comp);
itt = icaltime_from_timet_with_zone (time (NULL), FALSE,
icaltimezone_get_utc_timezone ());
@@ -1077,14 +1077,14 @@ comp_compliant (ECalComponentItipMethod method, ECalComponent *comp, ECal *clien
&& e_cal_component_has_simple_recurrence (clone)) {
GSList *rrule_list;
struct icalrecurrencetype *r;
-
+
e_cal_component_get_rrule_list (clone, &rrule_list);
r = rrule_list->data;
if (!icaltime_is_null_time (r->until) && r->until.is_date) {
ECalComponentDateTime dt;
icaltimezone *from_zone = NULL, *to_zone;
-
+
e_cal_component_get_dtstart (clone, &dt);
if (dt.value->is_date) {
@@ -1100,14 +1100,14 @@ comp_compliant (ECalComponentItipMethod method, ECalComponent *comp, ECal *clien
/* FIXME Error checking */
e_cal_get_timezone (client, dt.tzid, &from_zone, NULL);
}
-
+
to_zone = icaltimezone_get_utc_timezone ();
r->until.hour = dt.value->hour;
r->until.minute = dt.value->minute;
r->until.second = dt.value->second;
r->until.is_date = FALSE;
-
+
icaltimezone_convert_time (&r->until, from_zone, to_zone);
r->until.is_utc = TRUE;
@@ -1117,13 +1117,13 @@ comp_compliant (ECalComponentItipMethod method, ECalComponent *comp, ECal *clien
e_cal_component_free_recur_list (rrule_list);
}
-
+
/* We delete incoming alarms anyhow, and this helps with outlook */
e_cal_component_remove_all_alarms (clone);
/* Strip X-LIC-ERROR stuff */
e_cal_component_strip_errors (clone);
-
+
/* Comply with itip spec */
switch (method) {
case E_CAL_COMPONENT_METHOD_PUBLISH:
@@ -1135,7 +1135,7 @@ comp_compliant (ECalComponentItipMethod method, ECalComponent *comp, ECal *clien
break;
case E_CAL_COMPONENT_METHOD_CANCEL:
comp_sentby (clone, client);
- break;
+ break;
case E_CAL_COMPONENT_METHOD_REPLY:
break;
case E_CAL_COMPONENT_METHOD_ADD:
@@ -1176,14 +1176,14 @@ append_cal_attachments (GNOME_Evolution_Composer composer_server, ECalComponent
for (l = attach_list; l ; l = l->next) {
mime_attach = (struct CalMimeAttach *) l->data;
-
+
filename = CORBA_string_dup (mime_attach->filename ? mime_attach->filename : "");
content_type = CORBA_string_dup (mime_attach->content_type);
description = CORBA_string_dup (mime_attach->description);
-
+
attach_data = GNOME_Evolution_Composer_AttachmentData__alloc ();
attach_data->_length = mime_attach->length;
- attach_data->_maximum = attach_data->_length;
+ attach_data->_maximum = attach_data->_length;
attach_data->_buffer = CORBA_sequence_CORBA_char_allocbuf (attach_data->_length);
memcpy (attach_data->_buffer, mime_attach->encoded_data, attach_data->_length);
@@ -1212,7 +1212,7 @@ append_cal_attachments (GNOME_Evolution_Composer composer_server, ECalComponent
g_free (mime_attach->description);
g_free (mime_attach->encoded_data);
}
-
+
return retval;
}
@@ -1236,7 +1236,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp,
/* check whether backend could handle sending requests/updates */
if (method != E_CAL_COMPONENT_METHOD_PUBLISH && e_cal_get_save_schedules (client))
return TRUE;
-
+
CORBA_exception_init (&ev);
/* Give the server a chance to manipulate the comp */
@@ -1244,7 +1244,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp,
if (!comp_server_send (method, send_comp, client, zones, &users))
goto cleanup;
}
-
+
/* Tidy up the comp */
comp = comp_compliant (method, send_comp, client, zones);
@@ -1269,10 +1269,10 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp,
cc_list->_maximum = cc_list->_length = 0;
bcc_list = GNOME_Evolution_Composer_RecipientList__alloc ();
bcc_list->_maximum = bcc_list->_length = 0;
-
+
/* Subject information */
subject = comp_subject (method, comp);
-
+
/* From address */
from = comp_from (method, comp);
@@ -1319,7 +1319,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp,
attach_data = GNOME_Evolution_Composer_AttachmentData__alloc ();
attach_data->_length = strlen (ical_string);
- attach_data->_maximum = attach_data->_length;
+ attach_data->_maximum = attach_data->_length;
attach_data->_buffer = CORBA_sequence_CORBA_char_allocbuf (attach_data->_length);
memcpy (attach_data->_buffer, ical_string, attach_data->_length);
@@ -1328,7 +1328,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp,
TRUE, attach_data,
&ev);
}
-
+
if (BONOBO_EX (&ev)) {
g_warning ("Unable to place iTip message in composer");
goto cleanup;
@@ -1345,14 +1345,14 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp,
g_warning ("Unable to show the composer while sending iTip message");
else
retval = TRUE;
- } else {
+ } else {
GNOME_Evolution_Composer_send (composer_server, &ev);
if (BONOBO_EX (&ev))
g_warning ("Unable to send iTip message");
else
retval = TRUE;
}
-
+
cleanup:
CORBA_exception_free (&ev);
@@ -1365,7 +1365,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp,
g_list_foreach (users, (GFunc) g_free, NULL);
g_list_free (users);
}
-
+
if (to_list != NULL)
CORBA_free (to_list);
if (cc_list != NULL)
@@ -1425,10 +1425,10 @@ reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *send_comp
cc_list->_maximum = cc_list->_length = 0;
bcc_list = GNOME_Evolution_Composer_RecipientList__alloc ();
bcc_list->_maximum = bcc_list->_length = 0;
-
+
/* Subject information */
subject = comp_subject (method, comp);
-
+
/* From address */
from = comp_from (method, comp);
@@ -1457,7 +1457,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *send_comp
ical_string = icalcomponent_as_ical_string (top_level);
if (e_cal_component_get_vtype (comp) == E_CAL_COMPONENT_EVENT){
-
+
GString *body;
char *orig_from = NULL;
char *description = NULL;
@@ -1480,7 +1480,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *send_comp
description = (char *)text.value;
else
description = "";
- } else {
+ } else {
description = "";
}
@@ -1496,12 +1496,12 @@ reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *send_comp
if (organizer.value)
orig_from = g_strdup (itip_strip_mailto (organizer.value));
-
+
e_cal_component_get_location (comp, &location);
if (!location)
location = "Unspecified";
-
+
e_cal_component_get_dtstart (comp, &dtstart);
if (dtstart.value) {
start_zone = icaltimezone_get_builtin_timezone_from_tzid (dtstart.tzid);
@@ -1516,8 +1516,8 @@ reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *send_comp
start = icaltime_as_timet_with_zone (*dtstart.value, start_zone);
time = g_strdup (ctime (&start));
}
-
-
+
+
body = g_string_new ("<br><br><hr><br><b>______ Original Appointment ______ </b><br><br><table>");
if (orig_from && *orig_from)
@@ -1558,13 +1558,13 @@ reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *send_comp
}
-
+
GNOME_Evolution_Composer_show (composer_server, &ev);
if (BONOBO_EX (&ev))
g_warning ("Unable to show the composer while sending iTip message");
else
retval = TRUE;
-
+
cleanup:
CORBA_exception_free (&ev);
@@ -1577,7 +1577,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *send_comp
g_list_foreach (users, (GFunc) g_free, NULL);
g_list_free (users);
}
-
+
if (to_list != NULL)
CORBA_free (to_list);
if (cc_list != NULL)
@@ -1596,33 +1596,33 @@ reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *send_comp
}
gboolean
-itip_publish_begin (ECalComponent *pub_comp, ECal *client,
+itip_publish_begin (ECalComponent *pub_comp, ECal *client,
gboolean cloned, ECalComponent **clone)
{
icalcomponent *icomp =NULL, *icomp_clone = NULL;
icalproperty *prop;
-
+
if (e_cal_component_get_vtype (pub_comp) == E_CAL_COMPONENT_FREEBUSY) {
-
+
if (!cloned) {
*clone = e_cal_component_clone (pub_comp);
cloned = TRUE;
} else {
-
+
icomp = e_cal_component_get_icalcomponent (pub_comp);
icomp_clone = e_cal_component_get_icalcomponent (*clone);
for (prop = icalcomponent_get_first_property (icomp,
ICAL_FREEBUSY_PROPERTY);
prop != NULL;
- prop = icalcomponent_get_next_property (icomp,
+ prop = icalcomponent_get_next_property (icomp,
ICAL_FREEBUSY_PROPERTY))
{
icalproperty *p;
-
+
p = icalproperty_new_clone (prop);
icalcomponent_add_property (icomp_clone, p);
}
- }
+ }
}
return TRUE;
@@ -1632,19 +1632,19 @@ static void
fb_sort (struct icalperiodtype *ipt, int fb_count)
{
int i,j;
-
+
if (ipt == NULL || fb_count == 0)
return;
-
+
for (i = 0; i < fb_count-1; i++) {
for (j = i+1; j < fb_count; j++) {
struct icalperiodtype temp;
-
+
if (icaltime_compare (ipt[i].start, ipt[j].start) < 0)
continue;
-
+
if (icaltime_compare (ipt[i].start, ipt[j].start) == 0){
- if (icaltime_compare (ipt[i].end,
+ if (icaltime_compare (ipt[i].end,
ipt[j].start) < 0)
continue;
}
@@ -1664,48 +1664,48 @@ comp_fb_normalize (icalcomponent *icomp)
struct icaltimetype itt;
int fb_count, i = 0, j;
struct icalperiodtype *ipt;
-
+
iclone = icalcomponent_new (ICAL_VFREEBUSY_COMPONENT);
-
- prop = icalcomponent_get_first_property (icomp,
+
+ prop = icalcomponent_get_first_property (icomp,
ICAL_ORGANIZER_PROPERTY);
if (prop) {
p = icalproperty_new_clone (prop);
icalcomponent_add_property (iclone, p);
}
-
+
itt = icalcomponent_get_dtstart (icomp);
icalcomponent_set_dtstart (iclone, itt);
-
+
itt = icalcomponent_get_dtend (icomp);
icalcomponent_set_dtend (iclone, itt);
-
- fb_count = icalcomponent_count_properties (icomp,
+
+ fb_count = icalcomponent_count_properties (icomp,
ICAL_FREEBUSY_PROPERTY);
ipt = g_new0 (struct icalperiodtype, fb_count+1);
-
- for (prop = icalcomponent_get_first_property (icomp,
+
+ for (prop = icalcomponent_get_first_property (icomp,
ICAL_FREEBUSY_PROPERTY);
prop != NULL;
- prop = icalcomponent_get_next_property (icomp,
+ prop = icalcomponent_get_next_property (icomp,
ICAL_FREEBUSY_PROPERTY))
{
ipt[i] = icalproperty_get_freebusy (prop);
i++;
}
-
+
fb_sort (ipt, fb_count);
-
+
for (j = 0; j <= fb_count-1; j++) {
icalparameter *param;
-
+
prop = icalproperty_new_freebusy (ipt[j]);
param = icalparameter_new_fbtype (ICAL_FBTYPE_BUSY);
icalproperty_add_parameter (prop, param);
icalcomponent_add_property (iclone, prop);
}
g_free (ipt);
-
+
/* Should I strip this RFC 2446 says there must not be a UID
if the METHOD is PUBLISH?? */
uid = icalcomponent_get_uid (icomp);
@@ -1714,14 +1714,14 @@ comp_fb_normalize (icalcomponent *icomp)
itt = icaltime_from_timet_with_zone (time (NULL), FALSE,
icaltimezone_get_utc_timezone ());
- icalcomponent_set_dtstamp (iclone, itt);
-
+ icalcomponent_set_dtstamp (iclone, itt);
+
prop = icalcomponent_get_first_property (icomp, ICAL_URL_PROPERTY);
if (prop) {
p = icalproperty_new_clone (prop);
icalcomponent_add_property (iclone, p);
}
-
+
comment = icalcomponent_get_comment (icomp);
if (comment)
icalcomponent_set_comment (iclone, comment);
@@ -1729,11 +1729,11 @@ comp_fb_normalize (icalcomponent *icomp)
for (prop = icalcomponent_get_first_property (icomp, ICAL_X_PROPERTY);
prop != NULL;
prop = icalcomponent_get_next_property (icomp, ICAL_X_PROPERTY))
- {
+ {
p = icalproperty_new_clone (prop);
icalcomponent_add_property (iclone, p);
}
-
+
return iclone;
/* this will never be reached */
g_object_unref (iclone);
@@ -1741,7 +1741,7 @@ comp_fb_normalize (icalcomponent *icomp)
}
gboolean
-itip_publish_comp (ECal *client, gchar *uri, gchar *username,
+itip_publish_comp (ECal *client, gchar *uri, gchar *username,
gchar *password, ECalComponent **pub_comp)
{
icalcomponent *toplevel = NULL, *icalcomp = NULL;
@@ -1750,15 +1750,15 @@ itip_publish_comp (ECal *client, gchar *uri, gchar *username,
SoupMessage *msg;
SoupUri *real_uri;
char *ical_string;
-
+
toplevel = e_cal_util_new_top_level ();
icalcomponent_set_method (toplevel, ICAL_METHOD_PUBLISH);
-
+
e_cal_component_set_url (*pub_comp, uri);
-
+
icalcomp = e_cal_component_get_icalcomponent (*pub_comp);
-
- icomp = comp_fb_normalize (icalcomp);
+
+ icomp = comp_fb_normalize (icalcomp);
icalcomponent_add_component (toplevel, icomp);
ical_string = icalcomponent_as_ical_string (toplevel);
@@ -1772,10 +1772,10 @@ itip_publish_comp (ECal *client, gchar *uri, gchar *username,
g_object_unref (session);
return FALSE;
}
-
+
real_uri->user = g_strdup (username);
real_uri->passwd = g_strdup (password);
-
+
/* build the SOAP message */
msg = soup_message_new_from_uri (SOUP_METHOD_PUT, real_uri);
if (!msg) {
@@ -1783,23 +1783,23 @@ itip_publish_comp (ECal *client, gchar *uri, gchar *username,
g_object_unref (session);
return FALSE;
}
- soup_message_set_flags (msg, SOUP_MESSAGE_NO_REDIRECT);
+ soup_message_set_flags (msg, SOUP_MESSAGE_NO_REDIRECT);
soup_message_set_request (msg, "text/calendar", SOUP_BUFFER_USER_OWNED,
ical_string, strlen (ical_string));
-
+
/* send message to server */
soup_session_send_message (session, msg);
if (!SOUP_STATUS_IS_SUCCESSFUL (msg->status_code)) {
- g_warning(G_STRLOC ": Could not publish Free/Busy: %d: %s",
- msg->status_code,
+ g_warning(G_STRLOC ": Could not publish Free/Busy: %d: %s",
+ msg->status_code,
soup_status_get_phrase (msg->status_code));
g_object_unref (session);
return FALSE;
}
-
+
soup_uri_free (real_uri);
g_object_unref (session);
-
+
return TRUE;
}
diff --git a/calendar/gui/itip-utils.h b/calendar/gui/itip-utils.h
index eded65974d..e7014c9f47 100644
--- a/calendar/gui/itip-utils.h
+++ b/calendar/gui/itip-utils.h
@@ -42,10 +42,10 @@ char *itip_get_comp_attendee (ECalComponent *comp, ECal *client);
gboolean itip_send_comp (ECalComponentItipMethod method, ECalComponent *comp,
ECal *client, icalcomponent *zones, GSList *attachments_list, GList *users);
-gboolean itip_publish_comp (ECal *client, gchar* uri, gchar* username,
+gboolean itip_publish_comp (ECal *client, gchar* uri, gchar* username,
gchar* password, ECalComponent **pub_comp);
-gboolean itip_publish_begin (ECalComponent *pub_comp, ECal *client,
+gboolean itip_publish_begin (ECalComponent *pub_comp, ECal *client,
gboolean cloned, ECalComponent **clone);
gboolean reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *send_comp,
diff --git a/calendar/gui/main.c b/calendar/gui/main.c
index cbd90ea431..3f15b77c8e 100644
--- a/calendar/gui/main.c
+++ b/calendar/gui/main.c
@@ -130,14 +130,14 @@ initialize (void)
EImportClass *klass;
comp_editor_registry = E_COMP_EDITOR_REGISTRY (e_comp_editor_registry_new ());
-
+
#if 0
itip_control_factory_init ();
component_editor_factory_init ();
#endif
launch_alarm_daemon ();
-
+
/* Initialize plugin system */
e_plugin_hook_register_type (e_cal_popup_hook_get_type());
diff --git a/calendar/gui/memos-component.c b/calendar/gui/memos-component.c
index 40b71cf5f5..8766649959 100644
--- a/calendar/gui/memos-component.c
+++ b/calendar/gui/memos-component.c
@@ -84,16 +84,16 @@ extern ECompEditorRegistry *comp_editor_registry;
typedef struct _MemosComponentView
{
ESourceList *source_list;
-
+
GSList *source_selection;
-
+
EMemos *memos;
ETable *table;
ETableModel *model;
EInfoLabel *info_label;
GtkWidget *source_selector;
-
+
BonoboControl *view_control;
BonoboControl *sidebar_control;
BonoboControl *statusbar_control;
@@ -113,9 +113,9 @@ struct _MemosComponentPrivate {
GSList *source_selection;
GList *views;
-
+
ECal *create_ecal;
-
+
GList *notifications;
};
@@ -157,7 +157,7 @@ ensure_sources (MemosComponent *component)
group = E_SOURCE_GROUP (g->data);
- /* compare only file:// part. If user home dir name changes we do not want to create
+ /* compare only file:// part. If user home dir name changes we do not want to create
one more group */
if (!on_this_computer && !strncmp (base_uri_proto, e_source_group_peek_base_uri (group), 7))
@@ -249,10 +249,10 @@ static gboolean
is_in_selection (GSList *selection, ESource *source)
{
GSList *l;
-
+
for (l = selection; l; l = l->next) {
ESource *selected_source = l->data;
-
+
if (!strcmp (e_source_peek_uid (selected_source), e_source_peek_uid (source)))
return TRUE;
}
@@ -264,10 +264,10 @@ static gboolean
is_in_uids (GSList *uids, ESource *source)
{
GSList *l;
-
+
for (l = uids; l; l = l->next) {
const char *uid = l->data;
-
+
if (!strcmp (uid, e_source_peek_uid (source)))
return TRUE;
}
@@ -279,19 +279,19 @@ static void
update_uris_for_selection (MemosComponentView *component_view)
{
GSList *selection, *l, *uids_selected = NULL;
-
+
selection = e_source_selector_get_selection (E_SOURCE_SELECTOR (component_view->source_selector));
-
+
for (l = component_view->source_selection; l; l = l->next) {
ESource *old_selected_source = l->data;
if (!is_in_selection (selection, old_selected_source))
e_memos_remove_memo_source (component_view->memos, old_selected_source);
- }
-
+ }
+
for (l = selection; l; l = l->next) {
ESource *selected_source = l->data;
-
+
e_memos_add_memo_source (component_view->memos, selected_source);
uids_selected = g_slist_append (uids_selected, (char *)e_source_peek_uid (selected_source));
}
@@ -322,7 +322,7 @@ update_uri_for_primary_selection (MemosComponentView *component_view)
etable = e_memo_table_get_table (cal_table);
memos_control_sensitize_commands (component_view->view_control, component_view->memos, e_table_selected_count (etable));
-
+
/* Save the selection for next time we start up */
calendar_config_set_primary_memos (e_source_peek_uid (source));
}
@@ -331,7 +331,7 @@ static void
update_selection (MemosComponentView *component_view)
{
GSList *selection, *uids_selected, *l;
-
+
d(g_message("memos-component.c: update_selection called");)
/* Get the selection in gconf */
@@ -343,10 +343,10 @@ update_selection (MemosComponentView *component_view)
for (l = selection; l; l = l->next) {
ESource *source = l->data;
- if (!is_in_uids (uids_selected, source))
+ if (!is_in_uids (uids_selected, source))
e_source_selector_unselect_source (E_SOURCE_SELECTOR (component_view->source_selector), source);
}
-
+
e_source_selector_free_selection (selection);
/* Make sure the whole selection is there */
@@ -355,9 +355,9 @@ update_selection (MemosComponentView *component_view)
ESource *source;
source = e_source_list_peek_source_by_uid (component_view->source_list, uid);
- if (source)
+ if (source)
e_source_selector_select_source (E_SOURCE_SELECTOR (component_view->source_selector), source);
-
+
g_free (uid);
}
g_slist_free (uids_selected);
@@ -374,7 +374,7 @@ update_primary_selection (MemosComponentView *component_view)
source = e_source_list_peek_source_by_uid (component_view->source_list, uid);
g_free (uid);
}
-
+
if (source) {
e_source_selector_set_primary_selection (E_SOURCE_SELECTOR (component_view->source_selector), source);
} else {
@@ -394,7 +394,7 @@ copy_memo_list_cb (EPopup *ep, EPopupItem *pitem, void *data)
{
MemosComponentView *component_view = data;
ESource *selected_source;
-
+
selected_source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (component_view->source_selector));
if (!selected_source)
return;
@@ -434,7 +434,7 @@ delete_memo_list_cb (EPopup *ep, EPopupItem *pitem, void *data)
e_source_selector_unselect_source (E_SOURCE_SELECTOR (component_view->source_selector),
selected_source);
}
-
+
e_source_group_remove_source (e_source_peek_group (selected_source), selected_source);
e_source_list_sync (component_view->source_list, NULL);
}
@@ -533,7 +533,7 @@ set_info (MemosComponentView *component_view)
{
GString *message = g_string_new (NULL);
int rows, selected_rows;
-
+
rows = e_table_model_row_count (component_view->model);
selected_rows = e_table_selected_count (component_view->table);
@@ -596,11 +596,11 @@ impl_upgradeFromVersion (PortableServer_Servant servant,
}
static gboolean
-selector_tree_drag_drop (GtkWidget *widget,
- GdkDragContext *context,
- int x,
- int y,
- guint time,
+selector_tree_drag_drop (GtkWidget *widget,
+ GdkDragContext *context,
+ int x,
+ int y,
+ guint time,
CalendarComponent *component)
{
GtkTreeViewColumn *column;
@@ -610,12 +610,12 @@ selector_tree_drag_drop (GtkWidget *widget,
GtkTreeModel *model;
GtkTreeIter iter;
gpointer data;
-
- if (!gtk_tree_view_get_path_at_pos (GTK_TREE_VIEW (widget), x, y, &path,
+
+ if (!gtk_tree_view_get_path_at_pos (GTK_TREE_VIEW (widget), x, y, &path,
&column, &cell_x, &cell_y))
return FALSE;
-
-
+
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
if (!gtk_tree_model_get_iter (model, &iter, path)) {
@@ -624,17 +624,17 @@ selector_tree_drag_drop (GtkWidget *widget,
}
gtk_tree_model_get (model, &iter, 0, &data, -1);
-
+
if (E_IS_SOURCE_GROUP (data)) {
g_object_unref (data);
gtk_tree_path_free (path);
return FALSE;
}
-
+
gtk_tree_path_free (path);
return TRUE;
}
-
+
static gboolean
selector_tree_drag_motion (GtkWidget *widget,
GdkDragContext *context,
@@ -649,21 +649,21 @@ selector_tree_drag_motion (GtkWidget *widget,
GtkTreeModel *model;
GtkTreeIter iter;
GdkDragAction action = GDK_ACTION_DEFAULT;
-
+
if (!gtk_tree_view_get_dest_row_at_pos (GTK_TREE_VIEW (widget),
x, y, &path, &pos))
goto finish;
-
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
-
+
if (!gtk_tree_model_get_iter (model, &iter, path))
goto finish;
-
+
gtk_tree_model_get (model, &iter, 0, &data, -1);
if (E_IS_SOURCE_GROUP (data) || e_source_get_readonly (data))
goto finish;
-
+
gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget), path, GTK_TREE_VIEW_DROP_INTO_OR_BEFORE);
action = context->suggested_action;
if (action == GDK_ACTION_COPY && (context->actions & GDK_ACTION_MOVE))
@@ -688,7 +688,7 @@ update_single_object (ECal *client, icalcomponent *icalcomp, gboolean fail_on_mo
d(g_message("memos-component.c: update_single_object called");)
uid = (char *) icalcomponent_get_uid (icalcomp);
-
+
if (e_cal_get_object (client, uid, NULL, &tmp_icalcomp, NULL)) {
if (fail_on_modify)
return FALSE;
@@ -696,7 +696,7 @@ update_single_object (ECal *client, icalcomponent *icalcomp, gboolean fail_on_mo
return e_cal_modify_object (client, icalcomp, CALOBJ_MOD_ALL, NULL);
}
- return e_cal_create_object (client, icalcomp, &uid, NULL);
+ return e_cal_create_object (client, icalcomp, &uid, NULL);
}
static gboolean
@@ -704,7 +704,7 @@ update_objects (ECal *client, icalcomponent *icalcomp)
{
icalcomponent *subcomp;
icalcomponent_kind kind;
-
+
d(g_message("memos-component.c: update_objects called");)
kind = icalcomponent_isa (icalcomp);
@@ -716,7 +716,7 @@ update_objects (ECal *client, icalcomponent *icalcomp)
subcomp = icalcomponent_get_first_component (icalcomp, ICAL_ANY_COMPONENT);
while (subcomp) {
gboolean success;
-
+
kind = icalcomponent_isa (subcomp);
if (kind == ICAL_VTIMEZONE_COMPONENT) {
icaltimezone *zone;
@@ -741,10 +741,10 @@ update_objects (ECal *client, icalcomponent *icalcomp)
}
static void
-selector_tree_drag_data_received (GtkWidget *widget,
- GdkDragContext *context,
- gint x,
- gint y,
+selector_tree_drag_data_received (GtkWidget *widget,
+ GdkDragContext *context,
+ gint x,
+ gint y,
GtkSelectionData *data,
guint info,
guint time,
@@ -764,13 +764,13 @@ selector_tree_drag_data_received (GtkWidget *widget,
if (!gtk_tree_view_get_dest_row_at_pos (GTK_TREE_VIEW (widget),
x, y, &path, &pos))
goto finish;
-
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
-
+
if (!gtk_tree_model_get_iter (model, &iter, path))
goto finish;
-
-
+
+
gtk_tree_model_get (model, &iter, 0, &source, -1);
if (E_IS_SOURCE_GROUP (source) || e_source_get_readonly (source) || !data->data)
@@ -865,12 +865,12 @@ selector_tree_drag_data_received (GtkWidget *widget,
gtk_tree_path_free (path);
gtk_drag_finish (context, success, success && context->action == GDK_ACTION_MOVE, time);
-}
+}
static void
selector_tree_drag_leave (GtkWidget *widget, GdkDragContext *context, guint time, gpointer data)
{
- gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget),
+ gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget),
NULL, GTK_TREE_VIEW_DROP_BEFORE);
}
@@ -883,33 +883,33 @@ control_activate_cb (BonoboControl *control, gboolean activate, gpointer data)
if (activate) {
BonoboUIComponent *uic;
uic = bonobo_control_get_ui_component (component_view->view_control);
-
+
e_user_creatable_items_handler_activate (component_view->creatable_items_handler, uic);
- }
+ }
}
static void
config_create_ecal_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer data)
-{
+{
MemosComponent *component = data;
MemosComponentPrivate *priv;
-
+
priv = component->priv;
g_object_unref (priv->create_ecal);
priv->create_ecal = NULL;
-
+
priv->notifications = g_list_remove (priv->notifications, GUINT_TO_POINTER (id));
}
static ECal *
-setup_create_ecal (MemosComponent *component, MemosComponentView *component_view)
+setup_create_ecal (MemosComponent *component, MemosComponentView *component_view)
{
MemosComponentPrivate *priv;
ESource *source = NULL;
char *uid;
guint not;
-
+
priv = component->priv;
if (component_view) {
@@ -919,10 +919,10 @@ setup_create_ecal (MemosComponent *component, MemosComponentView *component_view
if (default_ecal)
return default_ecal;
}
-
+
if (priv->create_ecal)
- return priv->create_ecal;
-
+ return priv->create_ecal;
+
/* Get the current primary calendar, or try to set one if it doesn't already exist */
uid = calendar_config_get_primary_memos ();
if (uid) {
@@ -938,15 +938,15 @@ setup_create_ecal (MemosComponent *component, MemosComponentView *component_view
if (source)
priv->create_ecal = auth_new_cal_from_source (source, E_CAL_SOURCE_TYPE_JOURNAL);
}
-
+
if (priv->create_ecal) {
if (!e_cal_open (priv->create_ecal, FALSE, NULL)) {
GtkWidget *dialog;
-
+
dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_MODAL,
GTK_MESSAGE_WARNING, GTK_BUTTONS_OK,
- _("Unable to open the memo list '%s' for creating events and meetings"),
+ _("Unable to open the memo list '%s' for creating events and meetings"),
e_source_peek_name (source));
gtk_dialog_run (GTK_DIALOG (dialog));
gtk_widget_destroy (dialog);
@@ -956,7 +956,7 @@ setup_create_ecal (MemosComponent *component, MemosComponentView *component_view
} else {
GtkWidget *dialog;
-
+
dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_MODAL,
GTK_MESSAGE_WARNING, GTK_BUTTONS_OK,
_("There is no calendar available for creating memos"));
@@ -964,10 +964,10 @@ setup_create_ecal (MemosComponent *component, MemosComponentView *component_view
gtk_widget_destroy (dialog);
return NULL;
- }
+ }
/* Handle the fact it may change on us */
- not = calendar_config_add_notification_primary_memos (config_create_ecal_changed_cb,
+ not = calendar_config_add_notification_primary_memos (config_create_ecal_changed_cb,
component);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
@@ -995,7 +995,7 @@ create_new_memo (MemosComponent *memo_component, gboolean is_assigned, MemosComp
ECalComponent *comp;
MemoEditor *editor;
CompEditorFlags flags = 0;
-
+
ecal = setup_create_ecal (memo_component, component_view);
if (!ecal)
return FALSE;
@@ -1026,18 +1026,18 @@ create_local_item_cb (EUserCreatableItemsHandler *handler, const char *item_type
MemosComponentPrivate *priv;
MemosComponentView *component_view = NULL;
GList *l;
-
+
priv = memos_component->priv;
-
+
for (l = priv->views; l; l = l->next) {
component_view = l->data;
if (component_view->creatable_items_handler == handler)
break;
-
+
component_view = NULL;
}
-
+
if (strcmp (item_type_name, CREATE_MEMO_ID) == 0) {
create_new_memo (memos_component, FALSE, component_view);
} else if (strcmp (item_type_name, CREATE_SHARED_MEMO_ID) == 0) {
@@ -1055,28 +1055,28 @@ create_component_view (MemosComponent *memos_component)
GtkWidget *selector_scrolled_window, *vbox;
GtkWidget *statusbar_widget;
AtkObject *a11y;
-
+
priv = memos_component->priv;
/* Create the calendar component view */
component_view = g_new0 (MemosComponentView, 1);
-
+
/* Add the source lists */
component_view->source_list = g_object_ref (priv->source_list);
-
+
/* Create sidebar selector */
component_view->source_selector = e_source_selector_new (memos_component->priv->source_list);
e_source_selector_set_select_new ((ESourceSelector *)component_view->source_selector, TRUE);
a11y = gtk_widget_get_accessible (GTK_WIDGET (component_view->source_selector));
atk_object_set_name (a11y, _("Memo Source Selector"));
- g_signal_connect (component_view->source_selector, "drag-motion", G_CALLBACK (selector_tree_drag_motion),
+ g_signal_connect (component_view->source_selector, "drag-motion", G_CALLBACK (selector_tree_drag_motion),
memos_component);
- g_signal_connect (component_view->source_selector, "drag-leave", G_CALLBACK (selector_tree_drag_leave),
+ g_signal_connect (component_view->source_selector, "drag-leave", G_CALLBACK (selector_tree_drag_leave),
memos_component);
- g_signal_connect (component_view->source_selector, "drag-drop", G_CALLBACK (selector_tree_drag_drop),
+ g_signal_connect (component_view->source_selector, "drag-drop", G_CALLBACK (selector_tree_drag_drop),
memos_component);
- g_signal_connect (component_view->source_selector, "drag-data-received",
+ g_signal_connect (component_view->source_selector, "drag-data-received",
G_CALLBACK (selector_tree_drag_data_received), memos_component);
gtk_drag_dest_set(component_view->source_selector, GTK_DEST_DEFAULT_ALL, drag_types,
@@ -1116,9 +1116,9 @@ create_component_view (MemosComponent *memos_component)
component_view->model = E_TABLE_MODEL (e_memo_table_get_model (e_memos_get_calendar_table (component_view->memos)));
/* This signal is thrown if backends die - we update the selector */
- g_signal_connect (component_view->memos, "source_added",
+ g_signal_connect (component_view->memos, "source_added",
G_CALLBACK (source_added_cb), component_view);
- g_signal_connect (component_view->memos, "source_removed",
+ g_signal_connect (component_view->memos, "source_removed",
G_CALLBACK (source_removed_cb), component_view);
/* Create status bar */
@@ -1128,9 +1128,9 @@ create_component_view (MemosComponent *memos_component)
gtk_widget_show (statusbar_widget);
component_view->statusbar_control = bonobo_control_new (statusbar_widget);
-
+
e_memo_table_set_activity_handler (e_memos_get_calendar_table (component_view->memos), component_view->activity_handler);
-
+
/* connect after setting the initial selections, or we'll get unwanted calls
to calendar_control_sensitize_calendar_commands */
g_signal_connect (component_view->source_selector, "selection_changed",
@@ -1148,7 +1148,7 @@ create_component_view (MemosComponent *memos_component)
set_info (component_view);
g_signal_connect (component_view->table, "selection_change",
G_CALLBACK (table_selection_change_cb), component_view);
- g_signal_connect (component_view->model, "model_changed",
+ g_signal_connect (component_view->model, "model_changed",
G_CALLBACK (model_changed_cb), component_view);
g_signal_connect (component_view->model, "model_rows_inserted",
G_CALLBACK (model_rows_inserted_cb), component_view);
@@ -1156,7 +1156,7 @@ create_component_view (MemosComponent *memos_component)
G_CALLBACK (model_rows_deleted_cb), component_view);
/* Load the selection from the last run */
- update_selection (component_view);
+ update_selection (component_view);
update_primary_selection (component_view);
return component_view;
@@ -1164,15 +1164,15 @@ create_component_view (MemosComponent *memos_component)
static void
destroy_component_view (MemosComponentView *component_view)
-{
+{
GList *l;
-
+
if (component_view->source_list)
g_object_unref (component_view->source_list);
if (component_view->source_selection)
e_source_selector_free_selection (component_view->source_selection);
-
+
for (l = component_view->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
g_list_free (component_view->notifications);
@@ -1192,12 +1192,12 @@ view_destroyed_cb (gpointer data, GObject *where_the_object_was)
MemosComponent *memos_component = data;
MemosComponentPrivate *priv;
GList *l;
-
+
priv = memos_component->priv;
for (l = priv->views; l; l = l->next) {
MemosComponentView *component_view = l->data;
-
+
if (G_OBJECT (component_view->view_control) == where_the_object_was) {
priv->views = g_list_remove (priv->views, component_view);
destroy_component_view (component_view);
@@ -1216,7 +1216,7 @@ impl_createView (PortableServer_Servant servant,
MemosComponentPrivate *priv;
MemosComponentView *component_view;
EComponentView *ecv;
-
+
priv = component->priv;
/* Create the calendar component view */
@@ -1230,7 +1230,7 @@ impl_createView (PortableServer_Servant servant,
g_object_weak_ref (G_OBJECT (component_view->view_control), view_destroyed_cb, component);
priv->views = g_list_append (priv->views, component_view);
-
+
/* TODO: Make CalendarComponentView just subclass EComponentView */
ecv = e_component_view_new_controls (parent, "memos", component_view->sidebar_control,
component_view->view_control, component_view->statusbar_control);
@@ -1283,7 +1283,7 @@ impl_requestCreateItem (PortableServer_Servant servant,
CORBA_Environment *ev)
{
MemosComponent *memos_component = MEMOS_COMPONENT (bonobo_object_from_servant (servant));
-
+
if (strcmp (item_type_name, CREATE_MEMO_ID) == 0) {
if (!create_new_memo (memos_component, FALSE, NULL))
bonobo_exception_set (ev, ex_GNOME_Evolution_Component_Failed);
@@ -1308,7 +1308,7 @@ impl_dispose (GObject *object)
MemosComponent *memos_component = MEMOS_COMPONENT (object);
MemosComponentPrivate *priv = memos_component->priv;
GList *l;
-
+
if (priv->source_list != NULL) {
g_object_unref (priv->source_list);
priv->source_list = NULL;
@@ -1325,7 +1325,7 @@ impl_dispose (GObject *object)
for (l = priv->views; l; l = l->next) {
MemosComponentView *component_view = l->data;
-
+
g_object_weak_unref (G_OBJECT (component_view->view_control), view_destroyed_cb, memos_component);
}
g_list_free (priv->views);
@@ -1344,10 +1344,10 @@ impl_finalize (GObject *object)
{
MemosComponentPrivate *priv = MEMOS_COMPONENT (object)->priv;
GList *l;
-
+
for (l = priv->views; l; l = l->next) {
MemosComponentView *component_view = l->data;
-
+
destroy_component_view (component_view);
}
g_list_free (priv->views);
@@ -1382,7 +1382,7 @@ memos_component_init (MemosComponent *component, MemosComponentClass *klass)
MemosComponentPrivate *priv;
priv = g_new0 (MemosComponentPrivate, 1);
-
+
priv->base_directory = g_build_filename (g_get_home_dir (), ".evolution", NULL);
priv->config_directory = g_build_filename (g_get_home_dir (),
".evolution", "memos", "config",
@@ -1428,7 +1428,7 @@ memos_component_peek_config_directory (MemosComponent *component)
ESourceList *
memos_component_peek_source_list (MemosComponent *component)
{
- return component->priv->source_list;
+ return component->priv->source_list;
}
BONOBO_TYPE_FUNC_FULL (MemosComponent, GNOME_Evolution_Component, PARENT_TYPE, memos_component)
diff --git a/calendar/gui/migration.c b/calendar/gui/migration.c
index f6b977bbe9..3ed7d9fb5c 100644
--- a/calendar/gui/migration.c
+++ b/calendar/gui/migration.c
@@ -150,16 +150,16 @@ static void
setup_progress_dialog (gboolean tasks)
{
GtkWidget *vbox, *hbox, *w;
-
+
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
gtk_window_set_title ((GtkWindow *) window, _("Migrating..."));
gtk_window_set_modal ((GtkWindow *) window, TRUE);
gtk_container_set_border_width ((GtkContainer *) window, 6);
-
+
vbox = gtk_vbox_new (FALSE, 6);
gtk_widget_show (vbox);
gtk_container_add ((GtkContainer *) window, vbox);
-
+
if (tasks)
w = gtk_label_new (_("The location and hierarchy of the Evolution task "
"folders has changed since Evolution 1.x.\n\nPlease be "
@@ -172,19 +172,19 @@ setup_progress_dialog (gboolean tasks)
gtk_label_set_line_wrap ((GtkLabel *) w, TRUE);
gtk_widget_show (w);
gtk_box_pack_start_defaults ((GtkBox *) vbox, w);
-
+
hbox = gtk_hbox_new (FALSE, 6);
gtk_widget_show (hbox);
gtk_box_pack_start_defaults ((GtkBox *) vbox, hbox);
-
+
label = (GtkLabel *) gtk_label_new ("");
gtk_widget_show ((GtkWidget *) label);
gtk_box_pack_start_defaults ((GtkBox *) hbox, (GtkWidget *) label);
-
+
progress = (GtkProgressBar *) gtk_progress_bar_new ();
gtk_widget_show ((GtkWidget *) progress);
gtk_box_pack_start_defaults ((GtkBox *) hbox, (GtkWidget *) progress);
-
+
gtk_widget_show (window);
}
@@ -198,13 +198,13 @@ static void
dialog_set_folder_name (const char *folder_name)
{
char *text;
-
+
text = g_strdup_printf (_("Migrating `%s':"), folder_name);
gtk_label_set_text (label, text);
g_free (text);
-
+
gtk_progress_bar_set_fraction (progress, 0.0);
-
+
while (gtk_events_pending ())
gtk_main_iteration ();
}
@@ -213,12 +213,12 @@ static void
dialog_set_progress (double percent)
{
char text[5];
-
+
snprintf (text, sizeof (text), "%d%%", (int) (percent * 100.0f));
-
+
gtk_progress_bar_set_fraction (progress, percent);
gtk_progress_bar_set_text (progress, text);
-
+
while (gtk_events_pending ())
gtk_main_iteration ();
}
@@ -290,7 +290,7 @@ migrate_ical (ECal *old_ecal, ECal *new_ecal)
int num_added = 0;
int num_objects;
gboolean retval = TRUE;
-
+
/* both ecals are loaded, start the actual migration */
if (!e_cal_get_object_list (old_ecal, "#t", &objects, NULL))
return FALSE;
@@ -304,7 +304,7 @@ migrate_ical (ECal *old_ecal, ECal *new_ecal)
g_warning ("Migration of object failed: %s", error->message);
retval = FALSE;
}
-
+
g_clear_error (&error);
num_added ++;
@@ -326,7 +326,7 @@ migrate_ical_folder_to_source (char *old_path, ESource *new_source, ECalSourceTy
char *old_uri = g_strdup_printf ("file://%s", old_path);
GError *error = NULL;
gboolean retval = FALSE;
-
+
group = e_source_group_new ("", old_uri);
old_source = e_source_new ("", "");
e_source_group_add_source (group, old_source, -1);
@@ -364,7 +364,7 @@ finish:
g_object_unref (new_ecal);
g_free (old_uri);
- return retval;
+ return retval;
}
static gboolean
@@ -372,7 +372,7 @@ migrate_ical_folder (char *old_path, ESourceGroup *dest_group, char *source_name
{
ESource *new_source;
gboolean retval;
-
+
new_source = e_source_new (source_name, source_name);
e_source_set_relative_uri (new_source, e_source_peek_uid (new_source));
e_source_group_add_source (dest_group, new_source, -1);
@@ -397,7 +397,7 @@ create_calendar_contact_source (ESourceList *source_list)
{
ESourceGroup *group;
ESource *source;
-
+
/* Create the contacts group */
group = e_source_group_new (_("Contacts"), CONTACTS_BASE_URI);
e_source_list_add_group (source_list, group, -1);
@@ -490,7 +490,7 @@ create_calendar_sources (CalendarComponent *component,
/* Create the default Person calendar */
ESource *source = e_source_new (_("Personal"), PERSONAL_RELATIVE_URI);
e_source_group_add_source (*on_this_computer, source, -1);
-
+
if (!primary_calendar && !calendar_config_get_calendars_selected ()) {
GSList selected;
@@ -501,7 +501,7 @@ create_calendar_sources (CalendarComponent *component,
calendar_config_set_calendars_selected (&selected);
}
- g_free (primary_calendar);
+ g_free (primary_calendar);
e_source_set_color_spec (source, "#BECEDD");
*personal_source = source;
}
@@ -519,7 +519,7 @@ create_calendar_sources (CalendarComponent *component,
*contacts = group;
}
-
+
g_free (base_uri_proto);
g_free (base_uri);
}
@@ -538,7 +538,7 @@ create_task_sources (TasksComponent *component,
*on_this_computer = NULL;
*on_the_web = NULL;
*personal_source = NULL;
-
+
base_uri = g_build_filename (tasks_component_peek_base_directory (component),
"tasks", "local", NULL);
@@ -622,7 +622,7 @@ static void
migrate_pilot_db_key (const char *key, gpointer user_data)
{
EXmlHash *xmlhash = user_data;
-
+
e_xmlhash_add (xmlhash, key, "");
}
@@ -634,16 +634,16 @@ migrate_pilot_data (const char *component, const char *conduit, const char *old_
const char *ext;
char *filename;
GDir *dir;
-
+
if (!(dir = g_dir_open (old_path, 0, NULL)))
return;
-
+
map = g_alloca (12 + strlen (conduit));
sprintf (map, "pilot-map-%s-", conduit);
-
+
changelog = g_alloca (24 + strlen (conduit));
sprintf (changelog, "pilot-sync-evolution-%s-", conduit);
-
+
while ((dent = g_dir_read_name (dir))) {
if (!strncmp (dent, map, strlen (map)) &&
((ext = strrchr (dent, '.')) && !strcmp (ext, ".xml"))) {
@@ -652,13 +652,13 @@ migrate_pilot_data (const char *component, const char *conduit, const char *old_
size_t nread, nwritten;
int fd0, fd1;
ssize_t n;
-
+
filename = g_build_filename (old_path, dent, NULL);
if ((fd0 = g_open (filename, O_RDONLY|O_BINARY, 0)) == -1) {
g_free (filename);
continue;
}
-
+
g_free (filename);
filename = g_build_filename (new_path, dent, NULL);
if ((fd1 = g_open (filename, O_WRONLY | O_CREAT | O_TRUNC | O_BINARY, 0666)) == -1) {
@@ -666,38 +666,38 @@ migrate_pilot_data (const char *component, const char *conduit, const char *old_
close (fd0);
continue;
}
-
+
do {
do {
n = read (fd0, inbuf, sizeof (inbuf));
} while (n == -1 && errno == EINTR);
-
+
if (n < 1)
break;
-
+
nread = n;
nwritten = 0;
do {
do {
n = write (fd1, inbuf + nwritten, nread - nwritten);
} while (n == -1 && errno == EINTR);
-
+
if (n > 0)
nwritten += n;
} while (nwritten < nread && n != -1);
-
+
if (n == -1)
break;
} while (1);
-
+
if (n != -1)
n = fsync (fd1);
-
+
if (n == -1) {
g_warning ("Failed to migrate %s: %s", dent, strerror (errno));
g_unlink (filename);
}
-
+
close (fd0);
close (fd1);
g_free (filename);
@@ -707,31 +707,31 @@ migrate_pilot_data (const char *component, const char *conduit, const char *old_
EXmlHash *xmlhash;
EDbHash *dbhash;
struct stat st;
-
+
filename = g_build_filename (old_path, dent, NULL);
if (g_stat (filename, &st) == -1) {
g_free (filename);
continue;
}
-
+
dbhash = e_dbhash_new (filename);
g_free (filename);
-
+
filename = g_strdup_printf ("%s/%s.ics-%s", new_path, component, dent);
if (g_stat (filename, &st) != -1)
g_unlink (filename);
xmlhash = e_xmlhash_new (filename);
g_free (filename);
-
+
e_dbhash_foreach_key (dbhash, migrate_pilot_db_key, xmlhash);
-
+
e_dbhash_destroy (dbhash);
-
+
e_xmlhash_write (xmlhash);
e_xmlhash_destroy (xmlhash);
}
}
-
+
g_dir_close (dir);
}
@@ -758,21 +758,21 @@ migrate_calendars (CalendarComponent *component, int major, int minor, int revis
struct stat st;
conf_file = g_build_filename (g_get_home_dir (), "evolution", "config.xmldb", NULL);
- if (lstat (conf_file, &st) == 0 && S_ISREG (st.st_mode))
+ if (lstat (conf_file, &st) == 0 && S_ISREG (st.st_mode))
config_doc = xmlParseFile (conf_file);
g_free (conf_file);
-
+
if (config_doc && minor <= 2) {
- GConfClient *gconf;
+ GConfClient *gconf;
int res = 0;
-
+
/* move bonobo config to gconf */
gconf = gconf_client_get_default ();
-
+
res = e_bconf_import (gconf, config_doc, calendar_remap_list);
-
+
g_object_unref (gconf);
-
+
xmlFreeDoc(config_doc);
if (res != 0) {
@@ -798,7 +798,7 @@ migrate_calendars (CalendarComponent *component, int major, int minor, int revis
for (l = migration_dirs; l; l = l->next) {
char *source_name;
-
+
if (personal_source && !strcmp ((char*)l->data, local_cal_folder))
continue;
@@ -810,17 +810,17 @@ migrate_calendars (CalendarComponent *component, int major, int minor, int revis
g_free(source_name);
goto fail;
}
-
+
g_free (source_name);
}
-
+
g_free (local_cal_folder);
dialog_close ();
}
if (minor <= 4 || (minor == 5 && revision < 5)) {
- GConfClient *gconf;
+ GConfClient *gconf;
GConfValue *gconf_val;
int i;
const char *keys[] = {
@@ -830,9 +830,9 @@ migrate_calendars (CalendarComponent *component, int major, int minor, int revis
CALENDAR_CONFIG_MONTH_VPANE_POS,
NULL
};
-
+
gconf = gconf_client_get_default ();
-
+
for (i = 0; keys[i]; i++) {
gconf_val = gconf_client_get (gconf, keys[i], NULL);
if (gconf_val) {
@@ -841,13 +841,13 @@ migrate_calendars (CalendarComponent *component, int major, int minor, int revis
gconf_value_free (gconf_val);
}
}
-
+
g_object_unref (gconf);
}
-
+
if (minor < 5 || (minor == 5 && revision <= 10)) {
char *old_path, *new_path;
-
+
old_path = g_build_filename (g_get_home_dir (), "evolution", "local", "Calendar", NULL);
new_path = g_build_filename (calendar_component_peek_base_directory (component),
"calendar", "local", "system", NULL);
@@ -883,7 +883,7 @@ migrate_calendars (CalendarComponent *component, int major, int minor, int revis
/** @Event: component.migration
* @Title: Migration step in component initialization
* @Target: ECalEventTargetComponent
- *
+ *
* component.migration is emitted during the calendar component
* initialization process. This allows new calendar backend types
* to be distributed as an e-d-s backend and a plugin without
@@ -920,7 +920,7 @@ migrate_tasks (TasksComponent *component, int major, int minor, int revision, GE
creates the groups/sources or it finds the necessary
groups/sources. */
create_task_sources (component, tasks_component_peek_source_list (component), &on_this_computer, &on_the_web, &personal_source);
-
+
#ifndef G_OS_WIN32
if (major == 1) {
xmlDocPtr config_doc = NULL;
@@ -930,18 +930,18 @@ migrate_tasks (TasksComponent *component, int major, int minor, int revision, GE
if (g_file_test (conf_file, G_FILE_TEST_IS_REGULAR))
config_doc = e_xml_parse_file (conf_file);
g_free (conf_file);
-
+
if (config_doc && minor <= 2) {
- GConfClient *gconf;
+ GConfClient *gconf;
int res = 0;
-
+
/* move bonobo config to gconf */
gconf = gconf_client_get_default ();
-
+
res = e_bconf_import (gconf, config_doc, task_remap_list);
-
+
g_object_unref (gconf);
-
+
xmlFreeDoc(config_doc);
if (res != 0) {
@@ -953,9 +953,9 @@ migrate_tasks (TasksComponent *component, int major, int minor, int revision, GE
if (minor <= 4) {
GSList *migration_dirs, *l;
char *path, *local_task_folder;
-
+
setup_progress_dialog (TRUE);
-
+
path = g_build_filename (g_get_home_dir (), "evolution", "local", NULL);
migration_dirs = e_folder_map_local_folders (path, "tasks");
local_task_folder = g_build_filename (path, "Tasks", NULL);
@@ -966,7 +966,7 @@ migrate_tasks (TasksComponent *component, int major, int minor, int revision, GE
for (l = migration_dirs; l; l = l->next) {
char *source_name;
-
+
if (personal_source && !strcmp ((char*)l->data, local_task_folder))
continue;
@@ -978,18 +978,18 @@ migrate_tasks (TasksComponent *component, int major, int minor, int revision, GE
g_free(source_name);
goto fail;
}
-
+
g_free (source_name);
}
-
+
g_free (local_task_folder);
dialog_close ();
}
-
+
if (minor < 5 || (minor == 5 && revision <= 10)) {
char *old_path, *new_path;
-
+
old_path = g_build_filename (g_get_home_dir (), "evolution", "local", "Tasks", NULL);
new_path = g_build_filename (tasks_component_peek_base_directory (component),
"tasks", "local", "system", NULL);
@@ -1027,14 +1027,14 @@ fail:
g_object_unref (on_the_web);
if (personal_source)
g_object_unref (personal_source);
-
+
return retval;
}
/********************************************************************************************************
*
* MEMOS
- *
+ *
********************************************************************************************************/
static void
@@ -1051,7 +1051,7 @@ create_memo_sources (MemosComponent *component,
*on_this_computer = NULL;
*on_the_web = NULL;
*personal_source = NULL;
-
+
base_uri = g_build_filename (memos_component_peek_base_directory (component),
"memos", "local", NULL);
@@ -1150,8 +1150,8 @@ add_gw_esource (ESourceList *source_list, const char *group_name, const char *s
const char * use_ssl;
const char *poa_address;
const char *offline_sync;
-
-
+
+
poa_address = url->host;
if (!poa_address || strlen (poa_address) ==0)
return;
@@ -1167,7 +1167,7 @@ add_gw_esource (ESourceList *source_list, const char *group_name, const char *s
if (!e_source_list_add_group (source_list, group, -1))
return;
relative_uri = g_strdup_printf ("%s@%s/", url->user, poa_address);
-
+
source = e_source_new (source_name, relative_uri);
e_source_set_property (source, "auth", "1");
e_source_set_property (source, "username", url->user);
@@ -1185,7 +1185,7 @@ add_gw_esource (ESourceList *source_list, const char *group_name, const char *s
temp = ids;
for (; temp != NULL; temp = g_slist_next (temp))
g_free (temp->data);
-
+
g_slist_free (ids);
g_object_unref (source);
g_object_unref (group);
@@ -1212,7 +1212,7 @@ migrate_memos (MemosComponent *component, int major, int minor, int revision, st
if (major == 2 && minor < 8) {
EAccountList *al;
EAccount *a;
- CamelURL *url;
+ CamelURL *url;
EIterator *it;
GConfClient *gconf_client = gconf_client_get_default ();
al = e_account_list_new (gconf_client);
@@ -1220,7 +1220,7 @@ migrate_memos (MemosComponent *component, int major, int minor, int revision, st
e_iterator_is_valid(it);
e_iterator_next(it)) {
a = (EAccount *) e_iterator_get(it);
- if (!a->enabled || !is_groupwise_account (a))
+ if (!a->enabled || !is_groupwise_account (a))
continue;
url = camel_url_new (a->source->url, NULL);
add_gw_esource (source_list, a->name, _("Notes"), url, gconf_client);
@@ -1239,6 +1239,6 @@ migrate_memos (MemosComponent *component, int major, int minor, int revision, st
g_object_unref (on_the_web);
if (personal_source)
g_object_unref (personal_source);
-
+
return retval;
}
diff --git a/calendar/gui/misc.c b/calendar/gui/misc.c
index c67e37c2ea..f5ce590ea7 100644
--- a/calendar/gui/misc.c
+++ b/calendar/gui/misc.c
@@ -35,10 +35,10 @@
/**
* string_is_empty:
* @value: A string.
- *
+ *
* Returns whether a string is NULL, the empty string, or completely made up of
* whitespace characters.
- *
+ *
* Return value: TRUE if the string is empty, FALSE otherwise.
**/
gboolean
diff --git a/calendar/gui/print.c b/calendar/gui/print.c
index 80b7e42355..e56205c036 100644
--- a/calendar/gui/print.c
+++ b/calendar/gui/print.c
@@ -67,13 +67,13 @@ struct PrintCompItem {
};
struct PrintCalItem {
- GnomeCalendar *gcal;
+ GnomeCalendar *gcal;
time_t start;
};
static double
evo_calendar_print_renderer_get_width (GtkPrintContext *context,
- PangoFontDescription *font,
+ PangoFontDescription *font,
const char *text)
{
PangoLayout *layout;
@@ -315,16 +315,16 @@ print_border_with_triangles (GtkPrintContext *pc,
/* Fill in the interior of the rectangle, if desired. */
if (red >= -EPSILON && green >= -EPSILON && blue >= -EPSILON) {
-
+
cairo_move_to (cr, x1, y1);
-
+
if (left_triangle_width > 0.0)
cairo_line_to (cr, x1 - left_triangle_width,
(y1 + y2) / 2);
cairo_line_to (cr, x1, y2);
cairo_line_to (cr, x2, y2);
-
+
if (right_triangle_width > 0.0)
cairo_line_to (cr, x2 + right_triangle_width, (y1 + y2) / 2);
@@ -357,7 +357,7 @@ print_border_with_triangles (GtkPrintContext *pc,
cairo_close_path (cr);
cairo_set_source_rgb (cr, 0, 0, 0);
cairo_set_line_width (cr, line_width);
- cairo_stroke (cr);
+ cairo_stroke (cr);
}
cairo_restore (cr);
@@ -435,7 +435,7 @@ print_text (GtkPrintContext *context, PangoFontDescription *desc,
cairo_save (cr);
/* Set a clipping rectangle. */
- cairo_move_to (cr, x1, y1);
+ cairo_move_to (cr, x1, y1);
cairo_rectangle (cr, x1, y1, x2, y2);
cairo_clip (cr);
@@ -560,14 +560,14 @@ format_date(time_t time, int flags, char *buffer, int bufflen)
return buffer;
}
-static gboolean
+static gboolean
instance_cb (ECalComponent *comp, time_t instance_start, time_t instance_end, gpointer data)
{
-
+
gboolean *found = ((ECalModelGenerateInstancesData *) data)->cb_data;
-
+
*found = TRUE;
-
+
return FALSE;
}
@@ -680,19 +680,19 @@ print_month_small (GtkPrintContext *context, GnomeCalendar *gcal, time_t month,
sprintf (buf, "%d", day);
/* this is a slow messy way to do this ... but easy ... */
- e_cal_model_generate_instances (gnome_calendar_get_calendar_model (gcal), now,
+ e_cal_model_generate_instances (gnome_calendar_get_calendar_model (gcal), now,
time_day_end_with_zone (now, zone),
instance_cb, &found);
-
+
font = found ? font_bold : font_normal;
next = time_add_day_with_zone (now, 1, zone);
- if ((now >= greystart && now < greyend)
+ if ((now >= greystart && now < greyend)
|| (greystart >= now && greystart < next)) {
print_border (context,
cell_left, cell_right,
cell_top, cell_bottom,
- -1.0, 0.75);
+ -1.0, 0.75);
}
print_text (context, font, buf, PANGO_ALIGN_RIGHT,
cell_left, text_right,
@@ -731,8 +731,8 @@ bound_text (GtkPrintContext *context,
/* Set a clipping rectangle. */
cairo_move_to (cr, x1, y1);
cairo_rectangle (cr, x1, y1, x2, y2);
- cairo_clip (cr);
- cairo_new_path (cr);
+ cairo_clip (cr);
+ cairo_new_path (cr);
cairo_move_to (cr, x1, y1);
pango_cairo_show_layout (cr, layout);
@@ -762,7 +762,7 @@ print_day_background (GtkPrintContext *context, GnomeCalendar *gcal,
int i, hour, row;
double hour_minute_x;
cairo_t *cr;
-
+
/* Fill the time column in light-gray. */
print_border (context, left, left + width, top, bottom, -1.0, 0.9);
@@ -770,7 +770,7 @@ print_day_background (GtkPrintContext *context, GnomeCalendar *gcal,
cr = gtk_print_context_get_cairo_context (context);
cairo_set_source_rgb (cr, 0, 0, 0);
- print_border (context, left, right, top, bottom, 1.0, -1.0);
+ print_border (context, left, right, top, bottom, 1.0, -1.0);
/* Draw the vertical line on the right of the time column. */
cr = gtk_print_context_get_cairo_context (context);
@@ -778,7 +778,7 @@ print_day_background (GtkPrintContext *context, GnomeCalendar *gcal,
cairo_move_to (cr, left + width, bottom);
cairo_line_to (cr, left + width, top);
cairo_stroke (cr);
-
+
/* Calculate the row height. */
if (top > bottom)
yinc = (top - bottom) / (pdi->end_hour - pdi->start_hour);
@@ -801,7 +801,7 @@ print_day_background (GtkPrintContext *context, GnomeCalendar *gcal,
row = 0;
hour_minute_x = left + width * 0.58;
for (i = pdi->start_hour; i < pdi->end_hour; i++) {
- y = top + yinc * (row + 1) ;
+ y = top + yinc * (row + 1) ;
cr = gtk_print_context_get_cairo_context (context);
cairo_set_source_rgb (cr, 0, 0, 0);
@@ -827,7 +827,7 @@ print_day_background (GtkPrintContext *context, GnomeCalendar *gcal,
print_text (context, font_minute, minute, PANGO_ALIGN_LEFT,
hour_minute_x, left + width - 3,
y - yinc + yinc / 2, y - yinc + yinc / 2 + minute_font_size);
-
+
/* Draw the horizontal line between hours, across the entire
width of the day view. */
cr = gtk_print_context_get_cairo_context (context);
@@ -835,7 +835,7 @@ print_day_background (GtkPrintContext *context, GnomeCalendar *gcal,
cairo_line_to (cr, right, y);
cairo_set_line_width (cr, 1);
cairo_stroke (cr);
-
+
/* Draw the horizontal line for the 1/2-hours, across the
entire width except for part of the time column. */
cairo_move_to (cr, left + width * 0.6, y - yinc / 2);
@@ -1073,7 +1073,7 @@ print_day_event (GtkPrintContext *context, PangoFontDescription *font,
row_height = (bottom - top) / pdi->rows;
y1 = top + start_row * row_height;
y2 = top + (end_row + 1) * row_height;
-#if 0
+#if 0
g_print ("Event: %g,%g %g,%g\n row_height: %g start_row: %i top: %g rows: %i\n",
x1, y1, x2, y2, row_height, start_row, top, pdi->rows);
#endif
@@ -1174,7 +1174,7 @@ print_day_details (GtkPrintContext *context, GnomeCalendar *gcal, time_t whence,
if (pdi.events[0]->len > 0) {
struct icaltimetype tt;
- event = &g_array_index (pdi.events[0], EDayViewEvent, 0);
+ event = &g_array_index (pdi.events[0], EDayViewEvent, 0);
tt = icaltime_from_timet_with_zone (event->start, FALSE, zone);
if (tt.hour < pdi.start_hour)
pdi.start_hour = tt.hour;
@@ -1191,7 +1191,7 @@ print_day_details (GtkPrintContext *context, GnomeCalendar *gcal, time_t whence,
pdi.rows = (pdi.end_hour - pdi.start_hour) * 2;
}
-
+
/* Lay them out the long events, across the top of the page. */
e_day_view_layout_long_events (pdi.long_events, pdi.days_shown,
pdi.day_starts, &rows_in_top_display);
@@ -1203,7 +1203,7 @@ print_day_details (GtkPrintContext *context, GnomeCalendar *gcal, time_t whence,
print_day_long_event (context, font, left, right, top, bottom,
DAY_VIEW_ROW_HEIGHT, event, &pdi, model);
}
-
+
/* We always leave space for DAY_VIEW_MIN_ROWS_IN_TOP_DISPLAY in the
top display, but we may have more rows than that, in which case
the main display area will be compressed. */
@@ -1216,18 +1216,18 @@ print_day_details (GtkPrintContext *context, GnomeCalendar *gcal, time_t whence,
cairo_set_source_rgb (cr, 0, 0, 0);
print_border (context, left, right,
top, top + rows_in_top_display * DAY_VIEW_ROW_HEIGHT - 4,
- 1.0, -1.0);
-
+ 1.0, -1.0);
+
/* Adjust the area containing the main display. */
top += rows_in_top_display * DAY_VIEW_ROW_HEIGHT - 2;
-
+
/* Draw the borders, lines, and times down the left. */
print_day_background (context, gcal, whence, &pdi,
left, right, top, bottom);
/* Now adjust to get rid of the time column. */
left += DAY_VIEW_TIME_COLUMN_WIDTH;
-
-
+
+
/* lay out the short events, within the day. */
e_day_view_layout_day_events (pdi.events[0], DAY_VIEW_ROWS,
DAY_VIEW_MINS_PER_ROW, pdi.cols_per_row);
@@ -1245,7 +1245,7 @@ print_day_details (GtkPrintContext *context, GnomeCalendar *gcal, time_t whence,
print_day_event (context, font, left, right, top, bottom,
event, &pdi, model);
}
-
+
/* Free everything. */
free_event_array (pdi.long_events);
pango_font_description_free (font);
@@ -1362,7 +1362,7 @@ print_week_day_event (GtkPrintContext *context, PangoFontDescription *font,
buffer, sizeof (buffer));
print_rectangle (context, x1, y1, (x2 + 6) - x1, (y2 + 4) - y1, red, green, blue);
x1 += print_text_size (context, buffer, PANGO_ALIGN_LEFT, x1, x2, y1, y2 + 3 ) + 4;
- print_text_size (context, text, PANGO_ALIGN_LEFT, x1, x2, y1, y2 + 3);
+ print_text_size (context, text, PANGO_ALIGN_LEFT, x1, x2, y1, y2 + 3);
if (psi->weeks_shown <= 2) {
date_tm.tm_hour = event->end_minute / 60;
@@ -1371,11 +1371,11 @@ print_week_day_event (GtkPrintContext *context, PangoFontDescription *font,
e_time_format_time (&date_tm, psi->use_24_hour_format, FALSE,
buffer, sizeof (buffer));
- print_rectangle (context, x1, y1, (x2 + 6) - x1, (y2 + 4) - y1, red, green, blue);
+ print_rectangle (context, x1, y1, (x2 + 6) - x1, (y2 + 4) - y1, red, green, blue);
x1 += print_text_size (context, buffer, PANGO_ALIGN_LEFT, x1, x2, y1, y2 + 3) + 4;
}
- print_text_size (context, text, PANGO_ALIGN_LEFT, x1, x2, y1, y2 + 3);
+ print_text_size (context, text, PANGO_ALIGN_LEFT, x1, x2, y1, y2 + 3);
}
@@ -1450,12 +1450,12 @@ print_week_event (GtkPrintContext *context, PangoFontDescription *font,
psi->day_starts)) {
print_week_day_event (context, font, psi,
x1, x2, y1, y2,
- event, span, text, red, green, blue);
+ event, span, text, red, green, blue);
} else {
print_week_long_event (context, font, psi,
x1, x2, y1, y2,
event, span, text, red, green, blue);
- }
+ }
} else {
cairo_t *cr = gtk_print_context_get_cairo_context (context);
@@ -1568,9 +1568,9 @@ print_week_view_background (GtkPrintContext *context,
}
e_utf8_strftime (buffer, sizeof (buffer), format_string, &tm);
-
+
print_text_size (context, buffer, PANGO_ALIGN_RIGHT,
- x1, x2 - 4, y1 + 2, y1 + 2 + font_size);
+ x1, x2 - 4, y1 + 2, y1 + 2 + font_size);
}
}
@@ -1686,7 +1686,7 @@ print_week_summary (GtkPrintContext *context, GnomeCalendar *gcal,
cell_width = (right - left) / 2;
cell_height = (bottom - top) / 6;
}
-
+
/* Calculate the row height, using the normal font and with room for
space or a rectangle around it. */
@@ -1963,31 +1963,31 @@ print_day_view (GtkPrintContext *context, GnomeCalendar *gcal, time_t date)
print_day_details (context, gcal, date,
0.0, todo - 2.0, HEADER_HEIGHT,
height);
-
+
/* Print the TaskPad down the right. */
print_todo_details (context, gcal, 0, INT_MAX,
todo, width, HEADER_HEIGHT,
height);
-
+
/* Print the filled border around the header. */
print_border (context, 0.0, width,
0.0, HEADER_HEIGHT + 2.0, 1.0, 0.9);
-
+
/* Print the 2 mini calendar-months. */
l = width - SMALL_MONTH_PAD - SMALL_MONTH_WIDTH * 2 - SMALL_MONTH_SPACING;
print_month_small (context, gcal, date,
l, 4, l + SMALL_MONTH_WIDTH, HEADER_HEIGHT + 4,
DATE_MONTH | DATE_YEAR, date, date, FALSE);
-
+
l += SMALL_MONTH_SPACING + SMALL_MONTH_WIDTH;
print_month_small (context, gcal,
time_add_month_with_zone (date, 1, zone),
l, 4, l + SMALL_MONTH_WIDTH, HEADER_HEIGHT + 4,
DATE_MONTH | DATE_YEAR, 0, 0, FALSE);
-
-
+
+
/* Print the date, e.g. '8th May, 2001'. */
format_date (date, DATE_DAY | DATE_MONTH | DATE_YEAR,
buf, 100);
@@ -2042,8 +2042,8 @@ print_week_view (GtkPrintContext *context, GnomeCalendar *gcal, time_t date)
WEEK_NORMAL_FONT_SIZE,
0.0, width,
HEADER_HEIGHT + 20, height);
-
-
+
+
/* Print the border around the main view. */
print_border (context, 0.0, width, HEADER_HEIGHT ,
height, 1.0, -1.0);
@@ -2135,7 +2135,7 @@ print_year_view (GtkPrintContext *context, GnomeCalendar *gcal, time_t date)
width = gtk_page_setup_get_page_width (setup, GTK_UNIT_POINTS);
height = gtk_page_setup_get_page_height (setup, GTK_UNIT_POINTS);
- cr = gtk_print_context_get_cairo_context (context);
+ cr = gtk_print_context_get_cairo_context (context);
cairo_show_page (cr);
print_year_summary (context, gcal, date, 0.0,
@@ -2182,7 +2182,7 @@ get_zone_from_tzid (ECal *client, const char *tzid)
the builtin timezone with the TZID first. */
zone = icaltimezone_get_builtin_timezone_from_tzid (tzid);
if (!zone) {
- if (!e_cal_get_timezone (client, tzid, &zone, NULL))
+ if (!e_cal_get_timezone (client, tzid, &zone, NULL))
/* FIXME: Handle error better. */
g_warning ("Couldn't get timezone from server: %s",
tzid ? tzid : "");
@@ -2283,7 +2283,7 @@ print_calendar_draw_page (GtkPrintOperation *operation,
break;
default:
g_return_if_reached ();
- }
+ }
}
void
@@ -2338,9 +2338,9 @@ print_comp_draw_page (GtkPrintOperation *operation,
width = gtk_page_setup_get_page_width (setup, GTK_UNIT_POINTS);
height = gtk_page_setup_get_page_height (setup, GTK_UNIT_POINTS);
- /* PrintCompItem structure contains elements to be used
+ /* PrintCompItem structure contains elements to be used
* with the Print Context , obtained in comp_draw_page
- */
+ */
client = pci->client;
comp = pci->comp;
@@ -2357,7 +2357,7 @@ print_comp_draw_page (GtkPrintOperation *operation,
return;
cr = gtk_print_context_get_cairo_context (context);
-
+
/* Print the title in a box at the top of the page. */
font = get_font_for_size (18, PANGO_WEIGHT_BOLD);
header_size = 40;
@@ -2368,14 +2368,14 @@ print_comp_draw_page (GtkPrintOperation *operation,
pango_font_description_free (font);
top = header_size + 30;
-
+
/* Summary */
font = get_font_for_size (18, PANGO_WEIGHT_BOLD);
e_cal_component_get_summary (comp, &text);
summary_string = g_strdup_printf (_("Summary: %s"), text.value);
top = bound_text (context, font, summary_string, 0.0, top, width,
height);
-
+
g_free (summary_string);
/* Location */
@@ -2388,12 +2388,12 @@ print_comp_draw_page (GtkPrintOperation *operation,
g_free (location_string);
}
pango_font_description_free (font);
-
+
/* Date information */
print_date_label (context, comp, client, 0.0, width, top + 3, top + 15);
top += 20;
font = get_font_for_size (12, PANGO_WEIGHT_NORMAL);
-
+
/* For a VTODO we print the Status, Priority, % Complete and URL. */
if (vtype == E_CAL_COMPONENT_TODO) {
icalproperty_status status;
@@ -2401,7 +2401,7 @@ print_comp_draw_page (GtkPrintOperation *operation,
int *percent;
int *priority;
const char *url;
-
+
/* Status */
e_cal_component_get_status (comp, &status);
if (status != ICAL_STATUS_NONE) {
@@ -2473,7 +2473,7 @@ print_comp_draw_page (GtkPrintOperation *operation,
g_free (url_string);
}
}
-
+
/* Categories */
e_cal_component_get_categories (comp, &categories);
if (categories && categories[0]) {
@@ -2484,7 +2484,7 @@ print_comp_draw_page (GtkPrintOperation *operation,
top += get_font_size (font) - 6 ;
g_free (categories_string);
}
-
+
/* Contacts */
e_cal_component_get_contact_list (comp, &contact_list);
if (contact_list) {
@@ -2513,7 +2513,7 @@ print_comp_draw_page (GtkPrintOperation *operation,
top = 10; //FIXME
cairo_show_page (cr);
}
- if (text->value != NULL)
+ if (text->value != NULL)
top = bound_text (context, font, text->value, 0.0, top + 3, width, height) + 30;
}
diff --git a/calendar/gui/tag-calendar.c b/calendar/gui/tag-calendar.c
index b21e7a7ed1..29b4a491ae 100644
--- a/calendar/gui/tag-calendar.c
+++ b/calendar/gui/tag-calendar.c
@@ -76,7 +76,7 @@ prepare_tag (ECalendar *ecal, struct calendar_tag_closure *c, icaltimezone *zone
} else {
c->zone = calendar_config_get_icaltimezone ();
}
-
+
c->start_time = icaltime_as_timet_with_zone (start_tt, c->zone);
c->end_time = icaltime_as_timet_with_zone (end_tt, c->zone);
@@ -118,7 +118,7 @@ tag_calendar_cb (ECalComponent *comp,
* tag_calendar_by_client:
* @ecal: Calendar widget to tag.
* @client: A calendar client object.
- *
+ *
* Tags an #ECalendar widget with the events that occur in its current time
* range. The occurrences are extracted from the specified calendar @client.
**/
@@ -162,7 +162,7 @@ resolve_tzid_cb (const char *tzid, gpointer data)
g_return_val_if_fail (data != NULL, NULL);
g_return_val_if_fail (E_IS_CAL (data), NULL);
-
+
client = E_CAL (data);
/* Try to find the builtin timezone first. */
@@ -181,7 +181,7 @@ resolve_tzid_cb (const char *tzid, gpointer data)
* @ecal: Calendar widget to tag.
* @comp: A calendar component object.
* @clear_first: Whether the #ECalendar should be cleared of any marks first.
- *
+ *
* Tags an #ECalendar widget with any occurrences of a specific calendar
* component that occur within the calendar's current time range.
* Note that TRANSPARENT events are also tagged here.
@@ -191,7 +191,7 @@ resolve_tzid_cb (const char *tzid, gpointer data)
* have been added to the calendar on the server yet.
**/
void
-tag_calendar_by_comp (ECalendar *ecal, ECalComponent *comp, ECal *client, icaltimezone *display_zone,
+tag_calendar_by_comp (ECalendar *ecal, ECalComponent *comp, ECal *client, icaltimezone *display_zone,
gboolean clear_first, gboolean comp_is_on_server)
{
struct calendar_tag_closure c;
diff --git a/calendar/gui/tasks-component.c b/calendar/gui/tasks-component.c
index 2f8c563aa7..da1c0e61eb 100644
--- a/calendar/gui/tasks-component.c
+++ b/calendar/gui/tasks-component.c
@@ -80,19 +80,19 @@ static BonoboObjectClass *parent_class = NULL;
extern ECompEditorRegistry *comp_editor_registry;
-typedef struct
+typedef struct
{
ESourceList *source_list;
-
+
GSList *source_selection;
-
+
ETasks *tasks;
ETable *table;
ETableModel *model;
EInfoLabel *info_label;
GtkWidget *source_selector;
-
+
BonoboControl *view_control;
BonoboControl *sidebar_control;
BonoboControl *statusbar_control;
@@ -112,9 +112,9 @@ struct _TasksComponentPrivate {
GSList *source_selection;
GList *views;
-
+
ECal *create_ecal;
-
+
GList *notifications;
};
@@ -153,7 +153,7 @@ ensure_sources (TasksComponent *component)
group = E_SOURCE_GROUP (g->data);
- /* compare only file:// part. If user home dir name changes we do not want to create
+ /* compare only file:// part. If user home dir name changes we do not want to create
one more group */
if (!on_this_computer && !strncmp (base_uri_proto, e_source_group_peek_base_uri (group), 7))
@@ -245,10 +245,10 @@ static gboolean
is_in_selection (GSList *selection, ESource *source)
{
GSList *l;
-
+
for (l = selection; l; l = l->next) {
ESource *selected_source = l->data;
-
+
if (!strcmp (e_source_peek_uid (selected_source), e_source_peek_uid (source)))
return TRUE;
}
@@ -260,10 +260,10 @@ static gboolean
is_in_uids (GSList *uids, ESource *source)
{
GSList *l;
-
+
for (l = uids; l; l = l->next) {
const char *uid = l->data;
-
+
if (!strcmp (uid, e_source_peek_uid (source)))
return TRUE;
}
@@ -275,19 +275,19 @@ static void
update_uris_for_selection (TasksComponentView *component_view)
{
GSList *selection, *l, *uids_selected = NULL;
-
+
selection = e_source_selector_get_selection (E_SOURCE_SELECTOR (component_view->source_selector));
-
+
for (l = component_view->source_selection; l; l = l->next) {
ESource *old_selected_source = l->data;
if (!is_in_selection (selection, old_selected_source))
e_tasks_remove_todo_source (component_view->tasks, old_selected_source);
- }
-
+ }
+
for (l = selection; l; l = l->next) {
ESource *selected_source = l->data;
-
+
e_tasks_add_todo_source (component_view->tasks, selected_source);
uids_selected = g_slist_append (uids_selected, (char *)e_source_peek_uid (selected_source));
}
@@ -318,7 +318,7 @@ update_uri_for_primary_selection (TasksComponentView *component_view)
etable = e_calendar_table_get_table (cal_table);
tasks_control_sensitize_commands (component_view->view_control, component_view->tasks, e_table_selected_count (etable));
-
+
/* Save the selection for next time we start up */
calendar_config_set_primary_tasks (e_source_peek_uid (source));
}
@@ -337,10 +337,10 @@ update_selection (TasksComponentView *component_view)
for (l = selection; l; l = l->next) {
ESource *source = l->data;
- if (!is_in_uids (uids_selected, source))
+ if (!is_in_uids (uids_selected, source))
e_source_selector_unselect_source (E_SOURCE_SELECTOR (component_view->source_selector), source);
}
-
+
e_source_selector_free_selection (selection);
/* Make sure the whole selection is there */
@@ -349,9 +349,9 @@ update_selection (TasksComponentView *component_view)
ESource *source;
source = e_source_list_peek_source_by_uid (component_view->source_list, uid);
- if (source)
+ if (source)
e_source_selector_select_source (E_SOURCE_SELECTOR (component_view->source_selector), source);
-
+
g_free (uid);
}
g_slist_free (uids_selected);
@@ -368,7 +368,7 @@ update_primary_selection (TasksComponentView *component_view)
source = e_source_list_peek_source_by_uid (component_view->source_list, uid);
g_free (uid);
}
-
+
if (source) {
e_source_selector_set_primary_selection (E_SOURCE_SELECTOR (component_view->source_selector), source);
} else {
@@ -385,7 +385,7 @@ copy_task_list_cb (EPopup *ep, EPopupItem *pitem, void *data)
{
TasksComponentView *component_view = data;
ESource *selected_source;
-
+
selected_source = e_source_selector_peek_primary_selection (E_SOURCE_SELECTOR (component_view->source_selector));
if (!selected_source)
return;
@@ -425,7 +425,7 @@ delete_task_list_cb (EPopup *ep, EPopupItem *pitem, void *data)
e_source_selector_unselect_source (E_SOURCE_SELECTOR (component_view->source_selector),
selected_source);
}
-
+
e_source_group_remove_source (e_source_peek_group (selected_source), selected_source);
e_source_list_sync (component_view->source_list, NULL);
}
@@ -524,7 +524,7 @@ set_info (TasksComponentView *component_view)
{
GString *message = g_string_new (NULL);
int rows, selected_rows;
-
+
rows = e_table_model_row_count (component_view->model);
selected_rows = e_table_selected_count (component_view->table);
@@ -587,11 +587,11 @@ impl_upgradeFromVersion (PortableServer_Servant servant,
}
static gboolean
-selector_tree_drag_drop (GtkWidget *widget,
- GdkDragContext *context,
- int x,
- int y,
- guint time,
+selector_tree_drag_drop (GtkWidget *widget,
+ GdkDragContext *context,
+ int x,
+ int y,
+ guint time,
CalendarComponent *component)
{
GtkTreeViewColumn *column;
@@ -601,12 +601,12 @@ selector_tree_drag_drop (GtkWidget *widget,
GtkTreeModel *model;
GtkTreeIter iter;
gpointer data;
-
- if (!gtk_tree_view_get_path_at_pos (GTK_TREE_VIEW (widget), x, y, &path,
+
+ if (!gtk_tree_view_get_path_at_pos (GTK_TREE_VIEW (widget), x, y, &path,
&column, &cell_x, &cell_y))
return FALSE;
-
-
+
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
if (!gtk_tree_model_get_iter (model, &iter, path)) {
@@ -615,17 +615,17 @@ selector_tree_drag_drop (GtkWidget *widget,
}
gtk_tree_model_get (model, &iter, 0, &data, -1);
-
+
if (E_IS_SOURCE_GROUP (data)) {
g_object_unref (data);
gtk_tree_path_free (path);
return FALSE;
}
-
+
gtk_tree_path_free (path);
return TRUE;
}
-
+
static gboolean
selector_tree_drag_motion (GtkWidget *widget,
GdkDragContext *context,
@@ -640,21 +640,21 @@ selector_tree_drag_motion (GtkWidget *widget,
GtkTreeModel *model;
GtkTreeIter iter;
GdkDragAction action = GDK_ACTION_DEFAULT;
-
+
if (!gtk_tree_view_get_dest_row_at_pos (GTK_TREE_VIEW (widget),
x, y, &path, &pos))
goto finish;
-
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
-
+
if (!gtk_tree_model_get_iter (model, &iter, path))
goto finish;
-
+
gtk_tree_model_get (model, &iter, 0, &data, -1);
if (E_IS_SOURCE_GROUP (data) || e_source_get_readonly (data))
goto finish;
-
+
gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget), path, GTK_TREE_VIEW_DROP_INTO_OR_BEFORE);
action = context->suggested_action;
if (action == GDK_ACTION_COPY && (context->actions & GDK_ACTION_MOVE))
@@ -677,11 +677,11 @@ update_single_object (ECal *client, icalcomponent *icalcomp)
icalcomponent *tmp_icalcomp;
uid = (char *) icalcomponent_get_uid (icalcomp);
-
+
if (e_cal_get_object (client, uid, NULL, &tmp_icalcomp, NULL))
return e_cal_modify_object (client, icalcomp, CALOBJ_MOD_ALL, NULL);
- return e_cal_create_object (client, icalcomp, &uid, NULL);
+ return e_cal_create_object (client, icalcomp, &uid, NULL);
}
static gboolean
@@ -699,7 +699,7 @@ update_objects (ECal *client, icalcomponent *icalcomp)
subcomp = icalcomponent_get_first_component (icalcomp, ICAL_ANY_COMPONENT);
while (subcomp) {
gboolean success;
-
+
kind = icalcomponent_isa (subcomp);
if (kind == ICAL_VTIMEZONE_COMPONENT) {
icaltimezone *zone;
@@ -725,10 +725,10 @@ update_objects (ECal *client, icalcomponent *icalcomp)
}
static void
-selector_tree_drag_data_received (GtkWidget *widget,
- GdkDragContext *context,
- gint x,
- gint y,
+selector_tree_drag_data_received (GtkWidget *widget,
+ GdkDragContext *context,
+ gint x,
+ gint y,
GtkSelectionData *data,
guint info,
guint time,
@@ -748,13 +748,13 @@ selector_tree_drag_data_received (GtkWidget *widget,
if (!gtk_tree_view_get_dest_row_at_pos (GTK_TREE_VIEW (widget),
x, y, &path, &pos))
goto finish;
-
+
model = gtk_tree_view_get_model (GTK_TREE_VIEW (widget));
-
+
if (!gtk_tree_model_get_iter (model, &iter, path))
goto finish;
-
-
+
+
gtk_tree_model_get (model, &iter, 0, &source, -1);
if (E_IS_SOURCE_GROUP (source) || e_source_get_readonly (source) || !data->data)
@@ -849,12 +849,12 @@ selector_tree_drag_data_received (GtkWidget *widget,
gtk_tree_path_free (path);
gtk_drag_finish (context, success, context->action == GDK_ACTION_MOVE, time);
-}
+}
static void
selector_tree_drag_leave (GtkWidget *widget, GdkDragContext *context, guint time, gpointer data)
{
- gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget),
+ gtk_tree_view_set_drag_dest_row(GTK_TREE_VIEW (widget),
NULL, GTK_TREE_VIEW_DROP_BEFORE);
}
@@ -867,33 +867,33 @@ control_activate_cb (BonoboControl *control, gboolean activate, gpointer data)
if (activate) {
BonoboUIComponent *uic;
uic = bonobo_control_get_ui_component (component_view->view_control);
-
+
e_user_creatable_items_handler_activate (component_view->creatable_items_handler, uic);
- }
+ }
}
static void
config_create_ecal_changed_cb (GConfClient *client, guint id, GConfEntry *entry, gpointer data)
-{
+{
TasksComponent *component = data;
TasksComponentPrivate *priv;
-
+
priv = component->priv;
g_object_unref (priv->create_ecal);
priv->create_ecal = NULL;
-
+
priv->notifications = g_list_remove (priv->notifications, GUINT_TO_POINTER (id));
}
static ECal *
-setup_create_ecal (TasksComponent *component, TasksComponentView *component_view)
+setup_create_ecal (TasksComponent *component, TasksComponentView *component_view)
{
TasksComponentPrivate *priv;
ESource *source = NULL;
char *uid;
guint not;
-
+
priv = component->priv;
if (component_view) {
@@ -903,18 +903,18 @@ setup_create_ecal (TasksComponent *component, TasksComponentView *component_view
if (default_ecal)
return default_ecal;
}
-
+
if (priv->create_ecal)
- return priv->create_ecal;
-
- /* Get the current primary calendar, or try to set one if it doesn't already exist */
+ return priv->create_ecal;
+
+ /* Get the current primary calendar, or try to set one if it doesn't already exist */
uid = calendar_config_get_primary_tasks ();
if (uid) {
source = e_source_list_peek_source_by_uid (priv->source_list, uid);
g_free (uid);
priv->create_ecal = auth_new_cal_from_source (source, E_CAL_SOURCE_TYPE_TODO);
- }
+ }
if (!priv->create_ecal) {
/* Try to create a default if there isn't one */
@@ -922,19 +922,19 @@ setup_create_ecal (TasksComponent *component, TasksComponentView *component_view
if (source)
priv->create_ecal = auth_new_cal_from_source (source, E_CAL_SOURCE_TYPE_TODO);
}
-
+
if (priv->create_ecal) {
icaltimezone *zone;
-
+
zone = calendar_config_get_icaltimezone ();
e_cal_set_default_timezone (priv->create_ecal, zone, NULL);
if (!e_cal_open (priv->create_ecal, FALSE, NULL)) {
GtkWidget *dialog;
-
+
dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_MODAL,
GTK_MESSAGE_WARNING, GTK_BUTTONS_OK,
- _("Unable to open the task list '%s' for creating events and meetings"),
+ _("Unable to open the task list '%s' for creating events and meetings"),
e_source_peek_name (source));
gtk_dialog_run (GTK_DIALOG (dialog));
gtk_widget_destroy (dialog);
@@ -944,7 +944,7 @@ setup_create_ecal (TasksComponent *component, TasksComponentView *component_view
} else {
GtkWidget *dialog;
-
+
dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_MODAL,
GTK_MESSAGE_WARNING, GTK_BUTTONS_OK,
_("There is no calendar available for creating tasks"));
@@ -952,10 +952,10 @@ setup_create_ecal (TasksComponent *component, TasksComponentView *component_view
gtk_widget_destroy (dialog);
return NULL;
- }
+ }
/* Handle the fact it may change on us */
- not = calendar_config_add_notification_primary_tasks (config_create_ecal_changed_cb,
+ not = calendar_config_add_notification_primary_tasks (config_create_ecal_changed_cb,
component);
priv->notifications = g_list_prepend (priv->notifications, GUINT_TO_POINTER (not));
@@ -982,15 +982,15 @@ create_new_todo (TasksComponent *task_component, gboolean is_assigned, TasksComp
ECal *ecal;
ECalComponent *comp;
TaskEditor *editor;
- guint32 flags = 0;
-
+ guint32 flags = 0;
+
ecal = setup_create_ecal (task_component, component_view);
if (!ecal)
return FALSE;
if (is_assigned)
flags |= COMP_EDITOR_IS_ASSIGNED;
-
+
flags |= COMP_EDITOR_NEW_ITEM | COMP_EDITOR_USER_ORG;
editor = task_editor_new (ecal, flags);
@@ -1015,18 +1015,18 @@ create_local_item_cb (EUserCreatableItemsHandler *handler, const char *item_type
TasksComponentPrivate *priv;
TasksComponentView *component_view = NULL;
GList *l;
-
+
priv = tasks_component->priv;
-
+
for (l = priv->views; l; l = l->next) {
component_view = l->data;
if (component_view->creatable_items_handler == handler)
break;
-
+
component_view = NULL;
}
-
+
if (strcmp (item_type_name, CREATE_TASK_ID) == 0) {
create_new_todo (tasks_component, FALSE, component_view);
} else if (strcmp (item_type_name, CREATE_TASK_ASSIGNED_ID) == 0) {
@@ -1044,28 +1044,28 @@ create_component_view (TasksComponent *tasks_component)
GtkWidget *selector_scrolled_window, *vbox;
GtkWidget *statusbar_widget;
AtkObject *a11y;
-
+
priv = tasks_component->priv;
/* Create the calendar component view */
component_view = g_new0 (TasksComponentView, 1);
-
+
/* Add the source lists */
component_view->source_list = g_object_ref (priv->source_list);
-
+
/* Create sidebar selector */
component_view->source_selector = e_source_selector_new (tasks_component->priv->source_list);
e_source_selector_set_select_new ((ESourceSelector *)component_view->source_selector, TRUE);
a11y = gtk_widget_get_accessible (GTK_WIDGET (component_view->source_selector));
atk_object_set_name (a11y, _("Task Source Selector"));
- g_signal_connect (component_view->source_selector, "drag-motion", G_CALLBACK (selector_tree_drag_motion),
+ g_signal_connect (component_view->source_selector, "drag-motion", G_CALLBACK (selector_tree_drag_motion),
tasks_component);
- g_signal_connect (component_view->source_selector, "drag-leave", G_CALLBACK (selector_tree_drag_leave),
+ g_signal_connect (component_view->source_selector, "drag-leave", G_CALLBACK (selector_tree_drag_leave),
tasks_component);
- g_signal_connect (component_view->source_selector, "drag-drop", G_CALLBACK (selector_tree_drag_drop),
+ g_signal_connect (component_view->source_selector, "drag-drop", G_CALLBACK (selector_tree_drag_drop),
tasks_component);
- g_signal_connect (component_view->source_selector, "drag-data-received",
+ g_signal_connect (component_view->source_selector, "drag-data-received",
G_CALLBACK (selector_tree_drag_data_received), tasks_component);
gtk_drag_dest_set(component_view->source_selector, GTK_DEST_DEFAULT_ALL, drag_types,
@@ -1105,9 +1105,9 @@ create_component_view (TasksComponent *tasks_component)
component_view->model = E_TABLE_MODEL (e_calendar_table_get_model (e_tasks_get_calendar_table (component_view->tasks)));
/* This signal is thrown if backends die - we update the selector */
- g_signal_connect (component_view->tasks, "source_added",
+ g_signal_connect (component_view->tasks, "source_added",
G_CALLBACK (source_added_cb), component_view);
- g_signal_connect (component_view->tasks, "source_removed",
+ g_signal_connect (component_view->tasks, "source_removed",
G_CALLBACK (source_removed_cb), component_view);
/* Create status bar */
@@ -1117,9 +1117,9 @@ create_component_view (TasksComponent *tasks_component)
gtk_widget_show (statusbar_widget);
component_view->statusbar_control = bonobo_control_new (statusbar_widget);
-
+
e_calendar_table_set_activity_handler (e_tasks_get_calendar_table (component_view->tasks), component_view->activity_handler);
-
+
/* connect after setting the initial selections, or we'll get unwanted calls
to calendar_control_sensitize_calendar_commands */
g_signal_connect (component_view->source_selector, "selection_changed",
@@ -1137,7 +1137,7 @@ create_component_view (TasksComponent *tasks_component)
set_info (component_view);
g_signal_connect (component_view->table, "selection_change",
G_CALLBACK (table_selection_change_cb), component_view);
- g_signal_connect (component_view->model, "model_changed",
+ g_signal_connect (component_view->model, "model_changed",
G_CALLBACK (model_changed_cb), component_view);
g_signal_connect (component_view->model, "model_rows_inserted",
G_CALLBACK (model_rows_inserted_cb), component_view);
@@ -1145,7 +1145,7 @@ create_component_view (TasksComponent *tasks_component)
G_CALLBACK (model_rows_deleted_cb), component_view);
/* Load the selection from the last run */
- update_selection (component_view);
+ update_selection (component_view);
update_primary_selection (component_view);
return component_view;
@@ -1153,15 +1153,15 @@ create_component_view (TasksComponent *tasks_component)
static void
destroy_component_view (TasksComponentView *component_view)
-{
+{
GList *l;
-
+
if (component_view->source_list)
g_object_unref (component_view->source_list);
if (component_view->source_selection)
e_source_selector_free_selection (component_view->source_selection);
-
+
for (l = component_view->notifications; l; l = l->next)
calendar_config_remove_notification (GPOINTER_TO_UINT (l->data));
g_list_free (component_view->notifications);
@@ -1181,12 +1181,12 @@ view_destroyed_cb (gpointer data, GObject *where_the_object_was)
TasksComponent *tasks_component = data;
TasksComponentPrivate *priv;
GList *l;
-
+
priv = tasks_component->priv;
for (l = priv->views; l; l = l->next) {
TasksComponentView *component_view = l->data;
-
+
if (G_OBJECT (component_view->view_control) == where_the_object_was) {
priv->views = g_list_remove (priv->views, component_view);
destroy_component_view (component_view);
@@ -1205,7 +1205,7 @@ impl_createView (PortableServer_Servant servant,
TasksComponentPrivate *priv;
TasksComponentView *component_view;
EComponentView *ecv;
-
+
priv = component->priv;
/* Create the calendar component view */
@@ -1219,7 +1219,7 @@ impl_createView (PortableServer_Servant servant,
g_object_weak_ref (G_OBJECT (component_view->view_control), view_destroyed_cb, component);
priv->views = g_list_append (priv->views, component_view);
-
+
/* TODO: Make TasksComponentView just subclass EComponentView */
ecv = e_component_view_new_controls (parent, "tasks", component_view->sidebar_control,
component_view->view_control, component_view->statusbar_control);
@@ -1257,17 +1257,17 @@ impl_handleURI (PortableServer_Servant servant, const char *uri, CORBA_Environme
if (p) {
while (*p) {
len = strcspn (p, "=&");
-
+
/* If it's malformed, give up. */
if (p[len] != '=')
break;
-
+
header = (char *) p;
header[len] = '\0';
p += len + 1;
-
+
clen = strcspn (p, "&");
-
+
content = g_strndup (p, clen);
if (!g_ascii_strcasecmp (header, "source-uid")) {
src_uid = g_strdup (content);
@@ -1289,7 +1289,7 @@ impl_handleURI (PortableServer_Servant servant, const char *uri, CORBA_Environme
if (uid && src_uid) {
e_tasks_open_task_id (view->tasks, src_uid, uid, rid);
}
-
+
g_free (src_uid);
g_free (uid);
g_free (rid);
@@ -1345,7 +1345,7 @@ impl_requestCreateItem (PortableServer_Servant servant,
CORBA_Environment *ev)
{
TasksComponent *tasks_component = TASKS_COMPONENT (bonobo_object_from_servant (servant));
-
+
if (strcmp (item_type_name, CREATE_TASK_ID) == 0) {
if (!create_new_todo (tasks_component, FALSE, NULL))
bonobo_exception_set (ev, ex_GNOME_Evolution_Component_Failed);
@@ -1368,7 +1368,7 @@ impl_dispose (GObject *object)
TasksComponent *tasks_component = TASKS_COMPONENT (object);
TasksComponentPrivate *priv = tasks_component->priv;
GList *l;
-
+
if (priv->source_list != NULL) {
g_object_unref (priv->source_list);
priv->source_list = NULL;
@@ -1385,7 +1385,7 @@ impl_dispose (GObject *object)
for (l = priv->views; l; l = l->next) {
TasksComponentView *component_view = l->data;
-
+
g_object_weak_unref (G_OBJECT (component_view->view_control), view_destroyed_cb, tasks_component);
}
g_list_free (priv->views);
@@ -1404,10 +1404,10 @@ impl_finalize (GObject *object)
{
TasksComponentPrivate *priv = TASKS_COMPONENT (object)->priv;
GList *l;
-
+
for (l = priv->views; l; l = l->next) {
TasksComponentView *component_view = l->data;
-
+
destroy_component_view (component_view);
}
g_list_free (priv->views);
@@ -1448,7 +1448,7 @@ tasks_component_init (TasksComponent *component, TasksComponentClass *klass)
priv->config_directory = g_build_filename (g_get_home_dir (),
".evolution", "tasks", "config",
NULL);
-
+
component->priv = priv;
ensure_sources (component);
}
@@ -1489,7 +1489,7 @@ tasks_component_peek_config_directory (TasksComponent *component)
ESourceList *
tasks_component_peek_source_list (TasksComponent *component)
{
- return component->priv->source_list;
+ return component->priv->source_list;
}
BONOBO_TYPE_FUNC_FULL (TasksComponent, GNOME_Evolution_Component, PARENT_TYPE, tasks_component)
diff --git a/calendar/gui/tasks-control.c b/calendar/gui/tasks-control.c
index dda57aad74..5c0b89e3f8 100644
--- a/calendar/gui/tasks-control.c
+++ b/calendar/gui/tasks-control.c
@@ -97,12 +97,12 @@ static void tasks_control_forward_cmd (BonoboUIComponent *uic,
gpointer data,
const char *path);
-static void tasks_control_view_preview (BonoboUIComponent *uic,
- const char *path,
- Bonobo_UIComponent_EventType type,
- const char *state,
+static void tasks_control_view_preview (BonoboUIComponent *uic,
+ const char *path,
+ Bonobo_UIComponent_EventType type,
+ const char *state,
void *data);
-
+
BonoboControl *
tasks_control_new (void)
{
@@ -218,9 +218,9 @@ tasks_control_sensitize_commands (BonoboControl *control, ETasks *tasks, int n_s
ecal = e_cal_model_get_default_client (model);
- if (ecal)
+ if (ecal)
e_cal_is_read_only (ecal, &read_only, NULL);
-
+
sensitize_items (uic, tasks_sensitize_table, t->target.mask);
e_menu_update_target ((EMenu *)menu, (EMenuTarget *)t);
}
@@ -266,7 +266,7 @@ static EPixmap pixmaps [] = {
E_PIXMAP ("/Toolbar/Paste", "edit-paste", E_ICON_SIZE_LARGE_TOOLBAR),
E_PIXMAP ("/Toolbar/Print", "document-print", E_ICON_SIZE_LARGE_TOOLBAR),
E_PIXMAP ("/Toolbar/Delete", "edit-delete", E_ICON_SIZE_LARGE_TOOLBAR),
-
+
E_PIXMAP_END
};
void
@@ -302,8 +302,8 @@ tasks_control_activate (BonoboControl *control, ETasks *tasks)
NULL);
g_free (xmlfile);
- e_pixmaps_update (uic, pixmaps);
-
+ e_pixmaps_update (uic, pixmaps);
+
e_tasks_setup_view_menus (tasks, uic);
/* Signals from the tasks widget; also sensitize the menu items as appropriate */
@@ -320,7 +320,7 @@ tasks_control_activate (BonoboControl *control, ETasks *tasks)
state = calendar_config_get_preview_state();
bonobo_ui_component_thaw (uic, NULL);
-
+
bonobo_ui_component_add_listener(uic, "ViewPreview", tasks_control_view_preview, tasks);
bonobo_ui_component_set_prop(uic, "/commands/ViewPreview", "state", state?"1":"0", NULL);
/* Show the dialog for setting the timezone if the user hasn't chosen
@@ -441,7 +441,7 @@ confirm_purge (ETasks *tasks)
{
GtkWidget *dialog, *checkbox, *parent;
int button;
-
+
if (!calendar_config_get_confirm_purge ())
return TRUE;
@@ -457,12 +457,12 @@ confirm_purge (ETasks *tasks)
checkbox = gtk_check_button_new_with_label (_("Do not ask me again."));
gtk_widget_show (checkbox);
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (dialog)->vbox), checkbox, TRUE, TRUE, 6);
-
- button = gtk_dialog_run (GTK_DIALOG (dialog));
+
+ button = gtk_dialog_run (GTK_DIALOG (dialog));
if (button == GTK_RESPONSE_YES && gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (checkbox)))
calendar_config_set_confirm_purge (FALSE);
gtk_widget_destroy (dialog);
-
+
return button == GTK_RESPONSE_YES ? TRUE : FALSE;
}
@@ -535,7 +535,7 @@ tasks_control_forward_cmd (BonoboUIComponent *uic,
ETasks *tasks;
ECalendarTable *cal_table;
ECalModelComponent *comp_data;
-
+
tasks = E_TASKS (data);
cal_table = e_tasks_get_calendar_table (tasks);
comp_data = e_calendar_table_get_selected_comp (cal_table);
@@ -555,7 +555,7 @@ tasks_control_view_preview (BonoboUIComponent *uic, const char *path, Bonobo_UIC
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
tasks = E_TASKS (data);
calendar_config_set_preview_state (state[0] != '0');
diff --git a/calendar/gui/weekday-picker.c b/calendar/gui/weekday-picker.c
index cab6f9977d..166c5d5b26 100644
--- a/calendar/gui/weekday-picker.c
+++ b/calendar/gui/weekday-picker.c
@@ -109,7 +109,7 @@ weekday_picker_class_init (WeekdayPickerClass *class)
class->changed = NULL;
}
-static void
+static void
day_clicked (WeekdayPicker *wp, int index)
{
WeekdayPickerPrivate *priv = wp->priv;
@@ -324,7 +324,7 @@ get_day_text (int day_index)
/* we use strlen because we actually want to count bytes */
if (day_index == 6)
- char_size = strlen (day);
+ char_size = strlen (day);
else
char_size = strlen (day) - strlen (g_utf8_find_next_char (day, NULL));
@@ -459,7 +459,7 @@ weekday_picker_style_set (GtkWidget *widget, GtkStyle *previous_style)
pango_layout_set_text (layout, c, strlen (c));
pango_layout_get_pixel_size (layout, &w, NULL);
g_free (c);
-
+
if (w > max_width)
max_width = w;
}
@@ -478,10 +478,10 @@ weekday_picker_style_set (GtkWidget *widget, GtkStyle *previous_style)
/**
* weekday_picker_new:
- * @void:
- *
+ * @void:
+ *
* Creates a new weekday picker widget.
- *
+ *
* Return value: A newly-created weekday picker.
**/
GtkWidget *
@@ -494,7 +494,7 @@ weekday_picker_new (void)
* weekday_picker_set_days:
* @wp: A weekday picker.
* @day_mask: Bitmask with the days to be selected.
- *
+ *
* Sets the days that are selected in a weekday picker. In the @day_mask,
* Sunday is bit 0, Monday is bit 1, etc.
**/
@@ -517,9 +517,9 @@ weekday_picker_set_days (WeekdayPicker *wp, guint8 day_mask)
/**
* weekday_picker_get_days:
* @wp: A weekday picker.
- *
+ *
* Queries the days that are selected in a weekday picker.
- *
+ *
* Return value: Bit mask of selected days. Sunday is bit 0, Monday is bit 1,
* etc.
**/
@@ -539,7 +539,7 @@ weekday_picker_get_days (WeekdayPicker *wp)
* weekday_picker_set_blocked_days:
* @wp: A weekday picker.
* @blocked_day_mask: Bitmask with the days to be blocked.
- *
+ *
* Sets the days that the weekday picker will prevent from being modified by the
* user. The @blocked_day_mask is specified in the same way as in
* weekday_picker_set_days().
@@ -559,10 +559,10 @@ weekday_picker_set_blocked_days (WeekdayPicker *wp, guint8 blocked_day_mask)
/**
* weekday_picker_get_blocked_days:
* @wp: A weekday picker.
- *
+ *
* Queries the set of days that the weekday picker prevents from being modified
* by the user.
- *
+ *
* Return value: Bit mask of blocked days, with the same format as that returned
* by weekday_picker_get_days().
**/
@@ -583,7 +583,7 @@ weekday_picker_get_blocked_days (WeekdayPicker *wp)
* @wp: A weekday picker.
* @week_start_day: Index of the day that defines the start of the week; 0 is
* Sunday, 1 is Monday, etc.
- *
+ *
* Sets the day that defines the start of the week for a weekday picker.
**/
void
@@ -604,9 +604,9 @@ weekday_picker_set_week_start_day (WeekdayPicker *wp, int week_start_day)
/**
* weekday_picker_get_week_start_day:
* @wp: A weekday picker.
- *
+ *
* Queries the day that defines the start of the week in a weekday picker.
- *
+ *
* Return value: Index of the day that defines the start of the week. See
* weekday_picker_set_week_start_day() to see how this is represented.
**/
diff --git a/calendar/importers/icalendar-importer.c b/calendar/importers/icalendar-importer.c
index 5055e1a3ea..0b08fc893a 100644
--- a/calendar/importers/icalendar-importer.c
+++ b/calendar/importers/icalendar-importer.c
@@ -105,7 +105,7 @@ prepare_events (icalcomponent *icalcomp, GList **vtodos)
if (vtodos)
*vtodos = NULL;
-
+
iter = icalcomponent_begin_component (icalcomp, ICAL_ANY_COMPONENT);
while ((subcomp = icalcompiter_deref (&iter)) != NULL) {
icalcomponent_kind child_kind = icalcomponent_isa (subcomp);
@@ -218,7 +218,7 @@ ivcal_getwidget(EImport *ei, EImportTarget *target, EImportImporter *im)
GtkWidget *nb;
vbox = gtk_vbox_new (FALSE, FALSE);
-
+
hbox = gtk_hbox_new (FALSE, FALSE);
gtk_box_pack_start (GTK_BOX (vbox), hbox, FALSE, TRUE, 6);
@@ -389,7 +389,7 @@ ical_supported(EImport *ei, EImportTarget *target, EImportImporter *im)
if (icalcomp) {
if (icalcomponent_is_valid (icalcomp))
ret = TRUE;
- else
+ else
ret = FALSE;
icalcomponent_free (icalcomp);
}
@@ -487,7 +487,7 @@ vcal_supported(EImport *ei, EImportTarget *target, EImportImporter *im)
icalcomponent *icalcomp;
icalcomp = icalvcal_convert (vcal);
-
+
if (icalcomp) {
icalcomponent_free (icalcomp);
ret = TRUE;
diff --git a/composer/e-msg-composer-hdrs.c b/composer/e-msg-composer-hdrs.c
index a3170054fc..523c66f695 100644
--- a/composer/e-msg-composer-hdrs.c
+++ b/composer/e-msg-composer-hdrs.c
@@ -97,18 +97,18 @@ typedef struct {
struct _EMsgComposerHdrsPrivate {
ENameSelector *name_selector;
-
+
/* ui component */
BonoboUIComponent *uic;
-
+
/* The tooltips. */
GtkTooltips *tooltips;
-
+
EAccountList *accounts;
GSList *from_options;
-
+
gboolean post_custom;
-
+
/* Standard headers. */
EMsgComposerHdrPair from, reply_to, to, cc, bcc, post_to, subject;
};
@@ -138,9 +138,9 @@ setup_name_selector (EMsgComposerHdrs *hdrs)
{
EMsgComposerHdrsPrivate *priv;
ENameSelectorDialog *name_selector_dialog;
-
+
priv = hdrs->priv;
-
+
g_return_if_fail (priv->name_selector == NULL);
priv->name_selector = e_name_selector_new ();
@@ -167,13 +167,13 @@ static EMsgComposerHdrsAndString *
e_msg_composer_hdrs_and_string_create (EMsgComposerHdrs *hdrs, const char *string)
{
EMsgComposerHdrsAndString *emchas;
-
+
emchas = g_new (EMsgComposerHdrsAndString, 1);
emchas->hdrs = hdrs;
emchas->string = g_strdup (string);
if (emchas->hdrs)
g_object_ref (emchas->hdrs);
-
+
return emchas;
}
@@ -185,11 +185,11 @@ address_button_clicked_cb (GtkButton *button, gpointer data)
EMsgComposerHdrsPrivate *priv;
ENameSelectorDialog *name_selector_dialog;
guint index = 0;
-
+
emchas = data;
hdrs = emchas->hdrs;
priv = hdrs->priv;
-
+
if (button == (GtkButton *) hdrs->priv->to.label) {
gtk_widget_grab_focus (hdrs->priv->to.entry);
index = 0;
@@ -205,7 +205,7 @@ address_button_clicked_cb (GtkButton *button, gpointer data)
index = 2;
printf("index:%d\n", index);
}
-
+
name_selector_dialog = e_name_selector_peek_dialog (priv->name_selector);
e_name_selector_dialog_set_destination_index (name_selector_dialog, index);
gtk_widget_show (GTK_WIDGET (name_selector_dialog));
@@ -217,25 +217,25 @@ from_changed (GtkWidget *item, gpointer data)
EMsgComposerHdrs *hdrs = E_MSG_COMPOSER_HDRS (data);
const char *reply_to;
GList *post_items = NULL;
-
+
/* this will retrieve items relative to the previous account */
if (!hdrs->priv->post_custom)
post_items = e_msg_composer_hdrs_get_post_to(hdrs);
-
+
hdrs->account = g_object_get_data ((GObject *) item, "account");
-
+
/* we do this rather than calling e_msg_composer_hdrs_set_reply_to()
because we don't want to change the visibility of the header */
reply_to = hdrs->account->id->reply_to;
gtk_entry_set_text (GTK_ENTRY (hdrs->priv->reply_to.entry), reply_to ? reply_to : "");
-
+
/* folders should be made relative to the new from */
if (!hdrs->priv->post_custom) {
e_msg_composer_hdrs_set_post_to_list (hdrs, post_items);
g_list_foreach (post_items, (GFunc)g_free, NULL);
g_list_free(post_items);
}
-
+
g_signal_emit (hdrs, signals [FROM_CHANGED], 0);
}
@@ -245,11 +245,11 @@ account_can_send (EAccount *account)
static CamelStore *store;
CamelException ex;
gboolean result = FALSE;
-
- if (!account->parent_uid)
+
+ if (!account->parent_uid)
return TRUE;
-
- if (!(store = (CamelStore *) camel_session_get_service (session, e_account_get_string(account, E_ACCOUNT_SOURCE_URL), CAMEL_PROVIDER_STORE, &ex))) {
+
+ if (!(store = (CamelStore *) camel_session_get_service (session, e_account_get_string(account, E_ACCOUNT_SOURCE_URL), CAMEL_PROVIDER_STORE, &ex))) {
camel_exception_clear (&ex);
return result;
} else if (store->mode & CAMEL_STORE_WRITE)
@@ -264,10 +264,10 @@ account_added_cb (EAccountList *accounts, EAccount *account, EMsgComposerHdrs *h
{
GtkWidget *item, *menu, *omenu, *toplevel;
char *label;
-
+
omenu = e_msg_composer_hdrs_get_from_omenu (hdrs);
menu = gtk_option_menu_get_menu (GTK_OPTION_MENU (omenu));
-
+
if (account_can_send (account)) {
label = g_strdup_printf ("%s <%s>", account->id->name, account->id->address);
item = gtk_menu_item_new_with_label (label);
@@ -277,12 +277,12 @@ account_added_cb (EAccountList *accounts, EAccount *account, EMsgComposerHdrs *h
g_object_ref (account);
g_object_set_data ((GObject *) item, "account", account);
g_signal_connect (item, "activate", G_CALLBACK (from_changed), hdrs);
-
+
/* this is so we can later set which one we want */
hdrs->priv->from_options = g_slist_append (hdrs->priv->from_options, item);
-
+
gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
-
+
toplevel = gtk_widget_get_toplevel ((GtkWidget *) hdrs);
gtk_widget_set_sensitive (toplevel, TRUE);
}
@@ -307,7 +307,7 @@ account_changed_cb (EAccountList *accounts, EAccount *account, EMsgComposerHdrs
g_free (text);
break;
}
-
+
node = node->next;
}
}
@@ -327,30 +327,30 @@ account_removed_cb (EAccountList *accounts, EAccount *account, EMsgComposerHdrs
if (acnt == account) {
if (hdrs->account == account)
hdrs->account = NULL;
-
+
priv->from_options = g_slist_delete_link (priv->from_options, node);
g_object_unref (account);
gtk_widget_destroy (item);
break;
}
-
+
node = node->next;
}
-
+
if (hdrs->account == NULL) {
if (priv->from_options) {
/* the previously selected account was removed,
default the new selection to the first account in
the menu list */
omenu = e_msg_composer_hdrs_get_from_omenu (hdrs);
-
+
item = priv->from_options->data;
gtk_option_menu_set_history (GTK_OPTION_MENU (omenu), 0);
g_signal_emit_by_name (item, "activate", hdrs);
} else {
toplevel = gtk_widget_get_toplevel ((GtkWidget *) hdrs);
gtk_widget_set_sensitive (toplevel, FALSE);
-
+
/* FIXME: this should offer a 'configure account' button, can we do that? */
e_error_run((GtkWindow *)toplevel, "mail-composer:all-accounts-deleted", NULL);
}
@@ -371,11 +371,11 @@ create_from_optionmenu (EMsgComposerHdrs *hdrs)
omenu = gtk_option_menu_new ();
menu = gtk_menu_new ();
-
+
gconf = gconf_client_get_default ();
uid = gconf_client_get_string (gconf, "/apps/evolution/mail/default_account", NULL);
g_object_unref (gconf);
-
+
/* Make list of account email addresses */
addresses = g_ptr_array_new ();
iter = e_list_get_iterator ((EList *) priv->accounts);
@@ -384,23 +384,23 @@ create_from_optionmenu (EMsgComposerHdrs *hdrs)
if (account->id->address && account_can_send (account) && account->enabled)
g_ptr_array_add (addresses, account->id->address);
-
+
e_iterator_next (iter);
}
-
+
e_iterator_reset (iter);
-
+
while (e_iterator_is_valid (iter)) {
char *label;
-
+
account = (EAccount *) e_iterator_get (iter);
-
+
/* this should never ever fail */
if (!account || !account->name || !account->id) {
g_warning ("account details are bad\n");
continue;
}
-
+
if (account->id->address && *account->id->address && account_can_send (account) && account->enabled) {
/* If the account has a unique email address, just
* show that. Otherwise include the account name.
@@ -409,60 +409,60 @@ create_from_optionmenu (EMsgComposerHdrs *hdrs)
if (!strcmp (account->id->address, addresses->pdata[m]))
matches++;
}
-
+
if (matches > 1)
label = g_strdup_printf ("%s <%s> (%s)", account->id->name,
account->id->address, account->name);
else
label = g_strdup_printf ("%s <%s>", account->id->name, account->id->address);
-
+
item = gtk_menu_item_new_with_label (label);
g_free (label);
-
+
g_object_ref (account);
g_object_set_data ((GObject *) item, "account", account);
g_signal_connect (item, "activate", G_CALLBACK (from_changed), hdrs);
-
+
if (uid && !strcmp (account->uid, uid)) {
first = item;
history = i;
}
-
+
/* this is so we can later set which one we want */
hdrs->priv->from_options = g_slist_append (hdrs->priv->from_options, item);
-
+
gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
gtk_widget_show (item);
i++;
}
-
+
e_iterator_next (iter);
}
-
+
g_free (uid);
g_object_unref (iter);
-
+
g_ptr_array_free (addresses, TRUE);
-
+
gtk_option_menu_set_menu (GTK_OPTION_MENU (omenu), menu);
-
+
if (first) {
gtk_option_menu_set_history (GTK_OPTION_MENU (omenu), history);
g_signal_emit_by_name (first, "activate", hdrs);
}
-
+
hbox = gtk_hbox_new (FALSE, 6);
gtk_box_pack_start_defaults (GTK_BOX (hbox), omenu);
gtk_widget_show (omenu);
gtk_widget_show (hbox);
-
+
g_object_set_data ((GObject *) hbox, "from_menu", omenu);
-
+
/* listen for changes to the account list so we can auto-update the from menu */
g_signal_connect (priv->accounts, "account-added", G_CALLBACK (account_added_cb), hdrs);
g_signal_connect (priv->accounts, "account-changed", G_CALLBACK (account_changed_cb), hdrs);
g_signal_connect (priv->accounts, "account-removed", G_CALLBACK (account_removed_cb), hdrs);
-
+
return hbox;
}
@@ -471,7 +471,7 @@ addressbook_entry_changed (GtkWidget *entry,
gpointer user_data)
{
EMsgComposerHdrs *hdrs = E_MSG_COMPOSER_HDRS (user_data);
-
+
g_signal_emit (hdrs, signals[HDRS_CHANGED], 0);
}
@@ -519,7 +519,7 @@ create_addressbook_entry (EMsgComposerHdrs *hdrs, const char *name)
EMsgComposerHdrsPrivate *priv;
ENameSelectorModel *name_selector_model;
ENameSelectorEntry *name_selector_entry;
-
+
priv = hdrs->priv;
name_selector_model = e_name_selector_peek_model (priv->name_selector);
@@ -537,31 +537,31 @@ create_addressbook_entry (EMsgComposerHdrs *hdrs, const char *name)
#if 0
CORBA_exception_init (&ev);
-
+
GNOME_Evolution_Addressbook_SelectNames_addSection (
corba_select_names, name, name, &ev);
if (ev._major != CORBA_NO_EXCEPTION) {
CORBA_exception_free (&ev);
return NULL;
}
-
+
corba_control =
GNOME_Evolution_Addressbook_SelectNames_getEntryBySection (
corba_select_names, name, &ev);
-
+
if (ev._major != CORBA_NO_EXCEPTION) {
CORBA_exception_free (&ev);
return NULL;
}
-
+
CORBA_exception_free (&ev);
-
+
control_widget = bonobo_widget_new_control_from_objref (
corba_control, bonobo_ui_component_get_container (priv->uic));
-
+
cf = bonobo_widget_get_control_frame (BONOBO_WIDGET (control_widget));
pb = bonobo_control_frame_get_control_property_bag (cf, NULL);
-
+
bonobo_control_frame_set_autoactivate (cf, TRUE);
bonobo_event_source_client_add_listener (
@@ -584,7 +584,7 @@ post_browser_response (EMFolderSelector *emfs, int response, EMsgComposerHdrs *h
g_list_foreach (uris, (GFunc) g_free, NULL);
g_list_free (uris);
}
-
+
gtk_widget_destroy ((GtkWidget *) emfs);
}
@@ -595,7 +595,7 @@ post_browser_clicked_cb (GtkButton *button, EMsgComposerHdrs *hdrs)
EMFolderTree *emft;
GtkWidget *dialog;
GList *post_items;
-
+
gtk_widget_grab_focus(hdrs->priv->post_to.entry);
model = mail_component_peek_tree_model (mail_component_peek ());
emft = (EMFolderTree *) em_folder_tree_new_with_model (model);
@@ -605,12 +605,12 @@ post_browser_clicked_cb (GtkButton *button, EMsgComposerHdrs *hdrs)
dialog = em_folder_selector_new (emft, EM_FOLDER_SELECTOR_CAN_CREATE,
_("Posting destination"),
_("Choose folders to post the message to."), NULL);
-
- post_items = e_msg_composer_hdrs_get_post_to (hdrs);
+
+ post_items = e_msg_composer_hdrs_get_post_to (hdrs);
em_folder_selector_set_selected_list ((EMFolderSelector *) dialog, post_items);
g_list_foreach (post_items, (GFunc) g_free, NULL);
g_list_free (post_items);
-
+
g_signal_connect (dialog, "response", G_CALLBACK (post_browser_response), hdrs);
gtk_widget_show (dialog);
}
@@ -621,7 +621,7 @@ post_entry_changed_cb (GtkButton *button, EMsgComposerHdrs *hdrs)
hdrs->priv->post_custom = TRUE;
}
-static EMsgComposerHdrPair
+static EMsgComposerHdrPair
header_new_recipient (EMsgComposerHdrs *hdrs, const char *name, const char *tip)
{
EMsgComposerHdrPair ret;
@@ -633,14 +633,14 @@ header_new_recipient (EMsgComposerHdrs *hdrs, const char *name, const char *tip)
e_msg_composer_hdrs_and_string_create (hdrs, name),
(GClosureNotify) e_msg_composer_hdrs_and_string_free,
0);
-
+
gtk_tooltips_set_tip (hdrs->priv->tooltips, ret.label,
_("Click here for the address book"),
NULL);
-
+
ret.entry = create_addressbook_entry (hdrs, name);
ret.visible = FALSE;
-
+
return ret;
}
@@ -659,7 +659,7 @@ create_headers (EMsgComposerHdrs *hdrs)
{
EMsgComposerHdrsPrivate *priv = hdrs->priv;
AtkObject *a11y;
-
+
/*
* Reply-To:
*
@@ -670,14 +670,14 @@ create_headers (EMsgComposerHdrs *hdrs)
priv->reply_to.label = gtk_label_new_with_mnemonic (_("_Reply-To:"));
priv->reply_to.entry = gtk_entry_new ();
gtk_label_set_mnemonic_widget((GtkLabel *)priv->reply_to.label, priv->reply_to.entry);
-
+
/*
* From
*/
priv->from.label = gtk_label_new_with_mnemonic (_("Fr_om:"));
priv->from.entry = create_from_optionmenu (hdrs);
gtk_label_set_mnemonic_widget((GtkLabel *)priv->from.label, e_msg_composer_hdrs_get_from_omenu (hdrs));
-
+
/*
* Subject
*/
@@ -693,11 +693,11 @@ create_headers (EMsgComposerHdrs *hdrs)
priv->to = header_new_recipient (
hdrs, _("_To:"),
_("Enter the recipients of the message"));
-
+
priv->cc = header_new_recipient (
hdrs, _("_Cc:"),
_("Enter the addresses that will receive a carbon copy of the message"));
-
+
priv->bcc = header_new_recipient (
hdrs, _("_Bcc:"),
_("Enter the addresses that will receive a carbon copy of "
@@ -714,11 +714,11 @@ create_headers (EMsgComposerHdrs *hdrs)
gtk_tooltips_set_tip (hdrs->priv->tooltips, priv->post_to.label,
_("Click here to select folders to post to"),
NULL);
-
+
priv->post_to.entry = gtk_entry_new ();
if ((a11y = gtk_widget_get_accessible (priv->post_to.entry)))
- atk_object_set_name (a11y, _("Post To:"));
-
+ atk_object_set_name (a11y, _("Post To:"));
+
g_signal_connect(priv->post_to.entry, "changed",
G_CALLBACK (post_entry_changed_cb), hdrs);
@@ -732,7 +732,7 @@ attach_couple (EMsgComposerHdrs *hdrs, EMsgComposerHdrPair *pair, int line)
pair->label, 0, 1,
line, line + 1,
GTK_FILL, GTK_FILL, 3, 3);
-
+
if (line == LINE_TO || line == LINE_CC || line == LINE_BCC) {
gtk_table_attach (GTK_TABLE (hdrs),
pair->entry, 1, 2,
@@ -751,7 +751,7 @@ static void
attach_headers (EMsgComposerHdrs *hdrs)
{
EMsgComposerHdrsPrivate *p = hdrs->priv;
-
+
attach_couple (hdrs, &p->from, LINE_FROM);
attach_couple (hdrs, &p->reply_to, LINE_REPLYTO);
attach_couple (hdrs, &p->to, LINE_TO);
@@ -779,13 +779,13 @@ static void
headers_set_visibility (EMsgComposerHdrs *h, int visible_flags)
{
EMsgComposerHdrsPrivate *p = h->priv;
-
+
/* To is always visible if we're not doing Post-To */
if (!(h->visible_mask & E_MSG_COMPOSER_VISIBLE_POSTTO))
visible_flags |= E_MSG_COMPOSER_VISIBLE_TO;
else
visible_flags |= E_MSG_COMPOSER_VISIBLE_POSTTO;
-
+
set_pair_visibility (h, &p->from, visible_flags & E_MSG_COMPOSER_VISIBLE_FROM);
set_pair_visibility (h, &p->reply_to, visible_flags & E_MSG_COMPOSER_VISIBLE_REPLYTO);
set_pair_visibility (h, &p->to, visible_flags & E_MSG_COMPOSER_VISIBLE_TO);
@@ -802,7 +802,7 @@ headers_set_sensitivity (EMsgComposerHdrs *h)
bonobo_ui_component_set_prop (
h->priv->uic, "/commands/ViewTo", "sensitive",
h->visible_mask & E_MSG_COMPOSER_VISIBLE_TO ? "0" : "1", NULL);
-
+
bonobo_ui_component_set_prop (
h->priv->uic, "/commands/ViewPostTo", "sensitive",
h->visible_mask & E_MSG_COMPOSER_VISIBLE_POSTTO ? "0" : "1", NULL);
@@ -812,7 +812,7 @@ void
e_msg_composer_hdrs_set_visible_mask (EMsgComposerHdrs *hdrs, int visible_mask)
{
g_return_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs));
-
+
hdrs->visible_mask = visible_mask;
headers_set_sensitivity (hdrs);
}
@@ -821,7 +821,7 @@ void
e_msg_composer_hdrs_set_visible (EMsgComposerHdrs *hdrs, int visible_flags)
{
g_return_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs));
-
+
headers_set_visibility (hdrs, visible_flags);
gtk_widget_queue_resize (GTK_WIDGET (hdrs));
}
@@ -831,7 +831,7 @@ setup_headers (EMsgComposerHdrs *hdrs, int visible_flags)
{
create_headers (hdrs);
attach_headers (hdrs);
-
+
headers_set_sensitivity (hdrs);
headers_set_visibility (hdrs, visible_flags);
}
@@ -845,10 +845,10 @@ destroy (GtkObject *object)
EMsgComposerHdrs *hdrs;
EMsgComposerHdrsPrivate *priv;
GSList *l, *n;
-
+
hdrs = E_MSG_COMPOSER_HDRS (object);
priv = hdrs->priv;
-
+
if (priv) {
if (priv->name_selector != NULL) {
g_object_unref (priv->name_selector);
@@ -860,32 +860,32 @@ destroy (GtkObject *object)
g_object_unref (priv->tooltips);
priv->tooltips = NULL;
}
-
+
if (priv->accounts) {
g_signal_handlers_disconnect_matched(priv->accounts, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, hdrs);
g_object_unref (priv->accounts);
priv->accounts = NULL;
}
-
+
l = priv->from_options;
while (l) {
EAccount *account;
GtkWidget *item = l->data;
-
+
account = g_object_get_data ((GObject *) item, "account");
g_object_unref (account);
-
+
n = l->next;
g_slist_free_1 (l);
l = n;
}
-
+
priv->from_options = NULL;
-
+
g_free (priv);
hdrs->priv = NULL;
}
-
+
if (GTK_OBJECT_CLASS (parent_class)->destroy != NULL)
(* GTK_OBJECT_CLASS (parent_class)->destroy) (object);
}
@@ -895,12 +895,12 @@ static void
class_init (EMsgComposerHdrsClass *class)
{
GtkObjectClass *object_class;
-
+
object_class = GTK_OBJECT_CLASS (class);
object_class->destroy = destroy;
-
+
parent_class = g_type_class_ref (gtk_table_get_type ());
-
+
signals[SHOW_ADDRESS_DIALOG] =
g_signal_new ("show_address_dialog",
E_TYPE_MSG_COMPOSER_HDRS,
@@ -909,7 +909,7 @@ class_init (EMsgComposerHdrsClass *class)
NULL, NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
-
+
signals[SUBJECT_CHANGED] =
g_signal_new ("subject_changed",
E_TYPE_MSG_COMPOSER_HDRS,
@@ -919,7 +919,7 @@ class_init (EMsgComposerHdrsClass *class)
g_cclosure_marshal_VOID__STRING,
G_TYPE_NONE,
1, G_TYPE_STRING);
-
+
signals[HDRS_CHANGED] =
g_signal_new ("hdrs_changed",
E_TYPE_MSG_COMPOSER_HDRS,
@@ -928,7 +928,7 @@ class_init (EMsgComposerHdrsClass *class)
NULL, NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
-
+
signals[FROM_CHANGED] =
g_signal_new ("from_changed",
E_TYPE_MSG_COMPOSER_HDRS,
@@ -943,17 +943,17 @@ static void
init (EMsgComposerHdrs *hdrs)
{
EMsgComposerHdrsPrivate *priv;
-
+
priv = g_new0 (EMsgComposerHdrsPrivate, 1);
-
+
priv->tooltips = gtk_tooltips_new ();
g_object_ref_sink (priv->tooltips);
-
+
priv->accounts = mail_config_get_accounts ();
g_object_ref (priv->accounts);
priv->post_custom = FALSE;
-
+
hdrs->priv = priv;
}
@@ -962,7 +962,7 @@ GType
e_msg_composer_hdrs_get_type (void)
{
static GType type = 0;
-
+
if (type == 0) {
static const GTypeInfo info = {
sizeof (EMsgComposerHdrsClass),
@@ -975,10 +975,10 @@ e_msg_composer_hdrs_get_type (void)
0,
(GInstanceInitFunc) init,
};
-
+
type = g_type_register_static (gtk_table_get_type (), "EMsgComposerHdrs", &info, 0);
}
-
+
return type;
}
@@ -987,7 +987,7 @@ e_msg_composer_hdrs_new (BonoboUIComponent *uic, int visible_mask, int visible_f
{
EMsgComposerHdrs *new;
EMsgComposerHdrsPrivate *priv;
-
+
new = g_object_new (e_msg_composer_hdrs_get_type (), NULL);
priv = new->priv;
priv->uic = uic;
@@ -995,11 +995,11 @@ e_msg_composer_hdrs_new (BonoboUIComponent *uic, int visible_mask, int visible_f
g_object_ref_sink (new);
setup_name_selector (new);
-
+
new->visible_mask = visible_mask;
-
+
setup_headers (new, visible_flags);
-
+
return GTK_WIDGET (new);
}
@@ -1017,15 +1017,15 @@ set_recipients_from_destv (CamelMimeMessage *msg,
const char *text_addr, *header;
gboolean seen_hidden_list = FALSE;
int i;
-
+
to_addr = camel_internet_address_new ();
cc_addr = camel_internet_address_new ();
bcc_addr = camel_internet_address_new ();
-
+
if (to_destv) {
for (i = 0; to_destv[i] != NULL; ++i) {
text_addr = e_destination_get_address (to_destv[i]);
-
+
if (text_addr && *text_addr) {
target = to_addr;
if (e_destination_is_evolution_list (to_destv[i])
@@ -1033,12 +1033,12 @@ set_recipients_from_destv (CamelMimeMessage *msg,
target = bcc_addr;
seen_hidden_list = TRUE;
}
-
+
camel_address_decode (CAMEL_ADDRESS (target), text_addr);
}
}
}
-
+
if (cc_destv) {
for (i = 0; cc_destv[i] != NULL; ++i) {
text_addr = e_destination_get_address (cc_destv[i]);
@@ -1049,38 +1049,38 @@ set_recipients_from_destv (CamelMimeMessage *msg,
target = bcc_addr;
seen_hidden_list = TRUE;
}
-
+
camel_address_decode (CAMEL_ADDRESS (target), text_addr);
}
}
}
-
+
if (bcc_destv) {
for (i = 0; bcc_destv[i] != NULL; ++i) {
text_addr = e_destination_get_address (bcc_destv[i]);
- if (text_addr && *text_addr) {
+ if (text_addr && *text_addr) {
camel_address_decode (CAMEL_ADDRESS (bcc_addr), text_addr);
}
}
}
-
+
header = redirect ? CAMEL_RECIPIENT_TYPE_RESENT_TO : CAMEL_RECIPIENT_TYPE_TO;
if (camel_address_length (CAMEL_ADDRESS (to_addr)) > 0) {
camel_mime_message_set_recipients (msg, header, to_addr);
} else if (seen_hidden_list) {
camel_medium_set_header (CAMEL_MEDIUM (msg), header, "Undisclosed-Recipient:;");
}
-
+
header = redirect ? CAMEL_RECIPIENT_TYPE_RESENT_CC : CAMEL_RECIPIENT_TYPE_CC;
if (camel_address_length (CAMEL_ADDRESS (cc_addr)) > 0) {
camel_mime_message_set_recipients (msg, header, cc_addr);
}
-
+
header = redirect ? CAMEL_RECIPIENT_TYPE_RESENT_BCC : CAMEL_RECIPIENT_TYPE_BCC;
if (camel_address_length (CAMEL_ADDRESS (bcc_addr)) > 0) {
camel_mime_message_set_recipients (msg, header, bcc_addr);
}
-
+
camel_object_unref (to_addr);
camel_object_unref (cc_addr);
camel_object_unref (bcc_addr);
@@ -1098,10 +1098,10 @@ e_msg_composer_hdrs_to_message_internal (EMsgComposerHdrs *hdrs,
g_return_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs));
g_return_if_fail (CAMEL_IS_MIME_MESSAGE (msg));
-
+
subject = e_msg_composer_hdrs_get_subject (hdrs);
camel_mime_message_set_subject (msg, subject);
-
+
addr = e_msg_composer_hdrs_get_from (hdrs);
if (redirect) {
header = camel_address_encode (CAMEL_ADDRESS (addr));
@@ -1111,27 +1111,27 @@ e_msg_composer_hdrs_to_message_internal (EMsgComposerHdrs *hdrs,
camel_mime_message_set_from (msg, addr);
}
camel_object_unref (addr);
-
+
addr = e_msg_composer_hdrs_get_reply_to (hdrs);
if (addr) {
camel_mime_message_set_reply_to (msg, addr);
camel_object_unref (addr);
}
-
+
if (hdrs->priv->to.visible || hdrs->priv->cc.visible || hdrs->priv->bcc.visible) {
to_destv = e_msg_composer_hdrs_get_to (hdrs);
cc_destv = e_msg_composer_hdrs_get_cc (hdrs);
bcc_destv = e_msg_composer_hdrs_get_bcc (hdrs);
-
+
/* Attach destinations to the message. */
-
+
set_recipients_from_destv (msg, to_destv, cc_destv, bcc_destv, redirect);
-
+
e_destination_freev (to_destv);
e_destination_freev (cc_destv);
e_destination_freev (bcc_destv);
}
-
+
if (hdrs->priv->post_to.visible) {
GList *post, *l;
@@ -1173,9 +1173,9 @@ e_msg_composer_hdrs_set_from_account (EMsgComposerHdrs *hdrs,
char *uid = NULL;
GSList *l;
int i = 0;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs));
-
+
omenu = GTK_OPTION_MENU (e_msg_composer_hdrs_get_from_omenu (hdrs));
if (!account_name) {
@@ -1183,13 +1183,13 @@ e_msg_composer_hdrs_set_from_account (EMsgComposerHdrs *hdrs,
uid = gconf_client_get_string (gconf, "/apps/evolution/mail/default_account", NULL);
g_object_unref (gconf);
}
-
+
/* find the item that represents the account and activate it */
l = hdrs->priv->from_options;
while (l) {
EAccount *account;
item = l->data;
-
+
account = g_object_get_data ((GObject *) item, "account");
if (account_can_send (account)) {
if (account_name) {
@@ -1198,7 +1198,7 @@ e_msg_composer_hdrs_set_from_account (EMsgComposerHdrs *hdrs,
gtk_option_menu_set_history (omenu, i);
g_signal_emit_by_name (item, "activate", hdrs);
g_free (uid);
-
+
return;
}
} else if (uid && !strcmp (account->uid, uid)) {
@@ -1206,14 +1206,14 @@ e_msg_composer_hdrs_set_from_account (EMsgComposerHdrs *hdrs,
gtk_option_menu_set_history (omenu, i);
g_signal_emit_by_name (item, "activate", hdrs);
g_free (uid);
-
+
return;
}
}
l = l->next;
i++;
}
-
+
g_free (uid);
}
@@ -1222,9 +1222,9 @@ e_msg_composer_hdrs_set_reply_to (EMsgComposerHdrs *hdrs,
const char *reply_to)
{
g_return_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs));
-
+
gtk_entry_set_text (GTK_ENTRY (hdrs->priv->reply_to.entry), reply_to ? reply_to : "");
-
+
if (reply_to && *reply_to)
set_pair_visibility (hdrs, &hdrs->priv->cc, TRUE);
}
@@ -1271,7 +1271,7 @@ e_msg_composer_hdrs_set_cc (EMsgComposerHdrs *hdrs,
g_return_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs));
destinations_to_name_selector_entry (E_NAME_SELECTOR_ENTRY (hdrs->priv->cc.entry), cc_destv);
-
+
if (cc_destv && *cc_destv)
set_pair_visibility (hdrs, &hdrs->priv->cc, TRUE);
}
@@ -1283,7 +1283,7 @@ e_msg_composer_hdrs_set_bcc (EMsgComposerHdrs *hdrs,
g_return_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs));
destinations_to_name_selector_entry (E_NAME_SELECTOR_ENTRY (hdrs->priv->bcc.entry), bcc_destv);
-
+
if (bcc_destv && *bcc_destv)
set_pair_visibility (hdrs, &hdrs->priv->bcc, TRUE);
}
@@ -1294,14 +1294,14 @@ e_msg_composer_hdrs_set_post_to (EMsgComposerHdrs *hdrs,
const char *post_to)
{
GList *list;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs));
g_return_if_fail (post_to != NULL);
-
+
list = g_list_append (NULL, g_strdup (post_to));
-
+
e_msg_composer_hdrs_set_post_to_list (hdrs, list);
-
+
g_free (list->data);
g_list_free (list);
}
@@ -1310,22 +1310,22 @@ static GList *
newsgroups_list_split (const char *list)
{
GList *lst = NULL;
- char *tmp;
+ char *tmp;
char **items, **cur_ptr;
-
+
cur_ptr = items = g_strsplit (list, ",", 0);
-
+
while ((tmp = *cur_ptr) != NULL) {
g_strstrip (tmp);
-
+
if (tmp[0])
lst = g_list_append (lst, g_strdup (tmp));
-
+
cur_ptr++;
}
-
+
g_strfreev (items);
-
+
return lst;
}
@@ -1334,7 +1334,7 @@ get_account_store_url (EMsgComposerHdrs *hdrs)
{
CamelURL *url;
char *ret = NULL;
-
+
if (hdrs->account->source
&& hdrs->account->source->url
&& hdrs->account->source->url[0]
@@ -1342,27 +1342,27 @@ get_account_store_url (EMsgComposerHdrs *hdrs)
ret = camel_url_to_string (url, CAMEL_URL_HIDE_ALL);
camel_url_free (url);
}
-
+
return ret;
-}
+}
static char *
folder_name_to_string (EMsgComposerHdrs *hdrs, const char *uri)
{
char *storeurl = get_account_store_url (hdrs);
int len;
-
+
if (storeurl) {
len = strlen (storeurl);
-
+
if (g_ascii_strncasecmp (uri, storeurl, len) == 0) {
g_free (storeurl);
return g_strdup (uri + len);
}
-
+
g_free (storeurl);
}
-
+
return g_strdup (uri);
}
@@ -1372,7 +1372,7 @@ e_msg_composer_hdrs_set_post_to_list (EMsgComposerHdrs *hdrs, GList *urls)
GString *caption;
char *tmp;
gboolean post_custom;
-
+
if (hdrs->priv->post_to.entry == NULL)
return;
@@ -1384,10 +1384,10 @@ e_msg_composer_hdrs_set_post_to_list (EMsgComposerHdrs *hdrs, GList *urls)
g_string_append(caption, ", ");
g_string_append(caption, tmp);
}
-
+
urls = g_list_next (urls);
}
-
+
post_custom = hdrs->priv->post_custom;
gtk_entry_set_text(GTK_ENTRY(hdrs->priv->post_to.entry), caption->str);
hdrs->priv->post_custom = post_custom;
@@ -1402,11 +1402,11 @@ e_msg_composer_hdrs_set_post_to_base (EMsgComposerHdrs *hdrs, const char *base,
char *tmp, *tmp2;
gboolean post_custom;
GString *caption;
-
+
/* split to newsgroup names */
lst = newsgroups_list_split(post_to);
curlist = lst;
-
+
caption = g_string_new("");
while (curlist) {
/* FIXME: this doens't handle all folder names properly */
@@ -1420,7 +1420,7 @@ e_msg_composer_hdrs_set_post_to_base (EMsgComposerHdrs *hdrs, const char *base,
}
curlist = g_list_next(curlist);
}
-
+
post_custom = hdrs->priv->post_custom;
gtk_entry_set_text(GTK_ENTRY(hdrs->priv->post_to.entry), caption->str);
hdrs->priv->post_custom = post_custom;
@@ -1436,7 +1436,7 @@ e_msg_composer_hdrs_set_subject (EMsgComposerHdrs *hdrs,
{
g_return_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs));
g_return_if_fail (subject != NULL);
-
+
gtk_entry_set_text ((GtkEntry *) hdrs->priv->subject.entry, subject);
}
@@ -1448,15 +1448,15 @@ e_msg_composer_hdrs_get_from (EMsgComposerHdrs *hdrs)
EAccount *account;
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
if (!(account = hdrs->account)) {
/* FIXME: perhaps we should try the default account? */
return NULL;
}
-
+
addr = camel_internet_address_new ();
camel_internet_address_add (addr, account->id->name, account->id->address);
-
+
return addr;
}
@@ -1465,20 +1465,20 @@ e_msg_composer_hdrs_get_reply_to (EMsgComposerHdrs *hdrs)
{
CamelInternetAddress *addr;
const char *reply_to;
-
+
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
reply_to = gtk_entry_get_text (GTK_ENTRY (hdrs->priv->reply_to.entry));
-
+
if (!reply_to || *reply_to == '\0')
return NULL;
-
+
addr = camel_internet_address_new ();
if (camel_address_unformat (CAMEL_ADDRESS (addr), reply_to) == -1) {
camel_object_unref (CAMEL_OBJECT (addr));
return NULL;
}
-
+
return addr;
}
@@ -1510,7 +1510,7 @@ e_msg_composer_hdrs_get_internal (EMsgComposerHdrs *hdrs, ENameSelectorEntry *en
EDestinationStore *destination_store;
GList *destinations;
EDestination **destv = NULL;
-
+
destination_store = e_name_selector_entry_peek_destination_store (entry);
destinations = e_destination_store_list_destinations (destination_store);
@@ -1552,42 +1552,42 @@ e_msg_composer_hdrs_get_recipients (EMsgComposerHdrs *hdrs)
EDestination **bcc_destv;
EDestination **recip_destv;
int i, j, n;
-
+
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
to_destv = e_msg_composer_hdrs_get_to (hdrs);
cc_destv = e_msg_composer_hdrs_get_cc (hdrs);
bcc_destv = e_msg_composer_hdrs_get_bcc (hdrs);
-
+
n = 0;
-
+
for (i = 0; to_destv && to_destv[i] != NULL; i++, n++);
for (i = 0; cc_destv && cc_destv[i] != NULL; i++, n++);
for (i = 0; bcc_destv && bcc_destv[i] != NULL; i++, n++);
-
+
if (n == 0)
return NULL;
-
+
recip_destv = g_new (EDestination *, n + 1);
-
+
j = 0;
-
+
for (i = 0; to_destv && to_destv[i] != NULL; i++, j++)
recip_destv[j] = to_destv[i];
for (i = 0; cc_destv && cc_destv[i] != NULL; i++, j++)
recip_destv[j] = cc_destv[i];
for (i = 0; bcc_destv && bcc_destv[i] != NULL; i++, j++)
recip_destv[j] = bcc_destv[i];
-
+
if (j != n) {
g_warning ("j!=n \n");
}
recip_destv[j] = NULL;
-
+
g_free (to_destv);
g_free (cc_destv);
g_free (bcc_destv);
-
+
return recip_destv;
}
@@ -1597,16 +1597,16 @@ e_msg_composer_hdrs_get_post_to (EMsgComposerHdrs *hdrs)
{
GList *uris, *cur;
char *storeurl = NULL, *tmp;
-
+
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
if (hdrs->priv->post_to.entry == NULL)
return NULL;
-
+
tmp = g_strdup (gtk_entry_get_text (GTK_ENTRY (hdrs->priv->post_to.entry)));
uris = newsgroups_list_split (tmp);
g_free (tmp);
-
+
cur = uris;
while (cur) {
/* FIXME: this is a bit of a hack, should use camelurl's etc */
@@ -1620,12 +1620,12 @@ e_msg_composer_hdrs_get_post_to (EMsgComposerHdrs *hdrs)
g_free (cur->data);
cur->data = tmp;
}
-
+
cur = cur->next;
}
-
+
g_free (storeurl);
-
+
return uris;
}
@@ -1634,7 +1634,7 @@ const char *
e_msg_composer_hdrs_get_subject (EMsgComposerHdrs *hdrs)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
return gtk_entry_get_text ((GtkEntry *) hdrs->priv->subject.entry);
}
@@ -1643,7 +1643,7 @@ GtkWidget *
e_msg_composer_hdrs_get_reply_to_entry (EMsgComposerHdrs *hdrs)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
return hdrs->priv->reply_to.entry;
}
@@ -1651,7 +1651,7 @@ GtkWidget *
e_msg_composer_hdrs_get_to_entry (EMsgComposerHdrs *hdrs)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
return hdrs->priv->to.entry;
}
@@ -1659,7 +1659,7 @@ GtkWidget *
e_msg_composer_hdrs_get_cc_entry (EMsgComposerHdrs *hdrs)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
return hdrs->priv->cc.entry;
}
@@ -1667,7 +1667,7 @@ GtkWidget *
e_msg_composer_hdrs_get_bcc_entry (EMsgComposerHdrs *hdrs)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
return hdrs->priv->bcc.entry;
}
@@ -1675,7 +1675,7 @@ GtkWidget *
e_msg_composer_hdrs_get_post_to_label (EMsgComposerHdrs *hdrs)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
return hdrs->priv->post_to.entry;
}
@@ -1683,7 +1683,7 @@ GtkWidget *
e_msg_composer_hdrs_get_subject_entry (EMsgComposerHdrs *hdrs)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
return hdrs->priv->subject.entry;
}
@@ -1691,7 +1691,7 @@ GtkWidget *
e_msg_composer_hdrs_get_from_hbox (EMsgComposerHdrs *hdrs)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
return hdrs->priv->from.entry;
}
@@ -1699,7 +1699,7 @@ GtkWidget *
e_msg_composer_hdrs_get_from_omenu (EMsgComposerHdrs *hdrs)
{
g_return_val_if_fail (E_IS_MSG_COMPOSER_HDRS (hdrs), NULL);
-
+
return GTK_WIDGET (g_object_get_data ((GObject *) hdrs->priv->from.entry, "from_menu"));
}
diff --git a/composer/e-msg-composer-hdrs.h b/composer/e-msg-composer-hdrs.h
index 2888c5daa7..919400167d 100644
--- a/composer/e-msg-composer-hdrs.h
+++ b/composer/e-msg-composer-hdrs.h
@@ -51,13 +51,13 @@ typedef struct _EMsgComposerHdrsPrivate EMsgComposerHdrsPrivate;
struct _EMsgComposerHdrs {
GtkTable parent;
-
+
EMsgComposerHdrsPrivate *priv;
-
+
EAccount *account;
-
+
guint32 visible_mask;
-
+
gboolean has_changed;
};
diff --git a/composer/e-msg-composer-select-file.c b/composer/e-msg-composer-select-file.c
index 1d02f2bd8a..4cf92a661e 100644
--- a/composer/e-msg-composer-select-file.c
+++ b/composer/e-msg-composer-select-file.c
@@ -59,9 +59,9 @@ get_selector(struct _EMsgComposer *composer, const char *title, guint32 flags)
GtkWidget *showinline = NULL;
GList *icon_list;
char *path;
-
+
path = g_object_get_data ((GObject *) composer, "attach_path");
-
+
if (flags & SELECTOR_MODE_SAVE)
selection = gtk_file_chooser_dialog_new (title,
NULL,
@@ -76,37 +76,37 @@ get_selector(struct _EMsgComposer *composer, const char *title, guint32 flags)
GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
_("A_ttach"), GTK_RESPONSE_OK,
NULL);
-
+
gtk_dialog_set_default_response (GTK_DIALOG (selection), GTK_RESPONSE_OK);
gtk_file_chooser_set_local_only (GTK_FILE_CHOOSER (selection), FALSE);
-
+
if ((flags & SELECTOR_MODE_SAVE) == 0)
gtk_file_chooser_set_select_multiple ((GtkFileChooser *) selection, (flags & SELECTOR_MODE_MULTI));
-
+
/* restore last path used */
if (!path)
gtk_file_chooser_set_current_folder (GTK_FILE_CHOOSER (selection), g_get_home_dir ());
else
gtk_file_chooser_set_current_folder (GTK_FILE_CHOOSER (selection), path);
-
+
if (flags & SELECTOR_SHOW_INLINE) {
showinline = gtk_check_button_new_with_mnemonic (_("_Suggest automatic display of attachment"));
gtk_widget_show (showinline);
gtk_file_chooser_set_extra_widget (GTK_FILE_CHOOSER (selection), showinline);
g_object_set_data((GObject *)selection, "show-inline", showinline);
}
-
+
gtk_window_set_transient_for ((GtkWindow *) selection, (GtkWindow *) composer);
gtk_window_set_wmclass ((GtkWindow *) selection, "fileselection", "Evolution:composer");
gtk_window_set_modal ((GtkWindow *) selection, FALSE);
-
+
icon_list = e_icon_factory_get_icon_list ("mail-message-new");
if (icon_list) {
gtk_window_set_icon_list (GTK_WINDOW (selection), icon_list);
g_list_foreach (icon_list, (GFunc) g_object_unref, NULL);
g_list_free (icon_list);
}
-
+
return selection;
}
@@ -143,7 +143,7 @@ select_file_response(GtkWidget *selector, guint response, struct _EMsgComposer *
void e_msg_composer_select_file(struct _EMsgComposer *composer, GtkWidget **w, EMsgComposerSelectFileFunc func, const char *title, int save)
{
if (*w) {
- gtk_window_present((GtkWindow *)*w);
+ gtk_window_present((GtkWindow *)*w);
return;
}
@@ -163,7 +163,7 @@ select_attach_response(GtkWidget *selector, guint response, struct _EMsgComposer
EMsgComposerSelectAttachFunc func = g_object_get_data((GObject *)selector, "callback");
GtkToggleButton *showinline = g_object_get_data((GObject *)selector, "show-inline");
char *path = NULL;
-
+
char *filename = NULL;
names = gtk_file_chooser_get_uris (GTK_FILE_CHOOSER (selector));
filename = gtk_file_chooser_get_filename (GTK_FILE_CHOOSER (selector));
@@ -175,7 +175,7 @@ select_attach_response(GtkWidget *selector, guint response, struct _EMsgComposer
g_object_set_data_full ((GObject *) composer, "attach_path", path, g_free);
func(composer, names, gtk_toggle_button_get_active(showinline));
-
+
e_msg_composer_show_attachments_ui (composer);
@@ -189,7 +189,7 @@ select_attach_response(GtkWidget *selector, guint response, struct _EMsgComposer
void e_msg_composer_select_file_attachments(struct _EMsgComposer *composer, GtkWidget **w, EMsgComposerSelectAttachFunc func)
{
if (*w) {
- gtk_window_present((GtkWindow *)*w);
+ gtk_window_present((GtkWindow *)*w);
return;
}
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index f5b639dde0..eb4cac1e8b 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -23,7 +23,7 @@
* Jeffrey Stedfast (fejj@ximian.com)
* Miguel de Icaza (miguel@ximian.com)
* Radek Doulik (rodo@ximian.com)
- *
+ *
*/
/*
@@ -86,7 +86,7 @@
#include "misc/e-expander.h"
#include "e-util/e-error.h"
#include "e-util/e-util-private.h"
-#include <mail/em-event.h>
+#include <mail/em-event.h>
#include <camel/camel-session.h>
#include <camel/camel-charset-map.h>
@@ -138,13 +138,13 @@ typedef struct _EMsgComposerPrivate EMsgComposerPrivate;
struct _EMsgComposer {
BonoboWindow parent;
-
+
EMsgComposerPrivate *priv;
};
struct _EMsgComposerClass {
BonoboWindowClass parent_class;
-
+
void (* send) (EMsgComposer *composer);
void (* save_draft) (EMsgComposer *composer, int quit);
};
@@ -158,36 +158,36 @@ struct _EMsgComposerPrivate {
/* UIComponent for the non-control GtkEntries */
BonoboUIComponent *entry_uic;
-
+
GtkWidget *hdrs;
GPtrArray *extra_hdr_names, *extra_hdr_values;
-
+
GtkWidget *focused_entry;
-
+
GtkWidget *eeditor;
-
+
GtkWidget *attachment_bar;
GtkWidget *attachment_scrolled_window;
GtkWidget *attachment_expander;
GtkWidget *attachment_expander_label;
GtkWidget *attachment_expander_icon;
GtkWidget *attachment_expander_num;
-
+
GtkWidget *address_dialog;
-
+
Bonobo_PersistFile persist_file_interface;
Bonobo_PersistStream persist_stream_interface;
GNOME_GtkHTML_Editor_Engine eeditor_engine;
BonoboObject *eeditor_listener;
GHashTable *inline_images, *inline_images_by_url;
GList *current_images;
-
+
char *mime_type, *mime_body, *charset;
-
+
char *autosave_file;
int autosave_fd;
guint32 enable_autosave : 1;
-
+
guint32 attachment_bar_visible : 1;
guint32 send_html : 1;
guint32 is_alternative : 1;
@@ -206,22 +206,22 @@ struct _EMsgComposerPrivate {
guint32 set_priority : 1;
guint32 has_changed : 1;
guint32 autosaved : 1;
-
+
guint32 mode_post : 1;
-
+
guint32 in_signature_insert : 1;
-
+
struct _ESignature *signature;
struct _GtkOptionMenu *sig_menu;
guint sig_added_id;
guint sig_removed_id;
guint sig_changed_id;
-
+
CamelMimeMessage *redirect;
-
+
guint notify_id;
- gboolean send_invoked;
+ gboolean send_invoked;
EMMenu *menu;
GtkWidget *saveas; /* saveas async file requester */
@@ -306,13 +306,13 @@ destination_list_to_vector_sized (GList *list, int n)
{
EDestination **destv;
int i = 0;
-
+
if (n == -1)
n = g_list_length (list);
-
+
if (n == 0)
return NULL;
-
+
destv = g_new (EDestination *, n + 1);
while (list != NULL && i < n) {
destv[i] = E_DESTINATION (list->data);
@@ -321,7 +321,7 @@ destination_list_to_vector_sized (GList *list, int n)
list = g_list_next (list);
}
destv[i] = NULL;
-
+
return destv;
}
@@ -338,9 +338,9 @@ get_text (Bonobo_PersistStream persist, char *format)
BonoboStreamMem *stream_mem;
CORBA_Environment ev;
GByteArray *text;
-
+
CORBA_exception_init (&ev);
-
+
stream = bonobo_stream_mem_create (NULL, 0, FALSE, TRUE);
Bonobo_PersistStream_save (persist, (Bonobo_Stream)bonobo_object_corba_objref (BONOBO_OBJECT (stream)),
format, &ev);
@@ -349,14 +349,14 @@ get_text (Bonobo_PersistStream persist, char *format)
bonobo_exception_get_text (&ev));
return NULL;
}
-
+
CORBA_exception_free (&ev);
-
+
stream_mem = BONOBO_STREAM_MEM (stream);
text = g_byte_array_new ();
g_byte_array_append (text, (const guint8 *)stream_mem->buffer, stream_mem->pos);
bonobo_object_unref (BONOBO_OBJECT (stream));
-
+
return text;
}
@@ -369,14 +369,14 @@ best_encoding (GByteArray *buf, const char *charset)
size_t inlen, outlen;
int status, count = 0;
iconv_t cd;
-
+
if (!charset)
return -1;
-
+
cd = e_iconv_open (charset, "utf-8");
if (cd == (iconv_t) -1)
return -1;
-
+
in = (char*)buf->data;
inlen = buf->len;
do {
@@ -389,10 +389,10 @@ best_encoding (GByteArray *buf, const char *charset)
}
} while (status == (size_t) -1 && errno == E2BIG);
e_iconv_close (cd);
-
+
if (status == (size_t) -1 || status > 0)
return -1;
-
+
if (count == 0)
return CAMEL_TRANSFER_ENCODING_7BIT;
else if (count <= buf->len * 0.17)
@@ -407,10 +407,10 @@ composer_get_default_charset_setting (void)
GConfClient *gconf;
const char *locale;
char *charset;
-
+
gconf = gconf_client_get_default ();
charset = gconf_client_get_string (gconf, "/apps/evolution/mail/composer/charset", NULL);
-
+
if (!charset || charset[0] == '\0') {
g_free (charset);
charset = gconf_client_get_string (gconf, "/apps/evolution/mail/format/charset", NULL);
@@ -419,12 +419,12 @@ composer_get_default_charset_setting (void)
charset = NULL;
}
}
-
+
g_object_unref (gconf);
-
+
if (!charset && (locale = e_iconv_locale_charset ()))
charset = g_strdup (locale);
-
+
return charset ? charset : g_strdup ("us-ascii");
}
@@ -432,31 +432,31 @@ static char *
best_charset (GByteArray *buf, const char *default_charset, CamelTransferEncoding *encoding)
{
char *charset;
-
+
/* First try US-ASCII */
*encoding = best_encoding (buf, "US-ASCII");
if (*encoding == CAMEL_TRANSFER_ENCODING_7BIT)
return NULL;
-
+
/* Next try the user-specified charset for this message */
*encoding = best_encoding (buf, default_charset);
if (*encoding != -1)
return g_strdup (default_charset);
-
+
/* Now try the user's default charset from the mail config */
charset = composer_get_default_charset_setting ();
*encoding = best_encoding (buf, charset);
if (*encoding != -1)
return charset;
-
+
/* Try to find something that will work */
if (!(charset = (char *) camel_charset_best ((const gchar *)buf->data, buf->len))) {
*encoding = CAMEL_TRANSFER_ENCODING_7BIT;
return NULL;
}
-
+
*encoding = best_encoding (buf, charset);
-
+
return g_strdup (charset);
}
@@ -522,17 +522,17 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
GByteArray *data;
char *charset;
int i;
-
+
if (p->persist_stream_interface == CORBA_OBJECT_NIL)
return NULL;
-
+
/* evil kludgy hack for Redirect */
if (p->redirect) {
e_msg_composer_hdrs_to_redirect (hdrs, p->redirect);
camel_object_ref (p->redirect);
return p->redirect;
}
-
+
new = camel_mime_message_new ();
e_msg_composer_hdrs_to_message (hdrs, new);
for (i = 0; i < p->extra_hdr_names->len; i++) {
@@ -546,14 +546,14 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
char *mdn_address = hdrs->account->id->reply_to;
if (!mdn_address || !*mdn_address)
mdn_address = hdrs->account->id->address;
-
+
camel_medium_add_header (CAMEL_MEDIUM (new), "Disposition-Notification-To", mdn_address);
}
/* Message Priority */
- if (p->set_priority)
+ if (p->set_priority)
camel_medium_add_header (CAMEL_MEDIUM (new), "X-Priority", "1");
-
+
if (p->mime_body) {
plain_encoding = CAMEL_TRANSFER_ENCODING_7BIT;
for (i = 0; p->mime_body[i]; i++) {
@@ -572,7 +572,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
camel_object_unref (CAMEL_OBJECT (new));
return NULL;
}
-
+
/* FIXME: we may want to do better than this... */
type = camel_content_type_new ("text", "plain");
@@ -582,35 +582,35 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
g_free (charset);
}
}
-
+
stream = camel_stream_mem_new_with_byte_array (data);
-
+
/* convert the stream to the appropriate charset */
if (iconv_charset && g_ascii_strcasecmp (iconv_charset, "UTF-8") != 0) {
CamelStreamFilter *filter_stream;
CamelMimeFilterCharset *filter;
-
+
filter_stream = camel_stream_filter_new_with_stream (stream);
camel_object_unref (stream);
-
+
stream = (CamelStream *) filter_stream;
filter = camel_mime_filter_charset_new_convert ("UTF-8", iconv_charset);
camel_stream_filter_add (filter_stream, (CamelMimeFilter *) filter);
camel_object_unref (filter);
}
-
+
/* construct the content object */
plain = camel_data_wrapper_new ();
camel_data_wrapper_construct_from_stream (plain, stream);
camel_object_unref (stream);
-
+
camel_data_wrapper_set_mime_type_field (plain, type);
camel_content_type_unref (type);
-
+
if (p->send_html) {
CORBA_Environment ev;
clear_current_images (composer);
-
+
if (save_html_object_data) {
CORBA_exception_init (&ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "save-data-on", &ev);
@@ -620,79 +620,79 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "save-data-off", &ev);
CORBA_exception_free (&ev);
}
-
+
if (!data) {
/* The component has probably died */
camel_object_unref (new);
camel_object_unref (plain);
return NULL;
}
-
+
html = camel_data_wrapper_new ();
-
+
stream = camel_stream_mem_new_with_byte_array (data);
camel_data_wrapper_construct_from_stream (html, stream);
camel_object_unref (stream);
camel_data_wrapper_set_mime_type (html, "text/html; charset=utf-8");
-
+
/* Build the multipart/alternative */
body = camel_multipart_new ();
camel_data_wrapper_set_mime_type (CAMEL_DATA_WRAPPER (body),
"multipart/alternative");
camel_multipart_set_boundary (body, NULL);
-
+
part = camel_mime_part_new ();
camel_medium_set_content_object (CAMEL_MEDIUM (part), plain);
camel_object_unref (plain);
camel_mime_part_set_encoding (part, plain_encoding);
camel_multipart_add_part (body, part);
camel_object_unref (part);
-
+
part = camel_mime_part_new ();
camel_medium_set_content_object (CAMEL_MEDIUM (part), html);
camel_object_unref (html);
camel_multipart_add_part (body, part);
camel_object_unref (part);
-
+
/* If there are inlined images, construct a
* multipart/related containing the
* multipart/alternative and the images.
*/
if (p->current_images) {
CamelMultipart *html_with_images;
-
+
html_with_images = camel_multipart_new ();
camel_data_wrapper_set_mime_type (
CAMEL_DATA_WRAPPER (html_with_images),
"multipart/related; type=\"multipart/alternative\"");
camel_multipart_set_boundary (html_with_images, NULL);
-
+
part = camel_mime_part_new ();
camel_medium_set_content_object (CAMEL_MEDIUM (part), CAMEL_DATA_WRAPPER (body));
camel_object_unref (body);
camel_multipart_add_part (html_with_images, part);
camel_object_unref (part);
-
+
add_inlined_images (composer, html_with_images);
clear_current_images (composer);
-
+
current = CAMEL_DATA_WRAPPER (html_with_images);
} else
current = CAMEL_DATA_WRAPPER (body);
} else
current = plain;
-
+
if (e_attachment_bar_get_num_attachments (attachment_bar)) {
CamelMultipart *multipart = camel_multipart_new ();
-
+
if (p->is_alternative) {
camel_data_wrapper_set_mime_type (CAMEL_DATA_WRAPPER (multipart),
"multipart/alternative");
}
-
+
/* Generate a random boundary. */
camel_multipart_set_boundary (multipart, NULL);
-
+
part = camel_mime_part_new ();
camel_medium_set_content_object (CAMEL_MEDIUM (part), current);
if (current == plain)
@@ -700,19 +700,19 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
camel_object_unref (current);
camel_multipart_add_part (multipart, part);
camel_object_unref (part);
-
+
e_attachment_bar_to_multipart (attachment_bar, multipart, p->charset);
-
+
if (p->is_alternative) {
for (i = camel_multipart_get_number (multipart); i > 1; i--) {
part = camel_multipart_get_part (multipart, i - 1);
camel_medium_remove_header (CAMEL_MEDIUM (part), "Content-Disposition");
}
}
-
+
current = CAMEL_DATA_WRAPPER (multipart);
}
-
+
camel_exception_init (&ex);
/* Setup working recipient list if we're encrypting */
@@ -735,7 +735,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
}
}
-
+
if (p->pgp_sign || p->pgp_encrypt) {
const char *pgp_userid;
CamelInternetAddress *from = NULL;
@@ -753,14 +753,14 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
from = e_msg_composer_hdrs_get_from(hdrs);
camel_internet_address_get(from, 0, NULL, &pgp_userid);
}
-
+
if (p->pgp_sign) {
CamelMimePart *npart = camel_mime_part_new();
cipher = mail_crypto_get_pgp_cipher_context(hdrs->account);
camel_cipher_sign(cipher, pgp_userid, CAMEL_CIPHER_HASH_SHA1, part, npart, &ex);
camel_object_unref(cipher);
-
+
if (camel_exception_is_set(&ex)) {
camel_object_unref(npart);
goto exception;
@@ -769,7 +769,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
camel_object_unref(part);
part = npart;
}
-
+
if (p->pgp_encrypt) {
CamelMimePart *npart = camel_mime_part_new();
@@ -794,13 +794,13 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
}
if (from)
- camel_object_unref (from);
-
+ camel_object_unref (from);
+
current = camel_medium_get_content_object (CAMEL_MEDIUM (part));
camel_object_ref (current);
camel_object_unref (part);
}
-
+
#if defined (HAVE_NSS) && defined (SMIME_SUPPORTED)
if (p->smime_sign || p->smime_encrypt) {
CamelInternetAddress *from = NULL;
@@ -818,7 +818,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
_("Cannot sign outgoing message: No signing certificate set for this account"));
goto exception;
}
-
+
if (p->smime_encrypt
&& (hdrs->account == NULL || hdrs->account->smime_sign_key == NULL || hdrs->account->smime_sign_key[0] == 0)) {
camel_exception_set (&ex, CAMEL_EXCEPTION_SYSTEM,
@@ -841,7 +841,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
camel_cipher_sign(cipher, hdrs->account->smime_sign_key, CAMEL_CIPHER_HASH_SHA1, part, npart, &ex);
camel_object_unref(cipher);
-
+
if (camel_exception_is_set(&ex)) {
camel_object_unref(npart);
goto exception;
@@ -850,7 +850,7 @@ build_message (EMsgComposer *composer, gboolean save_html_object_data)
camel_object_unref(part);
part = npart;
}
-
+
if (p->smime_encrypt) {
/* check to see if we should encrypt to self, NB removed after use */
if (hdrs->account->smime_encrypt_to_self)
@@ -901,16 +901,16 @@ skip_content:
/* Attach whether this message was written in HTML */
camel_medium_set_header (CAMEL_MEDIUM (new), "X-Evolution-Format",
p->send_html ? "text/html" : "text/plain");
-
+
return new;
-
+
exception:
-
+
if (part != CAMEL_MIME_PART (new))
camel_object_unref (part);
-
+
camel_object_unref (new);
-
+
if (ex.id != CAMEL_EXCEPTION_USER_CANCEL) {
e_error_run((GtkWindow *)composer, "mail-composer:no-build-message",
camel_exception_get_description(&ex), NULL);
@@ -923,7 +923,7 @@ skip_content:
g_free(recipients->pdata[i]);
g_ptr_array_free(recipients, TRUE);
}
-
+
return NULL;
}
@@ -939,7 +939,7 @@ get_file_content (EMsgComposer *composer, const char *file_name, gboolean want_h
char *charset;
char *content;
int fd;
-
+
fd = g_open (file_name, O_RDONLY, 0);
if (fd == -1) {
if (warn)
@@ -947,27 +947,27 @@ get_file_content (EMsgComposer *composer, const char *file_name, gboolean want_h
file_name, g_strerror(errno), NULL);
return g_strdup ("");
}
-
+
stream = camel_stream_fs_new_with_fd (fd);
-
+
if (want_html) {
filtered_stream = camel_stream_filter_new_with_stream (stream);
camel_object_unref (stream);
-
+
html = camel_mime_filter_tohtml_new (flags, 0);
camel_stream_filter_add (filtered_stream, html);
camel_object_unref (html);
-
+
stream = (CamelStream *) filtered_stream;
}
-
+
memstream = (CamelStreamMem *) camel_stream_mem_new ();
buffer = g_byte_array_new ();
camel_stream_mem_set_byte_array (memstream, buffer);
-
+
camel_stream_write_to_stream (stream, (CamelStream *) memstream);
camel_object_unref (stream);
-
+
/* The newer signature UI saves signatures in UTF-8, but we still need to check that
the signature is valid UTF-8 because it is possible that the user imported a
signature file that is in his/her locale charset. If it's not in UTF-8 and not in
@@ -977,32 +977,32 @@ get_file_content (EMsgComposer *composer, const char *file_name, gboolean want_h
stream = (CamelStream *) memstream;
memstream = (CamelStreamMem *) camel_stream_mem_new ();
camel_stream_mem_set_byte_array (memstream, g_byte_array_new ());
-
+
filtered_stream = camel_stream_filter_new_with_stream (stream);
camel_object_unref (stream);
-
+
charset = composer && composer->priv->charset ? composer->priv->charset : NULL;
charset = charset ? g_strdup (charset) : composer_get_default_charset_setting ();
if ((charenc = (CamelMimeFilter *) camel_mime_filter_charset_new_convert (charset, "UTF-8"))) {
camel_stream_filter_add (filtered_stream, charenc);
camel_object_unref (charenc);
}
-
+
g_free (charset);
-
+
camel_stream_write_to_stream ((CamelStream *) filtered_stream, (CamelStream *) memstream);
camel_object_unref (filtered_stream);
g_byte_array_free (buffer, TRUE);
-
+
buffer = memstream->buffer;
}
-
+
camel_object_unref (memstream);
-
+
g_byte_array_append (buffer, (const guint8 *)"", 1);
content = (char*)buffer->data;
g_byte_array_free (buffer, FALSE);
-
+
return content;
}
@@ -1012,7 +1012,7 @@ e_msg_composer_get_sig_file_content (const char *sigfile, gboolean in_html)
if (!sigfile || !*sigfile) {
return NULL;
}
-
+
return get_file_content (NULL, sigfile, !in_html,
CAMEL_MIME_FILTER_TOHTML_PRESERVE_8BIT |
CAMEL_MIME_FILTER_TOHTML_CONVERT_URLS |
@@ -1026,16 +1026,16 @@ prepare_engine (EMsgComposer *composer)
{
CORBA_Environment ev;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
/* printf ("prepare_engine\n"); */
-
+
CORBA_exception_init (&ev);
p->eeditor_engine = (GNOME_GtkHTML_Editor_Engine) Bonobo_Unknown_queryInterface
(bonobo_widget_get_objref (BONOBO_WIDGET (p->eeditor)), "IDL:GNOME/GtkHTML/Editor/Engine:1.0", &ev);
if ((p->eeditor_engine != CORBA_OBJECT_NIL) && (ev._major == CORBA_NO_EXCEPTION)) {
-
+
/* printf ("trying set listener\n"); */
p->eeditor_listener = BONOBO_OBJECT (listener_new (composer));
if (p->eeditor_listener != NULL)
@@ -1045,12 +1045,12 @@ prepare_engine (EMsgComposer *composer)
(bonobo_object_corba_objref (p->eeditor_listener),
&ev),
&ev);
-
+
if ((ev._major != CORBA_NO_EXCEPTION) || (p->eeditor_listener == NULL)) {
CORBA_Environment err_ev;
CORBA_exception_init (&err_ev);
-
+
Bonobo_Unknown_unref (p->eeditor_engine, &err_ev);
CORBA_Object_release (p->eeditor_engine, &err_ev);
@@ -1108,7 +1108,7 @@ encode_signature_name (const char *name)
s ++;
}
*e = 0;
-
+
return ename;
}
@@ -1165,16 +1165,16 @@ get_signature_html (EMsgComposer *composer)
EMsgComposerPrivate *p = composer->priv;
char *text = NULL, *html = NULL;
gboolean format_html;
-
+
if (!p->signature)
return NULL;
-
+
if (!p->signature->autogen) {
if (!p->signature->filename)
return NULL;
-
+
format_html = p->signature->html;
-
+
if (p->signature->script) {
text = mail_config_signature_run_script (p->signature->filename);
} else {
@@ -1185,12 +1185,12 @@ get_signature_html (EMsgComposer *composer)
char *organization;
char *address;
char *name;
-
+
id = E_MSG_COMPOSER_HDRS (p->hdrs)->account->id;
address = id->address ? camel_text_to_html (id->address, CONVERT_SPACES, 0) : NULL;
name = id->name ? camel_text_to_html (id->name, CONVERT_SPACES, 0) : NULL;
organization = id->organization ? camel_text_to_html (id->organization, CONVERT_SPACES, 0) : NULL;
-
+
text = g_strdup_printf ("-- <BR>%s%s%s%s%s%s%s%s",
name ? name : "",
(address && *address) ? " &lt;<A HREF=\"mailto:" : "",
@@ -1205,14 +1205,14 @@ get_signature_html (EMsgComposer *composer)
g_free (organization);
format_html = TRUE;
}
-
+
/* printf ("text: %s\n", text); */
if (text) {
char *encoded_uid = NULL;
-
+
if (p->signature)
encoded_uid = encode_signature_name (p->signature->uid);
-
+
/* The signature dash convention ("-- \n") is specified in the
* "Son of RFC 1036": http://www.chemie.fu-berlin.de/outerspace/netnews/son-of-1036.html,
* section 4.3.2.
@@ -1231,7 +1231,7 @@ get_signature_html (EMsgComposer *composer)
g_free (encoded_uid);
text = html;
}
-
+
return text;
}
@@ -1248,22 +1248,22 @@ set_editor_text(EMsgComposer *composer, const char *text, ssize_t len, int set_s
GConfClient *gconf;
g_return_if_fail (p->persist_stream_interface != CORBA_OBJECT_NIL);
-
+
persist = p->persist_stream_interface;
-
+
CORBA_exception_init (&ev);
-
+
gconf = gconf_client_get_default ();
-
- /*
- Keeping Signatures in the beginning of composer
+ /*
+
+ Keeping Signatures in the beginning of composer
------------------------------------------------
- Purists are gonna blast me for this.
- But there are so many people (read Outlook users) who want this.
+ Purists are gonna blast me for this.
+ But there are so many people (read Outlook users) who want this.
And Evo is an exchange-client, Outlook-replacement etc.
- So Here it goes :(
+ So Here it goes :(
-- Sankar
@@ -1279,7 +1279,7 @@ set_editor_text(EMsgComposer *composer, const char *text, ssize_t len, int set_s
if (tmp) {
/* Minimizing the damage. Make it just a part of the body instead of a signature */
html = strstr (tmp, "-- \n");
- if (html) {
+ if (html) {
/* That two consecutive - symbols followed by a space */
*(html+1) = ' ';
body = g_strdup_printf ("</br>%s</br>%s", tmp, text);
@@ -1311,11 +1311,11 @@ set_editor_text(EMsgComposer *composer, const char *text, ssize_t len, int set_s
CORBA_exception_free (&ev);
return;
}
-
+
CORBA_exception_free (&ev);
-
+
bonobo_object_unref (BONOBO_OBJECT (stream));
-
+
if (set_signature && !reply_signature_on_top)
e_msg_composer_show_sig_file (composer);
}
@@ -1323,18 +1323,18 @@ set_editor_text(EMsgComposer *composer, const char *text, ssize_t len, int set_s
/* Commands. */
static void
-show_attachments (EMsgComposer *composer,
- gboolean show)
+show_attachments (EMsgComposer *composer,
+ gboolean show)
{
EMsgComposerPrivate *p = composer->priv;
e_expander_set_expanded (E_EXPANDER (p->attachment_expander), show);
- if (show)
- gtk_label_set_text_with_mnemonic (GTK_LABEL (composer->priv->attachment_expander_label),
- _("Hide _Attachment Bar"));
- else
- gtk_label_set_text_with_mnemonic (GTK_LABEL (composer->priv->attachment_expander_label),
- _("Show _Attachment Bar"));
+ if (show)
+ gtk_label_set_text_with_mnemonic (GTK_LABEL (composer->priv->attachment_expander_label),
+ _("Hide _Attachment Bar"));
+ else
+ gtk_label_set_text_with_mnemonic (GTK_LABEL (composer->priv->attachment_expander_label),
+ _("Show _Attachment Bar"));
}
static void
@@ -1343,12 +1343,12 @@ save (EMsgComposer *composer, const char *filename)
EMsgComposerPrivate *p = composer->priv;
CORBA_Environment ev;
int fd;
-
+
/* check to see if we already have the file and that we can create it */
if ((fd = g_open (filename, O_RDONLY | O_CREAT | O_EXCL, 0777)) == -1) {
int resp, errnosav = errno;
struct stat st;
-
+
if (g_stat (filename, &st) == 0 && S_ISREG (st.st_mode)) {
resp = e_error_run((GtkWindow *)composer, E_ERROR_ASK_FILE_EXISTS_OVERWRITE, filename, NULL);
if (resp != GTK_RESPONSE_OK)
@@ -1359,11 +1359,11 @@ save (EMsgComposer *composer, const char *filename)
}
} else
close (fd);
-
+
CORBA_exception_init (&ev);
-
+
Bonobo_PersistFile_save (p->persist_file_interface, filename, &ev);
-
+
if (ev._major != CORBA_NO_EXCEPTION) {
e_error_run((GtkWindow *)composer, E_ERROR_NO_SAVE_FILE,
filename, _("Unknown reason"));
@@ -1393,15 +1393,15 @@ load (EMsgComposer *composer, const char *file_name)
{
EMsgComposerPrivate *p = composer->priv;
CORBA_Environment ev;
-
+
CORBA_exception_init (&ev);
-
+
Bonobo_PersistFile_load (p->persist_file_interface, file_name, &ev);
-
+
if (ev._major != CORBA_NO_EXCEPTION)
e_error_run((GtkWindow *)composer, E_ERROR_NO_LOAD_FILE,
file_name, _("Unknown reason"), NULL);
-
+
CORBA_exception_free (&ev);
}
@@ -1428,28 +1428,28 @@ autosave_save_draft (EMsgComposer *composer)
char *file;
int fd, camelfd;
gboolean success = TRUE;
-
+
if (!e_msg_composer_is_dirty (composer))
return TRUE;
fd = p->autosave_fd;
file = p->autosave_file;
-
+
if (fd == -1) {
/* This code is odd, the fd is opened elsewhere but a failure is ignored */
e_error_run((GtkWindow *)composer, "mail-composer:no-autosave",
file, _("Could not open file"), NULL);
return FALSE;
}
-
+
message = e_msg_composer_get_message_draft (composer);
-
+
if (message == NULL) {
e_error_run((GtkWindow *)composer, "mail-composer:no-autosave",
file, _("Unable to retrieve message from editor"), NULL);
return FALSE;
}
-
+
if (lseek (fd, (off_t)0, SEEK_SET) == -1
|| ftruncate (fd, (off_t)0) == -1
|| (camelfd = dup(fd)) == -1) {
@@ -1458,7 +1458,7 @@ autosave_save_draft (EMsgComposer *composer)
file, g_strerror(errno), NULL);
return FALSE;
}
-
+
/* this does an lseek so we don't have to */
stream = camel_stream_fs_new_with_fd (camelfd);
if (camel_data_wrapper_write_to_stream (CAMEL_DATA_WRAPPER (message), stream) == -1
@@ -1474,46 +1474,46 @@ autosave_save_draft (EMsgComposer *composer)
e_msg_composer_unset_changed (composer);
e_msg_composer_set_autosaved (composer);
}
-
+
camel_object_unref (stream);
-
+
camel_object_unref (message);
-
+
return success;
}
-static EMsgComposer *
+static EMsgComposer *
autosave_load_draft (const char *filename)
{
CamelStream *stream;
CamelMimeMessage *msg;
EMsgComposer *composer;
-
+
g_return_val_if_fail (filename != NULL, NULL);
-
+
g_warning ("autosave load filename = \"%s\"", filename);
-
+
if (!(stream = camel_stream_fs_new_with_name (filename, O_RDONLY, 0)))
return NULL;
-
+
msg = camel_mime_message_new ();
camel_data_wrapper_construct_from_stream (CAMEL_DATA_WRAPPER (msg), stream);
camel_object_unref (stream);
-
+
composer = e_msg_composer_new_with_message (msg);
if (composer) {
if (autosave_save_draft (composer))
g_unlink (filename);
-
+
g_signal_connect (GTK_OBJECT (composer), "send",
G_CALLBACK (em_utils_composer_send_cb), NULL);
-
+
g_signal_connect (GTK_OBJECT (composer), "save-draft",
G_CALLBACK (em_utils_composer_save_draft_cb), NULL);
-
+
gtk_widget_show (GTK_WIDGET (composer));
}
-
+
return composer;
}
@@ -1538,7 +1538,7 @@ autosave_manager_query_load_orphans (AutosaveManager *am, GtkWindow *parent)
if (!dir) {
return;
}
-
+
while ((dname = g_dir_read_name (dir))) {
if ((!strncmp (dname, AUTOSAVE_SEED, len - 6))
&& (strlen (dname) == len)
@@ -1547,9 +1547,9 @@ autosave_manager_query_load_orphans (AutosaveManager *am, GtkWindow *parent)
struct stat st;
filename = g_build_filename (dirname, dname, NULL);
-
+
/*
- * check if the file has any length, It is a valid case if it doesn't
+ * check if the file has any length, It is a valid case if it doesn't
* so we simply don't ask then.
*/
if (g_stat (filename, &st) == -1 || st.st_size == 0) {
@@ -1557,32 +1557,32 @@ autosave_manager_query_load_orphans (AutosaveManager *am, GtkWindow *parent)
g_free (filename);
continue;
}
- match = g_slist_prepend (match, filename);
+ match = g_slist_prepend (match, filename);
}
}
-
+
g_dir_close (dir);
g_free (dirname);
-
+
if (match != NULL)
load = e_error_run(parent, "mail-composer:recover-autosave", NULL) == GTK_RESPONSE_YES;
-
+
while (match != NULL) {
GSList *next = match->next;
char *filename = match->data;
EMsgComposer *composer;
-
+
if (load) {
- /* FIXME: composer is never used */
+ /* FIXME: composer is never used */
composer = autosave_load_draft (filename);
} else {
g_unlink (filename);
}
-
+
g_free (filename);
g_slist_free_1 (match);
match = next;
- }
+ }
}
static void
@@ -1590,7 +1590,7 @@ autosave_run_foreach_cb (gpointer key, gpointer value, gpointer data)
{
EMsgComposer *composer = E_MSG_COMPOSER (value);
EMsgComposerPrivate *p = composer->priv;
-
+
if (p->enable_autosave)
autosave_save_draft (composer);
}
@@ -1599,12 +1599,12 @@ static gint
autosave_run (gpointer data)
{
AutosaveManager *am = data;
-
+
g_hash_table_foreach (am->table, (GHFunc)autosave_run_foreach_cb, am);
autosave_manager_stop (am);
autosave_manager_start (am);
-
+
return FALSE;
}
@@ -1647,23 +1647,23 @@ autosave_manager_new (void)
g_str_hash, g_str_equal,
(GDestroyNotify) g_free,
(GDestroyNotify) NULL);
-
+
am = g_new (AutosaveManager, 1);
am->table = table;
am->id = 0;
am->ask = TRUE;
-
+
return am;
}
static void
-autosave_manager_register (AutosaveManager *am, EMsgComposer *composer)
+autosave_manager_register (AutosaveManager *am, EMsgComposer *composer)
{
char *key;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (composer != NULL);
-
+
if (autosave_init_file (composer)) {
key = g_path_get_basename (p->autosave_file);
g_hash_table_insert (am->table, key, composer);
@@ -1678,7 +1678,7 @@ autosave_manager_register (AutosaveManager *am, EMsgComposer *composer)
}
static void
-autosave_manager_unregister (AutosaveManager *am, EMsgComposer *composer)
+autosave_manager_unregister (AutosaveManager *am, EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
gchar *key;
@@ -1689,7 +1689,7 @@ autosave_manager_unregister (AutosaveManager *am, EMsgComposer *composer)
key = g_path_get_basename (p->autosave_file);
g_hash_table_remove (am->table, key);
g_free (key);
-
+
/* only remove the file if we can successfully save it */
/* FIXME this test could probably be more efficient */
if (autosave_save_draft (composer)) {
@@ -1701,7 +1701,7 @@ autosave_manager_unregister (AutosaveManager *am, EMsgComposer *composer)
}
g_free (p->autosave_file);
p->autosave_file = NULL;
-
+
if (g_hash_table_size (am->table) == 0)
autosave_manager_stop (am);
}
@@ -1722,14 +1722,14 @@ do_exit (EMsgComposer *composer)
const char *subject;
int button;
EMsgComposerPrivate *p = composer->priv;
-
+
if (!e_msg_composer_is_dirty (composer) && !e_msg_composer_is_autosaved (composer)) {
gtk_widget_destroy (GTK_WIDGET (composer));
return;
}
-
+
gdk_window_raise (GTK_WIDGET (composer)->window);
-
+
subject = e_msg_composer_hdrs_get_subject (E_MSG_COMPOSER_HDRS (p->hdrs));
button = e_error_run((GtkWindow *)composer, "mail-composer:exit-unsaved",
@@ -1781,11 +1781,11 @@ menu_file_save_cb (BonoboUIComponent *uic,
EMsgComposerPrivate *p = composer->priv;
CORBA_char *file_name;
CORBA_Environment ev;
-
+
CORBA_exception_init (&ev);
-
+
file_name = Bonobo_PersistFile_getCurrentFile (p->persist_file_interface, &ev);
-
+
if (ev._major != CORBA_NO_EXCEPTION) {
saveas (composer);
} else {
@@ -1817,7 +1817,7 @@ menu_file_close_cb (BonoboUIComponent *uic,
const char *path)
{
EMsgComposer *composer;
-
+
composer = E_MSG_COMPOSER (data);
do_exit (composer);
}
@@ -1829,7 +1829,7 @@ menu_help_cb (BonoboUIComponent *uic,
const char *path)
{
EMsgComposer *composer = (EMsgComposer *) data;
-
+
e_msg_composer_show_help (composer);
}
@@ -1841,21 +1841,21 @@ add_to_bar (EMsgComposer *composer, GSList *names, int is_inline)
while (names) {
CamelURL *url;
-
+
if (!(url = camel_url_new (names->data, NULL)))
continue;
-
- if (!g_ascii_strcasecmp (url->protocol, "file")) {
+
+ if (!g_ascii_strcasecmp (url->protocol, "file")) {
e_attachment_bar_attach((EAttachmentBar *)p->attachment_bar, url->path, is_inline ? "inline" : "attachment");
} else {
- e_attachment_bar_attach_remote_file ((EAttachmentBar *)p->attachment_bar, names->data, is_inline ? "inline" : "attachment");
+ e_attachment_bar_attach_remote_file ((EAttachmentBar *)p->attachment_bar, names->data, is_inline ? "inline" : "attachment");
}
-
+
camel_url_free (url);
names = names->next;
}
}
-
+
static void
menu_file_add_attachment_cb (BonoboUIComponent *uic,
void *data,
@@ -1874,9 +1874,9 @@ menu_edit_cut_cb (BonoboUIComponent *uic, void *data, const char *path)
{
EMsgComposer *composer = data;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (p->focused_entry != NULL);
-
+
if (GTK_IS_ENTRY (p->focused_entry)) {
gtk_editable_cut_clipboard (GTK_EDITABLE (p->focused_entry));
} else {
@@ -1892,7 +1892,7 @@ menu_edit_copy_cb (BonoboUIComponent *uic, void *data, const char *path)
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (p->focused_entry != NULL);
-
+
if (GTK_IS_ENTRY (p->focused_entry)) {
gtk_editable_copy_clipboard (GTK_EDITABLE (p->focused_entry));
} else {
@@ -1906,9 +1906,9 @@ menu_edit_paste_cb (BonoboUIComponent *uic, void *data, const char *path)
{
EMsgComposer *composer = data;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (p->focused_entry != NULL);
-
+
if (GTK_IS_ENTRY (p->focused_entry)) {
gtk_editable_paste_clipboard (GTK_EDITABLE (p->focused_entry));
} else {
@@ -1925,10 +1925,10 @@ menu_send_options_cb (BonoboUIComponent *component, void *data, const char *path
EMsgComposer *composer = data;
target = em_event_target_new_composer (e, composer, EM_EVENT_COMPOSER_SEND_OPTION);
- e_msg_composer_set_send_options (composer, FALSE);
+ e_msg_composer_set_send_options (composer, FALSE);
e_event_emit((EEvent *)e, "composer.selectsendoption", (EEventTarget *)target);
if (!composer->priv->send_invoked) {
- e_error_run ((GtkWindow *)composer, "mail-composer:send-options-support", NULL);
+ e_error_run ((GtkWindow *)composer, "mail-composer:send-options-support", NULL);
}
}
@@ -1939,7 +1939,7 @@ menu_edit_select_all_cb (BonoboUIComponent *uic, void *data, const char *path)
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (p->focused_entry != NULL);
-
+
if (GTK_IS_ENTRY (p->focused_entry)) {
gtk_editable_set_position (GTK_EDITABLE (p->focused_entry), -1);
gtk_editable_select_region (GTK_EDITABLE (p->focused_entry), 0, -1);
@@ -1957,7 +1957,7 @@ menu_edit_delete_all_cb (BonoboUIComponent *uic, void *data, const char *path)
CORBA_Environment ev;
CORBA_exception_init (&ev);
-
+
GNOME_GtkHTML_Editor_Engine_undoBegin (p->eeditor_engine, "Delete all but signature", "Undelete all", &ev);
GNOME_GtkHTML_Editor_Engine_freeze (p->eeditor_engine, &ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "disable-selection", &ev);
@@ -1974,7 +1974,7 @@ menu_edit_delete_all_cb (BonoboUIComponent *uic, void *data, const char *path)
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "style-normal", &ev);
GNOME_GtkHTML_Editor_Engine_thaw (p->eeditor_engine, &ev);
GNOME_GtkHTML_Editor_Engine_undoEnd (p->eeditor_engine, &ev);
-
+
CORBA_exception_free (&ev);
/* printf ("delete all\n"); */
}
@@ -1989,7 +1989,7 @@ menu_format_html_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_send_html (E_MSG_COMPOSER (user_data), atoi (state));
}
@@ -2003,7 +2003,7 @@ menu_security_pgp_sign_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_pgp_sign (E_MSG_COMPOSER (composer), atoi (state));
}
@@ -2017,7 +2017,7 @@ menu_security_pgp_encrypt_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_pgp_encrypt (E_MSG_COMPOSER (composer), atoi (state));
}
@@ -2031,7 +2031,7 @@ menu_security_smime_sign_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_smime_sign (E_MSG_COMPOSER (composer), atoi (state));
}
@@ -2045,7 +2045,7 @@ menu_security_smime_encrypt_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_smime_encrypt (E_MSG_COMPOSER (composer), atoi (state));
}
@@ -2059,7 +2059,7 @@ menu_view_from_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_view_from (E_MSG_COMPOSER (user_data), atoi (state));
}
@@ -2072,7 +2072,7 @@ menu_view_replyto_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_view_replyto (E_MSG_COMPOSER (user_data), atoi (state));
}
@@ -2085,7 +2085,7 @@ menu_view_to_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_view_to (E_MSG_COMPOSER (user_data), atoi (state));
}
@@ -2098,7 +2098,7 @@ menu_view_postto_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_view_postto (E_MSG_COMPOSER (user_data), atoi (state));
}
@@ -2111,7 +2111,7 @@ menu_view_cc_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_view_cc (E_MSG_COMPOSER (user_data), atoi (state));
}
@@ -2124,7 +2124,7 @@ menu_view_bcc_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_view_bcc (E_MSG_COMPOSER (user_data), atoi (state));
}
@@ -2137,7 +2137,7 @@ menu_insert_receipt_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_request_receipt (E_MSG_COMPOSER (user_data), atoi (state));
}
@@ -2150,7 +2150,7 @@ menu_insert_priority_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
e_msg_composer_set_priority (E_MSG_COMPOSER (user_data), atoi (state));
}
@@ -2163,7 +2163,7 @@ menu_changed_charset_cb (BonoboUIComponent *component,
{
if (type != Bonobo_UIComponent_STATE_CHANGED)
return;
-
+
if (atoi (state)) {
EMsgComposer *composer = E_MSG_COMPOSER (user_data);
EMsgComposerPrivate *p = composer->priv;
@@ -2181,14 +2181,14 @@ static BonoboUIVerb verbs [] = {
BONOBO_UI_VERB ("FileSaveAs", menu_file_save_as_cb),
BONOBO_UI_VERB ("FileSaveDraft", menu_file_save_draft_cb),
BONOBO_UI_VERB ("FileClose", menu_file_close_cb),
- BONOBO_UI_VERB ("Help", menu_help_cb),
+ BONOBO_UI_VERB ("Help", menu_help_cb),
BONOBO_UI_VERB ("FileAttach", menu_file_add_attachment_cb),
-
+
BONOBO_UI_VERB ("FileSend", menu_file_send_cb),
-
+
BONOBO_UI_VERB ("DeleteAll", menu_edit_delete_all_cb),
BONOBO_UI_VERB ("InsertXSendOptions", menu_send_options_cb),
-
+
BONOBO_UI_VERB_END
};
@@ -2200,11 +2200,11 @@ static EPixmap pixcache [] = {
E_PIXMAP ("/commands/FileSave", "document-save", E_ICON_SIZE_MENU),
E_PIXMAP ("/commands/FileSaveAs", "document-save-as", E_ICON_SIZE_MENU),
E_PIXMAP ("/commands/FileSend", "mail-send", E_ICON_SIZE_MENU),
-
+
E_PIXMAP ("/Toolbar/FileSend", "mail-send", E_ICON_SIZE_LARGE_TOOLBAR),
E_PIXMAP ("/Toolbar/FileSaveDraft", "document-save", E_ICON_SIZE_LARGE_TOOLBAR) ,
E_PIXMAP ("/Toolbar/FileAttach", "mail-attachment", E_ICON_SIZE_LARGE_TOOLBAR),
-
+
E_PIXMAP_END
};
@@ -2215,10 +2215,10 @@ signature_activate_cb (GtkWidget *menu, EMsgComposer *composer)
GtkWidget *active;
ESignature *sig;
EMsgComposerPrivate *p = composer->priv;
-
+
active = gtk_menu_get_active (GTK_MENU (menu));
sig = g_object_get_data ((GObject *) active, "sig");
-
+
if (p->signature != sig) {
p->signature = sig;
e_msg_composer_show_sig_file (composer);
@@ -2230,16 +2230,16 @@ signature_added (ESignatureList *signatures, ESignature *sig, EMsgComposer *comp
{
GtkWidget *menu, *item;
EMsgComposerPrivate *p = composer->priv;
-
+
menu = gtk_option_menu_get_menu (p->sig_menu);
-
+
if (sig->autogen)
item = gtk_menu_item_new_with_label (_("Autogenerated"));
else
item = gtk_menu_item_new_with_label (sig->name);
g_object_set_data ((GObject *) item, "sig", sig);
gtk_widget_show (item);
-
+
gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
}
@@ -2250,12 +2250,12 @@ signature_removed (ESignatureList *signatures, ESignature *sig, EMsgComposer *co
ESignature *cur;
GList *items;
EMsgComposerPrivate *p = composer->priv;
-
+
if (p->signature == sig) {
p->signature = NULL;
e_msg_composer_show_sig_file (composer);
}
-
+
menu = gtk_option_menu_get_menu (p->sig_menu);
items = GTK_MENU_SHELL (menu)->children;
while (items != NULL) {
@@ -2272,7 +2272,7 @@ static void
menu_item_set_label (GtkMenuItem *item, const char *label)
{
GtkWidget *widget;
-
+
widget = gtk_bin_get_child ((GtkBin *) item);
if (GTK_IS_LABEL (widget))
gtk_label_set_text ((GtkLabel *) widget, label);
@@ -2285,7 +2285,7 @@ signature_changed (ESignatureList *signatures, ESignature *sig, EMsgComposer *co
ESignature *cur;
GList *items;
EMsgComposerPrivate *p = composer->priv;
-
+
menu = gtk_option_menu_get_menu (p->sig_menu);
items = GTK_MENU_SHELL (menu)->children;
while (items != NULL) {
@@ -2306,12 +2306,12 @@ sig_select_item (EMsgComposer *composer)
GList *items;
int i = 0;
EMsgComposerPrivate *p = composer->priv;
-
+
if (!p->signature) {
gtk_option_menu_set_history (p->sig_menu, 0);
return;
}
-
+
menu = gtk_option_menu_get_menu (p->sig_menu);
items = GTK_MENU_SHELL (menu)->children;
while (items != NULL) {
@@ -2334,7 +2334,7 @@ setup_signatures_menu (EMsgComposer *composer)
ESignature *sig;
EIterator *it;
EMsgComposerPrivate *p = composer->priv;
-
+
hbox = e_msg_composer_hdrs_get_from_hbox (E_MSG_COMPOSER_HDRS (p->hdrs));
label = gtk_label_new_with_mnemonic (_("Si_gnature:"));
@@ -2349,31 +2349,31 @@ setup_signatures_menu (EMsgComposer *composer)
hspace = gtk_hbox_new (FALSE, 0);
gtk_widget_show (hspace);
gtk_box_pack_start (GTK_BOX (hbox), hspace, FALSE, FALSE, 0);
-
+
menu = gtk_menu_new ();
gtk_widget_show (menu);
gtk_option_menu_set_menu (p->sig_menu, menu);
-
+
item = gtk_menu_item_new_with_label (_("None"));
gtk_widget_show (item);
-
+
gtk_menu_shell_append (GTK_MENU_SHELL (menu), item);
-
+
signatures = mail_config_get_signatures ();
it = e_list_get_iterator ((EList *) signatures);
-
+
while (e_iterator_is_valid (it)) {
sig = (ESignature *) e_iterator_get (it);
signature_added (signatures, sig, composer);
e_iterator_next (it);
}
-
+
g_object_unref (it);
-
+
g_signal_connect (menu, "selection-done", G_CALLBACK (signature_activate_cb), composer);
gtk_widget_show ((GtkWidget *) p->sig_menu);
-
+
p->sig_added_id = g_signal_connect (signatures, "signature-added", G_CALLBACK (signature_added), composer);
p->sig_removed_id = g_signal_connect (signatures, "signature-removed", G_CALLBACK (signature_removed), composer);
p->sig_changed_id = g_signal_connect (signatures, "signature-changed", G_CALLBACK (signature_changed), composer);
@@ -2388,25 +2388,25 @@ setup_ui (EMsgComposer *composer)
gboolean hide_smime;
char *charset;
char *xmlfile;
-
+
container = bonobo_window_get_ui_container (BONOBO_WINDOW (composer));
-
+
p->uic = bonobo_ui_component_new_default ();
/* FIXME: handle bonobo exceptions */
bonobo_ui_component_set_container (p->uic, bonobo_object_corba_objref (BONOBO_OBJECT (container)), NULL);
-
+
bonobo_ui_component_add_verb_list_with_data (p->uic, verbs, composer);
-
+
bonobo_ui_component_freeze (p->uic, NULL);
-
+
xmlfile = g_build_filename (EVOLUTION_UIDIR, "evolution-message-composer.xml", NULL);
bonobo_ui_util_set_ui (p->uic, PREFIX,
xmlfile,
"evolution-message-composer", NULL);
g_free (xmlfile);
-
+
e_pixmaps_update (p->uic, pixcache);
-
+
/* Populate the Charset Encoding menu and default it to whatever the user
chose as his default charset in the mailer */
charset = composer_get_default_charset_setting ();
@@ -2415,7 +2415,7 @@ setup_ui (EMsgComposer *composer)
menu_changed_charset_cb,
composer);
g_free (charset);
-
+
/* Format -> HTML */
bonobo_ui_component_set_prop (
p->uic, "/commands/FormatHtml",
@@ -2431,7 +2431,7 @@ setup_ui (EMsgComposer *composer)
bonobo_ui_component_add_listener (
p->uic, "ViewFrom",
menu_view_from_cb, composer);
-
+
/* View/ReplyTo */
bonobo_ui_component_set_prop (
p->uic, "/commands/ViewReplyTo",
@@ -2439,7 +2439,7 @@ setup_ui (EMsgComposer *composer)
bonobo_ui_component_add_listener (
p->uic, "ViewReplyTo",
menu_view_replyto_cb, composer);
-
+
/* View/To */
bonobo_ui_component_set_prop (
p->uic, "/commands/ViewTo",
@@ -2447,7 +2447,7 @@ setup_ui (EMsgComposer *composer)
bonobo_ui_component_add_listener (
p->uic, "ViewTo",
menu_view_to_cb, composer);
-
+
/* View/PostTo */
bonobo_ui_component_set_prop (
p->uic, "/commands/ViewPostTo",
@@ -2455,7 +2455,7 @@ setup_ui (EMsgComposer *composer)
bonobo_ui_component_add_listener (
p->uic, "ViewPostTo",
menu_view_postto_cb, composer);
-
+
/* View/CC */
bonobo_ui_component_set_prop (
p->uic, "/commands/ViewCC",
@@ -2463,7 +2463,7 @@ setup_ui (EMsgComposer *composer)
bonobo_ui_component_add_listener (
p->uic, "ViewCC",
menu_view_cc_cb, composer);
-
+
/* View/BCC */
bonobo_ui_component_set_prop (
p->uic, "/commands/ViewBCC",
@@ -2479,7 +2479,7 @@ setup_ui (EMsgComposer *composer)
bonobo_ui_component_add_listener (
p->uic, "RequestReceipt",
menu_insert_receipt_cb, composer);
-
+
/* Insert/Exchange Send Options */
/* bonobo_ui_component_set_prop (
p->uic, "/commands/XSendOptions",
@@ -2495,31 +2495,31 @@ setup_ui (EMsgComposer *composer)
bonobo_ui_component_add_listener (
p->uic, "SetPriority",
menu_insert_priority_cb, composer);
-
+
/* Security -> PGP Sign */
bonobo_ui_component_set_prop (
p->uic, "/commands/SecurityPGPSign",
"state", p->pgp_sign ? "1" : "0", NULL);
-
+
bonobo_ui_component_add_listener (
p->uic, "SecurityPGPSign",
menu_security_pgp_sign_cb, composer);
-
+
/* Security -> PGP Encrypt */
bonobo_ui_component_set_prop (
p->uic, "/commands/SecurityPGPEncrypt",
"state", p->pgp_encrypt ? "1" : "0", NULL);
-
+
bonobo_ui_component_add_listener (
p->uic, "SecurityPGPEncrypt",
menu_security_pgp_encrypt_cb, composer);
-
+
#if defined(HAVE_NSS) && defined(SMIME_SUPPORTED)
hide_smime = FALSE;
#else
hide_smime = TRUE;
#endif
-
+
/* Security -> S/MIME Sign */
bonobo_ui_component_set_prop (
p->uic, "/commands/SecuritySMimeSign",
@@ -2527,11 +2527,11 @@ setup_ui (EMsgComposer *composer)
bonobo_ui_component_set_prop (
p->uic, "/commands/SecuritySMimeSign",
"hidden", hide_smime ? "1" : "0", NULL);
-
+
bonobo_ui_component_add_listener (
p->uic, "SecuritySMimeSign",
menu_security_smime_sign_cb, composer);
-
+
/* Security -> S/MIME Encrypt */
bonobo_ui_component_set_prop (
p->uic, "/commands/SecuritySMimeEncrypt",
@@ -2539,11 +2539,11 @@ setup_ui (EMsgComposer *composer)
bonobo_ui_component_set_prop (
p->uic, "/commands/SecuritySMimeEncrypt",
"hidden", hide_smime ? "1" : "0", NULL);
-
+
bonobo_ui_component_add_listener (
p->uic, "SecuritySMimeEncrypt",
menu_security_smime_encrypt_cb, composer);
-
+
bonobo_ui_component_thaw (p->uic, NULL);
/* Create the UIComponent for the non-control entries */
@@ -2580,29 +2580,29 @@ attachment_bar_changed_cb (EAttachmentBar *bar,
show_attachments (composer, TRUE);
} else {
gtk_label_set_text (GTK_LABEL (p->attachment_expander_num), "");
- gtk_widget_hide (p->attachment_expander_icon);
+ gtk_widget_hide (p->attachment_expander_icon);
show_attachments (composer, FALSE);
}
-
-
+
+
/* Mark the composer as changed so it prompts about unsaved
changes on close */
e_msg_composer_set_changed (composer);
}
static void
-attachment_expander_activate_cb (EExpander *expander,
- void *data)
-{
- EMsgComposer *composer = E_MSG_COMPOSER (data);
- gboolean show = e_expander_get_expanded (expander);
-
- /* Update the expander label */
- if (show)
- gtk_label_set_text_with_mnemonic (GTK_LABEL (composer->priv->attachment_expander_label),
- _("Hide _Attachment Bar"));
- else
- gtk_label_set_text_with_mnemonic (GTK_LABEL (composer->priv->attachment_expander_label),
- _("Show _Attachment Bar"));
+attachment_expander_activate_cb (EExpander *expander,
+ void *data)
+{
+ EMsgComposer *composer = E_MSG_COMPOSER (data);
+ gboolean show = e_expander_get_expanded (expander);
+
+ /* Update the expander label */
+ if (show)
+ gtk_label_set_text_with_mnemonic (GTK_LABEL (composer->priv->attachment_expander_label),
+ _("Hide _Attachment Bar"));
+ else
+ gtk_label_set_text_with_mnemonic (GTK_LABEL (composer->priv->attachment_expander_label),
+ _("Show _Attachment Bar"));
}
static void
subject_changed_cb (EMsgComposerHdrs *hdrs,
@@ -2610,9 +2610,9 @@ subject_changed_cb (EMsgComposerHdrs *hdrs,
void *data)
{
EMsgComposer *composer;
-
+
composer = E_MSG_COMPOSER (data);
-
+
gtk_window_set_title (GTK_WINDOW (composer), subject[0] ? subject : _("Compose Message"));
}
@@ -2621,9 +2621,9 @@ hdrs_changed_cb (EMsgComposerHdrs *hdrs,
void *data)
{
EMsgComposer *composer;
-
+
composer = E_MSG_COMPOSER (data);
-
+
/* Mark the composer as changed so it prompts about unsaved changes on close */
e_msg_composer_set_changed (composer);
}
@@ -2640,31 +2640,31 @@ update_auto_recipients (EMsgComposerHdrs *hdrs, int mode, const char *auto_addrs
CamelInternetAddress *iaddr;
GList *list, *tail, *node;
int i, n = 0;
-
+
tail = list = NULL;
-
+
if (auto_addrs) {
iaddr = camel_internet_address_new ();
if (camel_address_decode (CAMEL_ADDRESS (iaddr), auto_addrs) != -1) {
for (i = 0; i < camel_address_length (CAMEL_ADDRESS (iaddr)); i++) {
const char *name, *addr;
-
+
if (!camel_internet_address_get (iaddr, i, &name, &addr))
continue;
-
+
dest = e_destination_new ();
e_destination_set_auto_recipient (dest, TRUE);
-
+
if (name)
e_destination_set_name (dest, name);
-
+
if (addr)
e_destination_set_email (dest, addr);
-
+
node = g_list_alloc ();
node->data = dest;
node->next = NULL;
-
+
if (tail) {
node->prev = tail;
tail->next = node;
@@ -2672,15 +2672,15 @@ update_auto_recipients (EMsgComposerHdrs *hdrs, int mode, const char *auto_addrs
node->prev = NULL;
list = node;
}
-
+
tail = node;
n++;
}
}
-
+
camel_object_unref (iaddr);
}
-
+
switch (mode) {
case UPDATE_AUTO_CC:
destv = e_msg_composer_hdrs_get_cc (hdrs);
@@ -2691,14 +2691,14 @@ update_auto_recipients (EMsgComposerHdrs *hdrs, int mode, const char *auto_addrs
default:
g_return_if_reached ();
}
-
+
if (destv) {
for (i = 0; destv[i]; i++) {
if (!e_destination_is_auto_recipient (destv[i])) {
node = g_list_alloc ();
node->data = e_destination_copy (destv[i]);
node->next = NULL;
-
+
if (tail) {
node->prev = tail;
tail->next = node;
@@ -2706,18 +2706,18 @@ update_auto_recipients (EMsgComposerHdrs *hdrs, int mode, const char *auto_addrs
node->prev = NULL;
list = node;
}
-
+
tail = node;
n++;
}
}
-
+
e_destination_freev (destv);
}
-
+
destv = destination_list_to_vector_sized (list, n);
g_list_free (list);
-
+
switch (mode) {
case UPDATE_AUTO_CC:
e_msg_composer_hdrs_set_cc (hdrs, destv);
@@ -2728,7 +2728,7 @@ update_auto_recipients (EMsgComposerHdrs *hdrs, int mode, const char *auto_addrs
default:
g_return_if_reached ();
}
-
+
e_destination_freev (destv);
}
@@ -2737,10 +2737,10 @@ from_changed_cb (EMsgComposerHdrs *hdrs, void *data)
{
EMsgComposer *composer = E_MSG_COMPOSER (data);
EMsgComposerPrivate *p = composer->priv;
-
+
if (hdrs->account) {
EAccount *account = hdrs->account;
-
+
e_msg_composer_set_pgp_sign (composer,
account->pgp_always_sign &&
(!account->pgp_no_imip_sign || !p->mime_type ||
@@ -2753,7 +2753,7 @@ from_changed_cb (EMsgComposerHdrs *hdrs, void *data)
update_auto_recipients (hdrs, UPDATE_AUTO_CC, NULL);
update_auto_recipients (hdrs, UPDATE_AUTO_BCC, NULL);
}
-
+
set_editor_signature (composer);
e_msg_composer_show_sig_file (composer);
}
@@ -2769,10 +2769,10 @@ composer_finalise (GObject *object)
composer = E_MSG_COMPOSER (object);
p = composer->priv;
-
+
if (p->extra_hdr_names) {
int i;
-
+
for (i = 0; i < p->extra_hdr_names->len; i++) {
g_free (p->extra_hdr_names->pdata[i]);
g_free (p->extra_hdr_values->pdata[i]);
@@ -2780,23 +2780,23 @@ composer_finalise (GObject *object)
g_ptr_array_free (p->extra_hdr_names, TRUE);
g_ptr_array_free (p->extra_hdr_values, TRUE);
}
-
+
g_hash_table_destroy (p->inline_images);
g_hash_table_destroy (p->inline_images_by_url);
-
+
g_free (p->charset);
g_free (p->mime_type);
g_free (p->mime_body);
-
+
if (p->redirect)
camel_object_unref (p->redirect);
-
-
+
+
g_free (p);
p = NULL;
composer->priv = NULL;
-
+
if (G_OBJECT_CLASS (parent_class)->finalize != NULL)
(* G_OBJECT_CLASS (parent_class)->finalize) (object);
}
@@ -2809,7 +2809,7 @@ composer_dispose(GObject *object)
* been destroyed, so we have to do this here.
*/
autosave_manager_unregister (am, E_MSG_COMPOSER (object));
-
+
if (G_OBJECT_CLASS (parent_class)->dispose != NULL)
(* G_OBJECT_CLASS (parent_class)->dispose) (object);
}
@@ -2822,7 +2822,7 @@ destroy (GtkObject *object)
EMsgComposerPrivate *p = composer->priv;
CORBA_Environment ev;
ESignatureList *signatures;
-
+
CORBA_exception_init (&ev);
if (p->menu) {
@@ -2850,7 +2850,7 @@ destroy (GtkObject *object)
bonobo_object_unref (BONOBO_OBJECT (p->entry_uic));
p->entry_uic = NULL;
}
-
+
/* FIXME? I assume the Bonobo widget will get destroyed
normally? */
if (p->address_dialog != NULL) {
@@ -2861,51 +2861,51 @@ destroy (GtkObject *object)
gtk_widget_destroy (p->hdrs);
p->hdrs = NULL;
}
-
+
if (p->notify_id) {
GConfClient *gconf = gconf_client_get_default ();
gconf_client_notify_remove (gconf, p->notify_id);
p->notify_id = 0;
g_object_unref (gconf);
- }
+ }
if (p->persist_stream_interface != CORBA_OBJECT_NIL) {
Bonobo_Unknown_unref (p->persist_stream_interface, &ev);
CORBA_Object_release (p->persist_stream_interface, &ev);
p->persist_stream_interface = CORBA_OBJECT_NIL;
}
-
+
if (p->persist_file_interface != CORBA_OBJECT_NIL) {
Bonobo_Unknown_unref (p->persist_file_interface, &ev);
CORBA_Object_release (p->persist_file_interface, &ev);
p->persist_file_interface = CORBA_OBJECT_NIL;
}
-
+
if (p->eeditor_engine != CORBA_OBJECT_NIL) {
Bonobo_Unknown_unref (p->eeditor_engine, &ev);
CORBA_Object_release (p->eeditor_engine, &ev);
p->eeditor_engine = CORBA_OBJECT_NIL;
}
-
+
CORBA_exception_free (&ev);
-
+
if (p->eeditor_listener) {
bonobo_object_unref (p->eeditor_listener);
p->eeditor_listener = NULL;
}
-
+
signatures = mail_config_get_signatures ();
-
+
if (p->sig_added_id != 0) {
g_signal_handler_disconnect (signatures, p->sig_added_id);
p->sig_added_id = 0;
}
-
+
if (p->sig_removed_id != 0) {
g_signal_handler_disconnect (signatures, p->sig_removed_id);
p->sig_removed_id = 0;
}
-
+
if (p->sig_changed_id != 0) {
g_signal_handler_disconnect (signatures, p->sig_changed_id);
p->sig_changed_id = 0;
@@ -2938,7 +2938,7 @@ delete_event (GtkWidget *widget,
GdkEventAny *event)
{
do_exit (E_MSG_COMPOSER (widget));
-
+
return TRUE;
}
@@ -2986,7 +2986,7 @@ int
e_msg_composer_get_remote_download_count (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
- return e_attachment_bar_get_download_count
+ return e_attachment_bar_get_download_count
(E_ATTACHMENT_BAR (p->attachment_bar));
}
@@ -3020,7 +3020,7 @@ drop_action(EMsgComposer *composer, GdkDragContext *context, guint32 action, Gtk
char *content_type;
int i, success = FALSE, delete = FALSE;
EMsgComposerPrivate *p = composer->priv;
-
+
switch (info) {
case DND_TYPE_MESSAGE_RFC822:
d(printf ("dropping a message/rfc822\n"));
@@ -3028,7 +3028,7 @@ drop_action(EMsgComposer *composer, GdkDragContext *context, guint32 action, Gtk
stream = camel_stream_mem_new ();
camel_stream_write (stream, (const gchar *)selection->data, selection->length);
camel_stream_reset (stream);
-
+
msg = camel_mime_message_new ();
if (camel_data_wrapper_construct_from_stream((CamelDataWrapper *)msg, stream) != -1) {
attach_message(composer, msg);
@@ -3056,18 +3056,18 @@ drop_action(EMsgComposer *composer, GdkDragContext *context, guint32 action, Gtk
tmp = g_strndup ((const gchar *) selection->data, selection->length);
urls = g_strsplit (tmp, "\n", 0);
g_free (tmp);
-
+
for (i = 0; urls[i] != NULL; i++) {
str = g_strstrip (urls[i]);
if (str[0] == '#' || str[0] == '\0') {
g_free (str);
continue;
}
-
+
handle_uri (composer, str, html_dnd);
g_free (str);
}
-
+
g_free (urls);
success = TRUE;
break;
@@ -3075,16 +3075,16 @@ drop_action(EMsgComposer *composer, GdkDragContext *context, guint32 action, Gtk
case DND_TYPE_TEXT_CALENDAR:
content_type = gdk_atom_name (selection->type);
d(printf ("dropping a %s\n", content_type));
-
+
mime_part = camel_mime_part_new ();
camel_mime_part_set_content (mime_part, (const gchar *)selection->data, selection->length, content_type);
camel_mime_part_set_disposition (mime_part, "inline");
-
+
e_attachment_bar_attach_mime_part (E_ATTACHMENT_BAR (p->attachment_bar), mime_part);
-
+
camel_object_unref (mime_part);
g_free (content_type);
-
+
success = TRUE;
break;
case DND_TYPE_X_UID_LIST: {
@@ -3180,7 +3180,7 @@ drop_action(EMsgComposer *composer, GdkDragContext *context, guint32 action, Gtk
if (e_attachment_bar_get_num_attachments(E_ATTACHMENT_BAR(p->attachment_bar)))
show_attachments (composer, TRUE);
-
+
gtk_drag_finish(context, success, delete, time);
}
@@ -3307,14 +3307,14 @@ class_init (EMsgComposerClass *klass)
gobject_class = G_OBJECT_CLASS(klass);
object_class = GTK_OBJECT_CLASS (klass);
widget_class = GTK_WIDGET_CLASS (klass);
-
+
gobject_class->finalize = composer_finalise;
gobject_class->dispose = composer_dispose;
object_class->destroy = destroy;
widget_class->delete_event = delete_event;
-
+
parent_class = g_type_class_ref(bonobo_window_get_type ());
-
+
signals[SEND] =
g_signal_new ("send",
E_TYPE_MSG_COMPOSER,
@@ -3323,7 +3323,7 @@ class_init (EMsgComposerClass *klass)
NULL, NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
-
+
signals[SAVE_DRAFT] =
g_signal_new ("save-draft",
E_TYPE_MSG_COMPOSER,
@@ -3353,46 +3353,46 @@ init (EMsgComposer *composer)
(GDestroyNotify) camel_object_unref);
p->uic = NULL;
-
+
p->hdrs = NULL;
p->extra_hdr_names = g_ptr_array_new ();
p->extra_hdr_values = g_ptr_array_new ();
-
+
p->focused_entry = NULL;
-
+
p->eeditor = NULL;
-
+
p->address_dialog = NULL;
-
+
p->attachment_bar = NULL;
p->attachment_scrolled_window = NULL;
-
+
p->persist_file_interface = CORBA_OBJECT_NIL;
p->persist_stream_interface = CORBA_OBJECT_NIL;
-
+
p->eeditor_engine = CORBA_OBJECT_NIL;
p->inline_images = inline_images;
p->inline_images_by_url = inline_images_by_url;
p->current_images = NULL;
-
+
p->attachment_bar_visible = FALSE;
p->send_html = FALSE;
p->pgp_sign = FALSE;
p->pgp_encrypt = FALSE;
p->smime_sign = FALSE;
p->smime_encrypt = FALSE;
-
+
p->has_changed = FALSE;
p->autosaved = FALSE;
-
- p->redirect = NULL;
- p->send_invoked = FALSE;
+
+ p->redirect = NULL;
+ p->send_invoked = FALSE;
p->charset = NULL;
-
+
p->enable_autosave = TRUE;
p->autosave_file = NULL;
p->autosave_fd = -1;
-
+
/** @HookPoint-EMMenu: Main Mail Menu
* @Id: org.gnome.evolution.mail.composer
* @Class: org.gnome.evolution.mail.bonobomenu:1.0
@@ -3402,7 +3402,7 @@ init (EMsgComposer *composer)
* target will point to the EMsgComposer object.
*/
p->menu = em_menu_new("org.gnome.evolution.mail.composer");
-
+
composer->priv = p;
}
@@ -3411,7 +3411,7 @@ GtkType
e_msg_composer_get_type (void)
{
static GType type = 0;
-
+
if (type == 0) {
static const GTypeInfo info = {
sizeof (EMsgComposerClass),
@@ -3422,10 +3422,10 @@ e_msg_composer_get_type (void)
0,
(GInstanceInitFunc) init,
};
-
+
type = g_type_register_static (bonobo_window_get_type (), "EMsgComposer", &info, 0);
}
-
+
return type;
}
@@ -3434,9 +3434,9 @@ e_msg_composer_load_config (EMsgComposer *composer, int visible_mask)
{
GConfClient *gconf;
EMsgComposerPrivate *p = composer->priv;
-
+
gconf = gconf_client_get_default ();
-
+
p->view_from = gconf_client_get_bool (
gconf, "/apps/evolution/mail/composer/view/From", NULL);
p->view_replyto = gconf_client_get_bool (
@@ -3445,32 +3445,32 @@ e_msg_composer_load_config (EMsgComposer *composer, int visible_mask)
gconf, "/apps/evolution/mail/composer/view/To", NULL);
p->view_postto = gconf_client_get_bool (
gconf, "/apps/evolution/mail/composer/view/PostTo", NULL);
- p->view_cc = gconf_client_get_bool (
+ p->view_cc = gconf_client_get_bool (
gconf, "/apps/evolution/mail/composer/view/Cc", NULL);
p->view_bcc = gconf_client_get_bool (
gconf, "/apps/evolution/mail/composer/view/Bcc", NULL);
p->view_subject = gconf_client_get_bool (
gconf, "/apps/evolution/mail/composer/view/Subject", NULL);
-
+
/* if we're mailing, you cannot disable to so it should appear checked */
if (visible_mask & E_MSG_COMPOSER_VISIBLE_TO)
p->view_to = TRUE;
else
p->view_to = FALSE;
-
+
/* ditto for post-to */
if (visible_mask & E_MSG_COMPOSER_VISIBLE_POSTTO)
p->view_postto = TRUE;
else
p->view_postto = FALSE;
-
+
/* we set these to false initially if we're posting */
if (!(visible_mask & E_MSG_COMPOSER_VISIBLE_CC))
p->view_cc = FALSE;
-
+
if (!(visible_mask & E_MSG_COMPOSER_VISIBLE_BCC))
p->view_bcc = FALSE;
-
+
g_object_unref (gconf);
}
@@ -3479,7 +3479,7 @@ e_msg_composer_get_visible_flags (EMsgComposer *composer)
{
int flags = 0;
EMsgComposerPrivate *p = composer->priv;
-
+
if (p->view_from)
flags |= E_MSG_COMPOSER_VISIBLE_FROM;
if (p->view_replyto)
@@ -3494,14 +3494,14 @@ e_msg_composer_get_visible_flags (EMsgComposer *composer)
flags |= E_MSG_COMPOSER_VISIBLE_BCC;
if (p->view_subject)
flags |= E_MSG_COMPOSER_VISIBLE_SUBJECT;
-
+
/*
* Until we have a GUI way, lets make sure that
* even if the user screws up, we will do the right
* thing (screws up == edit the config file manually
* and screw up).
*/
- flags |= E_MSG_COMPOSER_VISIBLE_SUBJECT;
+ flags |= E_MSG_COMPOSER_VISIBLE_SUBJECT;
return flags;
}
@@ -3515,29 +3515,29 @@ map_default_cb (EMsgComposer *composer, gpointer user_data)
const char *text;
EMsgComposerPrivate *p = composer->priv;
- /* If the 'To:' field is empty, focus it */
+ /* If the 'To:' field is empty, focus it */
widget = e_msg_composer_hdrs_get_to_entry (E_MSG_COMPOSER_HDRS (p->hdrs));
text = gtk_entry_get_text (GTK_ENTRY (widget));
-
+
if (!text || text[0] == '\0') {
gtk_widget_grab_focus (widget);
-
+
return;
}
-
+
/* If not, check the subject field */
-
+
subject = e_msg_composer_hdrs_get_subject (E_MSG_COMPOSER_HDRS (p->hdrs));
-
+
if (!subject || subject[0] == '\0') {
widget = e_msg_composer_hdrs_get_subject_entry (E_MSG_COMPOSER_HDRS (p->hdrs));
gtk_widget_grab_focus (widget);
return;
}
-
+
/* Jump to the editor as a last resort. */
-
+
CORBA_exception_init (&ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "grab-focus", &ev);
CORBA_exception_free (&ev);
@@ -3547,7 +3547,7 @@ static void
msg_composer_destroy_notify (void *data)
{
EMsgComposer *composer = E_MSG_COMPOSER (data);
-
+
all_composers = g_slist_remove (all_composers, composer);
}
@@ -3576,7 +3576,7 @@ composer_key_pressed (EMsgComposer *composer, GdkEventKey *event, void *user_dat
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "grab-focus", &ev);
CORBA_exception_free (&ev);
g_signal_stop_emission_by_name (composer, "key-press-event");
- return TRUE;
+ return TRUE;
}
return FALSE;
}
@@ -3616,7 +3616,7 @@ composer_entry_focus_in_event_cb (GtkWidget *widget, GdkEventFocus *event, gpoin
g_free (xmlfile);
bonobo_ui_component_thaw (p->entry_uic, NULL);
-
+
return FALSE;
}
@@ -3625,12 +3625,12 @@ composer_entry_focus_out_event_cb (GtkWidget *widget, GdkEventFocus *event, gpoi
{
EMsgComposer *composer = user_data;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_val_if_fail (p->focused_entry == widget, FALSE);
p->focused_entry = NULL;
bonobo_ui_component_unset_container (p->entry_uic, NULL);
-
+
return FALSE;
}
@@ -3640,13 +3640,13 @@ setup_cut_copy_paste (EMsgComposer *composer)
EMsgComposerHdrs *hdrs;
EMsgComposerPrivate *p = composer->priv;
GtkWidget *entry;
-
+
hdrs = (EMsgComposerHdrs *) p->hdrs;
-
+
entry = e_msg_composer_hdrs_get_subject_entry (hdrs);
g_signal_connect (entry, "focus_in_event", G_CALLBACK (composer_entry_focus_in_event_cb), composer);
g_signal_connect (entry, "focus_out_event", G_CALLBACK (composer_entry_focus_out_event_cb), composer);
-
+
entry = e_msg_composer_hdrs_get_reply_to_entry (hdrs);
g_signal_connect (entry, "focus_in_event", G_CALLBACK (composer_entry_focus_in_event_cb), composer);
g_signal_connect (entry, "focus_out_event", G_CALLBACK (composer_entry_focus_out_event_cb), composer);
@@ -3722,7 +3722,7 @@ static void
emcab_properties(EPopup *ep, EPopupItem *item, void *data)
{
EAttachmentBar *bar = data;
-
+
e_attachment_bar_edit_selected(bar);
}
@@ -3749,17 +3749,17 @@ emcab_popup_position(GtkMenu *menu, int *x, int *y, gboolean *push_in, gpointer
GnomeIconList *icon_list = user_data;
GList *selection;
GnomeCanvasPixbuf *image;
-
+
gdk_window_get_origin (((GtkWidget*) bar)->window, x, y);
-
+
selection = gnome_icon_list_get_selection (icon_list);
if (selection == NULL)
return;
-
+
image = gnome_icon_list_get_icon_pixbuf_item (icon_list, GPOINTER_TO_INT(selection->data));
if (image == NULL)
return;
-
+
/* Put menu to the center of icon. */
*x += (int)(image->item.x1 + image->item.x2) / 2;
*y += (int)(image->item.y1 + image->item.y2) / 2;
@@ -3783,7 +3783,7 @@ emcab_popup(EAttachmentBar *bar, GdkEventButton *event, int id)
GtkMenu *menu;
attachments = e_attachment_bar_get_attachment(bar, id);
-
+
for (i=0;i<sizeof(emcab_popups)/sizeof(emcab_popups[0]);i++)
menus = g_slist_prepend(menus, &emcab_popups[i]);
@@ -3806,7 +3806,7 @@ emcab_popup(EAttachmentBar *bar, GdkEventButton *event, int id)
gtk_menu_popup(menu, NULL, NULL, NULL, NULL, event->button, event->time);
}
-static gboolean
+static gboolean
popup_menu_event (GtkWidget *widget)
{
emcab_popup((EAttachmentBar *)widget, NULL, -1);
@@ -3820,10 +3820,10 @@ button_press_event (GtkWidget *widget, GdkEventButton *event)
EAttachmentBar *bar = (EAttachmentBar *)widget;
GnomeIconList *icon_list = GNOME_ICON_LIST(widget);
int icon_number;
-
+
if (event->button != 3)
return FALSE;
-
+
icon_number = gnome_icon_list_get_icon_at (icon_list, event->x, event->y);
if (icon_number >= 0) {
gnome_icon_list_unselect_all(icon_list);
@@ -3831,7 +3831,7 @@ button_press_event (GtkWidget *widget, GdkEventButton *event)
}
emcab_popup(bar, event, icon_number);
-
+
return TRUE;
}
@@ -3844,7 +3844,7 @@ key_press_event(GtkWidget *widget, GdkEventKey *event)
e_attachment_bar_remove_selected (bar);
return TRUE;
}
-
+
return FALSE;
}
@@ -3861,20 +3861,20 @@ create_composer (int visible_mask)
BonoboControlFrame *control_frame;
GtkWidget *html_widget = NULL;
gpointer servant;
- BonoboObject *impl;
+ BonoboObject *impl;
EMsgComposerPrivate *p;
-
+
composer = g_object_new (E_TYPE_MSG_COMPOSER, "win_name", _("Compose Message"), NULL);
p = composer->priv;
-
+
gtk_window_set_title ((GtkWindow *) composer, _("Compose Message"));
-
+
all_composers = g_slist_prepend (all_composers, composer);
-
+
g_signal_connect (composer, "key-press-event",
G_CALLBACK (composer_key_pressed),
NULL);
-
+
g_signal_connect (composer, "destroy",
G_CALLBACK (msg_composer_destroy_notify),
NULL);
@@ -3891,11 +3891,11 @@ create_composer (int visible_mask)
g_signal_connect(composer, "drag_data_received", G_CALLBACK (drag_data_received), composer);
g_signal_connect(composer, "drag-motion", G_CALLBACK(drag_motion), composer);
e_msg_composer_load_config (composer, visible_mask);
-
+
setup_ui (composer);
-
+
vbox = gtk_vbox_new (FALSE, 0);
-
+
vis = e_msg_composer_get_visible_flags (composer);
p->hdrs = e_msg_composer_hdrs_new (p->uic, visible_mask, vis);
if (!p->hdrs) {
@@ -3903,7 +3903,7 @@ create_composer (int visible_mask)
gtk_object_destroy (GTK_OBJECT (composer));
return NULL;
}
-
+
gtk_box_set_spacing (GTK_BOX (vbox), 6);
gtk_box_pack_start (GTK_BOX (vbox), p->hdrs, FALSE, FALSE, 0);
g_signal_connect (p->hdrs, "subject_changed",
@@ -3913,7 +3913,7 @@ create_composer (int visible_mask)
g_signal_connect (p->hdrs, "from_changed",
G_CALLBACK (from_changed_cb), composer);
gtk_widget_show (p->hdrs);
-
+
setup_signatures_menu (composer);
from_changed_cb((EMsgComposerHdrs *)p->hdrs, composer);
@@ -3930,12 +3930,12 @@ create_composer (int visible_mask)
control_frame = bonobo_widget_get_control_frame (BONOBO_WIDGET (p->eeditor));
bonobo_control_frame_set_autoactivate (control_frame, TRUE);
-
+
/* let the editor know which mode we are in */
- bonobo_widget_set_property (BONOBO_WIDGET (p->eeditor),
+ bonobo_widget_set_property (BONOBO_WIDGET (p->eeditor),
"FormatHTML", TC_CORBA_boolean, p->send_html,
NULL);
-
+
gconf = gconf_client_get_default ();
composer_settings_update (gconf, 0, NULL, composer);
gconf_client_add_dir (gconf, "/apps/evolution/mail/composer", GCONF_CLIENT_PRELOAD_ONELEVEL, NULL);
@@ -3946,9 +3946,9 @@ create_composer (int visible_mask)
gconf_client_get_int (gconf, "/apps/evolution/mail/composer/height", NULL));
g_signal_connect (composer, "unrealize", G_CALLBACK (e_msg_composer_unrealize), NULL);
g_object_unref (gconf);
-
+
editor_server = bonobo_widget_get_objref (BONOBO_WIDGET (p->eeditor));
-
+
/* FIXME: handle exceptions */
CORBA_exception_init (&ev);
p->persist_file_interface
@@ -3956,24 +3956,24 @@ create_composer (int visible_mask)
p->persist_stream_interface
= Bonobo_Unknown_queryInterface (editor_server, "IDL:Bonobo/PersistStream:1.0", &ev);
CORBA_exception_free (&ev);
-
+
gtk_box_pack_start (GTK_BOX (vbox), p->eeditor, TRUE, TRUE, 0);
-
+
/* Attachment editor, wrapped into an EScrollFrame. It's
hidden in an EExpander. */
-
+
p->attachment_scrolled_window = gtk_scrolled_window_new (NULL, NULL);
gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (p->attachment_scrolled_window),
GTK_SHADOW_IN);
gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (p->attachment_scrolled_window),
GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
-
+
p->attachment_bar = e_attachment_bar_new (NULL);
g_signal_connect (p->attachment_bar, "button_press_event", G_CALLBACK (button_press_event), NULL);
g_signal_connect (p->attachment_bar, "key_press_event", G_CALLBACK (key_press_event), NULL);
g_signal_connect (p->attachment_bar, "popup-menu", G_CALLBACK (popup_menu_event), NULL);
-
+
GTK_WIDGET_SET_FLAGS (p->attachment_bar, GTK_CAN_FOCUS);
gtk_container_add (GTK_CONTAINER (p->attachment_scrolled_window),
p->attachment_bar);
@@ -3988,7 +3988,7 @@ create_composer (int visible_mask)
gtk_misc_set_alignment (GTK_MISC (p->attachment_expander_label), 0.0, 0.5);
gtk_misc_set_alignment (GTK_MISC (p->attachment_expander_num), 1.0, 0.5);
expander_hbox = gtk_hbox_new (FALSE, 0);
-
+
p->attachment_expander_icon = e_icon_factory_get_image ("mail-attachment", E_ICON_SIZE_MENU);
gtk_misc_set_alignment (GTK_MISC (p->attachment_expander_icon), 1, 0.5);
gtk_widget_set_size_request (p->attachment_expander_icon, 100, -1);
@@ -4008,18 +4008,18 @@ create_composer (int visible_mask)
gtk_box_pack_start (GTK_BOX (vbox), p->attachment_expander, FALSE, FALSE, GNOME_PAD_SMALL);
gtk_widget_show (p->attachment_expander);
- e_expander_set_expanded (E_EXPANDER (p->attachment_expander), FALSE);
- g_signal_connect_after (p->attachment_expander, "activate",
+ e_expander_set_expanded (E_EXPANDER (p->attachment_expander), FALSE);
+ g_signal_connect_after (p->attachment_expander, "activate",
G_CALLBACK (attachment_expander_activate_cb), composer);
bonobo_window_set_contents (BONOBO_WINDOW (composer), vbox);
gtk_widget_show (vbox);
-
+
/* If we show this widget earlier, we lose network transparency. i.e. the
component appears on the machine evo is running on, ignoring any DISPLAY
variable. */
gtk_widget_show (p->eeditor);
-
+
prepare_engine (composer);
if (p->eeditor_engine == CORBA_OBJECT_NIL) {
e_error_run (GTK_WINDOW (composer), "mail-composer:no-editor-control", NULL);
@@ -4030,7 +4030,7 @@ create_composer (int visible_mask)
/* The engine would have the GtkHTML widget stored in "html-widget"
* We'll use that to listen for DnD signals
*/
-
+
servant = ORBit_small_get_servant (p->eeditor_engine);
if (servant && (impl = bonobo_object (servant)))
html_widget = g_object_get_data (G_OBJECT(impl), "html-widget");
@@ -4038,18 +4038,18 @@ create_composer (int visible_mask)
if (html_widget) {
g_signal_connect (html_widget, "drag_data_received", G_CALLBACK (drag_data_received), composer);
}
-
+
setup_cut_copy_paste (composer);
g_signal_connect (composer, "map", (GCallback) map_default_cb, NULL);
-
+
if (am == NULL)
am = autosave_manager_new ();
-
+
autosave_manager_register (am, composer);
p->has_changed = FALSE;
-
+
return composer;
}
@@ -4058,15 +4058,15 @@ set_editor_signature (EMsgComposer *composer)
{
EAccountIdentity *id;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (E_MSG_COMPOSER_HDRS (p->hdrs)->account != NULL);
-
+
id = E_MSG_COMPOSER_HDRS (p->hdrs)->account->id;
if (id->sig_uid)
p->signature = mail_config_get_signature_by_uid (id->sig_uid);
else
p->signature = NULL;
-
+
sig_select_item (composer);
}
@@ -4114,7 +4114,7 @@ e_msg_composer_new_with_type (int type)
* e_msg_composer_new:
*
* Create a new message composer widget.
- *
+ *
* Return value: A pointer to the newly created widget
**/
EMsgComposer *
@@ -4132,12 +4132,12 @@ is_special_header (const char *hdr_name)
*/
if (g_ascii_strncasecmp (hdr_name, "X-", 2))
return TRUE;
-
+
if (!g_ascii_strncasecmp (hdr_name, "X-Evolution", 11))
return TRUE;
-
+
/* we can keep all other X-* headers */
-
+
return FALSE;
}
@@ -4145,7 +4145,7 @@ static void
e_msg_composer_set_pending_body (EMsgComposer *composer, char *text, ssize_t len)
{
char *old;
-
+
old = g_object_get_data ((GObject *) composer, "body:text");
g_free (old);
g_object_set_data ((GObject *) composer, "body:text", text);
@@ -4157,20 +4157,20 @@ e_msg_composer_flush_pending_body (EMsgComposer *composer, gboolean apply)
{
char *body;
ssize_t len;
-
+
body = g_object_get_data ((GObject *) composer, "body:text");
len = GPOINTER_TO_SIZE (g_object_get_data ((GObject *) composer, "body:len"));
if (body) {
- if (apply)
+ if (apply)
set_editor_text (composer, body, len, FALSE, FALSE);
-
+
g_object_set_data ((GObject *) composer, "body:text", NULL);
g_free (body);
}
-}
+}
static void
-add_attachments_handle_mime_part (EMsgComposer *composer, CamelMimePart *mime_part,
+add_attachments_handle_mime_part (EMsgComposer *composer, CamelMimePart *mime_part,
gboolean just_inlines, gboolean related, int depth)
{
CamelContentType *content_type;
@@ -4181,7 +4181,7 @@ add_attachments_handle_mime_part (EMsgComposer *composer, CamelMimePart *mime_pa
content_type = camel_mime_part_get_content_type (mime_part);
wrapper = camel_medium_get_content_object (CAMEL_MEDIUM (mime_part));
-
+
if (CAMEL_IS_MULTIPART (wrapper)) {
/* another layer of multipartness... */
add_attachments_from_multipart (composer, (CamelMultipart *) wrapper, just_inlines, depth + 1);
@@ -4210,9 +4210,9 @@ add_attachments_from_multipart (EMsgComposer *composer, CamelMultipart *multipar
CamelMimePart *mime_part;
gboolean related;
int i, nparts;
-
+
related = camel_content_type_is (CAMEL_DATA_WRAPPER (multipart)->mime_type, "multipart", "related");
-
+
if (CAMEL_IS_MULTIPART_SIGNED (multipart)) {
mime_part = camel_multipart_get_part (multipart, CAMEL_MULTIPART_SIGNED_CONTENT);
add_attachments_handle_mime_part (composer, mime_part, just_inlines, related, depth);
@@ -4244,11 +4244,11 @@ e_msg_composer_add_message_attachments (EMsgComposer *composer, CamelMimeMessage
gboolean just_inlines)
{
CamelDataWrapper *wrapper;
-
+
wrapper = camel_medium_get_content_object (CAMEL_MEDIUM (message));
if (!CAMEL_IS_MULTIPART (wrapper))
return;
-
+
/* there must be attachments... */
add_attachments_from_multipart (composer, (CamelMultipart *) wrapper, just_inlines, 0);
}
@@ -4260,27 +4260,27 @@ handle_multipart_signed (EMsgComposer *composer, CamelMultipart *multipart, int
CamelContentType *content_type;
CamelDataWrapper *content;
CamelMimePart *mime_part;
-
+
/* FIXME: make sure this isn't an s/mime signed part?? */
e_msg_composer_set_pgp_sign (composer, TRUE);
-
+
mime_part = camel_multipart_get_part (multipart, CAMEL_MULTIPART_SIGNED_CONTENT);
if (!mime_part)
return;
content_type = camel_mime_part_get_content_type (mime_part);
-
+
content = camel_medium_get_content_object (CAMEL_MEDIUM (mime_part));
-
+
if (CAMEL_IS_MULTIPART (content)) {
multipart = CAMEL_MULTIPART (content);
-
+
/* Note: depth is preserved here because we're not
counting multipart/signed as a multipart, instead
we want to treat the content part as our mime part
here. */
-
+
if (CAMEL_IS_MULTIPART_SIGNED (content)) {
/* handle the signed content and configure the composer to sign outgoing messages */
handle_multipart_signed (composer, multipart, depth);
@@ -4317,7 +4317,7 @@ handle_multipart_encrypted (EMsgComposer *composer, CamelMimePart *multipart, in
/* FIXME: make sure this is a PGP/MIME encrypted part?? */
e_msg_composer_set_pgp_encrypt (composer, TRUE);
-
+
camel_exception_init (&ex);
cipher = mail_crypto_get_pgp_cipher_context (NULL);
mime_part = camel_mime_part_new();
@@ -4325,21 +4325,21 @@ handle_multipart_encrypted (EMsgComposer *composer, CamelMimePart *multipart, in
camel_object_unref(cipher);
camel_exception_clear (&ex);
if (valid == NULL)
- return;
+ return;
camel_cipher_validity_free(valid);
-
+
content_type = camel_mime_part_get_content_type (mime_part);
-
+
content = camel_medium_get_content_object (CAMEL_MEDIUM (mime_part));
-
+
if (CAMEL_IS_MULTIPART (content)) {
CamelMultipart *content_multipart = CAMEL_MULTIPART (content);
-
+
/* Note: depth is preserved here because we're not
counting multipart/encrypted as a multipart, instead
we want to treat the content part as our mime part
here. */
-
+
if (CAMEL_IS_MULTIPART_SIGNED (content)) {
/* handle the signed content and configure the composer to sign outgoing messages */
handle_multipart_signed (composer, content_multipart, depth);
@@ -4362,7 +4362,7 @@ handle_multipart_encrypted (EMsgComposer *composer, CamelMimePart *multipart, in
} else {
e_msg_composer_attach (composer, mime_part);
}
-
+
camel_object_unref (mime_part);
}
@@ -4372,14 +4372,14 @@ handle_multipart_alternative (EMsgComposer *composer, CamelMultipart *multipart,
/* Find the text/html part and set the composer body to it's contents */
CamelMimePart *text_part = NULL;
int i, nparts;
-
+
nparts = camel_multipart_get_number (multipart);
-
+
for (i = 0; i < nparts; i++) {
CamelContentType *content_type;
CamelDataWrapper *content;
CamelMimePart *mime_part;
-
+
mime_part = camel_multipart_get_part (multipart, i);
if (!mime_part)
@@ -4387,12 +4387,12 @@ handle_multipart_alternative (EMsgComposer *composer, CamelMultipart *multipart,
content_type = camel_mime_part_get_content_type (mime_part);
content = camel_medium_get_content_object (CAMEL_MEDIUM (mime_part));
-
+
if (CAMEL_IS_MULTIPART (content)) {
CamelMultipart *mp;
-
+
mp = CAMEL_MULTIPART (content);
-
+
if (CAMEL_IS_MULTIPART_SIGNED (content)) {
/* handle the signed content and configure the composer to sign outgoing messages */
handle_multipart_signed (composer, mp, depth + 1);
@@ -4416,7 +4416,7 @@ handle_multipart_alternative (EMsgComposer *composer, CamelMultipart *multipart,
e_msg_composer_attach (composer, mime_part);
}
}
-
+
if (text_part) {
ssize_t len;
char *html;
@@ -4430,9 +4430,9 @@ static void
handle_multipart (EMsgComposer *composer, CamelMultipart *multipart, int depth)
{
int i, nparts;
-
+
nparts = camel_multipart_get_number (multipart);
-
+
for (i = 0; i < nparts; i++) {
CamelContentType *content_type;
CamelDataWrapper *content;
@@ -4445,12 +4445,12 @@ handle_multipart (EMsgComposer *composer, CamelMultipart *multipart, int depth)
content_type = camel_mime_part_get_content_type (mime_part);
content = camel_medium_get_content_object (CAMEL_MEDIUM (mime_part));
-
+
if (CAMEL_IS_MULTIPART (content)) {
CamelMultipart *mp;
-
+
mp = CAMEL_MULTIPART (content);
-
+
if (CAMEL_IS_MULTIPART_SIGNED (content)) {
/* handle the signed content and configure the composer to sign outgoing messages */
handle_multipart_signed (composer, mp, depth + 1);
@@ -4486,13 +4486,13 @@ set_signature_gui (EMsgComposer *composer)
{
CORBA_Environment ev;
EMsgComposerPrivate *p = composer->priv;
-
+
p->signature = NULL;
-
+
CORBA_exception_init (&ev);
if (GNOME_GtkHTML_Editor_Engine_searchByData (p->eeditor_engine, 1, "ClueFlow", "signature", "1", &ev)) {
char *name, *str = NULL;
-
+
str = GNOME_GtkHTML_Editor_Engine_getParagraphData (p->eeditor_engine, "signature_name", &ev);
if (ev._major == CORBA_NO_EXCEPTION && str) {
if (!strncmp (str, "uid:", 4)) {
@@ -4505,7 +4505,7 @@ set_signature_gui (EMsgComposer *composer)
g_free (name);
}
}
-
+
sig_select_item (composer);
}
CORBA_exception_free (&ev);
@@ -4515,7 +4515,7 @@ set_signature_gui (EMsgComposer *composer)
/**
* e_msg_composer_new_with_message:
* @message: The message to use as the source
- *
+ *
* Create a new message composer widget.
*
* Note: Designed to work only for messages constructed using Evolution.
@@ -4539,7 +4539,7 @@ e_msg_composer_new_with_message (CamelMimeMessage *message)
struct _camel_header_raw *xev;
int len, i;
EMsgComposerPrivate *p;
-
+
for (headers = CAMEL_MIME_PART (message)->headers;headers;headers = headers->next) {
if (!strcmp(headers->name, "X-Evolution-PostTo"))
postto = g_list_append(postto, g_strstrip(g_strdup(headers->value)));
@@ -4547,26 +4547,26 @@ e_msg_composer_new_with_message (CamelMimeMessage *message)
new = create_composer (postto ? E_MSG_COMPOSER_VISIBLE_MASK_POST : E_MSG_COMPOSER_VISIBLE_MASK_MAIL);
p = new->priv;
-
+
if (!new) {
g_list_foreach(postto, (GFunc)g_free, NULL);
g_list_free(postto);
return NULL;
}
-
+
if (postto) {
e_msg_composer_hdrs_set_post_to_list(E_MSG_COMPOSER_HDRS (p->hdrs), postto);
g_list_foreach(postto, (GFunc)g_free, NULL);
g_list_free(postto);
postto = NULL;
}
-
+
/* Restore the Account preference */
account_name = (char *) camel_medium_get_header (CAMEL_MEDIUM (message), "X-Evolution-Account");
if (account_name) {
account_name = g_strdup (account_name);
g_strstrip (account_name);
-
+
if ((account = mail_config_get_account_by_uid(account_name)) == NULL)
/* 'old' setting */
account = mail_config_get_account_by_name(account_name);
@@ -4575,7 +4575,7 @@ e_msg_composer_new_with_message (CamelMimeMessage *message)
account_name = g_strdup (account->name);
}
}
-
+
if (postto == NULL) {
auto_cc = g_hash_table_new_full (
camel_strcase_hash, camel_strcase_equal,
@@ -4586,50 +4586,50 @@ e_msg_composer_new_with_message (CamelMimeMessage *message)
camel_strcase_hash, camel_strcase_equal,
(GDestroyNotify) g_free,
(GDestroyNotify) NULL);
-
+
if (account) {
CamelInternetAddress *iaddr;
-
+
/* hash our auto-recipients for this account */
if (account->always_cc) {
iaddr = camel_internet_address_new ();
if (camel_address_decode (CAMEL_ADDRESS (iaddr), account->cc_addrs) != -1) {
for (i = 0; i < camel_address_length (CAMEL_ADDRESS (iaddr)); i++) {
const char *name, *addr;
-
+
if (!camel_internet_address_get (iaddr, i, &name, &addr))
continue;
-
+
g_hash_table_insert (auto_cc, g_strdup (addr), GINT_TO_POINTER (TRUE));
}
}
camel_object_unref (iaddr);
}
-
+
if (account->always_bcc) {
iaddr = camel_internet_address_new ();
if (camel_address_decode (CAMEL_ADDRESS (iaddr), account->bcc_addrs) != -1) {
for (i = 0; i < camel_address_length (CAMEL_ADDRESS (iaddr)); i++) {
const char *name, *addr;
-
+
if (!camel_internet_address_get (iaddr, i, &name, &addr))
continue;
-
+
g_hash_table_insert (auto_bcc, g_strdup (addr), GINT_TO_POINTER (TRUE));
}
}
camel_object_unref (iaddr);
}
}
-
+
to = camel_mime_message_get_recipients (message, CAMEL_RECIPIENT_TYPE_TO);
cc = camel_mime_message_get_recipients (message, CAMEL_RECIPIENT_TYPE_CC);
bcc = camel_mime_message_get_recipients (message, CAMEL_RECIPIENT_TYPE_BCC);
-
+
len = CAMEL_ADDRESS (to)->addresses->len;
for (i = 0; i < len; i++) {
const char *name, *addr;
-
+
if (camel_internet_address_get (to, i, &name, &addr)) {
EDestination *dest = e_destination_new ();
e_destination_set_name (dest, name);
@@ -4639,43 +4639,43 @@ e_msg_composer_new_with_message (CamelMimeMessage *message)
}
Tov = destination_list_to_vector (To);
g_list_free (To);
-
+
len = CAMEL_ADDRESS (cc)->addresses->len;
for (i = 0; i < len; i++) {
const char *name, *addr;
-
+
if (camel_internet_address_get (cc, i, &name, &addr)) {
EDestination *dest = e_destination_new ();
e_destination_set_name (dest, name);
e_destination_set_email (dest, addr);
-
+
if (g_hash_table_lookup (auto_cc, addr))
e_destination_set_auto_recipient (dest, TRUE);
-
+
Cc = g_list_append (Cc, dest);
}
}
-
+
Ccv = destination_list_to_vector (Cc);
g_hash_table_destroy (auto_cc);
g_list_free (Cc);
-
+
len = CAMEL_ADDRESS (bcc)->addresses->len;
for (i = 0; i < len; i++) {
const char *name, *addr;
-
+
if (camel_internet_address_get (bcc, i, &name, &addr)) {
EDestination *dest = e_destination_new ();
e_destination_set_name (dest, name);
e_destination_set_email (dest, addr);
-
+
if (g_hash_table_lookup (auto_bcc, addr))
e_destination_set_auto_recipient (dest, TRUE);
-
+
Bcc = g_list_append (Bcc, dest);
}
}
-
+
Bccv = destination_list_to_vector (Bcc);
g_hash_table_destroy (auto_bcc);
g_list_free (Bcc);
@@ -4684,17 +4684,17 @@ e_msg_composer_new_with_message (CamelMimeMessage *message)
Ccv = NULL;
Bccv = NULL;
}
-
+
subject = camel_mime_message_get_subject (message);
-
+
e_msg_composer_set_headers (new, account_name, Tov, Ccv, Bccv, subject);
-
+
g_free (account_name);
-
+
e_destination_freev (Tov);
e_destination_freev (Ccv);
e_destination_freev (Bccv);
-
+
/* Restore the format editing preference */
format = camel_medium_get_header (CAMEL_MEDIUM (message), "X-Evolution-Format");
if (format) {
@@ -4722,11 +4722,11 @@ e_msg_composer_new_with_message (CamelMimeMessage *message)
}
g_strfreev(flags);
}
-
+
/* Remove any other X-Evolution-* headers that may have been set */
xev = mail_tool_remove_xevolution_headers (message);
camel_header_raw_clear(&xev);
-
+
/* set extra headers */
headers = CAMEL_MIME_PART (message)->headers;
while (headers) {
@@ -4736,18 +4736,18 @@ e_msg_composer_new_with_message (CamelMimeMessage *message)
g_ptr_array_add (p->extra_hdr_names, g_strdup (headers->name));
g_ptr_array_add (p->extra_hdr_values, g_strdup (headers->value));
}
-
+
headers = headers->next;
}
-
+
/* Restore the attachments and body text */
content = camel_medium_get_content_object (CAMEL_MEDIUM (message));
if (CAMEL_IS_MULTIPART (content)) {
CamelMultipart *multipart;
-
+
multipart = CAMEL_MULTIPART (content);
content_type = camel_mime_part_get_content_type (CAMEL_MIME_PART (message));
-
+
if (CAMEL_IS_MULTIPART_SIGNED (content)) {
/* handle the signed content and configure the composer to sign outgoing messages */
handle_multipart_signed (new, multipart, 0);
@@ -4768,14 +4768,14 @@ e_msg_composer_new_with_message (CamelMimeMessage *message)
html = em_utils_part_to_html((CamelMimePart *)message, &length, NULL);
e_msg_composer_set_pending_body(new, html, length);
}
-
+
/* We wait until now to set the body text because we need to ensure that
* the attachment bar has all the attachments, before we request them.
- */
+ */
e_msg_composer_flush_pending_body (new, TRUE);
-
+
set_signature_gui (new);
-
+
return new;
}
@@ -4788,9 +4788,9 @@ disable_editor (EMsgComposer *composer)
CORBA_exception_init (&ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "editable-off", &ev);
CORBA_exception_free (&ev);
-
+
gtk_widget_set_sensitive (p->attachment_bar, FALSE);
-
+
bonobo_ui_component_set_prop (p->uic, "/menu/Edit", "sensitive", "0", NULL);
bonobo_ui_component_set_prop (p->uic, "/menu/Format", "sensitive", "0", NULL);
bonobo_ui_component_set_prop (p->uic, "/menu/Insert", "sensitive", "0", NULL);
@@ -4799,7 +4799,7 @@ disable_editor (EMsgComposer *composer)
/**
* e_msg_composer_new_redirect:
* @message: The message to use as the source
- *
+ *
* Create a new message composer widget.
*
* Return value: A pointer to the newly created widget
@@ -4810,21 +4810,21 @@ e_msg_composer_new_redirect (CamelMimeMessage *message, const char *resent_from)
EMsgComposer *composer;
EMsgComposerPrivate *p;
const char *subject;
-
+
g_return_val_if_fail (CAMEL_IS_MIME_MESSAGE (message), NULL);
-
+
composer = e_msg_composer_new_with_message (message);
p = composer->priv;
-
+
subject = camel_mime_message_get_subject (message);
-
+
p->redirect = message;
camel_object_ref (message);
-
+
e_msg_composer_set_headers (composer, resent_from, NULL, NULL, NULL, subject);
-
+
disable_editor (composer);
-
+
return composer;
}
@@ -4835,20 +4835,20 @@ add_recipients (GList *list, const char *recips)
CamelInternetAddress *cia;
const char *name, *addr;
int num, i;
-
+
cia = camel_internet_address_new ();
num = camel_address_decode (CAMEL_ADDRESS (cia), recips);
-
+
for (i = 0; i < num; i++) {
if (camel_internet_address_get (cia, i, &name, &addr)) {
EDestination *dest = e_destination_new ();
e_destination_set_name (dest, name);
e_destination_set_email (dest, addr);
-
+
list = g_list_append (list, dest);
}
}
-
+
return list;
}
@@ -4865,9 +4865,9 @@ handle_mailto (EMsgComposer *composer, const char *mailto)
const char *p;
int len, clen;
CamelURL *url;
-
+
buf = g_strdup (mailto);
-
+
/* Parse recipients (everything after ':' until '?' or eos). */
p = buf + 7;
len = strcspn (p, "?");
@@ -4877,27 +4877,27 @@ handle_mailto (EMsgComposer *composer, const char *mailto)
to = add_recipients (to, content);
g_free (content);
}
-
+
p += len;
if (*p == '?') {
p++;
-
+
while (*p) {
len = strcspn (p, "=&");
-
+
/* If it's malformed, give up. */
if (p[len] != '=')
break;
-
+
header = (char *) p;
header[len] = '\0';
p += len + 1;
-
+
clen = strcspn (p, "&");
-
+
content = g_strndup (p, clen);
camel_url_decode (content);
-
+
if (!g_ascii_strcasecmp (header, "to")) {
to = add_recipients (to, content);
} else if (!g_ascii_strcasecmp (header, "cc")) {
@@ -4945,7 +4945,7 @@ handle_mailto (EMsgComposer *composer, const char *mailto)
"attachment");
}
gtk_widget_show (priv->attachment_expander);
- gtk_widget_show (priv->attachment_scrolled_window);
+ gtk_widget_show (priv->attachment_scrolled_window);
} else if (!g_ascii_strcasecmp (header, "from")) {
/* Ignore */
} else if (!g_ascii_strcasecmp (header, "reply-to")) {
@@ -4954,9 +4954,9 @@ handle_mailto (EMsgComposer *composer, const char *mailto)
/* add an arbitrary header? */
e_msg_composer_add_header (composer, header, content);
}
-
+
g_free (content);
-
+
p += clen;
if (*p == '&') {
p++;
@@ -4965,35 +4965,35 @@ handle_mailto (EMsgComposer *composer, const char *mailto)
}
}
}
-
+
g_free (buf);
-
+
tov = destination_list_to_vector (to);
ccv = destination_list_to_vector (cc);
bccv = destination_list_to_vector (bcc);
-
+
g_list_free (to);
g_list_free (cc);
g_list_free (bcc);
-
+
hdrs = E_MSG_COMPOSER_HDRS (priv->hdrs);
-
+
e_msg_composer_hdrs_set_to (hdrs, tov);
e_msg_composer_hdrs_set_cc (hdrs, ccv);
e_msg_composer_hdrs_set_bcc (hdrs, bccv);
-
+
e_destination_freev (tov);
e_destination_freev (ccv);
e_destination_freev (bccv);
-
+
if (subject) {
e_msg_composer_hdrs_set_subject (hdrs, subject);
g_free (subject);
}
-
+
if (body) {
char *htmlbody;
-
+
htmlbody = camel_text_to_html (body, CAMEL_MIME_FILTER_TOHTML_PRE, 0);
set_editor_text (composer, htmlbody, -1, FALSE, FALSE);
g_free (htmlbody);
@@ -5043,15 +5043,15 @@ EMsgComposer *
e_msg_composer_new_from_url (const char *url)
{
EMsgComposer *composer;
-
+
g_return_val_if_fail (g_ascii_strncasecmp (url, "mailto:", 7) == 0, NULL);
-
+
composer = e_msg_composer_new ();
if (!composer)
return NULL;
-
+
handle_mailto (composer, url);
-
+
return composer;
}
@@ -5067,7 +5067,7 @@ e_msg_composer_new_from_url (const char *url)
*
* Sets the headers in the composer to the given values.
**/
-void
+void
e_msg_composer_set_headers (EMsgComposer *composer,
const char *from,
EDestination **to,
@@ -5077,11 +5077,11 @@ e_msg_composer_set_headers (EMsgComposer *composer,
{
EMsgComposerHdrs *hdrs;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
hdrs = E_MSG_COMPOSER_HDRS (p->hdrs);
-
+
e_msg_composer_hdrs_set_to (hdrs, to);
e_msg_composer_hdrs_set_cc (hdrs, cc);
e_msg_composer_hdrs_set_bcc (hdrs, bcc);
@@ -5102,7 +5102,7 @@ e_msg_composer_set_body_text (EMsgComposer *composer, const char *text, ssize_t
{
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
g_return_if_fail (text != NULL);
-
+
set_editor_text (composer, text, len, TRUE, *text == '\0');
}
@@ -5121,11 +5121,11 @@ e_msg_composer_set_body (EMsgComposer *composer, const char *body,
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
set_editor_text (composer, _("<b>(The composer contains a non-text message body, which cannot be edited.)</b>"), -1, FALSE, FALSE);
e_msg_composer_set_send_html (composer, FALSE);
disable_editor (composer);
-
+
g_free (p->mime_body);
p->mime_body = g_strdup (body);
g_free (p->mime_type);
@@ -5158,7 +5158,7 @@ e_msg_composer_add_header (EMsgComposer *composer, const char *name,
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
g_return_if_fail (name != NULL);
g_return_if_fail (value != NULL);
-
+
g_ptr_array_add (p->extra_hdr_names, g_strdup (name));
g_ptr_array_add (p->extra_hdr_values, g_strdup (value));
}
@@ -5169,19 +5169,19 @@ e_msg_composer_add_header (EMsgComposer *composer, const char *name,
* @change_value: the header value to put in place of the previous
* value
*
- * Searches for a header with name=@name ,if found it removes
- * that header and adds a new header with the @name and @change_value .
+ * Searches for a header with name=@name ,if found it removes
+ * that header and adds a new header with the @name and @change_value .
* If not found then it creates a new header with @name and @change_value .
**/
-void
+void
e_msg_composer_modify_header (EMsgComposer *composer, const char *name,
const char *change_value)
{
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
g_return_if_fail (name != NULL);
g_return_if_fail (change_value != NULL);
-
- e_msg_composer_remove_header (composer, name);
+
+ e_msg_composer_remove_header (composer, name);
e_msg_composer_add_header (composer, name, change_value);
}
@@ -5191,7 +5191,7 @@ e_msg_composer_modify_header (EMsgComposer *composer, const char *name,
* @name: the header name
*
* Searches for the header and if found it removes it .
- **/
+ **/
void
e_msg_composer_remove_header (EMsgComposer *composer, const char *name)
{
@@ -5205,7 +5205,7 @@ e_msg_composer_remove_header (EMsgComposer *composer, const char *name)
for (i = 0; i < p->extra_hdr_names->len; i++) {
if (strcmp (p->extra_hdr_names->pdata[i], name) == 0) {
- g_print ("Hit : %s",name);
+ g_print ("Hit : %s",name);
g_ptr_array_remove_index (p->extra_hdr_names, i);
g_ptr_array_remove_index (p->extra_hdr_values, i);
}
@@ -5223,10 +5223,10 @@ e_msg_composer_attach (EMsgComposer *composer, CamelMimePart *attachment)
{
EAttachmentBar *bar;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
g_return_if_fail (CAMEL_IS_MIME_PART (attachment));
-
+
bar = E_ATTACHMENT_BAR (p->attachment_bar);
e_attachment_bar_attach_mime_part (bar, attachment);
@@ -5258,45 +5258,45 @@ e_msg_composer_add_inline_image_from_file (EMsgComposer *composer,
dec_file_name = g_strdup(file_name);
camel_url_decode(dec_file_name);
-
+
/* check for regular file */
if (g_stat (dec_file_name, &statbuf) < 0 || !S_ISREG (statbuf.st_mode))
return NULL;
-
+
stream = camel_stream_fs_new_with_name (dec_file_name, O_RDONLY, 0);
if (!stream)
return NULL;
-
+
wrapper = camel_data_wrapper_new ();
camel_data_wrapper_construct_from_stream (wrapper, stream);
camel_object_unref (CAMEL_OBJECT (stream));
-
+
mime_type = e_msg_composer_guess_mime_type (dec_file_name);
camel_data_wrapper_set_mime_type (wrapper, mime_type ? mime_type : "application/octet-stream");
g_free (mime_type);
-
+
part = camel_mime_part_new ();
camel_medium_set_content_object (CAMEL_MEDIUM (part), wrapper);
camel_object_unref (wrapper);
-
+
cid = camel_header_msgid_generate ();
camel_mime_part_set_content_id (part, cid);
name = g_path_get_basename(dec_file_name);
camel_mime_part_set_filename (part, name);
g_free(name);
camel_mime_part_set_encoding (part, CAMEL_TRANSFER_ENCODING_BASE64);
-
+
url = g_strdup_printf ("file:%s", dec_file_name);
g_hash_table_insert (p->inline_images_by_url, url, part);
-
+
url = g_strdup_printf ("cid:%s", cid);
g_hash_table_insert (p->inline_images, url, part);
g_free (cid);
g_free(dec_file_name);
-
+
return part;
-}
+}
/**
@@ -5320,11 +5320,11 @@ e_msg_composer_add_inline_image_from_mime_part (EMsgComposer *composer,
camel_mime_part_set_content_id (part, NULL);
cid = camel_mime_part_get_content_id (part);
}
-
+
url = g_strdup_printf ("cid:%s", cid);
g_hash_table_insert (p->inline_images, url, part);
camel_object_ref (part);
-
+
location = camel_mime_part_get_content_location (part);
if (location) {
g_hash_table_insert (p->inline_images_by_url,
@@ -5336,11 +5336,11 @@ e_msg_composer_add_inline_image_from_mime_part (EMsgComposer *composer,
/**
* e_msg_composer_get_message:
* @composer: A message composer widget
- *
+ *
* Retrieve the message edited by the user as a CamelMimeMessage. The
* CamelMimeMessage object is created on the fly; subsequent calls to this
* function will always create new objects from scratch.
- *
+ *
* Return value: A pointer to the new CamelMimeMessage object
**/
CamelMimeMessage *
@@ -5352,7 +5352,7 @@ e_msg_composer_get_message (EMsgComposer *composer, gboolean save_html_object_da
return NULL;
}
}
-
+
return build_message (composer, save_html_object_data);
}
@@ -5409,7 +5409,7 @@ e_msg_composer_get_message_draft (EMsgComposer *composer)
GString *flags;
int i;
EMsgComposerPrivate *p = composer->priv;
-
+
/* always save drafts as HTML to preserve formatting */
old_send_html = p->send_html;
p->send_html = TRUE;
@@ -5421,20 +5421,20 @@ e_msg_composer_get_message_draft (EMsgComposer *composer)
p->smime_sign = FALSE;
old_flags[3] = p->smime_encrypt;
p->smime_encrypt = FALSE;
-
+
msg = build_message (composer, TRUE);
-
+
p->send_html = old_send_html;
p->pgp_sign = old_flags[0];
p->pgp_encrypt = old_flags[1];
p->smime_sign = old_flags[2];
p->smime_encrypt = old_flags[3];
-
+
/* Attach account info to the draft. */
account = e_msg_composer_get_preferred_account (composer);
if (account && account->name)
camel_medium_set_header (CAMEL_MEDIUM (msg), "X-Evolution-Account", account->uid);
-
+
/* build_message() set this to text/html since we set p->send_html to
TRUE before calling e_msg_composer_get_message() */
if (!p->send_html)
@@ -5461,7 +5461,7 @@ delete_old_signature (EMsgComposer *composer)
{
CORBA_Environment ev;
EMsgComposerPrivate *p = composer->priv;
-
+
/* printf ("delete_old_signature\n"); */
CORBA_exception_init (&ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "block-selection", &ev);
@@ -5484,7 +5484,7 @@ delete_old_signature (EMsgComposer *composer)
/**
* e_msg_composer_show_sig:
* @composer: A message composer widget
- *
+ *
* Set a signature
**/
void
@@ -5494,7 +5494,7 @@ e_msg_composer_show_sig_file (EMsgComposer *composer)
char *html;
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
/* printf ("e_msg_composer_show_sig_file\n"); */
/* printf ("set sig '%s' '%s'\n", sig_file, p->sig_file); */
if (!p->redirect) {
@@ -5503,7 +5503,7 @@ e_msg_composer_show_sig_file (EMsgComposer *composer)
GNOME_GtkHTML_Editor_Engine_freeze (p->eeditor_engine, &ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "cursor-position-save", &ev);
GNOME_GtkHTML_Editor_Engine_undoBegin (p->eeditor_engine, "Set signature", "Reset signature", &ev);
-
+
delete_old_signature (composer);
html = get_signature_html (composer);
if (html) {
@@ -5519,7 +5519,7 @@ e_msg_composer_show_sig_file (EMsgComposer *composer)
GNOME_GtkHTML_Editor_Engine_insertHTML (p->eeditor_engine, html, &ev);
g_free (html);
}
-
+
GNOME_GtkHTML_Editor_Engine_undoEnd (p->eeditor_engine, &ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "cursor-position-restore", &ev);
GNOME_GtkHTML_Editor_Engine_thaw (p->eeditor_engine, &ev);
@@ -5534,7 +5534,7 @@ e_msg_composer_show_sig_file (EMsgComposer *composer)
* e_msg_composer_set_send_html:
* @composer: A message composer widget
* @send_html: Whether the composer should have the "Send HTML" flag set
- *
+ *
* Set the status of the "Send HTML" toggle item. The user can override it.
**/
void
@@ -5543,30 +5543,30 @@ e_msg_composer_set_send_html (EMsgComposer *composer,
{
CORBA_Environment ev;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if (p->send_html && send_html)
return;
-
+
if (!p->send_html && !send_html)
return;
-
+
p->send_html = send_html;
-
+
CORBA_exception_init (&ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "block-redraw", &ev);
CORBA_exception_free (&ev);
-
+
bonobo_ui_component_set_prop (p->uic, "/commands/FormatHtml",
"state", p->send_html ? "1" : "0", NULL);
-
+
/* let the editor know which mode we are in */
bonobo_widget_set_property (BONOBO_WIDGET (p->eeditor),
"FormatHTML", TC_CORBA_boolean,
p->send_html, NULL);
-
-
+
+
CORBA_exception_init (&ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "unblock-redraw", &ev);
CORBA_exception_free (&ev);
@@ -5576,9 +5576,9 @@ e_msg_composer_set_send_html (EMsgComposer *composer,
/**
* e_msg_composer_get_send_html:
* @composer: A message composer widget
- *
+ *
* Get the status of the "Send HTML mail" flag.
- *
+ *
* Return value: The status of the "Send HTML mail" flag.
**/
gboolean
@@ -5587,7 +5587,7 @@ e_msg_composer_get_send_html (EMsgComposer *composer)
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->send_html;
}
@@ -5603,11 +5603,11 @@ e_msg_composer_get_preferred_account (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
EMsgComposerHdrs *hdrs;
-
+
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), NULL);
-
+
hdrs = E_MSG_COMPOSER_HDRS (p->hdrs);
-
+
return hdrs->account;
}
@@ -5616,7 +5616,7 @@ e_msg_composer_get_preferred_account (EMsgComposer *composer)
* e_msg_composer_set_pgp_sign:
* @composer: A message composer widget
* @send_html: Whether the composer should have the "PGP Sign" flag set
- *
+ *
* Set the status of the "PGP Sign" toggle item. The user can override it.
**/
void
@@ -5624,15 +5624,15 @@ e_msg_composer_set_pgp_sign (EMsgComposer *composer, gboolean pgp_sign)
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if (p->pgp_sign && pgp_sign)
return;
if (!p->pgp_sign && !pgp_sign)
return;
-
+
p->pgp_sign = pgp_sign;
e_msg_composer_set_changed (composer);
-
+
bonobo_ui_component_set_prop (p->uic, "/commands/SecurityPGPSign",
"state", p->pgp_sign ? "1" : "0", NULL);
}
@@ -5641,9 +5641,9 @@ e_msg_composer_set_pgp_sign (EMsgComposer *composer, gboolean pgp_sign)
/**
* e_msg_composer_get_pgp_sign:
* @composer: A message composer widget
- *
+ *
* Get the status of the "PGP Sign" flag.
- *
+ *
* Return value: The status of the "PGP Sign" flag.
**/
gboolean
@@ -5651,7 +5651,7 @@ e_msg_composer_get_pgp_sign (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->pgp_sign;
}
@@ -5660,7 +5660,7 @@ e_msg_composer_get_pgp_sign (EMsgComposer *composer)
* e_msg_composer_set_pgp_encrypt:
* @composer: A message composer widget
* @send_html: Whether the composer should have the "PGP Encrypt" flag set
- *
+ *
* Set the status of the "PGP Encrypt" toggle item. The user can override it.
**/
void
@@ -5668,15 +5668,15 @@ e_msg_composer_set_pgp_encrypt (EMsgComposer *composer, gboolean pgp_encrypt)
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if (p->pgp_encrypt && pgp_encrypt)
return;
if (!p->pgp_encrypt && !pgp_encrypt)
return;
-
+
p->pgp_encrypt = pgp_encrypt;
e_msg_composer_set_changed (composer);
-
+
bonobo_ui_component_set_prop (p->uic, "/commands/SecurityPGPEncrypt",
"state", p->pgp_encrypt ? "1" : "0", NULL);
}
@@ -5685,9 +5685,9 @@ e_msg_composer_set_pgp_encrypt (EMsgComposer *composer, gboolean pgp_encrypt)
/**
* e_msg_composer_get_pgp_encrypt:
* @composer: A message composer widget
- *
+ *
* Get the status of the "PGP Encrypt" flag.
- *
+ *
* Return value: The status of the "PGP Encrypt" flag.
**/
gboolean
@@ -5695,7 +5695,7 @@ e_msg_composer_get_pgp_encrypt (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->pgp_encrypt;
}
@@ -5704,7 +5704,7 @@ e_msg_composer_get_pgp_encrypt (EMsgComposer *composer)
* e_msg_composer_set_smime_sign:
* @composer: A message composer widget
* @send_html: Whether the composer should have the "S/MIME Sign" flag set
- *
+ *
* Set the status of the "S/MIME Sign" toggle item. The user can override it.
**/
void
@@ -5712,13 +5712,13 @@ e_msg_composer_set_smime_sign (EMsgComposer *composer, gboolean smime_sign)
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if (p->smime_sign && smime_sign)
return;
if (!p->smime_sign && !smime_sign)
return;
-
- p->smime_sign = smime_sign;
+
+ p->smime_sign = smime_sign;
e_msg_composer_set_changed (composer);
bonobo_ui_component_set_prop (p->uic, "/commands/SecuritySMimeSign",
@@ -5729,9 +5729,9 @@ e_msg_composer_set_smime_sign (EMsgComposer *composer, gboolean smime_sign)
/**
* e_msg_composer_get_smime_sign:
* @composer: A message composer widget
- *
+ *
* Get the status of the "S/MIME Sign" flag.
- *
+ *
* Return value: The status of the "S/MIME Sign" flag.
**/
gboolean
@@ -5739,7 +5739,7 @@ e_msg_composer_get_smime_sign (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->smime_sign;
}
@@ -5748,7 +5748,7 @@ e_msg_composer_get_smime_sign (EMsgComposer *composer)
* e_msg_composer_set_smime_encrypt:
* @composer: A message composer widget
* @send_html: Whether the composer should have the "S/MIME Encrypt" flag set
- *
+ *
* Set the status of the "S/MIME Encrypt" toggle item. The user can override it.
**/
void
@@ -5756,15 +5756,15 @@ e_msg_composer_set_smime_encrypt (EMsgComposer *composer, gboolean smime_encrypt
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if (p->smime_encrypt && smime_encrypt)
return;
if (!p->smime_encrypt && !smime_encrypt)
return;
-
+
p->smime_encrypt = smime_encrypt;
e_msg_composer_set_changed (composer);
-
+
bonobo_ui_component_set_prop (p->uic, "/commands/SecuritySMimeEncrypt",
"state", p->smime_encrypt ? "1" : "0", NULL);
}
@@ -5773,9 +5773,9 @@ e_msg_composer_set_smime_encrypt (EMsgComposer *composer, gboolean smime_encrypt
/**
* e_msg_composer_get_smime_encrypt:
* @composer: A message composer widget
- *
+ *
* Get the status of the "S/MIME Encrypt" flag.
- *
+ *
* Return value: The status of the "S/MIME Encrypt" flag.
**/
gboolean
@@ -5783,7 +5783,7 @@ e_msg_composer_get_smime_encrypt (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->smime_encrypt;
}
@@ -5791,9 +5791,9 @@ e_msg_composer_get_smime_encrypt (EMsgComposer *composer)
/**
* e_msg_composer_get_view_from:
* @composer: A message composer widget
- *
+ *
* Get the status of the "View From header" flag.
- *
+ *
* Return value: The status of the "View From header" flag.
**/
gboolean
@@ -5801,7 +5801,7 @@ e_msg_composer_get_view_from (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->view_from;
}
@@ -5818,21 +5818,21 @@ e_msg_composer_set_view_from (EMsgComposer *composer, gboolean view_from)
{
EMsgComposerPrivate *p = composer->priv;
GConfClient *gconf;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if ((p->view_from && view_from) ||
(!p->view_from && !view_from))
return;
-
+
p->view_from = view_from;
bonobo_ui_component_set_prop (p->uic, "/commands/ViewFrom",
"state", p->view_from ? "1" : "0", NULL);
-
+
gconf = gconf_client_get_default ();
gconf_client_set_bool (gconf, "/apps/evolution/mail/composer/view/From", view_from, NULL);
g_object_unref (gconf);
-
+
e_msg_composer_hdrs_set_visible (E_MSG_COMPOSER_HDRS (p->hdrs),
e_msg_composer_get_visible_flags (composer));
}
@@ -5851,7 +5851,7 @@ e_msg_composer_get_view_replyto (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->view_replyto;
}
@@ -5868,22 +5868,22 @@ e_msg_composer_set_view_replyto (EMsgComposer *composer, gboolean view_replyto)
{
EMsgComposerPrivate *p = composer->priv;
GConfClient *gconf;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if ((p->view_replyto && view_replyto) ||
(!p->view_replyto && !view_replyto))
return;
-
+
p->view_replyto = view_replyto;
bonobo_ui_component_set_prop (p->uic, "/commands/ViewReplyTo",
"state", p->view_replyto ? "1" : "0", NULL);
-
+
/* we do this /only/ if the fields is in the visible_mask */
gconf = gconf_client_get_default ();
gconf_client_set_bool (gconf, "/apps/evolution/mail/composer/view/ReplyTo", view_replyto, NULL);
g_object_unref (gconf);
-
+
e_msg_composer_hdrs_set_visible (E_MSG_COMPOSER_HDRS (p->hdrs),
e_msg_composer_get_visible_flags (composer));
}
@@ -5902,7 +5902,7 @@ e_msg_composer_get_view_to (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->view_to;
}
@@ -5919,23 +5919,23 @@ e_msg_composer_set_view_to (EMsgComposer *composer, gboolean view_to)
{
EMsgComposerPrivate *p = composer->priv;
GConfClient *gconf;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if ((p->view_to && view_to) ||
(!p->view_to && !view_to))
return;
-
+
p->view_to = view_to;
bonobo_ui_component_set_prop (p->uic, "/commands/ViewTo",
"state", p->view_to ? "1" : "0", NULL);
-
+
if ((E_MSG_COMPOSER_HDRS(p->hdrs))->visible_mask & E_MSG_COMPOSER_VISIBLE_TO) {
gconf = gconf_client_get_default ();
gconf_client_set_bool (gconf, "/apps/evolution/mail/composer/view/To", view_to, NULL);
g_object_unref (gconf);
}
-
+
e_msg_composer_hdrs_set_visible (E_MSG_COMPOSER_HDRS (p->hdrs),
e_msg_composer_get_visible_flags (composer));
}
@@ -5955,7 +5955,7 @@ e_msg_composer_get_view_postto (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->view_postto;
}
@@ -5972,23 +5972,23 @@ e_msg_composer_set_view_postto (EMsgComposer *composer, gboolean view_postto)
{
GConfClient *gconf;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if ((p->view_postto && view_postto) ||
(!p->view_postto && !view_postto))
return;
-
+
p->view_postto = view_postto;
bonobo_ui_component_set_prop (p->uic, "/commands/ViewPostTo",
"state", p->view_postto ? "1" : "0", NULL);
-
+
if ((E_MSG_COMPOSER_HDRS(p->hdrs))->visible_mask & E_MSG_COMPOSER_VISIBLE_POSTTO) {
gconf = gconf_client_get_default ();
gconf_client_set_bool (gconf, "/apps/evolution/mail/composer/view/PostTo", view_postto, NULL);
g_object_unref (gconf);
}
-
+
e_msg_composer_hdrs_set_visible (E_MSG_COMPOSER_HDRS (p->hdrs),
e_msg_composer_get_visible_flags (composer));
}
@@ -5998,9 +5998,9 @@ e_msg_composer_set_view_postto (EMsgComposer *composer, gboolean view_postto)
/**
* e_msg_composer_get_view_cc:
* @composer: A message composer widget
- *
+ *
* Get the status of the "View CC header" flag.
- *
+ *
* Return value: The status of the "View CC header" flag.
**/
gboolean
@@ -6008,7 +6008,7 @@ e_msg_composer_get_view_cc (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->view_cc;
}
@@ -6025,23 +6025,23 @@ e_msg_composer_set_view_cc (EMsgComposer *composer, gboolean view_cc)
{
GConfClient *gconf;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if ((p->view_cc && view_cc) ||
(!p->view_cc && !view_cc))
return;
-
+
p->view_cc = view_cc;
bonobo_ui_component_set_prop (p->uic, "/commands/ViewCC",
"state", p->view_cc ? "1" : "0", NULL);
-
+
if ((E_MSG_COMPOSER_HDRS (p->hdrs))->visible_mask & E_MSG_COMPOSER_VISIBLE_CC) {
gconf = gconf_client_get_default ();
gconf_client_set_bool (gconf, "/apps/evolution/mail/composer/view/Cc", view_cc, NULL);
g_object_unref (gconf);
}
-
+
e_msg_composer_hdrs_set_visible (E_MSG_COMPOSER_HDRS (p->hdrs),
e_msg_composer_get_visible_flags (composer));
}
@@ -6051,9 +6051,9 @@ e_msg_composer_set_view_cc (EMsgComposer *composer, gboolean view_cc)
/**
* e_msg_composer_get_view_bcc:
* @composer: A message composer widget
- *
+ *
* Get the status of the "View BCC header" flag.
- *
+ *
* Return value: The status of the "View BCC header" flag.
**/
gboolean
@@ -6062,7 +6062,7 @@ e_msg_composer_get_view_bcc (EMsgComposer *composer)
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->view_bcc;
}
@@ -6079,23 +6079,23 @@ e_msg_composer_set_view_bcc (EMsgComposer *composer, gboolean view_bcc)
{
GConfClient *gconf;
EMsgComposerPrivate *p = composer->priv;
-
+
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if ((p->view_bcc && view_bcc) ||
(!p->view_bcc && !view_bcc))
return;
-
+
p->view_bcc = view_bcc;
bonobo_ui_component_set_prop (p->uic, "/commands/ViewBCC",
"state", p->view_bcc ? "1" : "0", NULL);
-
+
if ((E_MSG_COMPOSER_HDRS (p->hdrs))->visible_mask & E_MSG_COMPOSER_VISIBLE_BCC) {
gconf = gconf_client_get_default ();
gconf_client_set_bool (gconf, "/apps/evolution/mail/composer/view/Bcc", view_bcc, NULL);
g_object_unref (gconf);
}
-
+
e_msg_composer_hdrs_set_visible (E_MSG_COMPOSER_HDRS (p->hdrs),
e_msg_composer_get_visible_flags (composer));
}
@@ -6105,9 +6105,9 @@ e_msg_composer_set_view_bcc (EMsgComposer *composer, gboolean view_bcc)
/**
* e_msg_composer_get_request_receipt
* @composer: A message composer widget
- *
+ *
* Get the status of the "Request receipt" flag.
- *
+ *
* Return value: The status of the "Request receipt" flag.
**/
gboolean
@@ -6115,7 +6115,7 @@ e_msg_composer_get_request_receipt (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->request_receipt;
}
@@ -6132,11 +6132,11 @@ e_msg_composer_set_request_receipt (EMsgComposer *composer, gboolean request_rec
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if ((p->request_receipt && request_receipt) ||
(!p->request_receipt && !request_receipt))
return;
-
+
p->request_receipt = request_receipt;
bonobo_ui_component_set_prop (p->uic, "/commands/RequestReceipt",
"state", p->request_receipt ? "1" : "0", NULL);
@@ -6146,9 +6146,9 @@ e_msg_composer_set_request_receipt (EMsgComposer *composer, gboolean request_rec
/**
* e_msg_composer_get_priority
* @composer: A message composer widget
- *
+ *
* Get the status of the "Priority" flag.
- *
+ *
* Return value: The status of the "Priority" flag.
**/
gboolean
@@ -6156,7 +6156,7 @@ e_msg_composer_get_priority (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), FALSE);
-
+
return p->set_priority;
}
@@ -6173,11 +6173,11 @@ e_msg_composer_set_priority (EMsgComposer *composer, gboolean set_priority)
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
if ((p->set_priority && set_priority) ||
(!p->set_priority && !set_priority))
return;
-
+
p->set_priority= set_priority;
bonobo_ui_component_set_prop (p->uic, "/commands/SetPriority",
"state", p->set_priority ? "1" : "0", NULL);
@@ -6197,7 +6197,7 @@ e_msg_composer_get_to (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), NULL);
-
+
return p->hdrs ? e_msg_composer_hdrs_get_to (E_MSG_COMPOSER_HDRS (p->hdrs)) : NULL;
}
@@ -6206,7 +6206,7 @@ e_msg_composer_get_cc (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), NULL);
-
+
return p->hdrs ? e_msg_composer_hdrs_get_cc (E_MSG_COMPOSER_HDRS (p->hdrs)) : NULL;
}
@@ -6215,7 +6215,7 @@ e_msg_composer_get_bcc (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), NULL);
-
+
return p->hdrs ? e_msg_composer_hdrs_get_bcc (E_MSG_COMPOSER_HDRS (p->hdrs)) : NULL;
}
@@ -6224,7 +6224,7 @@ e_msg_composer_get_subject (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_val_if_fail (E_IS_MSG_COMPOSER (composer), NULL);
-
+
return p->hdrs ? e_msg_composer_hdrs_get_subject (E_MSG_COMPOSER_HDRS (p->hdrs)) : NULL;
}
@@ -6268,7 +6268,7 @@ e_msg_composer_set_changed (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
p->has_changed = TRUE;
}
@@ -6285,7 +6285,7 @@ e_msg_composer_unset_changed (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
p->has_changed = FALSE;
}
@@ -6295,7 +6295,7 @@ e_msg_composer_is_dirty (EMsgComposer *composer)
EMsgComposerPrivate *p = composer->priv;
CORBA_Environment ev;
gboolean rv;
-
+
CORBA_exception_init (&ev);
rv = p->has_changed
|| (GNOME_GtkHTML_Editor_Engine_hasUndo (p->eeditor_engine, &ev) &&
@@ -6334,13 +6334,13 @@ e_msg_composer_unset_autosaved (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
g_return_if_fail (E_IS_MSG_COMPOSER (composer));
-
+
p->autosaved = FALSE;
}
/**
* e_msg_composer_get_raw_message_text:
- *
+ *
* Returns the text/plain of the message from composer
**/
const gchar *
@@ -6388,7 +6388,7 @@ e_msg_composer_drop_editor_undo (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
CORBA_Environment ev;
-
+
CORBA_exception_init (&ev);
GNOME_GtkHTML_Editor_Engine_dropUndo (p->eeditor_engine, &ev);
CORBA_exception_free (&ev);
@@ -6429,7 +6429,7 @@ e_msg_composer_show_attachments_ui (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
- if (e_attachment_bar_get_num_attachments(E_ATTACHMENT_BAR(p->attachment_bar)))
+ if (e_attachment_bar_get_num_attachments(E_ATTACHMENT_BAR(p->attachment_bar)))
show_attachments (composer, TRUE);
}
@@ -6437,7 +6437,7 @@ void
e_msg_composer_set_alternative (EMsgComposer *composer, gboolean alt)
{
EMsgComposerPrivate *p = composer->priv;
-
+
p->is_alternative = alt;
p->send_html = !alt;
}
@@ -6447,9 +6447,9 @@ e_msg_composer_reply_indent (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
CORBA_Environment ev;
-
+
CORBA_exception_init (&ev);
-
+
if (!GNOME_GtkHTML_Editor_Engine_isParagraphEmpty (p->eeditor_engine, &ev)) {
if (GNOME_GtkHTML_Editor_Engine_isPreviousParagraphEmpty (p->eeditor_engine, &ev))
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "cursor-backward", &ev);
@@ -6465,7 +6465,7 @@ e_msg_composer_reply_indent (EMsgComposer *composer)
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "indent-zero", &ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "text-default-color", &ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "italic-off", &ev);
-
+
CORBA_exception_free (&ev);
}
@@ -6475,9 +6475,9 @@ e_msg_composer_insert_paragraph_before (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
CORBA_Environment ev;
-
+
CORBA_exception_init (&ev);
-
+
if (!p->in_signature_insert) {
CORBA_char *orig, *signature;
gboolean changed = FALSE;
@@ -6504,7 +6504,7 @@ e_msg_composer_insert_paragraph_before (EMsgComposer *composer)
}
}
}
-
+
CORBA_exception_free (&ev);
}
@@ -6527,14 +6527,14 @@ e_msg_composer_insert_paragraph_after (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
CORBA_Environment ev;
-
+
CORBA_exception_init (&ev);
-
+
if (!p->in_signature_insert) {
CORBA_char *orig, *signature;
/* FIXME check for insert-paragraph command */
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "italic-off", &ev);
-
+
orig = GNOME_GtkHTML_Editor_Engine_getParagraphData (p->eeditor_engine, "orig", &ev);
if (ev._major == CORBA_NO_EXCEPTION) {
if (orig && *orig == '1')
@@ -6549,7 +6549,7 @@ e_msg_composer_insert_paragraph_after (EMsgComposer *composer)
CORBA_free (signature);
}
}
-
+
CORBA_exception_free (&ev);
}
@@ -6558,13 +6558,13 @@ e_msg_composer_delete (EMsgComposer *composer)
{
EMsgComposerPrivate *p = composer->priv;
CORBA_Environment ev;
-
+
CORBA_exception_init (&ev);
-
+
if (GNOME_GtkHTML_Editor_Engine_isParagraphEmpty (p->eeditor_engine, &ev)) {
CORBA_char *orig;
CORBA_char *signature;
-
+
orig = GNOME_GtkHTML_Editor_Engine_getParagraphData (p->eeditor_engine, "orig", &ev);
if (ev._major == CORBA_NO_EXCEPTION) {
if (orig && *orig == '1') {
@@ -6621,7 +6621,7 @@ e_msg_composer_url_requested (EMsgComposer *composer, gchar *url)
{
EMsgComposerPrivate *p = composer->priv;
CamelMimePart *part = NULL;
-
+
part = g_hash_table_lookup (p->inline_images_by_url, url);
if (!part)
part = g_hash_table_lookup (p->inline_images, url);
@@ -6663,7 +6663,7 @@ e_msg_composer_set_saved (EMsgComposer *composer)
{
CORBA_Environment ev;
EMsgComposerPrivate *p = composer->priv;
-
+
CORBA_exception_init (&ev);
GNOME_GtkHTML_Editor_Engine_runCommand (p->eeditor_engine, "saved", &ev);
CORBA_exception_free (&ev);
@@ -6674,6 +6674,6 @@ e_msg_composer_set_send_options (EMsgComposer *composer, gboolean send_enable)
{
EMsgComposerPrivate *priv;
priv = composer->priv;
-
- priv->send_invoked = send_enable;
-}
+
+ priv->send_invoked = send_enable;
+}
diff --git a/composer/e-msg-composer.h b/composer/e-msg-composer.h
index a1ab0c1287..d285c0d6f1 100644
--- a/composer/e-msg-composer.h
+++ b/composer/e-msg-composer.h
@@ -68,7 +68,7 @@ void e_msg_composer_show_attachments_ui (EMsgComposer *composer);
void e_msg_composer_set_alternative (EMsgComposer *composer,
gboolean alt);
-
+
void e_msg_composer_set_headers (EMsgComposer *composer,
const char *from,
EDestination **to,
@@ -190,7 +190,7 @@ void e_msg_composer_link_clicked (EMsgComposer *composer, const gchar *url
EMsgComposerHdrs* e_msg_composer_get_hdrs (EMsgComposer *composer);
void e_msg_composer_set_saved (EMsgComposer *composer);
-void e_msg_composer_set_send_options (EMsgComposer *composer,
+void e_msg_composer_set_send_options (EMsgComposer *composer,
gboolean send_enable);
const gchar * e_msg_composer_get_raw_message_text (EMsgComposer *composer);
diff --git a/composer/evolution-composer.c b/composer/evolution-composer.c
index adfc0bb1ef..5c20c3a6aa 100644
--- a/composer/evolution-composer.c
+++ b/composer/evolution-composer.c
@@ -69,7 +69,7 @@ corba_recipientlist_to_destv (const GNOME_Evolution_Composer_RecipientList *cl)
if (*recip->name)
e_destination_set_name (destv[i], recip->name);
e_destination_set_email (destv[i], recip->address);
-
+
}
destv[cl->_length] = NULL;
@@ -92,38 +92,38 @@ impl_Composer_set_headers (PortableServer_Servant servant,
EAccount *account;
EIterator *iter;
int found = 0;
-
+
bonobo_object = bonobo_object_from_servant (servant);
composer = EVOLUTION_COMPOSER (bonobo_object);
-
+
account = mail_config_get_account_by_name (from);
if (!account) {
accounts = mail_config_get_accounts ();
iter = e_list_get_iterator ((EList *) accounts);
while (e_iterator_is_valid (iter)) {
account = (EAccount *) e_iterator_get (iter);
-
+
if (!g_ascii_strcasecmp (account->id->address, from)) {
found = TRUE;
break;
}
-
+
e_iterator_next (iter);
}
-
+
g_object_unref (iter);
-
+
if (!found)
account = mail_config_get_default_account ();
}
-
+
tov = corba_recipientlist_to_destv (to);
ccv = corba_recipientlist_to_destv (cc);
bccv = corba_recipientlist_to_destv (bcc);
-
+
e_msg_composer_set_headers (composer->composer, account->name,
tov, ccv, bccv, subject);
-
+
e_destination_freev (tov);
e_destination_freev (ccv);
e_destination_freev (bccv);
@@ -159,7 +159,7 @@ impl_Composer_set_body (PortableServer_Servant servant,
if (!g_ascii_strcasecmp (mime_type, "text/plain")) {
char *htmlbody = camel_text_to_html (body, CAMEL_MIME_FILTER_TOHTML_PRE, 0);
-
+
e_msg_composer_set_body_text (composer->composer, htmlbody, -1);
g_free (htmlbody);
} else if (!g_ascii_strcasecmp (mime_type, "text/html"))
@@ -330,20 +330,20 @@ enum_objects (BonoboItemHandler *handler, gpointer data, CORBA_Environment *ev)
}
#endif
-static Bonobo_Unknown
+static Bonobo_Unknown
get_object (BonoboItemHandler *h, const char *item_name, gboolean only_if_exists,
gpointer data, CORBA_Environment *ev)
{
EvolutionComposer *composer = data;
GSList *options, *l;
-
+
options = bonobo_item_option_parse (item_name);
for (l = options; l; l = l->next){
BonoboItemOption *option = l->data;
if (strcmp (option->key, "visible") == 0){
gboolean show = 1;
-
+
if (option->value)
show = atoi (option->value);
@@ -362,7 +362,7 @@ evolution_composer_construct (EvolutionComposer *composer,
GNOME_Evolution_Composer corba_object)
{
BonoboObject *item_handler;
-
+
g_return_if_fail (composer != NULL);
g_return_if_fail (EVOLUTION_IS_COMPOSER (composer));
g_return_if_fail (corba_object != CORBA_OBJECT_NIL);
diff --git a/composer/listener.c b/composer/listener.c
index 9bfd11a13d..474ac5f64f 100644
--- a/composer/listener.c
+++ b/composer/listener.c
@@ -7,12 +7,12 @@
This program is free software; you can redistribute it and/or
modify it under the terms of version 2 of the GNU General Public
License as published by the Free Software Foundation.
-
+
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
-
+
You should have received a copy of the GNU General Public
License along with this program; if not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
@@ -83,7 +83,7 @@ impl_event (PortableServer_Servant _servant,
}
} else if (!strcmp (name, "image_url")) {
gchar *url;
-
+
if ((url = e_msg_composer_resolve_image_url (l->composer, BONOBO_ARG_GET_STRING (arg)))) {
rv = bonobo_arg_new (BONOBO_ARG_STRING);
BONOBO_ARG_SET_STRING (rv, url);
@@ -92,22 +92,22 @@ impl_event (PortableServer_Servant _servant,
}
} else if (!strcmp (name, "delete")) {
e_msg_composer_delete (l->composer);
-
+
} else if (!strcmp (name, "url_requested")) {
GNOME_GtkHTML_Editor_URLRequestEvent *e = arg->_value;
CamelMimePart *part;
GByteArray *ba;
CamelStream *cstream;
CamelDataWrapper *wrapper;
-
+
if (!e->url || e->stream == CORBA_OBJECT_NIL)
return get_any_null ();
part = e_msg_composer_url_requested (l->composer, e->url);
-
+
if (!part)
return get_any_null ();
-
+
/* Write the data to a CamelStreamMem... */
ba = g_byte_array_new ();
cstream = camel_stream_mem_new_with_byte_array (ba);
@@ -116,7 +116,7 @@ impl_event (PortableServer_Servant _servant,
bonobo_stream_client_write (e->stream, ba->data, ba->len, ev);
camel_object_unref (cstream);
-
+
} else if (!strcmp (name, "link_clicked")) {
e_msg_composer_link_clicked (l->composer, BONOBO_ARG_GET_STRING (arg));
}
@@ -149,6 +149,6 @@ listener_new (EMsgComposer *composer)
listener = g_object_new (EDITOR_LISTENER_TYPE, NULL);
listener->composer = composer;
-
+
return listener;
}
diff --git a/composer/listener.h b/composer/listener.h
index a66d707ffd..d9f13454c0 100644
--- a/composer/listener.h
+++ b/composer/listener.h
@@ -7,12 +7,12 @@
This program is free software; you can redistribute it and/or
modify it under the terms of version 2 of the GNU General Public
License as published by the Free Software Foundation.
-
+
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
-
+
You should have received a copy of the GNU General Public
License along with this program; if not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
diff --git a/e-util/e-bconf-map.c b/e-util/e-bconf-map.c
index 039121a1fa..b41bbe1cde 100644
--- a/e-util/e-bconf-map.c
+++ b/e-util/e-bconf-map.c
@@ -58,12 +58,12 @@ e_bconf_hex_decode (const char *val)
{
const unsigned char *p = (const unsigned char *) val;
char *o, *res;
-
+
o = res = g_malloc (strlen (val) / 2 + 1);
for (p = (const unsigned char *)val; (p[0] && p[1]); p += 2)
*o++ = (hexnib[p[0]] << 4) | hexnib[p[1]];
*o = 0;
-
+
return res;
}
@@ -72,7 +72,7 @@ e_bconf_url_decode (const char *val)
{
const unsigned char *p = (const unsigned char *) val;
char *o, *res, c;
-
+
o = res = g_malloc (strlen (val) + 1);
while (*p) {
c = *p++;
@@ -84,7 +84,7 @@ e_bconf_url_decode (const char *val)
*o++ = c;
}
*o = 0;
-
+
return res;
}
@@ -95,13 +95,13 @@ e_bconf_get_path (xmlDocPtr doc, const char *path)
xmlNodePtr root;
char *val;
int found;
-
+
root = doc->children;
if (strcmp ((char *)root->name, "bonobo-config") != 0) {
g_warning ("not bonobo-config xml file");
return NULL;
}
-
+
root = root->children;
while (root) {
if (!strcmp ((char *)root->name, "section")) {
@@ -113,7 +113,7 @@ e_bconf_get_path (xmlDocPtr doc, const char *path)
}
root = root->next;
}
-
+
return root;
}
@@ -123,7 +123,7 @@ e_bconf_get_entry (xmlNodePtr root, const char *name)
xmlNodePtr node = root->children;
int found;
char *val;
-
+
while (node) {
if (!strcmp ((char *)node->name, "entry")) {
val = (char *)xmlGetProp (node, (const unsigned char *)"name");
@@ -134,7 +134,7 @@ e_bconf_get_entry (xmlNodePtr root, const char *name)
}
node = node->next;
}
-
+
return node;
}
@@ -143,12 +143,12 @@ e_bconf_get_value (xmlNodePtr root, const char *name)
{
xmlNodePtr node = e_bconf_get_entry (root, name);
char *prop, *val = NULL;
-
+
if (node && (prop = (char *)xmlGetProp (node, (const unsigned char *)"value"))) {
val = g_strdup (prop);
xmlFree (prop);
}
-
+
return val;
}
@@ -156,13 +156,13 @@ char *
e_bconf_get_bool (xmlNodePtr root, const char *name)
{
char *val, *res;
-
+
if ((val = e_bconf_get_value (root, name))) {
res = g_strdup (val[0] == '1' ? "true" : "false");
g_free (val);
} else
res = NULL;
-
+
return res;
}
@@ -170,13 +170,13 @@ char *
e_bconf_get_long (xmlNodePtr root, const char *name)
{
char *val, *res;
-
+
if ((val = e_bconf_get_value (root, name))) {
res = g_strdup (val);
g_free (val);
} else
res = NULL;
-
+
return res;
}
@@ -184,13 +184,13 @@ char *
e_bconf_get_string (xmlNodePtr root, const char *name)
{
char *val, *res;
-
+
if ((val = e_bconf_get_value (root, name))) {
res = e_bconf_hex_decode (val);
g_free (val);
} else
res = NULL;
-
+
return res;
}
@@ -221,17 +221,17 @@ bconf_lookup_enum (xmlNodePtr root, const char *name, e_bconf_map_t *map)
{
int index = 0, i;
char *val;
-
+
if ((val = e_bconf_get_value (root, name))) {
index = atoi (val);
g_free (val);
}
-
+
for (i = 0; map->child[i].from; i++) {
if (i == index)
return g_strdup (map->child[i].from);
}
-
+
return NULL;
}
@@ -245,7 +245,7 @@ get_name (const char *in, int index)
{
GString *out = g_string_new ("");
char c, *res;
-
+
while ((c = *in++)) {
if (c == '%') {
c = *in++;
@@ -261,10 +261,10 @@ get_name (const char *in, int index)
g_string_append_c (out, c);
}
}
-
+
res = out->str;
g_string_free (out, FALSE);
-
+
return res;
}
@@ -273,7 +273,7 @@ build_xml (xmlNodePtr root, e_bconf_map_t *map, int index, xmlNodePtr source)
{
char *name, *value;
xmlNodePtr node;
-
+
while (map->type != E_BCONF_MAP_END) {
if ((map->type & E_BCONF_MAP_MASK) == E_BCONF_MAP_CHILD) {
node = xmlNewChild (root, NULL, (unsigned char *)map->to, NULL);
@@ -281,16 +281,16 @@ build_xml (xmlNodePtr root, e_bconf_map_t *map, int index, xmlNodePtr source)
} else {
name = get_name (map->from, index);
value = lookup_table[(map->type & E_BCONF_MAP_MASK) - 1] (source, name, map);
-
+
d(printf ("key '%s=%s' -> ", name, value));
-
+
if (map->type & E_BCONF_MAP_CONTENT) {
if (value && value[0])
xmlNewTextChild (root, NULL, (unsigned char *)map->to, (unsigned char *)value);
} else {
xmlSetProp (root, (unsigned char *)map->to, (unsigned char *)value);
}
-
+
g_free (value);
g_free (name);
}
@@ -308,7 +308,7 @@ e_bconf_import_xml_blob (GConfClient *gconf, xmlDocPtr config_xmldb, e_bconf_map
int count = 0, i;
GSList *list, *l;
char *val;
-
+
source = e_bconf_get_path (config_xmldb, bconf_path);
if (source) {
list = NULL;
@@ -316,37 +316,37 @@ e_bconf_import_xml_blob (GConfClient *gconf, xmlDocPtr config_xmldb, e_bconf_map
count = atoi (val);
g_free (val);
}
-
+
d(printf("Found %d blobs at %s\n", count, bconf_path));
-
+
for (i = 0; i < count; i++) {
xmlDocPtr doc;
xmlNodePtr root;
xmlChar *xmlbuf;
int n;
-
+
doc = xmlNewDoc ((const unsigned char *)"1.0");
root = xmlNewDocNode (doc, NULL, (unsigned char *)name, NULL);
xmlDocSetRootElement (doc, root);
-
+
/* This could be set with a MAP_UID type ... */
if (idparam) {
char buf[16];
-
+
sprintf (buf, "%d", i);
xmlSetProp (root, (unsigned char *)idparam, (unsigned char *)buf);
}
-
+
build_xml (root, map, i, source);
-
+
xmlDocDumpMemory (doc, &xmlbuf, &n);
xmlFreeDoc (doc);
-
+
list = g_slist_append (list, xmlbuf);
}
-
+
gconf_client_set_list (gconf, gconf_path, GCONF_VALUE_STRING, list, NULL);
-
+
while (list) {
l = list->next;
xmlFree (list->data);
@@ -356,7 +356,7 @@ e_bconf_import_xml_blob (GConfClient *gconf, xmlDocPtr config_xmldb, e_bconf_map
} else {
g_warning ("could not find '%s' in old config database, skipping", bconf_path);
}
-
+
return 0;
}
@@ -372,13 +372,13 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
GSList *list, *l;
char buf[32];
int i, j, k;
-
+
/* process all flat config */
for (i = 0; remap_list[i].root; i++) {
d(printf ("Path: %s\n", remap_list[i].root));
if (!(source = e_bconf_get_path (config_xmldb, remap_list[i].root)))
continue;
-
+
map = remap_list[i].map;
for (j = 0; map[j].from; j++) {
if (map[j].type & E_GCONF_MAP_LIST) {
@@ -401,12 +401,12 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
list = g_slist_append (list, e_bconf_hex_decode (val));
break;
}
-
+
g_free (val);
k++;
}
} while (val);
-
+
if (list) {
path = g_strdup_printf ("/apps/evolution/%s", map[j].to);
gconf_client_set_list (gconf, path, gconf_type[map[j].type & E_GCONF_MAP_MASK], list, NULL);
@@ -415,7 +415,7 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
g_slist_foreach (list, (GFunc) g_free, NULL);
g_slist_free (list);
}
-
+
continue;
} else if (map[j].type == E_GCONF_MAP_ANYLIST) {
val = NULL;
@@ -423,13 +423,13 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
if (!(val = e_bconf_get_value (source, map[j].from)))
continue;
}
-
+
d(printf (" %s = '%s' -> %s [%d]\n",
map[j].from,
val == NULL ? "(null)" : val,
map[j].to,
map[j].type));
-
+
path = g_strdup_printf ("/apps/evolution/%s", map[j].to);
switch (map[j].type) {
case E_GCONF_MAP_BOOL:
@@ -455,13 +455,13 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
case E_GCONF_MAP_STRLIST: {
char *v = e_bconf_hex_decode (val);
char **t = g_strsplit (v, " !<-->!", 8196);
-
+
list = NULL;
for (k = 0; t[k]; k++) {
list = g_slist_append (list, t[k]);
d(printf (" [%d] = '%s'\n", k, t[k]));
}
-
+
gconf_client_set_list (gconf, path, GCONF_VALUE_STRING, list, NULL);
g_slist_free (list);
g_strfreev (t);
@@ -470,12 +470,12 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
case E_GCONF_MAP_ANYLIST: {
xmlNodePtr node = source->children;
list = NULL;
-
+
/* find the entry node */
while (node) {
if (!strcmp ((char *)node->name, "entry")) {
int found;
-
+
if ((tmp = (char *)xmlGetProp (node, (const unsigned char *)"name"))) {
found = strcmp ((char *)tmp, map[j].from) == 0;
xmlFree (tmp);
@@ -483,10 +483,10 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
break;
}
}
-
+
node = node->next;
}
-
+
/* find the the any block */
if (node) {
node = node->children;
@@ -496,7 +496,7 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
node = node->next;
}
}
-
+
/* skip to the value inside it */
if (node) {
node = node->children;
@@ -506,7 +506,7 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
node = node->next;
}
}
-
+
if (node) {
node = node->children;
while (node) {
@@ -515,7 +515,7 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
node = node->next;
}
}
-
+
/* & store */
if (list) {
gconf_client_set_list (gconf, path, GCONF_VALUE_STRING, list, NULL);
@@ -526,19 +526,19 @@ e_bconf_import (GConfClient *gconf, xmlDocPtr config_xmldb, e_gconf_map_list_t *
list = l;
}
}
-
+
break; }
case E_GCONF_MAP_COLOUR:
sprintf (buf, "#%06x", atoi (val) & 0xffffff);
gconf_client_set_string (gconf, path, buf, NULL);
break;
}
-
+
/* FIXME: handle errors */
g_free (path);
g_free (val);
}
}
-
+
return 0;
}
diff --git a/e-util/e-bit-array.c b/e-util/e-bit-array.c
index a4af5e76b5..572f0d4009 100644
--- a/e-util/e-bit-array.c
+++ b/e-util/e-bit-array.c
@@ -153,7 +153,7 @@ eba_dispose (GObject *object)
(* G_OBJECT_CLASS (e_bit_array_parent_class)->dispose) (object);
}
-/**
+/**
* e_selection_model_is_row_selected
* @selection: #EBitArray to check
* @n: The row to check
@@ -172,7 +172,7 @@ e_bit_array_value_at (EBitArray *eba,
return (eba->data[BOX(n)] >> OFFSET(n)) & 0x1;
}
-/**
+/**
* e_selection_model_foreach
* @selection: #EBitArray to traverse
* @callback: The callback function to call back.
@@ -181,7 +181,7 @@ e_bit_array_value_at (EBitArray *eba,
* This routine calls the given callback function once for each
* selected row, passing closure as the closure.
*/
-void
+void
e_bit_array_foreach (EBitArray *eba,
EForeachFunc callback,
gpointer closure)
@@ -202,7 +202,7 @@ e_bit_array_foreach (EBitArray *eba,
}
}
-/**
+/**
* e_selection_model_clear
* @selection: #EBitArray to clear
*
@@ -219,7 +219,7 @@ e_bit_array_clear(EBitArray *eba)
#define PART(x,n) (((x) & (0x01010101 << n)) >> n)
#define SECTION(x, n) (((x) >> (n * 8)) & 0xff)
-/**
+/**
* e_selection_model_selected_count
* @selection: #EBitArray to count
*
@@ -253,7 +253,7 @@ e_bit_array_selected_count (EBitArray *eba)
return count;
}
-/**
+/**
* e_selection_model_select_all
* @selection: #EBitArray to select all
*
@@ -264,10 +264,10 @@ void
e_bit_array_select_all (EBitArray *eba)
{
int i;
-
+
if (!eba->data)
eba->data = g_new0 (guint32, (eba->bit_count + 31) / 32);
-
+
for (i = 0; i < (eba->bit_count + 31) / 32; i ++) {
eba->data[i] = ONES;
}
@@ -285,7 +285,7 @@ e_bit_array_select_all (EBitArray *eba)
}
}
-/**
+/**
* e_selection_model_invert_selection
* @selection: #EBitArray to invert
*
@@ -299,7 +299,7 @@ e_bit_array_invert_selection (EBitArray *eba)
if (!eba->data)
eba->data = g_new0 (guint32, (eba->bit_count + 31) / 32);
-
+
for (i = 0; i < (eba->bit_count + 31) / 32; i ++) {
eba->data[i] = ~eba->data[i];
}
diff --git a/e-util/e-bit-array.h b/e-util/e-bit-array.h
index 0c7ba61199..b15e50a581 100644
--- a/e-util/e-bit-array.h
+++ b/e-util/e-bit-array.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-bit-array.h
* Copyright 2000, 2001, Ximian, Inc.
*
diff --git a/e-util/e-categories-config.c b/e-util/e-categories-config.c
index 16a7671155..9907f557e3 100644
--- a/e-util/e-categories-config.c
+++ b/e-util/e-categories-config.c
@@ -78,22 +78,22 @@ e_categories_config_open_dialog_for_entry (GtkEntry *entry)
GtkDialog *dialog;
const char *text;
int result;
-
+
g_return_if_fail (entry != NULL);
g_return_if_fail (GTK_IS_ENTRY (entry));
-
+
text = gtk_entry_get_text (GTK_ENTRY (entry));
dialog = GTK_DIALOG (e_categories_dialog_new (text));
gtk_window_set_transient_for (GTK_WINDOW (dialog), GTK_WINDOW(gtk_widget_get_toplevel (GTK_WIDGET (entry))));
-
+
/* run the dialog */
result = gtk_dialog_run (dialog);
-
+
if (result == GTK_RESPONSE_OK) {
text = e_categories_dialog_get_categories (E_CATEGORIES_DIALOG (dialog));
gtk_entry_set_text (GTK_ENTRY (entry), text);
}
-
+
gtk_object_destroy (GTK_OBJECT (dialog));
}
diff --git a/e-util/e-config-listener.c b/e-util/e-config-listener.c
index 44ed9c0447..b40b8e170a 100644
--- a/e-util/e-config-listener.c
+++ b/e-util/e-config-listener.c
@@ -572,7 +572,7 @@ e_config_listener_remove_dir (EConfigListener *cl, const char *dir)
slist = gconf_client_all_entries (cl->priv->db, dir, NULL);
for (iter = slist; iter != NULL; iter = iter->next) {
GConfEntry *entry = iter->data;
-
+
key = gconf_entry_get_key (entry);
gconf_client_unset (cl->priv->db, key, NULL);
gconf_entry_free (entry);
diff --git a/e-util/e-config.c b/e-util/e-config.c
index 484630cd1d..79e87c84b6 100644
--- a/e-util/e-config.c
+++ b/e-util/e-config.c
@@ -47,7 +47,7 @@
#include <glib/gi18n.h>
-#define d(x)
+#define d(x)
struct _EConfigFactory {
struct _EConfigFactory *next, *prev;
@@ -179,10 +179,10 @@ ep_base_init(GObjectClass *klass)
/**
* e_config_get_type:
- *
+ *
* Standard GObject method. Used to subclass for the concrete
* implementations.
- *
+ *
* Return value: EConfig type.
**/
GType
@@ -211,9 +211,9 @@ e_config_get_type(void)
* @type: The type of configuration manager, @E_CONFIG_BOOK or
* @E_CONFIG_DRUID.
* @id: The name of the configuration window this manager drives.
- *
+ *
* Used by implementing classes to initialise base parameters.
- *
+ *
* Return value: @ep is returned.
**/
EConfig *e_config_construct(EConfig *ep, int type, const char *id)
@@ -238,7 +238,7 @@ EConfig *e_config_construct(EConfig *ep, int type, const char *id)
* @freefunc: If supplied, called to free the item list (and/or items)
* once they are no longer needed.
* @data: Data for the callback methods.
- *
+ *
* Add new EConfigItems to the configuration window. Nothing will be
* done with them until the widget is built.
*
@@ -264,7 +264,7 @@ e_config_add_items(EConfig *ec, GSList *items, EConfigItemsFunc commitfunc, ECon
* @pageid: pageid to check.
* @check: checking callback.
* @data: user-data for the callback.
- *
+ *
* Add a page-checking function callback. It will be called to validate the
* data in the given page or pages. If @pageid is NULL then it will be called
* to validate every page, or the whole configuration window.
@@ -678,7 +678,7 @@ ec_rebuild(EConfig *emp)
}
frame = g_object_new(gtk_frame_get_type(),
- "shadow_type", GTK_SHADOW_NONE,
+ "shadow_type", GTK_SHADOW_NONE,
"label_widget", label,
"child", g_object_new(gtk_alignment_get_type(),
"left_padding", 12,
@@ -772,7 +772,7 @@ ec_rebuild(EConfig *emp)
* e_config_set_target:
* @emp: An initialised EConfig.
* @target: A target allocated from @emp.
- *
+ *
* Sets the target object for the config window. Generally the target
* is set only once, and will supply its own "changed" signal which
* can be used to drive the modal. This is a virtual method so that
@@ -800,12 +800,12 @@ ec_widget_destroy(GtkWidget *w, EConfig *ec)
/**
* e_config_create_widget:
* @emp: An initialised EConfig object.
- *
+ *
* Create the widget described by @emp. Only the core widget
* appropriate for the given type is created, i.e. a GtkNotebook for
* the E_CONFIG_BOOK type and a GnomeDruid for the E_CONFIG_DRUID
* type.
- *
+ *
* This object will be self-driving, but will not close itself once
* complete.
*
@@ -877,7 +877,7 @@ ec_dialog_response(GtkWidget *d, int id, EConfig *ec)
* @emp: Initialised and configured EMConfig derived instance.
* @parent: Parent window or NULL.
* @title: Title of window or dialog.
- *
+ *
* Create a managed GtkWindow object from @emp. This window will be
* fully driven by the EConfig @emp. If @emp.type is
* @E_CONFIG_DRUID, then this will be a toplevel GtkWindow containing
@@ -886,7 +886,7 @@ ec_dialog_response(GtkWidget *d, int id, EConfig *ec)
*
* Unless reffed otherwise, the management object @emp will be
* finalised when the widget is.
- *
+ *
* Return value: The window widget. This is also stored in @emp.window.
**/
GtkWidget *
@@ -949,9 +949,9 @@ ec_idle_handler_for_rebuild (gpointer data)
/**
* e_config_target_changed:
- * @emp:
- * @how:
- *
+ * @emp:
+ * @how:
+ *
* Indicate that the target has changed. This may be called by the
* self-aware target itself, or by the driving code. If @how is
* %E_CONFIG_TARGET_CHANGED_REBUILD, then the entire configuration
@@ -987,8 +987,8 @@ void e_config_target_changed(EConfig *emp, e_config_target_change_t how)
/**
* e_config_abort:
- * @ec:
- *
+ * @ec:
+ *
* Signify that the stateful configuration changes must be discarded
* to all listeners. This is used by self-driven druid or notebook, or
* may be used by code using the widget directly.
@@ -1007,8 +1007,8 @@ void e_config_abort(EConfig *ec)
/**
* e_config_commit:
- * @ec:
- *
+ * @ec:
+ *
* Signify that the stateful configuration changes should be saved.
* This is used by the self-driven druid or notebook, or may be used
* by code driving the widget directly.
@@ -1027,12 +1027,12 @@ void e_config_commit(EConfig *ec)
/**
* e_config_page_check:
- * @ec:
+ * @ec:
* @pageid: The path of the page item.
- *
+ *
* Check that a given page is complete. If @pageid is NULL, then check
* the whole config. No check is made that the page actually exists.
- *
+ *
* Return value: FALSE if the data is inconsistent/incomplete.
**/
gboolean e_config_page_check(EConfig *ec, const char *pageid)
@@ -1052,11 +1052,11 @@ gboolean e_config_page_check(EConfig *ec, const char *pageid)
/**
* e_config_page_get:
- * @ec:
+ * @ec:
* @pageid: The path of the page item.
- *
+ *
* Retrieve the page widget corresponding to @pageid.
- *
+ *
* Return value: The page widget. It will be the root GtkNotebook
* container or the GnomeDruidPage object.
**/
@@ -1077,12 +1077,12 @@ GtkWidget *e_config_page_get(EConfig *ec, const char *pageid)
/**
* e_config_page_next:
- * @ec:
+ * @ec:
* @pageid: The path of the page item.
- *
+ *
* Find the path of the next visible page after @pageid. If @pageid
* is NULL then find the first visible page.
- *
+ *
* Return value: The path of the next page, or @NULL if @pageid was the
* last configured and visible page.
**/
@@ -1108,12 +1108,12 @@ const char *e_config_page_next(EConfig *ec, const char *pageid)
/**
* e_config_page_next:
- * @ec:
+ * @ec:
* @pageid: The path of the page item.
- *
+ *
* Find the path of the previous visible page before @pageid. If @pageid
* is NULL then find the last visible page.
- *
+ *
* Return value: The path of the previous page, or @NULL if @pageid was the
* first configured and visible page.
**/
@@ -1147,12 +1147,12 @@ const char *e_config_page_prev(EConfig *ec, const char *pageid)
* @func: An EConfigFactoryFunc to call when the window @id is being
* created.
* @data: Callback data.
- *
+ *
* Add a config factory which will be called to add_items() any
* extra items's if wants to, to the current Config window.
*
* TODO: Make the id a pattern?
- *
+ *
* Return value: A handle to the factory.
**/
EConfigFactory *
@@ -1171,7 +1171,7 @@ e_config_class_add_factory(EConfigClass *klass, const char *id, EConfigFactoryFu
/**
* e_config_class_remove_factory:
* @f: Handle from :class_add_factory() call.
- *
+ *
* Remove a config factory. The handle @f may only be removed once.
**/
void
@@ -1187,7 +1187,7 @@ e_config_class_remove_factory(EConfigClass *klass, EConfigFactory *f)
* @ep: Parent EConfig object.
* @type: type, up to implementor
* @size: Size of object to allocate.
- *
+ *
* Allocate a new config target suitable for this class. Implementing
* classes will define the actual content of the target.
**/
@@ -1212,7 +1212,7 @@ void *e_config_target_new(EConfig *ep, int type, size_t size)
* e_config_target_free:
* @ep: Parent EConfig object.
* @o: The target to fre.
- *
+ *
* Free a target. The implementing class can override this method to
* free custom targets.
**/
@@ -1291,10 +1291,10 @@ ech_check(EConfig *ec, const char *pageid, void *data)
{
struct _EConfigHookGroup *group = data;
EConfigHookPageCheckData hdata;
-
+
if (!group->hook->hook.plugin->enabled)
return TRUE;
-
+
hdata.config = ec;
hdata.target = ec->target;
hdata.pageid = pageid?pageid:"";
@@ -1496,16 +1496,16 @@ emph_class_init(EPluginHookClass *klass)
/**
* e_config_hook_get_type:
- *
+ *
* Standard GObject function to get the object type.
- *
+ *
* Return value: The EConfigHook class type.
**/
GType
e_config_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EConfigHookClass), NULL, NULL, (GClassInitFunc) emph_class_init, NULL, NULL,
@@ -1515,7 +1515,7 @@ e_config_hook_get_type(void)
emph_parent_class = g_type_class_ref(e_plugin_hook_get_type());
type = g_type_register_static(e_plugin_hook_get_type(), "EConfigHook", &info, 0);
}
-
+
return type;
}
@@ -1525,7 +1525,7 @@ e_config_hook_get_type(void)
* @klass: The dervied EconfigHook class.
* @map: A map used to describe a single EConfigTarget type for this
* class.
- *
+ *
* Add a targe tmap to a concrete derived class of EConfig. The
* target map enumates the target types available for the implenting
* class.
diff --git a/e-util/e-config.h b/e-util/e-config.h
index c7f37a8e10..ffd4896c9d 100644
--- a/e-util/e-config.h
+++ b/e-util/e-config.h
@@ -62,11 +62,11 @@ typedef struct _GtkWidget * (*EConfigItemFactoryFunc)(EConfig *ec, EConfigItem *
/**
* enum _e_config_target_changed_t - Target changed mode.
- *
+ *
* @E_CONFIG_TARGET_CHANGED_STATE: A state of the target has changed.
* @E_CONFIG_TARGET_CHANGED_REBUILD: A state of the target has
* changed, and the UI must be reconfigured as a result.
- *
+ *
* How the target has changed. If @E_CONFIG_TARGET_CHANGED_REBUILD then a
* widget reconfigure is necessary, otherwise it is used to check if
* the widget is complete yet.
@@ -79,7 +79,7 @@ enum _e_config_target_change_t {
/**
* enum _e_config_t - configuration item type.
- *
+ *
* @E_CONFIG_BOOK: A notebook item. Only one of this or
* @E_CONFIG_DRUID may be included in the item list for the entire
* configuration description.
@@ -105,7 +105,7 @@ enum _e_config_target_change_t {
* section defined in the configuration system.
* @E_CONFIG_ITEM_TABLE: A configuration item with a parent
* @E_CONFIG_SECTION_TABLE.
- *
+ *
* A configuration item type for each configuration item added to the
* EConfig object. These are merged from all contributors to the
* configuration window, and then processed to form the combined
@@ -127,7 +127,7 @@ enum _e_config_t {
/**
* struct _EConfigItem - A configuration item.
- *
+ *
* @type: The configuration item type.
* @path: An absolute path positioning this item in the configuration
* window. This will be used as a sort key for an ASCII sort to
@@ -151,11 +151,11 @@ struct _EConfigItem {
/**
* struct _EConfigTarget - configuration context.
- *
+ *
* @config: The parent object.
* @widget: A target-specific parent widget.
* @type: The type of target, defined by implementing classes.
- *
+ *
* The base target object is used as the parent and placeholder for
* configuration context for a given configuration window. It is
* subclassed by implementing classes to provide domain-specific
@@ -172,7 +172,7 @@ struct _EConfigTarget {
/**
* struct _EConfig - A configuration management object.
- *
+ *
* @object: Superclass.
* @priv: Private data.
* @type: Either @E_CONFIG_BOOK or @E_CONFIG_DRIUD, describing the
@@ -186,7 +186,7 @@ struct _EConfigTarget {
* @window: If :create_window() is called, then the containing
* toplevel GtkDialog or GtkWindow appropriate for the @type of
* configuration window created.
- *
+ *
**/
struct _EConfig {
GObject object;
@@ -205,7 +205,7 @@ struct _EConfig {
/**
* struct _EConfigClass - Configuration management abstract class.
- *
+ *
* @object_class: Superclass.
* @factories: A list of factories registered on this type of
* configuration manager.
@@ -214,7 +214,7 @@ struct _EConfig {
* into changes on the target to propery drive the manager.
* @target_free: A virtual method used to free the target in an
* implementation-defined way.
- *
+ *
**/
struct _EConfigClass {
GObjectClass object_class;
@@ -279,7 +279,7 @@ typedef void (*EConfigHookItemFactoryFunc)(struct _EPlugin *plugin, EConfigHookI
/**
* struct _EConfigHookItemFactoryData - Factory marshalling structure.
- *
+ *
* @config: The parent EConfig. This is also available in
* @target->config but is here as a convenience. (TODO: do we need this).
* @item: The corresponding configuration item.
@@ -303,12 +303,12 @@ struct _EConfigHookItemFactoryData {
/**
* struct _EConfigHookPageCheckData - Check callback data.
- *
- * @config:
+ *
+ * @config:
* @target: The current configuration target. This is also available
* on @config->target.
* @pageid: Name of page to validate, or "" means check all configuration.
- *
+ *
**/
struct _EConfigHookPageCheckData {
EConfig *config;
@@ -318,7 +318,7 @@ struct _EConfigHookPageCheckData {
/**
* struct _EConfigHookGroup - A group of configuration items.
- *
+ *
* @hook: Parent object.
* @id: The configuration window to which these items apply.
* @target_type: The target type expected by the items. This is
@@ -345,11 +345,11 @@ struct _EConfigHookGroup {
/**
* struct _EConfigHook - Plugin hook for configuration windows.
- *
+ *
* @hook: Superclass.
* @groups: A list of EConfigHookGroup's of all configuration windows
* this plugin hooks into.
- *
+ *
**/
struct _EConfigHook {
EPluginHook hook;
@@ -360,7 +360,7 @@ struct _EConfigHook {
/**
* struct _EConfigHookClass - Abstract class for configuration window
* plugin hooks.
- *
+ *
* @hook_class: Superclass.
* @target_map: A table of EConfigHookTargetMap structures describing
* the possible target types supported by this class.
@@ -369,7 +369,7 @@ struct _EConfigHook {
*
* This is an abstract class defining the plugin hook point for
* configuration windows.
- *
+ *
**/
struct _EConfigHookClass {
EPluginHookClass hook_class;
diff --git a/e-util/e-corba-utils.c b/e-util/e-corba-utils.c
index 9fa5dc1d15..b688de6294 100644
--- a/e-util/e-corba-utils.c
+++ b/e-util/e-corba-utils.c
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/* e-html-utils.c
-*
+*
* Copyright (C) 2000 Ximian, Inc.
* Author: Ettore Perazzoli <ettore@ximian.com>
*
diff --git a/e-util/e-corba-utils.h b/e-util/e-corba-utils.h
index b93c70d41f..91fb305d52 100644
--- a/e-util/e-corba-utils.h
+++ b/e-util/e-corba-utils.h
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/* e-corba-utils.h
- *
+ *
* Copyright (C) 2000 Ximian, Inc.
* Author: Ettore Perazzoli <ettore@ximian.com>
*
diff --git a/e-util/e-cursor.c b/e-util/e-cursor.c
index 22d265ce7b..fa7fa991f9 100644
--- a/e-util/e-cursor.c
+++ b/e-util/e-cursor.c
@@ -32,13 +32,13 @@
* e_cursor_set:
* @widget: Any widget in a window, to which busy cursor has to be set
* cursor: The type of cursor to be set defined in e-cursor.h
- *
+ *
* Sets the cursor specified, to the top level window of the given widget.
- * It is not window aware, so if you popup a window, it will not have
+ * It is not window aware, so if you popup a window, it will not have
* busy cursor set. That has to be handled seperately with a new call to this
* function.
*
- * Return value:
+ * Return value:
**/
void e_cursor_set (GtkWidget *widget, ECursorType cursor)
{
diff --git a/e-util/e-dialog-utils.c b/e-util/e-dialog-utils.c
index 6aa5da34be..1c75dc83e5 100644
--- a/e-util/e-dialog-utils.c
+++ b/e-util/e-dialog-utils.c
@@ -82,7 +82,7 @@ e_notice (gpointer parent, GtkMessageType type, const char *format, ...)
str);
va_end (args);
g_free (str);
-
+
if (parent)
e_dialog_set_transient_for (GTK_WINDOW (dialog), parent);
gtk_dialog_run (GTK_DIALOG (dialog));
@@ -117,7 +117,7 @@ e_notice_with_xid (GdkNativeWindow parent, GtkMessageType type, const char *form
gtk_dialog_set_has_separator (GTK_DIALOG (dialog), FALSE);
va_end (args);
g_free (str);
-
+
if (parent)
e_dialog_set_transient_for_xid (GTK_WINDOW (dialog), parent);
gtk_dialog_run (GTK_DIALOG (dialog));
@@ -158,7 +158,7 @@ window_is_wm_toplevel (Display *display, Window window)
* e_dialog_set_transient_for:
* @dialog: a dialog window
* @parent_widget: the parent for @dialog
- *
+ *
* This sets the parent for @dialog to be @parent_widget. Unlike
* gtk_window_set_transient_for(), this doesn't need @parent_widget to
* be the actual toplevel, and also works if @parent_widget is
@@ -218,7 +218,7 @@ dialog_realized (GtkWindow *dialog, gpointer xid)
* e_dialog_set_transient_for_xid:
* @dialog: a dialog window
* @xid: the X Window parent
- *
+ *
* Like e_dialog_set_transient_for(), but use an XID to specify the
* parent window.
**/
@@ -263,7 +263,7 @@ save_ok (GtkWidget *widget, gpointer data)
GtkWidget *fs;
char **filename = data;
char *uri;
-
+
fs = gtk_widget_get_toplevel (widget);
uri = gtk_file_chooser_get_uri (GTK_FILE_CHOOSER (fs));
@@ -271,7 +271,7 @@ save_ok (GtkWidget *widget, gpointer data)
e_file_update_save_path(gtk_file_chooser_get_current_folder_uri(GTK_FILE_CHOOSER(fs)), TRUE);
*filename = uri;
}
-
+
gtk_main_quit ();
}
@@ -293,13 +293,13 @@ e_file_dialog_save (const char *title, const char *fname)
selection = e_file_get_save_filesel(NULL, title, fname, GTK_FILE_CHOOSER_ACTION_SAVE);
g_signal_connect (G_OBJECT (selection), "response", G_CALLBACK (filechooser_response), &filename);
-
+
gtk_widget_show (GTK_WIDGET (selection));
gtk_grab_add (GTK_WIDGET (selection));
gtk_main ();
-
+
gtk_widget_destroy (GTK_WIDGET (selection));
-
+
return filename;
}
@@ -309,13 +309,13 @@ save_folder_ok (GtkWidget *widget, gpointer data)
GtkWidget *fs;
char **filename = data;
char *uri;
-
+
fs = gtk_widget_get_toplevel (widget);
uri = gtk_file_chooser_get_current_folder_uri (GTK_FILE_CHOOSER (fs));
-
+
e_file_update_save_path(uri, FALSE);
*filename = uri;
-
+
gtk_main_quit ();
}
@@ -336,13 +336,13 @@ e_file_dialog_save_folder (const char *title)
selection = e_file_get_save_filesel(NULL, title, NULL, GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER);
g_signal_connect (G_OBJECT (selection), "response", G_CALLBACK (folderchooser_response), &filename);
-
+
gtk_widget_show (GTK_WIDGET (selection));
gtk_grab_add (GTK_WIDGET (selection));
gtk_main ();
-
+
gtk_widget_destroy (GTK_WIDGET (selection));
-
+
return filename;
}
diff --git a/e-util/e-dialog-widgets.c b/e-util/e-dialog-widgets.c
index 36ade95803..20f7db5ce5 100644
--- a/e-util/e-dialog-widgets.c
+++ b/e-util/e-dialog-widgets.c
@@ -58,7 +58,7 @@ dialog_destroy_cb (DialogHooks *hooks, GObject *dialog)
{
g_slist_free (hooks->whooks);
hooks->whooks = NULL;
-
+
g_free (hooks);
g_object_set_data (dialog, "dialog-hooks", NULL);
}
@@ -70,14 +70,14 @@ static DialogHooks *
get_dialog_hooks (GtkWidget *dialog)
{
DialogHooks *hooks;
-
+
hooks = g_object_get_data ((GObject *) dialog, "dialog-hooks");
if (!hooks) {
hooks = g_new0 (DialogHooks, 1);
g_object_set_data ((GObject *) dialog, "dialog-hooks", hooks);
g_object_weak_ref ((GObject *) dialog, (GWeakNotify) dialog_destroy_cb, hooks);
}
-
+
return hooks;
}
@@ -88,11 +88,11 @@ static int
value_to_index (const int *value_map, int value)
{
int i;
-
+
for (i = 0; value_map[i] != -1; i++)
if (value_map[i] == value)
return i;
-
+
return -1;
}
@@ -103,15 +103,15 @@ static int
index_to_value (const int *value_map, int index)
{
int i;
-
+
/* We do this the hard way, i.e. not as a simple array reference, to
* check for correctness.
*/
-
+
for (i = 0; value_map[i] != -1; i++)
if (i == index)
return value_map[i];
-
+
return -1;
}
@@ -121,12 +121,12 @@ hook_radio (GtkWidget *dialog, GtkRadioButton *radio, gpointer value_var, gpoint
{
const int *value_map;
int *value;
-
+
/* Set the value */
-
+
value = (int *) value_var;
value_map = (const int *) info;
-
+
e_dialog_radio_set (GTK_WIDGET (radio), *value, value_map);
}
@@ -136,10 +136,10 @@ get_radio_value (GtkRadioButton *radio, gpointer value_var, gpointer info)
{
int *value;
const int *value_map;
-
+
value = (int *) value_var;
value_map = (const int *) info;
-
+
*value = e_dialog_radio_get (GTK_WIDGET (radio), value_map);
}
@@ -149,12 +149,12 @@ hook_option_menu (GtkWidget *dialog, GtkOptionMenu *omenu, gpointer value_var, g
{
const int *value_map;
int *value;
-
+
/* Set the value */
-
+
value = (int *) value_var;
value_map = (const int *) info;
-
+
e_dialog_option_menu_set (GTK_WIDGET (omenu), *value, value_map);
}
@@ -164,10 +164,10 @@ get_option_menu_value (GtkOptionMenu *omenu, gpointer value_var, gpointer info)
{
const int *value_map;
int *value;
-
+
value = (int *) value_var;
value_map = (const int *) info;
-
+
*value = e_dialog_option_menu_get (GTK_WIDGET (omenu), value_map);
}
@@ -176,9 +176,9 @@ static void
hook_toggle (GtkWidget *dialog, GtkToggleButton *toggle, gpointer value_var, gpointer info)
{
gboolean *value;
-
+
/* Set the value */
-
+
value = (gboolean *) value_var;
e_dialog_toggle_set (GTK_WIDGET (toggle), *value);
}
@@ -188,7 +188,7 @@ static void
get_toggle_value (GtkToggleButton *toggle, gpointer value_var, gpointer info)
{
gboolean *value;
-
+
value = (gboolean *) value_var;
*value = e_dialog_toggle_get (GTK_WIDGET (toggle));
}
@@ -199,14 +199,14 @@ hook_spin_button (GtkWidget *dialog, GtkSpinButton *spin, gpointer value_var, gp
{
double *value;
GtkAdjustment *adj;
-
+
/* Set the value */
-
+
value = (double *) value_var;
e_dialog_spin_set (GTK_WIDGET (spin), *value);
-
+
/* Hook to changed */
-
+
adj = gtk_spin_button_get_adjustment (spin);
}
@@ -215,7 +215,7 @@ static void
get_spin_button_value (GtkSpinButton *spin, gpointer value_var, gpointer info)
{
double *value;
-
+
value = (double *) value_var;
*value = e_dialog_spin_get_double (GTK_WIDGET (spin));
}
@@ -225,11 +225,11 @@ static void
hook_editable (GtkWidget *dialog, GtkEditable *editable, gpointer value_var, gpointer info)
{
char **value;
-
+
/* Set the value */
-
+
value = (char **) value_var;
-
+
e_dialog_editable_set (GTK_WIDGET (editable), *value);
}
@@ -238,11 +238,11 @@ static void
get_editable_value (GtkEditable *editable, gpointer value_var, gpointer data)
{
char **value;
-
+
value = (char **) value_var;
if (*value)
g_free (*value);
-
+
*value = e_dialog_editable_get (GTK_WIDGET (editable));
}
@@ -250,19 +250,19 @@ get_editable_value (GtkEditable *editable, gpointer value_var, gpointer data)
* e_dialog_editable_set:
* @widget: A #GtkEditable widget.
* @value: String value.
- *
+ *
* Sets the string value inside a #GtkEditable-derived widget.
**/
void
e_dialog_editable_set (GtkWidget *widget, const char *value)
{
int pos = 0;
-
+
g_return_if_fail (widget != NULL);
g_return_if_fail (GTK_IS_EDITABLE (widget));
-
+
gtk_editable_delete_text (GTK_EDITABLE (widget), 0, -1);
-
+
if (value)
gtk_editable_insert_text (GTK_EDITABLE (widget), value, strlen (value), &pos);
}
@@ -270,9 +270,9 @@ e_dialog_editable_set (GtkWidget *widget, const char *value)
/**
* e_dialog_editable_get:
* @widget: A #GtkEditable widget.
- *
+ *
* Queries the string value inside a #GtkEditable-derived widget.
- *
+ *
* Return value: String value. You should free it when you are done with it.
* This function can return NULL if the string could not be converted from
* GTK+'s encoding into UTF8.
@@ -282,7 +282,7 @@ e_dialog_editable_get (GtkWidget *widget)
{
g_return_val_if_fail (widget != NULL, NULL);
g_return_val_if_fail (GTK_IS_EDITABLE (widget), NULL);
-
+
return gtk_editable_get_chars (GTK_EDITABLE (widget), 0, -1);
}
@@ -291,7 +291,7 @@ e_dialog_editable_get (GtkWidget *widget)
* @widget: A #GtkRadioButton in a radio button group.
* @value: Enumerated value.
* @value_map: Map from enumeration values to array indices.
- *
+ *
* Sets the selected item in a radio group. The specified @widget can be any of
* the #GtkRadioButtons in the group. Each radio button should correspond to an
* enumeration value; the specified @value will be mapped to an integer from
@@ -305,24 +305,24 @@ e_dialog_radio_set (GtkWidget *widget, int value, const int *value_map)
{
GSList *group, *l;
int i;
-
+
g_return_if_fail (widget != NULL);
g_return_if_fail (GTK_IS_RADIO_BUTTON (widget));
g_return_if_fail (value_map != NULL);
-
+
group = gtk_radio_button_get_group (GTK_RADIO_BUTTON (widget));
-
+
i = value_to_index (value_map, value);
if (i != -1) {
/* Groups are built by prepending items, so the list ends up in reverse
* order; we need to flip the index around.
*/
i = g_slist_length (group) - i - 1;
-
+
l = g_slist_nth (group, i);
if (!l)
g_message ("e_dialog_radio_set(): could not find index %d in radio group!", i);
-
+
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (l->data), TRUE);
} else
g_message ("e_dialog_radio_set(): could not find value %d in value map!", value);
@@ -332,11 +332,11 @@ e_dialog_radio_set (GtkWidget *widget, int value, const int *value_map)
* e_dialog_radio_get:
* @widget: A #GtkRadioButton in a radio button group.
* @value_map: Map from enumeration values to array indices.
- *
+ *
* Queries the selected item in a #GtkRadioButton group. Please read the
* description of e_dialog_radio_set() to see how @value_map maps enumeration
* values to button indices.
- *
+ *
* Return value: Enumeration value which corresponds to the selected item in the
* radio group.
**/
@@ -345,33 +345,33 @@ e_dialog_radio_get (GtkWidget *widget, const int *value_map)
{
GSList *group, *l;
int i, v;
-
+
g_return_val_if_fail (widget != NULL, -1);
g_return_val_if_fail (GTK_IS_RADIO_BUTTON (widget), -1);
g_return_val_if_fail (value_map != NULL, -1);
-
+
group = gtk_radio_button_get_group (GTK_RADIO_BUTTON (widget));
-
+
for (i = 0, l = group; l; l = l->next, i++) {
widget = GTK_WIDGET (l->data);
-
+
if (GTK_TOGGLE_BUTTON (widget)->active)
break;
}
-
+
g_return_val_if_fail (l != NULL, -1);
-
+
/* Groups are built by prepending items, so the list ends up in reverse
* order; we need to flip the index around.
*/
i = g_slist_length (group) - i - 1;
-
+
v = index_to_value (value_map, i);
if (v == -1) {
g_message ("e_dialog_radio_get(): could not find index %d in value map!", i);
return -1;
}
-
+
return v;
}
@@ -379,7 +379,7 @@ e_dialog_radio_get (GtkWidget *widget, const int *value_map)
* e_dialog_toggle_set:
* @widget: A #GtkToggleButton.
* @value: Toggle value.
- *
+ *
* Sets the value of a #GtkToggleButton-derived widget. This should not be used
* for radio buttons; it is more convenient to use use e_dialog_radio_set()
* instead.
@@ -389,18 +389,18 @@ e_dialog_toggle_set (GtkWidget *widget, gboolean value)
{
g_return_if_fail (widget != NULL);
g_return_if_fail (GTK_IS_TOGGLE_BUTTON (widget));
-
+
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (widget), value);
}
/**
* e_dialog_toggle_get:
* @widget: A #GtkToggleButton.
- *
+ *
* Queries the value of a #GtkToggleButton-derived widget. This should not be
* used for radio buttons; it is more convenient to use e_dialog_radio_get()
* instead.
- *
+ *
* Return value: Toggle value.
**/
gboolean
@@ -408,7 +408,7 @@ e_dialog_toggle_get (GtkWidget *widget)
{
g_return_val_if_fail (widget != NULL, FALSE);
g_return_val_if_fail (GTK_IS_TOGGLE_BUTTON (widget), FALSE);
-
+
return GTK_TOGGLE_BUTTON (widget)->active;
}
@@ -416,19 +416,19 @@ e_dialog_toggle_get (GtkWidget *widget)
* e_dialog_spin_set:
* @widget: A #GtkSpinButton.
* @value: Numeric value.
- *
+ *
* Sets the value of a #GtkSpinButton widget.
**/
void
e_dialog_spin_set (GtkWidget *widget, double value)
{
GtkAdjustment *adj;
-
+
g_return_if_fail (widget != NULL);
g_return_if_fail (GTK_IS_SPIN_BUTTON (widget));
-
+
adj = gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (widget));
-
+
adj->value = value;
g_signal_emit_by_name (adj, "value_changed", 0);
}
@@ -436,19 +436,19 @@ e_dialog_spin_set (GtkWidget *widget, double value)
/**
* e_dialog_spin_get_double:
* @widget: A #GtkSpinButton.
- *
+ *
* Queries the floating-point value of a #GtkSpinButton widget.
- *
+ *
* Return value: Numeric value.
**/
double
e_dialog_spin_get_double (GtkWidget *widget)
{
GtkAdjustment *adj;
-
+
g_return_val_if_fail (widget != NULL, 0.0);
g_return_val_if_fail (GTK_IS_SPIN_BUTTON (widget), 0.0);
-
+
adj = gtk_spin_button_get_adjustment (GTK_SPIN_BUTTON (widget));
return adj->value;
}
@@ -456,19 +456,19 @@ e_dialog_spin_get_double (GtkWidget *widget)
/**
* e_dialog_spin_get_int:
* @widget: A #GtkSpinButton.
- *
+ *
* Queries the integer value of a #GtkSpinButton widget.
- *
+ *
* Return value: Numeric value.
**/
int
e_dialog_spin_get_int (GtkWidget *widget)
{
double value;
-
+
g_return_val_if_fail (widget != NULL, -1);
g_return_val_if_fail (GTK_IS_SPIN_BUTTON (widget), -1);
-
+
value = e_dialog_spin_get_double (widget);
return (int) floor (value);
}
@@ -478,7 +478,7 @@ e_dialog_spin_get_int (GtkWidget *widget)
* @widget: A #GtkOptionMenu.
* @value: Enumerated value.
* @value_map: Map from enumeration values to array indices.
- *
+ *
* Sets the selected item in a #GtkOptionMenu. Please read the description of
* e_dialog_radio_set() to see how @value_map maps enumeration values to item
* indices.
@@ -487,13 +487,13 @@ void
e_dialog_option_menu_set (GtkWidget *widget, int value, const int *value_map)
{
int i;
-
+
g_return_if_fail (widget != NULL);
g_return_if_fail (GTK_IS_OPTION_MENU (widget));
g_return_if_fail (value_map != NULL);
-
+
i = value_to_index (value_map, value);
-
+
if (i != -1)
gtk_option_menu_set_history (GTK_OPTION_MENU (widget), i);
else
@@ -505,11 +505,11 @@ e_dialog_option_menu_set (GtkWidget *widget, int value, const int *value_map)
* e_dialog_option_menu_get:
* @widget: A #GtkOptionMenu.
* @value_map: Map from enumeration values to array indices.
- *
+ *
* Queries the selected item in a #GtkOptionMenu. Please read the description
* of e_dialog_radio_set() to see how @value_map maps enumeration values to item
* indices.
- *
+ *
* Return value: Enumeration value which corresponds to the selected item in the
* option menu.
**/
@@ -522,31 +522,31 @@ e_dialog_option_menu_get (GtkWidget *widget, const int *value_map)
GList *l;
int i;
int v;
-
+
g_return_val_if_fail (widget != NULL, -1);
g_return_val_if_fail (GTK_IS_OPTION_MENU (widget), -1);
g_return_val_if_fail (value_map != NULL, -1);
-
+
menu = GTK_MENU (gtk_option_menu_get_menu (GTK_OPTION_MENU (widget)));
-
+
active = gtk_menu_get_active (menu);
g_return_val_if_fail (active != NULL, -1);
-
+
children = GTK_MENU_SHELL (menu)->children;
-
+
for (i = 0, l = children; l; l = l->next, i++) {
if (GTK_WIDGET (l->data) == active)
break;
}
-
+
g_return_val_if_fail (l != NULL, -1);
-
+
v = index_to_value (value_map, i);
if (v == -1) {
g_message ("e_dialog_option_menu_get(): could not find index %d in value map!", i);
return -1;
}
-
+
return v;
}
@@ -611,7 +611,7 @@ e_dialog_combo_box_get (GtkWidget *widget, const int *value_map)
* e_dialog_dateedit_set:
* @widget: A #GnomeDateEdit widget.
* @t: Date/time value.
- *
+ *
* Sets the value of a #GnomeDateEdit widget.
**/
void
@@ -619,16 +619,16 @@ e_dialog_dateedit_set (GtkWidget *widget, time_t t)
{
g_return_if_fail (widget != NULL);
g_return_if_fail (GNOME_IS_DATE_EDIT (widget));
-
+
gnome_date_edit_set_time (GNOME_DATE_EDIT (widget), t);
}
/**
* e_dialog_dateedit_get:
* @widget: A #GnomeDateEdit widget.
- *
+ *
* Queries the value of a #GnomeDateEdit widget.
- *
+ *
* Return value: Date/time value.
**/
time_t
@@ -636,7 +636,7 @@ e_dialog_dateedit_get (GtkWidget *widget)
{
g_return_val_if_fail (widget != NULL, -1);
g_return_val_if_fail (GNOME_IS_DATE_EDIT (widget), -1);
-
+
return gnome_date_edit_get_time (GNOME_DATE_EDIT (widget));
}
@@ -647,7 +647,7 @@ e_dialog_dateedit_get (GtkWidget *widget)
* @value_var: Pointer to the variable that the @widget will control.
* @info: NULL for most widgets, or an integer value map array (see
* e_dialog_radio_set() for details).
- *
+ *
* Hooks a widget from a dialog box to the variable it will modify. Supported
* widgets are: #GtkEditable (char *), #GtkRadioButton (int/value_map pair; see
* e_dialog_radio_set() for more information), #GtkTogglebutton (gboolean),
@@ -671,18 +671,18 @@ e_dialog_widget_hook_value (GtkWidget *dialog, GtkWidget *widget,
{
DialogHooks *hooks;
WidgetHook *wh;
-
+
g_return_val_if_fail (dialog != NULL, FALSE);
g_return_val_if_fail (widget != NULL, FALSE);
g_return_val_if_fail (GTK_IS_WIDGET (widget), FALSE);
g_return_val_if_fail (value_var != NULL, FALSE);
-
+
hooks = get_dialog_hooks (dialog);
-
+
/* First check if it is a "group" widget, like a radio button or an
* option menu. Then we check for normal ungrouped widgets.
*/
-
+
if (GTK_IS_RADIO_BUTTON (widget))
hook_radio (dialog, GTK_RADIO_BUTTON (widget), value_var, info);
else if (GTK_IS_OPTION_MENU (widget))
@@ -695,14 +695,14 @@ e_dialog_widget_hook_value (GtkWidget *dialog, GtkWidget *widget,
hook_editable (dialog, GTK_EDITABLE (widget), value_var, info);
else
return FALSE;
-
+
wh = g_new (WidgetHook, 1);
wh->widget = widget;
wh->value_var = value_var;
wh->info = info;
-
+
hooks->whooks = g_slist_prepend (hooks->whooks, wh);
-
+
return TRUE;
}
@@ -710,7 +710,7 @@ e_dialog_widget_hook_value (GtkWidget *dialog, GtkWidget *widget,
* e_dialog_get_values:
* @dialog: A dialog box whose widgets have been hooked to the appropriate
* variables with e_dialog_widget_hook_value().
- *
+ *
* Makes every widget in a @dialog that was hooked with
* e_dialog_widget_hook_value() apply its value to its corresponding variable.
* The typical usage is to call this function in the handler for the "OK" button
@@ -721,16 +721,16 @@ e_dialog_get_values (GtkWidget *dialog)
{
DialogHooks *hooks;
GSList *l;
-
+
g_return_if_fail (dialog != NULL);
-
+
hooks = get_dialog_hooks (dialog);
-
+
for (l = hooks->whooks; l; l = l->next) {
WidgetHook *wh;
-
+
wh = l->data;
-
+
if (GTK_IS_RADIO_BUTTON (wh->widget))
get_radio_value (GTK_RADIO_BUTTON (wh->widget), wh->value_var, wh->info);
else if (GTK_IS_OPTION_MENU (wh->widget))
@@ -754,10 +754,10 @@ e_dialog_get_values (GtkWidget *dialog)
* @value_var: Pointer to the variable that the widget will control.
* @info: NULL for most widgets, or an integer value map array (see
* e_dialog_radio_set() for details).
- *
+ *
* Similar to e_dialog_widget_hook_value(), but uses the widget from a #GladeXML
* data structure.
- *
+ *
* Return value: TRUE if the type of the specified widget is supported, FALSE
* otherwise.
**/
@@ -766,19 +766,19 @@ e_dialog_xml_widget_hook_value (GladeXML *xml, GtkWidget *dialog, const char *wi
gpointer value_var, gpointer info)
{
GtkWidget *widget;
-
+
g_return_val_if_fail (xml != NULL, FALSE);
g_return_val_if_fail (GLADE_IS_XML (xml), FALSE);
g_return_val_if_fail (dialog != NULL, FALSE);
g_return_val_if_fail (widget_name != NULL, FALSE);
g_return_val_if_fail (value_var != NULL, FALSE);
-
+
widget = glade_xml_get_widget (xml, widget_name);
if (!widget) {
g_message ("e_dialog_xml_widget_hook_value(): could not find widget `%s' in "
"Glade data!", widget_name);
return FALSE;
}
-
+
return e_dialog_widget_hook_value (dialog, widget, value_var, info);
}
diff --git a/e-util/e-error.c b/e-util/e-error.c
index 9f2a768c9b..94ad35f31a 100644
--- a/e-util/e-error.c
+++ b/e-util/e-error.c
@@ -45,7 +45,7 @@
#include "e-util-private.h"
#include "e-error.h"
-#define d(x)
+#define d(x)
struct _e_error_button {
struct _e_error_button *next;
@@ -110,7 +110,7 @@ static int
map_response(const char *name)
{
int i;
-
+
for (i=0;i<sizeof(response_map)/sizeof(response_map[0]);i++)
if (!strcmp(name, response_map[i].name))
return response_map[i].id;
@@ -169,7 +169,7 @@ ee_load(const char *path)
char *tmp;
d(printf("loading error file %s\n", path));
-
+
doc = e_xml_parse_file (path);
if (doc == NULL) {
g_warning("Error file '%s' not found", path);
@@ -239,7 +239,7 @@ ee_load(const char *path)
e->default_response = map_response(tmp);
xmlFree(tmp);
}
-
+
tmp = (char *)xmlGetProp(error, (const unsigned char *)"scroll");
if (tmp) {
if (!strcmp(tmp, "yes"))
@@ -550,9 +550,9 @@ e_error_newv(GtkWindow *parent, const char *tag, const char *arg0, va_list ap)
gtk_scrolled_window_add_with_viewport ((GtkScrolledWindow *)scroll, w);
gtk_box_pack_start((GtkBox *)hbox, scroll, FALSE, FALSE, 0);
gtk_window_set_default_size ((GtkWindow *)dialog, 360, 180);
- } else
+ } else
gtk_box_pack_start((GtkBox *)hbox, w, FALSE, FALSE, 0);
-
+
gtk_widget_show_all(hbox);
gtk_box_pack_start((GtkBox *)dialog->vbox, hbox, TRUE, TRUE, 0);
@@ -562,16 +562,16 @@ e_error_newv(GtkWindow *parent, const char *tag, const char *arg0, va_list ap)
/**
* e_error_new:
- * @parent:
+ * @parent:
* @tag: error identifier
* @arg0: The first argument for the error formatter. The list must
* be NULL terminated.
- *
+ *
* Creates a new error widget. The @tag argument is used to determine
* which error to use, it is in the format domain:error-id. The NULL
* terminated list of arguments, starting with @arg0 is used to fill
* out the error definition.
- *
+ *
* Return value: A GtkDialog which can be used for showing an error
* dialog asynchronously.
**/
@@ -604,13 +604,13 @@ e_error_runv(GtkWindow *parent, const char *tag, const char *arg0, va_list ap)
/**
* e_error_run:
- * @parent:
- * @tag:
- * @arg0:
- *
+ * @parent:
+ * @tag:
+ * @arg0:
+ *
* Sets up, displays, runs and destroys a standard evolution error
* dialog based on @tag, which is in the format domain:error-id.
- *
+ *
* Return value: The response id of the button pressed.
**/
int
@@ -638,8 +638,8 @@ remove_parent(GtkWidget *w, GtkWidget *parent)
/**
* e_error_default_parent:
- * @parent:
- *
+ * @parent:
+ *
* Bit of a hack, set a default parent that will be used to parent any
* error boxes if none is supplied.
*
diff --git a/e-util/e-event.c b/e-util/e-event.c
index 363cc7f91f..5ac51d10ee 100644
--- a/e-util/e-event.c
+++ b/e-util/e-event.c
@@ -132,9 +132,9 @@ ep_class_init(GObjectClass *klass)
/**
* e_event_get_type:
- *
+ *
* Standard GObject type function. Used to subclass EEvent.
- *
+ *
* Return value: The EEvent type.
**/
GType
@@ -161,9 +161,9 @@ e_event_get_type(void)
* e_event_construct:
* @ep: An instantiated but uninitialised EEvent.
* @id: Event manager id.
- *
+ *
* Construct the base event instance with standard parameters.
- *
+ *
* Return value: Returns @ep.
**/
EEvent *e_event_construct(EEvent *ep, const char *id)
@@ -179,7 +179,7 @@ EEvent *e_event_construct(EEvent *ep, const char *id)
* @items: A list of EEventItems event listeners to register on this event manager.
* @freefunc: A function called when the @items list is no longer needed.
* @data: callback data for @freefunc and for item event handlers.
- *
+ *
* Adds @items to the list of events listened to on the event manager @emp.
*
* Return value: An opaque key which can later be passed to remove_items.
@@ -206,9 +206,9 @@ e_event_add_items(EEvent *emp, GSList *items, EEventItemsFunc freefunc, void *da
/**
* e_event_remove_items:
- * @emp:
- * @handle:
- *
+ * @emp:
+ * @handle:
+ *
* Remove items previously added. They MUST have been previously
* added, and may only be removed once.
**/
@@ -226,7 +226,7 @@ e_event_remove_items(EEvent *emp, void *handle)
g_slist_foreach(emp->priv->sorted, (GFunc)g_free, NULL);
g_slist_free(emp->priv->sorted);
emp->priv->sorted = NULL;
- }
+ }
}
static int
@@ -248,7 +248,7 @@ ee_cmp(const void *ap, const void *bp)
* @ee: An initialised EEvent, potentially with registered event listeners.
* @id: Event name. This will be compared against EEventItem.id.
* @target: The target describing the event context. This will be implementation defined.
- *
+ *
* Emit an event. @target will automatically be freed once its
* emission is complete.
**/
@@ -272,7 +272,7 @@ e_event_emit(EEvent *emp, const char *id, EEventTarget *target)
for (;node->next;node=node->next) {
GSList *l = node->events;
-
+
for (;l;l=g_slist_next(l)) {
struct _event_info *info;
@@ -312,7 +312,7 @@ e_event_emit(EEvent *emp, const char *id, EEventTarget *target)
* @ep: An initialised EEvent instance.
* @type: type, up to implementor
* @size: The size of memory to allocate. This must be >= sizeof(EEventTarget).
- *
+ *
* Allocate a new event target suitable for this class. It is up to
* the implementation to define the available target types and their
* structure.
@@ -338,7 +338,7 @@ void *e_event_target_new(EEvent *ep, int type, size_t size)
* e_event_target_free:
* @ep: An initialised EEvent instance on which this target was allocated.
* @o: The target to free.
- *
+ *
* Free a target. This invokes the virtual free method on the EEventClass.
**/
void
@@ -526,17 +526,17 @@ emph_class_init(EPluginHookClass *klass)
/**
* e_event_hook_get_type:
- *
+ *
* Standard GObject function to get the EEvent object type. Used to
* subclass EEventHook.
- *
+ *
* Return value: The type of the event hook class.
**/
GType
e_event_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EEventHookClass), NULL, NULL, (GClassInitFunc) emph_class_init, NULL, NULL,
@@ -546,7 +546,7 @@ e_event_hook_get_type(void)
emph_parent_class = g_type_class_ref(e_plugin_hook_get_type());
type = g_type_register_static(e_plugin_hook_get_type(), "EEventHook", &info, 0);
}
-
+
return type;
}
@@ -555,7 +555,7 @@ e_event_hook_get_type(void)
* @klass: The derived EEventHook class.
* @map: A map used to describe a single EEventTarget type for this
* class.
- *
+ *
* Add a target map to a concrete derived class of EEvent. The target
* map enumerates a single target type and th eenable mask bit names,
* so that the type can be loaded automatically by the base EEvent class.
diff --git a/e-util/e-event.h b/e-util/e-event.h
index d75d550767..e7cafbc33f 100644
--- a/e-util/e-event.h
+++ b/e-util/e-event.h
@@ -49,10 +49,10 @@ typedef void (*EEventFactoryFunc)(EEvent *ee, void *);
/**
* enum _e_event_t - Event type.
- *
+ *
* @E_EVENT_PASS: A passthrough event handler which only receives the event.
* @E_EVENT_SINK: A sink event handler swallows all events it processes.
- *
+ *
* The event type defines what type of event listener this is.
*
* Events should normally be @E_EVENT_PASS.
@@ -64,7 +64,7 @@ enum _e_event_t {
/**
* struct _EEventItem - An event listener item.
- *
+ *
* @type: The type of the event listener.
* @priority: A signed number signifying the priority of the event
* listener. 0 should be used normally. This is used to order event
@@ -78,7 +78,7 @@ enum _e_event_t {
* @user_data: Callback data.
* @enable: Target-specific mask to qualify the receipt of events.
* This is target and implementation specific.
- *
+ *
* An EEventItem defines a specific event listening point on a given
* EEvent object. When an event is broadcast onto an EEvent handler,
* any matching EEventItems will be invoked in priority order.
@@ -95,7 +95,7 @@ struct _EEventItem {
/**
* struct _EEventTarget - Base EventTarget.
- *
+ *
* @event: Parent object.
* @type: Target type. Defined by the implementation.
* @mask: Mask of this target. This is defined by the implementation,
@@ -104,7 +104,7 @@ struct _EEventItem {
* This defined a base EventTarget. This must be subclassed by
* implementations to provide contextual data for events, and define
* the enablement qualifiers.
- *
+ *
**/
struct _EEventTarget {
struct _EEvent *event; /* used for virtual methods */
@@ -117,7 +117,7 @@ struct _EEventTarget {
/**
* struct _EEvent - An Event Manager.
- *
+ *
* @object: Superclass.
* @priv: Private data.
* @id: Id of this event manager.
@@ -138,7 +138,7 @@ struct _EEvent {
/**
* struct _EEventClass - Event management type.
- *
+ *
* @object_class: Superclass.
* @target_free: Virtual method to free the target.
*
@@ -187,7 +187,7 @@ typedef void (*EEventHookFunc)(struct _EPlugin *plugin, EEventTarget *target);
/**
* struct _EEventHook - An event hook.
- *
+ *
* @hook: Superclass.
*
* The EEventHook class loads and manages the meta-data required to
@@ -202,13 +202,13 @@ struct _EEventHook {
};
/**
- * struct _EEventHookClass -
- *
- * @hook_class:
+ * struct _EEventHookClass -
+ *
+ * @hook_class:
* @target_map: Table of EPluginHookTargetMaps which enumerate the
* target types and enable bits of the implementing class.
* @event: The EEvent instance on which all loaded events must be registered.
- *
+ *
* The EEventHookClass is an empty event hooking class, which must be
* subclassed and initialised before use.
*
diff --git a/e-util/e-folder-map.c b/e-util/e-folder-map.c
index 31ae5ffb8e..6c6e07e263 100644
--- a/e-util/e-folder-map.c
+++ b/e-util/e-folder-map.c
@@ -45,25 +45,25 @@ is_type_folder (const char *metadata, const char *search_type)
xmlNodePtr node;
xmlDocPtr doc;
char *type;
-
+
doc = e_xml_parse_file (metadata);
if (!doc) {
g_warning ("Cannot parse `%s'", metadata);
return FALSE;
}
-
+
if (!(node = xmlDocGetRootElement (doc))) {
g_warning ("`%s' corrupt: document contains no root node", metadata);
xmlFreeDoc (doc);
return FALSE;
}
-
+
if (!node->name || strcmp ((char *)node->name, "efolder") != 0) {
g_warning ("`%s' corrupt: root node is not 'efolder'", metadata);
xmlFreeDoc (doc);
return FALSE;
}
-
+
node = node->children;
while (node != NULL) {
if (node->name && !strcmp ((char *)node->name, "type")) {
@@ -71,20 +71,20 @@ is_type_folder (const char *metadata, const char *search_type)
if (!strcmp (type, search_type)) {
xmlFreeDoc (doc);
xmlFree (type);
-
+
return TRUE;
}
-
+
xmlFree (type);
-
+
break;
}
-
+
node = node->next;
}
-
+
xmlFreeDoc (doc);
-
+
return FALSE;
}
@@ -101,7 +101,7 @@ e_folder_map_dir (const char *dirname, const char *type, GSList **dir_list)
g_free (path);
return;
}
-
+
if (!is_type_folder (path, type)) {
g_free (path);
goto try_subdirs;
@@ -109,8 +109,8 @@ e_folder_map_dir (const char *dirname, const char *type, GSList **dir_list)
d(g_message ("Found '%s'", dirname));
*dir_list = g_slist_prepend (*dir_list, g_strdup (dirname));
-
- g_free (path);
+
+ g_free (path);
try_subdirs:
@@ -119,32 +119,32 @@ e_folder_map_dir (const char *dirname, const char *type, GSList **dir_list)
g_free (path);
return;
}
-
+
if (!(dir = g_dir_open (path, 0, &error))) {
g_warning ("cannot open `%s': %s", path, error->message);
g_error_free (error);
g_free (path);
return;
}
-
+
while ((name = g_dir_read_name (dir))) {
char *full_path;
-
+
if (*name == '.')
continue;
-
+
full_path = g_build_filename (path, name, NULL);
if (!g_file_test (full_path, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_DIR)) {
g_free (full_path);
continue;
}
-
+
e_folder_map_dir (full_path, type, dir_list);
g_free (full_path);
}
-
+
g_dir_close (dir);
-
+
g_free (path);
}
@@ -152,34 +152,34 @@ GSList *
e_folder_map_local_folders (char *local_dir, char *type)
{
const char *name;
- GDir *dir;
+ GDir *dir;
GSList *dir_list = NULL;
GError *error = NULL;
-
+
if (!(dir = g_dir_open (local_dir, 0, &error))) {
g_warning ("cannot open `%s': %s", local_dir, error->message);
g_error_free (error);
return NULL;
}
-
+
while ((name = g_dir_read_name (dir))) {
char *full_path;
-
+
if (*name == '.')
continue;
-
+
full_path = g_build_filename (local_dir, name, NULL);
d(g_message ("Looking in %s", full_path));
if (!g_file_test (full_path, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_DIR)) {
g_free (full_path);
continue;
}
-
+
e_folder_map_dir (full_path, type, &dir_list);
g_free (full_path);
}
-
+
g_dir_close (dir);
return dir_list;
diff --git a/e-util/e-fsutils.c b/e-util/e-fsutils.c
index cb126df0cf..97118eddd0 100644
--- a/e-util/e-fsutils.c
+++ b/e-util/e-fsutils.c
@@ -51,10 +51,10 @@
/**
* e_fsutils_usage:
- * @path:
- *
+ * @path:
+ *
* Calculate the amount of disk space used by a given path.
- *
+ *
* Return value: The number of 1024 byte blocks used by the
* filesystem.
**/
@@ -118,10 +118,10 @@ fail:
/**
* e_fsutils_avail:
- * @path:
- *
+ * @path:
+ *
* Find the available disk space at the given path.
- *
+ *
* Return value: -1 if it could not be determined, otherwise the
* number of disk blocks, expressed as system-independent, 1024 byte
* blocks.
diff --git a/e-util/e-gui-utils.c b/e-util/e-gui-utils.c
index 18f9c9b50f..5a828dedf6 100644
--- a/e-util/e-gui-utils.c
+++ b/e-util/e-gui-utils.c
@@ -69,7 +69,7 @@ GtkWidget *e_create_image_widget(gchar *name,
{
GtkWidget *alignment = NULL;
GtkWidget *w;
-
+
if (string1) {
w = e_icon_factory_get_image (string1, E_ICON_SIZE_DIALOG);
diff --git a/e-util/e-html-utils.h b/e-util/e-html-utils.h
index 9d2262f9a7..73f40c9977 100644
--- a/e-util/e-html-utils.h
+++ b/e-util/e-html-utils.h
@@ -1,6 +1,6 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/* e-html-utils.c */
-/*
+/*
* Copyright (C) 2000 Ximian, Inc.
* Author: Dan Winship <danw@ximian.com>
*
diff --git a/e-util/e-icon-factory.c b/e-util/e-icon-factory.c
index 52a7f14e82..78b8122cdd 100644
--- a/e-util/e-icon-factory.c
+++ b/e-util/e-icon-factory.c
@@ -110,22 +110,22 @@ load_icon (const char *icon_key, const char *icon_name, int size, int scale)
int width;
GDir *dir;
char *x;
-
+
if (!(dir = g_dir_open (EVOLUTION_ICONSDIR, 0, NULL))) {
goto done;
}
-
+
/* scan icon directories looking for an icon with a size >= the size we need. */
while ((dent = g_dir_read_name (dir))) {
if (!(dent[0] >= '1' && dent[0] <= '9'))
continue;
-
+
if (((width = strtol (dent, &x, 10)) < size) || *x != 'x')
continue;
-
+
if (((strtol (x + 1, &x, 10)) != width) || *x != '\0')
continue;
-
+
/* if the icon exists in this directory, we can [use/scale] it */
g_free (filename);
basename = g_strconcat (icon_name, ".png", NULL);
@@ -137,7 +137,7 @@ load_icon (const char *icon_key, const char *icon_name, int size, int scale)
if ((unscaled = gdk_pixbuf_new_from_file (filename, NULL)))
break;
}
-
+
g_dir_close (dir);
} else {
gchar *size_x_size;
@@ -213,8 +213,8 @@ e_icon_factory_init (void)
icon_theme = gtk_icon_theme_get_default ();
gtk_icon_theme_append_search_path (icon_theme,
- EVOLUTION_DATADIR G_DIR_SEPARATOR_S
- "evolution" G_DIR_SEPARATOR_S
+ EVOLUTION_DATADIR G_DIR_SEPARATOR_S
+ "evolution" G_DIR_SEPARATOR_S
BASE_VERSION G_DIR_SEPARATOR_S "icons");
g_signal_connect (
icon_theme, "changed",
@@ -386,12 +386,12 @@ e_icon_factory_get_icon_list (const char *icon_name)
for (i = 0; i < G_N_ELEMENTS (icon_list_sizes); i++) {
size = icon_list_sizes[i];
sprintf (icon_key, "%dx%d/%s", size, size, icon_name);
-
+
if (!(icon = g_hash_table_lookup (name_to_icon, icon_key))) {
if ((icon = load_icon (icon_key, icon_name, size, FALSE)))
g_hash_table_insert (name_to_icon, icon->name, icon);
}
-
+
if (icon && icon->pixbuf) {
list = g_list_prepend (list, icon->pixbuf);
g_object_ref (icon->pixbuf);
diff --git a/e-util/e-import.c b/e-util/e-import.c
index 7cf02c07e5..92a54f59ac 100644
--- a/e-util/e-import.c
+++ b/e-util/e-import.c
@@ -47,7 +47,7 @@
#include <glib/gi18n.h>
-#define d(x)
+#define d(x)
#define _PRIVATE(o) (g_type_instance_get_private ((GTypeInstance *)o, e_import_get_type()))
@@ -124,10 +124,10 @@ ep_base_init(GObjectClass *klass)
/**
* e_import_get_type:
- *
+ *
* Standard GObject method. Used to subclass for the concrete
* implementations.
- *
+ *
* Return value: EImport type.
**/
GType
@@ -154,9 +154,9 @@ e_import_get_type(void)
* e_import_construct:
* @ep: The instance to initialise.
* @id: The name of the instance.
- *
+ *
* Used by implementing classes to initialise base parameters.
- *
+ *
* Return value: @ep is returned.
**/
EImport *e_import_construct(EImport *ep, const char *id)
@@ -175,13 +175,13 @@ EImport *e_import_new(const char *id)
/**
* e_import_import:
- * @ei:
+ * @ei:
* @t: Target to import.
* @im: Importer to use.
* @status: Status callback, called with progress information.
* @done: Complete callback, will always be called once complete.
* @data:
- *
+ *
* Run the import function of the selected importer. Once the
* importer has finished, it MUST call the e_import_complete()
* function. This allows importers to run in synchronous or
@@ -213,11 +213,11 @@ void e_import_cancel(EImport *ei, EImportTarget *t, EImportImporter *im)
* @ei:
* @target: Target of interest
* @im: Importer to get widget of
- *
+ *
* Gets a widget that the importer uses to configure its
* destination. This widget should be packed into a container
* widget. It should not be shown_all.
- *
+ *
* Return value: NULL if the importer doesn't support/require
* a destination.
**/
@@ -232,9 +232,9 @@ e_import_get_widget(EImport *ei, EImportTarget *target, EImportImporter *im)
/**
* e_import_complete:
- * @ei:
+ * @ei:
* @target: Target just completed (unused currently)
- *
+ *
* Signify that an import is complete. This must be called by
* importer implementations when they are done.
**/
@@ -252,14 +252,14 @@ void e_import_status(EImport *ei, EImportTarget *target, const char *what, int p
/**
* e_import_get_importers:
- * @emp:
- * @target:
- *
+ * @emp:
+ * @target:
+ *
* Get a list of importers. If @target is supplied, then only
* importers which support the type and location specified by the
* target are listed. If @target is NULL, then all importers are
* listed.
- *
+ *
* Return value: A list of importers. The list should be freed when
* no longer needed.
**/
@@ -292,7 +292,7 @@ e_import_get_importers(EImport *emp, EImportTarget *target)
* @freefunc: If supplied, called to free the importer node
* when it is no longer needed.
* @data: Data for the callback.
- *
+ *
**/
void
e_import_class_add_importer(EImportClass *klass, EImportImporter *importer, EImportImporterFunc freefunc, void *data)
@@ -343,7 +343,7 @@ void e_import_class_remove_importer(EImportClass *klass, EImportImporter *f)
* @ep: Parent EImport object.
* @type: type, up to implementor
* @size: Size of object to allocate.
- *
+ *
* Allocate a new import target suitable for this class. Implementing
* classes will define the actual content of the target.
**/
@@ -369,7 +369,7 @@ void *e_import_target_new(EImport *ep, int type, size_t size)
* e_import_target_free:
* @ep: Parent EImport object.
* @o: The target to fre.
- *
+ *
* Free a target. The implementing class can override this method to
* free custom targets.
**/
@@ -583,7 +583,7 @@ emph_class_init(EPluginHookClass *klass)
/** @HookClass: Evolution Importers
* @Id: org.gnome.evolution.import:1.0
* @Target: EImportTarget
- *
+ *
* A hook for data importers.
**/
@@ -600,16 +600,16 @@ emph_class_init(EPluginHookClass *klass)
/**
* e_import_hook_get_type:
- *
+ *
* Standard GObject function to get the object type.
- *
+ *
* Return value: The EImportHook class type.
**/
GType
e_import_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EImportHookClass), NULL, NULL, (GClassInitFunc) emph_class_init, NULL, NULL,
@@ -619,7 +619,7 @@ e_import_hook_get_type(void)
emph_parent_class = g_type_class_ref(e_plugin_hook_get_type());
type = g_type_register_static(e_plugin_hook_get_type(), "EImportHook", &info, 0);
}
-
+
return type;
}
@@ -629,7 +629,7 @@ e_import_hook_get_type(void)
* @klass: The dervied EimportHook class.
* @map: A map used to describe a single EImportTarget type for this
* class.
- *
+ *
* Add a targe tmap to a concrete derived class of EImport. The
* target map enumates the target types available for the implenting
* class.
diff --git a/e-util/e-import.h b/e-util/e-import.h
index 40bd29655a..15f2e3aea8 100644
--- a/e-util/e-import.h
+++ b/e-util/e-import.h
@@ -60,8 +60,8 @@ enum _e_import_target_t {
};
/**
- * struct _EImportImporter -
- *
+ * struct _EImportImporter -
+ *
* @type: target type
* @priority: Priority of importer. Higher values will be processed first.
* @supported: Callback to see if this target is supported by the importer.
@@ -90,13 +90,13 @@ struct _EImportImporter {
/**
* struct _EImportTarget - importation context.
- *
+ *
* @import: The parent object.
* @type: The type of target, defined by implementing classes.
* @data: This can be used to store run-time information
* about this target. Any allocated data must be set so
* as to free it when the target is freed.
- *
+ *
* The base target object is used as the parent and placeholder for
* import context for a given importer.
**/
@@ -128,7 +128,7 @@ struct _EImportTargetHome {
/**
* struct _EImport - An importer management object.
- *
+ *
* @object: Superclass.
* @id: ID of importer.
* @status: Status callback of current running import.
@@ -148,7 +148,7 @@ struct _EImport {
/**
* struct _EImportClass - Importer manager abstract class.
- *
+ *
* @object_class: Superclass.
* @factories: A list of factories registered on this type of
* importuration manager.
@@ -157,7 +157,7 @@ struct _EImport {
* into changes on the target to propery drive the manager.
* @target_free: A virtual method used to free the target in an
* implementation-defined way.
- *
+ *
**/
struct _EImportClass {
GObjectClass object_class;
@@ -223,11 +223,11 @@ struct _EImportHookImporter {
/**
* struct _EImportHook - Plugin hook for importuration windows.
- *
+ *
* @hook: Superclass.
* @groups: A list of EImportHookGroup's of all importuration windows
* this plugin hooks into.
- *
+ *
**/
struct _EImportHook {
EPluginHook hook;
@@ -238,7 +238,7 @@ struct _EImportHook {
/**
* struct _EImportHookClass - Abstract class for importuration window
* plugin hooks.
- *
+ *
* @hook_class: Superclass.
* @target_map: A table of EImportHookTargetMap structures describing
* the possible target types supported by this class.
@@ -247,7 +247,7 @@ struct _EImportHook {
*
* This is an abstract class defining the plugin hook point for
* importuration windows.
- *
+ *
**/
struct _EImportHookClass {
EPluginHookClass hook_class;
diff --git a/e-util/e-menu.c b/e-util/e-menu.c
index c9e6d098b4..0582d35c96 100644
--- a/e-util/e-menu.c
+++ b/e-util/e-menu.c
@@ -148,9 +148,9 @@ em_base_init(GObjectClass *klass)
/**
* e_menu_get_type:
- *
+ *
* Standard GObject type function. Used to subclass this type only.
- *
+ *
* Return value: The EMenu object type.
**/
GType
@@ -178,9 +178,9 @@ e_menu_get_type(void)
* e_menu_construct:
* @em: An instantiated but uninitislied EPopup.
* @menuid: The unique identifier for this menu.
- *
+ *
* Construct the base menu instance based on the parameters.
- *
+ *
* Return value: Returns @em.
**/
EMenu *e_menu_construct(EMenu *em, const char *menuid)
@@ -225,7 +225,7 @@ EMenu *e_menu_construct(EMenu *em, const char *menuid)
* associated with the menus.
* @freefunc: If supplied, called when the menu items are no longer needed.
* @data: user-data passed to @freefunc and activate callbacks.
- *
+ *
* Add new EMenuItems to the menu's. This may be called any number of
* times before the menu is first activated to hook onto any of the
* menu items defined for that view.
@@ -281,9 +281,9 @@ e_menu_add_items(EMenu *emp, GSList *items, GSList *uifiles, GSList *pixmaps, EM
/**
* e_menu_remove_items:
- * @emp:
- * @handle:
- *
+ * @emp:
+ * @handle:
+ *
* Remove menu items previously added.
**/
void
@@ -298,7 +298,7 @@ e_menu_remove_items(EMenu *emp, void *handle)
if (emp->uic) {
for (l = node->items;l;l=g_slist_next(l)) {
EMenuItem *item = l->data;
-
+
bonobo_ui_component_remove_verb(emp->uic, item->verb);
}
}
@@ -341,7 +341,7 @@ em_activate(BonoboUIComponent *uic, void *data, const char *cname)
* @em: An initialised EMenu.
* @uic: The BonoboUI component for this views menu's.
* @act: If %TRUE, then the control is being activated.
- *
+ *
* This is called by the owner of the component, control, or view to
* pass on the activate or deactivate control signals. If the view is
* being activated then the callbacks and menu items are setup,
@@ -424,7 +424,7 @@ void e_menu_activate(EMenu *em, struct _BonoboUIComponent *uic, int act)
* e_menu_update_target:
* @em: An initialised EMenu.
* @tp: Target, after this call the menu owns the target.
- *
+ *
* Change the target for the menu. Once the target is changed, the
* sensitivity state of the menu items managed by @em is re-evaluated
* and the physical menu's updated to reflect it.
@@ -477,13 +477,13 @@ void e_menu_update_target(EMenu *em, void *tp)
* called on all menus.
* @func: An EMenuFactoryFunc callback.
* @data: Callback data for @func.
- *
+ *
* Add a menu factory which will be called when the menu @menuid is
* created. The factory is free to add new items as it wishes to the
* menu provided in the callback.
*
* TODO: Make the menuid a pattern?
- *
+ *
* Return value: A handle to the factory.
**/
EMenuFactory *
@@ -515,7 +515,7 @@ e_menu_class_add_factory(EMenuClass *klass, const char *menuid, EMenuFactoryFunc
* e_menu_class_remove_factory:
* @klass: Class on which the factory was originally added.
* @f: Factory handle.
- *
+ *
* Remove a popup factory. This must only be called once, and must
* only be called using a valid factory handle @f. After this call,
* @f is undefined.
@@ -533,7 +533,7 @@ e_menu_class_remove_factory(EMenuClass *klass, EMenuFactory *f)
* @ep: An EMenu to which this target applies.
* @type: Target type, up to implementation.
* @size: Size of memory to allocate. Must be >= sizeof(EMenuTarget).
- *
+ *
* Allocate a new menu target suitable for this class. @size is used
* to specify the actual target size, which may vary depending on the
* implementing class.
@@ -559,7 +559,7 @@ void *e_menu_target_new(EMenu *ep, int type, size_t size)
* e_menu_target_free:
* @ep: EMenu on which the target was allocated.
* @o: Tareget to free.
- *
+ *
* Free a target.
**/
void
@@ -886,17 +886,17 @@ emph_class_init(EPluginHookClass *klass)
/**
* e_menu_hook_get_type:
- *
+ *
* Standard GObject function to get the object type. Used to subclass
* EMenuHook.
- *
+ *
* Return value: The type of the menu hook class.
**/
GType
e_menu_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EMenuHookClass), NULL, NULL, (GClassInitFunc) emph_class_init, NULL, NULL,
@@ -906,7 +906,7 @@ e_menu_hook_get_type(void)
emph_parent_class = g_type_class_ref(e_plugin_hook_get_type());
type = g_type_register_static(e_plugin_hook_get_type(), "EMenuHook", &info, 0);
}
-
+
return type;
}
@@ -914,7 +914,7 @@ e_menu_hook_get_type(void)
* e_menu_hook_class_add_target_map:
* @klass: The derived EMenuHook class.
* @map: A map used to describe a single EMenuTarget for this class.
- *
+ *
* Adds a target map to a concrete derived class of EMenu. The target
* map enumerates a single target type, and the enable mask bit names,
* so that the type can be loaded automatically by the EMenu class.
diff --git a/e-util/e-menu.h b/e-util/e-menu.h
index 2692878172..c5548a335b 100644
--- a/e-util/e-menu.h
+++ b/e-util/e-menu.h
@@ -53,13 +53,13 @@ typedef void (*EMenuItemsFunc)(EMenu *, GSList *items, GSList *uifiles, GSList *
/**
* enum _e_menu_t - Menu item type.
- *
+ *
* @E_MENU_ITEM: Normal menu item.
* @E_MENU_TOGGLE: Toggle menu item.
* @E_MENU_RADIO: unimplemented.
* @E_MENU_TYPE_MASK: Mask used to separate item type from option bits.
* @E_MENU_ACTIVE: Whether a toggle item is active.
- *
+ *
* The type of menu items which are supported by the menu system.
**/
enum _e_menu_t {
@@ -72,7 +72,7 @@ enum _e_menu_t {
/**
* struct _EMenuItem - A BonoboUI menu item.
- *
+ *
* @type: Menu item type. %E_MENU_ITEM or %E_MENU_TOGGLE.
* @path: BonoboUI Path to the menu item.
* @verb: BonoboUI verb for the menu item.
@@ -82,7 +82,7 @@ enum _e_menu_t {
* @user_data: User data for item.
* @visible: Visibility mask, unimplemented.
* @enable: Sensitivity mask, combined with the target mask.
- *
+ *
* An EMenuItem defines a single menu item. This menu item is used to
* hook onto callbacks from the bonobo menus, but not to build or
* merge the menu itself.
@@ -99,7 +99,7 @@ struct _EMenuItem {
/**
* struct _EMenuPixmap - A menu icon holder.
- *
+ *
* @command: The path to the command or verb to which this pixmap belongs.
* @name: The name of the icon. Either an icon-theme name or the full
* pathname of the icon.
@@ -119,11 +119,11 @@ struct _EMenuPixmap {
/**
* struct _EMenuUIFile - A meu UI file holder.
- *
+ *
* @appdir: TODO; should this be handled internally.
* @appname: TODO; should this be handled internally.
* @filename: The filename of the BonoboUI XML menu definition.
- *
+ *
* These values are passed directly to bonobo_ui_util_set_ui() when
* the menu is activated.
**/
@@ -135,7 +135,7 @@ struct _EMenuUIFile {
/**
* struct _EMenuTarget - A BonoboUI menu target definition.
- *
+ *
* @menu: The parent menu object, used for virtual methods on the target.
* @widget: The parent widget where available. In some cases the type
* of this object is part of the published api for the target, in
@@ -144,7 +144,7 @@ struct _EMenuUIFile {
* @type: Target type. This will be defined by the implementation.
* @mask: Target mask. This is used to sensitise show items based on
* their definition in EMenuItem.
- *
+ *
* An EMenuTarget defines the context for a specific view instance.
* It is used to enable and show menu items, and to provide contextual
* data to menu invocations.
@@ -156,20 +156,20 @@ struct _EMenuTarget {
guint32 type; /* for implementors */
guint32 mask; /* enable/visible mask */
-
+
/* implementation fields follow */
};
/**
* struct _EMenu - A BonoboUI menu manager object.
- *
+ *
* @object: Superclass.
* @priv: Private data.
* @menuid: The id of this menu instance.
* @uic: The current BonoboUIComponent which stores the actual menu
* items this object manages.
* @target: The current target for the view.
- *
+ *
* The EMenu manager object manages the mappings between EMenuItems
* and the BonoboUI menus loaded from UI files.
**/
@@ -183,8 +183,8 @@ struct _EMenu {
};
/**
- * struct _EMenuClass -
- *
+ * struct _EMenuClass -
+ *
* @object_class: Superclass type.
* @factories: A list of factories for this particular class of main menu.
* @target_free: Virtual method to free the menu target. The base
@@ -245,7 +245,7 @@ typedef void (*EMenuHookFunc)(struct _EPlugin *plugin, EMenuTarget *target);
/**
* struct _EMenuHookMenu - A group of items targetting a specific menu.
- *
+ *
* @hook: Parent pointer.
* @id: The identifier of the menu or view to which these items belong.
* @target_type: The target number of the type of target these menu
@@ -254,7 +254,7 @@ typedef void (*EMenuHookFunc)(struct _EPlugin *plugin, EMenuTarget *target);
* @uis: A list of filenames of the BonoboUI files that need to be
* loaded for an active view.
* @pixmaps: A list of EMenuHookPixmap structures for the menus.
- *
+ *
* This structure is used to keep track of all of the items that a
* plugin wishes to add to specific menu. This is used internally by
* a factory method defined by the EMenuHook to add the right menu
@@ -271,7 +271,7 @@ struct _EMenuHookMenu {
/**
* struct _EMenuHook - A BonoboUI menu hook.
- *
+ *
* @hook: Superclass.
* @menus: A list of EMenuHookMenus for all menus registered on this
* hook type.
@@ -287,13 +287,13 @@ struct _EMenuHook {
/**
* struct _EMenuHookClass - Menu hook type.
- *
+ *
* @hook_class: Superclass type.
* @target_map: Table of EluginHookTargetMaps which enumerate the
* target types and enable bits of the implementing class.
* @menu_class: The EMenuClass of the corresponding popup manager for
* implementing the class.
- *
+ *
* The EMenuHookClass is an empty concrete class. It must be
* subclassed and initialised appropriately to perform useful work.
*
diff --git a/e-util/e-mktemp.c b/e-util/e-mktemp.c
index 02a3e784fd..9ff294f929 100644
--- a/e-util/e-mktemp.c
+++ b/e-util/e-mktemp.c
@@ -107,10 +107,10 @@ get_dir (gboolean make)
GString *path;
time_t now = time(NULL);
static time_t last = 0;
-
+
#ifdef TEMP_HOME
char *tmpdir = NULL;
- tmpdir = g_build_filename(g_get_home_dir(), ".evolution",
+ tmpdir = g_build_filename(g_get_home_dir(), ".evolution",
"cache", "tmp", NULL);
path = g_string_new(tmpdir);
if (make && g_mkdir_with_parents(tmpdir, 0777) == -1) {
@@ -123,20 +123,20 @@ get_dir (gboolean make)
g_string_append_printf (path, "%d", (int) getuid ());
if (make) {
int ret;
-
+
/* shoot now, ask questions later */
ret = g_mkdir (path->str, S_IRWXU);
if (ret == -1) {
if (errno == EEXIST) {
struct stat st;
-
+
if (g_stat (path->str, &st) == -1) {
/* reset errno */
errno = EEXIST;
g_string_free (path, TRUE);
return NULL;
}
-
+
/* make sure this is a directory and belongs to us... */
if (!S_ISDIR (st.st_mode) || st.st_uid != getuid ()) {
/* eek! this is bad... */
@@ -150,7 +150,7 @@ get_dir (gboolean make)
}
}
}
-#endif
+#endif
d(printf("temp dir '%s'\n", path ? path->str : "(null)"));
@@ -168,20 +168,20 @@ e_mktemp (const char *template)
{
GString *path;
char *ret;
-
+
path = get_dir (TRUE);
if (!path)
return NULL;
-
+
g_string_append_c (path, '/');
if (template)
g_string_append (path, template);
else
g_string_append (path, "unknown-XXXXXX");
-
+
ret = mktemp (path->str);
g_string_free(path, ret == NULL);
-
+
return ret;
}
@@ -191,20 +191,20 @@ e_mkstemp (const char *template)
{
GString *path;
int fd;
-
+
path = get_dir (TRUE);
if (!path)
return -1;
-
+
g_string_append_c (path, '/');
if (template)
g_string_append (path, template);
else
g_string_append (path, "unknown-XXXXXX");
-
+
fd = g_mkstemp (path->str);
g_string_free(path, TRUE);
-
+
return fd;
}
@@ -214,17 +214,17 @@ e_mkdtemp (const char *template)
{
GString *path;
char *tmpdir;
-
+
path = get_dir (TRUE);
if (!path)
return NULL;
-
+
g_string_append_c (path, '/');
if (template)
g_string_append (path, template);
else
g_string_append (path, "unknown-XXXXXX");
-
+
#ifdef HAVE_MKDTEMP
tmpdir = mkdtemp (path->str);
#else
@@ -235,6 +235,6 @@ e_mkdtemp (const char *template)
}
#endif
g_string_free(path, tmpdir == NULL);
-
+
return tmpdir;
}
diff --git a/e-util/e-pilot-map.c b/e-util/e-pilot-map.c
index 3276337679..8c6f6a826c 100644
--- a/e-util/e-pilot-map.c
+++ b/e-util/e-pilot-map.c
@@ -30,7 +30,7 @@
#include "e-pilot-map.h"
-typedef struct
+typedef struct
{
char *uid;
gboolean archived;
@@ -65,7 +65,7 @@ real_e_pilot_map_insert (EPilotMap *map, guint32 pid, const char *uid, gboolean
if (pid != 0) {
new_pid = g_new (guint32, 1);
*new_pid = pid;
- }
+ }
new_uid = g_strdup (uid);
/* Values */
@@ -76,13 +76,13 @@ real_e_pilot_map_insert (EPilotMap *map, guint32 pid, const char *uid, gboolean
if (touch)
pnode->touched = TRUE;
}
-
+
unode = g_new0 (EPilotMapUidNode, 1);
unode->pid = pid;
unode->archived = archived;
if (touch)
unode->touched = TRUE;
-
+
/* Insertion */
if (pid != 0)
g_hash_table_insert (map->pid_map, new_pid, pnode);
@@ -93,14 +93,14 @@ static void
map_set_node_timet (xmlNodePtr node, const char *name, time_t t)
{
char *tstring;
-
+
tstring = g_strdup_printf ("%ld", t);
xmlSetProp (node, (unsigned char *)name, (unsigned char *)tstring);
g_free (tstring);
}
static void
-map_sax_start_element (void *data, const xmlChar *name,
+map_sax_start_element (void *data, const xmlChar *name,
const xmlChar **attrs)
{
EPilotMap *map = (EPilotMap *)data;
@@ -108,15 +108,15 @@ map_sax_start_element (void *data, const xmlChar *name,
if (!strcmp ((char *)name, "PilotMap")) {
while (attrs && *attrs != NULL) {
const xmlChar **val = attrs;
-
+
val++;
- if (!strcmp ((char *)*attrs, "timestamp"))
+ if (!strcmp ((char *)*attrs, "timestamp"))
map->since = (time_t)strtoul ((char *)*val, NULL, 0);
attrs = ++val;
}
}
-
+
if (!strcmp ((char *)name, "map")) {
const char *uid = NULL;
guint32 pid = 0;
@@ -124,17 +124,17 @@ map_sax_start_element (void *data, const xmlChar *name,
while (attrs && *attrs != NULL) {
const xmlChar **val = attrs;
-
+
val++;
- if (!strcmp ((char *)*attrs, "uid"))
+ if (!strcmp ((char *)*attrs, "uid"))
uid = (char *)*val;
-
+
if (!strcmp ((char *)*attrs, "pilot_id"))
pid = strtoul ((char *)*val, NULL, 0);
if (!strcmp ((char *)*attrs, "archived"))
archived = strtoul ((char *)*val, NULL, 0)== 1 ? TRUE : FALSE;
-
+
attrs = ++val;
}
@@ -156,7 +156,7 @@ map_write_foreach (gpointer key, gpointer value, gpointer data)
if (wd->touched_only && !unode->touched)
return;
-
+
mnode = xmlNewChild (root, NULL, (const unsigned char *)"map", NULL);
xmlSetProp (mnode, (const unsigned char *)"uid", (unsigned char *)uid);
@@ -172,38 +172,38 @@ map_write_foreach (gpointer key, gpointer value, gpointer data)
}
}
-gboolean
+gboolean
e_pilot_map_pid_is_archived (EPilotMap *map, guint32 pid)
{
EPilotMapPidNode *pnode;
g_return_val_if_fail (map != NULL, FALSE);
-
+
pnode = g_hash_table_lookup (map->pid_map, &pid);
if (pnode == NULL)
return FALSE;
-
+
return pnode->archived;
}
-gboolean
+gboolean
e_pilot_map_uid_is_archived (EPilotMap *map, const char *uid)
{
EPilotMapUidNode *unode;
g_return_val_if_fail (map != NULL, FALSE);
g_return_val_if_fail (uid != NULL, FALSE);
-
+
unode = g_hash_table_lookup (map->uid_map, uid);
if (unode == NULL)
return FALSE;
-
+
return unode->archived;
}
-void
+void
e_pilot_map_insert (EPilotMap *map, guint32 pid, const char *uid, gboolean archived)
{
EPilotMapPidNode *pnode;
@@ -228,7 +228,7 @@ e_pilot_map_insert (EPilotMap *map, guint32 pid, const char *uid, gboolean archi
real_e_pilot_map_insert (map, pid, uid, archived, TRUE);
}
-void
+void
e_pilot_map_remove_by_pid (EPilotMap *map, guint32 pid)
{
EPilotMapPidNode *pnode;
@@ -247,7 +247,7 @@ e_pilot_map_remove_by_pid (EPilotMap *map, guint32 pid)
g_hash_table_remove (map->pid_map, &pid);
}
-void
+void
e_pilot_map_remove_by_uid (EPilotMap *map, const char *uid)
{
EPilotMapPidNode *pnode;
@@ -267,28 +267,28 @@ e_pilot_map_remove_by_uid (EPilotMap *map, const char *uid)
}
-guint32
-e_pilot_map_lookup_pid (EPilotMap *map, const char *uid, gboolean touch)
+guint32
+e_pilot_map_lookup_pid (EPilotMap *map, const char *uid, gboolean touch)
{
EPilotMapUidNode *unode = NULL;
g_return_val_if_fail (map != NULL, 0);
g_return_val_if_fail (uid != NULL, 0);
-
+
unode = g_hash_table_lookup (map->uid_map, uid);
if (unode == NULL)
return 0;
-
+
if (touch) {
EPilotMapPidNode *pnode = NULL;
-
+
pnode = g_hash_table_lookup (map->pid_map, &unode->pid);
if (pnode != NULL)
pnode->touched = TRUE;
- unode->touched = TRUE;
+ unode->touched = TRUE;
}
-
+
return unode->pid;
}
@@ -298,26 +298,26 @@ e_pilot_map_lookup_uid (EPilotMap *map, guint32 pid, gboolean touch)
EPilotMapPidNode *pnode = NULL;
g_return_val_if_fail (map != NULL, NULL);
-
+
pnode = g_hash_table_lookup (map->pid_map, &pid);
if (pnode == NULL)
return NULL;
-
+
if (touch) {
EPilotMapUidNode *unode = NULL;
-
+
unode = g_hash_table_lookup (map->uid_map, pnode->uid);
g_return_val_if_fail (unode != NULL, NULL);
-
+
unode->touched = TRUE;
pnode->touched = TRUE;
}
-
+
return pnode->uid;
}
-int
+int
e_pilot_map_read (const char *filename, EPilotMap **map)
{
xmlSAXHandler handler;
@@ -349,12 +349,12 @@ e_pilot_map_read (const char *filename, EPilotMap **map)
}
new_map->write_touched_only = FALSE;
-
+
*map = new_map;
-
+
return 0;
}
-
+
int
e_pilot_map_write (const char *filename, EPilotMap *map)
{
@@ -364,7 +364,7 @@ e_pilot_map_write (const char *filename, EPilotMap *map)
g_return_val_if_fail (filename != NULL, -1);
g_return_val_if_fail (map != NULL, -1);
-
+
doc = xmlNewDoc ((const unsigned char *)"1.0");
if (doc == NULL) {
g_warning ("Pilot map file could not be created\n");
@@ -377,7 +377,7 @@ e_pilot_map_write (const char *filename, EPilotMap *map)
wd.touched_only = map->write_touched_only;
wd.root = xmlDocGetRootElement(doc);
g_hash_table_foreach (map->uid_map, map_write_foreach, &wd);
-
+
/* Write the file */
xmlSetDocCompressMode (doc, 0);
ret = e_xml_save_file (filename, doc);
@@ -385,7 +385,7 @@ e_pilot_map_write (const char *filename, EPilotMap *map)
g_warning ("Pilot map file '%s' could not be saved\n", filename);
return -1;
}
-
+
xmlFreeDoc (doc);
return 0;
@@ -403,7 +403,7 @@ e_pilot_map_clear (EPilotMap *map)
map->write_touched_only = FALSE;
}
-void
+void
e_pilot_map_destroy (EPilotMap *map)
{
g_return_if_fail (map != NULL);
diff --git a/e-util/e-pilot-util.c b/e-util/e-pilot-util.c
index dff11b14c7..b9e1bcb0e4 100644
--- a/e-util/e-pilot-util.c
+++ b/e-util/e-pilot-util.c
@@ -36,7 +36,7 @@ e_pilot_utf8_to_pchar (const char *string)
if (!string)
return NULL;
-
+
res = convert_ToPilotChar ("UTF-8", string, strlen (string), &pstring);
if (res != 0)
@@ -53,12 +53,12 @@ e_pilot_utf8_from_pchar (const char *string)
if (!string)
return NULL;
-
+
res = convert_FromPilotChar ("UTF-8", string, strlen (string), &ustring);
-
+
if (res != 0)
ustring = strdup (string);
-
+
return ustring;
}
@@ -76,7 +76,7 @@ e_pilot_get_sync_source (ESourceList *source_list)
for (s = e_source_group_peek_sources (group); s; s = s->next) {
ESource *source = E_SOURCE (s->data);
-
+
if (e_source_get_property (source, "pilot-sync"))
return source;
}
@@ -89,7 +89,7 @@ void
e_pilot_set_sync_source (ESourceList *source_list, ESource *source)
{
GSList *g;
-
+
g_return_if_fail (source_list != NULL);
g_return_if_fail (E_IS_SOURCE_LIST (source_list));
diff --git a/e-util/e-plugin.c b/e-util/e-plugin.c
index bdfe12c9b1..054298a942 100644
--- a/e-util/e-plugin.c
+++ b/e-util/e-plugin.c
@@ -270,17 +270,17 @@ ep_class_init(EPluginClass *klass)
/**
* e_plugin_get_type:
- *
+ *
* Standard GObject type function. This is only an abstract class, so
* you can only use this to subclass EPlugin.
- *
+ *
* Return value: The type.
**/
GType
e_plugin_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
char *path, *col, *p;
@@ -300,7 +300,7 @@ e_plugin_get_type(void)
path = g_build_filename(g_get_home_dir(), ".eplugins", NULL);
}
-
+
p = path;
while ((col = strchr(p, G_SEARCHPATH_SEPARATOR))) {
*col++ = 0;
@@ -310,7 +310,7 @@ e_plugin_get_type(void)
e_plugin_add_load_path(p);
g_free(path);
}
-
+
return type;
}
@@ -437,7 +437,7 @@ ep_load_pending(EPlugin *ep, EPluginHookClass *type)
if (class) {
if (strcmp(class, type->id) == 0) {
hook = g_object_new(G_OBJECT_CLASS_TYPE(type), NULL);
-
+
/* Don't bother loading hooks for plugins that are not anyway enabled */
if (ep->enabled) {
res = type->construct(hook, ep, node);
@@ -470,7 +470,7 @@ ep_load_pending(EPlugin *ep, EPluginHookClass *type)
/**
* e_plugin_add_load_path:
* @path: The path to add to search for plugins.
- *
+ *
* Add a path to be searched when e_plugin_load_plugins() is called.
* By default the system plugin directory and ~/.eplugins is used as
* the search path unless overriden by the environmental variable
@@ -489,10 +489,10 @@ e_plugin_add_load_path(const char *path)
/**
* e_plugin_load_plugins:
- *
+ *
* Scan the search path, looking for plugin definitions, and load them
* into memory.
- *
+ *
* Return value: Returns -1 if an error occurred.
**/
int
@@ -537,7 +537,7 @@ e_plugin_load_plugins(void)
/**
* e_plugin_register_type:
* @type: The GObject type of the plugin loader.
- *
+ *
* Register a new plugin type with the plugin system. Each type must
* subclass EPlugin and must override the type member of the
* EPluginClass with a unique name.
@@ -608,10 +608,10 @@ ep_list_plugin(void *key, void *val, void *dat)
/**
* e_plugin_list_plugins: List all plugins.
- *
+ *
* Static class method to retrieve a list of all current plugins. They
* are listed in no particular order.
- *
+ *
* Return value: A GSList of all plugins, they must be
* g_object_unref'd and the list freed.
**/
@@ -631,9 +631,9 @@ e_plugin_list_plugins(void)
* @ep: An EPlugin derived object.
* @root: The XML root node of the sub-tree containing the plugin
* definition.
- *
+ *
* Helper to invoke the construct virtual method.
- *
+ *
* Return value: The return from the construct virtual method.
**/
int
@@ -644,15 +644,15 @@ e_plugin_construct(EPlugin *ep, xmlNodePtr root)
/**
* e_plugin_invoke:
- * @ep:
+ * @ep:
* @name: The name of the function to invoke. The format of this name
* will depend on the EPlugin type and its language conventions.
* @data: The argument to the function. Its actual type depends on
* the hook on which the function resides. It is up to the called
* function to get this right.
- *
+ *
* Helper to invoke the invoke virtual method.
- *
+ *
* Return value: The return of the plugin invocation.
**/
void *
@@ -668,9 +668,9 @@ e_plugin_invoke(EPlugin *ep, const char *name, void *data)
/**
* e_plugin_enable:
- * @ep:
- * @state:
- *
+ * @ep:
+ * @state:
+ *
* Set the enable state of a plugin.
*
* THIS IS NOT FULLY IMPLEMENTED YET
@@ -686,8 +686,8 @@ e_plugin_enable(EPlugin *ep, int state)
/**
* e_plugin_configure:
-* @ep:
-*
+* @ep:
+*
*
**/
@@ -703,11 +703,11 @@ e_plugin_configure (EPlugin *ep)
* e_plugin_xml_prop:
* @node: An XML node.
* @id: The name of the property to retrieve.
- *
+ *
* A static helper function to look up a property on an XML node, and
* ensure it is allocated in GLib system memory. If GLib isn't using
* the system malloc then it must copy the property value.
- *
+ *
* Return value: The property, allocated in GLib memory, or NULL if no
* such property exists.
**/
@@ -732,10 +732,10 @@ e_plugin_xml_prop(xmlNodePtr node, const char *id)
* @node: An XML node.
* @id: The name of the property to retrieve.
* @domain: The translation domain for this string.
- *
+ *
* A static helper function to look up a property on an XML node, and
* translate it based on @domain.
- *
+ *
* Return value: The property, allocated in GLib memory, or NULL if no
* such property exists.
**/
@@ -760,11 +760,11 @@ e_plugin_xml_prop_domain(xmlNodePtr node, const char *id, const char *domain)
* @id: The name of the property to retrieve.
* @def: A default value if the property doesn't exist. Can be used
* to determine if the property isn't set.
- *
+ *
* A static helper function to look up a property on an XML node as an
* integer. If the property doesn't exist, then @def is returned as a
* default value instead.
- *
+ *
* Return value: The value if set, or @def if not.
**/
int
@@ -780,12 +780,12 @@ e_plugin_xml_int(xmlNodePtr node, const char *id, int def)
/**
* e_plugin_xml_content:
- * @node:
- *
+ * @node:
+ *
* A static helper function to retrieve the entire textual content of
* an XML node, and ensure it is allocated in GLib system memory. If
* GLib isn't using the system malloc them it must copy the content.
- *
+ *
* Return value: The node content, allocated in GLib memory.
**/
char *
@@ -806,13 +806,13 @@ e_plugin_xml_content(xmlNodePtr node)
/**
* e_plugin_xml_content_domain:
- * @node:
+ * @node:
* @domain:
- *
+ *
* A static helper function to retrieve the entire textual content of
* an XML node, and ensure it is allocated in GLib system memory. If
* GLib isn't using the system malloc them it must copy the content.
- *
+ *
* Return value: The node content, allocated in GLib memory.
**/
char *
@@ -852,7 +852,7 @@ epl_loadmodule(EPlugin *ep)
{
if (epl->module == NULL) {
EPluginLibEnableFunc enable;
-
+
if ((epl->module = g_module_open(epl->location, 0)) == NULL) {
g_warning("can't load plugin '%s'", g_module_error());
return -1;
@@ -1015,18 +1015,18 @@ epl_class_init(EPluginClass *klass)
/**
* e_plugin_lib_get_type:
- *
+ *
* Standard GObject function to retrieve the EPluginLib type. Use to
* register the type with the plugin system if you want to use shared
* library plugins.
- *
+ *
* Return value: The EPluginLib type.
**/
GType
e_plugin_lib_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EPluginLibClass), NULL, NULL, (GClassInitFunc) epl_class_init, NULL, NULL,
@@ -1036,7 +1036,7 @@ e_plugin_lib_get_type(void)
epl_parent_class = g_type_class_ref(e_plugin_get_type());
type = g_type_register_static(e_plugin_get_type(), "EPluginLib", &info, 0);
}
-
+
return type;
}
@@ -1072,17 +1072,17 @@ eph_class_init(EPluginHookClass *klass)
/**
* e_plugin_hook_get_type:
- *
+ *
* Standard GObject function to retrieve the EPluginHook type. Since
* EPluginHook is an abstract class, this is only used to subclass it.
- *
+ *
* Return value: The EPluginHook type.
**/
GType
e_plugin_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EPluginHookClass), NULL, NULL, (GClassInitFunc) eph_class_init, NULL, NULL,
@@ -1092,15 +1092,15 @@ e_plugin_hook_get_type(void)
eph_parent_class = g_type_class_ref(G_TYPE_OBJECT);
type = g_type_register_static(G_TYPE_OBJECT, "EPluginHook", &info, 0);
}
-
+
return type;
}
/**
* e_plugin_hook_enable: Set hook enabled state.
- * @eph:
- * @state:
- *
+ * @eph:
+ * @state:
+ *
* Set the enabled state of the plugin hook. This is called by the
* plugin code.
*
@@ -1114,8 +1114,8 @@ e_plugin_hook_enable(EPluginHook *eph, int state)
/**
* e_plugin_hook_register_type:
- * @type:
- *
+ * @type:
+ *
* Register a new plugin hook type with the plugin system. Each type
* must subclass EPluginHook and must override the id member of the
* EPluginHookClass with a unique identification string.
@@ -1195,7 +1195,7 @@ e_plugin_hook_register_type(GType type)
* @map: A zero-fill terminated array of EPluginHookTargeKeys used to
* map a string with a bit value.
* @prop: The property name.
- *
+ *
* This is a static helper function which looks up a property @prop on
* the XML node @root, and then uses the @map table to convert it into
* a bitmask. The property value is a comma separated list of
@@ -1241,17 +1241,17 @@ e_plugin_hook_mask(xmlNodePtr root, const struct _EPluginHookTargetKey *map, con
/**
* e_plugin_hook_id:
- * @root:
- * @map:
- * @prop:
- *
+ * @root:
+ * @map:
+ * @prop:
+ *
* This is a static helper function which looks up a property @prop on
* the XML node @root, and then uses the @map table to convert it into
* an integer.
*
* This is used as a helper wherever you need to represent an
* enumerated value in the XML.
- *
+ *
* Return value: If the @prop value is in @map, then the corresponding
* integer value, if not, then ~0.
**/
@@ -1352,7 +1352,7 @@ epth_class_init(EPluginHookClass *klass)
/**
* e_plugin_type_hook_get_type:
- *
+ *
* Get the type for the plugin plugin hook.
*
* Return value: The type of the plugin type hook.
@@ -1361,7 +1361,7 @@ GType
e_plugin_type_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EPluginTypeHookClass), NULL, NULL, (GClassInitFunc) epth_class_init, NULL, NULL,
@@ -1371,6 +1371,6 @@ e_plugin_type_hook_get_type(void)
epth_parent_class = g_type_class_ref(e_plugin_hook_get_type());
type = g_type_register_static(e_plugin_hook_get_type(), "EPluginTypeHook", &info, 0);
}
-
+
return type;
}
diff --git a/e-util/e-plugin.h b/e-util/e-plugin.h
index e1dc1f29fd..1d628dacd4 100644
--- a/e-util/e-plugin.h
+++ b/e-util/e-plugin.h
@@ -22,7 +22,7 @@ struct _EPluginAuthor {
/**
* struct _EPlugin - An EPlugin instance.
- *
+ *
* @object: Superclass.
* @id: Unique identifier for plugin instance.
* @path: Filename where the xml definition resides.
@@ -34,7 +34,7 @@ struct _EPluginAuthor {
* @hooks: A list of the EPluginHooks this plugin requires.
* @enabled: Whether the plugin is enabled or not. This is not fully
* implemented.
- *
+ *
* The base EPlugin object is used to represent each plugin directly.
* All of the plugin's hooks are loaded and managed through this
* object.
@@ -56,8 +56,8 @@ struct _EPlugin {
};
/**
- * struct _EPluginClass -
- *
+ * struct _EPluginClass -
+ *
* @class: Superclass.
* @type: The plugin type. This is used by the plugin loader to
* determine which plugin object to instantiate to handle the plugin.
@@ -126,18 +126,18 @@ typedef int (*EPluginLibEnableFunc)(EPluginLib *ep, int enable);
typedef int (*EPluginLibConfigureFunc)(EPluginLib *ep);
/**
- * struct _EPluginLib -
- *
+ * struct _EPluginLib -
+ *
* @plugin: Superclass.
* @location: The filename of the shared object.
* @module: The GModule once it is loaded.
- *
+ *
* This is a concrete EPlugin class. It loads and invokes dynamically
* loaded libraries using GModule. The shared object isn't loaded
* until the first callback is invoked.
*
* When the plugin is loaded, and if it exists, "e_plugin_lib_enable"
- * will be invoked to initialise the
+ * will be invoked to initialise the
**/
struct _EPluginLib {
EPlugin plugin;
@@ -147,10 +147,10 @@ struct _EPluginLib {
};
/**
- * struct _EPluginLibClass -
- *
+ * struct _EPluginLibClass -
+ *
* @plugin_class: Superclass.
- *
+ *
* The plugin library needs no additional class data.
**/
struct _EPluginLibClass {
@@ -169,11 +169,11 @@ typedef struct _EPluginHookTargetMap EPluginHookTargetMap;
typedef struct _EPluginHookTargetKey EPluginHookTargetKey;
/**
- * struct _EPluginHookTargetKey -
- *
+ * struct _EPluginHookTargetKey -
+ *
* @key: Enumeration value as a string.
* @value: Enumeration value as an integer.
- *
+ *
* A multi-purpose string to id mapping structure used with various
* helper functions to simplify plugin hook subclassing.
**/
@@ -183,8 +183,8 @@ struct _EPluginHookTargetKey {
};
/**
- * struct _EPluginHookTargetMap -
- *
+ * struct _EPluginHookTargetMap -
+ *
* @type: The string id of the target.
* @id: The integer id of the target. Maps directly to the type field
* of the various plugin type target id's.
@@ -202,10 +202,10 @@ struct _EPluginHookTargetMap {
/**
* struct _EPluginHook - A plugin hook.
- *
+ *
* @object: Superclass.
* @plugin: The parent object.
- *
+ *
* An EPluginHook is used as a container for each hook a given plugin
* is listening to.
**/
@@ -216,8 +216,8 @@ struct _EPluginHook {
};
/**
- * struct _EPluginHookClass -
- *
+ * struct _EPluginHookClass -
+ *
* @class: Superclass.
* @id: The plugin hook type. This must be overriden by each subclass
* and is used as a key when loading hook definitions. This string
@@ -227,7 +227,7 @@ struct _EPluginHook {
* @construct: Virtual method used to initialise the object when
* loaded.
* @enable: Virtual method used to enable or disable the hook.
- *
+ *
* The EPluginHookClass represents each hook type. The type of the
* class is registered in a global table and is used to instantiate a
* container for each hook.
diff --git a/e-util/e-popup.c b/e-util/e-popup.c
index c607b9045c..edeb6cebdc 100644
--- a/e-util/e-popup.c
+++ b/e-util/e-popup.c
@@ -164,9 +164,9 @@ ep_base_init(GObjectClass *klass)
/**
* e_popup_get_type:
- *
+ *
* Standard GObject type function.
- *
+ *
* Return value: The EPopup object type.
**/
GType
@@ -192,11 +192,11 @@ e_popup_get_type(void)
/**
* e_popup_new - Create an targetless popup menu manager.
* @menuid: Unique ID for this menu.
- *
+ *
* Create a targetless popup menu object. This can be used as a
* helper for creating popup menu's with no target. Such popup menu's
* wont be very pluggable.
- *
+ *
* Return value: A new EPopup.
**/
EPopup *e_popup_new(const char *menuid)
@@ -212,9 +212,9 @@ EPopup *e_popup_new(const char *menuid)
* e_popup_construct:
* @ep: An instantiated but uninitialised EPopup.
* @menuid: The menu identifier.
- *
+ *
* Construct the base popup instance with standard parameters.
- *
+ *
* Return value: Returns @ep.
**/
EPopup *e_popup_construct(EPopup *ep, const char *menuid)
@@ -233,7 +233,7 @@ EPopup *e_popup_construct(EPopup *ep, const char *menuid)
* longer needed.
* @data: user-data passed to @freefunc, and passed to all activate
* methods.
- *
+ *
* Add new EPopupItems to the menus. Any with the same path
* will override previously defined menu items, at menu building
* time. This may be called any number of times before the menu is
@@ -385,7 +385,7 @@ ep_build_tree(struct _item_node *inode, guint32 mask)
break;
case E_POPUP_RADIO: {
char *ppath = inode->parent?inode->parent->item->path:NULL;
-
+
menuitem = (GtkMenuItem *)gtk_radio_menu_item_new(g_hash_table_lookup(group_hash, ppath));
g_hash_table_insert(group_hash, ppath, gtk_radio_menu_item_get_group((GtkRadioMenuItem *)menuitem));
gtk_check_menu_item_set_active((GtkCheckMenuItem *)menuitem, item->type & E_POPUP_ACTIVE);
@@ -565,12 +565,12 @@ ep_popup_done(GtkWidget *w, EPopup *emp)
* @target: If set, the target of the selection. Static menu
* items will be added. The target will be freed once complete.
* @mask: Enable/disable and visibility mask.
- *
+ *
* Like popup_create_menu, but automatically sets up the menu
* so that it is destroyed once a selection takes place, and
* the EPopup is unreffed. This is the normal entry point as it
* automates most memory management for popup menus.
- *
+ *
* Return value: A menu, to popup.
**/
GtkMenu *
@@ -597,11 +597,11 @@ e_popup_create_menu_once(EPopup *emp, EPopupTarget *target, guint32 mask)
*
* This is a class-static method used to register factory callbacks
* against specific menu's.
- *
+ *
* The factory method will be invoked before the menu is created.
* This way, the factory may add any additional menu items it wishes
* based on the context supplied in the @target.
- *
+ *
* Return value: A handle to the factory which can be used to remove
* it later.
**/
@@ -622,7 +622,7 @@ e_popup_class_add_factory(EPopupClass *klass, const char *menuid, EPopupFactoryF
* e_popup_class_remove_factory:
* @klass: The EPopup derived class.
* @f: The factory handle returned by e_popup_class_add_factory().
- *
+ *
* Remove a popup menu factory. If it has not been added, or it has
* already been removed, then the result is undefined (i.e. it will
* crash).
@@ -644,7 +644,7 @@ e_popup_class_remove_factory(EPopupClass *klass, EPopupFactory *f)
* @type: type, defined by the implementing class.
* @size: The size of memory to allocate for the target. It must be
* equal or greater than the size of EPopupTarget.
- *
+ *
* Allocate a new popup target suitable for this popup type.
**/
void *e_popup_target_new(EPopup *ep, int type, size_t size)
@@ -668,7 +668,7 @@ void *e_popup_target_new(EPopup *ep, int type, size_t size)
* e_popup_target_free:
* @ep: An EPopup derived object.
* @o: The target, previously allocated by e_popup_target_new().
- *
+ *
* Free the target against @ep. Note that targets are automatically
* freed if they are passed to the menu creation functions, so this is
* only required if you are using the target for other purposes.
@@ -912,7 +912,7 @@ emph_class_init(EPluginHookClass *klass)
/**
* e_popup_hook_get_type:
- *
+ *
* Standard GObject function to get the object type. Used to subclass
* EPopupHook.
*
@@ -922,7 +922,7 @@ GType
e_popup_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EPopupHookClass), NULL, NULL, (GClassInitFunc) emph_class_init, NULL, NULL,
@@ -932,7 +932,7 @@ e_popup_hook_get_type(void)
emph_parent_class = g_type_class_ref(e_plugin_hook_get_type());
type = g_type_register_static(e_plugin_hook_get_type(), "EPopupHook", &info, 0);
}
-
+
return type;
}
@@ -941,7 +941,7 @@ e_popup_hook_get_type(void)
* @klass: The derived EPopupHook class.
* @map: A map used to describe a single EPopupTarget type for this
* class.
- *
+ *
* Add a target map to a concrete derived class of EPopup. The target
* map enumerates a single target type and the enable mask bit names,
* so that the type can be loaded automatically by the EPopup class.
diff --git a/e-util/e-popup.h b/e-util/e-popup.h
index e6d12cb9d4..a4928c035c 100644
--- a/e-util/e-popup.h
+++ b/e-util/e-popup.h
@@ -148,12 +148,12 @@ struct _EPopupTarget {
/**
* struct _EPopup - A Popup menu manager.
- *
+ *
* @object: Superclass, GObject.
* @priv: Private data.
* @menuid: The id of this menu instance.
* @target: The current target during the display of the popup menu.
- *
+ *
* The EPopup manager object. Each popup menu is built using this
* one-off object which is created each time the popup is invoked.
*/
@@ -168,15 +168,15 @@ struct _EPopup {
};
/**
- * struct _EPopupClass -
- *
+ * struct _EPopupClass -
+ *
* @object_class: Superclass type.
* @factories: A list of factories for this particular class of popup
* menu.
* @target_free: Virtual method to free the popup target. The base
* class frees the allocation and unrefs the popup pointer
* structure.
- *
+ *
* The EPopup class definition. This should be sub-classed for each
* component that wants to provide hookable popup menus. The
* sub-class only needs to know how to allocate and free the various target
@@ -229,15 +229,15 @@ typedef struct _EPluginHookTargetKey EPopupHookTargetMask;
typedef void (*EPopupHookFunc)(struct _EPlugin *plugin, EPopupTarget *target);
/**
- * struct _EPopupHookMenu -
- *
+ * struct _EPopupHookMenu -
+ *
* @hook: Parent pointer.
* @id: The identifier of the menu to which these items belong.
* @target_type: The target number of the type of target these menu
* items expect. It will generally also be defined by the menu id.
* @items: A list of EPopupItems.
* @factory: If supplied, a function to call
- *
+ *
* The structure used to keep track of all of the items that a plugin
* wishes to add to a given menu. This is used internally by a factory
* method set on EPlugin to add the right menu items to a given menu.
@@ -252,7 +252,7 @@ struct _EPopupHookMenu {
/**
* struct _EPopupHook - A popup menu hook.
- *
+ *
* @hook: Superclass.
* @menus: A list of EPopupHookMenus, for all menus registered on
* this hook type.
@@ -267,14 +267,14 @@ struct _EPopupHook {
};
/**
- * struct _EPopupHookClass -
- *
+ * struct _EPopupHookClass -
+ *
* @hook_class: Superclass.
* @target_map: Table of EPluginHookTargetMaps which enumerate the
* target types and enable bits of the implementing class.
* @popup_class: The EPopupClass of the corresponding popup manager
* for the implementing class.
- *
+ *
* The EPopupHookClass is a concrete class, however it is empty on its
* own. It needs to be sub-classed and initialised appropriately.
*
diff --git a/e-util/e-print.c b/e-util/e-print.c
index 204b621286..57d089f779 100644
--- a/e-util/e-print.c
+++ b/e-util/e-print.c
@@ -58,7 +58,7 @@ load_settings (void)
GtkPrintSettings *settings;
GSList *list;
GError *error = NULL;
-
+
client = gconf_client_get_default ();
settings = gtk_print_settings_new ();
@@ -83,9 +83,9 @@ save_settings (GtkPrintSettings *settings)
GConfClient *client;
GSList *list = NULL;
GError *error = NULL;
-
+
client = gconf_client_get_default ();
-
+
gtk_print_settings_foreach (
settings, (GtkPrintSettingsFunc) pack_settings, &list);
gconf_client_set_list (
@@ -96,7 +96,7 @@ save_settings (GtkPrintSettings *settings)
}
g_slist_foreach (list, (GFunc) g_free, NULL);
g_slist_free (list);
-
+
g_object_unref (client);
}
@@ -113,7 +113,7 @@ load_page_setup (GtkPrintSettings *settings)
if (paper_size != NULL)
gtk_page_setup_set_paper_size_and_default_margins (
page_setup, paper_size);
-
+
return page_setup;
}
diff --git a/e-util/e-print.h b/e-util/e-print.h
index 9102ddb9f5..740989a79b 100644
--- a/e-util/e-print.h
+++ b/e-util/e-print.h
@@ -31,4 +31,4 @@ void e_print_run_page_setup_dialog (GtkWindow *parent);
G_END_DECLS
-#endif
+#endif
diff --git a/e-util/e-profile-event.c b/e-util/e-profile-event.c
index 9c86f72b60..023f76746e 100644
--- a/e-util/e-profile-event.c
+++ b/e-util/e-profile-event.c
@@ -92,11 +92,11 @@ e_profile_event_get_type(void)
/**
* e_profile_event_peek:
- * @void:
- *
+ * @void:
+ *
* Get the singular instance of the profile event handler.
- *
- * Return value:
+ *
+ * Return value:
**/
EProfileEvent *e_profile_event_peek(void)
{
@@ -185,7 +185,7 @@ GType
e_profile_event_hook_get_type(void)
{
static GType type = 0;
-
+
if (!type) {
static const GTypeInfo info = {
sizeof(EProfileEventHookClass), NULL, NULL, (GClassInitFunc) emeh_class_init, NULL, NULL,
@@ -195,6 +195,6 @@ e_profile_event_hook_get_type(void)
emeh_parent_class = g_type_class_ref(e_event_hook_get_type());
type = g_type_register_static(e_event_hook_get_type(), "EProfileEventHook", &info, 0);
}
-
+
return type;
}
diff --git a/e-util/e-request.c b/e-util/e-request.c
index a0fb9cfac3..beb52686e9 100644
--- a/e-util/e-request.c
+++ b/e-util/e-request.c
@@ -39,9 +39,9 @@
* @title: the dialog title (in the locale character set)
* @prompt: the prompt (in the locale character set)
* @default: default value (in UTF8)
- *
+ *
* Request a string from the user.
- *
+ *
* Return value: %NULL if the user cancelled the dialog, the inserted
* string (in UTF8) otherwise. The string must be freed by the caller.
**/
@@ -56,10 +56,10 @@ e_request_string (GtkWindow *parent,
GtkWidget *dialog;
GtkWidget *entry;
GtkWidget *vbox;
-
+
g_return_val_if_fail (title != NULL, NULL);
g_return_val_if_fail (prompt != NULL, NULL);
-
+
dialog = gtk_dialog_new_with_buttons (title, parent,
GTK_DIALOG_DESTROY_WITH_PARENT | GTK_DIALOG_MODAL,
GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
@@ -68,13 +68,13 @@ e_request_string (GtkWindow *parent,
gtk_dialog_set_has_separator (GTK_DIALOG (dialog), FALSE);
gtk_dialog_set_default_response (GTK_DIALOG (dialog), GTK_RESPONSE_OK);
gtk_window_set_default_size (GTK_WINDOW (dialog), 275, -1);
- gtk_container_set_border_width (GTK_CONTAINER (dialog), 6);
+ gtk_container_set_border_width (GTK_CONTAINER (dialog), 6);
vbox = GTK_DIALOG (dialog)->vbox;
-
+
prompt_label = gtk_label_new (prompt);
gtk_box_pack_start (GTK_BOX (vbox), prompt_label, TRUE, TRUE, 6);
- gtk_box_set_spacing (GTK_BOX (vbox), 6);
+ gtk_box_set_spacing (GTK_BOX (vbox), 6);
entry = gtk_entry_new ();
gtk_entry_set_text (GTK_ENTRY (entry), default_string);
@@ -82,14 +82,14 @@ e_request_string (GtkWindow *parent,
gtk_entry_set_activates_default (GTK_ENTRY (entry), TRUE);
gtk_box_pack_start (GTK_BOX (vbox), entry, TRUE, TRUE, 3);
- atk_object_set_description (gtk_widget_get_accessible (entry), prompt);
+ atk_object_set_description (gtk_widget_get_accessible (entry), prompt);
gtk_widget_grab_focus (entry);
-
+
gtk_widget_show (prompt_label);
gtk_widget_show (entry);
gtk_widget_show (dialog);
-
+
switch (gtk_dialog_run (GTK_DIALOG (dialog))) {
case GTK_RESPONSE_OK:
text = g_strdup (gtk_entry_get_text (GTK_ENTRY (entry)));
@@ -100,6 +100,6 @@ e_request_string (GtkWindow *parent,
}
gtk_widget_destroy (dialog);
-
+
return text;
}
diff --git a/e-util/e-signature-list.c b/e-util/e-signature-list.c
index cbdf138a95..8acd9af451 100644
--- a/e-util/e-signature-list.c
+++ b/e-util/e-signature-list.c
@@ -61,7 +61,7 @@ GType
e_signature_list_get_type (void)
{
static GType type = 0;
-
+
if (!type) {
GTypeInfo type_info = {
sizeof (ESignatureListClass),
@@ -72,10 +72,10 @@ e_signature_list_get_type (void)
0,
(GInstanceInitFunc) e_signature_list_init,
};
-
+
type = g_type_register_static (E_TYPE_LIST, "ESignatureList", &type_info, 0);
}
-
+
return type;
}
@@ -84,13 +84,13 @@ static void
e_signature_list_class_init (ESignatureListClass *klass)
{
GObjectClass *object_class = (GObjectClass *) klass;
-
+
parent_class = g_type_class_ref (E_TYPE_LIST);
-
+
/* virtual method override */
object_class->dispose = e_signature_list_dispose;
object_class->finalize = e_signature_list_finalize;
-
+
/* signals */
signals[SIGNATURE_ADDED] =
g_signal_new ("signature-added",
@@ -131,14 +131,14 @@ static void
e_signature_list_dispose (GObject *object)
{
ESignatureList *list = (ESignatureList *) object;
-
+
if (list->priv->gconf) {
if (list->priv->notify_id != 0)
gconf_client_notify_remove (list->priv->gconf, list->priv->notify_id);
g_object_unref (list->priv->gconf);
list->priv->gconf = NULL;
}
-
+
G_OBJECT_CLASS (parent_class)->dispose (object);
}
@@ -146,9 +146,9 @@ static void
e_signature_list_finalize (GObject *object)
{
ESignatureList *list = (ESignatureList *) object;
-
+
g_free (list->priv);
-
+
G_OBJECT_CLASS (parent_class)->finalize (object);
}
@@ -156,13 +156,13 @@ static GSList *
add_autogen (ESignatureList *list, GSList *new_sigs)
{
ESignature *autogen;
-
+
autogen = e_signature_new ();
autogen->name = g_strdup ("Autogenerated");
autogen->autogen = TRUE;
-
+
e_list_append (E_LIST (list), autogen);
-
+
return g_slist_prepend (new_sigs, autogen);
}
@@ -178,9 +178,9 @@ gconf_signatures_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry,
EIterator *iter;
gboolean found;
char *uid;
-
+
old_sigs = e_list_duplicate (E_LIST (signature_list));
-
+
list = gconf_client_get_list (client, "/apps/evolution/mail/signatures", GCONF_VALUE_STRING, NULL);
for (l = list; l; l = l->next) {
found = FALSE;
@@ -196,16 +196,16 @@ gconf_signatures_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry,
e_iterator_delete (iter);
if (e_signature_set_from_xml (signature, l->data))
g_signal_emit (signature_list, signals[SIGNATURE_CHANGED], 0, signature);
-
+
have_autogen |= signature->autogen;
-
+
break;
}
}
-
+
g_object_unref (iter);
}
-
+
if (!found) {
/* Must be a new signature */
signature = e_signature_new_from_xml (l->data);
@@ -214,20 +214,20 @@ gconf_signatures_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry,
signature->uid = e_uid_new ();
resave = TRUE;
}
-
+
e_list_append (E_LIST (signature_list), signature);
new_sigs = g_slist_prepend (new_sigs, signature);
}
-
+
g_free (uid);
}
-
+
if (!have_autogen) {
new_sigs = add_autogen (signature_list, new_sigs);
have_autogen = TRUE;
resave = TRUE;
}
-
+
if (new_sigs != NULL) {
/* Now emit signals for each added signature. */
l = g_slist_reverse (new_sigs);
@@ -240,17 +240,17 @@ gconf_signatures_changed (GConfClient *client, guint cnxn_id, GConfEntry *entry,
l = n;
}
}
-
+
/* Anything left in old_sigs must have been deleted */
for (iter = e_list_get_iterator (old_sigs); e_iterator_is_valid (iter); e_iterator_next (iter)) {
signature = (ESignature *) e_iterator_get (iter);
e_list_remove (E_LIST (signature_list), signature);
g_signal_emit (signature_list, signals[SIGNATURE_REMOVED], 0, signature);
}
-
+
g_object_unref (iter);
g_object_unref (old_sigs);
-
+
signature_list->priv->resave = resave;
}
@@ -258,9 +258,9 @@ static void *
copy_func (const void *data, void *closure)
{
GObject *object = (GObject *)data;
-
+
g_object_ref (object);
-
+
return object;
}
@@ -289,12 +289,12 @@ ESignatureList *
e_signature_list_new (GConfClient *gconf)
{
ESignatureList *signature_list;
-
+
g_return_val_if_fail (GCONF_IS_CLIENT (gconf), NULL);
-
+
signature_list = g_object_new (E_TYPE_SIGNATURE_LIST, NULL);
e_signature_list_construct (signature_list, gconf);
-
+
return signature_list;
}
@@ -302,29 +302,29 @@ void
e_signature_list_construct (ESignatureList *signature_list, GConfClient *gconf)
{
g_return_if_fail (GCONF_IS_CLIENT (gconf));
-
+
e_list_construct (E_LIST (signature_list), copy_func, free_func, NULL);
signature_list->priv->gconf = gconf;
g_object_ref (gconf);
-
+
gconf_client_add_dir (signature_list->priv->gconf,
"/apps/evolution/mail/signatures",
GCONF_CLIENT_PRELOAD_ONELEVEL, NULL);
-
+
signature_list->priv->notify_id =
gconf_client_notify_add (signature_list->priv->gconf,
"/apps/evolution/mail/signatures",
gconf_signatures_changed, signature_list,
NULL, NULL);
-
+
gconf_signatures_changed (signature_list->priv->gconf,
signature_list->priv->notify_id,
NULL, signature_list);
-
+
if (signature_list->priv->resave) {
e_signature_list_save (signature_list);
signature_list->priv->resave = FALSE;
- }
+ }
}
@@ -341,27 +341,27 @@ e_signature_list_save (ESignatureList *signature_list)
ESignature *signature;
EIterator *iter;
char *xmlbuf;
-
+
for (iter = e_list_get_iterator (E_LIST (signature_list));
e_iterator_is_valid (iter);
e_iterator_next (iter)) {
signature = (ESignature *) e_iterator_get (iter);
-
+
if ((xmlbuf = e_signature_to_xml (signature)))
list = g_slist_append (list, xmlbuf);
}
-
+
g_object_unref (iter);
-
+
gconf_client_set_list (signature_list->priv->gconf,
"/apps/evolution/mail/signatures",
GCONF_VALUE_STRING, list, NULL);
-
+
while (list) {
g_free (list->data);
list = g_slist_remove (list, list->data);
}
-
+
gconf_client_suggest_sync (signature_list->priv->gconf, NULL);
}
@@ -370,7 +370,7 @@ e_signature_list_save (ESignatureList *signature_list)
* e_signature_list_add:
* @signatures: signature list
* @signature: signature to add
- *
+ *
* Add an signature to the signature list. Will emit the signature-changed
* event.
**/
@@ -386,7 +386,7 @@ e_signature_list_add (ESignatureList *signatures, ESignature *signature)
* e_signature_list_change:
* @signatures: signature list
* @signature: signature to change
- *
+ *
* Signal that the details of an signature have changed.
**/
void
@@ -401,7 +401,7 @@ e_signature_list_change (ESignatureList *signatures, ESignature *signature)
* e_signature_list_remove:
* @signatures: signature list
* @signature: signature
- *
+ *
* Remove an signature from the signature list, and emit the
* signature-removed signal. If the signature was the default signature,
* then reset the default to the first signature.
@@ -422,13 +422,13 @@ e_signature_list_remove (ESignatureList *signatures, ESignature *signature)
* @signatures: signature list
* @type: Type of search.
* @key: Search key.
- *
+ *
* Perform a search of the signature list on a single key.
*
* @type must be set from one of the following search types:
* E_SIGNATURE_FIND_NAME - Find a signature by signature name.
* E_SIGNATURE_FIND_UID - Find a signature based on UID
- *
+ *
* Return value: The signature or NULL if it doesn't exist.
**/
const ESignature *
@@ -436,20 +436,20 @@ e_signature_list_find (ESignatureList *signatures, e_signature_find_t type, cons
{
const ESignature *signature = NULL;
EIterator *it;
-
+
/* this could use a callback for more flexibility ...
... but this makes the common cases easier */
-
+
if (!key)
return NULL;
-
+
for (it = e_list_get_iterator ((EList *) signatures);
e_iterator_is_valid (it);
e_iterator_next (it)) {
int found = 0;
-
+
signature = (const ESignature *) e_iterator_get (it);
-
+
switch (type) {
case E_SIGNATURE_FIND_NAME:
found = strcmp (signature->name, key) == 0;
@@ -458,14 +458,14 @@ e_signature_list_find (ESignatureList *signatures, e_signature_find_t type, cons
found = strcmp (signature->uid, key) == 0;
break;
}
-
+
if (found)
break;
-
+
signature = NULL;
}
-
+
g_object_unref (it);
-
+
return signature;
}
diff --git a/e-util/e-signature-list.h b/e-util/e-signature-list.h
index 6dae824616..d79963672a 100644
--- a/e-util/e-signature-list.h
+++ b/e-util/e-signature-list.h
@@ -46,13 +46,13 @@ typedef enum {
struct _ESignatureList {
EList parent_object;
-
+
struct _ESignatureListPrivate *priv;
};
struct _ESignatureListClass {
EListClass parent_class;
-
+
/* signals */
void (* signature_added) (ESignatureList *, ESignature *);
void (* signature_changed) (ESignatureList *, ESignature *);
diff --git a/e-util/e-signature.c b/e-util/e-signature.c
index 9803ba7389..c062468174 100644
--- a/e-util/e-signature.c
+++ b/e-util/e-signature.c
@@ -50,7 +50,7 @@ GType
e_signature_get_type (void)
{
static GType type = 0;
-
+
if (!type) {
GTypeInfo type_info = {
sizeof (ESignatureClass),
@@ -61,10 +61,10 @@ e_signature_get_type (void)
0,
(GInstanceInitFunc) e_signature_init,
};
-
+
type = g_type_register_static (G_TYPE_OBJECT, "ESignature", &type_info, 0);
}
-
+
return type;
}
@@ -72,9 +72,9 @@ static void
e_signature_class_init (ESignatureClass *klass)
{
GObjectClass *object_class = (GObjectClass *) klass;
-
+
parent_class = g_type_class_ref (G_TYPE_OBJECT);
-
+
/* virtual method override */
object_class->finalize = e_signature_finalize;
}
@@ -89,11 +89,11 @@ static void
e_signature_finalize (GObject *object)
{
ESignature *sig = (ESignature *) object;
-
+
g_free (sig->uid);
g_free (sig->name);
g_free (sig->filename);
-
+
G_OBJECT_CLASS (parent_class)->finalize (object);
}
@@ -108,10 +108,10 @@ ESignature *
e_signature_new (void)
{
ESignature *signature;
-
+
signature = g_object_new (E_TYPE_SIGNATURE, NULL);
signature->uid = e_uid_new ();
-
+
return signature;
}
@@ -127,13 +127,13 @@ ESignature *
e_signature_new_from_xml (const char *xml)
{
ESignature *signature;
-
+
signature = g_object_new (E_TYPE_SIGNATURE, NULL);
if (!e_signature_set_from_xml (signature, xml)) {
g_object_unref (signature);
return NULL;
}
-
+
return signature;
}
@@ -143,17 +143,17 @@ xml_set_bool (xmlNodePtr node, const char *name, gboolean *val)
{
gboolean bool;
char *buf;
-
+
if ((buf = (char *)xmlGetProp (node, (const unsigned char *)name))) {
bool = (!strcmp (buf, "true") || !strcmp (buf, "yes"));
xmlFree (buf);
-
+
if (bool != *val) {
*val = bool;
return TRUE;
}
}
-
+
return FALSE;
}
@@ -161,11 +161,11 @@ static gboolean
xml_set_prop (xmlNodePtr node, const char *name, char **val)
{
char *buf, *new_val;
-
+
buf = (char *)xmlGetProp (node, (const unsigned char *)name);
new_val = g_strdup (buf);
xmlFree (buf);
-
+
/* We can use strcmp here whether the value is UTF8 or
* not, since we only care if the bytes changed.
*/
@@ -183,11 +183,11 @@ static gboolean
xml_set_content (xmlNodePtr node, char **val)
{
char *buf, *new_val;
-
+
buf = (char *)xmlNodeGetContent (node);
new_val = g_strdup (buf);
xmlFree (buf);
-
+
/* We can use strcmp here whether the value is UTF8 or
* not, since we only care if the bytes changed.
*/
@@ -216,19 +216,19 @@ e_signature_uid_from_xml (const char *xml)
xmlNodePtr node;
xmlDocPtr doc;
char *uid = NULL;
-
+
if (!(doc = xmlParseDoc ((unsigned char *) xml)))
return NULL;
-
+
node = doc->children;
if (strcmp ((char *)node->name, "signature") != 0) {
xmlFreeDoc (doc);
return NULL;
}
-
+
xml_set_prop (node, "uid", &uid);
xmlFreeDoc (doc);
-
+
return uid;
}
@@ -250,22 +250,22 @@ e_signature_set_from_xml (ESignature *signature, const char *xml)
xmlDocPtr doc;
gboolean bool;
char *buf;
-
+
if (!(doc = xmlParseDoc ((unsigned char *) xml)))
return FALSE;
-
+
node = doc->children;
if (strcmp ((char *)node->name, "signature") != 0) {
xmlFreeDoc (doc);
return FALSE;
}
-
+
if (!signature->uid)
xml_set_prop (node, "uid", &signature->uid);
-
+
changed |= xml_set_prop (node, "name", &signature->name);
changed |= xml_set_bool (node, "auto", &signature->autogen);
-
+
if (signature->autogen) {
/* we're done */
g_free (signature->filename);
@@ -273,10 +273,10 @@ e_signature_set_from_xml (ESignature *signature, const char *xml)
signature->script = FALSE;
signature->html = FALSE;
xmlFreeDoc (doc);
-
+
return changed;
}
-
+
buf = NULL;
xml_set_prop (node, "format", &buf);
if (buf && !strcmp (buf, "text/html"))
@@ -284,12 +284,12 @@ e_signature_set_from_xml (ESignature *signature, const char *xml)
else
bool = FALSE;
g_free (buf);
-
+
if (signature->html != bool) {
signature->html = bool;
changed = TRUE;
}
-
+
cur = node->children;
while (cur) {
if (!strcmp ((char *)cur->name, "filename")) {
@@ -305,12 +305,12 @@ e_signature_set_from_xml (ESignature *signature, const char *xml)
}
break;
}
-
+
cur = cur->next;
}
-
+
xmlFreeDoc (doc);
-
+
return changed;
}
@@ -330,19 +330,19 @@ e_signature_to_xml (ESignature *signature)
xmlNodePtr root, node;
xmlDocPtr doc;
int n;
-
+
doc = xmlNewDoc ((const unsigned char *)"1.0");
-
+
root = xmlNewDocNode (doc, NULL, (const unsigned char *)"signature", NULL);
xmlDocSetRootElement (doc, root);
-
+
xmlSetProp (root, (const unsigned char *)"name", (unsigned char *)signature->name);
xmlSetProp (root, (const unsigned char *)"uid", (unsigned char *)signature->uid);
xmlSetProp (root, (const unsigned char *)"auto", (const unsigned char *)(signature->autogen ? "true" : "false"));
-
+
if (!signature->autogen) {
xmlSetProp (root, (const unsigned char *)"format", (const unsigned char *)(signature->html ? "text/html" : "text/plain"));
-
+
if (signature->filename) {
node = xmlNewTextChild (root, NULL, (const unsigned char *)"filename", (unsigned char *)signature->filename);
if (signature->script)
@@ -352,16 +352,16 @@ e_signature_to_xml (ESignature *signature)
/* this is to make Evolution-1.4 and older 1.5 versions happy */
xmlSetProp (root, (const unsigned char *)"format", (const unsigned char *)"text/html");
}
-
+
xmlDocDumpMemory (doc, &xmlbuf, &n);
xmlFreeDoc (doc);
-
+
/* remap to glib memory */
tmp = g_malloc (n + 1);
memcpy (tmp, xmlbuf, n);
tmp[n] = '\0';
xmlFree (xmlbuf);
-
+
return tmp;
}
diff --git a/e-util/e-signature.h b/e-util/e-signature.h
index a7e1d9d207..5de0d64a66 100644
--- a/e-util/e-signature.h
+++ b/e-util/e-signature.h
@@ -42,11 +42,11 @@ typedef struct _ESignatureClass ESignatureClass;
struct _ESignature {
GObject parent_object;
-
+
gboolean autogen;
gboolean script;
gboolean html;
-
+
char *filename;
char *name;
char *uid;
@@ -54,7 +54,7 @@ struct _ESignature {
struct _ESignatureClass {
GObjectClass parent_class;
-
+
};
diff --git a/e-util/e-sorter-array.c b/e-util/e-sorter-array.c
index 6098efef03..3a2eaffe3c 100644
--- a/e-util/e-sorter-array.c
+++ b/e-util/e-sorter-array.c
@@ -242,7 +242,7 @@ e_sorter_array_class_init (ESorterArrayClass *klass)
sorter_class->model_to_sorted = esa_model_to_sorted ;
sorter_class->sorted_to_model = esa_sorted_to_model ;
sorter_class->get_model_to_sorted_array = esa_get_model_to_sorted_array ;
- sorter_class->get_sorted_to_model_array = esa_get_sorted_to_model_array ;
+ sorter_class->get_sorted_to_model_array = esa_get_sorted_to_model_array ;
sorter_class->needs_sorting = esa_needs_sorting ;
}
diff --git a/e-util/e-sorter-array.h b/e-util/e-sorter-array.h
index 9d5f7fad1b..a695b0d394 100644
--- a/e-util/e-sorter-array.h
+++ b/e-util/e-sorter-array.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-sorter-array.h
* Copyright 2000, 2001, Ximian, Inc.
*
diff --git a/e-util/e-sorter.c b/e-util/e-sorter.c
index 992afe68f4..89e9eca459 100644
--- a/e-util/e-sorter.c
+++ b/e-util/e-sorter.c
@@ -60,7 +60,7 @@ ESorter *
e_sorter_new (void)
{
ESorter *es = g_object_new (E_SORTER_TYPE, NULL);
-
+
return es;
}
diff --git a/e-util/e-sorter.h b/e-util/e-sorter.h
index 732061dc1a..c43a93ff5c 100644
--- a/e-util/e-sorter.h
+++ b/e-util/e-sorter.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-sorter.h
* Copyright 2000, 2001, Ximian, Inc.
*
@@ -47,14 +47,14 @@ typedef struct {
int row);
gint (*sorted_to_model) (ESorter *sorter,
int row);
-
+
void (*get_model_to_sorted_array) (ESorter *sorter,
int **array,
int *count);
void (*get_sorted_to_model_array) (ESorter *sorter,
int **array,
int *count);
-
+
gboolean (*needs_sorting) (ESorter *sorter);
} ESorterClass;
diff --git a/e-util/e-text-event-processor-emacs-like.c b/e-util/e-text-event-processor-emacs-like.c
index b39b56df16..dfde0cf446 100644
--- a/e-util/e-text-event-processor-emacs-like.c
+++ b/e-util/e-text-event-processor-emacs-like.c
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-text-event-processor-emacs-like.c
* Copyright 2000, 2001, Ximian, Inc.
*
@@ -185,7 +185,7 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
command.value = event->motion.position;
}
break;
- case GDK_KEY_PRESS:
+ case GDK_KEY_PRESS:
{
ETextEventProcessorEventKey key = event->key;
command.time = event->key.time;
@@ -236,7 +236,7 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
else
command.position = E_TEP_FORWARD_CHARACTER;
break;
-
+
case GDK_BackSpace:
command.action = E_TEP_DELETE;
if (key.state & GDK_CONTROL_MASK)
@@ -272,7 +272,7 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
command.action = E_TEP_COPY;
command.position = E_TEP_SELECTION;
g_signal_emit_by_name (tep, "command", &command);
-
+
command.action = E_TEP_DELETE;
command.position = E_TEP_SELECTION;
break;
@@ -285,7 +285,7 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
command.action = E_TEP_COPY;
command.position = E_TEP_SELECTION;
g_signal_emit_by_name (tep, "command", &command);
-
+
command.action = E_TEP_DELETE;
command.position = E_TEP_SELECTION;
} else {
@@ -436,7 +436,7 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
if ((key.state & GDK_CONTROL_MASK) && !(key.state & GDK_MOD1_MASK)) {
if ((key.keyval >= 'A') && (key.keyval <= 'Z'))
key.keyval -= 'A' - 'a';
-
+
if ((key.keyval >= 'a') && (key.keyval <= 'z')) {
command.position = control_keys[(int) (key.keyval - 'a')].position;
if (control_keys[(int) (key.keyval - 'a')].action != E_TEP_MOVE)
@@ -453,16 +453,16 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
command.action = E_TEP_COPY;
command.position = E_TEP_SELECTION;
g_signal_emit_by_name (tep, "command", &command);
-
+
command.action = E_TEP_DELETE;
command.position = E_TEP_SELECTION;
}
-
+
break;
} else if ((key.state & GDK_MOD1_MASK) && !(key.state & GDK_CONTROL_MASK)) {
if ((key.keyval >= 'A') && (key.keyval <= 'Z'))
key.keyval -= 'A' - 'a';
-
+
if ((key.keyval >= 'a') && (key.keyval <= 'z')) {
command.position = alt_keys[(int) (key.keyval - 'a')].position;
if (alt_keys[(int) (key.keyval - 'a')].action != E_TEP_MOVE)
@@ -479,7 +479,7 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
command.position = E_TEP_SELECTION;
command.value = strlen(key.string);
command.string = key.string;
-
+
} else {
command.action = E_TEP_NOP;
}
diff --git a/e-util/e-text-event-processor-emacs-like.h b/e-util/e-text-event-processor-emacs-like.h
index c6020cb993..9726ab3a06 100644
--- a/e-util/e-text-event-processor-emacs-like.h
+++ b/e-util/e-text-event-processor-emacs-like.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-text-event-processor-emacs-like.h
* Copyright 2000, 2001, Ximian, Inc.
*
@@ -48,7 +48,7 @@ typedef struct _ETextEventProcessorEmacsLikeClass ETextEventProcessorEmacsLikeC
struct _ETextEventProcessorEmacsLike
{
ETextEventProcessor parent;
-
+
/* object specific fields */
guint mouse_down : 1;
};
diff --git a/e-util/e-text-event-processor-types.h b/e-util/e-text-event-processor-types.h
index 0966044806..ba68cae113 100644
--- a/e-util/e-text-event-processor-types.h
+++ b/e-util/e-text-event-processor-types.h
@@ -1,5 +1,5 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
+/*
* e-text-event-processor-types.h
* Copyright 2000, 2001, Ximian, Inc.
*
@@ -69,7 +69,7 @@ typedef enum {
E_TEP_INSERT,
E_TEP_CAPS,
-
+
E_TEP_COPY,
E_TEP_PASTE,
E_TEP_GET_SELECTION,
diff --git a/e-util/e-text-event-processor.c b/e-util/e-text-event-processor.c
index a46301db73..a1121adbad 100644
--- a/e-util/e-text-event-processor.c
+++ b/e-util/e-text-event-processor.c