Commit Graph

31 Commits

Author SHA1 Message Date
Nathan Sobo
c7a4755808 If Workspace.open finds existing item, yield event loop
This ensures that the function always behaves asynchronously regardless
of the state of the workspace.

/cc @maxbrunsfeld

Signed-off-by: Antonio Scandurra <as-cii@github.com>
2017-03-29 09:27:21 -06:00
Nathan Sobo
45bd466384 Don’t add item in Workspace.open if activateItem is false
We thought it was a bug that activateItem: false caused the
item not to be added, but it turned out there were package
tests that depended on this behavior.

Ideally, we should have an addItem option that exhibits this
behavior instead.

Signed-off-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2017-03-28 15:00:13 -06:00
Matthew Dapena-Tretter
3b23ab44bc Add getLocation() to PaneContainer class
This allows the location to be inspected without having to jump to the
DOM and searching for a dock element.
2017-03-27 17:45:21 -07:00
Matthew Dapena-Tretter
401a549bf5 Don't open items in disallowed locations 2017-03-27 17:45:21 -07:00
Max Brunsfeld
bc872143cc Avoid duplicate search for pane container in Workspace.open 2017-03-24 15:49:35 -07:00
Max Brunsfeld
4082b67fb0 Refactor Workspace.open
Signed-off-by: Nathan Sobo <nathan@github.com>
2017-03-24 15:35:52 -07:00
Matthew Dapena-Tretter
52606171bf Add "location" param to open() 2017-03-23 18:50:40 -07:00
Matthew Dapena-Tretter
d9e1fcc70b Merge branch 'master' into HEAD
* master: (43 commits)
  If one arch fails, kill the other for perf on appveyor
  ⬆️ dalek@0.2.1
  Revert "⬆️ all packages that use atom-select-list"
  ⬆️ atom-keymap
  ⬆️ status-bar
  ⬆️ all packages that use atom-select-list
  ⬆️ language-ruby@0.71.0
  ⬆️ autocomplete-css@0.16.1
  Ensure `packagesCache` exists before accessing it
  🎨
  ⬆️ less-cache
  Use `core/` instead of `<embedded>` for keymaps loaded during snapshot
  Set also defaultSettings.core.projectHome when initializing Config
  Fix tests
  ⬆️ atom-keymap
  Replace CommandRegistry.addBundled with a boolean param in .add
  Delete unused build scripts
  🔥 Remove parserlib
  Resolve style sheets paths during `script/build` for bundled packages
  Don't use cached less sources and imported files in dev mode
  ...
2017-03-23 18:47:46 -07:00
Matthew Dapena-Tretter
77ea97e623 Use async/await in openItem() 2017-03-23 11:43:06 -07:00
Matthew Dapena-Tretter
3e826591fd Clean up storage of most recent location 2017-03-23 11:28:40 -07:00
Matthew Dapena-Tretter
d307c791c4 Be consistent about what "location" refers to 2017-03-23 11:24:37 -07:00
Matthew Dapena-Tretter
3fcec8b8cd previousLocations -> itemLocationStore 2017-03-23 10:39:02 -07:00
Matthew Dapena-Tretter
98e7fcc505 Prefer getElement() to view registry for Docks, PaneContainer & Pane 2017-03-20 22:39:23 -07:00
Matthew Dapena-Tretter
d854a88dbb Add workspace.toggle() method 2017-03-18 15:32:01 -07:00
Matthew Dapena-Tretter
5c7bd66896 Remember previous item locations 2017-03-18 15:32:01 -07:00
Matthew Dapena-Tretter
64e290b57f Make open() location aware 2017-03-18 15:32:01 -07:00
Matthew Dapena-Tretter
238ce1d8cd Make workspace inspection methods location-aware 2017-03-18 15:32:00 -07:00
Matthew Dapena-Tretter
a6424a795e Separate searching panes from creation 2017-03-18 15:32:00 -07:00
Matthew Dapena-Tretter
3ff830102f Serialize docks 2017-03-18 15:31:57 -07:00
Matthew Dapena-Tretter
bf39947eee Add Dock component 2017-03-18 15:31:51 -07:00
Antonio Scandurra
934c377af6 Fix tests 2017-03-17 17:04:11 +01:00
Matthew Dapena-Tretter
7f5ad9a359 Add workspace center 2017-03-16 14:45:09 -07:00
Antonio Scandurra
81af989f0d Merge branch 'master' into as-snapshot-atom-environment 2017-03-16 21:08:41 +01:00
Dirk Thomas
865294f3c8 pass through line count options 2017-03-10 10:37:50 -08:00
Antonio Scandurra
c4d0944c0d Snapshot more objects 2017-03-10 16:49:53 +01:00
Matthew Dapena-Tretter
e85ed1dc7f Refactor open; separate creation and placement of items
This is a refactoring that sets up the work for #13878 (docks).

Because items will be able to dictate their preferred locations, we
need to detangle the item creation from their placement.
2017-03-09 23:29:51 -08:00
Matthew Dapena-Tretter
4b3e2ccca4 Remove the buildTextEditor binding
The comment was actually no longer accurate since arrow functions
aren't newable. After doing an audit, @maxbrunsfeld determined that it
could just be removed.
2017-03-09 15:14:06 -08:00
Max Brunsfeld
3c06381018 Fix usage of dynamic arguments variable in an arrow function 2017-03-03 12:00:45 -08:00
Matthew Dapena-Tretter
53ec839ae5 Convert workspace to JavaScript: cleanup 2017-03-02 18:11:22 -08:00
Matthew Dapena-Tretter
7a0d7f8b4c Convert workspace to JavaScript: lint 2017-03-02 18:01:40 -08:00
Matthew Dapena-Tretter
cb71ce64ae Convert workspace to JavaScript: decaffeinate 2017-03-02 18:01:40 -08:00