Commit Graph

2660 Commits

Author SHA1 Message Date
Kevin Sawicki
d2bd937f36 Store packages in hash instead of array
This allows quick lookup by name without having to
memoize the resolved path.
2013-05-22 15:29:35 -07:00
Kevin Sawicki
ff1f9b98d2 Use path.basename() instead of fsUtils.base() 2013-05-22 15:29:35 -07:00
Kevin Sawicki
0c85b40789 Add initial support for installing and uninstalling 2013-05-22 15:29:35 -07:00
Kevin Sawicki
fb712cf9c1 Add asserts for homepage and issue links 2013-05-22 15:29:35 -07:00
Kevin Sawicki
061b285aeb Use simpler internal tag 2013-05-22 15:29:35 -07:00
Kevin Sawicki
9841df732f Remove unused method 2013-05-22 15:29:35 -07:00
Kevin Sawicki
9f94d1b6b4 Add initial spec for available packages 2013-05-22 15:29:35 -07:00
Kevin Sawicki
7c04662d7d Remove logging statement 2013-05-22 15:29:34 -07:00
Kevin Sawicki
4746ac82c3 Show counts in nav area badge 2013-05-22 15:29:34 -07:00
Kevin Sawicki
a223439eb8 Combine package configs into single panel 2013-05-22 15:29:34 -07:00
Kevin Sawicki
6e50b5c005 Mark class as internal 2013-05-22 15:29:34 -07:00
Kevin Sawicki
213524e893 Show upgrade as default action when newer version exists 2013-05-22 15:29:34 -07:00
Kevin Sawicki
be020fad39 💄 2013-05-22 15:29:34 -07:00
Kevin Sawicki
2308533235 Add issue link to dropdown 2013-05-22 15:29:34 -07:00
Kevin Sawicki
009b50557c Add homepage link to dropdown 2013-05-22 15:29:34 -07:00
Kevin Sawicki
8668dd67ac Add README to package section 2013-05-22 15:29:34 -07:00
Kevin Sawicki
e7df1f1f3d Use a dropdown button for package actions 2013-05-22 15:29:34 -07:00
Kevin Sawicki
6b81eebb02 Add initial available packages view 2013-05-22 15:29:34 -07:00
Kevin Sawicki
d3cbd937fb Clip buffer position in screenPositionForBufferPosition()
Closes #562
2013-05-22 15:25:27 -07:00
probablycorey
0901e1a34c Allow spec window to store window state
It just stores window dimensions for now.
2013-05-22 11:56:33 -07:00
Garen Torikian
f49ec5fac8 Explicitly require nak's bin executable 2013-05-22 10:05:50 -07:00
Garen Torikian
ab466b60c8 command in project.scan needs to resolve to the bin, not the lib file
This is because nak was changed to also be run as a regular Node script, not just an executable
2013-05-22 09:29:37 -07:00
Cheng Zhao
61f8878e05 Merge branch 'master' into atom-shell
Conflicts:
	package.json
	script/bootstrap
	spec/app/window-spec.coffee
	src/app/window.coffee
2013-05-22 20:52:42 +08:00
Kevin Sawicki
42e1595bd7 💄 2013-05-21 18:49:27 -07:00
Kevin Sawicki
e7c08d1202 Exclude core.ignoredNames when scanning project 2013-05-21 18:46:03 -07:00
probablycorey
b58fcc5395 Specs run (but fail hardcore) 2013-05-21 17:04:00 -07:00
probablycorey
d4b146d080 Serialize window dimensions 2013-05-21 14:33:45 -07:00
probablycorey
f65fbdf7ae Don't show window until it is finished loading 2013-05-21 14:32:12 -07:00
probablycorey
f23cb1aa79 Window state works now
The state is now stored in ~/.atom/.storage/SHA-OF-PATH. It is written
to every time it is set.
2013-05-21 14:12:15 -07:00
probablycorey
26094a5405 Use executedFrom command line option to resolve paths 2013-05-20 16:02:06 -07:00
Cheng Zhao
4faf48233b 💄 2013-05-20 22:36:49 +08:00
Cheng Zhao
bf6e0752f8 Remove atom.presentModal and its helper methods.
Since all the dialogs are modal and blocking now, there is no need to
keep the atom.presentModal which is used to emulate the blocking
behavior.
2013-05-20 22:25:57 +08:00
Cheng Zhao
6e012ed24f Adopt to new open/save dialog API. 2013-05-20 22:23:27 +08:00
Cheng Zhao
60fcb97a3e Send window commands instead of invoking window APIs directly.
For some events generated on the browser side, like reloading, closing
window, we should not handle those events directly, instead we should
send the corresponding commands to the renderer and let the renderer
deal with it.

