Commit Graph

51 Commits

Author SHA1 Message Date
Feross Aboukhadijeh
ac0504bde4 Prevent repeated setBadge IPC calls 2016-03-08 11:51:02 -08:00
DC
ff56d818f6 Torrent list styling
* Download button is a lot easier to read: white down arrow when off, animated and pulsating green down arrow when downloading, solid green up arrow when seeding

* Play button shows a spinner if you click play before a torrent is ready, then an exclamation point if the torrent still isn't ready after 10 seconds

* Drop target shows up always, not just when the torrent list is empty. Lights up when you drag something

* Fixed alignment, the Xs to delete torrents are now aligned with the + to add a new torrent
2016-03-08 04:20:37 -08:00
DC
4c03e98a19 Video controls: never hide when paused
Also simplifies CSS
2016-03-08 02:36:33 -08:00
Feross Aboukhadijeh
0cca67a436 fix fullscreen on Windows
The win.isFullScreen() state takes a second to update so we should just
pass the state manually into onToggleFullScreen().
2016-03-07 22:22:25 -08:00
Feross Aboukhadijeh
7c68be4fd4 code style 2016-03-07 22:21:01 -08:00
Feross Aboukhadijeh
8ab2a1415b update player window title to torrent name (Windows, Linux)
This also moves all the state “diffing” for purposes of updating the
app’s window via Electron APIs into one function updateElectron().
2016-03-07 22:20:39 -08:00
Feross Aboukhadijeh
5171e1a7da code style 2016-03-07 22:20:08 -08:00
DC
4b890ee9f6 Show Blender Foundation videos by default
* Finishes the saved torrents feature!
* Torrents load and save correctly. Poster is autogenerated only once.
* Torrents can be paused and restarted
* Download button indicates state:
 - White means paused
 - Pulsating green means downloading
 - Solid green means finished downloading, only seeding
