One more bit of cleanup for PR #529.
We can register `handleClick` once on the `<tr>` tag and just have the
onclick handler on `col-select` too. Because dispatcher calls
`event.stopPropagation()` we don't need to worry about event bubbling
up to the `<tr>`.
The goal of this commit is to merge the two torrent status lines onto a
single, concise line which has high signal and information density.
- Hide download speed, upload speed, and number of peers when 0,
because that's just noise.
- Remove number of files, because that information can be found by
expanding the torrent.
This also allowed the further reduction of the torrent item height from
110px to 100px.
Based on @watson's PR #463.
Differences:
- Remove the "Open Folder" link from expanded torrent view.
- Use showItemInFolder instead of openItem electron API
- Add a separator
- Use IPC to invoke electron.shell.showItemInFolder from main process
* Separate hidden window, with its own renderer process, for WebTorrent
(Must be a window. You cannot run WebRTC at all in a Web Worker, and you can't
run it well in a node process like the electron main process.)
* Disabled the create-torrent-modal for now. That gives us a consistent UX
regardless of whether the user dragged files or folders onto the app or opened
the Create New Torrent menu item.
* Main process routes all messages between the main and webtorrent windows.
* The renderer index.js is smaller now (but still too big), with the WebTorrent
interface moved to webtorrent.js / it's own process.
* The UI should be faster now, and should not lag under load.
* Work around a Chrome bug by avoiding Windows-specific backslash paths
* Change the name of the program from "Streaming torrent client" to "WebTorrent"
Next step: Chromecast and Airplay play/pause, scrub, and state management
When casting, the correct cast button should be lit up and the video should be replaced with a title image and text
- make torrent placeholder the exact size of a normal torrent
- make torrent list window minimum size of two torrents
- make window start out sized for 4 torrents
- increase font size responsively
* 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
* 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