Commit Graph

108 Commits

Author SHA1 Message Date
Max Brunsfeld
cca04f85a3 📝 Document async onWillDestroyItem behavior 2017-09-12 15:19:46 -07:00
Will Binns-Smith
128f702784 Add documentation to addModalPanel api 2017-08-22 23:14:54 -07:00
Wliu
8963cf4955 Only use multiline if the flag is passed in 2017-08-10 13:24:46 -04:00
Wliu
2fa2feacaf Multiline is important, don't forget to set it 2017-08-09 22:52:39 -04:00
Wliu
b6fb15fce3 📝
[ci skip]
2017-07-19 16:21:56 -04:00
Antonio Scandurra
62ee913567 Ensure custom title bar is always updated when document.title changes
This commit uses a new private API on Workspace that emits an event
every time the window title gets updated (e.g. as a result of an active
pane item changing, the project paths changing, etc.).

This fixes a bug that left the custom title bar with a stale
document.title under some circumstances.

Signed-off-by: Jason Rudolph <jasonrudolph@github.com>
2017-06-26 16:29:31 +02:00
Max Brunsfeld
c1c0e7e921 Merge pull request #14736 from atom/fb-mdt-observe-dock-visibility
Add methods for observing dock visibility
2017-06-22 14:11:52 -07:00
Max Brunsfeld
2420d12e44 Merge pull request #14435 from atom/mb-use-native-text-buffer
Use new native text-buffer implementation
2017-06-08 16:50:53 -07:00
Jason Rudolph
5d7e9a622f Merge pull request #14640 from atom/jr-directional-pane-navigation-for-entire-workspace
Teach directional pane navigation commands to support docks
2017-06-08 19:15:33 -04:00
Matthew Dapena-Tretter
ca6254dd66 Add methods for observing dock visibility 2017-06-07 16:24:28 -07:00
Wliu
7c48291333 🔥 getPaneContainers from the API 2017-06-07 10:55:26 -04:00
Wliu
55a0fcb3f2 📝 Document pane location methods in Workspace 2017-06-06 23:33:46 -04:00
Max Brunsfeld
3b56ef8cbf Merge remote-tracking branch 'origin/master' into mb-use-native-text-buffer 2017-06-06 17:12:34 -07:00
Jason Rudolph
e1719a8923 Teach Workspace::reset() to properly reset hasActiveTextEditor 2017-06-02 15:56:13 -04:00
Jason Rudolph
2347c9bdaa Always invoke callback with current active text editor
This makes observeActiveTextEditor consistent with observers like
observeActivePaneItem, which always invoke the callback with the current
value, regardless of whether that value is undefined or not.
2017-06-02 15:55:00 -04:00
Jason Rudolph
9629caefb7 Remove unnecessary serialization 2017-06-02 15:09:20 -04:00
Jason Rudolph
5b61c0a949 🐛 Initialize active editor state correctly after reload
Fixes the following bug:

1. Open Atom
2. Open a file
3. Observe the file's encoding in the status bar
4. Reload Atom
5. Close the file
6. Observe that the closed file's encoding is still present in the
status bar

