Cheng Zhao
059d97e1aa
Merge pull request #4181 from bengotow/scroll-touch-events
...
Extend NativeWindow to track touch-based scroll events on OS X
2016-01-25 14:47:54 +08:00
Cheng Zhao
5372b6cd91
Fullscreenable => FullScreenable
2016-01-24 14:31:36 +08:00
Cheng Zhao
31624995bc
Merge pull request #4202 from evgenyzinoviev/shadow-pr
...
Added hasShadow option to BrowserWindow on OS X
2016-01-22 23:56:38 -08:00
evgenyzinoviev
ff41b4a267
added hasShadow option to BrowserWindow (osx)
2016-01-23 01:16:08 +01:00
evgenyzinoviev
ef51e4e108
maximizable and fullscreenable
2016-01-22 23:21:46 +01:00
Ben Gotow
d492ff45d5
Rename up/down => begin/end
2016-01-21 16:31:09 -08:00
Ben Gotow
bd2252ea55
Extend NativeWindow to track touch-based scroll events on OS X
...
In N1, we want to implement the famous "swipe to archive" action on threads in the user's inbox. Chrome exposes `scroll` and `wheel` events, but these aren't sufficient to implement the interaction because the element needs to "snap" when the user lifts their fingers from the trackpad, not when they / we stop receiving `wheel` / `scroll` events. These events may stop before the user lifts their fingers, or continue after the user has lifted their fingers if they had enough momentum for the gesture to continue.
This exposes BrowserWindow `scroll-touch-down` and `scroll-touch-up`, which fire immeditaely when the user touches two fingers to the trackpad, and again when the user lifts their fingers. Combined with the existing wheel event should allow for "swipe-to-archive" and other similar interactions.
Note: This is only implemented on Mac OS X and the events don't fire unless you're using a trackpad!
Related: #1486 , #2683 , https://github.com/nylas/N1/issues/541
2016-01-21 09:40:21 -08:00
evgenyzinoviev
2a554cb138
added or/and improved closable, minimizable, movable, resizable features for windows on os x and windows
2016-01-19 16:14:57 +01:00
evgenyzinoviev
b75dccb0be
arguments handing rewritten, doc updated
2016-01-15 17:31:31 +01:00
evgenyzinoviev
2598b00b41
Animate window resizing on OS X
2016-01-15 05:59:58 +01:00
Cheng Zhao
1944472c2f
docs: Make win.getNativeWindowHandle more clear
2016-01-11 13:43:24 +08:00
Omri Litov
943e46f3bd
Fix linux and mac build errors
2016-01-08 00:27:53 +02:00
Omri Litov
3f0c007578
Added getNativeWindowHandle
2016-01-07 22:38:35 +02:00
Cheng Zhao
14db4a1946
Add isDevToolsFocused to webview
2016-01-04 10:46:30 +08:00
billyct
5f092a6c65
support an api with SetIgnoreMouseEvents, and worked fine with osx
2015-12-06 10:14:54 +08:00
Cheng Zhao
973ae06f21
Destroy the native window in next tick
...
It fixes a possible crash when native code is iterating all windows
while the JavaScript code decides to destroy a window.
2015-12-04 11:35:04 +08:00
Cheng Zhao
6795bd1d96
Do not manually manage native resources
...
We should rely on the destructor to cleanup everything, instead of
putting them in the Destroy method.
2015-12-03 15:38:43 +08:00
Cheng Zhao
8d20dda6d7
No need to override TitleWasSet in NativeWindow
2015-12-01 17:51:09 +08:00
Eran Tiktin
18de28c3ff
Make BrowserWindow options argument optional
...
Resolves #3473
2015-11-21 06:22:19 +02:00
Cheng Zhao
9a20b33d97
Add isDestroyed method for classes with destroy method
2015-11-19 17:08:16 +08:00
Cheng Zhao
860c46b3c1
Separate options from switches
...
On Windows the case sensitivity of command line switches are ignored, so
--nodeIntegraion will become --nodeintegration.
We should separate options from switches so we use "nodeIntegraion" in
options, while passing "--node-integration" in command line.
2015-11-13 14:05:49 +08:00
Cheng Zhao
960d325a58
Be compatible with old BrowserWindow options
2015-11-11 10:37:34 +08:00
Cheng Zhao
d37aa8bed9
Reorder switches
2015-11-11 10:37:34 +08:00
Cheng Zhao
917b33dbe7
Small code cleanup
2015-10-29 10:55:08 +08:00
Omri Litov
ef038257d1
Returns buffer instead of WPARAM and LPARAM
2015-10-29 03:00:44 +02:00
Omri Litov
f22837523f
Use WPARAM as uint64_t and LPARAM as int64_t
2015-10-28 21:54:50 +02:00
Cheng Zhao
b86267aa3b
Use uint64_t instead of LPARAM
...
LPARAM is defined to differnt types on differnt machines with different
SDKs, so there is no way to represent it on all platforms safely, using
uint64_t seems to be the only safe choice.
2015-10-28 19:51:24 +08:00
Cheng Zhao
5fd310c75f
Add converter for LPARAM
2015-10-28 19:43:05 +08:00
Omri Litov
e355532d27
Change windows messages api to hook instead of emitter
2015-10-27 14:00:08 +02:00
Omri Litov
edbebf84b9
Added browser-window event 'message'
2015-10-27 03:12:01 +02:00
Cheng Zhao
e36d455d51
Add setBackgroundColor method
2015-10-23 11:35:33 +08:00
Cheng Zhao
f2c7943d42
Add WebContents.getOwnerBrowserWindow
2015-10-01 13:45:59 +08:00
Cheng Zhao
83c514001e
Move devtools API to WebContents
2015-10-01 11:25:31 +08:00
Cheng Zhao
de41890196
Inherit parent window's options in window.open
2015-09-22 22:32:10 +08:00
Cheng Zhao
86f523d3c1
Move BeginFrameSubscription to WebContents
2015-09-18 15:57:43 +08:00
Cheng Zhao
42863e4700
Move SendInputEvent to WebContents
2015-09-18 14:20:31 +08:00
Cheng Zhao
9e7de78231
Fix cpplint warnings
2015-09-18 14:12:48 +08:00
Cheng Zhao
c550546ff1
Do not manually convert Object to WebInputEvent
2015-09-18 14:09:31 +08:00
Cheng Zhao
ec90d03d74
Fix compilation error
2015-09-18 12:10:00 +08:00
Cheng Zhao
ee0d48dc5a
Merge branch 'master' of https://github.com/MaxWhere/electron into MaxWhere-master
2015-09-18 12:01:33 +08:00
Cheng Zhao
e73c655d65
No need to delete window in Destory
...
The native window is now automatically deleted after it gets closed.
2015-09-17 11:32:19 +08:00
Cheng Zhao
e3c64d7971
Release the native window after window gets closed
...
Previously we delete the window after the JS object gets garbage
collected, which is too late for releasing some resources.
2015-09-17 11:30:17 +08:00
Heilig Benedek
ceef06b344
Renamed setOffscreenRender to begin/endFrameSubscription because the name was a bit misleading, and replaced the ArrayBuffer creation with a node::Buffer::New call.
2015-09-16 02:59:16 +02:00
Cheng Zhao
b72a5884f2
Add BrowserWindow.isDevToolsFocused
2015-09-15 11:43:45 +08:00
Cheng Zhao
238d4add99
devtools-opened should be emitted after devtools is opened
2015-09-15 09:18:22 +08:00
Heilig Benedek
b2af370249
Changed StringArray options to regular js objects with boolean values for better readability from the js side
2015-09-10 02:10:47 +02:00
Cheng Zhao
446235c8cd
Fix backward compatibility with old BrowserWindow options
2015-09-09 15:55:26 +08:00
Cheng Zhao
46b2b91a27
Don't use Node's internal APIs
2015-09-07 16:41:49 +08:00
Cheng Zhao
e2bd1abce6
Make sure BrowserContext is destroyed on exit
2015-09-06 10:54:34 +08:00
Cheng Zhao
0b97d58a6f
Move a few options in NativeWindow to web-preferences
2015-09-06 10:53:03 +08:00