Mailspring/spec
Ben Gotow 4f34c8403f feat(trash): Trash for Gmail, and architectural changes for common tasks
Summary:
This diff centralizes logic for creating common tasks for things like moving to trash, archive, etc. TaskFactory exposes a set of convenience methods and hides the whole "and also remove the current label" business from the user.

This diff also formally separates the concept of "moving to trash" and "archiving" so that "remove" isn't used in an unclear way.

I also refactored where selection is managed. Previously you'd fire some action like archiveSelection and it'd clear the selection, but if you selected some items and used another method to archive a few, they were still selected. The selection is now bound to the ModelView as intended, so if items are removed from the modelView, they are removed from it's attached selection. This means that it shouldn't /technically/ be possible to have selected items which are not in view.

I haven't refactored the tests yet. They are likely broken...

Fix next/prev logic

Test Plan: Run tests

Reviewers: evan

Reviewed By: evan

Differential Revision: https://phab.nylas.com/D2157
2015-10-21 10:38:00 -07:00
..
components refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
fixtures refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
models refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
stores fix(tasks): don't continue if dependent task fails 2015-10-21 10:33:43 -07:00
tasks feat(trash): Trash for Gmail, and architectural changes for common tasks 2015-10-21 10:38:00 -07:00
action-bridge-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
atom-reporter.coffee feat(logging): Developer bar, verbose logging to logstash, Electron 0.26.0 2015-05-19 17:02:46 -07:00
atom-spec.coffee fix(auth): Resize the auth window after an update to the token status 2015-10-06 17:58:07 -07:00
auto-update-manager-spec.coffee fix(updater): Send UUID and email accounts to enable more specific update distribution 2015-10-03 14:45:39 -07:00
buffered-process-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
clipboard-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
component-registry-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
database-object-registry-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
database-view-spec.coffee feat(trash): Trash for Gmail, and architectural changes for common tasks 2015-10-21 10:38:00 -07:00
dom-utils-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
jasmine-helper.coffee refactor(dir): move exports to src/global and consolidate tests 2015-10-02 09:19:37 -07:00
jasmine-jquery.js refactor(dir): move exports to src/global and consolidate tests 2015-10-02 09:19:37 -07:00
jasmine.js refactor(dir): move exports to src/global and consolidate tests 2015-10-02 09:19:37 -07:00
launch-services-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
menu-manager-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
model-view-selection-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
model-view-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
module-cache-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
nylas-api-spec.coffee fix(sync): Request all labels / folders to avoid paging and missing inbox 2015-10-03 23:53:59 -07:00
nylas-protocol-handler-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
package-manager-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
package-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
quoted-html-parser-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
quoted-plain-text-parser-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
spec-bootstrap.coffee refactor(exports): move exports to src/global 2015-10-01 21:23:37 -07:00
spec-helper-platform.coffee fix(drafts): Various improvements and fixes to drafts, draft state management 2015-02-03 16:24:31 -08:00
spec-helper.coffee refactor(dir): move exports to src/global and consolidate tests 2015-10-02 09:19:37 -07:00
spec-suite.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
style-manager-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
styles-element-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
test_utils.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
theme-manager-spec.coffee fix(specs): Fix intermittent async error and max event listener leak 2015-10-09 15:42:37 -07:00
time-reporter.coffee refactor(utils): switch to regular underscore 2015-05-19 16:06:59 -07:00
undo-manager-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00
utils-spec.coffee refactor(spec) move spec-nylas to spec 2015-10-01 21:39:44 -07:00