The window.reload() is also moved to atom.reload(), because I saw things
like toggleFullScreen(), focus(), toggleDevTools() are also there.
2013-05-20 14:19:12 +08:00
Cheng Zhao
0ad96ca7da Make a few window related atom.* functions work. 2013-05-20 11:55:27 +08:00
Cheng Zhao
8be54136ed Use "shell.openExternal(url)" to open links in external browsers. 2013-05-20 10:12:40 +08:00
Cheng Zhao
1301eb0fa4 Use atom-shell's API for pasteboard operations. 2013-05-20 09:43:19 +08:00
Cheng Zhao
c8891c1008 Adopt to API change of dialog.showMessageBox. 2013-05-18 12:21:25 +08:00
Cheng Zhao
6260d350ac Should always show devtools instead of toggling when getting error. 2013-05-17 23:07:34 +08:00
Cheng Zhao
26c89f71b2 Use BrowserWindow's 'close' event instead of 'beforeunload' to control closing.
Ideally both window closing and reloading should use 'beforeunload' to
control whether the unloading should continue, however since the save as
dialog is asynchronous, we have to prevent unloading first and then
continue after user's confirmation. And since we can not distinguish
whether the window is reloading or closing in the 'beforeunload'
handler, we do not know what to continue after user's confirmation. So I
have to rely on BrowserWindow's 'close' event to let user decide whether
window should be closed.
2013-05-17 22:30:14 +08:00
Cheng Zhao
b27cd33116 Implement atom.confirm with atom-shell's dialog API.
Note that the dialog.showMessageBox is blocking, so we don't need to use
the '@presentModal'.
2013-05-17 20:39:37 +08:00
Cheng Zhao
f0448ba231 Trigger 'window:close' command in the 'beforeunload' event handler.
When user wants to close the window, the 'beforeunload' event would be
called, then the closing would be cancelled and the 'window:close'
command would be triggered. In the 'window:close' handler, a confirm
dialog could be showed if there are unsaved contents, and if the window
is really meant to be closed, the window would be tried to be closed
again and this time 'beforeunload' handler wont't prevent it.
2013-05-17 20:17:06 +08:00
Cheng Zhao
acf5e21f50 Do unload work in 'unload' event handler instead of 'beforeunload'.
In Atom, the 'beforeunload' event never prevents window from closing so
it in fact has the same effect with 'unload' event, I guess using
'beforeunload' instead of 'unload' is because the 'beforeunload' is
guarrenteed to happen when window is closing or application is quiting.
However in Atom Shell the 'unload' event is guarrenteed to happen on
both conditions, just like the 'beforeunload' in Atom, so it's safe to
replace the 'beforeunload' with 'unload' here.

And in Atom Shell, the 'beforeunload' event is mainly used for
preventing window from closing, just like the 'window:close' command in
Atom.
2013-05-17 20:17:03 +08:00
Cheng Zhao
d1ca0a8f8f Use toggleDevTools instead of showDevTools. Fixes atom/atom-shell#8.
Currently the toggleDevTools of atom-shell is simulated by keeping state
of devtools, because there is no way to know the state of devtools in
brightray, so it could not behave correctly sometimes.

This problem will be solved when brightray is patched and atom-shel gets
updated.
2013-05-17 19:02:03 +08:00
Cheng Zhao
e7b35d27e7 Revert ae7dce4575.
Now require('package') won't wrong resolve to the package.json, so
reverting previous workaround.
2013-05-17 18:48:02 +08:00
Kevin Sawicki
84753e55a7 Add enable/disable helpers to jquery extensions 2013-05-16 17:29:48 -07:00
probablycorey
8f17889f7f Open dialog creates new atom window 2013-05-16 16:38:47 -07:00
Kevin Sawicki
392ffce8c7 Remove unused requires 2013-05-16 15:54:10 -07:00
Kevin Sawicki
d7a238b5ec Guard against possibly null event handler 2013-05-16 15:49:53 -07:00
probablycorey
92ec78cd8a Show dev tools when toggleDevTools is triggered
Eventually want make toggle work as expected. Related to https://github.com/atom/atom-shell/issues/8
2013-05-16 15:14:50 -07:00