This bug occured because the reload did not deserialize/serialze the
workspace's active text editor state. As a result, when closing the
text editor in step 5, we failed to notify observers that there is no
longer an active text editor.
2017-06-02 08:01:42 -04:00
Jason Rudolph
5dfbb65b0e 🎨 Reduce ternaries 2017-06-01 17:09:38 -04:00
Jason Rudolph
6a694f80f4 🎨 Replace instanceof check with nullness check
xref: https://github.com/atom/atom/pull/14695#discussion_r119721719
2017-06-01 17:04:43 -04:00
Jason Rudolph
fe550a1b03 🎨 Refactor: Introduce explaining variable
xref: https://github.com/atom/atom/pull/14695#discussion_r119721719
2017-06-01 17:04:17 -04:00
Jason Rudolph
14d8eccc6e 📝 Add API docs for observeActiveTextEditor(callback) 2017-06-01 15:47:31 -04:00
Jason Rudolph
5b52d8c77a 📝 Add API docs for onDidChangeActiveTextEditor(callback) 2017-06-01 15:44:37 -04:00
Max Brunsfeld
dc320181fc Fix handling of .save and .saveAs rejections
* Make Pane.close, Pane.saveActiveItem, and Pane.saveActiveItemAs async.
* Refactor the logic for prompting to save on window unload
2017-05-31 17:46:04 -07:00
Jason Rudolph
05efc143ed Add Workspace::observeActiveTextEditor() 2017-05-31 16:17:54 -04:00
Jason Rudolph
cf50625cc6 Teach Workspace::getActiveTextEditor() to get item from center 2017-05-31 14:32:20 -04:00
Jason Rudolph
cd24e820f5 💚 Fix linter failure 2017-05-31 13:13:09 -04:00
Jason Rudolph
8cae9a1365 🎨 Refactor: Extract getVisiblePanes() function 2017-05-31 12:01:10 -04:00
Jason Rudolph
0e3dfc3ba1 🎨 Refactor: Extract getVisiblePaneContainers() function 2017-05-31 11:57:57 -04:00
Max Brunsfeld
6c0b70f5f3 Start work on integrating new native TextBuffer version 2017-05-19 11:33:49 -07:00
Max Brunsfeld
07c2a8e8d6 Merge pull request #14339 from atom/mb-dont-change-focus-when-hiding-unfocused-dock
Don't change focus when hiding an unfocused dock
2017-05-11 16:28:27 -07:00
Nathan Sobo
66609a1414 Act on active center items only when saving and closing
Signed-off-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2017-05-10 13:21:50 -06:00
Max Brunsfeld
2f336a64d3 Check dock focus using the DOM, not the active pane container state 2017-05-02 13:30:36 -07:00
Max Brunsfeld
a61accf175 Don't change focus when hiding an unfocused dock 2017-05-02 10:34:14 -07:00
Max Brunsfeld
0015e026a2 Add Workspace.paneContainerForItem method 2017-04-17 11:34:45 -07:00
Matthew Dapena-Tretter
abd8f2c0b7 🐛 Fix URI resolution in openSync()
@Alhadis noticed I missed this in 53ec839.
2017-04-13 23:44:47 -07:00
Max Brunsfeld
82a7a6c78a Always search a pane container w/ the given URI in workspace.open 2017-04-12 10:23:49 -07:00
Nathan Sobo
e0309883bb Merge pull request #14137 from atom/ns-mb-document-workspace-item-interface
Document pane item interface on Workspace
2017-04-11 20:20:00 -06:00
Nathan Sobo
1641d9bb7d Merge pull request #14174 from atom/ns-as-avoid-deserialization-error
Avoid errors deserializing 1.17 workspace state in prior Atom versions
2017-04-11 11:10:50 -06:00
Nathan Sobo
879f6bf454 Avoid errors deserializing 1.17 workspace state in prior Atom versions 2017-04-11 10:04:52 -06:00
Max Brunsfeld
c43bfafdfb Move hoveredDock property from Workspace to WorkspaceElement
It's not used in Workspace anymore.
2017-04-10 14:18:58 -07:00
Max Brunsfeld
399b70662d Fix regression in hovered dock tracking due to workspace refactor
Also, backfill tests for showing, hiding and updating the dock toggle
buttons in response to mouse movements.
2017-04-10 14:15:31 -07:00
Max Brunsfeld
48336fb95e Don't use workspace's itemLocationStore in tests 2017-04-07 15:30:44 -07:00
Max Brunsfeld
63d27c5f0a Rename Dock.isOpen to .isVisible and Dock.open to .show 2017-04-06 17:23:53 -07:00
Max Brunsfeld
b5a449ba39 Fix lint errors 2017-04-06 16:44:44 -07:00
Matthew Dapena-Tretter
6efe462378 Remove unused require 2017-04-06 17:27:17 -06:00
Matthew Dapena-Tretter
d133b03d7d Remove saveFocusedPaneItem(As) methods
Now that dock pane items will be capable of being the workspace's
active item, there's no need to have these methods.
2017-04-06 17:26:35 -06:00
Nathan Sobo
40b9fd9f5d Deprecate atom.workspace.paneContainer 2017-04-06 17:24:03 -06:00
Nathan Sobo
497eba7d24 Store center and docks in Worskpace.paneContainers sub-object 2017-04-06 17:17:05 -06:00
Nathan Sobo
52d8cbfb0e Handle (de)serialization in WorkspaceCenter 2017-04-06 17:07:20 -06:00
Nathan Sobo
f808411c96 Destroy WorkspaceCenter and Docks instead of PaneContainer 2017-04-06 16:58:33 -06:00