2016-03-07 22:15:47 -08:00
Feross Aboukhadijeh
35ec241b01 Leave fullscreen when player closes
For #3
2016-03-07 18:39:11 -08:00
Feross Aboukhadijeh
2ea94de8c6 Show video title in app title bar 2016-03-07 15:48:22 -08:00
Feross Aboukhadijeh
2a423a8cb3 Use config.APP_NAME throughout 2016-03-07 15:48:22 -08:00
Nate Goldman
01b37e54c9 Merge pull request #71 from feross/home-dir
Cross-platform home directory detection
2016-03-07 15:29:54 -08:00
Feross Aboukhadijeh
031adeecc5 Cross-platform home directory detection
os.homedir() handles cross-platform complexities for us.
2016-03-07 15:15:34 -08:00
Nate Goldman
5f0c8e86ad improve loading experience 2016-03-07 12:42:39 -08:00
Feross Aboukhadijeh
0d18641bcb Merge pull request #59 from feross/load-state
load state first
2016-03-07 11:18:11 -08:00
Nate Goldman
de7bc442a7 fix empty infoHash issue 2016-03-07 10:51:32 -08:00
Nate Goldman
383659ad1a add downloads folder - fix #53
- fixed issue where nothing but infoHash was getting saved
- better defaults mgmt for state.saved
- no duplicates saved
2016-03-07 10:34:05 -08:00
Nate Goldman
4e07ecf05c load state first 2016-03-07 10:33:31 -08:00
Giuseppe Crinò
abb1e2bd16 Make spacebar trigger play/pause event
Step forward in closing #3
2016-03-07 19:06:02 +01:00
DC
093d810b90 Remove updateThrottled 2016-03-07 04:53:04 -08:00
DC
713c391c05 Add download button
Doesn't do anything yet
2016-03-07 00:01:32 -08:00
DC
5aa1cce09e Fix state loading and saving
This is the rest of PR #56
2016-03-06 22:29:53 -08:00
Nate Goldman
4f093497a7 fix bugs from #56 2016-03-06 22:16:12 -08:00
DC
61a99508ae Clean up and document index.js 2016-03-06 21:41:16 -08:00
Nate Goldman
96340d3255 style 2016-03-05 22:45:09 -08:00
Nate Goldman
ec56d9a642 save config on torrent.destroy 2016-03-05 22:44:53 -08:00
Nate Goldman
045f38089c add persistent app config
resolves #24
2016-03-05 22:27:47 -08:00
Feross Aboukhadijeh
f161a7c7e7 no need to account for header in aspect ratio
Since the header floats on top of the video now
2016-03-05 21:55:51 -08:00
Nate Goldman
7c1c430097 hide header on video after mouse idle 2016-03-05 20:33:12 -08:00
Feross Aboukhadijeh
569111d336 load torrents from state.saved 2016-03-05 20:16:10 -08:00
Feross Aboukhadijeh
6664c92ea6 refactor torrent event handling 2016-03-05 20:08:12 -08:00
Feross Aboukhadijeh
edf3d83e2e TODO 2016-03-05 20:07:55 -08:00
Feross Aboukhadijeh
db5de7d3ad one less global 2016-03-05 20:07:51 -08:00
Feross Aboukhadijeh
c7b49ae45b renderer: Use dispatch() code path even for ipc messages 2016-03-05 19:52:31 -08:00
Feross Aboukhadijeh
c01fb66bae move renderer state into new file 2016-03-05 19:52:16 -08:00
Feross Aboukhadijeh
e78716b0fa add missing update() calls (fix #36) 2016-03-05 19:33:28 -08:00
Feross Aboukhadijeh
52427dd183 Hide player controls when mouse is still, even when not fullscreened (fix #37) 2016-03-05 19:24:42 -08:00
Feross Aboukhadijeh
edb16a1bf1 Use single quotes in hyperx 2016-03-05 19:02:40 -08:00
DC
d1b61bdc07 Hide cursor after 2s in fullscreen 2016-03-05 17:01:20 -08:00
DC
098827ec78 State: put temp state directly in state, saved in state.saved 2016-03-05 16:00:41 -08:00
DC
5b383d3ed0 Split state into temp and saved
Also stop using IPC to calculate window width

Add default torrents--the Blender Foundation videos--not displayed yet
2016-03-05 15:51:43 -08:00
Nate Goldman
c2b5f7a7bb Merge pull request #28 from feross/main-loop
Batch virtual-dom changes (fix #27)
2016-03-05 15:35:02 -08:00
Feross Aboukhadijeh
5c45a81665 Batch virtual-dom changes (fix #27)
From `main-loop`:

> main-loop is an optimization module for a virtual DOM system.
Normally you would re-create the virtual tree every time your state
changes. This is not optimum, with main-loop you will only update your
virtual tree at most once per request animation frame.

> main-loop basically gives you batching of your virtual DOM changes,
which means if you change your model multiple times it will be rendered
once asynchronously on the next request animation frame.
2016-03-05 15:25:15 -08:00
Feross Aboukhadijeh
11464176cb Start in correct full screen state
If the app is already fullscreen when it is loaded, set
state.view.isFullScreen to the correct state.
2016-03-05 14:56:55 -08:00
Feross Aboukhadijeh
fc68a08de7 menu: new "Add Fake Airplay" and "Add Fake Chromecast" items
Fixes #21
2016-03-05 14:04:33 -08:00
Nate Goldman
6e5a481903 fix chromecast play 2016-03-05 11:39:32 -08:00
Nate Goldman
efc116f0ad rm console.log 2016-03-05 10:03:31 -08:00
DC
e4f2716d06 Video player polish
No header on Linux and OSX, just a back button on mouseover

ESC exits fullscreen, or if already not in fullscreen, goes back

More accurate scrub position

Removed the calc(100% -38x) hack, replaced with flexbox
2016-03-05 06:12:02 -08:00
DC
59b3bd04a9 Letterbox video. Hide toolbar in fullscreen
Cleaner-looking Chromecast and Airplay icons

Hide top bar in full screen mode
2016-03-05 05:14:24 -08:00
DC
b7b30ed7c4 Cast buttons and fullscreen in player controls 2016-03-05 01:09:34 -08:00