Cheng Zhao
d6103dd639
Expose Menu API in javascript.
2013-05-14 19:24:52 +08:00
Cheng Zhao
13c0a05fdd
Add popup method for Menu.
2013-05-14 16:50:56 +08:00
Cheng Zhao
667384ef74
Use Atom's icon.
2013-05-14 15:50:33 +08:00
Cheng Zhao
a7052292e6
Update node: add Atom.app/Contents/Resources/app to module paths.
2013-05-13 18:45:17 +08:00
Cheng Zhao
de8d713630
It seems that shutil.make_archive doesn't support symbol links, invoke the zip command instead.
2013-05-13 16:22:21 +08:00
Cheng Zhao
836f29add6
When copying bundle the symbol links should be kept.
2013-05-13 15:27:49 +08:00
Cheng Zhao
fc4dd0aecb
Save the latest version when uploading distribution.
2013-05-12 17:44:03 +08:00
Cheng Zhao
1a2637e2cc
Update node: cleanup unused hacks.
2013-05-12 16:18:12 +08:00
Cheng Zhao
e065067d6d
Add script to download atom-shell.
...
The scripts are stolen from aroben/libchromiumcontent.
2013-05-12 16:16:52 +08:00
Cheng Zhao
3290c05e75
Add script to make distribution and upload.
...
The scripts are stolen from aroben/libchromiumcontent.
2013-05-12 16:16:02 +08:00
Cheng Zhao
ebac5f9ed5
Ship the custom node binary build with atom-shell.
...
This is required by the child_process.fork, which is indeed executing
the node binary to start a script.
The node fork can be found at:
https://github.com/atom/cefode-node/tree/chromium-v8
2013-05-11 21:07:03 +08:00
Cheng Zhao
85e22c0709
Expose dialog.showMessageBox API.
2013-05-10 21:19:13 +08:00
Cheng Zhao
a5459da717
💄
2013-05-10 20:54:55 +08:00
Cheng Zhao
34e9132b68
Modify Window API to be more consistent.
...
* '_' becomes '-'
* removes 'position' field
* adds 'center' method.
2013-05-10 20:34:05 +08:00
Cheng Zhao
e6a9add691
Rename atom module to atom_delegate to avoid conflicts with Atom.
2013-05-07 20:33:50 +08:00
Cheng Zhao
1900ad4cb9
Make sure the 'closed' event is emitted before 'window-all-closed'.
2013-05-07 16:20:52 +08:00
Cheng Zhao
ed576dcc68
Update to lastest brightray.
2013-05-07 12:06:54 +08:00
Cheng Zhao
ffc0d4f516
Fix whitespace/line_length warnings of cpplint.
2013-05-07 11:43:21 +08:00
Cheng Zhao
dae98fa43f
Expose MenuModel's methods in js.
2013-05-07 00:03:34 +08:00
Cheng Zhao
7cc04035c4
Add Menu API. (WIP)
2013-05-06 20:27:09 +08:00
Cheng Zhao
5915591592
Pass the native window object directly in native dialog API.
2013-05-05 20:36:46 +08:00
Cheng Zhao
67f998357c
Make the CallbacksRegistry a separate module, though rather small.
2013-05-05 20:30:38 +08:00
Cheng Zhao
f725927c44
Use cross-platform callbacks in the dialog API.
2013-05-05 20:24:20 +08:00
Cheng Zhao
d377cbfa74
Don't send ATOM_BROWSER_DEREFERENCE message if context is already gone.
...
It's possible that the object gets destructed after reloading, however
since we already released all objects in browser when unloading, it
would cause troubles when sending message in an unexist context. We just
rely on the closure to mark whether the context is gone.
A more suitable solution, however, is to restart renderer process when
doing reloading.
2013-05-04 23:00:57 +08:00
Cheng Zhao
35441ad8fb
The unwrapArgs relies on the valueToMeta function.
2013-05-04 22:59:32 +08:00
Cheng Zhao
e7547363e2
Check whether id is valid when adding to weak map.
...
It's possible that the object has been added to weak map before and then
erased, so having an id property doesn't mean it's added in the weak map.
2013-05-04 22:57:17 +08:00
Cheng Zhao
84dc221b2e
Clear listeners on process object when unloading.
...
The process object is created under node context, and it will live
through the reloading, so we are responsible for clearing the listeners
to make sure resources are not leaked.
2013-05-04 21:52:14 +08:00
Cheng Zhao
6bf0d5d798
Modify funtion's names to make RPC code more easy to understand.
2013-05-04 21:38:25 +08:00
Cheng Zhao
36c260f4d5
Resupport cross-process callback.
...
It seems that it's avoidable to make callback cross-process when we
start to emitting events for GUI elements, without this feature our
implementation will be much more complicated. I will find a way to warn
about resources leak in browser.
2013-05-04 17:01:28 +08:00
Cheng Zhao
188bb5e225
Pass remote objects from renderer to browser by ID.
2013-05-03 21:51:06 +08:00
Cheng Zhao
73d4b01597
Cache remote.getCurrentWindow.
2013-05-03 21:14:28 +08:00
Cheng Zhao
ec43f740a7
Add the generialized showMessageBox API.
2013-05-03 21:03:26 +08:00
Cheng Zhao
4aeb5e1388
Add dialog API.
...
Supported APIs:
* openFile
* openMultiFiles
* openFolder
* saveAs
Each API is asynchronous and accepts a callback.
2013-05-03 19:31:24 +08:00
Cheng Zhao
42f10a15d5
URL => Url, ID => Id in coffee script.
2013-05-03 15:36:25 +08:00
Cheng Zhao
9b75019898
Add 'quit' and 'window-all-closed' events for app module.
2013-05-03 10:53:54 +08:00
Cheng Zhao
66404b5f15
Add the 'app' built-in module.
2013-05-03 00:05:09 +08:00
Cheng Zhao
d151d494bd
Add Browser class to controll when the application should quit.
2013-05-02 23:43:23 +08:00
Cheng Zhao
8cf1050730
Add _mac suffix for obj-c files.
2013-05-02 23:03:14 +08:00
Cheng Zhao
264f085afb
Add WindowList class to manage all windows.
2013-05-02 22:54:09 +08:00
Cheng Zhao
43d42ca57f
Quiting the application is now equivalent to close all windows.
2013-05-02 20:09:19 +08:00
Cheng Zhao
e7aab096e7
Make sure WindowClosed message is sent when window is destroyed.
2013-05-02 20:08:23 +08:00
Cheng Zhao
21df63fc9b
Add 'closed' and 'destroyed' event for Window.
2013-05-02 18:19:07 +08:00
Cheng Zhao
afe07521c5
Correctly handle window's lifetime when it's closed.
2013-05-01 23:28:01 +08:00
Cheng Zhao
9e489cae0c
Add window closing related methods for window observer.
2013-05-01 16:33:19 +08:00
Cheng Zhao
edd8410c24
Simply the closing model.
2013-05-01 16:12:00 +08:00
Cheng Zhao
9f1fe4d2c2
Closing a window requires closing web contents now.
...
In this way, we can prevent the close of window by using beforeunload
handler.
2013-05-01 15:42:30 +08:00
Cheng Zhao
31d6be0e63
Release resources in browser when renderer view is gonna unloaded.
2013-05-01 10:59:29 +08:00
Cheng Zhao
a674572dd4
Implement beforeunload event.
...
Unlike normal browser which would show a dialog to choose whether to
continue, you can just return a empty string in the handler to prevent
unloading.
2013-05-01 00:05:19 +08:00
Cheng Zhao
bcf6cd9f1b
Drop support for cross-process callbacks.
...
Now it's forbidden for browser to store reference to objects (including
functions) in renderer, because when the renderer is destroyed, it's
extremely hard to clean all of corresponding objects in browser
correctly, which would cause very bad resources leak.
2013-04-30 22:37:54 +08:00
Cheng Zhao
74c519ac3f
Enable getting window from routing id and process id.
2013-04-30 20:32:23 +08:00